Last active
October 11, 2015 15:58
-
-
Save jeffschwartz/3883484 to your computer and use it in GitHub Desktop.
My vim configuration files
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"Currently Empty |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
" | |
"pathogen settings | |
" | |
call pathogen#infect() | |
" | |
"color settings | |
" | |
set background=dark | |
"colorscheme solarized | |
color jellybeans | |
" | |
"various others | |
" | |
syntax on | |
filetype plugin indent on | |
set encoding=utf-8 | |
set tabstop=4 | |
set shiftwidth=4 | |
set expandtab | |
set gfn=Menlo\ Regular:h18 | |
set linespace=5 | |
set nowrap | |
set number | |
set hidden | |
" | |
"status line configuration | |
" - commented out because using powerline as a | |
"replacment for my own status line configuration | |
"set statusline=%t\ %y\ format:\ %{&f};\ buffer#:\ %n;\ [%c,%l,%L];\ %{fugitive#statusline()} | |
" | |
set laststatus=2 | |
let g:Powerline_symbols = 'unicode' | |
" | |
" Auto Commands | |
" | |
au BufNewFile,BufRead *.ejs set filetype=html | |
au BufNewFile,BufRead *.less set filetype=css | |
au BufWritePost *.less exe '!lessc ' . shellescape(expand('<afile>')) . ' ' . shellescape(expand('<afile>:r')) . '.css' | |
au FileType javascript set omnifunc=javascriptcomplete#CompleteJS | |
au FileType html set omnifunc=htmlcomplete#CompleteTags | |
au FileType css set omnifunc=csscomplete#CompleteCSS | |
" | |
"set indent guides size | |
" | |
let g:indent_guides_guide_size = 1 | |
" | |
"custome keyboard mappings | |
" | |
"map leader key to comma | |
let mapleader = "," | |
"map <leader>d to toggle the NERDTree | |
map <leader>d :execute 'NERDTreeToggle ' . getcwd()<CR> | |
"Run Syntastic command SyntasticCheck to lint file | |
map <leader>s :execute 'SyntasticCheck '<CR> | |
"Run Syntastic command Errors to display error window at bottom | |
map <leader>e :execute 'Errors '<CR> | |
inoremap <C-Space> <C-x><C-o> | |
nnoremap <silent> <C-l> :nohlsearch<CR><C-l> | |
nnoremap ; : | |
inoremap ( ()<Left> | |
inoremap <expr> ) strpart(getline('.'), col('.')-1, 1) == ")" ? "\<Right>" : ")" | |
inoremap { {}<Left> | |
inoremap {<CR> {<CR>}<Esc>O | |
inoremap {{ { | |
inoremap {} {} | |
" toggle wrap | |
map <leader>w :set wrap!<CR> | |
" use jj for esc in insert mode | |
imap jj <esc> | |
" | |
" search configurations | |
" | |
"search with ignore case | |
set ignorecase | |
"search with smart case - aAAaaa will use case sensitive search, aaaaa with case insensitive search | |
set smartcase |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment