カレントディレクトリが Git リポジトリ内にある場合,そのリポジトリのルートを VimFiler で開くコマンドを
.vimrc に次のように書けば OK です.
function! s:git_root_dir() if(system('git rev-parse --is-inside-work-tree') == "true\n") return ':VimFiler ' . system('git rev-parse --show-cdup') . '\<CR>' else echoerr '!!!current directory is outside git working tree!!!' endif endfunction nnoremap <expr><Leader>fg <SID>git_root_dir()