-
Notifications
You must be signed in to change notification settings - Fork 110
chore(gha): auto-create issue for release #450
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
✅ Heimdall Review Status
|
|
Looks okay to me but want @danyalprout to review |
danyalprout
left a comment
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.
logic looks great to me, would be fantastic if we could move the logic out to a script in the scripts folder/port it to bash too.
Thanks!
.github/workflows/create-release.yml
Outdated
| fi | ||
| - name: Create release tracking issue | ||
| uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1 |
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.
Verified this is 7.0.1 actions/github-script@60a0d83
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.
good catch. i should've checked this - this is a dangerous workflow with contents: write 🥵
All done @danyalprout :) |
.github/workflows/create-release.yml
Outdated
| env: | ||
| GH_TOKEN: ${{ github.token }} |
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.
I don't think you'll need to do this (based on the other scripts)
scripts/release/create-issue.sh
Outdated
| TAG_FILE="${RUNNER_TEMP:-}/release_tag" | ||
|
|
||
| if [[ ! -f "$TAG_FILE" ]]; then | ||
| echo "No tag file found at $TAG_FILE, skipping issue creation" | ||
| exit 0 | ||
| fi | ||
|
|
||
| TAG=$(cat "$TAG_FILE") | ||
| TAG="${TAG%$'\r'}" # Remove Windows line endings if present | ||
| TAG="${TAG%$'\n'}" # Remove newline if present | ||
|
|
||
| if [[ -z "$TAG" ]]; then | ||
| echo "Tag file is empty, skipping issue creation" | ||
| exit 0 | ||
| fi | ||
|
|
||
| echo "=== Create Release Tracking Issue ===" | ||
| echo "Tag: $TAG" |
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.
As we only want one issue per branch, we can just pass in the branch name similar to:
https://github.com/base/node-reth/blob/main/.github/workflows/create-release.yml#L41
https://github.com/base/node-reth/blob/main/scripts/release/create-tag.sh#L11
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.
@danyalprout. can you check please
- Add step to create release tracking issue with checklist - Auto-assign issue to workflow triggerer - Add issues:write permission Closes base#437
danyalprout
left a comment
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, thank you!
Summary
Changes
issues: writepermissionCreate release tracking issuestep usingactions/github-scriptCloses #437