pfetch: Fix android sed

This commit is contained in:
Dylan Araps 2019-10-14 09:53:12 +03:00
parent 616e1b0c3b
commit 6c3d5c3a87
No known key found for this signature in database
GPG Key ID: 46D62DD9F1DE636E

6
pfetch
View File

@ -1302,8 +1302,12 @@ get_ascii() {
# output without the use of a pipe ('|').
# This ensures that any variables defined in the while loop
# are still accessible in the script.
#
# The 'awk' command below used to be a simple 'sed', however
# some versions of Android shipped with a totally broken 'sed'
# command from 'toybox' and so we're forced to avoid 'sed'.
done <<-EOF
$(printf %s "$ascii" | sed 's/\[3.m//g')
$(printf %s "$ascii" | awk '{gsub("\\[3.m","");print}')
EOF
# Add a gap between the ascii art and the information.