mirror of
https://github.com/fastapi/fastapi.git
synced 2026-09-12 21:38:39 -04:00
👷 Use GitHub CLI for Git authentication (#16166)
This commit is contained in:
1 parent
22c2d0e53b
commit
da2f094327
1 file changed
+2
-2
@@ -72,11 +72,11 @@ jobs:
|
||||
- name: Commit and push changes
|
||||
if: env.CAN_PUSH == 'true' && steps.changes.outputs.changed == 'true'
|
||||
env:
|
||||
PR_PUSH_TOKEN: ${{ steps.pr-push.outputs.token }}
|
||||
GH_TOKEN: ${{ steps.pr-push.outputs.token }}
|
||||
run: |
|
||||
git config user.name "pr-push[bot]"
|
||||
git config user.email "pr-push[bot]@users.noreply.github.com"
|
||||
git remote set-url origin "https://x-access-token:${PR_PUSH_TOKEN}@github.com/${GITHUB_REPOSITORY}.git"
|
||||
gh auth setup-git
|
||||
git add -A
|
||||
if git diff --staged --quiet; then
|
||||
echo "No changes to commit"
|
||||
|
||||
Reference in new issue
Block a user