投稿

ラベル(linux)が付いた投稿を表示しています

2. Editting prompt

$PS1 is set like below by default in MAC OS. In MAC OS, PS1 is quickly reflected after changing PS1. Takaharus-MacBook-Pro:~ tkurokawa$ echo $PS1 \h:\W \u\$ Takaharus-MacBook-Pro:~ tkurokawa$ PS1=[TK:\W]$ [TK:W]$ Login shell executes the following files: 1.        /etc/profile 2.        ~/.bash_profile 3.        ~/.bash_login 4.        ~/.profile ~/.bashrc   is not listed but in most of   ~/.bash_profile   seems to call ~/.bashrc. .basshrc can be pushed from echo with " echo 'export PS1="[\w]$"' > .bashrc ". [TK:W]$echo 'export PS1="[\w]$"' > .bashrc [TK:W]$more .bashrc export PS1="[\w]$" [TK:W]$echo "export PS1="[\w]$"" > .bashrc [TK:W]$more .bashrc export PS1=[w] #\w is removed. This doesn't work.   [TK:W]$echo 'export PS1='[\w]$'' > .bashrc...