From 520a43ced38843d5116594b359854e02fa7ed057 Mon Sep 17 00:00:00 2001 From: Izorkin Date: Fri, 25 Aug 2017 11:34:21 +0300 Subject: Fix zsh completions (#28550) * Fix zsh completions * Fix zsh completions (fix commit) * Fix zsh completions (fix commit) --- nixos/modules/programs/zsh/zsh.nix | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'nixos') diff --git a/nixos/modules/programs/zsh/zsh.nix b/nixos/modules/programs/zsh/zsh.nix index a055291282c9..ee61e2d2382c 100644 --- a/nixos/modules/programs/zsh/zsh.nix +++ b/nixos/modules/programs/zsh/zsh.nix @@ -158,6 +158,11 @@ in HELPDIR="${pkgs.zsh}/share/zsh/$ZSH_VERSION/help" + # Tell zsh how to find installed completions + for p in ''${(z)NIX_PROFILES}; do + fpath+=($p/share/zsh/site-functions $p/share/zsh/$ZSH_VERSION/functions $p/share/zsh/vendor-completions) + done + ${optionalString cfg.enableCompletion "autoload -U compinit && compinit"} ${optionalString (cfg.enableAutosuggestions) @@ -172,11 +177,6 @@ in ${cfg.promptInit} - # Tell zsh how to find installed completions - for p in ''${(z)NIX_PROFILES}; do - fpath+=($p/share/zsh/site-functions $p/share/zsh/$ZSH_VERSION/functions $p/share/zsh/vendor-completions) - done - # Read system-wide modifications. if test -f /etc/zshrc.local; then . /etc/zshrc.local -- cgit 1.4.1