forked from BlackIkeEagle/vimfiles
-
Notifications
You must be signed in to change notification settings - Fork 0
/
vimrc
128 lines (103 loc) · 2.91 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
" BlackEagles vimrc for Linux && Windows
"
" (c) 2010 - 2012
" nocompatible has to be the first of all ( use the real vimpower )
set nocompatible
" set leader key
let mapleader = ','
" WHO ARE YOU ?
let g:AuthorName="Nobody"
let g:AuthorEmail="nobody@example.com"
" DEFAULT WORKSPACE AREA
let g:Workspace="~/devel/"
syntax on
" set the colorsheme
colorscheme peaksea
set background=dark
" backup rules
set backup
if has("win32")
set backupdir=$TEMP
set directory=$TEMP
set viewdir=$TEMP
else
silent execute '!mkdir -p $HOME/.vim/tmp/backup'
set backupdir=$HOME/.vim/tmp/backup
silent execute '!mkdir -p $HOME/.vim/tmp/swap'
set directory=$HOME/.vim/tmp/swap
silent execute '!mkdir -p $HOME/.vim/tmp/views'
set viewdir=$HOME/.vim/tmp/views
endif
" commandline history
set history=1000
" backspace stuff
set backspace=indent,eol,start
" some weird stuff to make it faster
set nocursorcolumn
set nocursorline
" allow project specific settings
set exrc
set secure
" some interface options
set ruler " show cursorposition
set cursorline " highlight current line
set showcmd " display incomplete commands
set incsearch " incremental searching
set hlsearch " highlight searchresult
set number " show linennumbers
set linespace=0 " stick together (usefull for nfo files)
set hidden " hide buffer even when changed
set scrolloff=4 " keep at least 4 lines above or below the cursor
" fileformat stuff
"set fileformat=unix
set fileformats=unix,dos
"set encoding=utf-8
"set fileencoding=utf-8
set fileencodings=utf-8,ucs-bom,cp1250,iso-8859-1
" filetype
filetype on
filetype plugin on
filetype indent on
" tabstop settings
set tabstop=4
set softtabstop=4
set shiftwidth=4
set noexpandtab
" statusline stuff
set laststatus=2
set statusline=%<%F%h\ %(%y\ %)[%{&ff}]\ %{\"[\".(&fenc==\"\"?&enc:&fenc).\"]\"}\ %([%R%M]\ %)%=#%n\ %l/%L,%c%V\ %P
" diff settings
set diffopt=filler,iwhite,vertical
" SuperTab settings
"let g:SuperTabDefaultCompletionType = "<c-x><c-o>"
"let g:SuperTabContextDefaultCompletionType = "<c-x><c-o>"
" php settings
let php_sql_query=0
let php_html_in_strings=0
let php_parent_error_close=1
let php_parent_error_open=1
" Folding stuff
let php_folding=1
let javascript_fold=1
" AutoClose settings
let g:AutoCloseOn=0
"let g:AutoClosePairs= {'(': ')', '[': ']', '"': '"', "'": "'", '<': '>'}
" syntastic
let g:syntastic_enable_signs=1
let g:syntastic_auto_loc_list=1
" custom functionkey mapping
map <silent> <F3> :CodeTidy<CR>
map <silent> <F4> :PhpDoc<CR>
map <silent> <F5> :NERDTreeToggle<CR>
map <silent> <F6> :TagbarToggle<CR>
map <silent> <F8> :Bufferlist<CR>
map <silent> <F9> :noh<CR>
map <silent> <F11> :set list!<CR>
" nfo shit
au BufReadPre *.nfo set fileencodings=cp437
au BufReadPost *.nfo set fileencodings=utf-8,ucs-bom,cp1250
au BufReadPre *.diz set fileencodings=cp437
au BufReadPost *.diz set fileencodings=utf-8,ucs-bom,cp1250
if version >= 702
autocmd BufWinLeave * call clearmatches()
endif