2016-01-19 15:10:51 -06:00
|
|
|
|
execute pathogen#infect()
|
|
|
|
|
set ruler
|
|
|
|
|
set autoindent
|
2016-02-02 09:43:04 -06:00
|
|
|
|
set tabstop=2
|
|
|
|
|
set shiftwidth=2
|
2016-01-19 15:10:51 -06:00
|
|
|
|
set expandtab
|
|
|
|
|
syntax enable
|
|
|
|
|
set number
|
|
|
|
|
set hlsearch
|
|
|
|
|
set incsearch
|
|
|
|
|
set autochdir
|
|
|
|
|
set textwidth=79
|
|
|
|
|
|
2017-05-10 10:00:07 -05:00
|
|
|
|
"set guifont=SimplexMono\ Light\ Condensed\ 10
|
|
|
|
|
set guifont=Terminus
|
2016-01-19 15:10:51 -06:00
|
|
|
|
filetype plugin on
|
|
|
|
|
filetype indent on
|
|
|
|
|
|
|
|
|
|
highlight Folded term=standout ctermfg=5 ctermbg=0
|
|
|
|
|
|
|
|
|
|
let mapleader=" "
|
|
|
|
|
|
|
|
|
|
autocmd BufRead *.java set makeprg=ant
|
|
|
|
|
autocmd BufRead *.java set efm=%A\ %#[javac]\ %f:%l:\ %m,%-Z\ %#[javac]\ %p^,%-C%.%#
|
|
|
|
|
|
|
|
|
|
"source ~/.vim/.jdb_java.vim
|
|
|
|
|
|
2017-05-10 10:00:07 -05:00
|
|
|
|
autocmd BufRead /tmp/psql.edit.* set syntax=sql
|
2016-01-30 20:54:28 -06:00
|
|
|
|
autocmd BufRead,BufNewFile *.md setlocal filetype=markdown
|
|
|
|
|
autocmd BufEnter *.* silent loadview
|
|
|
|
|
autocmd BufLeave *.* mkview!
|
2016-01-19 15:10:51 -06:00
|
|
|
|
|
|
|
|
|
autocmd BufRead *.java set foldnestmax=2
|
|
|
|
|
autocmd BufRead *.java set foldmethod=syntax
|
|
|
|
|
|
|
|
|
|
inoremap <Nul> <C-x><C-o>
|
|
|
|
|
|
|
|
|
|
" Search for selected text, forwards or backwards.
|
|
|
|
|
vnoremap <silent> * :<C-U>
|
|
|
|
|
\let old_reg=getreg('"')<Bar>let old_regtype=getregtype('"')<CR>
|
|
|
|
|
\gvy/<C-R><C-R>=substitute(
|
|
|
|
|
\escape(@", '/\.*$^~['), '\_s\+', '\\_s\\+', 'g')<CR><CR>
|
|
|
|
|
\gV:call setreg('"', old_reg, old_regtype)<CR>
|
|
|
|
|
vnoremap <silent> # :<C-U>
|
|
|
|
|
\let old_reg=getreg('"')<Bar>let old_regtype=getregtype('"')<CR>
|
|
|
|
|
\gvy?<C-R><C-R>=substitute(
|
|
|
|
|
\escape(@", '?\.*$^~['), '\_s\+', '\\_s\\+', 'g')<CR><CR>
|
|
|
|
|
\gV:call setreg('"', old_reg, old_regtype)<CR>
|
|
|
|
|
|
|
|
|
|
"Highlight lines past 80 characters long
|
|
|
|
|
"highlight OverLength ctermbg=red ctermfg=white guibg=#592929
|
|
|
|
|
"match OverLength /\%80v.\+/
|
|
|
|
|
"autocmd BufAdd .* match OverLength /\%80v.\+/
|
|
|
|
|
|
|
|
|
|
let g:solarized_contrast="high"
|
|
|
|
|
let g:ctrlp_max_files = 0
|
|
|
|
|
let g:ctrlp_custom_ignore = {
|
2017-05-10 10:00:07 -05:00
|
|
|
|
\ 'dir': '\v\.git$|\.hg$|\.svn$|build$|target$|node_modules$|nimcache$',
|
2016-01-19 15:10:51 -06:00
|
|
|
|
\ 'file': '\v\.(class|exe|so|dll|sw.)$'
|
|
|
|
|
\ }
|
|
|
|
|
|
|
|
|
|
let groovy_space_errors = 1
|
|
|
|
|
let groovy_allow_cpp_keywords = 1
|
|
|
|
|
|
|
|
|
|
" Generate Java Getter and Setter for one property.
|
|
|
|
|
" Expects property lines to match /private \w\+ \w\+/
|
|
|
|
|
" Requires mark A to be set at the current property line start and mark B to
|
|
|
|
|
" be set where the getter and setter should be inserted. The marks are updated
|
|
|
|
|
" so that the command can be immediately invoked again for a subsequent
|
|
|
|
|
" property.
|
|
|
|
|
" nmap <Leader>gs wve"tywve"py'bo
public void set "ppbvUhxA("tpA "ppA) {
this."ppA = "ppA;
}
public "tpA get "ppbvUhxA() {
return this."ppA;
}mb'a/private \w+\+ \w\+;
ma
|
|
|
|
|
nmap <Leader>jgs :let @t=''<CR>:let @n=''<CR>'a0v$:s/\v^\s*(private\|public\|protected)? ?(\w+(\<[^>]+\>)?) (\w+);/\=setreg('T', submatch(2))/n<CR>0v$:s/\v^\s*(private\|public\|protected)? ?(\w+(\<[^>]+\>)?) (\w+);/\=setreg('N', submatch(4))/n<CR>'bo<CR>public <ESC>"tpA get <ESC>"npbvUhxA() {<CR> return this.<ESC>"npA;<CR>}<ESC><<o<CR>public void set <ESC>"npbvUhxA(<ESC>"tpA <ESC>"npA) {<CR> this.<ESC>"npA = <ESC>"npA;<CR>}<ESC><<mb'anma
|
|
|
|
|
|
2017-06-28 14:05:43 -05:00
|
|
|
|
" Clean un-used Java imports.
|
|
|
|
|
nmap <Leader>jci :UnusedImportsRemove<CR>
|
2016-01-19 15:10:51 -06:00
|
|
|
|
|
|
|
|
|
" Format the file using java-file-formatter. java-file-formatter should be a
|
|
|
|
|
" command that takes a file path as the first argument and either alters the
|
|
|
|
|
" file in place or prints out the altered file on STDOUT.
|
|
|
|
|
nmap <Leader>jsf :!java-file-formatter %:p<CR>
|
|
|
|
|
|
|
|
|
|
nmap <Leader>wo :vsplit /home/jdbernard/projects/worklog/worklog.txt<CR><C-w>L200<C-w><43<C-w>>
|
|
|
|
|
nmap <Leader>ws :w<CR>:silent !git add %<CR>:!git commit<CR>
|
2017-05-10 10:00:07 -05:00
|
|
|
|
|
|
|
|
|
nmap <Leader>b :CtrlPBuffer<CR>
|