fish: clear existing completions before defining aliases (#1165)

Fish ships with built-in completions for common commands like `j` (share/completions/j.fish for autojump). These override zoxide's completions when using `--cmd j`. Clear them before defining aliases.
This commit is contained in:
Simon Olofsson
2026-01-30 16:54:27 +05:30
committed by GitHub
parent f00fe0f0ae
commit 324b0d35e7
+2
View File
@@ -117,9 +117,11 @@ end
{%- when Some with (cmd) %}
abbr --erase {{cmd}} &>/dev/null
complete --erase --command {{cmd}}
alias {{cmd}}=__zoxide_z
abbr --erase {{cmd}}i &>/dev/null
complete --erase --command {{cmd}}i
alias {{cmd}}i=__zoxide_zi
{%- when None %}