Fix scope problems
This commit is contained in:
parent
fdc4d9ccae
commit
0e14d4b93c
1 changed files with 10 additions and 8 deletions
18
functions
18
functions
|
@ -5,14 +5,6 @@
|
|||
################################################################################
|
||||
|
||||
|
||||
local ZSH_THEME_GIT_PROMPT_PREFIX="%{$fg_bold[green]%}[%{$fg_bold[blue]%}"
|
||||
local ZSH_THEME_GIT_PROMPT_SUFFIX="%{$fg_bold[green]%}]"
|
||||
local ZSH_THEME_GIT_PROMPT_CLEAN="%{$fg_no_bold[green]%}✓"
|
||||
local ZSH_THEME_GIT_PROMPT_AHEAD="%{$fg_no_bold[cyan]%}▴"
|
||||
local ZSH_THEME_GIT_PROMPT_BEHIND="%{$fg_no_bold[magenta]%}▾"
|
||||
local ZSH_THEME_GIT_PROMPT_STAGED="%{$fg_no_bold[green]%}●"
|
||||
local ZSH_THEME_GIT_PROMPT_UNSTAGED="%{$fg_no_bold[yellow]%}●"
|
||||
local ZSH_THEME_GIT_PROMPT_UNTRACKED="%{$fg_no_bold[red]%}●"
|
||||
|
||||
local ZSH_THEME_VIRTUALENV_PREFIX=" %{$fg_bold[green]%}(%{%b$fg[green]%}"
|
||||
local ZSH_THEME_VIRTUALENV_SUFFIX="%{$reset_color$fg_bold[green]%})%{$reset_color%}"
|
||||
|
@ -114,6 +106,13 @@ space_sh_git_branch () {
|
|||
}
|
||||
|
||||
space_sh_git_status () {
|
||||
local ZSH_THEME_GIT_PROMPT_CLEAN="%{$fg_no_bold[green]%}✓"
|
||||
local ZSH_THEME_GIT_PROMPT_AHEAD="%{$fg_no_bold[cyan]%}▴"
|
||||
local ZSH_THEME_GIT_PROMPT_BEHIND="%{$fg_no_bold[magenta]%}▾"
|
||||
local ZSH_THEME_GIT_PROMPT_STAGED="%{$fg_no_bold[green]%}●"
|
||||
local ZSH_THEME_GIT_PROMPT_UNSTAGED="%{$fg_no_bold[yellow]%}●"
|
||||
local ZSH_THEME_GIT_PROMPT_UNTRACKED="%{$fg_no_bold[red]%}●"
|
||||
|
||||
_INDEX=$(command git status --porcelain -b 2> /dev/null)
|
||||
local _STATUS=""
|
||||
if $(echo "$_INDEX" | grep '^[AMRD]. ' &> /dev/null); then
|
||||
|
@ -144,6 +143,9 @@ space_sh_git_status () {
|
|||
}
|
||||
|
||||
space_sh_git_prompt () {
|
||||
local ZSH_THEME_GIT_PROMPT_PREFIX="%{$fg_bold[green]%}[%{$fg_bold[blue]%}"
|
||||
local ZSH_THEME_GIT_PROMPT_SUFFIX="%{$fg_bold[green]%}]"
|
||||
|
||||
local _branch=$(space_sh_git_branch)
|
||||
local _result=""
|
||||
if [[ "${_branch}x" != "x" ]]; then
|
||||
|
|
Loading…
Reference in a new issue