author | Oleksandr Gavenko <gavenkoa@gmail.com> |
Tue, 16 Mar 2010 15:48:46 +0200 | |
changeset 37 | 5d56427b59a4 |
parent 27 | 55688ec975f9 |
child 40 | b8185f03f364 |
permissions | -rw-r--r-- |
25 | 1 |
" On loding VIM search for /etc/vimrc, ~/.vimrc. |
2 |
||
3 |
syntax on |
|
4 |
||
26 | 5 |
" Do not emulate old vi bug. |
25 | 6 |
set nocompatible |
7 |
||
26 | 8 |
" Same as set ts=4, by default - 8, how long TAB. |
25 | 9 |
set tabstop=4 |
26 | 10 |
" Use spaces instead TAB. |
25 | 11 |
set shiftwidth=4 |
12 |
set smarttab |
|
13 |
set et |
|
14 |
||
26 | 15 |
" Move cursor on RET to previous line indent. |
16 |
set autoindent |
|
17 |
" Indent for C-like languages. |
|
18 |
set smartindent |
|
19 |
||
20 |
" This setting will cause the cursor to very briefly jump to a |
|
21 |
" brace/parenthese/bracket's "match" whenever you type a closing or opening |
|
22 |
" brace/parenthese/bracket. I've had almost no mismatched-punctuation errors |
|
23 |
" since I started using this setting. |
|
24 |
set showmatch |
|
25 |
||
26 |
" Turn on incremental search with ignore case (except explicit caps). |
|
27 |
set incsearch |
|
28 |
set ignorecase |
|
29 |
set smartcase |
|
30 |
||
27
55688ec975f9
Remove custom status line.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
26
diff
changeset
|
31 |
" Have 3 lines of offset (or buffer) when scrolling. |
55688ec975f9
Remove custom status line.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
26
diff
changeset
|
32 |
set scrolloff=3 |
55688ec975f9
Remove custom status line.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
26
diff
changeset
|
33 |
|
26 | 34 |
" I find the toolbar in the GUI version of vim (gvim) to be somewhat useless |
35 |
" visual clutter. This option gets rid of the toolbar. |
|
36 |
set guioptions-=T |
|
37 |
||
38 |
||
39 |
" This setting prevents vi from making its annoying beeps when a command |
|
40 |
" doesn't work. Instead, it briefly flashes the screen -- much less annoying. |
|
41 |
set vb t_vb= |
|
42 |
||
43 |
||
44 |
" This setting ensures that each window contains a statusline that displays |
|
45 |
" the current cursor position. |
|
25 | 46 |
set ruler |
47 |
||
26 | 48 |
" By default, search matches are highlighted. I find this annoying most of the |
49 |
" time. This option turns off search highlighting. You can always turn it back |
|
50 |
" on with :set hls. |
|
51 |
set nohls |
|
52 |
||
53 |
" With this nifty option, vim will search for text as you enter it. For |
|
54 |
" instance, if you type /bob to search for bob, vi will go to the first "b" |
|
55 |
" after you type the "b," to the first "bo" after you type the "o," and so on. |
|
56 |
" It makes searching much faster, since if you pay attention you never have to |
|
57 |
" enter more than the minimum number of characters to find your target |
|
58 |
" location. Make sure that you press Enter to accept the match after vim finds |
|
59 |
" the location you want. |
|
60 |
set incsearch |
|
61 |
||
62 |
||
63 |
" By default, vim doesn't let the cursor stray beyond the defined text. This |
|
64 |
" setting allows the cursor to freely roam anywhere it likes in command mode. |
|
65 |
" It feels weird at first but is quite useful. |
|
66 |
set virtualedit=all |
|
67 |
||
68 |
set ruler |
|
69 |
||
25 | 70 |
" Local Variables: |
71 |
" mode: fundamental |
|
72 |
" comment-start: "\"" |
|
73 |
" eval: (font-lock-add-keywords nil '( ("^[[:blank:]]*\".*" . font-lock-comment-face) )) |
|
74 |
" End: |