Prompt file imported from zbzq8ztx22-star/windsurf-demo (
.windsurf/workflows/github/address-pr-comments.md). Copyright stays with the author.
-
Check out the PR branch:
gh pr checkout [id] -
Get comments on PR
gh api --paginate repos/[owner]/[repo]/pulls/[id]/comments | jq '.[] | {user: .user.login, body, path, line, original_line, created_at, in_reply_to_id, pull_request_review_id, commit_id}'
-
For EACH comment, do the following. Remember to address one comment at a time. 3a. Print out the following: "(index). From [user] on [file]:[lines] — [body]" 3b. Analyze the file and the line range. 3c. If you don't understand the comment, do not make a change. Just ask me for clarification, or to implement it myself. 3d. If you think you can make the change, make the change BEFORE moving onto the next comment.
-
After all comments are processed, summarize what you did, and which comments need the USER's attention.