From d4e2bfe8923f46a2c05e52d8427c743e447f0ded Mon Sep 17 00:00:00 2001 From: kazukazuinaina Date: Sun, 15 Dec 2019 23:08:31 +0900 Subject: [PATCH] add try catch in gina.vim's extension in branch.vim --- autoload/airline/extensions/branch.vim | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/autoload/airline/extensions/branch.vim b/autoload/airline/extensions/branch.vim index be463175..344ebef9 100644 --- a/autoload/airline/extensions/branch.vim +++ b/autoload/airline/extensions/branch.vim @@ -98,8 +98,11 @@ function! s:update_git_branch() let s:vcs_config['git'].branch='mas' endif else - let g:gina#component#repo#commit_length = s:sha1size - let s:vcs_config['git'].branch = gina#component#repo#branch() + try + let g:gina#component#repo#commit_length = s:sha1size + let s:vcs_config['git'].branch = gina#component#repo#branch() + catch + endtry if s:vcs_config['git'].branch is# 'master' && \ airline#util#winwidth() < 81 " Shorten default a bit