MajdataPlay build #991
Workflow file for this run
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 Project | |
run-name: MajdataPlay build | |
on: [push] | |
env: | |
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }} | |
UNITY_EMAIL: ${{ secrets.UNITY_EMAIL }} | |
UNITY_PASSWORD: ${{ secrets.UNITY_PASSWORD }} | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
configuration: [Debug, Release] | |
env: | |
COMMIT_HASH_FULL: ${{ github.sha }} | |
OUTPUT_NAME: MajdataPlay-${{ matrix.configuration }} | |
CONFIGURATION: ${{ matrix.configuration }} | |
TARGET_PLATFORM: "StandaloneWindows64" | |
steps: | |
- name: Get commit hash | |
run: echo "COMMIT_HASH=$(echo ${{ env.COMMIT_HASH_FULL }} | cut -c1-7)" >> $GITHUB_ENV | |
- name: Setup output filename | |
run: echo "OUTPUT_NAME=MajdataPlay-${{ env.COMMIT_HASH }}-${{ matrix.configuration }}" >> $GITHUB_ENV | |
- name: Checkout the repository | |
uses: actions/checkout@v4 | |
with: | |
submodules: true | |
fetch-depth: 0 | |
- name: Cache libraries | |
uses: actions/cache@v3 | |
with: | |
path: Library | |
key: Library-${{ env.TARGET_PLATFORM }} | |
restore-keys: Library-${{ env.TARGET_PLATFORM }} | |
- if: env.CONFIGURATION == 'Debug' | |
name: Debug build | |
uses: game-ci/unity-builder@v4.3.0 | |
with: | |
targetPlatform: ${{ env.TARGET_PLATFORM }} | |
versioning: Semantic | |
buildName: MajdataPlay | |
buildsPath: ${{ env.CONFIGURATION }} | |
buildMethod: MajdataPlay.Misc.Editor.CustomBuild.BuildDebug | |
- if: env.CONFIGURATION == 'Release' | |
name: Release build | |
uses: game-ci/unity-builder@v4.3.0 | |
with: | |
targetPlatform: ${{ env.TARGET_PLATFORM }} | |
versioning: Semantic | |
buildName: MajdataPlay | |
buildsPath: ${{ env.CONFIGURATION }} | |
- name: List files in build directory | |
run: ls -R ${{ env.CONFIGURATION }} | |
- name: Upload build | |
uses: actions/upload-artifact@v4 | |
with: | |
name: ${{ env.OUTPUT_NAME }} | |
path: ${{ env.CONFIGURATION }} |