forked from husio/vim-configuration
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvimrc
More file actions
109 lines (96 loc) · 2.37 KB
/
vimrc
File metadata and controls
109 lines (96 loc) · 2.37 KB
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
" {{{ pathogen init
call pathogen#runtime_append_all_bundles()
" }}}
" {{{ custom vim mode settings (colorscheme, guioptions, etc)
if has("gui_running")
set guioptions-=r
set guioptions-=L
set guioptions-=T
set guioptions-=m
set guioptions-=e
set guifont=Monospace\ 8
colorscheme mustang
set mousehide
set lines=70 columns=200
elseif (&term == 'xterm-color')
set t_Co=256
colorscheme jhdark
else
set background=dark
colorscheme ron
endif
" }}}
" {{{ printing setup
set printdevice=LaserJet
"set printheader="%<%f%h%m%=Strona %N"
set printencoding=iso-8859-2
set printfont=curier
set printfont=Mono\ 8
" }}}
" {{{ plugin setup
let NERDTreeIgnore = ['.py[oc]']
" }}}
" {{{ main configuration
set mouse=a
"set spelllang=pl
"set spell
syntax on
set nocompatible
set nobackup
set ruler
set showcmd
set number
set hlsearch
set smarttab
set pastetoggle=<F11>
set autoindent
set wildmode=list:longest,full
set completeopt=longest,menuone
set enc=utf8
set textwidth=78
set fileencodings=utf-8
set foldmethod=marker
set foldlevelstart=0
"set path=$PWD/**
"set cursorline
set tabstop=4
set shiftwidth=4
set expandtab
set nolazyredraw
set magic
" }}}
" {{{ line status builder
set laststatus=2
set statusline=\ %{HasPaste()}%F%m%r%h\ %w\ \ CWD:\ %r%{CurDir()}%h\ \ \ Line:\ %l/%L:%c
function! CurDir()
let curdir = substitute(getcwd(), '/home/piotrek/', "~/", "g")
return curdir
endfunction
function! HasPaste()
if &paste
return 'PASTE MODE '
else
return ''
endif
endfunction
" }}}
" {{{ filetype related configuration
filetype on
filetype plugin on
filetype indent on
autocmd BufNewFile * startinsert
autocmd BufReadPost PKGBUILD setfiletype PKGBUILD
autocmd BufRead,BufNewFile *.mkd setfiletype mkd
autocmd BufRead,BufNewFile *.html set textwidth=0
autocmd BufRead,BufNewFile *.html set ft=htmldjango
autocmd BufRead,BufNewFile *.js setfiletype javascript.jquery
" remove white characters from end of each line
autocmd BufWritePre * :%s/\s\+$//e
"}}}
" {{{ yankring plugin setup
let g:yankring_history_dir = expand("$HOME") . "/.yankring"
" create yankring directory if does not exists
call system("[ -d " . g:yankring_history_dir . " ] || mkdir " . g:yankring_history_dir)
let g:yankring_min_element_length = 1
let g:yankring_max_history = 40
" }}}