Skip to content
Snippets Groups Projects
Commit d45ad754 authored by Zach Hilman's avatar Zach Hilman
Browse files

ci: Add version counter variable

parent 0a662d00
No related branches found
No related tags found
No related merge requests found
...@@ -5,7 +5,7 @@ cd /yuzu ...@@ -5,7 +5,7 @@ cd /yuzu
ccache -s ccache -s
mkdir build || true && cd build mkdir build || true && cd build
cmake .. -G Ninja -DYUZU_USE_BUNDLED_UNICORN=ON -DYUZU_USE_QT_WEB_ENGINE=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_C_COMPILER=/usr/lib/ccache/gcc -DCMAKE_CXX_COMPILER=/usr/lib/ccache/g++ -DYUZU_ENABLE_COMPATIBILITY_REPORTING=${ENABLE_COMPATIBILITY_REPORTING:-"OFF"} -DENABLE_COMPATIBILITY_LIST_DOWNLOAD=ON -DUSE_DISCORD_PRESENCE=ON cmake .. -G Ninja -DDISPLAY_VERSION=$1 -DYUZU_USE_BUNDLED_UNICORN=ON -DYUZU_USE_QT_WEB_ENGINE=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_C_COMPILER=/usr/lib/ccache/gcc -DCMAKE_CXX_COMPILER=/usr/lib/ccache/g++ -DYUZU_ENABLE_COMPATIBILITY_REPORTING=${ENABLE_COMPATIBILITY_REPORTING:-"OFF"} -DENABLE_COMPATIBILITY_LIST_DOWNLOAD=ON -DUSE_DISCORD_PRESENCE=ON
ninja ninja
......
...@@ -2,4 +2,4 @@ ...@@ -2,4 +2,4 @@
mkdir -p "ccache" || true mkdir -p "ccache" || true
chmod a+x ./.ci/scripts/linux/docker.sh chmod a+x ./.ci/scripts/linux/docker.sh
docker run -e ENABLE_COMPATIBILITY_REPORTING -e CCACHE_DIR=/yuzu/ccache -v $(pwd):/yuzu yuzuemu/build-environments:linux-fresh /bin/bash /yuzu/.ci/scripts/linux/docker.sh docker run -e ENABLE_COMPATIBILITY_REPORTING -e CCACHE_DIR=/yuzu/ccache -v $(pwd):/yuzu yuzuemu/build-environments:linux-fresh /bin/bash /yuzu/.ci/scripts/linux/docker.sh $1
...@@ -13,7 +13,7 @@ echo '' >> /bin/cmd ...@@ -13,7 +13,7 @@ echo '' >> /bin/cmd
chmod +x /bin/cmd chmod +x /bin/cmd
mkdir build || true && cd build mkdir build || true && cd build
cmake .. -G Ninja -DCMAKE_TOOLCHAIN_FILE="$(pwd)/../CMakeModules/MinGWCross.cmake" -DUSE_CCACHE=ON -DYUZU_USE_BUNDLED_UNICORN=ON -DENABLE_COMPATIBILITY_LIST_DOWNLOAD=ON -DCMAKE_BUILD_TYPE=Release cmake .. -G Ninja -DDISPLAY_VERSION=$1 -DCMAKE_TOOLCHAIN_FILE="$(pwd)/../CMakeModules/MinGWCross.cmake" -DUSE_CCACHE=ON -DYUZU_USE_BUNDLED_UNICORN=ON -DENABLE_COMPATIBILITY_LIST_DOWNLOAD=ON -DCMAKE_BUILD_TYPE=Release
ninja ninja
# Clean up the dirty hacks # Clean up the dirty hacks
......
...@@ -2,4 +2,4 @@ ...@@ -2,4 +2,4 @@
mkdir -p "ccache" || true mkdir -p "ccache" || true
chmod a+x ./.ci/scripts/windows/docker.sh chmod a+x ./.ci/scripts/windows/docker.sh
docker run -e CCACHE_DIR=/yuzu/ccache -v $(pwd):/yuzu yuzuemu/build-environments:linux-mingw /bin/bash -ex /yuzu/.ci/scripts/windows/docker.sh docker run -e CCACHE_DIR=/yuzu/ccache -v $(pwd):/yuzu yuzuemu/build-environments:linux-mingw /bin/bash -ex /yuzu/.ci/scripts/windows/docker.sh $1
parameters: parameters:
artifactSource: 'true' artifactSource: 'true'
cache: 'false' cache: 'false'
version: ''
steps: steps:
- script: mkdir build && cd build && set DATE=`date '+%Y.%m.%d'` && set CI=true && set AZURE_REPO_NAME=yuzu-emu/yuzu-$(BuildName) && set AZURE_REPO_TAG=$(BuildName)-$DATE && cmake -G "Visual Studio 15 2017 Win64" --config Release -DYUZU_USE_BUNDLED_QT=1 -DYUZU_USE_BUNDLED_SDL2=1 -DYUZU_USE_BUNDLED_UNICORN=1 -DYUZU_USE_QT_WEB_ENGINE=ON -DENABLE_COMPATIBILITY_LIST_DOWNLOAD=ON -DYUZU_ENABLE_COMPATIBILITY_REPORTING=${COMPAT} -DUSE_DISCORD_PRESENCE=ON .. && cd .. - script: mkdir build && cd build && cmake -G "Visual Studio 15 2017 Win64" --config Release -DYUZU_USE_BUNDLED_QT=1 -DYUZU_USE_BUNDLED_SDL2=1 -DYUZU_USE_BUNDLED_UNICORN=1 -DYUZU_USE_QT_WEB_ENGINE=ON -DENABLE_COMPATIBILITY_LIST_DOWNLOAD=ON -DYUZU_ENABLE_COMPATIBILITY_REPORTING=${COMPAT} -DUSE_DISCORD_PRESENCE=ON -DDISPLAY_VERSION=${{ parameters['version'] }} .. && cd ..
displayName: 'Configure CMake' displayName: 'Configure CMake'
- task: MSBuild@1 - task: MSBuild@1
displayName: 'Build' displayName: 'Build'
......
parameters: parameters:
artifactSource: 'true' artifactSource: 'true'
cache: 'false' cache: 'false'
version: ''
steps: steps:
- task: DockerInstaller@0 - task: DockerInstaller@0
...@@ -13,7 +14,7 @@ steps: ...@@ -13,7 +14,7 @@ steps:
key: yuzu-v1-$(BuildName)-$(BuildSuffix)-$(CacheSuffix) key: yuzu-v1-$(BuildName)-$(BuildSuffix)-$(CacheSuffix)
path: $(System.DefaultWorkingDirectory)/ccache path: $(System.DefaultWorkingDirectory)/ccache
cacheHitVar: CACHE_RESTORED cacheHitVar: CACHE_RESTORED
- script: export DATE=`date '+%Y.%m.%d'` && export CI=true && export AZURE_REPO_NAME=yuzu-emu/yuzu-$(BuildName) && export AZURE_REPO_TAG=$(BuildName)-$DATE && chmod a+x ./.ci/scripts/$(ScriptFolder)/exec.sh && ./.ci/scripts/$(ScriptFolder)/exec.sh - script: chmod a+x ./.ci/scripts/$(ScriptFolder)/exec.sh && ./.ci/scripts/$(ScriptFolder)/exec.sh ${{ parameters['version'] }}
displayName: 'Build' displayName: 'Build'
- script: chmod a+x ./.ci/scripts/$(ScriptFolder)/upload.sh && RELEASE_NAME=$(BuildName) ./.ci/scripts/$(ScriptFolder)/upload.sh - script: chmod a+x ./.ci/scripts/$(ScriptFolder)/upload.sh && RELEASE_NAME=$(BuildName) ./.ci/scripts/$(ScriptFolder)/upload.sh
displayName: 'Package Artifacts' displayName: 'Package Artifacts'
......
parameters:
version: ''
jobs: jobs:
- job: build - job: build
displayName: 'standard' displayName: 'standard'
...@@ -20,4 +23,5 @@ jobs: ...@@ -20,4 +23,5 @@ jobs:
- template: ./build-single.yml - template: ./build-single.yml
parameters: parameters:
artifactSource: 'false' artifactSource: 'false'
cache: $(parameters.cache) cache: $(parameters.cache)
\ No newline at end of file version: $(parameters.version)
\ No newline at end of file
parameters:
version: ''
jobs: jobs:
- job: build_test - job: build_test
displayName: 'testing' displayName: 'testing'
...@@ -31,3 +34,4 @@ jobs: ...@@ -31,3 +34,4 @@ jobs:
parameters: parameters:
artifactSource: 'false' artifactSource: 'false'
cache: 'false' cache: 'false'
version: $(parameters.version)
\ No newline at end of file
trigger: trigger:
- master - master
variables:
DisplayVersion: $[counter(variables['DisplayPrefix'], 1)]
stages: stages:
- stage: format - stage: format
displayName: 'format' displayName: 'format'
...@@ -34,6 +37,7 @@ stages: ...@@ -34,6 +37,7 @@ stages:
parameters: parameters:
artifactSource: 'false' artifactSource: 'false'
cache: 'true' cache: 'true'
version: $(DisplayVersion)
- stage: build_win - stage: build_win
dependsOn: format dependsOn: format
displayName: 'build-windows' displayName: 'build-windows'
...@@ -51,6 +55,7 @@ stages: ...@@ -51,6 +55,7 @@ stages:
parameters: parameters:
artifactSource: 'false' artifactSource: 'false'
cache: 'true' cache: 'true'
version: $(DisplayVersion)
- stage: release - stage: release
displayName: 'Release' displayName: 'Release'
dependsOn: dependsOn:
......
trigger: trigger:
- master - master
variables:
DisplayVersion: $[counter(variables['DisplayPrefix'], 1)]
stages: stages:
- stage: format - stage: format
displayName: 'format' displayName: 'format'
...@@ -28,3 +31,4 @@ stages: ...@@ -28,3 +31,4 @@ stages:
parameters: parameters:
artifactSource: 'false' artifactSource: 'false'
cache: $(parameters.cache) cache: $(parameters.cache)
version: $(DisplayVersion)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment