set nocompatible syntax enable colors bluegreen set autoread filetype plugin on " commenting command! -range -bar -nargs=0 LC ,s/^/;; / command! -range -bar -nargs=0 LUC ,s/^;; // " lower case command! -range -bar -nargs=0 LOWER ,s/[A-Z]/\L&/g " upper case command! -range -bar -nargs=0 UPPER ,s/[a-z]/\U&/g " some common strings command -nargs=0 DASHES normal i;; ----------------------------------------------- command -nargs=0 DASHED normal i;; - - - - - - - - - - - - - - - - - - - - - - - - command -nargs=0 BANNER normal i;; -----------------------------------------------;; -----------------------------------------------;; ----------------------------------------------- command -nargs=0 TEMPORARY normal i;; TEMPORARY >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>;; <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< " autosource ~/.vimrc after writing " http://vim.wikia.com/wiki/Change_vimrc_with_auto_reload " autocmd! bufwritepost .vimrc source % " folding set foldmethod=marker " hang fix set swapsync= set nofsync " tab over settings set softtabstop=4 set expandtab set shiftwidth=4 set ai set laststatus=2 " .lisp gets 2 spaces au BufRead,BufNewFile *.lisp setlocal softtabstop=2 shiftwidth=2 " paste toggle map :set paste map :set nopaste imap :set paste imap set pastetoggle= " ctrl-h : sets highlighted words to normal noremap :nohls " ctrl-n/p : next and previous buffers noremap :next noremap :prev " resize the vertical split easlier noremap :vertical resize -2 noremap :vertical resize +2 " page up and page down noremap noremap - " virtual lines nmap j gj nmap k gk noremap gk noremap gj " yank and drop across multiple vim instances set clipboard=unnamed " make backspace key work set bs=2 " use mouse, ruler, hightlight search set mouse=a set ruler set hlsearch autocmd BufEnter *.php setlocal indentexpr= " wildmenu for better :b tabbing set wildmenu set wildchar= " omnicomplete autocmd FileType lisp set omnifunc=lispcomplete#Complete " Arduino syntax highlighting au BufNewFile,BufRead *.pde setf arduino