aboutsummaryrefslogtreecommitdiffstats
path: root/.vimrc
diff options
context:
space:
mode:
Diffstat (limited to '.vimrc')
-rw-r--r--.vimrc18
1 files changed, 11 insertions, 7 deletions
diff --git a/.vimrc b/.vimrc
index 0a4d03a..9fd3225 100644
--- a/.vimrc
+++ b/.vimrc
@@ -78,7 +78,7 @@ noremap gr gq
"insert lines below
nnoremap ++ ==
-nnoremap = Oa<C-u><Esc>j
+nnoremap = O<Esc>j
"folds!
nnoremap fo zO
@@ -118,17 +118,19 @@ end
" FILETYPE SETTINGS "
"""""""""""""""""""""""
-"always use rust instead of hercules
-au BufNewFile,BufRead *.rs set filetype=rust
-
-"always use LaTeX
-au BufNewFile,BufRead *.tex set filetype=tex
-
"annoying syntax-related values that need to be set before files are
"opened
let g:c_no_comment_fold = 1
let g:c_no_if0_fold = 1
+if has("autocmd")
+
+"always use rust instead of hercules
+autocmd BufNewFile,BufRead *.rs set filetype=rust
+
+"always use LaTeX
+autocmd BufNewFile,BufRead *.tex set filetype=tex
+
"other filetype-specific settings. i can't figure out how to stick all
"the FileTypes in one dict (mostly because i have no idea what i'm
"doing with viml), so separate lines it is.
@@ -252,3 +254,5 @@ function! Settings_vim()
"mappings
nnoremap <buffer> -- O"
endfunction
+
+endif "autocmd