Skip to content

Commit

Permalink
🔐 Use repo secret GH_PAT
Browse files Browse the repository at this point in the history
  • Loading branch information
shnizzedy committed Nov 7, 2024
1 parent d8adc6e commit ca7892f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/match_target_repository.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
GITHUB_BASE_LOGIN: ${{ github.event.pull_request.base.repo.owner.login }}
GITHUB_BASE_REPO_NAME: ${{ github.event.pull_request.base.repo.name }}
GITHUB_REPO: ${{ github.event.pull_request.head.repo.full_name }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_PAT: ${{ secrets.GH_PAT }}
HEAD_REF: ${{ github.head_ref }}
run: |
TARGET_REPO_URL="https://github.com/${GITHUB_BASE_LOGIN}/${GITHUB_BASE_REPO_NAME}"
Expand All @@ -34,7 +34,7 @@ jobs:
# Commit and push changes
git config --local user.email "[email protected]"
git config --local user.name "🐈 Theodore"
git remote set-url --push origin "https://${GITHUB_TOKEN}@github.com/${GITHUB_REPO}"
git remote set-url --push origin "https://${GH_PAT}@github.com/${GITHUB_REPO}"
git add pyproject.toml
git commit -m ":twisted_rightwards_arrows: Update repository URL to PR target."
git push origin HEAD:"${HEAD_REF}"

0 comments on commit ca7892f

Please sign in to comment.