summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
7df7fe8)
looks a bit cleaner to me
" pathogen.vim runtime path manipulation
silent! call pathogen#infect()
" pathogen.vim runtime path manipulation
silent! call pathogen#infect()
set incsearch
set ignorecase
set smartcase
set hlsearch
nmap <Leader>q :nohl<CR>
set incsearch
set ignorecase
set smartcase
set hlsearch
nmap <Leader>q :nohl<CR>
" open/close NERDTree with \e
nmap <Leader>e :NERDTreeToggle<CR>
" <space> to open files/dirs
" open/close NERDTree with \e
nmap <Leader>e :NERDTreeToggle<CR>
" <space> to open files/dirs
autocmd vimenter * if !argc() | NERDTree | endif
" close vim if only NERDTree is open
autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTreeType") && b:NERDTreeType == "primary") | q | endif
autocmd vimenter * if !argc() | NERDTree | endif
" close vim if only NERDTree is open
autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTreeType") && b:NERDTreeType == "primary") | q | endif
let g:airline#extensions#tabline#enabled = 1
let g:airline#extensions#tabline#enabled = 1
:nmap <Leader>b :set expandtab tabstop=4 shiftwidth=4 softtabstop=4<CR>
:nmap <Leader>B :set expandtab tabstop=8 shiftwidth=8 softtabstop=4<CR>
:nmap <Leader>M :set noexpandtab tabstop=8 softtabstop=4 shiftwidth=4<CR>
:nmap <Leader>m :set expandtab tabstop=2 shiftwidth=2 softtabstop=2<CR>
:nmap <Leader>b :set expandtab tabstop=4 shiftwidth=4 softtabstop=4<CR>
:nmap <Leader>B :set expandtab tabstop=8 shiftwidth=8 softtabstop=4<CR>
:nmap <Leader>M :set noexpandtab tabstop=8 softtabstop=4 shiftwidth=4<CR>
:nmap <Leader>m :set expandtab tabstop=2 shiftwidth=2 softtabstop=2<CR>
if has("vms")
set nobackup " do not keep a backup file, use versions instead
else
set backup " keep a backup file
set backupdir=$HOME/.vim/backupdir
endif
if has("vms")
set nobackup " do not keep a backup file, use versions instead
else
set backup " keep a backup file
set backupdir=$HOME/.vim/backupdir
endif
set background=dark " Dark background, d'uh!
set number " show some linenumbers
set showmatch " Show matching brackets.
set showbreak=▒▒ " show these chars for wrapped lines
set list listchars=tab:»·,trail:· " show these chars for tabs and trailing spaces
set background=dark " Dark background, d'uh!
set number " show some linenumbers
set showmatch " Show matching brackets.
set showbreak=▒▒ " show these chars for wrapped lines
set list listchars=tab:»·,trail:· " show these chars for tabs and trailing spaces
set history=500 " keep 500 lines of command line history
set ruler " show the cursor position all the time
set confirm " Ask what to do when closing unsaved documents
set history=500 " keep 500 lines of command line history
set ruler " show the cursor position all the time
set confirm " Ask what to do when closing unsaved documents
set backspace=indent,eol,start " allow backspacing over everything in insert mode
set viminfo='100,<50,s10,h,n~/.vim/viminfo " viminfo defaults but save file in .vim
set backspace=indent,eol,start " allow backspacing over everything in insert mode
set viminfo='100,<50,s10,h,n~/.vim/viminfo " viminfo defaults but save file in .vim
set softtabstop=4
set shiftwidth=4
set expandtab
set softtabstop=4
set shiftwidth=4
set expandtab
" Don't use Ex mode, use Q for formatting
map Q gq
" Don't use Ex mode, use Q for formatting
map Q gq
" Press `` to toggle insert and replace mode (no <Insert> key on Mac keyboard)
imap `` <Insert>
" Press `` to toggle insert and replace mode (no <Insert> key on Mac keyboard)
imap `` <Insert>
nmap <F11> :set paste! paste?<CR>
imap <F11> <C-o>:set paste!<CR>
vmap <F11> <Esc>:set paste!<CR>gv
set pastetoggle=<F11>
nmap <F11> :set paste! paste?<CR>
imap <F11> <C-o>:set paste!<CR>
vmap <F11> <Esc>:set paste!<CR>gv
set pastetoggle=<F11>
" In many terminal emulators the mouse works just fine, thus enable it.
if has('mouse')
"xterm mouse with middleclick paste
" In many terminal emulators the mouse works just fine, thus enable it.
if has('mouse')
"xterm mouse with middleclick paste
set ttymouse=xterm
"set ttymouse=xterm2
endif
set ttymouse=xterm
"set ttymouse=xterm2
endif
" Switch syntax highlighting on, when the terminal has colors
" Also switch on highlighting the last used search pattern.
if &t_Co > 2 || has("gui_running")
syntax on
endif
" Switch syntax highlighting on, when the terminal has colors
" Also switch on highlighting the last used search pattern.
if &t_Co > 2 || has("gui_running")
syntax on
endif
" Only do this part when compiled with support for autocommands.
if has("autocmd")
" Enable file type detection.
" Only do this part when compiled with support for autocommands.
if has("autocmd")
" Enable file type detection.
augroup END
else
set autoindent " always set autoindenting on
augroup END
else
set autoindent " always set autoindenting on
-endif " has("autocmd") }}}
" Convenient command to see the difference between the current buffer and the
" file it was loaded from, thus the changes you made.
" Only define it when not defined already.
" Convenient command to see the difference between the current buffer and the
" file it was loaded from, thus the changes you made.
" Only define it when not defined already.
command DiffOrig vert new | set bt=nofile | r # | 0d_ | diffthis
\ | wincmd p | diffthis
endif
command DiffOrig vert new | set bt=nofile | r # | 0d_ | diffthis
\ | wincmd p | diffthis
endif
set foldmethod=marker
set foldlevelstart=99
" space will toggle current fold in normal mode, if not in a fold, normal
set foldmethod=marker
set foldlevelstart=99
" space will toggle current fold in normal mode, if not in a fold, normal
" save and restore folds
autocmd BufWinLeave *.* mkview
autocmd BufWinEnter *.* silent loadview
" save and restore folds
autocmd BufWinLeave *.* mkview
autocmd BufWinEnter *.* silent loadview
-function! NextIndent(exclusive, fwd, lowerlevel, skipblanks) " {{{
+function! NextIndent(exclusive, fwd, lowerlevel, skipblanks) " {{{1
" Jump to the next or previous line that has the same level or a lower
" level of indentation than the current line.
"
" Jump to the next or previous line that has the same level or a lower
" level of indentation than the current line.
"
onoremap <silent> ]l :call NextIndent(0, 1, 0, 1)<CR>
onoremap <silent> [L :call NextIndent(1, 0, 1, 1)<CR>
onoremap <silent> ]L :call NextIndent(1, 1, 1, 1)<CR>
onoremap <silent> ]l :call NextIndent(0, 1, 0, 1)<CR>
onoremap <silent> [L :call NextIndent(1, 0, 1, 1)<CR>
onoremap <silent> ]L :call NextIndent(1, 1, 1, 1)<CR>
-" end of jump indent }}}