From: Simon Ruderich Date: Thu, 15 Nov 2012 16:59:04 +0000 (+0100) Subject: vimrc: Add FSWitch settings. X-Git-Url: https://ruderich.org/simon/gitweb/?a=commitdiff_plain;h=134f3aca5c54cf8e44f2e7c110ece7b8a6fce798;p=config%2Fdotfiles.git vimrc: Add FSWitch settings. --- diff --git a/vimrc b/vimrc index b537d17..8922942 100644 --- a/vimrc +++ b/vimrc @@ -808,6 +808,18 @@ if has('eval') let g:ctrlp_cache_dir = $HOME . '/.vim/cache/ctrlp' " Permanent cache, cleared by a crontab entry. let g:ctrlp_clear_cache_on_exit = 0 + +" FSWitch settings. + " Default don't work well for my projects. + augroup vimrc + autocmd BufEnter *.cc let b:fswitchdst = 'h' + \ | let b:fswitchlocs = './' + autocmd BufEnter *.h let b:fswitchdst = 'cc,c' + \ | let b:fswitchlocs = './' + augroup END + + " Switch to corresponding header/source file. + nnoremap h :FSHere endif