Repository navigation
v0.5.0
Side-by-side output outside the viewer, lazygit integration, SQL parsed as code, and a diff that
holds up against huge or hostile input.
Added
- Headless output can be shown side by side:
--layout auto|stacked|side-by-sideand
--width N. Stacked stays the default and its output is unchanged.autouses two columns
when the terminal is wide enough and most lines fit without wrapping. Rows are paired by
omnidiff's own matching, so a moved line names where it went (→ N,← N). omnidiff git configureasks which layout plaingit diffshould use (auto, stacked or side
by side) and writes it intodiff.external.- lazygit support: as an
extDiffrenderer (git.diffRenderers), omnidiff tags each row with
the patch line it stands for (OSC 1717 v1), so lazygit can stage, navigate and open lines of
omnidiff's rendering. Without lazygit asking for it, the output is unchanged. - SQL is diffed as code, with the tree-sitter grammar nvim-treesitter uses, when a file parses
without errors. Other SQL files keep the line diff and the[plain text]label.
Changed
- Matching and highlighting follow the hand-made ground truth more closely: zero visible
mismatches on 1,475 of 1,760 fixtures (from 1,462). The matching runs 42% fewer instructions. - A file whose syntax tree has more than 300,000 nodes on a side is diffed as plain text, so a
huge generated file finishes in seconds instead of minutes and gigabytes. - A PDF with a page inserted or removed in the middle shows one added or removed page, not every
later page as changed. - Opening a large diff no longer stalls the viewer: syntax highlighting runs in the background
(a 13,000-line pair: 800 ms of UI time to under 2 ms).
Fixed
- As git's external diff, omnidiff never makes git abandon a multi-file diff. A file named like
a flag (-x.rs,--help) is diffed as a file, and a file omnidiff cannot diff prints one
omnidiff: could not diff PATHline instead of failing.git configureandjj configurenow
write--before the two paths. - git's external-diff form (
git --no-pager diff, lazygit) runs headless instead of opening the
full-screen viewer and blocking;--mode tuistill opens it.git difftoolis unchanged. - Files from an untrusted commit are handled safely: a path with
..can no longer write outside
the review workspace, control and bidi characters in file names are shown escaped, and a file
name starting with+is not read as an editor command. - Archives, PDFs, pictures, fonts and catalogs are decoded within fixed size and time budgets,
and a crash inside a decoder is reported as an error instead of ending the program. - Drawing PDF pages in parallel no longer marks an unchanged page as edited now and then.
Library
- With
default-features = falsethe library no longer pulls in clap, serde_json or libc: 185
crates instead of 200. tui::headless::runtakes aPair(Pair::read(before, after)) instead of two paths, plus
record_file(OSC 1717) andlayout;tui::json_output::runtakes aPairtoo.diff::content::archive::Zip::newtakes&[u8]. New:code::language::MAX_AST_NODESand
requires_clean_parse,diff::content::Budgetandcontained, and each decoder'sMAX_*
limits.