blob: 0c14b8c9a72c0ca607c611d526585d15d3d551ba (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
{ config, lib, pkgs, ... }:
{
options.shell.zsh = {
enable = lib.mkEnableOption "Enables zsh.";
};
config = lib.mkIf config.shell.zsh.enable {
shell.default = lib.mkDefault "zsh";
shell.command =
if config.shell.default == "zsh" then
lib.mkForce "${pkgs.zsh}/bin/zsh"
else "";
programs.zsh.enable = true;
programs.zsh.dotDir = ".config/zsh";
programs.zsh.history.path = "${config.xdg.cacheHome}/zsh/history";
programs.zsh.initExtra = builtins.readFile ./zshrc;
programs.zsh.shellAliases = config.shell.alias;
};
}
|