Plug 'vim-scripts/mediawiki.vim'
Plug 'vim-scripts/replacewithregister'
Plug 'vim-scripts/yankring.vim'
+Plug 'wincent/loupe'
" colorschemes
Plug 'morhetz/gruvbox'
Plug 'kana/vim-operator-user'
" staging
-" find an alternative (latex-box? Automatic Latex Plugin?)
-Plug 'vim-latex/vim-latex'
-Plug 'alx741/vinfo'
-" needs editing colorscheme
-" Plug 'jeaye/color_coded'
" Check LucHermites plugins: https://github.com/LucHermitte/lh-cpp
-Plug 'wincent/loupe'
call plug#end()
map <space> <leader>
" make
-nnoremap <leader>r :make!<cr>
-nnoremap <leader><cr> :make!<cr>
+function! Make()
+ let l:make_dir = ""
+ if exists("b:make_dir")
+ let l:make_dir = "-C ".b:make_dir
+ elseif exists("g:make_dir")
+ let l:make_dir = "-C ".g:make_dir
+ endif
+
+ let l:make_targets = ""
+ if exists("g:make_targets")
+ let l:make_targets = g:make_targets
+ endif
+ execute "make! ".l:make_dir." ".l:make_targets
+endf
+nnoremap <leader>r :call Make()<cr>
" unhighlight search
nnoremap <silent> <Leader>/ :silent nohl<CR>
" vim-json {{{2
let g:vim_json_syntax_conceal = 0
-" vim-latex {{{2
-let g:tex_flavor='latex'
-let g:Tex_DefaultTargetFormat='pdf'
-let g:Tex_MultipleCompileFormats='pdf'
-
" vim-sneak {{{2
let g:sneak#streak = 1
let g:sneak#target_labels = "aoeuisnthdpylrcgfqjkxzmwvz" " dvorak