commit 6102c93fdb457b489fc7fcc7c00d92fc0a9e40de
parent 9f37223fc102269c9126687c66f1e9d64ed004a7
Author: Frederic Cambus <fred@statdns.com>
Date: Thu, 4 Jun 2020 15:32:18 +0200
Merge pull request #126 from nikcorg/patch-1
Use cut instead of awk for reading the config file
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ansiweather b/ansiweather
@@ -34,7 +34,7 @@ get_config() {
ret=""
if [ -f "$config_file" ]
then
- ret=$(grep "^$1:" "$config_file" | awk -F: '{print $2}')
+ ret=$(grep "^$1:" "$config_file" | cut -d: -f2-)
fi
if [ "X$ret" = "X" ]