mirror of
https://github.com/NaomiAmethyst/dots.git
synced 2025-08-05 16:48:38 +00:00
Fix.
This commit is contained in:
parent
3278ecbdab
commit
6c53fa777e
1 changed files with 2 additions and 2 deletions
|
@ -143,12 +143,12 @@ function updateprompt () {
|
||||||
if [[ -n ${remote} ]] ; then
|
if [[ -n ${remote} ]] ; then
|
||||||
# for git prior to 1.7
|
# for git prior to 1.7
|
||||||
# ahead=$(git rev-list origin/${hook_com[branch]}..HEAD | wc -l)
|
# ahead=$(git rev-list origin/${hook_com[branch]}..HEAD | wc -l)
|
||||||
local ahead=$(git rev-list ${branch}@{upstream}..HEAD 2>/dev/null | wc -l)
|
local ahead="$(git rev-list ${branch}@{upstream}..HEAD 2>/dev/null | wc -l)"
|
||||||
gitstatus+=( "${GREEN}+${ahead}${GRAY}" )
|
gitstatus+=( "${GREEN}+${ahead}${GRAY}" )
|
||||||
|
|
||||||
# for git prior to 1.7
|
# for git prior to 1.7
|
||||||
# behind=$(git rev-list HEAD..origin/${hook_com[branch]} | wc -l)
|
# behind=$(git rev-list HEAD..origin/${hook_com[branch]} | wc -l)
|
||||||
local behind=$(git rev-list HEAD..${branch}@{upstream} 2>/dev/null | wc -l)
|
local behind="$(git rev-list HEAD..${branch}@{upstream} 2>/dev/null | wc -l)"
|
||||||
gitstatus+=( "${RED}-${behind}${GRAY}" )
|
gitstatus+=( "${RED}-${behind}${GRAY}" )
|
||||||
|
|
||||||
remotepart="${RESETCOLOR}${GRAY}[${remote} ${(j:/:)gitstatus}]${RESETCOLOR}"
|
remotepart="${RESETCOLOR}${GRAY}[${remote} ${(j:/:)gitstatus}]${RESETCOLOR}"
|
||||||
|
|
Loading…
Add table
Reference in a new issue