News for hackers. Stuff that matters.
Re:Bash PS1 Generator by paulmac_ie on Thursday June 24, 2021 @10:11AM (#27617735)
This is my prompt that shows my git branch, AWS_PROFILE etc:

    if [ "$color_prompt" = yes ]; then
        PS1='\[\033[0;32m\]\[\033[0m\033[0;32m\]\u\ 
        [\033[0;36m\] @ \[\033[0;36m\]\h \w\ 
        [\033[0;32m\]$(__git_ps1)\n\[\033[0;32m\]└─\ 
        [\033[0m\033[0;32m\] \$\[\033[0m\033[0;32m\] 
        AWS:${AWS_PROFILE} ▶\[\033[0m\] '
    else
        PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
    fi

There are no comments on this comment yet.