contrib/meshwizard: Fix setting of values which contain spaces & cleanups
[project/luci.git] / contrib / package / meshwizard / files / usr / bin / meshwizard / helpers / setup_system.sh
1 #!/bin/sh
2 # Sets values from /etc/config/freifunk and/or the community profile in /etc/config/system
3
4 . $dir/functions.sh
5
6 if [ -n "$(env | grep '^system_')" ]; then
7 env | grep "^system_" | sed "s/system_/uci set system.system./g" | while read line; do
8 eval $line
9 done
10 fi
11
12 uci -q delete meshwizard.system && uci commit meshwizard
13 uci_commitverbose "System config" system