Merge pull request #124 from R3pl4c3r/master
Set the theme as the default theme(branch: master)
This commit is contained in:
commit
7ba20064cb
11
Makefile
11
Makefile
@ -8,11 +8,16 @@ include $(TOPDIR)/rules.mk
|
|||||||
|
|
||||||
LUCI_TITLE:=Argon Theme
|
LUCI_TITLE:=Argon Theme
|
||||||
LUCI_DEPENDS:=
|
LUCI_DEPENDS:=
|
||||||
PKG_VERSION:=2.2.4
|
PKG_VERSION:=2.2.5
|
||||||
PKG_RELEASE:=20200821
|
PKG_RELEASE:=20200907
|
||||||
|
|
||||||
include $(TOPDIR)/feeds/luci/luci.mk
|
include $(TOPDIR)/feeds/luci/luci.mk
|
||||||
|
|
||||||
|
define Package/luci-theme-argon/install
|
||||||
|
$(INSTALL_DIR) $(1)/etc/uci-defaults
|
||||||
|
$(INSTALL_BIN) ./files/30_luci-theme-argon $(1)/etc/uci-defaults/luci-theme-argon
|
||||||
|
endef
|
||||||
|
|
||||||
define Package/luci-theme-argon/postinst
|
define Package/luci-theme-argon/postinst
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
sed -i ":a;$!N;s/tmpl.render.*sysauth_template.*return/local scope = { duser = default_user, fuser = user }\nlocal ok, res = luci.util.copcall\(luci.template.render_string, [[<% include\(\"themes\/\" .. theme .. \"\/sysauth\"\) %>]], scope\)\nif ok then\nreturn res\nend\nreturn luci.template.render\(\"sysauth\", scope\)/;ba" /usr/lib/lua/luci/dispatcher.lua
|
sed -i ":a;$!N;s/tmpl.render.*sysauth_template.*return/local scope = { duser = default_user, fuser = user }\nlocal ok, res = luci.util.copcall\(luci.template.render_string, [[<% include\(\"themes\/\" .. theme .. \"\/sysauth\"\) %>]], scope\)\nif ok then\nreturn res\nend\nreturn luci.template.render\(\"sysauth\", scope\)/;ba" /usr/lib/lua/luci/dispatcher.lua
|
||||||
@ -22,4 +27,4 @@ rm -Rf /var/luci-indexcache
|
|||||||
exit 0
|
exit 0
|
||||||
endef
|
endef
|
||||||
|
|
||||||
# call BuildPackage - OpenWrt buildroot signature
|
# call BuildPackage - OpenWrt buildroot signature
|
||||||
|
7
files/30_luci-theme-atmaterial
Normal file
7
files/30_luci-theme-atmaterial
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
uci batch <<-EOF
|
||||||
|
set luci.themes.Argon=/luci-static/argon
|
||||||
|
set luci.main.mediaurlbase=/luci-static/argon
|
||||||
|
commit luci
|
||||||
|
EOF
|
||||||
|
exit 0
|
Loading…
x
Reference in New Issue
Block a user