|
@@ -2,16 +2,25 @@
|
|
|
|
|
|
PROMPT='
|
|
|
$(_user_host)${_current_dir} $(git_prompt_info) $(_ruby_version)
|
|
|
-▶ '
|
|
|
+%{$fg[$CARETCOLOR]%}▶%{$resetcolor%} '
|
|
|
|
|
|
-PROMPT2='%{$fg[grey]%}◀%{$reset_color%} '
|
|
|
+PROMPT2='%{$fg[$CARETCOLOR]%}◀%{$reset_color%} '
|
|
|
|
|
|
RPROMPT='$(_vi_status)%{$(echotc UP 1)%}$(_git_time_since_commit) $(git_prompt_status) ${_return_status}%{$(echotc DO 1)%}'
|
|
|
|
|
|
-local _current_dir="%{$fg[blue]%}%3~%{$reset_color%} "
|
|
|
-local _return_status="%{$fg[red]%}%(?..⍉)%{$reset_color%}"
|
|
|
+local _current_dir="%{$fg_bold[blue]%}%3~%{$reset_color%} "
|
|
|
+local _return_status="%{$fg_bold[red]%}%(?..⍉)%{$reset_color%}"
|
|
|
local _hist_no="%{$fg[grey]%}%h%{$reset_color%}"
|
|
|
|
|
|
+function _current_dir() {
|
|
|
+ local _max_pwd_length="65"
|
|
|
+ if [[ $(echo -n $PWD | wc -c) -gt ${_max_pwd_length} ]]; then
|
|
|
+ echo "%{$fg_bold[blue]%}%-2~ ... %3~%{$reset_color%} "
|
|
|
+ else
|
|
|
+ echo "%{$fg_bold[blue]%}%~%{$reset_color%} "
|
|
|
+ fi
|
|
|
+}
|
|
|
+
|
|
|
function _user_host() {
|
|
|
if [[ -n $SSH_CONNECTION ]]; then
|
|
|
me="%n@%m"
|
|
@@ -85,13 +94,13 @@ ZSH_THEME_GIT_PROMPT_MODIFIED="%{$fg[yellow]%}⚑ "
|
|
|
ZSH_THEME_GIT_PROMPT_DELETED="%{$fg[red]%}✖ "
|
|
|
ZSH_THEME_GIT_PROMPT_RENAMED="%{$fg[blue]%}▴ "
|
|
|
ZSH_THEME_GIT_PROMPT_UNMERGED="%{$fg[cyan]%}§ "
|
|
|
-ZSH_THEME_GIT_PROMPT_UNTRACKED="%{$fg[grey]%}◒ "
|
|
|
+ZSH_THEME_GIT_PROMPT_UNTRACKED="%{$fg[white]%}◒ "
|
|
|
|
|
|
# Colors vary depending on time lapsed.
|
|
|
ZSH_THEME_GIT_TIME_SINCE_COMMIT_SHORT="%{$fg[green]%}"
|
|
|
ZSH_THEME_GIT_TIME_SHORT_COMMIT_MEDIUM="%{$fg[yellow]%}"
|
|
|
ZSH_THEME_GIT_TIME_SINCE_COMMIT_LONG="%{$fg[red]%}"
|
|
|
-ZSH_THEME_GIT_TIME_SINCE_COMMIT_NEUTRAL="%{$fg[grey]%}"
|
|
|
+ZSH_THEME_GIT_TIME_SINCE_COMMIT_NEUTRAL="%{$fg[white]%}"
|
|
|
|
|
|
# LS colors, made with http://geoff.greer.fm/lscolors/
|
|
|
export LSCOLORS="exfxcxdxbxegedabagacad"
|