Clean up prompt

This commit is contained in:
Henrik Lissner 2015-05-09 16:22:03 -04:00
parent 3c07fa6001
commit e3bec317fc

View file

@ -1,7 +1,4 @@
# Pure
# by Sindre Sorhus
# https://github.com/sindresorhus/pure
# MIT License
# Based off Pure <https://github.com/sindresorhus/pure>
# For my own and others sanity
# git:
@ -16,7 +13,6 @@
# %m => shortname host
# %(?..) => prompt conditional - %(condition.true.false)
# turns seconds into human readable time
# 165392 => 1d 21h 56m 32s
prompt_pure_human_time() {
@ -90,7 +86,7 @@ prompt_pure_precmd() {
local arrows=''
(( $(command git rev-list --right-only --count HEAD...@'{u}' 2>/dev/null) > 0 )) && arrows='⇣'
(( $(command git rev-list --left-only --count HEAD...@'{u}' 2>/dev/null) > 0 )) && arrows+='⇡'
print -Pn "\e7\e[A\e[1G\e[`prompt_pure_string_length $prompt_pure_preprompt`C%F{cyan}${arrows}%f\e8"
RPROMPT+="\e7\e[A\e[1G\e[`prompt_pure_string_length $prompt_pure_preprompt`C%F{cyan}${arrows}%f\e8"
}
} &!
@ -98,7 +94,6 @@ prompt_pure_precmd() {
unset cmd_timestamp
}
prompt_pure_setup() {
# prevent percentage showing up
# if output doesn't end with a newline