From 85de8ec624c771759f9b3d285b5a40e3d39ef43e Mon Sep 17 00:00:00 2001 From: Felix Tenley Date: Sat, 14 Mar 2020 04:13:43 +0100 Subject: [PATCH] feat: move plugins from initExtraBeforeCompInit to plugins --- home/shell/default.nix | 22 +++++++++++++++++----- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/home/shell/default.nix b/home/shell/default.nix index 5967ab9..f9c4755 100644 --- a/home/shell/default.nix +++ b/home/shell/default.nix @@ -24,11 +24,23 @@ in enableAutosuggestions = true; autocd = true; defaultKeymap = "viins"; - initExtraBeforeCompInit = with pkgs; '' - source ${zsh-syntax-highlighting}/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh - source ${zsh-history-substring-search}/share/zsh-history-substring-search/zsh-history-substring-search.zsh - source ${./first-tab-completion.zsh} - ''; + plugins = with pkgs; [ + { + name = "first-tab-completion"; + src = lib.cleanSource ./.; + file = "first-tab-completion.zsh"; + } + { + name = "zsh-syntax-highlighting"; + src = zsh-syntax-highlighting; + file = "share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh"; + } + { + name = "zsh-history-substring-search"; + src = zsh-history-substring-search; + file = "share/zsh-history-substring-search/zsh-history-substring-search.zsh"; + } + ]; initExtra = '' zmodload zsh/complist zstyle ':completion:*' menu select