projects
/
dotfiles
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add .inputrc to get vi keybindings for readline programs
[dotfiles]
/
.vimrc
diff --git
a/.vimrc
b/.vimrc
index
5aa1f56
..
dd1d9bd
100644
(file)
--- a/
.vimrc
+++ b/
.vimrc
@@
-11,6
+11,9
@@
set wildignore=*.swp,*.bak,*.pyc,*.class,*.o,*.exe
" Set filetype stuff to on.
filetype on
filetype plugin on
" Set filetype stuff to on.
filetype on
filetype plugin on
+
+" Set up autoindentation.
+set smartindent
filetype indent on
" Example filetype-specific setting:
filetype indent on
" Example filetype-specific setting:
@@
-18,9
+21,10
@@
filetype indent on
" autocmd filetype python set expandtab
" endif
" autocmd filetype python set expandtab
" endif
-" Show line numbers.
-set number
-set numberwidth=4
+" Allow folding.
+set foldenable
+set foldmethod=syntax
+set foldlevelstart=99
" Scroll five lines ahead of cursor.
set scrolloff=5
" Scroll five lines ahead of cursor.
set scrolloff=5
@@
-28,16
+32,16
@@
set scrolloff=5
" Turn off error bells and visual bell
set noeb vb t_vb=
" Turn off error bells and visual bell
set noeb vb t_vb=
-" Set up autoindentation.
-set smartindent
-filetype indent on
-
-" Set tabs to width 4.
-set softtabstop=4
-set tabstop=4
-set shiftwidth=4
+" Set tabs to width 2.
+filetype plugin indent on
+set shiftwidth=2
+set softtabstop=2
+set tabstop=2
set expandtab
set expandtab
+" language-specific settings: tab width is 4 for python
+autocmd FileType python setlocal shiftwidth=4 softtabstop=4 tabstop=4
+
" Allow backspacing over everything in insert mode.
set backspace=indent,eol,start
" Allow backspacing over everything in insert mode.
set backspace=indent,eol,start
@@
-51,9
+55,6
@@
augroup Spacing
autocmd FileType help,make match BadSpacing / *$/
augroup END
autocmd FileType help,make match BadSpacing / *$/
augroup END
-" Highlight search terms.
-set hlsearch
-
" Search as you type.
set incsearch
" Search as you type.
set incsearch
@@
-86,6
+87,11
@@
syn sync fromstart
" Set the color scheme to desert.
colorscheme desert
" Set the color scheme to desert.
colorscheme desert
+" Set custom whitespace display
+set list
+set showbreak=↪\
+set listchars=tab:\ \ →,eol:↲,nbsp:␣,trail:•,extends:⟩,precedes:⟨
+
" Unmap the arrow keys to prevent bad habits.
noremap <Up> ""
noremap! <Up> <Esc>
" Unmap the arrow keys to prevent bad habits.
noremap <Up> ""
noremap! <Up> <Esc>