gh-pr-comments

๐Ÿ› ๏ธ Development

Test locally with injected GraphQL fixtures, plus the release workflow.

๐Ÿงช Testing locally

You can bypass live GitHub calls by providing a GraphQL result via the GH_REVIEW_PR_JSON env variable. This can be either a path to a file or the JSON string itself.

Example with your own GraphQL response file:

GH_REVIEW_PR_JSON=/path/to/your_graphql.json \
  ./gh-pr-comments 123 -R owner/repo --json

The above prints the parsed comments as JSON. Use --list to print the UI list instead:

GH_REVIEW_PR_JSON=/path/to/your_graphql.json \
  ./gh-pr-comments 123 -R owner/repo --list

๐Ÿท๏ธ Versioning & releases

This project follows Semantic Versioning. Release workflow:

  1. Determine the next version (e.g. v0.1.1) based on the changes: fix = patch, new backward-compatible feature = minor, breaking change = major.

  2. Update CHANGELOG.md with a new section for the version (include the date):

    ## v0.1.1 - 2025-09-04
    - Add ...
    - Fix ...
  3. Commit and tag:

    git add CHANGELOG.md
    git commit -m "chore(release): v0.1.1"
    git tag v0.1.1
    git push && git push --tags

Users can check the installed version with:

gh pr-comments --version

On this page