mirror of
https://github.com/SpaceVim/SpaceVim.git
synced 2025-01-23 13:00:04 +08:00
fix(git): fix git branch info
This commit is contained in:
parent
0f623af900
commit
a6e14e1cfb
@ -91,7 +91,7 @@ function! s:git_branch() abort
|
||||
endtry
|
||||
elseif exists('g:loaded_git')
|
||||
try
|
||||
let head = '%{git#branch#current()}'
|
||||
let head = git#branch#current()
|
||||
if g:spacevim_statusline_unicode == 1
|
||||
return empty(head) ? '' : ' '.head . ' ' . s:gtm_status()
|
||||
else
|
||||
|
@ -91,6 +91,9 @@ endfunction
|
||||
|
||||
function! s:on_exit_show_branch(id, data, event) abort
|
||||
let pwd = get(s:job_pwds, 'jobid' . a:id, '')
|
||||
if !has_key(s:branch_info, pwd)
|
||||
let s:branch_info[pwd] = {}
|
||||
endif
|
||||
call extend(s:branch_info[pwd], {
|
||||
\ 'last_update_done' : localtime(),
|
||||
\ })
|
||||
|
Loading…
Reference in New Issue
Block a user