-
Notifications
You must be signed in to change notification settings - Fork 1
/
darwin-configuration.nix
49 lines (38 loc) · 1.34 KB
/
darwin-configuration.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# add home-manager as a channel first
# nix-channel --add https://github.com/nix-community/home-manager/archive/master.tar.gz home-manager
{ config, pkgs, ... }:
{
nixpkgs.config.allowUnfree = true;
nix = {
package = pkgs.nixVersions.stable;
extraOptions = ''
experimental-features = nix-command flakes
'';
};
# link home.packages to /Applications so that Spotlight can find them
system.build.applications = pkgs.lib.mkForce (pkgs.buildEnv {
name = "applications";
paths = config.environment.systemPackages ++ config.home-manager.users.ag.home.packages;
pathsToLink = "/Applications";
});
programs.bash.enableCompletion = true;
programs.zsh.enable = true;
# Auto upgrade nix package and the daemon service.
services.nix-daemon.enable = true;
# Used for backwards compatibility, please read the changelog before changing.
# $ darwin-rebuild changelog
system.stateVersion = 4;
environment.systemPackages = with pkgs; [
pinentry_mac
gnupg
];
environment.shells = [pkgs.bashInteractive];
home-manager.users.ag.programs.bash.bashrcExtra = pkgs.lib.mkAfter ''
export PATH="/etc/profiles/per-user/$USER/bin:/Applications/Visual Studio Code.app/Contents/Resources/app/bin:$PATH"
'';
age.secrets.ag-npmrc = {
file = ../../secrets/ag.npmrc.age;
owner = "ag";
group = "staff";
};
}