Feat/templates repo immutable - #32
Merged
Merged
Conversation
fredbi
force-pushed
the
feat/templates-repo-immutable
branch
from
August 21, 2026 10:59
3ac9f7a to
c7b8ae2
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #32 +/- ##
==========================================
+ Coverage 67.06% 75.96% +8.90%
==========================================
Files 31 54 +23
Lines 2663 3945 +1282
==========================================
+ Hits 1786 2997 +1211
- Misses 843 947 +104
+ Partials 34 1 -33 ☔ View full report in Codecov by Harness. |
* makes dependabot more responsive (twice a week instead of once) * fixes dependabot PR limit to avoid skipping updates on mono-repos * bumps go.mod dependencies * drops the Go Report Card (discontinued service) Signed-off-by: Frederic BIDON <fredbi@yahoo.com>
WithTokenSeparator replaces the whole predicate, so a caller wanting one extra separator had to restate the default classification. WithExtraTokenSeparator takes runes and keeps the default: customTokenSeparatorFunc consults defaultTokenSeparator first, then a set holding only the runes that are not already separators. Signed-off-by: Frederic BIDON <fredbi@yahoo.com>
Generators assemble a funcmap from several parts and need the overriding rules spelled out. Merge is last-wins, Coalesce is first-wins, and both delete the text/template builtins from the result so no part can shadow "and", "index", "printf" and the rest. Pick clones a funcmap down to the named functions, ignoring names the source does not hold. Signed-off-by: Frederic BIDON <fredbi@yahoo.com>
Replaces the mutable Repository (NewRepository, LoadDefaults, LoadDir, LoadContrib, AddFile, SetAllowOverride, SetProtectedTemplates) with one built in a single pass from sources declared as options. New parses every asset together so any template can call any other, then freezes the set. Clone re-parses from scratch, so a template calling an overridden one picks up the new definition and the two repositories share no state. Compose derives repositories from repositories: Rebase, Merge, Coalesce, the last two delegating to funcmaps.Merge and funcmaps.Coalesce for the funcmap side. Signed-off-by: Frederic BIDON <fredbi@yahoo.com>
New shared funcmap for typical go codegen. Removed external dependencies such as sprig, etc. Signed-off-by: Frederic BIDON <fredbi@yahoo.com>
fredbi
force-pushed
the
feat/templates-repo-immutable
branch
from
August 21, 2026 11:55
c7b8ae2 to
5beb6d4
Compare
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.
Change type
Please select: 🆕 New feature or enhancement|🔧 Bug fix'|📃 Documentation update
Short description
Fixes
Full description
Checklist