From e737f3d560de2b8172e6dd83901bc1359283303c Mon Sep 17 00:00:00 2001 From: dev Date: Sat, 14 Nov 2026 00:21:57 +0000 Subject: README: the two questions the hook asks git, and how they are tested without git --- README | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'README') diff --git a/README b/README index f795411..b2bb0a0 100644 --- a/README +++ b/README @@ -257,6 +257,13 @@ runs anywhere a compiler does, and it tests the real binary rather than a model of it: argument parsing, exit codes, messages, and the editing commands writing files. +Two facts do not come out of the line git passes, and the hook asks git for +them: which branch `HEAD` is, and whether `old` is an ancestor of `new`. Those +are covered with a stand-in named `git` in `PATH`, which answers to order and +lets the asking be tested without git - including the case where git is not +there at all, where the hook has to fail toward denying rather than toward +guessing. + `make clean && make sanitizer` runs both suites under AddressSanitizer and UBSan. Everything frees what it reads, which matters only because it keeps that run empty. -- cgit v1.2.3