aboutsummaryrefslogtreecommitdiff
path: root/powerlevel10k.zsh-theme
diff options
context:
space:
mode:
authorromkatv <roman.perepelitsa@gmail.com>2020-01-26 18:54:52 +0300
committerromkatv <roman.perepelitsa@gmail.com>2020-01-26 18:54:52 +0300
commita9715367d4547dabaa724f9907bc971078453528 (patch)
tree9d84ab2be3a7e3a91901b68494a55d350923616e /powerlevel10k.zsh-theme
parent98c614b85114b43124d5d861c3849c9b294799ff (diff)
fix prompt_char (never showed error); unify options
Diffstat (limited to 'powerlevel10k.zsh-theme')
-rw-r--r--powerlevel10k.zsh-theme11
1 files changed, 8 insertions, 3 deletions
diff --git a/powerlevel10k.zsh-theme b/powerlevel10k.zsh-theme
index 834edd6d..7bf6a2e3 100644
--- a/powerlevel10k.zsh-theme
+++ b/powerlevel10k.zsh-theme
@@ -18,10 +18,14 @@
'builtin' 'setopt' 'no_aliases' 'no_sh_glob' 'brace_expand'
(( $+__p9k_root_dir )) || typeset -gr __p9k_root_dir=${POWERLEVEL9K_INSTALLATION_DIR:-${${(%):-%x}:A:h}}
+(( $+__p9k_intro )) || typeset -gr __p9k_intro='emulate -L zsh -o no_hist_expand -o extended_glob -o no_prompt_bang -o prompt_percent -o no_prompt_subst -o no_aliases -o no_bg_nice -o typeset_silent
+local -a match mbegin mend reply
+local -i MBEGIN MEND OPTIND
+local MATCH REPLY OPTARG IFS=$'\'' \t\n\0'\''
+[[ -z $_p9k_locale ]] || local LC_ALL=$_p9k_locale'
() {
- emulate -L zsh
- setopt no_hist_expand extended_glob no_prompt_bang no_prompt_subst prompt_percent no_aliases
+ eval $__p9k_intro
if (( $+__p9k_sourced )); then
prompt_powerlevel9k_setup
return 0
@@ -40,7 +44,8 @@
source $__p9k_root_dir/internal/p10k.zsh || true
}
-(( ! $+__p9k_instant_prompt_active )) || unsetopt local_options prompt_cr prompt_sp
+unsetopt local_options
+(( $+__p9k_instant_prompt_active )) && unsetopt prompt_cr prompt_sp || setopt prompt_cr prompt_sp
(( ${#__p9k_src_opts} )) && setopt ${__p9k_src_opts[@]}
'builtin' 'unset' '__p9k_src_opts'