• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

umputun / revdiff / 24744742665
90%

Build:
DEFAULT BRANCH: master
Ran 21 Apr 2026 08:28PM UTC
Jobs 1
Files 58
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

21 Apr 2026 08:27PM UTC coverage: 89.188% (+0.04%) from 89.152%
24744742665

push

github

web-flow
feat: add compact diff mode with --compact flag and C keybinding (#135)

* add plan: compact-diff-mode

* feat: add contextLines parameter to Renderer.FileDiff

Extends both diff.Renderer and ui.Renderer interfaces with a contextLines
int parameter on FileDiff. All wrappers (Fallback, Exclude, Include) pass
it through to the inner renderer; context-only sources (FileReader,
DirectoryReader, StdinReader) ignore it. VCS renderers accept it but
continue to use the hardcoded full-file context arg — arg construction
moves to Task 2. UI callsites pass 0 for now, preserving behavior.

Both moq mocks regenerated.

* feat: use contextLines in Git/Hg/Jj FileDiff via per-renderer helpers

Replace the hardcoded full-file arg in the three VCS renderers with small
helpers (gitContextArg, hgContextArg, jjContextArg) that map the caller's
contextLines value to the right -U / --context= argument. Zero / negative /
>= 1000000 keeps the existing full-file behavior via the fullFileContext
(and jjFullContext) sentinel; any positive value below the sentinel becomes
a small-context request.

Table-driven tests cover the helpers, and end-to-end tests build a real
20-line file in a tiny repo for each VCS, invoke FileDiff with
contextLines=2, and assert exactly 1 added / 1 removed / 4 context lines,
confirming the arg reaches the underlying VCS. A paired contextLines=0
assertion locks in the full-file default.

* feat: add Compact and CompactContext config fields

Adds --compact boolean flag and --compact-context int flag (default 5)
to the options struct. These will drive the new compact diff mode that
passes a smaller -U value to the underlying VCS.

Both flags follow the --collapsed precedent with matching long/ini-name/env
tags. Tests cover CLI flag, env var, and config file parsing variants plus
default values.

* feat: add ActionToggleCompact keymap action with default binding C

* feat: wire compact diff mode into UI model

Add compact/compactContext fields to modeState... (continued)

113 of 118 new or added lines in 14 files covered. (95.76%)

7696 of 8629 relevant lines covered (89.19%)

471.71 hits per line

Uncovered Changes

Lines Coverage ∆ File
3
9.84
3.8% app/main.go
2
80.0
0.44% app/diff/jj.go
Jobs
ID Job ID Ran Files Coverage
1 24744742665.1 21 Apr 2026 08:28PM UTC 58
89.19
GitHub Action Run
Source Files on build 24744742665
  • Tree
  • List 58
  • Changed 14
  • Source Changed 0
  • Coverage Changed 14
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • 389b7510 on github
  • Prev Build on refs/tags/v0.21.0 (#24684257784)
  • Next Build on master (#24745754706)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc