-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: unity cloud build cache improvements (#1640)
* don't delete the targets on healty builds * Testing cache options * Updateing default values * Updated the defaults * Testing workspace caching * Testing workspace caching * Testing cache and adding logs * Use cache from existing target * Fixed compilation error * Updated Build Weekly Release to not use cache and make clean build * Removed debug options * Setting default values * Fixes spacing issue * Fixing defaults values * Fixing compilation error
- Loading branch information
Showing
4 changed files
with
98 additions
and
18 deletions.
There are no files selected for viewing
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
name: Handle PR Closure | ||
|
||
on: | ||
pull_request: | ||
types: | ||
- closed | ||
|
||
jobs: | ||
handle-pr-closure: | ||
name: Handle PR Closure | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v2 | ||
|
||
- name: Check if PR is merged | ||
id: check_if_merged | ||
run: echo "PR_MERGED=${{ github.event.pull_request.merged }}" >> $GITHUB_ENV | ||
|
||
- name: Delete Unity Cloud target if merged | ||
if: env.PR_MERGED == 'true' | ||
env: | ||
API_KEY: ${{ secrets.UNITY_CLOUD_API_KEY }} | ||
ORG_ID: ${{ secrets.UNITY_CLOUD_ORG_ID }} | ||
PROJECT_ID: ${{ secrets.UNITY_CLOUD_PROJECT_ID }} | ||
run: python -u scripts/cloudbuild/build.py --delete | ||
|
||
- name: Delete Unity Cloud target if closed without merging | ||
if: env.PR_MERGED != 'true' | ||
env: | ||
API_KEY: ${{ secrets.UNITY_CLOUD_API_KEY }} | ||
ORG_ID: ${{ secrets.UNITY_CLOUD_ORG_ID }} | ||
PROJECT_ID: ${{ secrets.UNITY_CLOUD_PROJECT_ID }} | ||
run: python -u scripts/cloudbuild/build.py --delete |
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