From 8dad5a22399782a4ef681174219546cb050e580f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20Reu=C3=9Fe?= Date: Mon, 24 Oct 2022 09:13:07 +0200 Subject: [PATCH] nixos/zsh: prefer added completions over completions shipped with Zsh Zsh ships some rudimentary completions for programs where upstream also ships their own completions (e.g., curl). So as not to shadow those completions, we need to prepend to the fpath instead of appending. Fixes #197502 --- nixos/modules/programs/zsh/zsh.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nixos/modules/programs/zsh/zsh.nix b/nixos/modules/programs/zsh/zsh.nix index 0c59d20fee46..29790e0dd759 100644 --- a/nixos/modules/programs/zsh/zsh.nix +++ b/nixos/modules/programs/zsh/zsh.nix @@ -184,7 +184,7 @@ in # 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) + fpath=($p/share/zsh/site-functions $p/share/zsh/$ZSH_VERSION/functions $p/share/zsh/vendor-completions $fpath) done # Setup custom shell init stuff.