Skip to content

Commit

Permalink
Use a repository variable to control CI artifact upload for PRs
Browse files Browse the repository at this point in the history
  • Loading branch information
nickbeth committed Mar 1, 2024
1 parent d5d6e67 commit a503ca1
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/pr_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,17 +55,20 @@ jobs:
run: ./gradlew --no-daemon --stacktrace --build-cache --parallel --configure-on-demand assembleDevRelease assembleDevReldebug

- name: Rename APKs
if: ${{ vars.UPLOAD_PR_ARTIFACTS == 'true' }}
run: |
mv app/build/outputs/apk/dev/release/app-dev-release.apk strato-pr${{ github.event.number }}-release.apk
mv app/build/outputs/apk/dev/reldebug/app-dev-reldebug.apk strato-pr${{ github.event.number }}-reldebug.apk
- name: Upload Release APK
if: ${{ vars.UPLOAD_PR_ARTIFACTS == 'true' }}
uses: actions/upload-artifact@v4
with:
name: strato-pr${{ github.event.number }}-release.apk
path: strato-pr${{ github.event.number }}-release.apk

- name: Upload Debug APK
if: ${{ vars.UPLOAD_PR_ARTIFACTS == 'true' }}
uses: actions/upload-artifact@v4
with:
name: strato-pr${{ github.event.number }}-reldebug.apk
Expand Down

0 comments on commit a503ca1

Please sign in to comment.