一:设置bashrc
if [ -f /etc/bashrc ]; then
. /etc/bashrc
fi
alias egrep=‘egrep --color=auto‘
alias fgrep=‘fgrep --color=auto‘
alias g=‘gvim‘
alias ga=‘g ~/.alias‘
alias glg=‘git lg‘
alias gls=‘git status‘
alias grep=‘grep --color=auto‘
alias gst=‘git status‘
alias h=‘history‘
alias l=‘ls -lh‘
alias la=‘ls -A‘
alias ll=‘ls -alF‘
alias ls=‘ls --color=auto‘
alias sa=‘source ~/.alias‘
alias venv=‘virtualenv‘
三:设置vim
全局:
/etc/vim/autoload/pathogen.vim
/etc/vim/autoload/bundle/** VIM插件统一安装到该目录下,本地用户ln -s 到各自目录
/etc/vimrc
"------------------------------------------------- set nu colorscheme desert syntax on set ruler "set cursorline "set cursorcolumn "------------------------------------------------- imap <s-enter> <esc>o imap <c-enter> <esc>O nmap K 6k nmap J 6j "------------------------------------------------- set autoindent set smartindent set smarttab set tabstop=4 set shiftwidth=4 set expandtab set list listchars=tab:>- "ret !4 set virtualedit=all "------------------------------------------------- "call pathogen#infect() syntax on filetype plugin indent on "------------------------------------------------- autocmd FileType apache set commentstring=#\ %s autocmd FileType verilog set commentstring=//\ %s autocmd FileType c set commentstring=//\ %s
本地用户:
ln -s /etc/vim/autoload/ ~/.vim/
ln -s /etc/vim/autoload/bundle/* ~/.vim/bundle/
g ~/.vimrc 需要加入
call pathogen#infect()
四:设置本地环境
~/.bashrc
~/.alias_local
~/.vimrc
~/.vim
原文:http://www.cnblogs.com/goco/p/4072331.html