-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Remove pull request template #18104
base: main
Are you sure you want to change the base?
Remove pull request template #18104
Changes from 3 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
### Pull Request reminders for autofix | ||
|
||
(internal access required) | ||
|
||
- [ ] Autofixes generated based on these changes are valid, only needed if this PR makes significant changes to `.ql`, `.qll`, or `.qhelp` files. See [the documentation](https://github.com/github/codeql-team/blob/main/docs/best-practices/validating-autofix-for-query-changes.md). | ||
- [ ] Changes to autofix are validated [at scale](https://github.com/github/codeql-dca/blob/main/doc/autofix.md). | ||
- [ ] Adding a new query? Consider also [adding the query to autofix](https://github.com/github/codeml-autofix/blob/main/docs/updating-query-support.md#adding-a-new-query-to-the-query-suite). |
This file was deleted.
Original file line number | Diff line number | Diff line change | ||
---|---|---|---|---|
@@ -1,4 +1,4 @@ | ||||
name: Check change note | ||||
name: Check change note and reminders | ||||
|
||||
permissions: | ||||
pull-requests: read | ||||
|
@@ -9,17 +9,39 @@ on: | |||
paths: | ||||
- "*/ql/src/**/*.ql" | ||||
- "*/ql/src/**/*.qll" | ||||
- "*/ql/src/**/*.qhelp" | ||||
- "*/ql/lib/**/*.ql" | ||||
- "*/ql/lib/**/*.qll" | ||||
- "*/ql/lib/**/*.qhelp" | ||||
- "*/ql/lib/**/*.yml" | ||||
- "shared/**/*.ql" | ||||
- "shared/**/*.qll" | ||||
- "shared/**/*.qhelp" | ||||
- "!**/experimental/**" | ||||
- "!ql/**" | ||||
- "!rust/**" | ||||
- ".github/workflows/check-change-note.yml" | ||||
|
||||
jobs: | ||||
add-pr-reminders: | ||||
env: | ||||
REPO: ${{ github.repository }} | ||||
PULL_REQUEST_NUMBER: ${{ github.event.number }} | ||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/store-information-in-variables#default-environment-variables
So we can skip declaring our own variable here. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I was just following along with Is there a reason to change it in this job, but not the other? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I have pushed a commit that makes use of GITHUB_REPOSITORY everywhere in this file. |
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||||
runs-on: ubuntu-latest | ||||
steps: | ||||
|
||||
- name: Check if the 'reminders' comment exists | ||||
run: | | ||||
reminder_comment=$(gh api "repos/$REPO/issues/$PULL_REQUEST_NUMBER/comments" --jq '.[] | select(.body | test("### Pull Request reminders for autofix"))') | ||||
|
||||
esbena marked this conversation as resolved.
Show resolved
Hide resolved
|
||||
if [ -z "$reminder_comment" ]; then | ||||
echo "The reminder comment does not exist. Adding it." | ||||
comment_body="$(cat .github/pr-comment-reminder.md)" | ||||
|
||||
gh api "repos/$REPO/issues/$PULL_REQUEST_NUMBER/comments" -f body="$comment_body" | ||||
fi | ||||
esbena marked this conversation as resolved.
Show resolved
Hide resolved
|
||||
|
||||
check-change-note: | ||||
env: | ||||
REPO: ${{ github.repository }} | ||||
|
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.
Can we please restrict this comment to only occur when there are changes in
*/ql/src/**
? Otherwise I think we'll add too much noise.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.
Thinking back: didn't we actually decide against this commenting approach in the first place in #17017 (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.
Yeah, upon further thought, I don't think we should spam PRs with a comment like this.