#!/bin/sh
[ ! -f "/usr/share/ucitrack/luci-app-pushbot.json" ] && {
    cat > /usr/share/ucitrack/luci-app-pushbot.json << EEOF
{
    "config": "pushbot",
    "init": "pushbot"
}
EEOF
}

uci -q batch <<-EOF >/dev/null
	delete ucitrack.@pushbot[-1]
	add ucitrack pushbot
	set ucitrack.@pushbot[-1].init=pushbot
	commit ucitrack
EOF

rm -rf /tmp/luci-*
exit 0
