-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.vimrc
188 lines (160 loc) · 4.35 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
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
set nocompatible " be iMproved, required
filetype off " required
"set autochdir
" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/Vundle.vim/
let path='~/.vim/bundle'
call vundle#begin(path)
" let Vundle manage Vundle, required
Plugin 'gmarik/Vundle.vim'
" My Bundles here:
"
" original repos on github
" dash plugin for OS X
Plugin 'rizzatti/dash.vim'
" Plugin 'refactor'
"Plugin 'YankRing.vim'
"Bundle 'tpope/vim-fugitive'
Bundle 'Lokaltog/vim-easymotion'
"Bundle 'Lokaltog/vim-powerline'
Bundle 'sjl/gundo.vim'
Bundle 'klen/python-mode'
"Bundle 'majutsushi/tagbar'
"Bundle 'myusuf3/numbers.vim'
"Bundle 'vim-scripts/ScrollColors'
"Bundle 'vim-scripts/mru.vim'
"Bundle 'vim-scripts/CSApprox.git'
Bundle 'chrisbra/DynamicSigns'
Bundle 'nathanaelkane/vim-indent-guides'
"Bundle 'scrooloose/syntastic'
Bundle 'scrooloose/nerdtree'
Bundle 'scrooloose/nerdcommenter'
"Bundle 'skammer/vim-css-color'
Bundle 'kien/ctrlp.vim'
"Bundle 'tpope/vim-surround'
Bundle 'whatyouhide/vim-gotham'
"Bundle 'airblade/vim-gitgutter'
"Bundle 'xsbeats/vim-blade'
" vim-scripts repos
" non github repos
" All of your Plugins must be added before the following line
call vundle#end() " required
filetype plugin indent on " required
" To ignore plugin indent changes, instead use:
" filetype plugin on
"
" Brief help
" :PluginList - lists configured plugins
" :PluginInstall - installs plugins; append `!` to update or just :PluginUpdate
" :PluginSearch foo - searches for foo; append `!` to refresh local cache
" :PluginClean - confirms removal of unused plugins; append `!` to auto-approve removal
"
" see :h vundle for more details or wiki for FAQ
" Put your non-Plugin stuff after this line
set wildmenu
set hidden
set nowrap
set tabstop=4
set backspace=indent,eol,start
set autoindent
set number
set shiftwidth=4
set shiftround
set showmatch
set ignorecase
set smartcase
set smarttab
set laststatus=2
set encoding=utf-8
set hlsearch
set incsearch
set history=1000
set undolevels=1000
set wildignore=*.swp,*.bak,*.pyc,*.class
set title
set visualbell
set noerrorbells
set nobackup
set noswapfile
" always display current line number + column
set ruler
if has('autocmd')
filetype plugin indent on
autocmd filetype python set expandtab
endif
" Toggle relative numbers plugin
nnoremap <silent><leader>rn :set relativenumber!<cr>
set rnu!
set t_Co=256
colorscheme gotham256
" Set font depending on OS!
if has("gui_running")
if has("gui_gtk2")
set guifont=Inconsolata\ 11
elseif has("gui_macvim")
set guifont=Menlo\ Regular:h14
elseif has("gui_win32")
set guifont=Consolas:h11:cANSI
endif
endif
if &t_Co > 2 || has("gui_running")
syntax on
endif
" Nerd Tree toggle with f1, f2, f3!
map <F1> :NERDTreeToggle<CR>
map <F2> :NERDTreeToggle<CR>
" Toggle paste nopaste modes
nnoremap <F3> :set invpaste paste?<CR>
set pastetoggle=<F3>
set showmode
" numbers vim
" nnoremap <F2> :GitGutterToggle<CR>
nnoremap <F4> :NumbersToggle<CR>
nnoremap <F5> :GundoToggle<CR>
nnoremap <F6> :TagbarToggle<CR>
" if hit enter -> clear search hl results!
nnoremap <CR> :noh<CR><CR>:<backspace>
nnoremap ; :
nnoremap <space> za
nnoremap <F6> :set hlsearch!<CR>
set foldmethod=syntax
set foldlevel=3
" history of actions !!! deleted stufff, pasted stuff
" :nnoremap <silent> <F11> :YRShow<CR>
"set ofu=syntaxcomplete#Complete
"set guioptions-=m "remove menu bar
"set guioptions-=T "remove toolbar
set guioptions-=r "remove right-hand scroll bar
set guioptions-=L "remove right-hand scroll bar
" Alternating Line colors with DynamicSigns plugin
" let g:Signs_Alternate=1
" autocmd VimEnter * UpdateSigns
" Indentation lines
set ts=4 sw=4 et
let g:indent_guides_start_level = 2
let g:indent_guides_guide_size = 1
let g:ctrlp_cmd = 'call CallCtrlP()'
func! CallCtrlP()
if exists('s:called_ctrlp')
CtrlPLastMode
else
let s:called_ctrlp = 1
CtrlPMRU
endif
endfunc
" Use autocompletion with TAB !
function! Tab_Or_Complete()
if col('.')>1 && strpart( getline('.'), col('.')-2, 3 ) =~ '^\w'
return "\<C-N>"
else
return "\<Tab>"
endif
endfunction
inoremap <Tab> <C-R>=Tab_Or_Complete()<CR>
" Screen size options
" If GVIM -> Full screen
if has("gui_running")
" GUI is running or is about to start.
" Maximize gvim window (for an alternative on Windows, see simalt below).
set lines=900 columns=900
endif