mirror of
https://github.com/Blinue/Magpie.git
synced 2026-06-24 02:04:10 +00:00
Bumps [actions/checkout](https://github.com/actions/checkout) from 5 to 6. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v5...v6) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '6' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
49 lines
1.6 KiB
YAML
49 lines
1.6 KiB
YAML
name: build
|
|
|
|
on:
|
|
push:
|
|
paths: [ '.github/workflows/build.yml', 'Magpie.sln', '*.props', 'scripts/publish.py', 'src/**' ]
|
|
pull_request:
|
|
paths: [ '.github/workflows/build.yml', 'Magpie.sln', '*.props', 'scripts/publish.py', 'src/**' ]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: windows-latest
|
|
strategy:
|
|
matrix:
|
|
compiler: ["MSVC", "ClangCL"]
|
|
platform: ["x64", "ARM64"]
|
|
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
|
|
- uses: actions/setup-python@v6
|
|
with:
|
|
python-version: '3.11'
|
|
|
|
- name: Setup Conan
|
|
run: pip install conan
|
|
|
|
- name: Load Conan cache
|
|
uses: actions/cache@v4
|
|
with:
|
|
path: ~/.conan2/p
|
|
key: Conan-${{ hashFiles('src/**/conanfile.txt') }}-${{ matrix.compiler }}-${{ matrix.platform }}
|
|
|
|
- name: Build
|
|
if: github.ref != 'refs/heads/dev' && github.ref != 'refs/heads/main'
|
|
run: python scripts/publish.py --compiler=${{ matrix.compiler }} --platform=${{ matrix.platform }}
|
|
|
|
- name: Build and sign
|
|
if: github.ref == 'refs/heads/dev' || github.ref == 'refs/heads/main'
|
|
run: python scripts/publish.py --compiler=${{ matrix.compiler }} --platform=${{ matrix.platform }} --pfx-path=certs\Magpie.pfx --pfx-password="${{ secrets.MAGPIE_PFX_PASSWORD }}"
|
|
|
|
- name: Save hash
|
|
id: hash
|
|
run: echo "sha_short=$(git rev-parse --short HEAD)" >> $env:GITHUB_OUTPUT
|
|
|
|
- name: Store build
|
|
uses: actions/upload-artifact@v5
|
|
with:
|
|
name: Magpie-dev-${{ steps.hash.outputs.sha_short }}-${{ matrix.compiler }}-${{ matrix.platform }}
|
|
path: ./publish/${{ matrix.platform }}
|