mirror of
https://github.com/microsoft/GSL.git
synced 2024-11-03 17:56:43 -05:00
Add extra checks and logging
This commit is contained in:
parent
c9219945fa
commit
3d45a84f47
@ -166,7 +166,13 @@ on_finish:
|
|||||||
"Authorization" = "Bearer $env:APPVEYOR_API_TOKEN"
|
"Authorization" = "Bearer $env:APPVEYOR_API_TOKEN"
|
||||||
"Content-type" = "application/json"
|
"Content-type" = "application/json"
|
||||||
}
|
}
|
||||||
$build.build.jobs | Foreach-Object { git push origin --delete asm/$($env:APPVEYOR_REPO_COMMIT)/appveyor-$($_.jobId) }
|
$build.build.jobs | Foreach-Object {
|
||||||
|
$branchName = "asm/$($env:APPVEYOR_REPO_COMMIT)/appveyor-$($_.jobId)"
|
||||||
|
git ls-remote --heads --exit-code https://github.com/dadonenf/GSL.git $branchName
|
||||||
|
if($?){
|
||||||
|
git push origin --delete asm/$($env:APPVEYOR_REPO_COMMIT)/appveyor-$($_.jobId)
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -110,7 +110,20 @@ function collectAsm {
|
|||||||
|
|
||||||
#collect all branches to merge
|
#collect all branches to merge
|
||||||
$asmBranches = @()
|
$asmBranches = @()
|
||||||
(Get-AppVeyorBuild).build.jobs | Foreach-Object { $asmBranches += "origin/asm/$($env:APPVEYOR_REPO_COMMIT)/appveyor-$($_.jobId)"}
|
(Get-AppVeyorBuild).build.jobs | Foreach-Object {
|
||||||
|
$branchName = "asm/$($env:APPVEYOR_REPO_COMMIT)/appveyor-$($_.jobId)"
|
||||||
|
|
||||||
|
#Check that all branches exist
|
||||||
|
git ls-remote --heads --exit-code https://github.com/dadonenf/GSL.git $branchName
|
||||||
|
if(-not $?){
|
||||||
|
throw "Missing branch for job $($_.jobId)"
|
||||||
|
}
|
||||||
|
|
||||||
|
#Add origin branch to the branch list
|
||||||
|
$branchName = "origin/"+$branchName
|
||||||
|
$asmBranches += $branchName
|
||||||
|
}
|
||||||
|
|
||||||
#TODO: collect asm from travis
|
#TODO: collect asm from travis
|
||||||
# $travisBuild = Get-TravisBuild
|
# $travisBuild = Get-TravisBuild
|
||||||
# $travisJobs = @()
|
# $travisJobs = @()
|
||||||
@ -121,6 +134,7 @@ function collectAsm {
|
|||||||
git checkout master
|
git checkout master
|
||||||
git pull
|
git pull
|
||||||
git branch -a
|
git branch -a
|
||||||
|
Write-Host "git merge --squash $($branchString)"
|
||||||
git merge --squash $branchString
|
git merge --squash $branchString
|
||||||
if(-not $?){
|
if(-not $?){
|
||||||
throw "Failed merge"
|
throw "Failed merge"
|
||||||
|
Loading…
Reference in New Issue
Block a user