Break up config, add other improvements.
This commit is contained in:
parent
73c84169ff
commit
a606022dd6
14 changed files with 114 additions and 133 deletions
16
ftplugin/java.vim
Normal file
16
ftplugin/java.vim
Normal file
|
@ -0,0 +1,16 @@
|
|||
let g:JavaImpDataDir = $HOME . "/.vim/JavaImp"
|
||||
|
||||
" F7 to call clean redundant Java imports and sort them
|
||||
function JavaImpClean()
|
||||
%!~/bin/clean_imports.sh %
|
||||
:JavaImpSort
|
||||
endfunction
|
||||
:command JavaImpClean exec JavaImpClean()
|
||||
:nnoremap <F7> :JavaImpClean<CR>
|
||||
|
||||
"let makeprg = 'java -cp /opt/boxen/homebrew/opt/checkstyle/libexec/checkstyle-6.0-all.jar -c '. vimrc_git . '/checkstyle.xml %:p'
|
||||
let makeprg = 'checkstyle -c '. vimrc_git . '/checkstyle.xml ./%'
|
||||
|
||||
let &makeprg=escape(makeprg, ' ')
|
||||
setlocal errorformat=%f:%l:\ %m,%f:%l:%v:\ %m,%-G%.%#
|
||||
|
2
ftplugin/javascript.vim
Normal file
2
ftplugin/javascript.vim
Normal file
|
@ -0,0 +1,2 @@
|
|||
setlocal fdm=indent
|
||||
setlocal smartindent
|
8
ftplugin/markdown.vim
Normal file
8
ftplugin/markdown.vim
Normal file
|
@ -0,0 +1,8 @@
|
|||
" set a smaller indent
|
||||
setlocal ts=2
|
||||
|
||||
" and set up the buffer just like a text file
|
||||
let oldwd = getcwd()
|
||||
exec "cd ~/.vim/ftplugin"
|
||||
source text.vim
|
||||
exec "cd " . oldwd
|
22
ftplugin/text.vim
Normal file
22
ftplugin/text.vim
Normal file
|
@ -0,0 +1,22 @@
|
|||
" don't hard break text
|
||||
setlocal tw=0
|
||||
" keep soft breaks between words
|
||||
setlocal linebreak
|
||||
" turn list off as it interferes with soft wrapping
|
||||
setlocal nolist!
|
||||
" turn off breaking when typing new text
|
||||
setlocal formatoptions-=t
|
||||
" turn off line width hint
|
||||
setlocal colorcolumn=0
|
||||
|
||||
" narrow width for gui since text will softwrap based on width
|
||||
if has("gui_running")
|
||||
" narrow the gui window for text wrangling
|
||||
setlocal columns=120
|
||||
endif
|
||||
|
||||
" open full screen with macvim
|
||||
if has("gui_macvim")
|
||||
set fuoptions=maxvert,maxhorz
|
||||
au GUIEnter * set fullscreen
|
||||
endif
|
Loading…
Add table
Add a link
Reference in a new issue