feat(nix): add style tooling

This commit was merged in pull request #52.
This commit is contained in:
2026-09-16 00:13:28 -04:00
parent 5d40b43dd9
commit d24f58a4c9
7 changed files with 91 additions and 7 deletions

28
src/dotfiles/apps.nix Normal file
View File

@@ -0,0 +1,28 @@
{
inputs,
lib,
formatter,
system,
}:
let
pkgs = inputs.nixpkgs.legacyPackages.${system};
in
{
fix = {
type = "app";
program = lib.getExe (pkgs.writeShellApplication {
name = "fix";
runtimeInputs = [
formatter.config.build.wrapper
pkgs.statix
pkgs.deadnix
];
text = ''
treefmt
statix fix .
deadnix --edit --exclude configs/nixos/hosts/*/hardware-configuration.nix -- .
treefmt
'';
});
};
}