Update .bashrc
This commit is contained in:
parent
9657c32fde
commit
6555cc80cd
1 changed files with 17 additions and 6 deletions
23
.bashrc
23
.bashrc
|
@ -69,10 +69,21 @@ GEM_HOME="$(ls -t -U | ruby -e 'puts Gem.user_dir')"
|
|||
GEM_PATH="$GEM_HOME"
|
||||
PATH="$PATH:$GEM_HOME/bin"
|
||||
|
||||
Reset='\033[0m'
|
||||
Green='\033[32m'
|
||||
Red='\033[31m'
|
||||
Blue='\033[34m'
|
||||
Yellow='\033[33m'
|
||||
|
||||
# Set bash prompt
|
||||
RCol='\033[0m'
|
||||
Gre='\033[32m';
|
||||
Red='\033[31m';
|
||||
Blu='\033[34m';
|
||||
Yel='\033[33m';
|
||||
PS1="${RCol}┌─[\`if [ \$? = 0 ]; then echo "${Gre}"; else echo "${Red}"; fi\`\t\[${Rcol}\] \[${Blu}\]\h\[${RCol}\] \[${Yel}\]\w\[${RCol}\]]\n└─╼ "
|
||||
set_bash_prompt() {
|
||||
PS1="${Reset}┌─"
|
||||
PS1="${PS1}${Red}[\t]"
|
||||
PS1="${PS1}${Blue}[\h]"
|
||||
PS1="${PS1}${Yellow}[\w]"
|
||||
PS1="${PS1}${Blue}$(__git_ps1 "[%s]")"
|
||||
PS1="${PS1}${Reset}\n└─╼ "
|
||||
MSYS2_PS1="$PS1"
|
||||
}
|
||||
|
||||
PROMPT_COMMAND=set_bash_prompt
|
Loading…
Add table
Add a link
Reference in a new issue