aboutsummaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorschererleander <leander@schererleander.de>2025-04-29 22:47:33 +0200
committerschererleander <leander@schererleander.de>2025-04-29 22:47:33 +0200
commit1b0a888b4552d9c56a62676e2cb3577faa54e7cd (patch)
tree4008e7cc52da01991c8b60d0b8b71b8a1004b464 /modules
parentcf2fe4f8b9e346b3286de0540d844d4b69feedb4 (diff)
fix plugins
Diffstat (limited to 'modules')
-rw-r--r--modules/zsh.nix42
1 files changed, 24 insertions, 18 deletions
diff --git a/modules/zsh.nix b/modules/zsh.nix
index 9dab7d8..3f4a7b1 100644
--- a/modules/zsh.nix
+++ b/modules/zsh.nix
@@ -3,27 +3,33 @@
let
cfg = config.zsh;
in {
- options.zsh.enable = lib.mkEnableOption "Enable zsh and configure";
+ options.zsh.enable = lib.mkEnableOption "Configure zsh";
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";
- }
- ];
+ enable = true;
+ enableCompletion = true;
+ autosuggestion.enable = true;
+ syntaxHighlighting.enable = true;
+
+ initExtra = ''
+ # Directory completion with trailing slash
+ zstyle ':completion:*' list-dirs-first true
+ zstyle ':completion:*' special-dirs true
+ zstyle ':completion:*' squeeze-slashes true
+ zstyle ':completion:*' add-space false
+ '';
+
+ zplug = {
+ enable = true;
+ plugins = [
+ { name = "mafredri/zsh-async"; }
+ { name = "zpm-zsh/colorize"; }
+ { name = "sindresorhus/pure"; tags = [ "as:theme" "use:pure.zsh" ]; }
+ { name = "zdharma-continuum/fast-syntax-highlighting"; }
+ { name = "zsh-users/zsh-autosuggestions"; }
+ ];
+ };
};
};
}