set wildignorecase
endif
-" Increase history of executed commands (:).
+" Show completion menu even if only one entry matches.
+if exists('+completeopt')
+ set completeopt+=menuone
+endif
+
+" Increase history of executed commands (:) and search patterns (/).
set history=1000
" Increase number of possible undos.
set undolevels=1000
-" Remember marks (including the last cursor position) for more files.
+" Remember marks (including the last cursor position) for more files. ^= is
+" necessary because 'viminfo' is parsed from the beginning and the first match
+" is used.
if has('viminfo')
set viminfo^='1000
endif
endif
" Clear all vimrc-related autocmds. Has to be done here as the vimrc augroup
-" is used multiple times.
+" is used multiple times. Necessary to support reloading the vimrc.
if has('autocmd')
augroup vimrc
autocmd!
set virtualedit=block
" Already display matches while typing the search command. This makes spotting
-" errors easy.
+" typos easy and searching faster.
set incsearch
" Activate syntax folding.
" Allow buffers with changes to be hidden. Very important for effective
" editing with multiple buffers. Prevents the "E37: No write since last change
-" (add ! to override)" warning.
+" (add ! to override)" warning when switching buffers.
set hidden
" In case 'hlsearch' is used disable it with <C-L>. Thanks to frogonwheels and
" vimgor (bot) in #vim on Freenode (2010-03-30 05:58 CEST).
-noremap <silent> <C-L> :nohlsearch<CR><C-L>
+nnoremap <silent> <C-L> :nohlsearch<CR><C-L>
" <C-U> in insert mode deletes a lot, break undo sequence before deleting the
" line so the change can be undone. Thanks to the vimrc_example.vim file in