Skip to content

Build release assets #128

Build release assets

Build release assets #128

Workflow file for this run

name: Build release assets
on:
release:
types:
- created
env:
UNITY_EMAIL: ${{ secrets.UNITY_EMAIL }}
UNITY_PASSWORD: ${{ secrets.UNITY_PASSWORD }}
UNITY_SERIAL: ${{ secrets.UNITY_SERIAL }}
GITHUB_TOKEN: ${{ github.token }}
jobs:
build:
name: Build for ${{ matrix.targetPlatform }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
targetPlatform:
- StandaloneWindows
- StandaloneWindows64
- StandaloneLinux64
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
lfs: true
ref: ${{ github.event.release.tag }}
- uses: actions/cache@v2
with:
path: Library
key: Library-${{ matrix.targetPlatform }}
restore-keys: Library-
- uses: game-ci/unity-builder@v4
with:
targetPlatform: ${{ matrix.targetPlatform }}
- uses: vimtor/action-zip@v1
with:
files: build/${{ matrix.targetPlatform }}/
recursive: true
dest: ${{ matrix.targetPlatform }}.zip
- uses: shogo82148/actions-upload-release-asset@v1
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ${{ matrix.targetPlatform }}.zip