-
Notifications
You must be signed in to change notification settings - Fork 0
/
vimrc
120 lines (99 loc) · 2.66 KB
/
vimrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
syntax enable " Syntax highlighting
filetype off
set nocompatible
set modeline
set number " Numbers of lines on left side
set hlsearch " Higlighting of search results
set incsearch " Incremental search
set autoindent
set ignorecase
set encoding=utf-8
set fileencoding=utf-8
set smartcase
set gdefault
set showmatch
set guifont=PragmataPro
set noswapfile
set cursorline
set cc=79
set list
set listchars=tab:▸\ ,eol:¬
set autoread
set spell
set mouse=a " Mouse support for everything
let mapleader=","
set tabstop=4
set softtabstop=4
set shiftwidth=4
set shiftround
set expandtab
let NERDTreeIgnore = ['\.pyc$']
let NERDTreeShowBookmarks=1
augroup group
autocmd!
au FileChangedShell * echo "Warning: File changed on disk"
autocmd BufWritePost *
\ if filereadable('tags') |
\ call system('ctags -a '.expand('%')) |
\ endif
au Filetype arduino setlocal ts=2 sts=2 sw=2
au Filetype python setlocal ts=4 sts=4 sw=4
au Filetype html setlocal ts=2 sts=2 sw=2
augroup END
" PLUGINS
" Vundle config below, don't mess with it
" (copied from https://github.com/gmarik/vundlenn)
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
" let Vundle manage Vundle
" required!
Plugin 'gmarik/Vundle.vim'
" My bundles here:
"
" original repos on GitHub
Plugin 'davidhalter/jedi-vim'
Plugin 'flazz/vim-colorschemes'
Plugin 'kien/ctrlp.vim'
set wildignore+=*/tmp/*,*.so,*.swp,*.zip,*.pyc
Plugin 'msanders/snipmate.vim'
Plugin 'scrooloose/syntastic'
Plugin 'scrooloose/nerdtree'
Plugin 'tpope/vim-fugitive'
Plugin 'tpope/vim-surround'
Plugin 'Lokaltog/powerline', {'rtp': 'powerline/bindings/vim/'}
" Powerline setup
set guifont=DejaVu\ Sans\ Mono\ for\ Powerline\ 9
set laststatus=2
if ! has('gui_running')
set ttimeoutlen=10
augroup FastEscape
autocmd!
au InsertEnter * set timeoutlen=0
au InsertLeave * set timeoutlen=1000
augroup END
endif
call vundle#end() " required
filetype plugin indent on " required!
"
" Brief help
" :PluginList - list configured bundles
" :PluginInstall(!) - install (update) bundles
" :PluginSearch(!) foo - search (or refresh cache first) for foo
" :PluginClean(!) - confirm (or auto-approve) removal of unused bundles
"
" see :h vundle for more details or wiki for FAQ
" NOTE: comments after Bundle commands are not allowed.
" COLORS
set t_Co=256
let g:solarized_termcolors=256
colorscheme solarized
set background=light
" CUSTOM MAPINGS
noremap <F5> :!python2 %<CR>
noremap <Leader>n :NERDTreeToggle<CR>
noremap <Leader>. :NERDTreeFromBookmark dotfiles<CR>
noremap <Up> <NOP>
noremap <Down> <NOP>
noremap <Left> <NOP>
noremap <Right> <NOP>
vnoremap <Leader>s :sort<CR>