Programming/Kernel

[Kernel : Linux]bash 환경 설정하기

MB Brad KWON 2013. 6. 18. 12:53

 리눅스에서는 bash를 기본적인 쉘로 사용한다. 시스템 내에서 알 수 없는 문자를 출력한다고 해서 매번 '[export LANG=C]'를 입력하는 것은 번거롭다. root 사용자의 경우, /root/.bashrc 파일을 수정하면 보다 편한 개발 환경을 구축할 수 있다.


LANG=C; exprot LANG;

export PS1='\h:\w\$'                 //언어설정을 추가해서 메시지 깨짐을 방지

umask 022

echo -ne '\033[11;0]'                  //경고비프음을 제거


#you may uncomment the following lines if you want 'ls' to be colorized:

export LS_OPTION='--color=auto'           //ls 결과에 색상을 사용

eval "'discolors'"

alias ls='ls $LS_OPTIONS'

alias ll='ls $LS_OPTIONS -l'

alias l='ls $LS_OPTIONS -lA'


#some more alias to avoid making mistakes:

alias rm='rm -i'

alias cp='cp -i'

alias mv='mv -i'