Wallpaper file now supports comments

This commit is contained in:
Sasha Koshka 2024-01-31 13:35:16 -05:00
parent 0dd701da37
commit 794f7216cd

View File

@ -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"