|
|
@ -8,6 +8,27 @@ |
|
|
|
# http://i.imgur.com/AzjmpwM.png |
|
|
|
# http://i.imgur.com/AzjmpwM.png |
|
|
|
# |
|
|
|
# |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# |
|
|
|
|
|
|
|
# 16 TERMINAL COLORS |
|
|
|
|
|
|
|
# -- --------------- |
|
|
|
|
|
|
|
# 0 black |
|
|
|
|
|
|
|
# 1 red |
|
|
|
|
|
|
|
# 2 green |
|
|
|
|
|
|
|
# 3 yellow |
|
|
|
|
|
|
|
# 4 blue |
|
|
|
|
|
|
|
# 5 magenta |
|
|
|
|
|
|
|
# 6 cyan |
|
|
|
|
|
|
|
# 7 white |
|
|
|
|
|
|
|
# 8 bright black |
|
|
|
|
|
|
|
# 9 bright red |
|
|
|
|
|
|
|
# 10 bright green |
|
|
|
|
|
|
|
# 11 bright yellow |
|
|
|
|
|
|
|
# 12 bright blue |
|
|
|
|
|
|
|
# 13 bright magenta |
|
|
|
|
|
|
|
# 14 bright cyan |
|
|
|
|
|
|
|
# 15 bright white |
|
|
|
|
|
|
|
# |
|
|
|
|
|
|
|
|
|
|
|
# Load dependencies. |
|
|
|
# Load dependencies. |
|
|
|
pmodload 'helper' |
|
|
|
pmodload 'helper' |
|
|
|
|
|
|
|
|
|
|
@ -57,7 +78,7 @@ function prompt_sorin_precmd { |
|
|
|
prompt_sorin_pwd |
|
|
|
prompt_sorin_pwd |
|
|
|
|
|
|
|
|
|
|
|
# Define prompts. |
|
|
|
# Define prompts. |
|
|
|
RPROMPT='${editor_info[overwrite]}%(?:: %F{red}⏎%f)${VIM:+" %B%F{green}V%f%b"}${INSIDE_EMACS:+" %B%F{green}E%f%b"}%f' |
|
|
|
RPROMPT='${editor_info[overwrite]}%(?:: %F{1}⏎%f)${VIM:+" %B%F{6}V%f%b"}${INSIDE_EMACS:+" %B%F{6}E%f%b"}%f' |
|
|
|
|
|
|
|
|
|
|
|
# Kill the old process of slow commands if it is still running. |
|
|
|
# Kill the old process of slow commands if it is still running. |
|
|
|
if (( _prompt_sorin_precmd_async_pid > 0 )); then |
|
|
|
if (( _prompt_sorin_precmd_async_pid > 0 )); then |
|
|
@ -84,33 +105,33 @@ function prompt_sorin_setup { |
|
|
|
add-zsh-hook precmd prompt_sorin_precmd |
|
|
|
add-zsh-hook precmd prompt_sorin_precmd |
|
|
|
|
|
|
|
|
|
|
|
# Set editor-info parameters. |
|
|
|
# Set editor-info parameters. |
|
|
|
zstyle ':prezto:module:editor:info:completing' format '%B%F{red}...%f%b' |
|
|
|
zstyle ':prezto:module:editor:info:completing' format '%B%F{7}...%f%b' |
|
|
|
zstyle ':prezto:module:editor:info:keymap:primary' format ' %B%F{red}❯%F{yellow}❯%F{green}❯%f%b' |
|
|
|
zstyle ':prezto:module:editor:info:keymap:primary' format ' %B%F{1}❯%F{3}❯%F{2}❯%f%b' |
|
|
|
zstyle ':prezto:module:editor:info:keymap:primary:overwrite' format ' %F{red}♺%f' |
|
|
|
zstyle ':prezto:module:editor:info:keymap:primary:overwrite' format ' %F{3}♺%f' |
|
|
|
zstyle ':prezto:module:editor:info:keymap:alternate' format ' %B%F{green}❮%F{yellow}❮%F{red}❮%f%b' |
|
|
|
zstyle ':prezto:module:editor:info:keymap:alternate' format ' %B%F{2}❮%F{3}❮%F{1}❮%f%b' |
|
|
|
|
|
|
|
|
|
|
|
# Set git-info parameters. |
|
|
|
# Set git-info parameters. |
|
|
|
zstyle ':prezto:module:git:info' verbose 'yes' |
|
|
|
zstyle ':prezto:module:git:info' verbose 'yes' |
|
|
|
zstyle ':prezto:module:git:info:action' format ':%%B%F{yellow}%s%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:action' format '%F{7}:%f%%B%F{9}%s%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:added' format ' %%B%F{green}✚%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:added' format ' %%B%F{2}✚%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:ahead' format ' %%B%F{yellow}⬆%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:ahead' format ' %%B%F{13}⬆%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:behind' format ' %%B%F{yellow}⬇%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:behind' format ' %%B%F{13}⬇%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:branch' format ':%F{green}%b%f' |
|
|
|
zstyle ':prezto:module:git:info:branch' format ' %%B%F{2}%b%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:commit' format ':%F{green}%.7c%f' |
|
|
|
zstyle ':prezto:module:git:info:commit' format ' %%B%F{3}%.7c%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:deleted' format ' %%B%F{red}✖%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:deleted' format ' %%B%F{1}✖%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:modified' format ' %%B%F{blue}✱%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:modified' format ' %%B%F{4}✱%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:position' format ':%F{red}%p%f' |
|
|
|
zstyle ':prezto:module:git:info:position' format ' %%B%F{13}%p%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:renamed' format ' %%B%F{magenta}➜%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:renamed' format ' %%B%F{5}➜%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:stashed' format ' %%B%F{cyan}✭%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:stashed' format ' %%B%F{6}✭%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:unmerged' format ' %%B%F{yellow}═%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:unmerged' format ' %%B%F{3}═%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:untracked' format ' %%B%F{white}◼%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:untracked' format ' %%B%F{7}◼%f%%b' |
|
|
|
zstyle ':prezto:module:git:info:keys' format \ |
|
|
|
zstyle ':prezto:module:git:info:keys' format \ |
|
|
|
'status' '$(coalesce "%b" "%p" "%c")%s%A%B%S%a%d%m%r%U%u' |
|
|
|
'status' '$(coalesce "%b" "%p" "%c")%s%A%B%S%a%d%m%r%U%u' |
|
|
|
|
|
|
|
|
|
|
|
# Define prompts. |
|
|
|
# Define prompts. |
|
|
|
PROMPT='${SSH_TTY:+"%F{red}%n%f@%F{yellow}%m%f "}%F{cyan}${_prompt_sorin_pwd}%(!. %B%F{red}#%f%b.)${editor_info[keymap]} ' |
|
|
|
PROMPT='${SSH_TTY:+"%F{9}%n%f%F{7}@%f%F{3}%m%f "}%F{4}${_prompt_sorin_pwd}%(!. %B%F{1}#%f%b.)${editor_info[keymap]} ' |
|
|
|
RPROMPT='' |
|
|
|
RPROMPT='' |
|
|
|
SPROMPT='zsh: correct %F{red}%R%f to %F{green}%r%f [nyae]? ' |
|
|
|
SPROMPT='zsh: correct %F{1}%R%f to %F{2}%r%f [nyae]? ' |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
prompt_sorin_setup "$@" |
|
|
|
prompt_sorin_setup "$@" |
|
|
|