mirror of
https://github.com/dylanaraps/neofetch.git
synced 2025-12-23 12:09:55 +00:00
Fix padding on android
This commit is contained in:
5
neofetch
5
neofetch
@@ -1974,6 +1974,11 @@ getascii() {
|
||||
[ "${#line}" -gt "$ascii_length" ] && ascii_length="${#line}"
|
||||
done <<< "$ascii_strip"
|
||||
|
||||
# Workaround for calculating length of block chars
|
||||
# when locale is set to 'C'
|
||||
block_char="█"
|
||||
[ "${#block_char}" == 3 ] && ascii_length="$((ascii_length / 3 + 2))"
|
||||
|
||||
lines="$(printf "%s\n" "$ascii_strip" | wc -l)"
|
||||
padding="\033[$((ascii_length + gap))C"
|
||||
printf "%b%s" "$print"
|
||||
|
||||
Reference in New Issue
Block a user