Skip to main content

ghp

Compact GitHub activity summary with repository-scoped checkpoints.

Install

uv tool install ghp
# or
uvx ghp

Dev

uv sync
uv run ghp --version

Usage

ghp                                   # open issues + PRs snapshot
ghp upstream                          # use the GitHub repo from the upstream remote
ghp 1h                                # deltas since 1 hour ago
ghp upstream 1h                       # upstream deltas since 1 hour ago
ghp 2026-03-07T14:00:00Z              # deltas since timestamp
ghp --json                            # machine-readable output
ghp --me @clod                        # highlight mentions
ghp --repo owner/name                 # explicit repo
ghp inbox                             # unread notifications across all repositories
ghp inbox 1d                          # read and unread notifications since 1 day ago
ghp inbox --repo owner/name           # unread notifications for one repository
ghp owned                             # PRs awaiting workflow approval, unwatched repositories

Behavior

  • Cursor defaults to the saved checkpoint for the current GitHub repository when --since is omitted.
  • upstream selects the repository configured as the Git remote named upstream.
  • Checkpoints are stored under $XDG_STATE_HOME/ghp/checkpoints/. When XDG_STATE_HOME is unset or invalid, ghp uses ~/.local/state/ghp/checkpoints/.
  • Each repository has its own atomically replaced checkpoint file, so origin, upstream, and --repo queries do not advance each other's checkpoints.
  • Saved checkpoints include a one-second margin because GitHub's since filters are strict and timestamps have second precision. Boundary activity may appear again on the next run.
  • Tool installs and upgrades leave checkpoint state in place.
  • Repository-keyed .ghp-last-update-timestamp files are migrated to XDG state and removed after successful writes. Older plaintext files require an explicit window such as ghp 1h once because they do not identify a repository.
  • --since accepts relative shorthands (30m, 2h, 1d, 1w) and normalizes timestamps to canonical UTC.
  • Snapshot mode returns open issues and open PRs.
  • Delta mode returns issues, PRs, issue comments, PR review comments, and recent commits since the cutoff.
  • inbox lists the authenticated account's notifications, grouped by repository and newest first. It ignores the current checkout and reads and writes no checkpoint: GitHub's unread state is the cursor, and ghp never marks a notification as read.
  • inbox alone returns unread notifications. With a TIME it returns read and unread notifications updated since then, and marks the read ones read.
  • Each inbox line gives the issue or pull request number (or short commit hash), the subject type, the reason GitHub sent it (such as mention, review_requested, or author), the update time, and the title.
  • owned checks every account you own: your user account and each organization where you are an admin. It ignores the current checkout and keeps no checkpoint.
  • owned lists open pull requests whose GitHub Actions runs wait for maintainer approval, oldest first. GitHub holds runs from first-time and fork contributors this way, and sends no reminder while they wait. A pull request matches when its head commit has a run in the action_required state.
  • owned also lists non-fork, non-archived repositories you own but do not watch. GitHub sends no notifications for those, so their new issues and pull requests never reach ghp inbox.
  • API or auth failures exit non-zero instead of silently pretending there was no activity.
  • --json prints a machine-readable payload; on failure it emits a JSON object with an error field and exits non-zero.

Auth

Looks for tokens in this order:

  1. $GITHUB_PAT
  2. $GITHUB_TOKEN
  3. $GH_TOKEN
  4. gh auth token (gh CLI)

ghp owned always needs a token.

ghp inbox always needs a token, and GitHub's notifications API accepts only a gh CLI token or a classic personal access token with the notifications or repo scope. Fine-grained personal access tokens are rejected.

Test

uv run python -m unittest discover -s tests
scripts/test-install.sh

Metadata

Release files for ghp 0.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ghp 0.3.0
File Size Uploaded Provenance Actions
ghp-0.3.0.tar.gz 18.8 kB Without provenance Details for ghp-0.3.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for ghp 0.3.0
File Interpreter ABI Platform Actions
ghp-0.3.0-py3-none-any.whl Python 3 none any Details for ghp-0.3.0-py3-none-any.whl

Total release size: 30.6 kB

Release files / ghp-0.3.0.tar.gz

Download URL ghp-0.3.0.tar.gz
Size 18.8 kB
Tags Source
SHA-256 checksum
How to use checksums
0eebd75172ac14a705a7fdbed7e78b10af4e6ccff26334d91175b99217b7013a
BLAKE2b-256 checksum
How to use checksums
51a07a996e0989f27cb7382564b4c22af727e2a1034b2056d183cf013bb702fe
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.1 {"installer":{"name":"uv","version":"0.13.1","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / ghp-0.3.0-py3-none-any.whl

Download URL ghp-0.3.0-py3-none-any.whl
Size 11.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b8eaefff6debe1715d8ede075338b248e8ba4468330dc44e132a4398fc5b429f
BLAKE2b-256 checksum
How to use checksums
985b28db49832879ce9f95b0cee026fa288f81e1e2487109c141cdf94e9a73d9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.1 {"installer":{"name":"uv","version":"0.13.1","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for ghp 0.3.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page