Skip to content

Commit ab104b2

Browse files
zsh: add as module
1 parent ccde89f commit ab104b2

File tree

4 files changed

+14
-4
lines changed

4 files changed

+14
-4
lines changed

flake.nix

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,13 +66,15 @@
6666
self.nixosModules.mac-app-util
6767
self.nixosModules.emacs
6868
self.nixosModules.controlling
69+
self.nixosModules.zsh
6970
];
7071
};
7172
git = import ./modules/git;
7273
nix-starter-kit = import ./modules/nix-starter-kit.nix;
7374
mac-app-util = import ./modules/mac-app-util;
7475
emacs = import ./modules/emacs;
7576
controlling = import ./modules/controlling;
77+
zsh = import ./modules/zsh;
7678
};
7779
};
7880
};

modules/nix-starter-kit.nix

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,6 @@
3535
xz
3636
zip
3737
];
38-
39-
# FIXME(Johannes): module!
40-
# file.".config/zsh/ag.zsh".source = ./zsh/ag.zsh;
4138
};
4239

4340
programs = {

modules/zsh/default.nix

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{ config, lib, ... }:
2+
3+
{
4+
options.active-group.zsh.enable = lib.mkEnableOption "zsh";
5+
6+
config = lib.mkIf config.active-group.zsh.enable {
7+
home.file.".config/zsh/ag.zsh".source = ./ag.zsh;
8+
};
9+
}

templates/default/home.nix

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,15 @@ in
1212
home = {
1313
inherit username stateVersion homeDirectory;
1414
sessionVariables = rec {
15-
# NOTE: We assume that the howto directory sits at ~/howto!
15+
# NOTE: point this to your local howto checkout
1616
TEXINPUTS = "${homeDirectory}/howto/tex:";
1717
EDITOR = "emacsclient";
1818
VISUAL = EDITOR;
1919
ALTERNATE_EDITOR = "";
2020
};
2121
};
2222

23+
# NOTE: Change things to your liking here!
2324
active-group = {
2425
nix-starter-kit.enable = true;
2526
mac-app-util.enable = pkgs.stdenv.isDarwin;
@@ -33,5 +34,6 @@ in
3334
userName = settings.userFullName;
3435
userEmail = settings.email;
3536
};
37+
zsh.enable = true;
3638
};
3739
}

0 commit comments

Comments
 (0)