Read-only GitHub reviewer CLI: triage, re-review diffs, comment threads
Project description
twgh
Read-only GitHub reviewer CLI: triage what needs you, re-review only what changed since you last looked (force-push robust), and see which of your comments were addressed — across github.com and GitHub Enterprise.
twgh never writes to GitHub — no approvals, no comments, no merges. It is the read side of reviewing; for actions it hands you off to the browser.
Install
From PyPI (requires Python ≥ 3.12):
uv tool install twgh # or: pipx install twgh
From source:
make install # uv tool install -e . + bash completion
Prerequisites
- The GitHub CLI
gh, authenticated for each host you review on:gh auth login --hostname <host>. twgh borrows gh for auth, host routing, and transport; it never handles your token.
Use-cases
1. Triage — which PRs need me right now?
twgh status
Cross-repo rollup of every open PR you are review-requested on, commented on,
or have reviewed. Per PR: author, your review state against the current head
(needs_review / needs_re_review / up_to_date), and open-thread count.
★ marks PRs that moved since your last status run — new head or new comments,
tracked via a local snapshot (the first run deliberately flags nothing).
--json for scripting.
2. Re-review — what changed since I last looked?
twgh diff <ref>
The author pushed again; you don't want to re-read the whole PR. diff anchors
on your last submitted review (else your last inline comment) and shows
anchor→HEAD, restricted to the files you commented on (--all for the whole
PR). The anchor is a commit OID, so the diff survives force-pushes and rebases.
With no prior review there is nothing to re-diff — it points you at twgh open
instead.
3. Catch up — what was said while I was away?
twgh comments <ref>
All PR discussion in one chronological stream: top-level comments plus inline
review comments. Comments in resolved threads are hidden (--all to include),
--by <user> / --mine to filter.
4. Follow up — were my comments addressed?
twgh threads [<ref>]
Each open conversation gets a verdict from what GitHub knows:
✓ resolved— the thread is marked resolved~ changed— the anchored code moved since the comment (inspect withtwgh diff)· untouched— the point still stands as written
Omit <ref> for a global inbox of open threads across all PRs that involve
you. --mine / --by <user> to filter, --all to include resolved.
5. Act — everything twgh stays out of
twgh open <ref>
Opens the PR in the browser for the write actions: approving, replying, resolving, merging.
PR references
<ref> is a PR URL, host/owner/repo#N, owner/repo#N, owner/repo/N, or a
bare number inside a repo checkout. status prints URLs — paste them straight
back.
Host selection
-H/--gh-host overrides $GH_HOST, which defaults to github.com. Works as a
global option (twgh -H bmw.ghe.com status) or per command.
Development
make test # pytest + coverage (floor 85%)
make static-analysis # ruff lint-fix, format, ty
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file twgh-0.1.2.tar.gz.
File metadata
- Download URL: twgh-0.1.2.tar.gz
- Upload date:
- Size: 15.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
972d3099905135e92e8284212c6c93dff8cb6e4caf245ee63e1241ac2f1d2323
|
|
| MD5 |
75345bd8dfed9d7453ba14c79307db9b
|
|
| BLAKE2b-256 |
e55c7f12797b1e306679ca0e4507a7786b4259232439417243417c8334a4108d
|
File details
Details for the file twgh-0.1.2-py3-none-any.whl.
File metadata
- Download URL: twgh-0.1.2-py3-none-any.whl
- Upload date:
- Size: 16.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
78bd27d8785c8d58135b0708d5e4b70cb81d1a70b533e1da71f690e78a4992bd
|
|
| MD5 |
223a16b01b6c1a21f60b1bb99a8b702f
|
|
| BLAKE2b-256 |
7f03d022063fc82aadc5cb855adfb0c3828a18949ad3a95aae3f10dac5b6059c
|