op-packages/luci-app-switchtools/root/etc/uci-defaults/40_luci-switchtools
github-actions[bot] 32600acc60 🌴 Sync 2026-03-05 23:51:42
2026-03-05 23:51:42 +08:00

19 lines
394 B
Bash

#!/bin/sh
[ ! -f "/usr/share/ucitrack/luci-app-switchmode.json" ] && {
cat > /usr/share/ucitrack/luci-app-switchmode.json << EEOF
{
"config": "switchmode",
"init": "switchmode"
}
EEOF
}
uci -q batch <<-EOF >/dev/null
delete ucitrack.@switchmode[-1]
add ucitrack switchmode
add_list ucitrack.@switchmode[-1].affects=network
commit ucitrack
EOF
rm -f /tmp/luci-indexcache
exit 0