1
0
Fork 0
mirror of https://github.com/LnL7/nix-darwin.git synced 2024-12-14 11:57:34 +00:00
nix-darwin/modules/nix/nix-darwin.nix
2016-12-12 17:34:43 +01:00

41 lines
772 B
Nix

{ config, pkgs, ... }:
let
inherit (pkgs) stdenv;
writeProgram = name: env: src:
pkgs.substituteAll ({
inherit name src;
dir = "bin";
isExecutable = true;
} // env);
darwin-option = writeProgram "darwin-option"
{
inherit (config.system) profile;
inherit (stdenv) shell;
}
../../pkgs/nix-tools/darwin-option.sh;
darwin-rebuild = writeProgram "darwin-rebuild"
{
inherit (config.system) profile;
inherit (stdenv) shell;
path = "${pkgs.coreutils}/bin:${config.environment.systemPath}";
}
../../pkgs/nix-tools/darwin-rebuild.sh;
in
{
config = {
environment.systemPackages =
[ # Include nix-tools by default
darwin-option
darwin-rebuild
];
};
}