Skip to content

Commit

Permalink
profile.d/toolbox.sh: set bash PS1 as explicit string constant
Browse files Browse the repository at this point in the history
since it is constant there is no need to use printf and embed
binary color codes, which also made it hard to match on toolbox PS1.

Signed-off-by: Jens Petersen <[email protected]>

#1514
  • Loading branch information
juhp committed Jul 1, 2024
1 parent cb6eee8 commit 76ec022
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion profile.d/toolbox.sh
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ fi

if [ -f /run/.containerenv ] \
&& [ -f /run/.toolboxenv ]; then
[ "${BASH_VERSION:-}" != "" ] && PS1=$(printf "\[\033[35m\]⬢\[\033[0m\]%s" "[\u@\h \W]\\$ ")
[ "${BASH_VERSION:-}" != "" ] && PS1='\[\e[35m\]⬢\[\e[0m\][\u@\h \W]\$ '
[ "${ZSH_VERSION:-}" != "" ] && PS1=$(printf "\033[35m⬢\033[0m%s" "[%n@%m]%~%# ")

if ! [ -f "$toolbox_welcome_stub" ]; then
Expand Down

0 comments on commit 76ec022

Please sign in to comment.