nix_config/home/modules/zsh/default.nix

26 lines
531 B
Nix
Raw Normal View History

2024-11-29 07:44:04 +01:00
{
config,
lib,
pkgs,
...
}:
with lib; let
cfg = config.local.services.zsh;
in {
2024-11-29 19:23:51 +01:00
options.local.services.zsh = {
enable = mkEnableOption "zsh settings";
prompt = mkOption {
type = types.str;
description = "prompt for your terminal";
example = literalExpression "%B[%~] \${vcs_info_msg_0_}%b";
};
};
2024-11-29 07:44:04 +01:00
config = mkIf cfg.enable {
programs.zsh = {
enable = true;
syntaxHighlighting.enable = true;
2024-11-29 19:23:51 +01:00
initExtra = import ./zshrc.nix {inherit config lib pkgs;};
2024-11-29 07:44:04 +01:00
};
};
}