Fix PHP container PS1

This commit is contained in:
cytopia
2018-11-04 06:35:10 +01:00
parent 4569855e6e
commit db397e5ef5

View File

@@ -19,7 +19,7 @@ _clr_usr='\[\e[0;31m\]'
_clr_ver='\[\e[0;36m\]'
_clr_dir='\[\e[0;34m\]'
_clr_off='\[\e[0m\]'
PS1_PHP="$( php -v 2>/dev/null | grep -Eo '^PHP\s([-_.a-z0-9])+' )"
PS1_PHP="$( php -v 2>/dev/null | grep -Eo '^PHP\s([-_.a-zA-Z0-9])+' )"
PS1_PHP="${PS1_PHP//PHP[[:space:]]}"
PS1_USR="$( whoami )"
PS1="${_clr_usr}${PS1_USR}${_clr_off}@${_clr_ver}php-${PS1_PHP}${_clr_off} in ${_clr_dir}\w${_clr_off} \$ "