my vimrc 081122
2008年11月22日 (vim)
source
colorscheme torte
"colorscheme elflord
"colorscheme koehler
"colorscheme murphy
"colorscheme pablo
"colorscheme ron
nmap <C-v> <C-v>
"highlight CursorM guibg=red guifg=NONE
"set columns=80
"set lines=30
"set autowrite
set noautowrite
set autoindent
"set noautoindent
"set backup
set nobackup
"set compatible
set nocompatible
"set cursorcolumn
set nocursorcolumn
"set cursorline
set nocursorline
"set hlsearch
set nohlsearch
set ignorecase
"set noignorecase
set number
"set nonumber
"set list
set nolist
set showmatch
"set noshowmatch
set showmode
"set noshowmode
set smartcase
"set nosmartcase
set smartindent
"set nosmartindent
set smarttab
"set nosmarttab
"set textmode
set notextmode
set wrap
"set nowrap
"set visualbell
set novisualbell
"set errorbells
set noerrorbells
"set backupdir=>/tmp
set backspace=1
"set backspace=2
set fileencodings=utf-8,euc-jp,cp932
set fileformats=unix,dos,mac
set history=1000
set iminsert=0
set imsearch=0
set matchpairs=(:),{:},<:>,[:]
set matchtime=1
set shiftwidth=4
set softtabstop=4
set switchbuf=useopen
set tabstop=4
set undolevels=1000
"set virtualedit=insert
set virtualedit=block
"set virtualedit=all
set clipboard+=autoselect
"set guioptions+=a
syntax on
"source ~/.vim/plugins/*.vim
"source ~/.vim/colors/*.vim
~/.vimrc
PR
my vimrc 080805
2008年08月05日 (vim)
source
colorscheme torte
nmap <C-v> <C-v>
"highlight CursorM guibg=red guifg=NONE
"set columns=80
"set lines=30
"set autowrite
set noautowrite
set autoindent
"set noautoindent
"set backup
set nobackup
"set compatible
set nocompatible
"set hlsearch
set nohlsearch
set ignorecase
"set noignorecase
set number
"set nonumber
"set list
set nolist
set showmatch
"set noshowmatch
set showmode
"set noshowmode
set smartcase
"set nosmartcase
set smartindent
"set nosmartindent
set smarttab
"set nosmarttab
"set textmode
set notextmode
"set wrap
set nowrap
"set visualbell
set novisualbell
"set errorbells
set noerrorbells
"set backupdir=>/tmp
set backspace=1
"set backspace=2
set fileencodings=utf-8,euc-jp,cp932
set fileformats=unix,dos,mac
set history=1000
set iminsert=0
set imsearch=0
set matchpairs=(:),{:},<:>,[:]
set matchtime=1
set shiftwidth=4
set softtabstop=4
set switchbuf=useopen
set tabstop=4
set undolevels=1000
"set virtualedit=insert
set virtualedit=block
"set virtualedit=all
source ~/.vim/plugins/*.vim
syntax on
~/.vimrc
visualbell errorbell
2008年08月05日 (vim)
command
:set visualbell # visualbell on :set novisualbell # visualbell off :set errorbells # errorbell on :set noerrorbells # errorbell off
note
cf. :help errorbells :help visualbell
replace
2008年08月04日 (vim)
全ての行を対象にstringをreplaceに置換.
:%subsutitute/string/replace
2〜19行目を対象にstringをreplaceに置換.
:2,19substitute/string/replace
21〜最終行を対象にstringをreplaceに置換.
:21,$substitute/string/replace
その行の全てのパターンを置換する場合はgオプションを使う.gオプションがなければ最初にマッチしたものだけが置換される.
:%subsutitute/string/replace/g
マッチするごとに置換するかどうか尋ねるにはcオプションを使う.
:%substutute/string/replace/c
短縮形.
:%s/string/replace/c
区切りは/以外でもOK.
:%s;string;replace
正規表現も使える.この場合sで始まり,ingで終わるバターンをreplaceに置換.
:%s/s.*ing/replace
正規表現をエスケープ.
:%s/s\.\*ing/replace
詳しくはhelpを.
:help substitute