-
Notifications
You must be signed in to change notification settings - Fork 354
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feature/treefmt - integrate treefmt-nix #1679
base: main
Are you sure you want to change the base?
Conversation
(cherry picked from commit f1de7ec)
(cherry picked from commit 099be01)
…on and include in pre-commit hooks (cherry picked from commit 2218266)
Signed-off-by: John Muchovej <[email protected]>
@@ -3,11 +3,12 @@ | |||
let | |||
__DEVENV_VARS__ | |||
in { | |||
treefmt-nix.url = "github:numtide/treefmt-nix"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's not add it by default, not many will use it so it should be optional.
@@ -50,6 +50,9 @@ Running ``devenv init`` generates ``devenv.nix``: | |||
# https://devenv.sh/git-hooks/ | |||
git-hooks.hooks.shellcheck.enable = true; | |||
|
|||
# https://devenv.sh/treefmt/ | |||
treefmt.programs.nixpkgs-fmt.enable = true; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same here, not that important feature to be in the README
👋 @domenkozar thanks for already taking a peek! 😮 essentially, in devenv/src/modules/integrations/git-hooks.nix Lines 4 to 7 in 68a6d54
|
Just so you know, the way this integration needs to be done has changed based on the treefmt package. I got it working in my own library here: I hope that helps you guys! |
attempting to continue the work from #1317.