Adding .bash_profile, which on Mac OS X Lion is sourced instead of
[dotfiles] / .vimrc
diff --git a/.vimrc b/.vimrc
index b17c535..eac5995 100644 (file)
--- a/.vimrc
+++ b/.vimrc
@@ -18,6 +18,11 @@ filetype indent on
 "     autocmd filetype python set expandtab
 " endif
 
+" Allow folding.
+set foldenable
+set foldmethod=syntax
+set foldlevelstart=99
+
 " Show line numbers.
 set number
 set numberwidth=4
@@ -25,6 +30,9 @@ set numberwidth=4
 " Scroll five lines ahead of cursor.
 set scrolloff=5
 
+" Turn off error bells and visual bell
+set noeb vb t_vb=
+
 " Set up autoindentation.
 set smartindent
 filetype indent on
@@ -93,4 +101,14 @@ noremap! <Left> <Esc>
 noremap  <Right> ""
 noremap! <Right> <Esc>
 
-
+" Map open and close items in insert mode.
+" Keep this commented out until I can get it working better.
+"inoremap { {<CR>}<Esc>O
+"inoremap [ []<Esc>i
+"inoremap ( ()<Esc>i
+"inoremap } <Esc>/}<CR>o
+"inoremap ] <Esc>/]<CR>a
+"inoremap ) <Esc>/)<CR>a
+
+" Automatically reload the .vimrc when changes are made to it
+au! BufWritePost .vimrc source %