flake: dev-shell: use exposed pre-commit script

This commit is contained in:
Bruno BELANYI 2023-03-09 09:07:49 +00:00
parent 8657774d06
commit eac628963a

View file

@ -1,6 +1,6 @@
{ inputs, ... }: { inputs, ... }:
{ {
perSystem = { self', pkgs, ... }: { perSystem = { self', config, pkgs, ... }: {
devShells = { devShells = {
default = pkgs.mkShell { default = pkgs.mkShell {
name = "NixOS-config"; name = "NixOS-config";
@ -10,7 +10,9 @@
nixpkgs-fmt nixpkgs-fmt
]; ];
inherit (self'.checks.pre-commit) shellHook; shellHook = ''
${config.pre-commit.installationScript}
'';
}; };
}; };
}; };