bash ~ zsh wip
This commit is contained in:
20
modules/shell/config.nix
Normal file
20
modules/shell/config.nix
Normal file
@@ -0,0 +1,20 @@
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
options.my.shell.type = lib.mkOption {
|
||||
type = lib.types.enum [
|
||||
"bash"
|
||||
"zsh"
|
||||
];
|
||||
default = "bash";
|
||||
description = "The shell to use system-wide (bash or zsh)";
|
||||
};
|
||||
config = {
|
||||
users.users.jawz.shell = pkgs.${config.my.shell.type};
|
||||
programs.zsh.enable = config.my.shell.type == "zsh";
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user