From 55ece560a121900d61057975a9308f06c7d86c0d Mon Sep 17 00:00:00 2001 From: Daniel Lovell Date: Wed, 25 Sep 2024 16:51:21 -0700 Subject: [PATCH] Added builder.yaml CI action --- .github/workflows/builder.yaml | 37 ++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 .github/workflows/builder.yaml diff --git a/.github/workflows/builder.yaml b/.github/workflows/builder.yaml new file mode 100644 index 0000000..d545c14 --- /dev/null +++ b/.github/workflows/builder.yaml @@ -0,0 +1,37 @@ +name: Build project + +on: [push, pull_request] + +jobs: + buildForAllSupportedPlatforms: + name: Build for ${{ matrix.targetPlatform }} + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + targetPlatform: + - StandaloneOSX # Build a macOS standalone (Intel 64-bit). + - StandaloneWindows64 # Build a Windows 64-bit standalone. + steps: + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + lfs: false + - uses: actions/cache@v3 + with: + path: Library + key: Library-${{ matrix.targetPlatform }} + restore-keys: Library- + - if: matrix.targetPlatform == 'Android' + uses: jlumbroso/free-disk-space@v1.3.1 + - uses: game-ci/unity-builder@v4 + env: + UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }} + UNITY_EMAIL: ${{ secrets.UNITY_EMAIL }} + UNITY_PASSWORD: ${{ secrets.UNITY_PASSWORD }} + with: + targetPlatform: ${{ matrix.targetPlatform }} + - uses: actions/upload-artifact@v3 + with: + name: Build-${{ matrix.targetPlatform }} + path: build/${{ matrix.targetPlatform }} \ No newline at end of file