Skip to content

v2.23.1

Choose a tag to compare

@SanderMuller SanderMuller released this 31 Jul 16:08
· 5 commits to main since this release
Immutable release. Only release title and notes can be modified.

Fixes four ways the dangling-symbols.sh companion introduced in 2.23.0 could report a clean sweep on a merge that had a real dangling reference. If you are on 2.23.0, upgrade — a check that silently passes is worse than no check, because resolve-conflicts tells you to trust its result.

Fixed

  • The sweep no longer depends on the reader's git configuration. It parsed git's human-facing output while assuming defaults, but that output is shaped by settings the script neither set nor inspected. Four of them made it print No dangling references and exit 0 against a repository that provably had one:
    • grep.patternType=extended — the word-boundary \b is a GNU regex extension that matches nothing under ERE, so every symbol lookup came back empty. The lookup now uses git grep -w -F: -w is a git option rather than a regex feature, and -F treats the symbol as the literal identifier it is. Verified against the basic, extended, fixed and perl pattern types.
    • color.diff=always / color.ui=always — ANSI escapes prefixed every line, so the ^- and ^+ matching that finds removed declarations stopped working. Closed with --no-color.
    • diff.external, and the GIT_EXTERNAL_DIFF environment variable — an external driver replaced the diff output entirely. Closed with --no-ext-diff.
    • A textconv driver bound through .gitattributes — content was rewritten before diffing, so a symbol could be transformed out of the diff. Closed with --no-textconv.
  • A failed sweep now fails loudly instead of reporting success. die was being called from inside a pipeline subshell, where exit terminates only that subshell; the script printed its error and then fell through to No dangling references with exit 0. Both diffs are now collected in the main shell, so a git failure exits 2.
  • resolve-conflicts no longer falls through to the commit phase on a fast-forward. The fast-forward outcome noted that nothing needed verifying but omitted the explicit stop its sibling outcome carries, leaving a path that reached the commit phase with an empty tree.

Full Changelog: 2.23.0...2.23.1