CI pipeline triggered by egor-demidov #25
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build Windows | |
run-name: CI pipeline triggered by ${{ github.actor }} | |
permissions: | |
contents: write | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
VCPKG_FEATURE_FLAGS: dependencygraph | |
VCPKG_BINARY_SOURCES: "clear;x-gha,readwrite" | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
jobs: | |
Compile-Windows-MSVC: | |
runs-on: windows-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
with: | |
submodules: recursive | |
- name: Export GitHub Actions cache environment variables | |
uses: actions/github-script@v7 | |
with: | |
script: | | |
core.exportVariable('ACTIONS_CACHE_URL', process.env.ACTIONS_CACHE_URL || ''); | |
core.exportVariable('ACTIONS_RUNTIME_TOKEN', process.env.ACTIONS_RUNTIME_TOKEN || ''); | |
- name: Set up vcpkg and configure | |
run: | | |
$src_dir = pwd | |
C: | |
cd / | |
git clone https://github.com/microsoft/vcpkg.git | |
cd vcpkg; .\bootstrap-vcpkg.bat | |
$env:VCPKG_ROOT = pwd | |
$env:PATH = "$env:VCPKG_ROOT;$env:PATH" | |
cd $src_dir | |
cmake -G Ninja -DVCPKG_INSTALL_OPTIONS="--x-buildtrees-root=C:/bld;--x-packages-root=C:/pkg" -DVCPKG_TARGET_TRIPLET=x64-windows-static -DVCPKG_BUILD_TYPE=Release -DCMAKE_BUILD_TYPE=Release --preset=default . | |
type C:\bld\qtdeclarative\install-x64-windows-static-rel-out.log | |
- name: Build | |
run: | | |
cd build | |
cmake --build . --config Release | |
dir | |
- name: Archive compiled artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: soot-dem-gui-windows-msvc-x86_64 | |
path: | | |
. |