update prompt
This commit is contained in:
parent
3764099eb1
commit
508ed7fb97
14
bash/bashrc
14
bash/bashrc
@ -114,7 +114,7 @@ parse_git() {
|
|||||||
if [[ $? -ne 0 ]]; then
|
if [[ $? -ne 0 ]]; then
|
||||||
return
|
return
|
||||||
else
|
else
|
||||||
printf ":(${BRANCH})["
|
printf "\033[1;37m:(${BRANCH})["
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if echo "${STATUS}" | grep -c "nothing to commit" &> /dev/null; then printf "\033[1;34m=\033[0m"; else printf ""; fi
|
if echo "${STATUS}" | grep -c "nothing to commit" &> /dev/null; then printf "\033[1;34m=\033[0m"; else printf ""; fi
|
||||||
@ -126,7 +126,7 @@ parse_git() {
|
|||||||
if echo "${STATUS}" | grep -c "Untracked files:" &> /dev/null; then printf "\033[1;33m?\033[0m"; else printf ""; fi
|
if echo "${STATUS}" | grep -c "Untracked files:" &> /dev/null; then printf "\033[1;33m?\033[0m"; else printf ""; fi
|
||||||
if echo "${STATUS}" | grep -c "modified:" &> /dev/null; then printf "\033[1;33m*\033[0m"; else printf ""; fi
|
if echo "${STATUS}" | grep -c "modified:" &> /dev/null; then printf "\033[1;33m*\033[0m"; else printf ""; fi
|
||||||
|
|
||||||
printf "]"
|
printf "\033[1;37m]"
|
||||||
}
|
}
|
||||||
|
|
||||||
# tmux
|
# tmux
|
||||||
@ -174,10 +174,14 @@ bkup() {
|
|||||||
|
|
||||||
#========== PROMPTS ==========#
|
#========== PROMPTS ==========#
|
||||||
# git prompts
|
# git prompts
|
||||||
# PS1="\[\033[1;34m\]\w\[\033[0m\]\$(parse_git) \[\033[1;35m\]\$\[\033[0m\] "
|
# PS1="\[\033[1;34m\]\w\[\033[0m\]\$(parse_git) \[\033[1;36m\]\$\[\033[0m\] "
|
||||||
PS1="\[\033[1;35m\]\u\[\033[1;33m\]@\[\033[1;36m\]\h\[\033[0m\]:\[\033[1;37:\[\033[1;34m\]\w\[\033[0m\]\$(parse_git)\[\033[0m\]\[\033[1;33m\]$ \[\033[0m\]"
|
# PS1="\[\033[1;35m\]\u\[\033[1;33m\]@\[\033[1;36m\]\h\[\033[0m\]:\[\033[1;37:\[\033[1;34m\]\w\[\033[0m\]\$(parse_git)\[\033[0m\]\[\033[1;33m\]$ \[\033[0m\]"
|
||||||
|
# PS1="\[\033[1;36m\]\u \[\033[1;37m\]at \[\033[1;33m\]\h \[\033[1;37m\]in \[\033[1;34m\]\w \[\033[1;37m\]on \[\033[1;37m\]\$(parse_git)\n\[\033[1;37m\]\$ "
|
||||||
|
|
||||||
# non git prom\]pts
|
PS1="\[\033[1;34m\]\W\[\033[0m\]\$(parse_git) \[\033[1;35m\]\$\[\033[0m\] "
|
||||||
|
# PS1="\[\033[1;35m\]\u\[\033[1;33m\]@\[\033[1;36m\]\h\[\033[0m\]:\[\033[1;37:\[\033[1;34m\]\W\[\033[0m\]\$(parse_git)\[\033[0m\]\[\033[1;33m\]$ \[\033[0m\]"
|
||||||
|
|
||||||
|
# non git prompts
|
||||||
# PS1="\[\033[1;34m\]\w \[\033[1;33m\]\$ \[\033[0m\]"
|
# PS1="\[\033[1;34m\]\w \[\033[1;33m\]\$ \[\033[0m\]"
|
||||||
# PS1="\[\033[1;35m\]\u\[\033[1;33m\]@\[\033[1;36m\]\h\[\033[0m\]:\[\033[1;37:\[\033[1;34m\]\w\[\033[0m\]\[\033[1;33m\]$ \[\033[0m\]"
|
# PS1="\[\033[1;35m\]\u\[\033[1;33m\]@\[\033[1;36m\]\h\[\033[0m\]:\[\033[1;37:\[\033[1;34m\]\w\[\033[0m\]\[\033[1;33m\]$ \[\033[0m\]"
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user