born() takes a HEAD as new only when it names a branch under refs/heads/ that no ref holds yet; a broken ref, a tag target or any other state is an error in Git's words. The branch name keeps every byte. Round 3 is fixed; round 4 waits until 0.1.3 ships. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
4 lines
759 B
Markdown
4 lines
759 B
Markdown
FAIL
|
|
|
|
- apps/ely-tree/src/git.rs:80 — The HEAD check also treats corrupt references as an empty repository, swallowing real Git errors (rule 2). Reproduction: create a repository with one commit, then replace its current `.git/refs/heads/<branch>` file with `not-an-object-id\n`. On both native Windows and WSL Linux, `rev-parse --verify -q HEAD` exits 1 without output; `born()` returns `Ok(false)`, and both `recover::reflog()` and `structure::lfs()` return `Ok([])`, although `git reflog show HEAD --` reports `fatal: bad revision 'HEAD'`. Recognize only a valid unborn symbolic HEAD as empty; propagate corrupt/unreadable-reference errors and add a regression for this case. Evidence: `.work/G-03-r1/windows-probe.log`, `.work/G-03-r1/linux-probe.log`.
|