Repository navigation
fixed store plants packet if more plants were added before gatlingpea… #194
This file contains hidden or 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 | |
| on: | |
| push: | |
| branches: [dev, main] | |
| pull_request: | |
| branches: [dev, main] | |
| workflow_dispatch: | |
| permissions: | |
| contents: read | |
| env: | |
| VCPKG_MANIFEST_DIR: ${{ github.workspace }} | |
| jobs: | |
| build: | |
| runs-on: windows-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - preset: windows-x64-release-msvc | |
| build_preset: Windows-x64-Release | |
| triplet: x64-windows-static | |
| artifact_name: Export-x64-Release | |
| - preset: windows-x86-release-msvc | |
| build_preset: Windows-x86-Release | |
| triplet: x86-windows-static | |
| artifact_name: Export-x86-Release | |
| - preset: windows-x64-debug-msvc | |
| build_preset: Windows-x64-Debug | |
| triplet: x64-windows-static | |
| artifact_name: Export-x64-Debug | |
| - preset: windows-x86-debug-msvc | |
| build_preset: Windows-x86-Debug | |
| triplet: x86-windows-static | |
| artifact_name: Export-x86-Debug | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Setup MSVC Developer Environment | |
| uses: ilammy/msvc-dev-cmd@v1 | |
| with: | |
| arch: ${{ contains(matrix.preset, 'x86') && 'x86' || 'x64' }} | |
| - name: Setup CMake | |
| uses: lukka/get-cmake@latest | |
| with: | |
| cmakeVersion: '3.31' | |
| - name: Setup vcpkg | |
| uses: lukka/run-vcpkg@v11 | |
| with: | |
| vcpkgGitCommitId: d59510da59a2ee8b943509998b63da7b472d93cf | |
| - name: Cache vcpkg binary packages | |
| uses: actions/cache@v4 | |
| with: | |
| path: | | |
| ${{ github.workspace }}/vcpkg/downloads | |
| ${{ github.workspace }}/vcpkg/packages | |
| key: vcpkg-${{ matrix.triplet }}-${{ hashFiles('vcpkg.json', 'vcpkg-configuration.json') }} | |
| restore-keys: | | |
| vcpkg-${{ matrix.triplet }}- | |
| - name: Configure | |
| run: cmake --preset ${{ matrix.preset }} -DGITHUB_ACTIONS=ON | |
| env: | |
| VCPKG_DEFAULT_TRIPLET: ${{ matrix.triplet }} | |
| - name: Build | |
| run: cmake --build --preset ${{ matrix.build_preset }} | |
| - name: Install | |
| run: cmake --install out/build/msvc/${{ matrix.preset }} | |
| - name: Package Export folder | |
| run: | | |
| mkdir packaged | |
| powershell Compress-Archive -Path "Export/*" -DestinationPath "packaged/${{ matrix.artifact_name }}.zip" | |
| - name: Upload artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: ${{ matrix.artifact_name }} | |
| path: packaged/${{ matrix.artifact_name }}.zip | |
| - name: Build summary | |
| if: always() | |
| run: | | |
| echo "## Build Result: ${{ matrix.artifact_name }}" >> $env:GITHUB_STEP_SUMMARY | |
| echo "- **Preset:** ${{ matrix.preset }}" >> $env:GITHUB_STEP_SUMMARY | |
| echo "- **Triplet:** ${{ matrix.triplet }}" >> $env:GITHUB_STEP_SUMMARY | |
| echo "- **Status:** ${{ job.status }}" >> $env:GITHUB_STEP_SUMMARY |