vim setup
来源:互联网 发布:利用445端口入侵win7 编辑:程序博客网 时间:2024/06/07 21:48
mac:
vi /usr/share/vim/vimrc
linux:
vi /etc/vimrc
or
~/.vimrc
windows:
C:\Program Files (x86)\Vim\_vimrc
cygwin:
vi /etc/vimrc
set ai
set ts=4 sw=4
set ruler
set nonu
set hls
set incsearch
set smartindent
set wildmenu
set showcmd
set formatoptions=tcq
set fileformats=unix,dos
set t_Co=256
syntax on
set fileencodings=ucs-bom,utf-8,cp936,gb18030,big5,euc-jp,euc-kr,latin1
colorscheme molokai "good color, need install
colorscheme pablo "mac
colorscheme desert "linux or windows
"google style
set ts=2 sw=2
set expandtab
" 记录上次编辑的位置
" Only do this part when compiled with support for autocommands
if has("autocmd")
augroup redhat
autocmd!
" In text files, always limit the width of text to 78 characters
autocmd BufRead *.txt set tw=78
" When editing a file, always jump to the last cursor position
autocmd BufReadPost *
\ if line("'\"") > 0 && line ("'\"") <= line("$") |
\ exe "normal! g'\"" |
\ endif
" don't write swapfile on most commonly used directories for NFS mounts or USB sticks
autocmd BufNewFile,BufReadPre /media/*,/mnt/* set directory=~/tmp,/var/tmp,/tmp
" start with spec file template
autocmd BufNewFile *.spec 0r /usr/share/vim/vimfiles/template.spec
augroup END
endif
gvim:
winpos 235 235
set lines=25 columns=108
colo peachpuff
set nobackup
第一行为设置启动位置;
第二行为设置窗口大小,行X列;
第三行为设置本色方案;
nobackup不生成~文件
关闭ctrl + a全选
Vim\vim74\mswin.vim
" CTRL-A is Select all
"noremap <C-A> gggH<C-O>G
"inoremap <C-A> <C-O>gg<C-O>gH<C-O>G
"cnoremap <C-A> <C-C>gggH<C-O>G
"onoremap <C-A> <C-C>gggH<C-O>G
"snoremap <C-A> <C-C>gggH<C-O>G
"xnoremap <C-A> <C-C>ggV
colorscheme molokai
/usr/share/vim/vim7x/colors/
阅读全文
0 0
- vim setup
- VIM setup command
- setup
- setup
- Setup
- setup
- Setup a simplified IDE on Linux OS(Vim +Ctags + Taglist)
- Cronjob setup
- setup.asm
- xen setup
- inno setup
- Eclair setup
- cygwin setup
- Setup Cygwin
- Setup Boost
- Hudson setup
- MySql Setup
- apache setup
- axios 封装
- bzoj 4592: [Shoi2015]脑洞治疗仪 线段树
- java
- ROS多台计算机之间网络通信
- struts2中提供的类型转换
- vim setup
- 网络更新购物车的适配器
- 手机和电脑设备判断显示不同的页面
- Java开发练习9.2 TCP
- 【BZOJ】4552 [Tjoi2016&Heoi2016]排序 二分+线段树
- Android状态栏微技巧,带你真正理解沉浸式模式
- 错误情况简单
- Ubuntu 16.04编译安装OpenCV(Python)
- 学习JSON第一步