themes: Add registration of themes at package installation time
This commit is contained in:
parent
4deb486228
commit
71306947ea
3 changed files with 10 additions and 1 deletions
|
@ -44,4 +44,3 @@ config internal template
|
|||
option compiledir "/tmp/.lucitplcache"
|
||||
|
||||
config internal themes
|
||||
option OpenWRT "/luci-static/openwrt.org"
|
||||
|
|
4
themes/openwrt.org/ipkg/postinst
Executable file
4
themes/openwrt.org/ipkg/postinst
Executable file
|
@ -0,0 +1,4 @@
|
|||
#!/bin/sh
|
||||
[ -n "${IPKG_INSTROOT}" ] || {
|
||||
( . /etc/uci-defaults/luci-theme-openwrt ) && rm -f /etc/uci-defaults/luci-theme-openwrt
|
||||
}
|
6
themes/openwrt.org/root/etc/uci-defaults/luci-theme-openwrt
Executable file
6
themes/openwrt.org/root/etc/uci-defaults/luci-theme-openwrt
Executable file
|
@ -0,0 +1,6 @@
|
|||
#!/bin/sh
|
||||
uci batch <<-EOF
|
||||
set luci.themes.OpenWRT=/luci-static/openwrt.org
|
||||
commit luci
|
||||
EOF
|
||||
|
Loading…
Reference in a new issue