mirror of
https://github.com/nix-community/nix-direnv.git
synced 2025-11-08 19:46:11 +01:00
modernize treefmt configuration
This commit is contained in:
parent
bd2255044c
commit
c57fe2b791
1 changed files with 10 additions and 6 deletions
14
treefmt.nix
14
treefmt.nix
|
|
@ -3,10 +3,10 @@
|
||||||
inputs.treefmt-nix.flakeModule
|
inputs.treefmt-nix.flakeModule
|
||||||
];
|
];
|
||||||
|
|
||||||
perSystem = _: {
|
perSystem = {
|
||||||
treefmt = {
|
treefmt = {
|
||||||
# Used to find the project root
|
# Used to find the project root
|
||||||
projectRootFile = "flake.lock";
|
projectRootFile = ".git/config";
|
||||||
|
|
||||||
programs = {
|
programs = {
|
||||||
deadnix.enable = true;
|
deadnix.enable = true;
|
||||||
|
|
@ -20,9 +20,13 @@
|
||||||
statix.enable = true;
|
statix.enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
settings.formatter = {
|
settings.formatter =
|
||||||
shellcheck.includes = [ "*.sh" "direnvrc" ];
|
let
|
||||||
shfmt.includes = [ "*.sh" "direnvrc" ];
|
shellIncludes = [ "*.sh" "direnvrc" ];
|
||||||
|
in
|
||||||
|
{
|
||||||
|
shellcheck.includes = shellIncludes;
|
||||||
|
shfmt.includes = shellIncludes;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue