From 794f7216cd792755d3897d0931710ba1d60e91f2 Mon Sep 17 00:00:00 2001 From: Sasha Koshka Date: Wed, 31 Jan 2024 13:35:16 -0500 Subject: [PATCH] Wallpaper file now supports comments --- session/src/xmd-load-wallpaper | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/session/src/xmd-load-wallpaper b/session/src/xmd-load-wallpaper index 155c60b..5ebef03 100755 --- a/session/src/xmd-load-wallpaper +++ b/session/src/xmd-load-wallpaper @@ -25,6 +25,9 @@ if type "$configFilePath" > /dev/null; then color="black" while read -r line; do + line=`echo $line | sed s/\#.\*$//g` + [ -z "$line" ] && continue + IFS="=" read key value << EOF $line EOF @@ -32,7 +35,7 @@ EOF "mode") mode="$value";; "file") file="$value";; "color") color="$value";; - *) echo "$name: bad key $key in $configFilePath" >&2;; + *) echo "$name: bad key $key in $configFilePath" >&2;; esac done < "$configFilePath"