commit 4652737b81b24dcce7649daed265b3ca539eced5
parent 0eb7f4b0d28a491c885451658955a34c1e7c3312
Author: Frederic Cambus <fred@statdns.com>
Date: Sat, 11 Nov 2017 22:06:14 +0100
Revert explicit escaping commits
Diffstat:
2 files changed, 31 insertions(+), 31 deletions(-)
diff --git a/ansiweather b/ansiweather
@@ -7,7 +7,7 @@
# https://github.com/fcambus/ansiweather #
# #
# Created: 2013-08-29 #
-# Last Updated: 2017-08-30 #
+# Last Updated: 2017-11-11 #
# #
# AnsiWeather is released under the BSD 2-Clause license. #
# See LICENSE file for details. #
@@ -123,11 +123,11 @@ timeformat=$(get_config "timeformat" || echo "%b %d %r")
###[ Colors and characters ]###################################################
-background=$(get_config "background" || echo "\\033[44m")
-text=$(get_config "text" || echo "\\033[36;1m")
-data=$(get_config "data" || echo "\\033[33;1m")
-delimiter=$(get_config "delimiter" || echo "\\033[35m=>")
-dashes=$(get_config "dashes" || echo "\\033[34m-")
+background=$(get_config "background" || echo "\033[44m")
+text=$(get_config "text" || echo "\033[36;1m")
+data=$(get_config "data" || echo "\033[33;1m")
+delimiter=$(get_config "delimiter" || echo "\033[35m=>")
+dashes=$(get_config "dashes" || echo "\033[34m-")
@@ -145,15 +145,15 @@ forecast_text=$(get_config "forecast_text" || echo "forecast")
###[ Unicode Symbols for icons ]###############################################
-sun=$(get_config "sun" || echo "\\033[33;1m\\xe2\\x98\\x80")
-moon=$(get_config "moon" || echo "\\033[36m\\xe2\\x98\\xbd")
-clouds=$(get_config "clouds" || echo "\\033[37;1m\\xe2\\x98\\x81")
-rain=$(get_config "rain" || echo "\\033[37;1m\\xe2\\x98\\x94")
-fog=$(get_config "fog" || echo "\\033[37;1m\\xe2\\x96\\x92")
-mist=$(get_config "mist" || echo "\\033[34m\\xe2\\x96\\x91")
-haze=$(get_config "haze" || echo "\\033[33m\\xe2\\x96\\x91")
-snow=$(get_config "snow" || echo "\\033[37;1m\\xe2\\x9d\\x84")
-thunderstorm=$(get_config "thunderstorm" || echo "\\033[33;1m\\xe2\\x9a\\xa1")
+sun=$(get_config "sun" || echo "\033[33;1m\xe2\x98\x80")
+moon=$(get_config "moon" || echo "\033[36m\xe2\x98\xbd")
+clouds=$(get_config "clouds" || echo "\033[37;1m\xe2\x98\x81")
+rain=$(get_config "rain" || echo "\033[37;1m\xe2\x98\x94")
+fog=$(get_config "fog" || echo "\033[37;1m\xe2\x96\x92")
+mist=$(get_config "mist" || echo "\033[34m\xe2\x96\x91")
+haze=$(get_config "haze" || echo "\033[33m\xe2\x96\x91")
+snow=$(get_config "snow" || echo "\033[37;1m\xe2\x9d\x84")
+thunderstorm=$(get_config "thunderstorm" || echo "\033[33;1m\xe2\x9a\xa1")
@@ -399,7 +399,7 @@ fi
if [ "$ansi" = true ]
then
- env printf "$output\\033[0m\\n"
+ env printf "$output\033[0m\n"
else
- env printf "$output\\n" | sed "s/$(printf '\033')\\[[0-9;]*m//g"
+ env printf "$output\n" | sed "s/$(printf '\033')\[[0-9;]*m//g"
fi
diff --git a/ansiweatherrc.example b/ansiweatherrc.example
@@ -15,11 +15,11 @@ dateformat:%a %b %d
timeformat:%b %d %r
# Text and Colors
-background:\\033[44m
-text:\\033[36;1m
-data:\\033[33;1m
-delimiter:\\033[35m=>
-dashes:\\033[34m-
+background:\033[44m
+text:\033[36;1m
+data:\033[33;1m
+delimiter:\033[35m=>
+dashes:\033[34m-
forecast_text:forecast
greeting_text:Weather in
humidity_text:Humidity
@@ -30,12 +30,12 @@ wind_directions:N NNE NE ENE E ESE SE SSE S SSW SW WSW W WNW NW NNW
wind_text:Wind
# Icons
-sun:\\033[33;1m\\xe2\\x98\\x80
-moon:\\033[36m\\xe2\\x98\\xbd
-clouds:\\033[37;1m\\xe2\\x98\\x81
-rain:\\033[37;1m\\xe2\\x98\\x94
-fog:\\033[37;1m\\xe2\\x96\\x92
-mist:\\033[34m\\xe2\\x96\\x91
-haze:\\033[33m\\xe2\\x96\\x91
-snow:\\033[37;1m\\xe2\\x9d\\x84
-thunderstorm:\\033[33;1m\\xe2\\x9a\\xa1
+sun:\033[33;1m\xe2\x98\x80
+moon:\033[36m\xe2\x98\xbd
+clouds:\033[37;1m\xe2\x98\x81
+rain:\033[37;1m\xe2\x98\x94
+fog:\033[37;1m\xe2\x96\x92
+mist:\033[34m\xe2\x96\x91
+haze:\033[33m\xe2\x96\x91
+snow:\033[37;1m\xe2\x9d\x84
+thunderstorm:\033[33;1m\xe2\x9a\xa1