feat(git): add grouped commit integration opt-out - #248
Merged
Conversation
### Summary Add a default-enabled `git.enable` umbrella so projects can disable all Flakebox commit-time Git integration with one option. When disabled, Flakebox omits generated pre-commit and commit-msg hooks, the commit template, their shell activation/configuration, the pre-commit timer package, and generated Just/GitHub consumers of the absent hook. Preserve the existing granular options for partial control. ### Details Gate the three existing generation and activation branches with `git.enable` while leaving contributed check configuration and each partial enable option unchanged. Gate the Just lint recipe/final-check dependency and GitHub CI lint job on effective pre-commit enablement, including the existing granular pre-commit option. This prevents future Flakebox generation, hook installation, template configuration, and dangling consumers without adding stale-state manifests or automatic deletion. Document manual cleanup of additive generated files, hooks under Git’s common directory after ownership confirmation, and the template setting only when it still equals Flakebox’s value. Add evaluation assertions for defaults, retained partial values, and package omission. Generated checks cover positive default artifacts/actions/consumers, umbrella-disabled output, and each granular artifact combination. ### Reviews An independent maintainability review initially found dangling Just/GitHub pre-commit consumers, incomplete default/granular coverage, and unsafe/incomplete manual cleanup documentation. The implementation gated consumers on effective pre-commit enablement, expanded generated-behavior coverage, and made cleanup instructions ownership- and value-aware. Follow-up review passed. ### Validation - `nix develop -c treefmt` - focused `gitHooks` Nix check - `nix develop -c selfci check` - `nix develop -c selfci check --candidate vtllymzy`
dpc
marked this pull request as ready for review
July 25, 2026 00:01
dpc
added a commit
to dpc/flakebox
that referenced
this pull request
Jul 30, 2026
feat(git): add grouped commit integration opt-out
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.
Posted by Tau
Summary
Add
git.enable, a default-true umbrella option for disabling all Flakebox commit-time Git integration without configuring three separate partial options.Details
With
git.enable = false, Flakebox does not generate or installpre-commitorcommit-msg, generate/configure the commit template, include the hook timer package, or generate Just/GitHub consumers of the absent pre-commit hook. Existinggit.pre-commit.enable,git.commit-msg.enable, andgit.commit-template.enableoptions retain granular behavior when the umbrella is enabled.The option prevents future generated/activated state but intentionally does not delete prior local state. Documentation gives ownership-aware manual cleanup commands for additive generated files, Git common-directory hooks, and only the known Flakebox
commit.templatevalue.Generated behavior tests cover default-enabled output, umbrella-disabled output, all granular artifact combinations, activation commands, packages, and Just/GitHub consumers.