summaryrefslogtreecommitdiff
path: root/etc
diff options
context:
space:
mode:
authorLiliana Marie Prikler <liliana.prikler@gmail.com>2021-10-24 14:09:47 +0200
committerTobias Geerinckx-Rice <me@tobias.gr>2021-10-24 20:17:05 +0200
commit55f6d9e818512b4e3e4adacfa99deb201b6854be (patch)
treef81cc3071c950a495ee0d113752274cab6dba581 /etc
parent2ab53a68fd687b15deb5ad837e20e7ea81cac484 (diff)
downloadguix-patches-55f6d9e818512b4e3e4adacfa99deb201b6854be.tar
guix-patches-55f6d9e818512b4e3e4adacfa99deb201b6854be.tar.gz
etc: completion: Filter gratuitous spaces from available packages.
Tested with: guix environment --{ad-hoc,pure} zsh guix bash-completion coreutils -- zsh % fpath=(~/guix/etc/completion/zsh $fpath) % autoload -U compinit; compinit * etc/completion/zsh/_guix (_guix_list_available_packages): Remove spaces. Co-authored-by: Tobias Geerinckx-Rice <me@tobias.gr>
Diffstat (limited to 'etc')
-rw-r--r--etc/completion/zsh/_guix1
1 files changed, 1 insertions, 0 deletions
diff --git a/etc/completion/zsh/_guix b/etc/completion/zsh/_guix
index bbc13c6ca1..9b1f16c664 100644
--- a/etc/completion/zsh/_guix
+++ b/etc/completion/zsh/_guix
@@ -58,6 +58,7 @@ _guix_list_available_packages()
if ( [[ ${+_guix_available_packages} -eq 0 ]] || _cache_invalid GUIX_AVAILABLE_PACKAGES ) \
&& ! _retrieve_cache GUIX_AVAILABLE_PACKAGES; then
_guix_available_packages=(${${(f)"$(guix package -A | cut -f1)"}})
+ _guix_available_packages=("${_guix_available_packages[@]// /}")
_store_cache GUIX_AVAILABLE_PACKAGES _guix_available_packages
fi
}