diff --git a/plugin/stdheader.vim b/plugin/stdheader.vim index da78555..dd0f02e 100644 --- a/plugin/stdheader.vim +++ b/plugin/stdheader.vim @@ -129,9 +129,13 @@ function! s:update() call s:filetype() if getline(9) =~ s:start . repeat(' ', s:margin - strlen(s:start)) . "Updated: " if &mod - call setline(9, s:line(9)) + if s:not_rebasing() + call setline(9, s:line(9)) + endif + endif + if s:not_rebasing() + call setline(4, s:line(4)) endif - call setline(4, s:line(4)) return 0 endif return 1 @@ -143,6 +147,13 @@ function! s:stdheader() endif endfunction +function! s:not_rebasing() + if system("ls `git rev-parse --git-dir 2>/dev/null` | grep rebase | wc -l") + return 0 + endif + return 1 +endfunction + " Bind command and shortcut command! Stdheader call s:stdheader () map :Stdheader