# HG changeset patch # User "Mathieu Clabaut " # Date 1152741133 -7200 # Node ID 5cef1a92aa04e1b3db135354de1583e6262481a7 # Parent 4ad79eeebf965f4157e422474d01b13b02403173 HGcommand.vim : HGGetStatusLine accept to display an empty 'branch' value diff -r 4ad79eeebf96 -r 5cef1a92aa04 contrib/vim/hgcommand.vim --- a/contrib/vim/hgcommand.vim Wed Jul 12 23:52:13 2006 +0200 +++ b/contrib/vim/hgcommand.vim Wed Jul 12 23:52:13 2006 +0200 @@ -635,13 +635,16 @@ if exists('b:HGRevision') \ && b:HGRevision != '' - \ && exists('b:HGBranch') - \ && b:HGBranch != '' \ && exists('b:HGRepository') \ && b:HGRepository != '' \ && exists('g:HGCommandEnableBufferSetup') \ && g:HGCommandEnableBufferSetup - return '[HG ' . b:HGRepository . '/' . b:HGBranch .'/' . b:HGRevision . ']' + if !exists('b:HGBranch') + let l:branch='' + else + let l:branch=b:HGBranch + endif + return '[HG ' . b:HGRepository . '/' . l:branch .'/' . b:HGRevision . ']' else return '' endif