aboutsummaryrefslogtreecommitdiff
path: root/modules/zsh.nix
diff options
context:
space:
mode:
Diffstat (limited to 'modules/zsh.nix')
-rw-r--r--modules/zsh.nix29
1 files changed, 29 insertions, 0 deletions
diff --git a/modules/zsh.nix b/modules/zsh.nix
new file mode 100644
index 0000000..9dab7d8
--- /dev/null
+++ b/modules/zsh.nix
@@ -0,0 +1,29 @@
+{ config, lib, pkgs, ... }:
+
+let
+ cfg = config.zsh;
+in {
+ options.zsh.enable = lib.mkEnableOption "Enable zsh and configure";
+
+ config = lib.mkIf cfg.enable {
+ programs.zsh = {
+ enable = true;
+ autosuggestion.enable = true;
+ historySubstringSearch.enable = true;
+ plugins = [
+ {
+ name = "pure";
+ src = "${pkgs.pure-prompt}/share/zsh/site-functions";
+ }
+ {
+ name = "zsh-completions";
+ src = "${pkgs.zsh-completions}/share/zsh/site-functions";
+ }
+ {
+ name = "fast-syntax-highlighting";
+ src = "${pkgs.zsh-fast-syntax-highlighting}/share/zsh/site-functions";
+ }
+ ];
+ };
+ };
+}