-
Notifications
You must be signed in to change notification settings - Fork 0
/
vimrc.txt
149 lines (117 loc) · 3.45 KB
/
vimrc.txt
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
" ---- vundle configurations ----
set nocompatible
filetype off
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
" For Windows
" set rtp+=~/vimfiles/bundle/Vundle.vim
" let path='~/vimfiles/bundle'
" call vundle#begin(path)
" Plugins...
Plugin 'gmarik/Vundle.vim'
Plugin 'davidhalter/jedi-vim'
Plugin 'klen/python-mode'
Plugin 'scrooloose/nerdtree'
Plugin 'Raimondi/delimitMate'
Plugin 'nvie/vim-flake8'
Plugin 'marijnh/tern_for_vim'
Plugin 'kien/ctrlp.vim'
Plugin 'Lokaltog/vim-powerline'
" plugins for vim-snipmate
Plugin 'MarcWeber/vim-addon-mw-utils'
Plugin 'tomtom/tlib_vim'
Plugin 'garbas/vim-snipmate'
Plugin 'digitaltoad/vim-jade'
" --
call vundle#end()
" ---- /vundle configurations/ ----
set foldmethod=indent
set foldlevel=99
" setting <leader> key to comma
let mapleader = ","
set number
" Make search case insensitive
set hlsearch
set incsearch
set ignorecase
set smartcase
" tab configuration
set tabstop=4
set shiftwidth=4
set softtabstop=4
set smarttab
set expandtab
" word wrap
set wrap
set linebreak
set nolist
set textwidth=0
set wrapmargin=0
set backspace=indent,eol,start
" indentation
set autoindent
" Disable stupid backup and swap files - they trigger too many events
" for file system watchers
set nobackup
set nowritebackup
set noswapfile
" easier moving of code blocks
" Try to go into visual mode (v), thenselect several lines of code here and
" then press ``>`` several times.
vnoremap < <gv " better indentation
vnoremap > >gv " better indentation
" to easily move though windows
noremap <c-j> <c-w>j
noremap <c-k> <c-w>k
noremap <c-l> <c-w>l
noremap <c-h> <c-w>h
" gundo plugin shortcut
map <leader>G :GundoToggle<CR>
" NERDTree plugin shortcut
map <C-n> :NERDTreeToggle<CR>
" jedi-vim configuration
let g:jedi#popup_on_dot = 0
" delimitMate configuration
syntax on " syntax highlighting
filetype on " try to detect filetypes
" use python instead of python3 for tern support
if(has("python"))
" enable tern shortcuts
let g:tern_map_keys=1
map <leader>td :TernDoc<CR>
map <leader>tb :TernDocBrowse<CR>
map <leader>tt :TernType<CR>
map <leader>tD :TernDef<CR>
map <leader>tpd :TernDefPreview<CR>
map <leader>tsd :TernDefSplit<CR>
map <leader>ttd :TernDefTab<CR>
map <leader>tr :TernRefs<CR>
map <leader>tR :TernRename<CR>
endif
if (has("python3"))
let g:jedi#force_py_version = 3
endif
colorscheme torte
filetype plugin indent on " enable loading indent file for filetype
" python-mode configuration
" let g:pymode=0
let g:pymode_indent=0
let g:pymode_motion=0
let g:pymode_doc=0
let g:pymode_breakpoint=1
let g:pymode_lint=0
let g:pymode_rope=0
let g:pymode_syntax=0
let g:pymode_virtualenv=1 " Auto fix vim python paths if virtualenv enabled
" let g:pymode_folding=1 " Enable python folding
" let g:pymode_utils_whitespaces=0 " Do not autoremove unused whitespaces
" let g:pymode_lint_ignore = "C0110 Exported" " ignore pep257 missing docstring warning
" let g:pymode_lint_minheight = 5 " Minimal height of pylint error window
" let g:pymode_lint_maxheight = 15 " Maximal height of pylint error window
" let g:pymode_lint_write = 0 " Disable pylint checking every save
" let g:pymode_run_key = "<leader>run" " default key conflicts with jedi-vim
" let g:pymode_syntax_highlight_self=0 " do not highlight self
" let g:pymode_rope_vim_completion=0 " use jedi-vim for completion
" let g:pymode_rope_guess_project=0
" let g:pymode_doc_key="<leader>k" " used jedi-vim for help
let g:pymode_run_bind = '<leader>R'