Skip to content

Commit

Permalink
Use elevated permissions token
Browse files Browse the repository at this point in the history
  • Loading branch information
ayoy committed Mar 13, 2024
1 parent e7547fa commit 36fc28d
Showing 1 changed file with 5 additions and 12 deletions.
17 changes: 5 additions & 12 deletions .github/workflows/hotfix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,26 +34,19 @@ jobs:
- name: Prepare fastlane
run: bundle install

- name: Find last release version
id: find_last_release
env:
GH_TOKEN: ${{ github.token }}
run: |
last_release="$(gh api repos/${{ github.repository }}/releases/latest | jq -r .tag_name)"
echo "last_release=$last_release" >> $GITHUB_OUTPUT
- name: Make release branch
id: make_release_branch
env:
APPLE_API_KEY_BASE64: ${{ secrets.APPLE_API_KEY_BASE64 }}
APPLE_API_KEY_ID: ${{ secrets.APPLE_API_KEY_ID }}
APPLE_API_KEY_ISSUER: ${{ secrets.APPLE_API_KEY_ISSUER }}
GH_TOKEN: ${{ github.token }}
LAST_RELEASE: ${{ steps.find_last_release.outputs.last_release }}
GH_TOKEN: ${{ secrets.GHA_ELEVATED_PERMISSIONS_TOKEN }}
run: |
git config --global user.name "Dax the Duck"
git config --global user.email "[email protected]"
bundle exec fastlane prepare_hotfix version:"$LAST_RELEASE"
last_release="$(gh api repos/${{ github.repository }}/releases/latest | jq -r .tag_name)"
echo "last_release=$last_release" >> $GITHUB_OUTPUT
bundle exec fastlane prepare_hotfix version:"$last_release"
- name: Create release task
id: create_release_task
Expand Down Expand Up @@ -91,7 +84,7 @@ jobs:
uses: ./.github/actions/asana-add-comment
env:
BRANCH: ${{ steps.make_release_branch.outputs.release_branch_name }}
RELEASE_TAG: ${{ steps.find_last_release.outputs.last_release }}
RELEASE_TAG: ${{ steps.make_release_branch.outputs.last_release }}
WORKFLOW_URL: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}
with:
access-token: ${{ secrets.ASANA_ACCESS_TOKEN }}
Expand Down

0 comments on commit 36fc28d

Please sign in to comment.