mirror of
https://github.com/romkatv/powerlevel10k.git
synced 2024-12-24 16:11:57 +00:00
fix p10k display -a
This commit is contained in:
parent
f06be72977
commit
d71d1409c4
2 changed files with 19 additions and 5 deletions
|
@ -1,4 +1,4 @@
|
|||
if [[ $__p9k_sourced != 5 ]]; then
|
||||
if [[ $__p9k_sourced != 6 ]]; then
|
||||
>&2 print -P ""
|
||||
>&2 print -P "[%F{1}ERROR%f]: Corrupted powerlevel10k installation."
|
||||
>&2 print -P ""
|
||||
|
@ -7562,7 +7562,7 @@ typeset -gi __p9k_reset_state
|
|||
function p10k() {
|
||||
[[ $# != 1 || $1 != finalize ]] || { p10k-instant-prompt-finalize; return 0 }
|
||||
|
||||
eval "$__p9k_intro"
|
||||
eval "$__p9k_intro_no_reply"
|
||||
|
||||
if (( !ARGC )); then
|
||||
print -rP -- $__p9k_p10k_usage >&2
|
||||
|
@ -7571,6 +7571,8 @@ function p10k() {
|
|||
|
||||
case $1 in
|
||||
segment)
|
||||
local REPLY
|
||||
local -a reply
|
||||
shift
|
||||
local -i OPTIND
|
||||
local OPTARG opt state bg=0 fg icon cond text ref=0 expand=0
|
||||
|
@ -7635,6 +7637,8 @@ function p10k() {
|
|||
done
|
||||
return 0
|
||||
fi
|
||||
local REPLY
|
||||
local -a reply
|
||||
for opt in "${@:$OPTIND}"; do
|
||||
pair=(${(s:=:)opt})
|
||||
list=(${(s:,:)${pair[2]}})
|
||||
|
@ -7677,6 +7681,8 @@ function p10k() {
|
|||
print -rP -- $__p9k_p10k_configure_usage >&2
|
||||
return 1
|
||||
fi
|
||||
local REPLY
|
||||
local -a reply
|
||||
p9k_configure "$@" || return
|
||||
;;
|
||||
reload)
|
||||
|
|
|
@ -18,12 +18,20 @@
|
|||
'builtin' 'setopt' 'no_aliases' 'no_sh_glob' 'brace_expand'
|
||||
|
||||
(( $+__p9k_root_dir )) || typeset -gr __p9k_root_dir=${POWERLEVEL9K_INSTALLATION_DIR:-${${(%):-%x}:A:h}}
|
||||
# Note: leading spaces before `local` are important. Otherwise Antigen will remove `local` (!!!).
|
||||
(( $+__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
|
||||
(( $+__p9k_intro )) || {
|
||||
# Note: leading spaces before `local` are important. Otherwise Antigen will remove `local` (!!!).
|
||||
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'
|
||||
# The same as above but without `local -a reply` and `local REPLY`.
|
||||
typeset -gr __p9k_intro_no_reply='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
|
||||
local -i MBEGIN MEND OPTIND
|
||||
local REPLY OPTARG IFS=$'\'' \t\n\0'\''
|
||||
[[ -z $_p9k__locale ]] || local LC_ALL=$_p9k__locale'
|
||||
}
|
||||
|
||||
() {
|
||||
eval "$__p9k_intro"
|
||||
|
@ -35,7 +43,7 @@
|
|||
if [[ $__p9k_dump_file != $__p9k_instant_prompt_dump_file ]] && (( ! $+functions[_p9k_preinit] )) && source $__p9k_dump_file 2>/dev/null && (( $+functions[_p9k_preinit] )); then
|
||||
_p9k_preinit
|
||||
fi
|
||||
typeset -gr __p9k_sourced=5
|
||||
typeset -gr __p9k_sourced=6
|
||||
if [[ -w $__p9k_root_dir && -w $__p9k_root_dir/internal && -w $__p9k_root_dir/gitstatus && ${(%):-%#} == % ]]; then
|
||||
local f
|
||||
for f in $__p9k_root_dir/{powerlevel9k.zsh-theme,powerlevel10k.zsh-theme,internal/p10k.zsh,internal/icons.zsh,internal/configure.zsh,internal/worker.zsh,internal/parser.zsh,gitstatus/gitstatus.plugin.zsh}; do
|
||||
|
|
Loading…
Reference in a new issue