mirror of
https://github.com/Swarsel/.dotfiles.git
synced 2025-12-06 00:57:22 +01:00
feat: add checks to devShell
This commit is contained in:
parent
647a2ae1a8
commit
0a6cf0e006
3 changed files with 41 additions and 13 deletions
32
flake.nix
32
flake.nix
|
|
@ -199,16 +199,30 @@
|
|||
homeManagerModules = import ./modules/home;
|
||||
|
||||
packages = forEachSystem (pkgs: import ./pkgs { inherit pkgs; });
|
||||
devShells = forEachSystem
|
||||
(pkgs:
|
||||
{
|
||||
default = pkgs.mkShell {
|
||||
NIX_CONFIG = "experimental-features = nix-command flakes";
|
||||
nativeBuildInputs = [ pkgs.nix pkgs.home-manager pkgs.git ];
|
||||
};
|
||||
});
|
||||
devShells = forAllSystems (
|
||||
system:
|
||||
let
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
checks = self.checks.${system};
|
||||
in
|
||||
{
|
||||
default = pkgs.mkShell {
|
||||
NIX_CONFIG = "experimental-features = nix-command flakes";
|
||||
inherit (checks.pre-commit-check) shellHook;
|
||||
buildInputs = checks.pre-commit-check.enabledPackages;
|
||||
nativeBuildInputs = [
|
||||
pkgs.nix
|
||||
pkgs.home-manager
|
||||
pkgs.git
|
||||
pkgs.just
|
||||
pkgs.age
|
||||
pkgs.ssh-to-age
|
||||
pkgs.sops
|
||||
];
|
||||
};
|
||||
}
|
||||
);
|
||||
|
||||
# this sets the formatter that is going to be used by nix fmt
|
||||
formatter = forEachSystem (pkgs: pkgs.nixpkgs-fmt);
|
||||
checks = forAllSystems (
|
||||
system:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue