summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobby Russell <robby@planetargon.com>2015-09-29 11:31:59 -0700
committerRobby Russell <robby@planetargon.com>2015-09-29 11:31:59 -0700
commita9c882094dedfdefb311db5967b974980cec49ec (patch)
tree2808e74a8062e0411a6edd6c498b7178a7a7b4d0
parent52e2aaee068814aadc989ac904bb055349240869 (diff)
parent4589bc6c654650d52a47b5cb86c588f4ab2aca46 (diff)
downloadzsh-a9c882094dedfdefb311db5967b974980cec49ec.tar.gz
zsh-a9c882094dedfdefb311db5967b974980cec49ec.tar.bz2
zsh-a9c882094dedfdefb311db5967b974980cec49ec.zip
Merge pull request #4426 from apjanke/turn-off-3889-by-default
completion: turn off the #3889 compfix check by default
-rw-r--r--oh-my-zsh.sh18
1 files changed, 12 insertions, 6 deletions
diff --git a/oh-my-zsh.sh b/oh-my-zsh.sh
index 8e31ddd0f..6cc5ac630 100644
--- a/oh-my-zsh.sh
+++ b/oh-my-zsh.sh
@@ -11,6 +11,8 @@ fpath=($ZSH/functions $ZSH/completions $fpath)
# Load all stock functions (from $fpath files) called below.
autoload -U compaudit compinit
+: ${ZSH_DISABLE_COMPFIX:=true}
+
# Set ZSH_CUSTOM to the path where your custom config files
# and plugins exists, or else we will use the default custom/
if [[ -z "$ZSH_CUSTOM" ]]; then
@@ -62,13 +64,17 @@ if [ -z "$ZSH_COMPDUMP" ]; then
ZSH_COMPDUMP="${ZDOTDIR:-${HOME}}/.zcompdump-${SHORT_HOST}-${ZSH_VERSION}"
fi
-# If completion insecurities exist, warn the user without enabling completions.
-if ! compaudit &>/dev/null; then
- # This function resides in the "lib/compfix.zsh" script sourced above.
- handle_completion_insecurities
-# Else, enable and cache completions to the desired file.
+if [[ $ZSH_DISABLE_COMPFIX != true ]]; then
+ # If completion insecurities exist, warn the user without enabling completions.
+ if ! compaudit &>/dev/null; then
+ # This function resides in the "lib/compfix.zsh" script sourced above.
+ handle_completion_insecurities
+ # Else, enable and cache completions to the desired file.
+ else
+ compinit -d "${ZSH_COMPDUMP}"
+ fi
else
- compinit -d "${ZSH_COMPDUMP}"
+ compinit -i -d "${ZSH_COMPDUMP}"
fi
# Load all of the plugins that were defined in ~/.zshrc