vpetro / vim-config (http://petro.tanrei.ca/)

Vim configuration files

Clone this repository (size: 833.8 KB): HTTPS / SSH
$ hg clone http://bitbucket.org/vpetro/vim-config/

Changed (Δ338 bytes):

raw changeset »

dot.vimrc (49 lines added, 59 lines removed)

Up to file-list dot.vimrc:

@@ -42,6 +42,11 @@ set nowrap
42
42
43
43
" turn on the folding
44
44
"set foldmethod=indent
45
"
46
47
" set up the nice command matching
48
set wildmenu
49
set wildmode=longest,list
45
50
46
51
" turn off the toolbar and menubar
47
52
if has('gui')
@@ -62,7 +67,7 @@ end
62
67
" set the directory for .swp files so that they 
63
68
" dont appear in the current directory of the file being
64
69
" edited
65
set dir=/home/petrov/.tmp
70
set dir=/Users/petrov/.tmp
66
71
67
72
" show the line numbers by default
68
73
set number
@@ -149,12 +154,8 @@ map <leader>v :sp /Users/petrov/.vimrc<c
149
154
map <leader>V :source /Users/petrov/.vimrc<cr>
150
155
151
156
" Taglist 
152
let Tlist_Ctags_Cmd='/opt/local/bin/ctags'
157
let Tlist_Ctags_Cmd="/opt/local/bin/ctags"
153
158
154
" minifubexplorer
155
"let g:miniBufExplMapWindowNavVim=1
156
"let g:miniBufExplCTabSwitchBufs=1
157
"let g:miniBufExplMapWindowNavVim=1
158
159
159
160
160
161
" put the search result in the middle of the screen
@@ -167,57 +168,33 @@ nmap g# g#zz
167
168
168
169
set listchars=tab:>-,trail:-
169
170
170
au BufRead,BufNewFile *.scala set filetype=scala
171
autocmd FileType py set efm=%f:%l:%m
172
173
"set grepprg='grep\ -nH\ $*'
174
"set the default output to pdf
175
"let g:Tex_DefaultTargetFormat='pdf'
176
 "set the execution string that will be used to compile the tex source into LaTeX. "S*" is replaced with the filename of the main tex file
177
"let g:Tex_CompileRule_pdf='pdflatex -file-line-error-style -interaction=nonstopmode $*'
178
 "set the execution string that will be used to view the pdf output
179
"let g:Tex_ViewRuleComplete_pdf='/usr/bin/open -a /Applications/Skim.app $*.pdf &'
180
" my settings
181
let g:Tex_TreatMacViewerAsUNIX = 1
182
let g:Tex_ExecuteUNIXViewerInForeground = 1
183
let g:Tex_ViewRule_ps = 'skim'
184
let g:Tex_ViewRule_pdf = 'skim'
185
let g:Tex_ViewRule_dvi = 'texniscope'
186
let g:Tex_GotoError=0
187
"end of my settings
188
"let g:Tex_DefaultTargetFormat = 'pdf'
189
"let g:Tex_CompileRule_dvi = 'latex --interaction=nonstopmode $*'
190
"let g:Tex_CompileRule_ps = 'dvips -Pwww -o $*.ps $*.dvi'
191
"let g:Tex_CompileRule_pspdf = 'ps2pdf $*.ps'
192
"let g:Tex_CompileRule_dvipdf = 'dvipdfm $*.dvi'
193
"let g:Tex_CompileRule_pdf = 'pdflatex $*'
171
set grepprg='grep\ -nH\ $*'
172
let g:Tex_DefaultTargetFormat = 'pdf'
173
let g:Tex_CompileRule_dvi = 'latex --interaction=nonstopmode $*'
174
let g:Tex_CompileRule_ps = 'dvips -Pwww -o $*.ps $*.dvi'
175
let g:Tex_CompileRule_pspdf = 'ps2pdf $*.ps'
176
let g:Tex_CompileRule_dvipdf = 'dvipdfm $*.dvi'
177
let g:Tex_CompileRule_pdf = 'pdflatex $*'
178
"we dont do dvi :)
194
179
"let g:Tex_ViewRule_dvi = 'texniscope'
195
"let g:Tex_ViewRule_ps = 'Preview'
196
"let g:Tex_ViewRule_pdf = 'Skim'
197
"let g:Tex_FormatDependency_ps  = 'dvi,ps'
198
"let g:Tex_FormatDependency_pspdf = 'dvi,ps,pspdf'
199
"let g:Tex_FormatDependency_dvipdf = 'dvi,dvipdf'
200
201
"let g:Tex_IgnoredWarnings ='
202
       "\"Underfull\n".
203
       "\"Overfull\n".
204
       "\"specifier changed to\n".
205
       "\"You have requested\n".
206
       "\"Missing number, treated as zero.\n".
207
       "\"There were undefined references\n".
208
       "\"Citation %.%# undefined\n".
209
       "\"\oval, \circle, or \line size unavailable\n"' 
210
211
212
213
" Python imaps
214
215
au FileType python inoremap <buffer> $r return<space>
216
au FileType python inoremap <buffer> $s self
217
au FileType python inoremap <buffer> $c ##<cr>#<space><cr>#<esc>kla
218
au FileType python inoremap <buffer> $i import<space>
219
au FileType python inoremap <buffer> $p print<space>
220
au FileType python inoremap <buffer> $d """<cr>"""<esc>O
180
let g:Tex_ViewRule_ps = 'Preview'
181
let g:Tex_ViewRule_pdf = 'Skim'
182
let g:Tex_FormatDependency_ps  = 'dvi,ps'
183
let g:Tex_FormatDependency_pspdf = 'dvi,ps,pspdf'
184
let g:Tex_FormatDependency_dvipdf = 'dvi,dvipdf'
185
" if the line below is not set then it will not compile 
186
" bibtex for pdf. It will only do it for dvi.
187
" As stated above, we dont do dvi. : )
188
"let g:Tex_MultipleCompileFormats = "pdf"
189
let g:Tex_IgnoredWarnings ='
190
       \"Underfull\n".
191
       \"Overfull\n".
192
       \"specifier changed to\n".
193
       \"You have requested\n".
194
       \"Missing number, treated as zero.\n".
195
       \"There were undefined references\n".
196
       \"Citation %.%# undefined\n".
197
       \"\oval, \circle, or \line size unavailable\n"' 
221
198
222
199
223
200
" Run the current buffer through python
@@ -231,12 +208,25 @@ function! Python_Eval_VSplit() range
231
208
 execute ":!python " . src . " > " . dst
232
209
 execute ":pedit! " . dst
233
210
endfunction
211
234
212
au FileType python vmap <F7> :call Python_Eval_VSplit()<cr>
235
213
236
237
214
" markdown stuff
238
215
augroup mkd
239
216
    autocmd BufRead *.mkd set ai formatoptions=tcroqn2 comments=n:>
240
217
augroup END
218
au FileType mkd map <buffer> <leader><space> :w!<cr>:!markdown %<cr>
241
219
242
au FileType mkd map <buffer> <leader><space> :w!<cr>:!markdown %<cr>
220
" turn on autocompletion for python and others
221
autocmd FileType python set omnifunc=pythoncomplete#Complete
222
autocmd FileType javascript set omnifunc=javascriptcomplete#CompleteJS
223
autocmd FileType html set omnifunc=htmlcomplete#CompleteTags
224
autocmd FileType css set omnifunc=csscomplete#CompleteCSS
225
autocmd FileType xml set omnifunc=xmlcomplete#CompleteTags
226
autocmd FileType php set omnifunc=phpcomplete#CompletePHP
227
autocmd FileType c set omnifunc=ccomplete#Complete
228
229
" haskell mode configuration
230
au BufEnter *.hs compiler ghc
231
let g:haddock_browser = "/Applications/Firefox.app"
232
let g:haddock_docdir = "/opt/local/share/ghc-6.10.1/"