mirror of
https://github.com/microsoft/GSL.git
synced 2024-11-03 17:56:43 -05:00
Move git commands for appveyor to batch file
This commit is contained in:
parent
7262240b19
commit
85dd342eb4
15
appveyor.yml
15
appveyor.yml
@ -73,6 +73,7 @@ install:
|
|||||||
}
|
}
|
||||||
|
|
||||||
before_build:
|
before_build:
|
||||||
|
- set ASM_FOLDER=%APPVEYOR_BUILD_WORKER_IMAGE%_%GSL_CXX_STANDARD%_%USE_TOOLSET%_%env:PLATFORM%_%env:CONFIGURATION%
|
||||||
- ps: |
|
- ps: |
|
||||||
if ("$env:USE_GENERATOR" -eq "Ninja") {
|
if ("$env:USE_GENERATOR" -eq "Ninja") {
|
||||||
$GeneratorFlags = '-k 10'
|
$GeneratorFlags = '-k 10'
|
||||||
@ -82,7 +83,7 @@ before_build:
|
|||||||
} else {
|
} else {
|
||||||
$env:VCVARSALL = "`"$env:VCVAR2017`" $Architecture"
|
$env:VCVARSALL = "`"$env:VCVAR2017`" $Architecture"
|
||||||
}
|
}
|
||||||
$env:CMakeGenFlags = "-G Ninja -DGSL_CXX_STANDARD=$env:GSL_CXX_STANDARD -DGSL_ASM_FOLDER=`"$($env:APPVEYOR_BUILD_WORKER_IMAGE)_$($env:GSL_CXX_STANDARD)_$($env:USE_TOOLSET)_$($env:PLATFORM)_$($env:CONFIGURATION)`""
|
$env:CMakeGenFlags = "-G Ninja -DGSL_CXX_STANDARD=$env:GSL_CXX_STANDARD -DGSL_ASM_FOLDER=`"$($env:ASM_FOLDER)`""
|
||||||
} else {
|
} else {
|
||||||
$GeneratorFlags = '/m /v:minimal'
|
$GeneratorFlags = '/m /v:minimal'
|
||||||
if ("$env:APPVEYOR_BUILD_WORKER_IMAGE" -eq "Visual Studio 2015") {
|
if ("$env:APPVEYOR_BUILD_WORKER_IMAGE" -eq "Visual Studio 2015") {
|
||||||
@ -96,9 +97,9 @@ before_build:
|
|||||||
$Architecture = "x64"
|
$Architecture = "x64"
|
||||||
}
|
}
|
||||||
if ("$env:USE_TOOLSET" -eq "LLVM") {
|
if ("$env:USE_TOOLSET" -eq "LLVM") {
|
||||||
$env:CMakeGenFlags = "-G `"$Generator`" -A $Architecture -T llvm -DGSL_CXX_STANDARD=$env:GSL_CXX_STANDARD -DGSL_ASM_FOLDER=`"$($env:APPVEYOR_BUILD_WORKER_IMAGE)_$($env:GSL_CXX_STANDARD)_$($env:USE_TOOLSET)_$($env:PLATFORM)_$($env:CONFIGURATION)`""
|
$env:CMakeGenFlags = "-G `"$Generator`" -A $Architecture -T llvm -DGSL_CXX_STANDARD=$env:GSL_CXX_STANDARD -DGSL_ASM_FOLDER=`"$($env:ASM_FOLDER)`""
|
||||||
} else {
|
} else {
|
||||||
$env:CMakeGenFlags = "-G `"$Generator`" -A $Architecture -DGSL_CXX_STANDARD=$env:GSL_CXX_STANDARD -DGSL_ASM_FOLDER=`"$($env:APPVEYOR_BUILD_WORKER_IMAGE)_$($env:GSL_CXX_STANDARD)_$($env:USE_TOOLSET)_$($env:PLATFORM)_$($env:CONFIGURATION)`""
|
$env:CMakeGenFlags = "-G `"$Generator`" -A $Architecture -DGSL_CXX_STANDARD=$env:GSL_CXX_STANDARD -DGSL_ASM_FOLDER=`"$($env:ASM_FOLDER)`""
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if ("$env:USE_TOOLSET" -eq "LLVM") {
|
if ("$env:USE_TOOLSET" -eq "LLVM") {
|
||||||
@ -136,13 +137,7 @@ on_success:
|
|||||||
- git config --global user.name "Daniel Donenfeld"
|
- git config --global user.name "Daniel Donenfeld"
|
||||||
- git config --global core.autocrlf false
|
- git config --global core.autocrlf false
|
||||||
- cd %APPVEYOR_BUILD_FOLDER%
|
- cd %APPVEYOR_BUILD_FOLDER%
|
||||||
# - ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
|
- push_asm.bat
|
||||||
- git checkout %APPVEYOR_REPO_BRANCH%
|
|
||||||
- git add "asm/*"
|
|
||||||
# - ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
|
|
||||||
- git status
|
|
||||||
- git diff-index --cached --quiet --exit-code HEAD || (git commit -m "[skip ci] Update ASM for %APPVEYOR_BUILD_WORKER_IMAGE%_%GSL_CXX_STANDARD%_%USE_TOOLSET%_%PLATFORM%_%CONFIGURATION%" && git push)
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
deploy: off
|
deploy: off
|
||||||
|
4
push_asm.bat
Normal file
4
push_asm.bat
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
git checkout %APPVEYOR_REPO_BRANCH%
|
||||||
|
git add "asm/*"
|
||||||
|
git status
|
||||||
|
git diff-index --cached --quiet --exit-code HEAD || (git commit -m "[skip ci] Update ASM for %ASM_FOLDER%" && git push)
|
Loading…
Reference in New Issue
Block a user