From 58f246595ac7d9c8ddeb13fcef1f64eddc7d9908 Mon Sep 17 00:00:00 2001 From: Daiderd Jordan Date: Mon, 12 Dec 2016 22:00:48 +0100 Subject: add programs.zsh module --- modules/programs/zsh.nix | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 modules/programs/zsh.nix (limited to 'modules/programs') diff --git a/modules/programs/zsh.nix b/modules/programs/zsh.nix new file mode 100644 index 0000000..ff39d4b --- /dev/null +++ b/modules/programs/zsh.nix @@ -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}"; + + }; +} -- cgit v1.2.3