mirror of
https://github.com/dylanaraps/neofetch.git
synced 2025-10-04 09:08:38 +00:00
Fix whitespace on Windows
This commit is contained in:
5
neofetch
5
neofetch
@@ -2799,12 +2799,9 @@ getlinebreak () {
|
|||||||
#
|
#
|
||||||
# The 'set -f/+f' is here so that 'echo' doesn't cause any expansion
|
# The 'set -f/+f' is here so that 'echo' doesn't cause any expansion
|
||||||
# of special characters.
|
# of special characters.
|
||||||
#
|
|
||||||
# The whitespace trim doesn't work with multiline strings so we use
|
|
||||||
# '${1//[[:space:]]/ }' to remove newlines beofre we trim the whitespace.
|
|
||||||
trim() {
|
trim() {
|
||||||
set -f
|
set -f
|
||||||
builtin echo -E ${1//$'\n'/ }
|
builtin echo -En $1
|
||||||
set +f
|
set +f
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user