Skip to content

Commit

Permalink
WIP 7
Browse files Browse the repository at this point in the history
  • Loading branch information
12joan committed Apr 5, 2024
1 parent 5163178 commit 669d7af
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 24 deletions.
50 changes: 27 additions & 23 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Development build
name: Build

on:
workflow_call:
Expand All @@ -13,37 +13,41 @@ on:

jobs:
build:
name: Build ${{ inputs.targetPlatform }}
if: ${{ github.ref == 'refs/heads/dx/package-builds' }}
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- name: Install vendor
run: |
curl ${{ secrets.VENDOR_URL }} -o vendor.zip
yarn vendor:unpack
rm vendor.zip
# - uses: actions/cache@v3
# - name: Install vendor
# run: |
# curl ${{ secrets.VENDOR_URL }} -o vendor.zip
# yarn vendor:unpack
# rm vendor.zip

# # - uses: actions/cache@v3
# # with:
# # path: Library
# # key: Library-${{ hashFiles('Assets/**', 'Packages/**', 'ProjectSettings/**') }}
# # restore-keys: |
# # Library-

# - uses: game-ci/unity-builder@v4
# env:
# UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
# UNITY_EMAIL: ${{ secrets.UNITY_EMAIL }}
# UNITY_PASSWORD: ${{ secrets.UNITY_PASSWORD }}
# with:
# path: Library
# key: Library-${{ hashFiles('Assets/**', 'Packages/**', 'ProjectSettings/**') }}
# restore-keys: |
# Library-

- uses: game-ci/unity-builder@v4
env:
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
UNITY_EMAIL: ${{ secrets.UNITY_EMAIL }}
UNITY_PASSWORD: ${{ secrets.UNITY_PASSWORD }}
with:
targetPlatform: ${{ inputs.targetPlatform }}
customParameters: ${{ inputs.customParameters }}
# targetPlatform: ${{ inputs.targetPlatform }}
# customParameters: ${{ inputs.customParameters }}

- uses: actions/upload-artifact@v3
with:
name: Build-${{ inputs.targetPlatform }}
path: build/${{ inputs.targetPlatform }}
# path: build/${{ inputs.targetPlatform }}
path: Assets/src

- run: echo "artifact_name=Build-"${{ inputs.targetPlatform }} >> $GITHUB_OUTPUT
- run: |
echo "artifact_name=Build-${{ inputs.targetPlatform }}" >> $GITHUB_OUTPUT
echo "run_id=$GITHUB_RUN_ID" >> $GITHUB_OUTPUT
5 changes: 4 additions & 1 deletion .github/workflows/windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,15 @@ jobs:
secrets: inherit

package_windows:
name: Package Windows build
needs: build
runs-on: windows-latest

steps:
- uses: actions/download-artifact@v4
with:
name: ${{ needs.build.outputs.artifact_name }}
run-id: ${{ needs.build.outputs.run_id }}
github-token: ${{ secrets.GITHUB_TOKEN }}

- run: ls -R
- run: dir

0 comments on commit 669d7af

Please sign in to comment.