-
Notifications
You must be signed in to change notification settings - Fork 0
/
.vimrc
77 lines (60 loc) · 1.42 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
"make sure vim and crontab do not suck
if $VIM_CRONTAB == "true"
set nobackup
set nowritebackup
endif
set nocompatible "make vim act as vim not vi
set backspace=indent,eol,start "make backspace work as we want
set enc=utf8 "set encoding to utf8
set nu "set line numbers
"set indentation
set ts=4
set softtabstop=4
set shiftwidth=4
set expandtab
"set some search stuff
set incsearch
set hlsearch
set ignorecase
set ruler
set clipboard=unnamed
color koehler
"set background=dark
"colorscheme solarized
set modeline
set laststatus=2
" arrow key mappings for wrapped lines
map <Up> gk
map <Down> gj
" mapping esc
inoremap jj <ESC>
" center search on page
map n nzz
map N Nzz
"tab mappings
map gb gT
"toggle line wrap off
set wrap!
" change to directory that file buffer is in
nnoremap ,cd :cd %:p:h<CR>
"syntax hilighting on
syntax enable
"work for pasting
set pastetoggle=<F2>
"some typos and other commands
command! Q q
command! W w
command! Wq wq
command! WQ wq
" Mapping shortcut to remove highlight
nnoremap <space> :nohl<CR>
"
" Python Specific Code
" python sepcific keywords (remove '(' and '.' )
au BufEnter *.py set iskeyword=@,48-57,_,192-255
filetype indent plugin on
autocmd FileType python set complete+=k~/.vim/syntax/python.vim isk+=.,(
"remove trailing whitespace from python files
autocmd BufWritePre * :%s/\s\+$//e
"pathogen
execute pathogen#infect()