Skip to content

Commit 268da8e

Browse files
committed
fix: testing project generation.
1 parent 3b6eacb commit 268da8e

File tree

1 file changed

+17
-21
lines changed

1 file changed

+17
-21
lines changed

.github/workflows/generate-unity-project-files.yml

Lines changed: 17 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -7,32 +7,28 @@ on:
77
workflow_dispatch:
88

99
jobs:
10-
generate-solution:
10+
setup-unity:
1111
runs-on: ubuntu-latest
12+
1213
steps:
13-
- name: Checkout repository
14+
- name: Checkout Repository
1415
uses: actions/checkout@v4
1516

16-
- name: Cache Library Folder
17-
uses: actions/cache@v3
18-
with:
19-
path: Library
20-
key: Library-${{ runner.os }}-${{ github.sha }}
21-
restore-keys: |
22-
Library-${{ runner.os }}-
17+
- name: Download and Install Unity Hub
18+
run: |
19+
wget https://public-cdn.cloud.unity3d.com/hub/prod/UnityHub.AppImage -O UnityHub.AppImage
20+
chmod +x UnityHub.AppImage
21+
sudo mv UnityHub.AppImage /usr/local/bin/unity-hub
2322
24-
- name: Install Unity
25-
uses: game-ci/unity-activate@v2
26-
with:
27-
unityVersion: 2022.3.10f1 # Set your Unity version
28-
personalLicense: ${{ secrets.UNITY_LICENSE }}
23+
- name: Install Unity via Unity Hub CLI
24+
run: |
25+
unity-hub --headless install
26+
unity-hub -- --headless install --version 2021.3.16f1
2927
30-
- name: Generate Solution Files
28+
- name: Verify Unity Installation
3129
run: |
32-
unity-editor -batchmode -quit -nographics -logFile -executeMethod UnityEditor.SyncVS.SyncSolution
30+
/opt/unity/Editor/Unity --version
3331
34-
- name: Upload Solution Files
35-
uses: actions/upload-artifact@v4
36-
with:
37-
name: UnitySolution
38-
path: "*.sln"
32+
- name: Generate Solution and Project Files
33+
run: |
34+
/opt/unity/Editor/Unity -batchmode -logFile /dev/stdout -projectPath $GITHUB_WORKSPACE -quit

0 commit comments

Comments
 (0)