Expand description
Best-effort git plumbing for recording the commit that closes an issue.
A commit cannot contain its own hash: its hash is derived from its tree
and its message, so a ticket can never store the hash of the very commit
that writes it. tix therefore records either the work commit that was
already made (auto-captured from HEAD when a ticket is closed) or, after
the closure commit lands, resolves the commit that last touched the issue
file. Both are best-effort: a missing git, a non-repository directory, or
an uncommitted file yields None and never an error.
Functionsยง
- current_
head - The current
HEADcommit hash, best-effort. - last_
commit_ for_ path - The most recent commit that touched
path, best-effort. - resolve_
closing_ commit - The hash to record for automatic resolution (
--commit auto): the commit that last touched the issue file, falling back toHEAD.