Skip to content

Commit

Permalink
Don't expand aliases
Browse files Browse the repository at this point in the history
  • Loading branch information
marlonrichert committed May 21, 2023
1 parent 4fbd121 commit 52e2e03
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 10 deletions.
3 changes: 1 addition & 2 deletions functions/completion/_autocomplete.command
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
#compdef -command-

local -P ret=1
_expand_alias "$@" &&
ret=0
_autocd "$@" &&
ret=0
return ret
9 changes: 1 addition & 8 deletions scripts/.autocomplete.config
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,7 @@ autocomplete:config:cache-path() {
reply=( "${XDG_CACHE_HOME:-$HOME/.cache}/zsh/compcache" )
}

builtin zstyle -e ':completion:*' completer autocomplete:config:completer
autocomplete:config:completer() {
if [[ $CURRENT -eq 1 && -z $PREFIX$SUFFIX && $compstate[context] == command ]]; then
reply=( _complete )
else
reply=( _complete _prefix _ignored _correct _approximate )
fi
}
builtin zstyle ':completion:*' completer _complete _prefix _ignored _correct _approximate

builtin zstyle ':completion:*:expand:*' tag-order '! original' -
builtin zstyle -e ':completion:*:-command-:*' tag-order autocomplete:config:tag-order:command
Expand Down

0 comments on commit 52e2e03

Please sign in to comment.