treefmt: flatten the config
By importing the config on the treefmt module level, it makes the config more flat, and also compatible with non-flake-parts users.
This commit is contained in:
parent
ea9e8d7489
commit
c2eac1a161
2 changed files with 43 additions and 46 deletions
|
@ -60,9 +60,10 @@
|
|||
inputs.treefmt-nix.flakeModule
|
||||
./effect.nix
|
||||
./shell.nix
|
||||
./treefmt.nix
|
||||
];
|
||||
|
||||
perSystem.treefmt.imports = [ ./treefmt.nix ];
|
||||
|
||||
flake.nixosConfigurations =
|
||||
let
|
||||
inherit (inputs.nixpkgs.lib) nixosSystem;
|
||||
|
|
|
@ -1,6 +1,4 @@
|
|||
{
|
||||
perSystem = { pkgs, ... }: {
|
||||
treefmt = {
|
||||
{ pkgs, ... }: {
|
||||
# Used to find the project root
|
||||
projectRootFile = "flake.lock";
|
||||
|
||||
|
@ -49,6 +47,4 @@
|
|||
includes = [ "*.py" ];
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue