Updating Unity distr to 2022.3.17f1 and Cinemachine to 3.0.1 #30
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: Main workflow 🎮 | |
on: | |
push: | |
branches: | |
- main | |
env: | |
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }} | |
UNITY_EMAIL: ${{ secrets.UNITY_EMAIL }} | |
UNITY_PASSWORD: ${{ secrets.UNITY_PASSWORD }} | |
# TODO Read the value from ProjectVersion.txt | |
UNITY_VERSION: 2022.3.17f1 | |
jobs: | |
buildWebGL: | |
name: Build for WebGL 🖥️ | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Create LFS file list | |
run: git lfs ls-files -l | cut -d' ' -f1 | sort > .lfs-assets-id | |
- name: Restore LFS cache | |
uses: actions/cache@v3 | |
id: lfs-cache | |
with: | |
path: .git/lfs | |
key: ${{ runner.os }}-lfs-${{ hashFiles('.lfs-assets-id') }} | |
- name: Git LFS Pull | |
run: | | |
git lfs pull | |
git add . | |
git reset --hard | |
- name: Restore Library cache | |
uses: actions/cache@v3 | |
with: | |
path: Library | |
key: Library-build-WebGL | |
restore-keys: | | |
Library-build- | |
Library- | |
- uses: game-ci/[email protected] | |
with: | |
unityVersion: ${{ env.UNITY_VERSION }} | |
targetPlatform: WebGL | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: build-WebGL | |
path: build/WebGL | |
deployPages: | |
needs: buildWebGL | |
name: Deploy to Github Pages 🚀 | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- uses: actions/download-artifact@v3 | |
with: | |
name: build-WebGL | |
path: build | |
- name: Deploy 🚀 | |
uses: JamesIves/github-pages-deploy-action@v4 | |
with: | |
branch: gh-pages | |
folder: build/WebGL |