Browse files

Fixed the path to .git directory. git rev-parse --git-dir does not ad…

…d the trailing "/"
  • Loading branch information...
1 parent 73a1817 commit 44215060718249449d59e1b59524817cf2d102db @amjith amjith committed May 20, 2009
Showing with 2 additions and 2 deletions.
  1. +2 −2 plugin/git.vim
View
4 plugin/git.vim
@@ -43,8 +43,8 @@ endfunction
function! GitBranch()
let git_dir = <SID>GetGitDir()
- if strlen(git_dir) && filereadable(git_dir . 'HEAD')
- let lines = readfile(git_dir . 'HEAD')
+ if strlen(git_dir) && filereadable(git_dir . '/HEAD')
+ let lines = readfile(git_dir . '/HEAD')
return len(lines) ? matchstr(lines[0], '[^/]*$') : ''
else
return ''

0 comments on commit 4421506

Please sign in to comment.