-
Notifications
You must be signed in to change notification settings - Fork 13.6k
workflows/release-documentation: Submit a pull request with changes #108247
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
This is instead of pushing directly. Creating a pull request is slightly more work for the release manager, but it is more secure as we no longer need a secret with write access to the www-releases repo.
@llvm/pr-subscribers-github-workflow Author: Tom Stellard (tstellar) ChangesThis is instead of pushing directly. Creating a pull request is slightly more work for the release manager, but it is more secure as we no longer need a secret with write access to the www-releases repo. Full diff: https://github.com/llvm/llvm-project/pull/108247.diff 1 Files Affected:
diff --git a/.github/workflows/release-documentation.yml b/.github/workflows/release-documentation.yml
index 70e5f08b6f72e2..922c5093f13579 100644
--- a/.github/workflows/release-documentation.yml
+++ b/.github/workflows/release-documentation.yml
@@ -72,17 +72,20 @@ jobs:
ref: main
fetch-depth: 0
path: www-releases
+ persist-credentials: false
- name: Upload Release Notes
if: env.upload
env:
- WWW_RELEASES_TOKEN: ${{ secrets.WWW_RELEASES_TOKEN }}
+ GH_TOKEN: ${{ secrets.WWW_RELEASES_TOKEN }}
run: |
- mkdir -p ../www-releases/${{ inputs.release-version }}
- mv ./docs-build/html-export/* ../www-releases/${{ inputs.release-version }}
- cd ../www-releases
+ mkdir -p www-releases/${{ inputs.release-version }}
+ mv ./docs-build/html-export/* www-releases/${{ inputs.release-version }}
+ cd www-releases
+ git checkout -b ${{ inputs.release-version }}
git add ${{ inputs.release-version }}
git config user.email "[email protected]"
git config user.name "llvmbot"
git commit -a -m "Add ${{ inputs.release-version }} documentation"
- git push "https://[email protected]/${{ github.repository_owner }}/www-releases" main:main
+ git push --force "https://[email protected]/llvmbot/www-releases.git" HEAD:refs/heads/${{ inputs.release-version }}
+ gh pr create -f -B main -H ${{ inputs.release-version }} -R llvmbot/www-releases
|
Ping. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems reasonable enough to me.
@tru should probably weigh in on this one though given I'm not that familiar with the release process.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
/cherry-pick 9cd289f |
…lvm#108247) This is instead of pushing directly. Creating a pull request is slightly more work for the release manager, but it is more secure as we no longer need a secret with write access to the www-releases repo. (cherry picked from commit 9cd289f)
/pull-request #110665 |
…lvm#108247) This is instead of pushing directly. Creating a pull request is slightly more work for the release manager, but it is more secure as we no longer need a secret with write access to the www-releases repo.
…lvm#108247) This is instead of pushing directly. Creating a pull request is slightly more work for the release manager, but it is more secure as we no longer need a secret with write access to the www-releases repo. (cherry picked from commit 9cd289f)
…lvm#108247) This is instead of pushing directly. Creating a pull request is slightly more work for the release manager, but it is more secure as we no longer need a secret with write access to the www-releases repo. (cherry picked from commit 9cd289f)
This is instead of pushing directly. Creating a pull request is slightly more work for the release manager, but it is more secure as we no longer need a secret with write access to the www-releases repo.