diff options
author | Tuowen Zhao <ztuowen@gmail.com> | 2022-02-19 17:12:23 -0600 |
---|---|---|
committer | Tuowen Zhao <ztuowen@gmail.com> | 2022-02-19 17:12:23 -0600 |
commit | cae9a2b797649379e865e6bd73bc67e294e4ac77 (patch) | |
tree | 481419eff4bc761c3ca516704427394193473419 /plugins/rust/rust.plugin.zsh | |
parent | 49edbf438ed690c76e6b2af80368c59404cf0167 (diff) | |
parent | 3427da4057dbe302933a7b5b19b4e23bfb9d0969 (diff) | |
download | zsh-cae9a2b797649379e865e6bd73bc67e294e4ac77.tar.gz zsh-cae9a2b797649379e865e6bd73bc67e294e4ac77.tar.bz2 zsh-cae9a2b797649379e865e6bd73bc67e294e4ac77.zip |
Merge remote-tracking branch 'origin/master'
Diffstat (limited to 'plugins/rust/rust.plugin.zsh')
-rw-r--r-- | plugins/rust/rust.plugin.zsh | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/plugins/rust/rust.plugin.zsh b/plugins/rust/rust.plugin.zsh index 014c73b3b..db6ca9e74 100644 --- a/plugins/rust/rust.plugin.zsh +++ b/plugins/rust/rust.plugin.zsh @@ -11,7 +11,7 @@ command mkdir -p "$ZSH_CACHE_DIR/completions" # bind it to `cargo`. Otherwise, compinit will have already done that if [[ ! -f "$ZSH_CACHE_DIR/completions/_cargo" ]]; then autoload -Uz _cargo - declare -A _comps + typeset -g -A _comps _comps[cargo]=_cargo fi @@ -19,7 +19,7 @@ fi # bind it to `rustup`. Otherwise, compinit will have already done that if [[ ! -f "$ZSH_CACHE_DIR/completions/_rustup" ]]; then autoload -Uz _rustup - declare -A _comps + typeset -g -A _comps _comps[rustup]=_rustup fi @@ -27,5 +27,5 @@ fi rustup completions zsh >| "$ZSH_CACHE_DIR/completions/_rustup" &| cat >| "$ZSH_CACHE_DIR/completions/_cargo" <<'EOF' #compdef cargo -source $(rustc +${${(z)$(rustup default)}[1]} --print sysroot)/share/zsh/site-functions/_cargo +source "$(rustc +${${(z)$(rustup default)}[1]} --print sysroot)"/share/zsh/site-functions/_cargo EOF |