O/S - cpueblo.com

bashrc, vimrc 의 밝은 색상 값 및 grep 검색 세팅


글쓴이 : 유광희 날짜 : 2013-06-25 (화) 15:27 조회 : 17661

안녕하세요. 유광희 입니다.

 

제가 새 서버에 사용하는 기본 세팅 값입니다.

 

1. putty 검은색 바탕에 맞춰 밝은 색으로 ls 색상을 변경

2. grep 사용시 컬러 사용

3. cpueblo_find .svn 을 제외하고 검색하는 방법 입니다

4. vi 실행시 나타나는 색상도 검은색 바탕에 맞춰 밝게 조절합니다.

5. profile 에는 SVN 커밋시 vim 을 사용하도록 설정

 

/etc/bashrc, /etc/vimrc, /etc/profile 에 적용하면 모든 계정에 적용되며

~/.bashrc, ~/.vimrc, ~/.bash_profile 로 로그인된 계정에만 적용합니다.

 

 


$ vi ~/.bashrc
또는 vi /etc/bashrc
export LS_COLORS="di=01;33":"fi=01;37":"ex=01;32":"ln=01;36":"so=01;33" 
alias grep='grep --color' 
alias cpueblo_find='find . -not \( -name .svn -prune \) -type f | xargs grep --color ' 
alias cpueblo_svn_file_remove='find . -name .svn -print0 | xargs -0 rm -rf'


 * cpueblo_svn_file_remove 는 현재 폴더와 하위 폴더의  .svn 을 모두 찾아내어 삭제하는 기능 입니다.

 


$ vi ~/.vimrc 
또는 vi /etc/vimrc
hi Comment term=bold cterm=bold ctermfg=4 
hi Constant term=bold cterm=bold ctermfg=1 
set ts=4




$ vi ~/.bash_profile
또는 /etc/profile

export SVN_EDITOR=/usr/bin/vim

 

감사합니다.