Skip to content

Commit

Permalink
[Workflow] Enforce TODO_UPNEXT comments to have an associated usern…
Browse files Browse the repository at this point in the history
…ame (#896)

Improve process for `TODO_UPNEXT`

Goal is to block PRs on this: `TODO_UPNEXT: <do something>`
Allow PRs on this: `TODO_UPNEXT(@Olshansk): <do something>`

Verification:

![Screenshot 2024-10-28 at 5 18 20 PM](https://github.com/user-attachments/assets/caa1e209-1b20-4cf0-b1ab-5dc217f4319d)



---

Co-authored-by: Dima K. <[email protected]>
  • Loading branch information
Olshansk and okdas authored Nov 5, 2024
1 parent bae452a commit 12342f0
Showing 1 changed file with 19 additions and 1 deletion.
20 changes: 19 additions & 1 deletion .github/workflows/reviewdog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,25 @@ jobs:
reporter: github-pr-review
level: error
fail_on_error: true
pattern: TODO_IN_THIS_
pattern: TODO_IN_THIS_|TODO_THIS_

# Makes sure that comments like TODO_UPNEXT prevent merging if there is
# no associated username right after.
# Example failure: TODO_UPNEXT: <do something>
# Example non-failure: TODO_UPNEXT(@olshansk): <do something>
# See https://github.com/pokt-network/action-fail-on-found
check_todo_upnext:
name: Check TODO_UPNEXT
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pokt-network/action-fail-on-found@v1
with:
github_token: ${{ secrets.github_token }}
reporter: github-pr-review
level: error
fail_on_error: true
pattern: "TODO_UPNEXT:"

# Prevent the use of `sed` in helper scripts. This ensures compatibility across
# Darwin and Linux systems.
Expand Down

0 comments on commit 12342f0

Please sign in to comment.