diff options
| author | Gabriel Schneider <[email protected]> | 2026-09-30 18:18:47 -0300 |
|---|---|---|
| committer | Gabriel Schneider <[email protected]> | 2026-10-01 00:12:17 -0300 |
| commit | 3f6c259711252b57646f447de85e44c5239ebd0d (patch) | |
| tree | e75a1239f69a7b9ea0b3a7784315a0d71e8a15d2 /src/CHANGELOG.md | |
| parent | 97464fad2d4f6a58608cf92729fd8395db89c7b4 (diff) | |
| download | pardes-3f6c259711252b57646f447de85e44c5239ebd0d.tar.gz pardes-3f6c259711252b57646f447de85e44c5239ebd0d.zip | |
A diff look names a file as the repository does: git's side prefix dropped by git's rules, a plain diff's names as written
In a git section (one with a `diff --git` line) the one-letter side prefix
git writes, `a/`/`b/` or with diff.mnemonicPrefix `c/`, `i/`, `w/`, `o/`,
is dropped from its paths only when both paths of that line carry one,
different ones: `--no-prefix` writes none, so its `a/x a/x` is a real
directory `a` and is kept. A plain `diff -u` never strips: its names are
used as written, past the timestamp. `/dev/null` stays itself.
The walker does this once (diff.Walk.side, diff.gitHeader), so the path a
look resolves, and the one a miss says, are the repository's name:
`Look: src/x.zig: no such file here`, `Look: lib/old.zig: deleted by this
diff`. The look no longer tries a stripped name beside the written one.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Diffstat (limited to 'src/CHANGELOG.md')
| -rw-r--r-- | src/CHANGELOG.md | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/CHANGELOG.md b/src/CHANGELOG.md index 881df10c..69b737ca 100644 --- a/src/CHANGELOG.md +++ b/src/CHANGELOG.md @@ -1,5 +1,13 @@ # Changelog +## Unreleased + +- A look on a diff names a file as the repository does: git's `a/`/`b/` + (or mnemonic `c/`, `i/`, `w/`) is dropped only where both paths of the + `diff --git` line carry one, a `--no-prefix` diff's real `a/` is kept, a + plain `diff -u`'s names are as written, and a missing file is said by + that name (`Look: src/x.zig: no such file here`). + ## 0.0.10 - A 9P write never moves dot's end: scrolling written text into view moves |
