Created
January 5, 2014 22:56
-
-
Save jonashw/8275182 to your computer and use it in GitHub Desktop.
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
let mapleader="," | |
"enable pathogen | |
filetype off | |
call pathogen#runtime_append_all_bundles() | |
call pathogen#helptags() | |
"git status on statusline | |
set statusline=%t | |
set statusline+=%m | |
set statusline+=\ %{fugitive#statusline()} | |
"ack searching | |
nmap <leader>a <Esc>:Ack! | |
"python stuff | |
"be inside a method and type 'za' to open and close a fold. | |
"set foldmethod=indent | |
"set foldlevel=99 | |
"task list: hit <leader>td to open the task list.. q to close | |
"also: hit enter on the task to jmp to the buffer | |
map <leader>td <Plug>TaskList | |
"everything else | |
syntax on | |
cd ~ | |
set hls! | |
set ts=4 | |
set background=dark | |
"colorscheme ir_black | |
colorscheme desert | |
map <C-j> <C-W>j<C-W>_ | |
map <C-h> <C-W>h<C-W>_ | |
map <C-k> <C-W>k<C-W>_ | |
map <C-l> <C-W>l<C-W>_ | |
set gfn=Consolas:h10:cANSI | |
"set guioptions-=m "remove menu bar | |
set guioptions-=T "remove toolbar | |
set guioptions-=m "remove menu | |
"set guioptions-=r "remove right-hand scroll bar | |
set mouse=a "automatically enable mouse usage | |
set autochdir "always switch to the current file directory | |
set cursorline | |
hi cursorline guibg=#000000 | |
set ruler | |
set rulerformat=%30(%=\:b%n%y%m%r%w\ %l,%c%V\ %P%) "a ruler on steroids | |
"set nowrap | |
set wrap | |
"faster transition to ex command mode | |
nnoremap ; : | |
"wrapped lines goes down/up to next row, rather | |
nnoremap j gj | |
nnoremap k gk | |
"Yank from the cursor to the end of the line, to be consistent with C and D | |
nnoremap Y y$ | |
"au VimEnter * NERDTree | |
map <F2> :echo 'Current time = ' . strftime('%c')<CR> | |
"hotkey to reload my .vimrc | |
map <C-F1> :source ~/_vimrc <CR> | |
"hotkey to edit my .vimrc | |
map <C-S-F1> :vsplit ~/_vimrc <CR> | |
map <C-t> :NERDTreeToggle <CR> | |
"set relativenumber | |
set nu | |
filetype plugin on | |
filetype indent on | |
set smartindent | |
set shiftwidth=4 | |
nnoremap <C-s> <esc>:w<CR> | |
map <C-p> "+gP | |
map <C-c> "+y | |
"easier inter-tabular navigation! | |
map <a-l> :tabn<CR> | |
map <a-h> :tabp<CR> | |
map <a-n> :tabnew<CR> | |
map <a-t> :tabnew<CR> | |
nnoremap ,on :NERDTree ~/Desktop<CR> | |
map <a-f> :FufFile<CR> | |
"make it easier to exit insert mode: | |
:inoremap jk <esc> | |
"improve the statusline appearance for each window: | |
hi StatusLine guibg=White | |
hi StatusLineNC guifg=Black | |
set winminheight=0 "don't show code from collapsed windows | |
"keep vim from equalizing the windows when one closes | |
set noequalalways | |
"Grep | |
nnoremap <silent> <F3> :Grep<CR> | |
nnoremap <silent> <C-F3> :Regrep<CR> | |
"from http://stackoverflow.com/questions/1218390/what-is-your-most-productive-shortcut-with-vim | |
set ignorecase "case-insensitive searching | |
set scrolloff=2 "2 lines above/below cursor when scrolling | |
set bs=indent,eol,start "Allow backspacing over everything in insert mode | |
set viminfo='20,\"500 "remember copy registers after quitting in the .viminfo file -- 20 jump links, regs up to 500 lines' | |
"set hidden "remember undo after quitting | |
set history=50 "keep 50 lines of command history | |
set lazyredraw "no redraws in macros | |
"macros for a custom job... WeedCards | |
let @i=':%s/: /","/g | |
' | |
let @j='gg0GI,new WeedDescriptor("jkr G$A")jk@iggO€ü€kb{"weedname", new List<WeedDescriptor>{Go}}kVGggj>' | |
""enable omnicomplete | |
"set omnifunc=syntaxcomplete#Complete | |
""enable IDE-like interactive search for omnicomplete | |
"set completeopt=longest,menuone | |
""change the behavior of the <Enter> key when the popup menu is visible. In that case the Enter key will simply select the highlighted menu item, just as <C-Y> does | |
"inoremap <expr> <CR> pumvisible() ? "\<C-y>" : "\<C-g>u\<CR>" | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment