applications: revise uci-defaults scripts
[project/luci.git] / applications / luci-hd-idle / root / etc / uci-defaults / luci-hd_idle
old mode 100644 (file)
new mode 100755 (executable)
index 6a37176..92f4356
@@ -1,7 +1,11 @@
 #!/bin/sh
 
-uci batch <<-EOF
-       add ucitrack hd-idle
-       set ucitrack.@hd-idle[-1].init=hd-idle
-       commit ucitrack
+uci -q batch <<-EOF >/dev/null
+       delete ucitrack.@hd-idle[-1]
+       add ucitrack hd-idle
+       set ucitrack.@hd-idle[-1].init=hd-idle
+       commit ucitrack
 EOF
+
+rm -f /tmp/luci-indexcache
+exit 0