Repository navigation
ghusage 0.1.2
Highlights
Open a commit and read its diff
- New command:
ghusage commit <OWNER/REPO@SHA | commit URL> [--patch]shows one commit: its author and committer, parents, full message and changed files with lines added and removed. Add--patchto print the diff. It also accepts.../pull/NUMBER/commits/SHAURLs and--format json. - In the terminal UI, the PR Detail screen now lists the pull request's commits, oldest first. Commits removed by a force push stay in the list, dimmed and marked
removed. PressTabto move the focus to the list,/to search it,Enterto open a commit andoto open it on GitHub. - The new Commit screen shows the commit's details, the changed files and a colored diff. The diff keeps its
+,-and@@prefixes, so it is readable without color. Use]and[to jump between files. The commit loads in the background, so the UI keeps responding while it loads. - Fetched commits are cached, so a commit you have opened once can be shown again with
--offline. The cache includes the commit message, file names and the diff. See Privacy.
npm installs recover from a missing native package
ghusage on npm ships its binary in a per-platform optional dependency (@ghusage/ghusage-<os>-<arch>). Sometimes the optional dependency doesn't get installed. This happens, for example, when a registry mirror or a supply-chain proxy has not picked up the new version yet. Before, the command then failed with "Missing optional native package".
- The launcher now fetches the missing native package on first run. It uses your own npm configuration (registry, proxy and auth), so the package comes from wherever
npmitself would fetch it, and it is stored in a cache directory. - Set
GHUSAGE_NO_AUTO_INSTALL=1to turn this off. SetGHUSAGE_CACHE_DIRto choose where the package is stored. - The release process now waits until every platform package is available on the registry before it publishes the main package.
- See Getting started → Missing native package for updating and for fixing an install by hand.
Japanese documentation
The documentation site has moved to https://ghusage.under18.dev and now has a full Japanese translation at /ja/.
Fixes
- Reports over a period loaded slowly from a large cache. For each pull request active in the period, SQLite scanned all of the account's cached events. The query now uses the pull request index. In the debug benchmark, cached 7- and 30-day loads went from over two minutes to seconds.
- TUI: the PR timing row "Review → author reply" is renamed "Review → next author activity". The value counts any next activity by the author, not only replies.
Documentation
- Known limitations now cover:
- narrow terminals
- termination by signal (the terminal UI does not restore the terminal after
SIGTERM) - the permissions of an existing data directory, which are left unchanged
- The Platforms section now says what has been checked by hand on Windows and states that Linux is covered by CI only.
- The rate-limit section now states that rate-limit handling is tested with simulated GitHub responses, not by exhausting a real account's limits.
Install / update
npm install -g ghusage@0.1.2Full changelog: v0.1.1...v0.1.2