Last active
January 2, 2016 05:49
-
-
Save tbonemalone/8259225 to your computer and use it in GitHub Desktop.
Local vim setting for use with [Maximum Awesome](https://github.com/square/maximum-awesome)
This file contains hidden or 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
set nocursorline " don't highlight current line | |
set hlsearch "hilight search matches | |
set shiftround " When at 3 spaces and hit >> go to 4 not 5 | |
"Press space to toggle highlight on/off, and show current value | |
nnoremap <Space> :set hlsearch! hlsearch?<CR> | |
"Switch between the last two files | |
nnoremap <leader><leader> <c-^> | |
"Windows and splits | |
" Open new vertical split | |
nnoremap <leader>w <C-w>v<C-w>l | |
" keyboard shortcuts | |
inoremap jj <ESC> | |
" NOTE: Don't forget to add Bundle 'bling/vim-airline' to .vimrc.bundles.local | |
" fonts for vim-airline | |
if !exists('g:airline_symbols') | |
let g:airline_symbols = {} | |
endif | |
" use old vim-powerline symbols | |
let g:airline_left_sep = '⮀' | |
let g:airline_left_alt_sep = '⮁' | |
let g:airline_right_sep = '⮂' | |
let g:airline_right_alt_sep = '⮃' | |
let g:airline_symbols.branch = '⭠' | |
let g:airline_symbols.readonly = '⭤' | |
let g:airline_symbols.linenr = '⭡' | |
" set airline theme | |
let g:airline_theme='powerlineish' | |
" remove pause caused by vim-airline when exiting insert mode | |
:set ttimeoutlen=50 | |
" don't duplicate mode display | |
set noshowmode | |
" gui settings | |
if (&t_Co == 256 || has('gui_running')) | |
if ($TERM_PROGRAM == 'iTerm.app') | |
colorscheme solarized | |
else | |
colorscheme desert | |
endif | |
endif | |
" Disambiguate ,a & ,t from the Align plugin, making them fast again. | |
" | |
" This section is here to prevent AlignMaps from adding a bunch of mappings | |
" that interfere with the very-common ,a and ,t mappings. This will get run | |
" at every startup to remove the AlignMaps for the *next* vim startup. | |
" | |
" If you do want the AlignMaps mappings, remove this section, remove | |
" ~/.vim/bundle/Align, and re-run rake in maximum-awesome. | |
function! s:RemoveConflictingAlignMaps() | |
if exists("g:loaded_AlignMapsPlugin") | |
AlignMapsClean | |
endif | |
endfunction | |
command! -nargs=0 RemoveConflictingAlignMaps call s:RemoveConflictingAlignMaps() | |
silent! autocmd VimEnter * RemoveConflictingAlignMaps |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment