add programs.zsh module
This commit is contained in:
parent
b933e03c15
commit
58f246595a
3 changed files with 41 additions and 2 deletions
37
modules/programs/zsh.nix
Normal file
37
modules/programs/zsh.nix
Normal file
|
|
@ -0,0 +1,37 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
|
||||
cfg = config.programs.zsh;
|
||||
|
||||
in
|
||||
|
||||
{
|
||||
options = {
|
||||
|
||||
programs.zsh.enable = mkOption {
|
||||
type = types.bool;
|
||||
default = false;
|
||||
description = ''
|
||||
Whether to configure zsh as an interactive shell.
|
||||
'';
|
||||
};
|
||||
|
||||
programs.zsh.shell = mkOption {
|
||||
type = types.path;
|
||||
default = "${pkgs.zsh}/bin/zsh";
|
||||
description = ''
|
||||
Zsh shell to use.
|
||||
'';
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
||||
environment.variables.SHELL = "${cfg.shell}";
|
||||
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue