Repository navigation
feat: add configurable file and Git version sources - #182
Merged
Merged
Conversation
Resolve versions from local Git tags or VERSION, with source-specific increment and set behavior. Add specs, requirements, and regression coverage for issue #181.
Keep Git tags as the version source while applying proposed versions to configured hook targets. Update the spec and exercise all increment variants.
justinmchase
commented
Oct 28, 2026
justinmchase
commented
Oct 28, 2026
justinmchase
commented
Oct 28, 2026
justinmchase
commented
Oct 28, 2026
justinmchase
commented
Oct 28, 2026
getVersionFromGitTags had grown an unreachable-remote-tag map, a compare-based "highest version wins" reduction for same-commit tags, and a separate ls-remote-and-precision-fetch pass just to avoid pulling in unrelated tags. Replace it with: check local tags first (zero network calls in the common case), and only when shallow with tags on the remote, deepen the commit history incrementally with a tree/blob filter until a reachable tag turns up. No comparison between same-commit tags, no reachability bookkeeping against ls-remote output. This changes two observable behaviors, now reflected in the spec and requirements: when multiple version tags name the same commit, one is used arbitrarily instead of picking the highest; and deepening may also pull in unrelated tag refs (never their tree/blob contents) instead of fetching only the one resolved tag. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Same-commit comparison is a narrow, well-defined case (at most a handful of tags), unlike comparing across different commits while walking history for the nearest reachable tag, which stays a plain first-match. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
source: file | gitconfiguration. File remains the default; a missingVERSIONis initialized from reachable local tags or0.1.0.VERSION, makeincreport the same proposal asgit-latest, and letsetapply post hooks without creating a file or tag.Validation
deno task test(56 Deno tests plus Node, Helm, Maven, and .NET scenarios)deno fmt --check .agents AGENTS.md deno.json src README.mddeno lintdeno check main.tsCloses #181