nix/shell.nix
2023-09-19 21:02:27 +09:00

24 lines
No EOL
656 B
Nix

# shell.nix
# A nixpkgs instance that is grabbed from the pinned nixpkgs commit in the lock file
# Useful to avoid using channels when using legacy nix commands
{
pkgs ? (import ./lib/nixpkgs.nix ) { },
sops-nix ? (import ./lib/sops-nix.nix) { }
}: {
default = pkgs.mkShell {
sops-nix = sops-nix;
NIX_CONFIG = "experimental-features = nix-command flakes";
# imports all files ending in .asc/.gpg
sopsPGPKeyDirs = [
"${toString ./.}/keys/hosts"
"${toString ./.}/keys/users"
];
nativeBuildInputs = [
pkgs.nix
pkgs.home-manager
pkgs.git
(sops-nix {}).sops-import-keys-hook
];
};
}