forked from DeviceFarmer/minitouch
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcheck_if_new.ps1
More file actions
19 lines (15 loc) · 744 Bytes
/
check_if_new.ps1
File metadata and controls
19 lines (15 loc) · 744 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
Push-Location DeviceFarmer_minitouch
$json = (ConvertFrom-Json $env:last_release_json)
# $json.name; $json.tag_name
$current_commit = git log -1 --format=%h
$current_commit_msg = git log -1 --format=%s
Write-Output "::echo::on"
Write-Output "current:$current_commit - last:$($json.tag_name)"
if (-not ($json.tag_name -eq $current_commit)) { $new_commit = "true" } else { $new_commit = "false" }
Write-Output "new_commit=$new_commit" >> $Env:GITHUB_ENV
Write-Output "new_commit=$new_commit"
Write-Output "current_commit=$current_commit" >> $Env:GITHUB_ENV
Write-Output "current_commit=$current_commit"
Write-Output "current_commit_msg=$current_commit_msg" >> $Env:GITHUB_ENV
Write-Output "current_commit_msg=$current_commit_msg"
Pop-Location