From 95f915abf12e15eecb290c64a619aaea917c1c36 Mon Sep 17 00:00:00 2001
From: Beginner <70857188+Beginner-Go@users.noreply.github.com>
Date: Sun, 21 Nov 2021 14:48:21 +0800
Subject: [PATCH] luci-app: tidy up code (#8277)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
1.文件尾部添加换行并删除多余的换行
2.整理代码,看起来更直观
3.更正文件的权限
4.将一些文件的CR LF末行符全部转为LF
---
.../ddns-scripts_dnspod/update_dnspod_cn.sh | 0
.../ddns-scripts_dnspod/update_dnspod_com.sh | 0
package/lean/dns2socks/Makefile | 0
package/lean/dsmboot/files/dsmboot | 0
.../files/root/etc/hotplug.d/iface/60-6in4 | 0
.../lib/firmware/brcm/brcmfmac4366c-pcie.bin | Bin
package/lean/luci-app-adbyby-plus/Makefile | 1 -
.../luasrc/controller/adbyby.lua | 18 +-
.../luasrc/model/cbi/adbyby/advanced.lua | 2 +-
.../luasrc/model/cbi/adbyby/base.lua | 43 +-
.../luasrc/model/cbi/adbyby/black.lua | 1 -
.../luasrc/model/cbi/adbyby/block.lua | 1 -
.../luasrc/model/cbi/adbyby/esc.lua | 1 -
.../luasrc/model/cbi/adbyby/help.lua | 1 -
.../luasrc/model/cbi/adbyby/user.lua | 1 -
.../luasrc/view/adbyby/adbyby_status.htm | 2 +-
package/lean/luci-app-airplay2/Makefile | 1 -
.../luasrc/controller/shairport-sync.lua | 4 +-
.../luasrc/model/cbi/shairport-sync.lua | 28 +-
.../shairport-sync/shairport-sync_status.htm | 2 +-
package/lean/luci-app-amule/Makefile | 1 -
.../luci-app-amule/luasrc/model/cbi/amule.lua | 2 +-
package/lean/luci-app-amule/po/zh-cn/amule.po | 1 -
.../root/etc/hotplug.d/iface/20-amule | 0
package/lean/luci-app-arpbind/Makefile | 1 -
.../luasrc/model/cbi/arpbind.lua | 7 +-
package/lean/luci-app-autoreboot/Makefile | 1 -
.../luasrc/controller/autoreboot.lua | 1 +
.../luasrc/model/cbi/autoreboot.lua | 40 +-
.../root/etc/config/autoreboot | 1 -
package/lean/luci-app-baidupcs-web/Makefile | 44 +--
.../luasrc/controller/baidupcs-web.lua | 6 +-
.../root/etc/uci-defaults/luci-baidupcs-web | 22 +-
.../luasrc/model/cbi/cifs.lua | 4 +-
.../root/etc/uci-defaults/luci-cifsd | 0
.../luasrc/controller/cpufreq.lua | 1 -
package/lean/luci-app-dnsforwarder/Makefile | 38 +-
.../luasrc/controller/dnsforwarder.lua | 3 +-
.../luasrc/model/cbi/dnsforwarder/general.lua | 371 +++++++++---------
.../luasrc/model/cbi/dnsforwarder/log.lua | 59 ++-
.../po/zh-cn/dnsforwarder.po | 16 +-
package/lean/luci-app-docker/Makefile | 1 -
.../luasrc/controller/docker.lua | 6 +-
.../luasrc/model/cbi/docker.lua | 6 +-
.../luasrc/view/docker/docker_status.htm | 2 +-
.../luci-app-docker/root/etc/config/dockerd | 1 -
package/lean/luci-app-easymesh/Makefile | 0
.../luasrc/controller/easymesh.lua | 3 +-
.../luasrc/model/cbi/easymesh.lua | 0
.../root/etc/config/easymesh | 0
package/lean/luci-app-familycloud/Makefile | 1 -
.../luasrc/controller/familycloud.lua | 8 +-
.../model/cbi/familycloud/familycloud.lua | 10 +-
...familycloudlog.lua => familycloud_log.lua} | 4 +-
.../view/familycloud/familycloud_status.htm | 2 +-
package/lean/luci-app-filetransfer/Makefile | 2 -
package/lean/luci-app-frpc/Makefile | 2 -
.../luasrc/model/cbi/frp/basic.lua | 22 +-
.../luasrc/model/cbi/frps/server.lua | 24 +-
.../lean/luci-app-frps/root/etc/init.d/frps | 0
.../root/etc/uci-defaults/40_luci-frps | 0
.../luasrc/model/cbi/guest-wifi.lua | 1 -
.../luasrc/controller/haproxy.lua | 3 +-
.../luasrc/model/cbi/haproxy.lua | 47 +--
package/lean/luci-app-ipsec-vpnd/Makefile | 2 -
.../luasrc/controller/ipsec-server.lua | 7 +-
.../cbi/{ipsec-server => }/ipsec-server.lua | 6 +-
.../luasrc/view/ipsec/ipsec_status.htm | 2 +-
.../luasrc/model/cbi/kodexplorer/settings.lua | 41 +-
...{download.htm => kodexplorer_download.htm} | 2 +-
.../{status.htm => kodexplorer_status.htm} | 2 +-
.../{version.htm => kodexplorer_version.htm} | 2 +-
.../luci-app-music-remote-center/Makefile | 1 -
.../luasrc/controller/forked-daapd.lua | 7 +-
.../luasrc/model/cbi/forked-daapd.lua | 18 +-
.../view/forked-daapd/forked-daapd_status.htm | 2 +-
package/lean/luci-app-mwan3helper/Makefile | 2 -
.../luasrc/controller/mwan3helper.lua | 4 +-
.../luasrc/model/cbi/mwan3helper/client.lua | 2 -
.../luasrc/model/cbi/mwan3helper/list.lua | 2 -
.../view/mwan3helper/mwan3helper_status.htm | 2 +-
.../luasrc/controller/n2n_v2.lua | 10 +-
.../luasrc/model/cbi/n2n_v2.lua | 9 +-
.../luasrc/view/n2n_v2/n2n_v2_status.htm | 20 +
.../luasrc/view/n2n_v2/status.htm | 20 -
.../luasrc/controller/netdata.lua | 2 +-
package/lean/luci-app-nfs/Makefile | 1 -
.../root/etc/uci-defaults/luci-nfs | 0
.../luci-app-nps/luasrc/controller/nps.lua | 2 +-
.../luci-app-nps/luasrc/model/cbi/nps.lua | 14 +-
.../luasrc/view/nps/nps_status.htm | 0
package/lean/luci-app-nps/po/zh-cn/nps.po | 2 +-
package/lean/luci-app-nps/root/etc/config/nps | 0
package/lean/luci-app-pppoe-relay/Makefile | 2 -
.../luasrc/controller/pppoe-relay.lua | 2 +-
.../luasrc/model/cbi/pppoe-relay.lua | 28 +-
package/lean/luci-app-pptp-server/Makefile | 4 -
.../luasrc/controller/pptp-server.lua | 11 +-
.../cbi/{pptp-server => }/pptp-server.lua | 8 +-
.../pptp-server_status.htm} | 6 +-
.../etc/uci-defaults/{pptpd => luci-pptpd} | 0
package/lean/luci-app-ps3netsrv/Makefile | 1 -
.../luasrc/controller/ps3netsrv.lua | 4 +-
.../luasrc/model/cbi/ps3netsrv.lua | 14 +-
.../view/ps3netsrv/ps3netsrv_status.htm | 2 +-
package/lean/luci-app-ramfree/Makefile | 2 -
.../luasrc/model/cbi/samba4.lua | 4 +-
.../lean/luci-app-ssrserver-python/Makefile | 2 -
.../luasrc/controller/ssrs.lua | 4 +-
.../luasrc/model/cbi/ssrs.lua | 50 +--
.../luasrc/view/ssrs/ssrs_status.htm | 2 +-
package/lean/luci-app-syncdial/Makefile | 1 -
.../luasrc/controller/syncdial.lua | 1 +
.../luasrc/model/cbi/syncdial.lua | 131 ++++---
.../root/etc/hotplug.d/iface/01-dialcheck | 0
.../root/etc/hotplug.d/iface/01-mvifcreate | 0
package/lean/luci-app-ttyd/Makefile | 1 -
.../cbi/unblockmusic/unblockmusic_log.lua | 4 +-
.../view/unblockmusic/unblockmusic_status.htm | 2 +-
package/lean/luci-app-usb-printer/Makefile | 3 +-
package/lean/luci-app-uugamebooster/Makefile | 2 +-
.../luasrc/controller/uuplugin.lua | 4 +-
.../root/etc/uci-defaults/45_luci-uuplugin | 0
.../luasrc/controller/v2ray_server.lua | 1 -
.../luasrc/model/cbi/v2ray_server/index.lua | 13 +-
.../luasrc/controller/verysync.lua | 4 +-
.../luasrc/model/cbi/verysync.lua | 2 +-
package/lean/luci-app-vsftpd/Makefile | 1 -
.../luasrc/model/cbi/vsftpd/anonymous.lua | 13 +-
.../luasrc/model/cbi/vsftpd/general.lua | 52 ++-
.../luasrc/model/cbi/vsftpd/item.lua | 10 +-
.../luasrc/model/cbi/vsftpd/log.lua | 4 +-
.../luasrc/model/cbi/vsftpd/users.lua | 6 +-
package/lean/luci-app-webadmin/Makefile | 2 -
.../luasrc/controller/webadmin.lua | 1 -
.../luasrc/model/cbi/webadmin.lua | 15 +-
package/lean/luci-app-wrtbwmon/Makefile | 1 -
.../luasrc/model/cbi/wrtbwmon/config.lua | 9 +-
package/lean/luci-app-zerotier/Makefile | 2 -
.../luasrc/controller/zerotier.lua | 4 +-
.../luasrc/model/cbi/zerotier/settings.lua | 31 +-
.../root/etc/uci-defaults/30_luci-theme-argon | 0
.../luasrc/view/themes/netgear/footer.htm | 0
.../luasrc/view/themes/netgear/header.htm | 0
package/lean/n2n_v2/files/n2n_v2.init | 0
package/lean/ntfs3-mount/files/mount.ntfs3 | 0
.../lean/openwrt-fullconenat/files/Makefile | 1 -
package/lean/pdnsd-alt/files/pdnsd.init | 0
package/lean/ps3netsrv/files/ps3netsrv.init | 0
.../shortcut-fe/files/usr/bin/sfe_dump | 0
package/lean/srelay/files/srelay.init | 0
package/lean/tcpping/Makefile | 76 ++--
package/lean/vlmcsd/files/vlmcsd.init | 0
package/lean/vsftpd-alt/files/vsftpd-uci.init | 0
package/lean/vsftpd-alt/files/vsftpd.init | 0
155 files changed, 804 insertions(+), 793 deletions(-)
mode change 100644 => 100755 package/lean/ddns-scripts_dnspod/update_dnspod_cn.sh
mode change 100644 => 100755 package/lean/ddns-scripts_dnspod/update_dnspod_com.sh
mode change 100755 => 100644 package/lean/dns2socks/Makefile
mode change 100644 => 100755 package/lean/dsmboot/files/dsmboot
mode change 100644 => 100755 package/lean/ipv6-helper/files/root/etc/hotplug.d/iface/60-6in4
mode change 100644 => 100755 package/lean/k3-brcmfmac4366c-firmware/files/lib/firmware/brcm/brcmfmac4366c-pcie.bin
mode change 100644 => 100755 package/lean/luci-app-amule/root/etc/hotplug.d/iface/20-amule
mode change 100755 => 100644 package/lean/luci-app-arpbind/Makefile
mode change 100644 => 100755 package/lean/luci-app-cifsd/root/etc/uci-defaults/luci-cifsd
mode change 100755 => 100644 package/lean/luci-app-docker/Makefile
mode change 100755 => 100644 package/lean/luci-app-easymesh/Makefile
mode change 100755 => 100644 package/lean/luci-app-easymesh/luasrc/controller/easymesh.lua
mode change 100755 => 100644 package/lean/luci-app-easymesh/luasrc/model/cbi/easymesh.lua
mode change 100755 => 100644 package/lean/luci-app-easymesh/root/etc/config/easymesh
rename package/lean/luci-app-familycloud/luasrc/model/cbi/familycloud/{familycloudlog.lua => familycloud_log.lua} (87%)
mode change 100644 => 100755 package/lean/luci-app-frps/root/etc/init.d/frps
mode change 100644 => 100755 package/lean/luci-app-frps/root/etc/uci-defaults/40_luci-frps
mode change 100755 => 100644 package/lean/luci-app-haproxy-tcp/luasrc/controller/haproxy.lua
mode change 100755 => 100644 package/lean/luci-app-haproxy-tcp/luasrc/model/cbi/haproxy.lua
rename package/lean/luci-app-ipsec-vpnd/luasrc/model/cbi/{ipsec-server => }/ipsec-server.lua (90%)
rename package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/{download.htm => kodexplorer_download.htm} (99%)
rename package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/{status.htm => kodexplorer_status.htm} (98%)
rename package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/{version.htm => kodexplorer_version.htm} (97%)
create mode 100644 package/lean/luci-app-n2n_v2/luasrc/view/n2n_v2/n2n_v2_status.htm
delete mode 100644 package/lean/luci-app-n2n_v2/luasrc/view/n2n_v2/status.htm
mode change 100644 => 100755 package/lean/luci-app-nfs/root/etc/uci-defaults/luci-nfs
mode change 100755 => 100644 package/lean/luci-app-nps/luasrc/view/nps/nps_status.htm
mode change 100755 => 100644 package/lean/luci-app-nps/root/etc/config/nps
rename package/lean/luci-app-pptp-server/luasrc/model/cbi/{pptp-server => }/pptp-server.lua (89%)
rename package/lean/luci-app-pptp-server/luasrc/view/{pptp/pptp_status.htm => pptp-server/pptp-server_status.htm} (85%)
rename package/lean/luci-app-pptp-server/root/etc/uci-defaults/{pptpd => luci-pptpd} (100%)
mode change 100755 => 100644 package/lean/luci-app-syncdial/Makefile
mode change 100644 => 100755 package/lean/luci-app-syncdial/root/etc/hotplug.d/iface/01-dialcheck
mode change 100644 => 100755 package/lean/luci-app-syncdial/root/etc/hotplug.d/iface/01-mvifcreate
mode change 100644 => 100755 package/lean/luci-app-uugamebooster/root/etc/uci-defaults/45_luci-uuplugin
mode change 100644 => 100755 package/lean/luci-theme-argon/root/etc/uci-defaults/30_luci-theme-argon
mode change 100755 => 100644 package/lean/luci-theme-netgear/luasrc/view/themes/netgear/footer.htm
mode change 100755 => 100644 package/lean/luci-theme-netgear/luasrc/view/themes/netgear/header.htm
mode change 100644 => 100755 package/lean/n2n_v2/files/n2n_v2.init
mode change 100644 => 100755 package/lean/ntfs3-mount/files/mount.ntfs3
mode change 100644 => 100755 package/lean/pdnsd-alt/files/pdnsd.init
mode change 100644 => 100755 package/lean/ps3netsrv/files/ps3netsrv.init
mode change 100644 => 100755 package/lean/shortcut-fe/shortcut-fe/files/usr/bin/sfe_dump
mode change 100644 => 100755 package/lean/srelay/files/srelay.init
mode change 100644 => 100755 package/lean/vlmcsd/files/vlmcsd.init
mode change 100644 => 100755 package/lean/vsftpd-alt/files/vsftpd-uci.init
mode change 100644 => 100755 package/lean/vsftpd-alt/files/vsftpd.init
diff --git a/package/lean/ddns-scripts_dnspod/update_dnspod_cn.sh b/package/lean/ddns-scripts_dnspod/update_dnspod_cn.sh
old mode 100644
new mode 100755
diff --git a/package/lean/ddns-scripts_dnspod/update_dnspod_com.sh b/package/lean/ddns-scripts_dnspod/update_dnspod_com.sh
old mode 100644
new mode 100755
diff --git a/package/lean/dns2socks/Makefile b/package/lean/dns2socks/Makefile
old mode 100755
new mode 100644
diff --git a/package/lean/dsmboot/files/dsmboot b/package/lean/dsmboot/files/dsmboot
old mode 100644
new mode 100755
diff --git a/package/lean/ipv6-helper/files/root/etc/hotplug.d/iface/60-6in4 b/package/lean/ipv6-helper/files/root/etc/hotplug.d/iface/60-6in4
old mode 100644
new mode 100755
diff --git a/package/lean/k3-brcmfmac4366c-firmware/files/lib/firmware/brcm/brcmfmac4366c-pcie.bin b/package/lean/k3-brcmfmac4366c-firmware/files/lib/firmware/brcm/brcmfmac4366c-pcie.bin
old mode 100644
new mode 100755
diff --git a/package/lean/luci-app-adbyby-plus/Makefile b/package/lean/luci-app-adbyby-plus/Makefile
index bd8c1e99d..f7f3628b6 100644
--- a/package/lean/luci-app-adbyby-plus/Makefile
+++ b/package/lean/luci-app-adbyby-plus/Makefile
@@ -15,4 +15,3 @@ PKG_RELEASE:=75
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
diff --git a/package/lean/luci-app-adbyby-plus/luasrc/controller/adbyby.lua b/package/lean/luci-app-adbyby-plus/luasrc/controller/adbyby.lua
index 8945605d6..85adb1466 100644
--- a/package/lean/luci-app-adbyby-plus/luasrc/controller/adbyby.lua
+++ b/package/lean/luci-app-adbyby-plus/luasrc/controller/adbyby.lua
@@ -21,16 +21,16 @@ function index()
end
function act_status()
- local e={}
- e.running=luci.sys.call("pgrep adbyby >/dev/null")==0
+ local e = {}
+ e.running = luci.sys.call("pgrep adbyby >/dev/null") == 0
luci.http.prepare_content("application/json")
luci.http.write_json(e)
end
function refresh_data()
- local set =luci.http.formvalue("set")
- local icount =0
+ local set = luci.http.formvalue("set")
+ local icount = 0
if set == "rule_data" then
luci.sys.exec("/usr/share/adbyby/rule-update")
@@ -38,7 +38,7 @@ luci.sys.exec("/usr/share/adbyby/rule-update")
if tonumber(icount)>0 then
if nixio.fs.access("/usr/share/adbyby/rules/") then
- oldcount=luci.sys.exec("/usr/share/adbyby/rule-count '/usr/share/adbyby/rules/'")
+ oldcount = luci.sys.exec("/usr/share/adbyby/rule-count '/usr/share/adbyby/rules/'")
else
oldcount=0
end
@@ -54,14 +54,14 @@ luci.sys.exec("/usr/share/adbyby/rule-update")
retstring ="0"
end
else
-refresh_cmd="uclient-fetch -q --no-check-certificate -O - 'https://easylist-downloads.adblockplus.org/easylistchina+easylist.txt' > /tmp/adnew.conf"
-sret=luci.sys.call(refresh_cmd .. " 2>/dev/null")
+refresh_cmd = "uclient-fetch -q --no-check-certificate -O - 'https://easylist-downloads.adblockplus.org/easylistchina+easylist.txt' > /tmp/adnew.conf"
+sret = luci.sys.call(refresh_cmd .. " 2>/dev/null")
if sret== 0 then
luci.sys.call("/usr/share/adbyby/ad-update")
icount = luci.sys.exec("cat /tmp/ad.conf | wc -l")
if tonumber(icount)>0 then
if nixio.fs.access("/usr/share/adbyby/dnsmasq.adblock") then
- oldcount=luci.sys.exec("cat /usr/share/adbyby/dnsmasq.adblock | wc -l")
+ oldcount = luci.sys.exec("cat /usr/share/adbyby/dnsmasq.adblock | wc -l")
else
oldcount=0
end
@@ -83,4 +83,4 @@ end
end
luci.http.prepare_content("application/json")
luci.http.write_json({ ret=retstring ,retcount=icount})
-end
\ No newline at end of file
+end
diff --git a/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/advanced.lua b/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/advanced.lua
index 220943efb..1d9faa69a 100644
--- a/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/advanced.lua
+++ b/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/advanced.lua
@@ -54,4 +54,4 @@ end
o = s:option(DynamicList, "subscribe_url", translate("Anti-AD Rules Subscribe"))
o.rmempty = true
-return m
\ No newline at end of file
+return m
diff --git a/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/base.lua b/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/base.lua
index 3081e89e8..b9872cb19 100644
--- a/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/base.lua
+++ b/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/base.lua
@@ -18,21 +18,18 @@ m:section(SimpleSection).template = "adbyby/adbyby_status"
s = m:section(TypedSection, "adbyby")
s.anonymous = true
-o = s:option(Flag, "enable")
-o.title = translate("Enable")
+o = s:option(Flag, "enable", translate("Enable"))
o.default = 0
o.rmempty = false
-o = s:option(ListValue, "wan_mode")
-o.title = translate("Running Mode")
+o = s:option(ListValue, "wan_mode", translate("Running Mode"))
o:value("0", translate("Global Mode (The slowest and the best effects)"))
o:value("1", translate("Plus + Mode (Filter domain name list and blacklist website.Recommended)"))
o:value("2", translate("No filter Mode (Must set in Client Filter Mode Settings manually)"))
o.default = 1
o.rmempty = false
-o = s:option(Button, "restart")
-o.title = translate("Adbyby and Rule state")
+o = s:option(Button, "restart", translate("Adbyby and Rule state"))
o.inputtitle = translate("Update Adbyby Rules Manually")
o.description = string.format(""..translate("Last Update Checked")..": %s
"..translate("Lazy Rule")..":%s
"..translate("Video Rule")..":%s", UD, DL, DV)
o.inputstyle = "reload"
@@ -42,28 +39,28 @@ o.write = function()
HTTP.redirect(DISP.build_url("admin", "services", "adbyby"))
end
-t=m:section(TypedSection,"acl_rule",translate("Client Filter Mode Settings"),
-translate("Filter mode settings can be set to specific LAN clients ( No filter , Global filter ) . Does not need to be set by default."))
-t.template="cbi/tblsection"
-t.sortable=true
-t.anonymous=true
-t.addremove=true
+t = m:section(TypedSection, "acl_rule", translate("Client Filter Mode Settings"))
+t.description = translate("Filter mode settings can be set to specific LAN clients ( No filter , Global filter ) . Does not need to be set by default.")
+t.template = "cbi/tblsection"
+t.sortable = true
+t.anonymous = true
+t.addremove = true
-e=t:option(Value,"ipaddr",translate("IP Address"))
-e.width="40%"
-e.datatype="ip4addr"
-e.placeholder="0.0.0.0/0"
+e = t:option(Value, "ipaddr", translate("IP Address"))
+e.width = "40%"
+e.datatype = "ip4addr"
+e.placeholder = "0.0.0.0/0"
luci.ip.neighbors({ family = 4 }, function(entry)
if entry.reachable then
e:value(entry.dest:string())
end
end)
-e=t:option(ListValue,"filter_mode",translate("Filter Mode"))
-e.width="40%"
-e.default="disable"
-e.rmempty=false
-e:value("disable",translate("No filter"))
-e:value("global",translate("Global filter"))
+e = t:option(ListValue, "filter_mode", translate("Filter Mode"))
+e.width = "40%"
+e.default = "disable"
+e.rmempty = false
+e:value("disable", translate("No filter"))
+e:value("global", translate("Global filter"))
-return m
\ No newline at end of file
+return m
diff --git a/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/black.lua b/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/black.lua
index 4d571ed19..3fd32ec4e 100644
--- a/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/black.lua
+++ b/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/black.lua
@@ -21,4 +21,3 @@ function f.handle(self, state, data)
end
return f
-
diff --git a/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/block.lua b/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/block.lua
index 50c739762..dd715fd88 100644
--- a/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/block.lua
+++ b/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/block.lua
@@ -21,4 +21,3 @@ function f.handle(self, state, data)
end
return f
-
diff --git a/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/esc.lua b/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/esc.lua
index 78d37f56c..5c6f168a1 100644
--- a/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/esc.lua
+++ b/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/esc.lua
@@ -21,4 +21,3 @@ function f.handle(self, state, data)
end
return f
-
diff --git a/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/help.lua b/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/help.lua
index 438c34d72..a0c20b90d 100644
--- a/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/help.lua
+++ b/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/help.lua
@@ -21,4 +21,3 @@ function f.handle(self, state, data)
end
return f
-
diff --git a/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/user.lua b/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/user.lua
index 3c4498db0..13887db99 100644
--- a/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/user.lua
+++ b/package/lean/luci-app-adbyby-plus/luasrc/model/cbi/adbyby/user.lua
@@ -21,4 +21,3 @@ function f.handle(self, state, data)
end
return f
-
diff --git a/package/lean/luci-app-adbyby-plus/luasrc/view/adbyby/adbyby_status.htm b/package/lean/luci-app-adbyby-plus/luasrc/view/adbyby/adbyby_status.htm
index 6e9be7264..3b2f40e06 100644
--- a/package/lean/luci-app-adbyby-plus/luasrc/view/adbyby/adbyby_status.htm
+++ b/package/lean/luci-app-adbyby-plus/luasrc/view/adbyby/adbyby_status.htm
@@ -19,4 +19,4 @@ XHR.poll(3, '<%=url([[admin]], [[services]], [[adbyby]], [[run]])%>', null,
<%:Collecting data...%>
- \ No newline at end of file + diff --git a/package/lean/luci-app-airplay2/Makefile b/package/lean/luci-app-airplay2/Makefile index 63a58f2bc..f51851538 100644 --- a/package/lean/luci-app-airplay2/Makefile +++ b/package/lean/luci-app-airplay2/Makefile @@ -15,4 +15,3 @@ PKG_RELEASE:=10 include $(TOPDIR)/feeds/luci/luci.mk # call BuildPackage - OpenWrt buildroot signature - diff --git a/package/lean/luci-app-airplay2/luasrc/controller/shairport-sync.lua b/package/lean/luci-app-airplay2/luasrc/controller/shairport-sync.lua index 177351c32..f33e9f7ea 100644 --- a/package/lean/luci-app-airplay2/luasrc/controller/shairport-sync.lua +++ b/package/lean/luci-app-airplay2/luasrc/controller/shairport-sync.lua @@ -13,8 +13,8 @@ function index() end function act_status() - local e={} - e.running=luci.sys.call("pgrep shairport-sync >/dev/null")==0 + local e = {} + e.running = luci.sys.call("pgrep shairport-sync >/dev/null") == 0 luci.http.prepare_content("application/json") luci.http.write_json(e) end diff --git a/package/lean/luci-app-airplay2/luasrc/model/cbi/shairport-sync.lua b/package/lean/luci-app-airplay2/luasrc/model/cbi/shairport-sync.lua index 86a25f82d..9e41bac30 100644 --- a/package/lean/luci-app-airplay2/luasrc/model/cbi/shairport-sync.lua +++ b/package/lean/luci-app-airplay2/luasrc/model/cbi/shairport-sync.lua @@ -1,25 +1,27 @@ -- Copyright 2020 Lean<%:Collecting data...%>
- \ No newline at end of file + diff --git a/package/lean/luci-app-amule/Makefile b/package/lean/luci-app-amule/Makefile index bd1e1e63c..f67c0ff7c 100644 --- a/package/lean/luci-app-amule/Makefile +++ b/package/lean/luci-app-amule/Makefile @@ -12,4 +12,3 @@ LUCI_PKGARCH:=all include $(TOPDIR)/feeds/luci/luci.mk # call BuildPackage - OpenWrt buildroot signature - diff --git a/package/lean/luci-app-amule/luasrc/model/cbi/amule.lua b/package/lean/luci-app-amule/luasrc/model/cbi/amule.lua index b18138f85..a81958c95 100644 --- a/package/lean/luci-app-amule/luasrc/model/cbi/amule.lua +++ b/package/lean/luci-app-amule/luasrc/model/cbi/amule.lua @@ -27,7 +27,7 @@ end m = Map("amule", translate("aMule"), translate("aMule is a ED2K/KAD client for all platforms.") .. "
-local fs = require "nixio.fs"
-local CONFIG_FILE = "/tmp/dnsforwarder.conf";
-
-function sync_value_to_file(value, file)
- value = value:gsub("\r\n?", "\n")
- local old_value = nixio.fs.readfile(file)
- if value ~= old_value then
- nixio.fs.writefile(file, value)
- end
-
-end
-local state_msg = ""
-
-local dnsforwarder_on = (luci.sys.call("pidof dnsforwarder > /dev/null") == 0)
-local resolv_file = luci.sys.exec("uci get dhcp.@dnsmasq[0].resolvfile")
-local listen_port = luci.sys.exec("uci get dhcp.@dnsmasq[0].server")
-
-if dnsforwarder_on then
- state_msg = "" .. translate("Running") .. ""
-else
- state_msg = "" .. translate("Not running") .. ""
-end
-
-
-if dnsforwarder_on and string.sub(listen_port,1,14) == "127.0.0.1#5053" then
- state_msg=state_msg .. ",DNSmasq已经将流量定向至本软件"
-elseif dnsforwarder_on then
- state_msg=state_msg .. ""
-end
-
-if resolv_file=="" then
-
-else if dnsforwarder_on then
- state_msg=state_msg .. ""
- end
-end
-m=Map("dnsforwarder",translate("dnsforwarder"),translate("Dnsforwarder是企业级DNS服务器,可以通过TCP协议进行DNS解析,可以方便的使用iptables进行透明代理,配合ipset、GFWList使用效果更佳。默认上游服务器为114DNS,SSR和Redsocks的GFWList模式要依赖本软件包提供的功能").. "
状态 - " .. state_msg)
-s=m:section(TypedSection,"arguments", translate("通用配置"))
-s.addremove=false
-s.anonymous=true
- view_enable = s:option(Flag,"enabled",translate("Enable"))
- view_dnsmasq = s:option(Flag,"dnsmasq",translate("设置成DNSmasq的上游服务器"),translate("让DNSMasq从本软件获得解析结果,支持GFWList模式"))
- view_addr = s:option(Value,"addr",translate("转发地址"),translate("请填写dnsforwarder的监听地址,默认127.0.0.1:5053,如果填写208.67.222.222:5353那么可不通过该软件获得无污染结果"))
- view_addr.default = "127.0.0.1:5053"
-
--- ---------------------------------------------------
-s1=m:section(TypedSection,"config",translate("标准配置"))
-s1.addremove=false
-s1.anonymous=true
- log_enable = s1:option(Flag,"log",translate("打开文件日志"))
- log_enable.rmempty=false
- log_enable.default="false"
- log_enable.disabled="false"
- log_enable.enabled="true"
- log_size = s1:option(Value,"log_size",translate("单个日志文件大小的临界值(字节)"),translate("当日志文件大小超过这个临界值后,当前的日志文件将会被重命名,然后建立一个新的日志文件,继续记录日志"))
- log_size.datatype="uinteger"
- log_size.default="102400"
- log_size:depends ({log="true"})
- log_path = s1:option(Value,"log_path",translate("设定日志文件所在的文件夹"),translate("日志文件初始的文件名为 `dnsforwarder.log',当超过临界值之后,将会被重命名为 `dnsforwarder.log.1'、`dnsforwarder.log.2' 等等,然后重新建立一个 dnsforwarder.log' 文件"))
- log_path.datatype="directory"
- log_path.default="/var/log/"
- log_path.readonly=true
- log_path:depends ({log="true"})
- gfw_enable = s1:option(Flag,"gfw",translate("使用GFW列表"))
- gfw_enable.rmempty=false
- gfw_enable.default="true"
- gfw_enable.disabled="false"
- gfw_enable.enabled="true"
- udp_local = s1:option(DynamicList,"udp_local",translate("本地监听"),translate("设置在本地开启的接口的IP地址和端口,可以是本地回环地址 (127.0.0.1) ,本地局域网,以及互联网
如果是 IPv6 地址,请在IP两端加上方括号(不包含端口部分),例如 [::1]:53 (本地回环)、[fe80::699c:f79a:9bb6:1]:5353
如果不指定端口,则默认为 53"))
- tcp_group = s1:option(DynamicList,"tcp_group",translate("解析策略(TCP)"),translate([[格式:<IP1[:PORT],IP2[:PORT],...> <DOMAIN1,DOMAIN2,...> <on|PROXY1[:PORT],PROXY2[:PORT],...>
- 设置一个 TCP 上游服务器组,并指定通过这些上游服务器查询的域名
- 第一部分参数“<IP1[:PORT],IP2[:PORT],...>”,用于指定 TCP 上游服务器,不写端口则默认使用 53 端口
- 第二部分参数“<DOMAIN1,DOMAIN2,...>”,用于指定通过这些 TCP 上游服务器查询的域名,可以包含通配符
- 第三部分参数“<no|PROXY1[:PORT],PROXY2[:PORT],...>”,用于指定查询时使用的 Socks5 代理,不写端口则默认使用 1080 端口。`no' 代表不使用代理]]))
- tcp_group.placeholder = "8.8.8.8 * on"
- tcp_group.default=tcp_group.placeholder
- udp_group = s1:option(DynamicList,"udp_group",translate("解析策略(UDP)"),translate([[格式:<IP1[:PORT],IP2[:PORT],...> <DOMAIN1,DOMAIN2,...> <on|off>
- 设置一个 UDP 上游服务器组,并指定通过这些上游服务器查询的域名
- 第一部分参数“<IP1[:PORT],IP2[:PORT],...>”,用于指定 UDP 上游服务器,不写端口则默认使用 53 端口
- 第二部分参数“<DOMAIN1,DOMAIN2,...>”,用于指定通过这些 UDP 上游服务器查询的域名,可以包含通配符
- 第三部分参数“<on|off>”,用于指定是否开启并发查询,`on' 为开启,`off' 为不开启
- 并发查询指的是,向所有指定的 UDP 服务器发送查询请求,取最先接受到的未屏蔽的回复作为查询结果,并丢弃其余的回复]]))
- udp_group.placeholder = "9.9.9.9,119.29.29.29,223.5.5.5,114.114.114.114 * on"
- udp_group.default=udp_group.placeholder
- group_file = s1:option(DynamicList,"group_file",translate("解析策略(文件)"),translate([[
- 从文件加载服务器组,
- 服务器组文件的写法点击这里查看。]]))
- group_file.datatype="file"
- s1:option(DummyValue,"nothing"," ",translate([[
- 解析策略优先级:解析策略(TCP)>解析策略(UDP)>解析策略(文件)
- 1.对于没有指定服务器的域名,会随机选择一个服务器组进行查询。
- 2.如果某域名匹配多个服务器组,则选择的顺序如下:
- 2.1 优先选择不含通配符的匹配项,如果仍然有多条匹配,则选择匹配度最高的那个,
- 如果匹配度相同的情况下仍然有多条匹配,则选择最后一个。
- (例如 `ipv6.microsoft.com' 比 `microsoft.com' 对于域名 `teredo.ipv6.microsoft.com' 的匹配度更高)
- 2.2 然后选择包含通配符的匹配项,如果有多条匹配,则选择第一个.
- ]]))
- block_ip = s1:option(DynamicList,"block_ip",translate("DNS黑名单"),translate("阻挡含有以上 IP 地址的 DNS 数据包,IPv6 地址不用加方括号"))
- block_ip.datatype="ipaddr"
- block_ip.delimiter = ","
- ip_substituting = s1:option(DynamicList,"ip_substituting",translate("替换 DNS 数据包"),translate("替换 DNS 数据包中的 IP 地址(只支持 IPv4 地址),例如:
127.0.0.1 1.2.0.127
的效果是把 DNS 数据包中所有的 127.0.0.1 地址替换为 1.2.0.127,仅替换通过服务器(TCP 和 UDP)查询而来的 DNS 数据包,对于缓存中和 Hosts 中的结果无效"))
- ip_substituting.placeholder = "127.0.0.1 1.2.0.127"
- block_negative_resp = s1:option(Flag,"block_negative_resp",translate("过滤失败请求"),translate("是否过滤来自上游服务器的查询未成功的响应。查询未成功指:格式错误、服务器错误、域名不存在和服务器拒绝请求等,参见 RFC 6895,`2.3. RCODE Assignment'"))
- block_negative_resp.rmempty=false
- block_negative_resp.default="false"
- block_negative_resp.disabled="false"
- block_negative_resp.enabled="true"
- append_host = s1:option(DynamicList,"append_host",translate("附加hosts"),translate([[
- 写法与HOSTS文件中的一样,同样支持通配符,IPv6 地址不用加方括号
- 也可以定义 CName 的 Hosts 项,例如:www.google.cn *.google.com
,这样所有匹配 *.google.com 的域名都将指向 www.google.cn 的 IP 地址
- 如果使某些域名跳过在 hosts 中的查询,可以@@ *.012345.com
这样所有匹配 *.012345.com 的域名都不会在 hosts 中查询
- 各种 hosts 的优先级从高到低:1.带 `@@' 的禁止项 2.一般 hosts 项 3.CName hosts 项
- ]]))
- block_ipv6 = s1:option(Flag,"block_ipv6",translate("拒绝IPv6 地址"),translate("如果一个域名在 Hosts 被指定了一个 IPv4 地址(包括文件 Hosts 和 `AppendHosts' 指定的 Hosts),那么拒绝对这个域名的 IPv6 地址查询"))
- block_ipv6.rmempty=false
- block_ipv6.default="false"
- block_ipv6.disabled="false"
- block_ipv6.enabled="true"
-
- cache = s1:option(Flag,"cache",translate("使用缓存"),translate("是否使用缓存"))
- cache.rmempty=false
- cache.default="false"
- cache.disabled="false"
- cache.enabled="true"
- cache_size = s1:option(Value,"cache_size",translate("缓存大小 (字节)"),translate("缓存大小不能小于 102400 (100KB)"))
- cache_size.datatype="min(102400)"
- cache_size.default="1048576"
- cache_size:depends ({cache="true"})
- cache_file = s1:option(Value,"cache_file",translate("缓存文件"))
- cache_file.default="/tmp/dnsforwarder.cache"
- cache_file.readonly=true
- cache_file:depends ({cache="true"})
- cache_ignore = s1:option(Flag,"cache_ignore",translate("忽略TTL"),translate("为 `true' 时将忽略 TTL,此时所有的缓存条目将不会被移除,为 `false' 时不忽略 TTL,缓存条目将会按照 TTL 的时间来移除"))
- cache_ignore.rmempty=false
- cache_ignore.default="false"
- cache_ignore.disabled="false"
- cache_ignore.enabled="true"
- cache_ignore:depends ({cache="true"})
- cache_control = s1:option(DynamicList,"cache_control",translate("控制域名的缓存行为"),translate([[
- 单条格式:<DOMAIN> [$ [$] ]<TYPE> [ARGUMENT]
- <DOMAIN> 是域名;[$ [$] ] 是传染设定;<TYPE> 是类型;[ARGUMENT] 是参数
- <DOMAIN> 支持通配符,支持尾部匹配
- <TYPE> 有以下可选项(均为小写):
- orig : 使用原先的 TTL,即不改变指定域名记录的 TTL,此类型无需 [ARGUMENT] 参数
- nocache : 不缓存指定域名记录,此类型无需 [ARGUMENT] 参数
- fixed : 将指定域名记录的 TTL 修改为一个预先指定的常数值,这个值通过 [ARGUMENT] 参数指定
- vari : 将指定域名记录的 TTL 修改为一个预先规定的变量,这个变量通过 [ARGUMENT] 参数指定,此时 [ARGUMENT] 参数的格式为 `ax+b',其中 a、b 为非负整数(需用户手工指定),x 为记录原先的 TTL 值(不需要用户指定)。此选项必须为 `ax+b' 的形式,不能是 `ax-b' 或者其它的变体形
-
传染机制:
- 主动传染 (此为默认情况):主动传染 : 所有的域名记录不论是否存在单独指定的控制条目,均使用上级域名控制条目
- 被动传染(<TYPE> 前加一个 `$'): 如果存在单独指定的控制条目,那么使用单独指定的控制条目,否则使用上级域名的控制条目
- 不传染( 前加两个 `$'): 如果存在单独指定的控制条目,那么使用单独指定的控制条目,如果没有则不修改记录的 TTL 值
- 只有被查询的域名控制条目才具有传染性质
-
常见例子:
- * fixed 300
强制使所有缓存的条目的 TTL 为 300
- * vari 2x+0
将所有缓存条目的 TTL 加倍。即原来为300,现在为600
- ]]))
- cache_control:depends ({cache="true"})
-
- domain_statistic = s1:option(Flag,"domain_statistic",translate("启用域名统计"),translate("域名信息统计会依照模板文件记录域名的查询情况目前只能生成到/root/.dnsforwarder/statistic.html
会影响闪存寿命不建议开启"))
- domain_statistic.rmempty=false
- domain_statistic.default="false"
- domain_statistic.disabled="false"
- domain_statistic.enabled="true"
-
- view_cfg = s1:option(TextValue, "1", nil)
- view_cfg.rmempty = false
- view_cfg.rows = 24
- view_cfg.readonly=true
-
- function view_cfg.cfgvalue()
- return nixio.fs.readfile(CONFIG_FILE) or ""
- end
- function view_cfg.write(self, section, value)
- end
-
--- ---------------------------------------------------
-local apply = luci.http.formvalue("cbi.apply")
-if apply then
- os.execute("/etc/init.d/dnsforwarder makeconfig >/dev/null 2>&1 &")
- os.execute("/etc/init.d/dnsforwarder restart >/dev/null 2>&1 &")
-end
-
-return m
+--Alex<1886090@gmail.com>
+--Dennis
+local fs = require "nixio.fs"
+local CONFIG_FILE = "/tmp/dnsforwarder.conf";
+
+function sync_value_to_file(value, file)
+ value = value:gsub("\r\n?", "\n")
+ local old_value = nixio.fs.readfile(file)
+ if value ~= old_value then
+ nixio.fs.writefile(file, value)
+ end
+
+end
+local state_msg = ""
+
+local dnsforwarder_on = (luci.sys.call("pidof dnsforwarder > /dev/null") == 0)
+local resolv_file = luci.sys.exec("uci get dhcp.@dnsmasq[0].resolvfile")
+local listen_port = luci.sys.exec("uci get dhcp.@dnsmasq[0].server")
+
+if dnsforwarder_on then
+ state_msg = "" .. translate("Running") .. ""
+else
+ state_msg = "" .. translate("Not running") .. ""
+end
+
+
+if dnsforwarder_on and string.sub(listen_port,1,14) == "127.0.0.1#5053" then
+ state_msg = state_msg .. ",DNSmasq已经将流量定向至本软件"
+elseif dnsforwarder_on then
+ state_msg = state_msg .. ""
+end
+
+if resolv_file=="" then
+
+else if dnsforwarder_on then
+ state_msg = state_msg .. ""
+ end
+end
+
+m = Map("dnsforwarder",translate("dnsforwarder"),translate("Dnsforwarder是企业级DNS服务器,可以通过TCP协议进行DNS解析,可以方便的使用iptables进行透明代理,配合ipset、GFWList使用效果更佳。默认上游服务器为114DNS,SSR和Redsocks的GFWList模式要依赖本软件包提供的功能").. "
状态 - " .. state_msg)
+s = m:section(TypedSection,"arguments", translate("通用配置"))
+s.addremove=false
+s.anonymous=true
+ view_enable = s:option(Flag,"enabled",translate("Enable"))
+ view_dnsmasq = s:option(Flag,"dnsmasq",translate("设置成DNSmasq的上游服务器"),translate("让DNSMasq从本软件获得解析结果,支持GFWList模式"))
+ view_addr = s:option(Value,"addr",translate("转发地址"),translate("请填写dnsforwarder的监听地址,默认127.0.0.1:5053,如果填写208.67.222.222:5353那么可不通过该软件获得无污染结果"))
+ view_addr.default = "127.0.0.1:5053"
+
+-- ---------------------------------------------------
+s1 = m:section(TypedSection,"config",translate("标准配置"))
+s1.addremove = false
+s1.anonymous = true
+ log_enable = s1:option(Flag,"log",translate("打开文件日志"))
+ log_enable.rmempty = false
+ log_enable.default = "false"
+ log_enable.disabled = "false"
+ log_enable.enabled = "true"
+ log_size = s1:option(Value,"log_size",translate("单个日志文件大小的临界值(字节)"),translate("当日志文件大小超过这个临界值后,当前的日志文件将会被重命名,然后建立一个新的日志文件,继续记录日志"))
+ log_size.datatype = "uinteger"
+ log_size.default = "102400"
+ log_size:depends ({log="true"})
+ log_path = s1:option(Value,"log_path",translate("设定日志文件所在的文件夹"),translate("日志文件初始的文件名为 `dnsforwarder.log',当超过临界值之后,将会被重命名为 `dnsforwarder.log.1'、`dnsforwarder.log.2' 等等,然后重新建立一个 dnsforwarder.log' 文件"))
+ log_path.datatype = "directory"
+ log_path.default = "/var/log/"
+ log_path.readonly = true
+ log_path:depends ({log="true"})
+ gfw_enable = s1:option(Flag,"gfw",translate("使用GFW列表"))
+ gfw_enable.rmempty = false
+ gfw_enable.default = "true"
+ gfw_enable.disabled = "false"
+ gfw_enable.enabled = "true"
+ udp_local = s1:option(DynamicList,"udp_local",translate("本地监听"),translate("设置在本地开启的接口的IP地址和端口,可以是本地回环地址 (127.0.0.1) ,本地局域网,以及互联网
如果是 IPv6 地址,请在IP两端加上方括号(不包含端口部分),例如 [::1]:53 (本地回环)、[fe80::699c:f79a:9bb6:1]:5353
如果不指定端口,则默认为 53"))
+ tcp_group = s1:option(DynamicList,"tcp_group",translate("解析策略(TCP)"),translate([[格式:<IP1[:PORT],IP2[:PORT],...> <DOMAIN1,DOMAIN2,...> <on|PROXY1[:PORT],PROXY2[:PORT],...>
+ 设置一个 TCP 上游服务器组,并指定通过这些上游服务器查询的域名
+ 第一部分参数“<IP1[:PORT],IP2[:PORT],...>”,用于指定 TCP 上游服务器,不写端口则默认使用 53 端口
+ 第二部分参数“<DOMAIN1,DOMAIN2,...>”,用于指定通过这些 TCP 上游服务器查询的域名,可以包含通配符
+ 第三部分参数“<no|PROXY1[:PORT],PROXY2[:PORT],...>”,用于指定查询时使用的 Socks5 代理,不写端口则默认使用 1080 端口。`no' 代表不使用代理]]))
+ tcp_group.placeholder = "8.8.8.8 * on"
+ tcp_group.default = tcp_group.placeholder
+ udp_group = s1:option(DynamicList,"udp_group",translate("解析策略(UDP)"),translate([[格式:<IP1[:PORT],IP2[:PORT],...> <DOMAIN1,DOMAIN2,...> <on|off>
+ 设置一个 UDP 上游服务器组,并指定通过这些上游服务器查询的域名
+ 第一部分参数“<IP1[:PORT],IP2[:PORT],...>”,用于指定 UDP 上游服务器,不写端口则默认使用 53 端口
+ 第二部分参数“<DOMAIN1,DOMAIN2,...>”,用于指定通过这些 UDP 上游服务器查询的域名,可以包含通配符
+ 第三部分参数“<on|off>”,用于指定是否开启并发查询,`on' 为开启,`off' 为不开启
+ 并发查询指的是,向所有指定的 UDP 服务器发送查询请求,取最先接受到的未屏蔽的回复作为查询结果,并丢弃其余的回复]]))
+ udp_group.placeholder = "9.9.9.9,119.29.29.29,223.5.5.5,114.114.114.114 * on"
+ udp_group.default = udp_group.placeholder
+ group_file = s1:option(DynamicList,"group_file",translate("解析策略(文件)"),translate([[
+ 从文件加载服务器组,
+ 服务器组文件的写法点击这里查看。]]))
+ group_file.datatype = "file"
+ s1:option(DummyValue,"nothing"," ",translate([[
+ 解析策略优先级:解析策略(TCP)>解析策略(UDP)>解析策略(文件)
+ 1.对于没有指定服务器的域名,会随机选择一个服务器组进行查询。
+ 2.如果某域名匹配多个服务器组,则选择的顺序如下:
+ 2.1 优先选择不含通配符的匹配项,如果仍然有多条匹配,则选择匹配度最高的那个,
+ 如果匹配度相同的情况下仍然有多条匹配,则选择最后一个。
+ (例如 `ipv6.microsoft.com' 比 `microsoft.com' 对于域名 `teredo.ipv6.microsoft.com' 的匹配度更高)
+ 2.2 然后选择包含通配符的匹配项,如果有多条匹配,则选择第一个.
+ ]]))
+ block_ip = s1:option(DynamicList,"block_ip",translate("DNS黑名单"),translate("阻挡含有以上 IP 地址的 DNS 数据包,IPv6 地址不用加方括号"))
+ block_ip.datatype = "ipaddr"
+ block_ip.delimiter = ","
+ ip_substituting = s1:option(DynamicList,"ip_substituting",translate("替换 DNS 数据包"),translate("替换 DNS 数据包中的 IP 地址(只支持 IPv4 地址),例如:
127.0.0.1 1.2.0.127
的效果是把 DNS 数据包中所有的 127.0.0.1 地址替换为 1.2.0.127,仅替换通过服务器(TCP 和 UDP)查询而来的 DNS 数据包,对于缓存中和 Hosts 中的结果无效"))
+ ip_substituting.placeholder = "127.0.0.1 1.2.0.127"
+ block_negative_resp = s1:option(Flag,"block_negative_resp",translate("过滤失败请求"),translate("是否过滤来自上游服务器的查询未成功的响应。查询未成功指:格式错误、服务器错误、域名不存在和服务器拒绝请求等,参见 RFC 6895,`2.3. RCODE Assignment'"))
+ block_negative_resp.rmempty = false
+ block_negative_resp.default = "false"
+ block_negative_resp.disabled = "false"
+ block_negative_resp.enabled = "true"
+ append_host = s1:option(DynamicList,"append_host",translate("附加hosts"),translate([[
+ 写法与HOSTS文件中的一样,同样支持通配符,IPv6 地址不用加方括号
+ 也可以定义 CName 的 Hosts 项,例如:www.google.cn *.google.com
,这样所有匹配 *.google.com 的域名都将指向 www.google.cn 的 IP 地址
+ 如果使某些域名跳过在 hosts 中的查询,可以@@ *.012345.com
这样所有匹配 *.012345.com 的域名都不会在 hosts 中查询
+ 各种 hosts 的优先级从高到低:1.带 `@@' 的禁止项 2.一般 hosts 项 3.CName hosts 项
+ ]]))
+ block_ipv6 = s1:option(Flag,"block_ipv6",translate("拒绝IPv6 地址"),translate("如果一个域名在 Hosts 被指定了一个 IPv4 地址(包括文件 Hosts 和 `AppendHosts' 指定的 Hosts),那么拒绝对这个域名的 IPv6 地址查询"))
+ block_ipv6.rmempty = false
+ block_ipv6.default = "false"
+ block_ipv6.disabled = "false"
+ block_ipv6.enabled = "true"
+
+ cache = s1:option(Flag,"cache",translate("使用缓存"),translate("是否使用缓存"))
+ cache.rmempty = false
+ cache.default = "false"
+ cache.disabled = "false"
+ cache.enabled = "true"
+ cache_size = s1:option(Value,"cache_size",translate("缓存大小 (字节)"),translate("缓存大小不能小于 102400 (100KB)"))
+ cache_size.datatype = "min(102400)"
+ cache_size.default = "1048576"
+ cache_size:depends ({cache="true"})
+ cache_file = s1:option(Value,"cache_file",translate("缓存文件"))
+ cache_file.default="/tmp/dnsforwarder.cache"
+ cache_file.readonly=true
+ cache_file:depends ({cache="true"})
+ cache_ignore = s1:option(Flag,"cache_ignore",translate("忽略TTL"),translate("为 `true' 时将忽略 TTL,此时所有的缓存条目将不会被移除,为 `false' 时不忽略 TTL,缓存条目将会按照 TTL 的时间来移除"))
+ cache_ignore.rmempty=false
+ cache_ignore.default = "false"
+ cache_ignore.disabled = "false"
+ cache_ignore.enabled = "true"
+ cache_ignore:depends ({cache="true"})
+ cache_control = s1:option(DynamicList,"cache_control",translate("控制域名的缓存行为"),translate([[
+ 单条格式:<DOMAIN> [$ [$] ]<TYPE> [ARGUMENT]
+ <DOMAIN> 是域名;[$ [$] ] 是传染设定;<TYPE> 是类型;[ARGUMENT] 是参数
+ <DOMAIN> 支持通配符,支持尾部匹配
+ <TYPE> 有以下可选项(均为小写):
+ orig : 使用原先的 TTL,即不改变指定域名记录的 TTL,此类型无需 [ARGUMENT] 参数
+ nocache : 不缓存指定域名记录,此类型无需 [ARGUMENT] 参数
+ fixed : 将指定域名记录的 TTL 修改为一个预先指定的常数值,这个值通过 [ARGUMENT] 参数指定
+ vari : 将指定域名记录的 TTL 修改为一个预先规定的变量,这个变量通过 [ARGUMENT] 参数指定,此时 [ARGUMENT] 参数的格式为 `ax+b',其中 a、b 为非负整数(需用户手工指定),x 为记录原先的 TTL 值(不需要用户指定)。此选项必须为 `ax+b' 的形式,不能是 `ax-b' 或者其它的变体形
+
传染机制:
+ 主动传染 (此为默认情况):主动传染 : 所有的域名记录不论是否存在单独指定的控制条目,均使用上级域名控制条目
+ 被动传染(<TYPE> 前加一个 `$'): 如果存在单独指定的控制条目,那么使用单独指定的控制条目,否则使用上级域名的控制条目
+ 不传染( 前加两个 `$'): 如果存在单独指定的控制条目,那么使用单独指定的控制条目,如果没有则不修改记录的 TTL 值
+ 只有被查询的域名控制条目才具有传染性质
+
常见例子:
+ * fixed 300
强制使所有缓存的条目的 TTL 为 300
+ * vari 2x+0
将所有缓存条目的 TTL 加倍。即原来为300,现在为600
+ ]]))
+ cache_control:depends ({cache="true"})
+
+ domain_statistic = s1:option(Flag,"domain_statistic",translate("启用域名统计"),translate("域名信息统计会依照模板文件记录域名的查询情况目前只能生成到/root/.dnsforwarder/statistic.html
会影响闪存寿命不建议开启"))
+ domain_statistic.rmempty = false
+ domain_statistic.default = "false"
+ domain_statistic.disabled = "false"
+ domain_statistic.enabled = "true"
+
+ view_cfg = s1:option(TextValue, "1", nil)
+ view_cfg.rmempty = false
+ view_cfg.rows = 24
+ view_cfg.readonly = true
+
+ function view_cfg.cfgvalue()
+ return nixio.fs.readfile(CONFIG_FILE) or ""
+ end
+ function view_cfg.write(self, section, value)
+ end
+
+-- ---------------------------------------------------
+local apply = luci.http.formvalue("cbi.apply")
+if apply then
+ os.execute("/etc/init.d/dnsforwarder makeconfig >/dev/null 2>&1 &")
+ os.execute("/etc/init.d/dnsforwarder restart >/dev/null 2>&1 &")
+end
+
+return m
diff --git a/package/lean/luci-app-dnsforwarder/luasrc/model/cbi/dnsforwarder/log.lua b/package/lean/luci-app-dnsforwarder/luasrc/model/cbi/dnsforwarder/log.lua
index 9a4830e6b..499fd375d 100644
--- a/package/lean/luci-app-dnsforwarder/luasrc/model/cbi/dnsforwarder/log.lua
+++ b/package/lean/luci-app-dnsforwarder/luasrc/model/cbi/dnsforwarder/log.lua
@@ -1,31 +1,28 @@
-local fs = require "nixio.fs"
-local log = "/var/log/dnsforwarder.log"
-
-function sync_value_to_file(value, file)
- value = value:gsub("\r\n?", "\n")
- local old_value = nixio.fs.readfile(file)
- if value ~= old_value then
- nixio.fs.writefile(file, value)
- end
-end
-
-m = Map("dnsforwarder", translate("运行日志"),translate("如果想观察日志,需要在配置文件中写明LogOn true 和 LogFileFolder /var/log"))
-s=m:section(TypedSection,"arguments","")
-s.addremove=false
-s.anonymous=true
-
-
-
-
-gfwlist = s:option(TextValue, "gfwlist",nil, nil)
-gfwlist.description = translate("日志文件默认位置:" .. log)
-gfwlist.rows = 26
-gfwlist.wrap = "off"
-gfwlist.cfgvalue = function(self, section)
- return fs.readfile(log) or ""
-end
-
-
-
-
-return m
\ No newline at end of file
+local fs = require "nixio.fs"
+local log = "/var/log/dnsforwarder.log"
+
+function sync_value_to_file(value, file)
+ value = value:gsub("\r\n?", "\n")
+ local old_value = nixio.fs.readfile(file)
+ if value ~= old_value then
+ nixio.fs.writefile(file, value)
+ end
+end
+
+m = Map("dnsforwarder")
+m.title = translate("运行日志")
+m.description = translate("如果想观察日志,需要在配置文件中写明LogOn true 和 LogFileFolder /var/log")
+
+s = m:section(TypedSection,"arguments","")
+s.addremove = false
+s.anonymous = true
+
+gfwlist = s:option(TextValue, "gfwlist",nil, nil)
+gfwlist.description = translate("日志文件默认位置:" .. log)
+gfwlist.rows = 26
+gfwlist.wrap = "off"
+gfwlist.cfgvalue = function(self, section)
+ return fs.readfile(log) or ""
+end
+
+return m
diff --git a/package/lean/luci-app-dnsforwarder/po/zh-cn/dnsforwarder.po b/package/lean/luci-app-dnsforwarder/po/zh-cn/dnsforwarder.po
index dbd444848..7fd8e0285 100644
--- a/package/lean/luci-app-dnsforwarder/po/zh-cn/dnsforwarder.po
+++ b/package/lean/luci-app-dnsforwarder/po/zh-cn/dnsforwarder.po
@@ -1,8 +1,8 @@
-msgid "Enable"
-msgstr "启用"
-
-msgid "Running"
-msgstr "运行中"
-
-msgid "Not running"
-msgstr "未运行"
+msgid "Enable"
+msgstr "启用"
+
+msgid "Running"
+msgstr "运行中"
+
+msgid "Not running"
+msgstr "未运行"
diff --git a/package/lean/luci-app-docker/Makefile b/package/lean/luci-app-docker/Makefile
old mode 100755
new mode 100644
index 7875680d4..d468ad0dc
--- a/package/lean/luci-app-docker/Makefile
+++ b/package/lean/luci-app-docker/Makefile
@@ -15,4 +15,3 @@ PKG_RELEASE:=12
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
diff --git a/package/lean/luci-app-docker/luasrc/controller/docker.lua b/package/lean/luci-app-docker/luasrc/controller/docker.lua
index 31d531ac8..eb5dadbc2 100644
--- a/package/lean/luci-app-docker/luasrc/controller/docker.lua
+++ b/package/lean/luci-app-docker/luasrc/controller/docker.lua
@@ -10,8 +10,8 @@ function index()
end
function act_status()
- local e={}
- e.running=luci.sys.call("pgrep /usr/bin/dockerd >/dev/null")==0
+ local e = {}
+ e.running = luci.sys.call("pgrep /usr/bin/dockerd >/dev/null") == 0
luci.http.prepare_content("application/json")
luci.http.write_json(e)
-end
\ No newline at end of file
+end
diff --git a/package/lean/luci-app-docker/luasrc/model/cbi/docker.lua b/package/lean/luci-app-docker/luasrc/model/cbi/docker.lua
index a2ea9f542..037f3ee87 100644
--- a/package/lean/luci-app-docker/luasrc/model/cbi/docker.lua
+++ b/package/lean/luci-app-docker/luasrc/model/cbi/docker.lua
@@ -8,7 +8,7 @@ end
m = Map("dockerd", "Docker CE", translate("Docker is a set of platform-as-a-service (PaaS) products that use OS-level virtualization to deliver software in packages called containers.") .. button)
-m:section(SimpleSection).template = "docker/docker_status"
+m:section(SimpleSection).template = "docker/docker_status"
s = m:section(TypedSection, "docker")
s.anonymous = true
@@ -17,7 +17,7 @@ wan_mode = s:option(Flag, "wan_mode", translate("Enable WAN access Docker"), tra
wan_mode.default = 0
wan_mode.rmempty = false
-o=s:option(DummyValue,"readme",translate(" "))
-o.description=translate(""..translate("Download DockerReadme.pdf").."")
+o = s:option(DummyValue,"readme",translate(" "))
+o.description = translate(""..translate("Download DockerReadme.pdf").."")
return m
diff --git a/package/lean/luci-app-docker/luasrc/view/docker/docker_status.htm b/package/lean/luci-app-docker/luasrc/view/docker/docker_status.htm
index 4d2c71468..f3cf6b761 100644
--- a/package/lean/luci-app-docker/luasrc/view/docker/docker_status.htm
+++ b/package/lean/luci-app-docker/luasrc/view/docker/docker_status.htm
@@ -19,4 +19,4 @@ XHR.poll(3, '<%=url([[admin]], [[services]], [[docker]], [[status]])%>', null,
<%:Collecting data...%>
-
\ No newline at end of file
+
diff --git a/package/lean/luci-app-docker/root/etc/config/dockerd b/package/lean/luci-app-docker/root/etc/config/dockerd
index b73c0a3e3..7f1e0880b 100644
--- a/package/lean/luci-app-docker/root/etc/config/dockerd
+++ b/package/lean/luci-app-docker/root/etc/config/dockerd
@@ -1,4 +1,3 @@
config docker
option wan_mode '0'
-
diff --git a/package/lean/luci-app-easymesh/Makefile b/package/lean/luci-app-easymesh/Makefile
old mode 100755
new mode 100644
diff --git a/package/lean/luci-app-easymesh/luasrc/controller/easymesh.lua b/package/lean/luci-app-easymesh/luasrc/controller/easymesh.lua
old mode 100755
new mode 100644
index 19e24ac82..a004058d5
--- a/package/lean/luci-app-easymesh/luasrc/controller/easymesh.lua
+++ b/package/lean/luci-app-easymesh/luasrc/controller/easymesh.lua
@@ -1,4 +1,4 @@
-#-- Copyright (C) 2021 dz
+-- Copyright (C) 2021 dz
module("luci.controller.easymesh", package.seeall)
@@ -8,7 +8,6 @@ function index()
end
local page
-
page = entry({"admin", "network", "easymesh"}, cbi("easymesh"), _("EASY MESH"), 60)
page.dependent = true
page.acl_depends = { "luci-app-easymesh" }
diff --git a/package/lean/luci-app-easymesh/luasrc/model/cbi/easymesh.lua b/package/lean/luci-app-easymesh/luasrc/model/cbi/easymesh.lua
old mode 100755
new mode 100644
diff --git a/package/lean/luci-app-easymesh/root/etc/config/easymesh b/package/lean/luci-app-easymesh/root/etc/config/easymesh
old mode 100755
new mode 100644
diff --git a/package/lean/luci-app-familycloud/Makefile b/package/lean/luci-app-familycloud/Makefile
index ac8eb34ed..926ec8324 100644
--- a/package/lean/luci-app-familycloud/Makefile
+++ b/package/lean/luci-app-familycloud/Makefile
@@ -15,4 +15,3 @@ PKG_RELEASE:=6
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
diff --git a/package/lean/luci-app-familycloud/luasrc/controller/familycloud.lua b/package/lean/luci-app-familycloud/luasrc/controller/familycloud.lua
index 8d3a77218..b0f3b6d48 100644
--- a/package/lean/luci-app-familycloud/luasrc/controller/familycloud.lua
+++ b/package/lean/luci-app-familycloud/luasrc/controller/familycloud.lua
@@ -1,4 +1,3 @@
-
module("luci.controller.familycloud", package.seeall)
function index()
@@ -9,15 +8,14 @@ function index()
entry({"admin", "services", "familycloud"}, firstchild(), _("天翼家庭云/云盘提速"), 80).dependent = false
entry({"admin", "services", "familycloud", "general"}, cbi("familycloud/familycloud"), _("Base Setting"), 1)
- entry({"admin", "services", "familycloud", "log"}, form("familycloud/familycloudlog"), _("Log"), 2)
+ entry({"admin", "services", "familycloud", "log"}, form("familycloud/familycloud_log"), _("Log"), 2)
entry({"admin", "services", "familycloud", "status"}, call("act_status")).leaf = true
end
function act_status()
- local e={}
- e.running=luci.sys.call("ps | grep speedup.sh | grep -v grep >/dev/null")==0
+ local e = {}
+ e.running = luci.sys.call("ps | grep speedup.sh | grep -v grep >/dev/null") == 0
luci.http.prepare_content("application/json")
luci.http.write_json(e)
end
-
diff --git a/package/lean/luci-app-familycloud/luasrc/model/cbi/familycloud/familycloud.lua b/package/lean/luci-app-familycloud/luasrc/model/cbi/familycloud/familycloud.lua
index d4a0b6428..e57ff0243 100644
--- a/package/lean/luci-app-familycloud/luasrc/model/cbi/familycloud/familycloud.lua
+++ b/package/lean/luci-app-familycloud/luasrc/model/cbi/familycloud/familycloud.lua
@@ -1,12 +1,12 @@
-
-mp = Map("familycloud", translate("天翼家庭云/天翼云盘提速"))
+mp = Map("familycloud")
+mp.title = translate("天翼家庭云/天翼云盘提速")
mp.description = translate("天翼家庭云/天翼云盘提速 (最高可达500Mbps)")
-mp:section(SimpleSection).template = "familycloud/familycloud_status"
+mp:section(SimpleSection).template = "familycloud/familycloud_status"
s = mp:section(TypedSection, "familycloud")
-s.anonymous=true
-s.addremove=false
+s.anonymous = true
+s.addremove = false
enabled = s:option(Flag, "enabled", translate("启用提速"))
enabled.default = 0
diff --git a/package/lean/luci-app-familycloud/luasrc/model/cbi/familycloud/familycloudlog.lua b/package/lean/luci-app-familycloud/luasrc/model/cbi/familycloud/familycloud_log.lua
similarity index 87%
rename from package/lean/luci-app-familycloud/luasrc/model/cbi/familycloud/familycloudlog.lua
rename to package/lean/luci-app-familycloud/luasrc/model/cbi/familycloud/familycloud_log.lua
index 9471b410d..c1b7ad0b0 100644
--- a/package/lean/luci-app-familycloud/luasrc/model/cbi/familycloud/familycloudlog.lua
+++ b/package/lean/luci-app-familycloud/luasrc/model/cbi/familycloud/familycloud_log.lua
@@ -9,6 +9,6 @@ t.rows = 15
function t.cfgvalue()
return fs.readfile(conffile) or ""
end
-t.readonly="readonly"
+t.readonly = "readonly"
-return f
\ No newline at end of file
+return f
diff --git a/package/lean/luci-app-familycloud/luasrc/view/familycloud/familycloud_status.htm b/package/lean/luci-app-familycloud/luasrc/view/familycloud/familycloud_status.htm
index 002565430..b2ae91c91 100644
--- a/package/lean/luci-app-familycloud/luasrc/view/familycloud/familycloud_status.htm
+++ b/package/lean/luci-app-familycloud/luasrc/view/familycloud/familycloud_status.htm
@@ -19,4 +19,4 @@ XHR.poll(3, '<%=url([[admin]], [[services]], [[familycloud]], [[status]])%>', nu
<%:Collecting data...%>
-
\ No newline at end of file
+
diff --git a/package/lean/luci-app-filetransfer/Makefile b/package/lean/luci-app-filetransfer/Makefile
index dae88c85d..6c8aa5a49 100644
--- a/package/lean/luci-app-filetransfer/Makefile
+++ b/package/lean/luci-app-filetransfer/Makefile
@@ -14,5 +14,3 @@ PKG_RELEASE:=2
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
-
diff --git a/package/lean/luci-app-frpc/Makefile b/package/lean/luci-app-frpc/Makefile
index 7d7ce4227..470303a6e 100644
--- a/package/lean/luci-app-frpc/Makefile
+++ b/package/lean/luci-app-frpc/Makefile
@@ -15,5 +15,3 @@ PKG_RELEASE:=2
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
-
diff --git a/package/lean/luci-app-frpc/luasrc/model/cbi/frp/basic.lua b/package/lean/luci-app-frpc/luasrc/model/cbi/frp/basic.lua
index 740fca71e..d65e68610 100644
--- a/package/lean/luci-app-frpc/luasrc/model/cbi/frp/basic.lua
+++ b/package/lean/luci-app-frpc/luasrc/model/cbi/frp/basic.lua
@@ -1,10 +1,10 @@
-local o=require"luci.dispatcher"
-local e=require("luci.model.ipkg")
-local s=require"nixio.fs"
-local e=luci.model.uci.cursor()
-local i="frp"
+local o = require"luci.dispatcher"
+local e = require("luci.model.ipkg")
+local s = require"nixio.fs"
+local e = luci.model.uci.cursor()
+local i = "frp"
local a,t,e
-local n={}
+local n = {}
a = Map("frp")
a.title = translate("Frp Setting")
@@ -195,14 +195,14 @@ end
e = t:option(DummyValue,"remote_port",translate("Remote Port"))
e.width = "10%"
e.cfgvalue = function(t,b)
-local t=a.uci:get(i,b,"type")or""
+local t = a.uci:get(i,b,"type")or""
if t==""or b==""then return""end
if t=="http" then
-local b=a.uci:get(i,"common","vhost_http_port")or"" return b end
+local b = a.uci:get(i,"common","vhost_http_port")or"" return b end
if t=="https" then
-local b=a.uci:get(i,"common","vhost_https_port")or"" return b end
+local b = a.uci:get(i,"common","vhost_https_port")or"" return b end
if t=="tcp" or t=="udp" then
-local b=a.uci:get(i,b,"remote_port")or"" return b end
+local b = a.uci:get(i,b,"remote_port")or"" return b end
end
e = t:option(DummyValue, "local_ip", translate("Local Host Address"))
@@ -225,7 +225,7 @@ end
e = t:option(DummyValue, "use_compression", translate("Use Compression"))
e.width = "15%"
-e.cfgvalue=function(t,n)
+e.cfgvalue = function(t,n)
local t = a.uci:get(i,n,"use_compression")or""
local b
if t==""or b==""then return""end
diff --git a/package/lean/luci-app-frps/luasrc/model/cbi/frps/server.lua b/package/lean/luci-app-frps/luasrc/model/cbi/frps/server.lua
index 47073f684..7fca105c1 100644
--- a/package/lean/luci-app-frps/luasrc/model/cbi/frps/server.lua
+++ b/package/lean/luci-app-frps/luasrc/model/cbi/frps/server.lua
@@ -24,31 +24,31 @@ o.disabled = "false"
o.defalut = o.enabled
o.rmempty = false
-o = s:option(Flag, "tls_only", translate("Enforce frps only accept TLS connection"),
- translatef("Requirements: frpc v0.25.0+, frps v0.32.0+"))
+o = s:option(Flag, "tls_only", translate("Enforce frps only accept TLS connection"))
+o.description = translatef("Requirements: frpc v0.25.0+, frps v0.32.0+")
o.enabled = "true"
o.disabled = "false"
o.default = o.disabled
o.rmempty = false
-o = s:option(Value, "bind_udp_port", translate("UDP bind port"),
- translatef("Optional: udp port to help make udp hole to penetrate nat"))
+o = s:option(Value, "bind_udp_port", translate("UDP bind port"))
+o.description = translatef("Optional: udp port to help make udp hole to penetrate nat")
o.datatype = "port"
-o = s:option(Value, "kcp_bind_port", translate("KCP bind port"),
- translatef("Optional: udp port used for kcp protocol, it can be same with 'bind port'; if not set, kcp is disabled in frps"))
+o = s:option(Value, "kcp_bind_port", translate("KCP bind port"))
+o.description = translatef("Optional: udp port used for kcp protocol, it can be same with 'bind port'; if not set, kcp is disabled in frps")
o.datatype = "port"
-o = s:option(Value, "vhost_http_port", translate("vhost http port"),
- translatef("Optional: if you want to support virtual host, you must set the http port for listening"))
+o = s:option(Value, "vhost_http_port", translate("vhost http port"))
+o.description = translatef("Optional: if you want to support virtual host, you must set the http port for listening")
o.datatype = "port"
-o = s:option(Value, "vhost_https_port", translate("vhost https port"),
- translatef("Optional: Note: http port and https port can be same with bind_port"))
+o = s:option(Value, "vhost_https_port", translate("vhost https port"))
+o.description = translatef("Optional: Note: http port and https port can be same with bind_port")
o.datatype = "port"
-o = s:option(DynamicList, "extra_setting", translate("Extra Settings"),
- translatef("List of extra settings will be added to config file. Format: option=value, eg. detailed_errors_to_client=false
.(NO SPACE!)"))
+o = s:option(DynamicList, "extra_setting", translate("Extra Settings"))
+o.description = translatef("List of extra settings will be added to config file. Format: option=value, eg. detailed_errors_to_client=false
.(NO SPACE!)")
o.placeholder = "option=value"
return m
\ No newline at end of file
diff --git a/package/lean/luci-app-frps/root/etc/init.d/frps b/package/lean/luci-app-frps/root/etc/init.d/frps
old mode 100644
new mode 100755
diff --git a/package/lean/luci-app-frps/root/etc/uci-defaults/40_luci-frps b/package/lean/luci-app-frps/root/etc/uci-defaults/40_luci-frps
old mode 100644
new mode 100755
diff --git a/package/lean/luci-app-guest-wifi/luasrc/model/cbi/guest-wifi.lua b/package/lean/luci-app-guest-wifi/luasrc/model/cbi/guest-wifi.lua
index c498af3ce..1fbd555ca 100644
--- a/package/lean/luci-app-guest-wifi/luasrc/model/cbi/guest-wifi.lua
+++ b/package/lean/luci-app-guest-wifi/luasrc/model/cbi/guest-wifi.lua
@@ -63,4 +63,3 @@ leasetime.default = "1h"
leasetime.rmempty = true
return m
-
diff --git a/package/lean/luci-app-haproxy-tcp/luasrc/controller/haproxy.lua b/package/lean/luci-app-haproxy-tcp/luasrc/controller/haproxy.lua
old mode 100755
new mode 100644
index 7beb8cf43..849209694
--- a/package/lean/luci-app-haproxy-tcp/luasrc/controller/haproxy.lua
+++ b/package/lean/luci-app-haproxy-tcp/luasrc/controller/haproxy.lua
@@ -1,8 +1,9 @@
module("luci.controller.haproxy", package.seeall)
+
function index()
if not nixio.fs.access("/etc/config/haproxy") then
return
end
entry({"admin", "services", "haproxy"}, cbi("haproxy"), _("HAProxy")).dependent = true
-end
\ No newline at end of file
+end
diff --git a/package/lean/luci-app-haproxy-tcp/luasrc/model/cbi/haproxy.lua b/package/lean/luci-app-haproxy-tcp/luasrc/model/cbi/haproxy.lua
old mode 100755
new mode 100644
index f18122439..382fa5b02
--- a/package/lean/luci-app-haproxy-tcp/luasrc/model/cbi/haproxy.lua
+++ b/package/lean/luci-app-haproxy-tcp/luasrc/model/cbi/haproxy.lua
@@ -16,11 +16,11 @@ if haproxy_on then
else
state_msg = "" .. translate("Not running") .. ""
end
-m=Map("haproxy",translate("HAProxy"),translate("HAProxy能够检测Shadowsocks服务器的连通情况,从而实现负载均衡和高可用的功能,支持主备用服务器宕机自动切换,并且可以设置多个主服务器用于分流,规定每个分流节点的流量比例等。前提条件是你的所有Shadowsocks服务器的【加密方式】和【密码】一致。
使用方法:配置好你的Shadowsocks服务器ip地址和端口,然后开启Shadowsocks服务,将服务器地址填写为【127.0.0.1】,端口【2222】,其他参数和之前一样即可,你可以通过访问【路由器的IP:1111/haproxy】输入用户名admin,密码root来观察各节点健康状况,红色为宕机,绿色正常,使用说明请点击这里") .. "
后台监控页面:" .. router_ip .. ":1111/haproxy 用户名admin,密码root" .. "
状态 - " .. state_msg)
-s=m:section(TypedSection,"arguments","")
- s.addremove=false
- s.anonymous=true
- view_enable = s:option(Flag,"enabled",translate("Enable"))
+m = Map("haproxy", translate("HAProxy"), translate("HAProxy能够检测Shadowsocks服务器的连通情况,从而实现负载均衡和高可用的功能,支持主备用服务器宕机自动切换,并且可以设置多个主服务器用于分流,规定每个分流节点的流量比例等。前提条件是你的所有Shadowsocks服务器的【加密方式】和【密码】一致。
使用方法:配置好你的Shadowsocks服务器ip地址和端口,然后开启Shadowsocks服务,将服务器地址填写为【127.0.0.1】,端口【2222】,其他参数和之前一样即可,你可以通过访问【路由器的IP:1111/haproxy】输入用户名admin,密码root来观察各节点健康状况,红色为宕机,绿色正常,使用说明请点击这里") .. "
后台监控页面:" .. router_ip .. ":1111/haproxy 用户名admin,密码root" .. "
状态 - " .. state_msg)
+s = m:section(TypedSection,"arguments","")
+ s.addremove = false
+ s.anonymous = true
+ view_enable = s:option(Flag, "enabled", translate("Enable"))
--通过读写配置文件控制HAProxy这种方式已经弃用
--view_cfg = s:option(TextValue, "1", nil)
--view_cfg.rmempty = false
@@ -32,36 +32,37 @@ s=m:section(TypedSection,"arguments","")
--function view_cfg.write(self, section, value)
-- sync_value_to_file(value, "/etc/haproxy.cfg")
--end
-s=m:section(TypedSection,"main_server","" .. translate("Main Server List") .. "")
- s.anonymous=true
- s.addremove=true
- o=s:option(Value,"server_name",translate("Display Name"),translate("Only English Characters,No spaces"))
+s = m:section(TypedSection, "main_server","" .. translate("Main Server List") .. "")
+ s.anonymous = true
+ s.addremove = true
+ o = s:option(Value, "server_name", translate("Display Name"), translate("Only English Characters,No spaces"))
o.rmempty = false
- o=s:option(Flag,"validate",translate("validate"))
+ o = s:option(Flag,"validate",translate("validate"))
- o=s:option(Value,"server_ip",translate("Proxy Server IP"))
+ o = s:option(Value, "server_ip", translate("Proxy Server IP"))
- o=s:option(Value,"server_port",translate("Proxy Server Port"))
- o.datatype="uinteger"
- o=s:option(Value,"server_weight",translate("Weight"))
- o.datatype="uinteger"
+ o = s:option(Value, "server_port", translate("Proxy Server Port"))
+ o.datatype = "uinteger"
+ o = s:option(Value, "server_weight", translate("Weight"))
+ o.datatype = "uinteger"
-s=m:section(TypedSection,"backup_server","" .. translate("Backup Server List") .. "")
- s.anonymous=true
- s.addremove=true
- o=s:option(Value,"server_name",translate("Display Name"),translate("Only English Characters,No spaces"))
+s = m:section(TypedSection,"backup_server","" .. translate("Backup Server List") .. "")
+ s.anonymous = true
+ s.addremove = true
+ o = s:option(Value, "server_name", translate("Display Name"), translate("Only English Characters,No spaces"))
o.rmempty = false
- o=s:option(Flag,"validate",translate("validate"))
+ o = s:option(Flag, "validate", translate("validate"))
- o=s:option(Value,"server_ip",translate("Proxy Server IP"))
+ o = s:option(Value, "server_ip", translate("Proxy Server IP"))
- o=s:option(Value,"server_port",translate("Proxy Server Port"))
- o.datatype="uinteger"
+ o = s:option(Value, "server_port", translate("Proxy Server Port"))
+ o.datatype = "uinteger"
-- ---------------------------------------------------
local apply = luci.http.formvalue("cbi.apply")
if apply then
os.execute("/etc/haproxy_init.sh restart >/dev/null 2>&1 &")
end
+
return m
diff --git a/package/lean/luci-app-ipsec-vpnd/Makefile b/package/lean/luci-app-ipsec-vpnd/Makefile
index d9a888c19..f9d5eaa6f 100644
--- a/package/lean/luci-app-ipsec-vpnd/Makefile
+++ b/package/lean/luci-app-ipsec-vpnd/Makefile
@@ -14,5 +14,3 @@ PKG_RELEASE:=11
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
-
diff --git a/package/lean/luci-app-ipsec-vpnd/luasrc/controller/ipsec-server.lua b/package/lean/luci-app-ipsec-vpnd/luasrc/controller/ipsec-server.lua
index 8b8000883..4594275e6 100644
--- a/package/lean/luci-app-ipsec-vpnd/luasrc/controller/ipsec-server.lua
+++ b/package/lean/luci-app-ipsec-vpnd/luasrc/controller/ipsec-server.lua
@@ -1,4 +1,3 @@
-
module("luci.controller.ipsec-server", package.seeall)
function index()
@@ -7,13 +6,13 @@ function index()
end
entry({"admin", "vpn"}, firstchild(), "VPN", 45).dependent = false
- entry({"admin", "vpn", "ipsec-server"}, cbi("ipsec-server/ipsec-server"), _("IPSec VPN Server"), 80).dependent = false
+ entry({"admin", "vpn", "ipsec-server"}, cbi("ipsec-server"), _("IPSec VPN Server"), 80).dependent = false
entry({"admin", "vpn", "ipsec-server", "status"}, call("act_status")).leaf = true
end
function act_status()
- local e={}
- e.running=luci.sys.call("pgrep ipsec >/dev/null")==0
+ local e = {}
+ e.running = luci.sys.call("pgrep ipsec >/dev/null") == 0
luci.http.prepare_content("application/json")
luci.http.write_json(e)
end
diff --git a/package/lean/luci-app-ipsec-vpnd/luasrc/model/cbi/ipsec-server/ipsec-server.lua b/package/lean/luci-app-ipsec-vpnd/luasrc/model/cbi/ipsec-server.lua
similarity index 90%
rename from package/lean/luci-app-ipsec-vpnd/luasrc/model/cbi/ipsec-server/ipsec-server.lua
rename to package/lean/luci-app-ipsec-vpnd/luasrc/model/cbi/ipsec-server.lua
index 79a47b8bf..aa11ae1d8 100644
--- a/package/lean/luci-app-ipsec-vpnd/luasrc/model/cbi/ipsec-server/ipsec-server.lua
+++ b/package/lean/luci-app-ipsec-vpnd/luasrc/model/cbi/ipsec-server.lua
@@ -1,8 +1,8 @@
-
-mp = Map("ipsec", translate("IPSec VPN Server"))
+mp = Map("ipsec")
+mp.title = translate("IPSec VPN Server")
mp.description = translate("IPSec VPN connectivity using the native built-in VPN Client on iOS or Andriod (IKEv1 with PSK and Xauth)")
-mp:section(SimpleSection).template = "ipsec/ipsec_status"
+mp:section(SimpleSection).template = "ipsec/ipsec_status"
s = mp:section(NamedSection, "ipsec", "service")
s.anonymouse = true
diff --git a/package/lean/luci-app-ipsec-vpnd/luasrc/view/ipsec/ipsec_status.htm b/package/lean/luci-app-ipsec-vpnd/luasrc/view/ipsec/ipsec_status.htm
index 60225b490..1e256c73b 100644
--- a/package/lean/luci-app-ipsec-vpnd/luasrc/view/ipsec/ipsec_status.htm
+++ b/package/lean/luci-app-ipsec-vpnd/luasrc/view/ipsec/ipsec_status.htm
@@ -19,4 +19,4 @@ XHR.poll(3, '<%=url([[admin]], [[vpn]], [[ipsec-server]], [[status]])%>', null,
<%:Collecting data...%>
-
\ No newline at end of file
+
diff --git a/package/lean/luci-app-kodexplorer/luasrc/model/cbi/kodexplorer/settings.lua b/package/lean/luci-app-kodexplorer/luasrc/model/cbi/kodexplorer/settings.lua
index 0b483e62c..2645e9c4e 100644
--- a/package/lean/luci-app-kodexplorer/luasrc/model/cbi/kodexplorer/settings.lua
+++ b/package/lean/luci-app-kodexplorer/luasrc/model/cbi/kodexplorer/settings.lua
@@ -1,6 +1,8 @@
-m = Map("kodexplorer", translate("KodExplorer"), translate(
- "KodExplorer is a fast and efficient private cloud and online document management system that provides secure, controllable, easy-to-use and highly customizable private cloud products for personal websites, enterprise private cloud deployment, network storage, online document management, and online office. With Windows style interface and operation habits, it can be used quickly without adaptation. It supports online preview of hundreds of common file formats and is extensible and easy to customize."))
-m:append(Template("kodexplorer/status"))
+m = Map("kodexplorer")
+m.title = translate("KodExplorer")
+m.description = translate("KodExplorer is a fast and efficient private cloud and online document management system that provides secure, controllable, easy-to-use and highly customizable private cloud products for personal websites, enterprise private cloud deployment, network storage, online document management, and online office. With Windows style interface and operation habits, it can be used quickly without adaptation. It supports online preview of hundreds of common file formats and is extensible and easy to customize.")
+
+m:section(SimpleSection).template = "kodexplorer/kodexplorer_status"
s = m:section(TypedSection, "global", translate("Global Settings"))
s.anonymous = true
@@ -14,41 +16,36 @@ o.datatype = "port"
o.default = 8081
o.rmempty = false
-o = s:option(Value, "memory_limit", translate("Maximum memory usage"),
- translate(
- "If your device has a lot of memory, you can increase it."))
+o = s:option(Value, "memory_limit", translate("Maximum memory usage"))
+o.description = translate("If your device has a lot of memory, you can increase it.")
o.default = "8M"
o.rmempty = false
-o = s:option(Value, "post_max_size", translate("Maximum POST capacity"),
- translate(
- "This value cannot be greater than the maximum memory usage"))
+o = s:option(Value, "post_max_size", translate("Maximum POST capacity"))
+o.description = translate("This value cannot be greater than the maximum memory usage")
o.default = "12M"
o.rmempty = false
-o = s:option(Value, "upload_max_filesize",
- translate("Maximum memory usage for uploading files"), translate(
- "This value cannot be greater than the POST maximum capacity"))
+o = s:option(Value, "upload_max_filesize", translate("Maximum memory usage for uploading files"))
+o.description = translate("This value cannot be greater than the POST maximum capacity")
o.default = "12M"
o.rmempty = false
-o = s:option(Value, "storage_device_path", translate("Storage device path"),
- translate(
- "It is recommended to insert a usb flash drive or hard disk and enter the path. For example, /mnt/sda1/"))
+o = s:option(Value, "storage_device_path", translate("Storage device path"))
+o.description = translate("It is recommended to insert a usb flash drive or hard disk and enter the path. For example, /mnt/sda1/")
o.default = "/mnt/sda1/"
o.rmempty = false
-o = s:option(Value, "project_directory", translate("Project directory"),
- translate(
- "It is recommended to insert a usb flash drive or hard disk and enter the path. For example, /mnt/sda1/kodexplorer"))
+o = s:option(Value, "project_directory", translate("Project directory"))
+o.description = translate("It is recommended to insert a usb flash drive or hard disk and enter the path. For example, /mnt/sda1/kodexplorer")
o.default = "/mnt/sda1/kodexplorer"
o.rmempty = false
-s:append(Template("kodexplorer/version"))
+s:section(SimpleSection).template = "kodexplorer/kodexplorer_version"
-o = s:option(Button, "_download", translate("Manually update"), translate(
- "Make sure you have enough space.
Be sure to fill out the device path and store path for the first run, and then save the application. Then manually download, otherwise can not use!"))
-o.template = "kodexplorer/download"
+o = s:option(Button, "_download", translate("Manually update"))
+o.description = translate("Make sure you have enough space.
Be sure to fill out the device path and store path for the first run, and then save the application. Then manually download, otherwise can not use!")
+o.template = "kodexplorer/kodexplorer_download"
o.inputstyle = "apply"
o.btnclick = "downloadClick(this);"
o.id = "download_btn"
diff --git a/package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/download.htm b/package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/kodexplorer_download.htm
similarity index 99%
rename from package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/download.htm
rename to package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/kodexplorer_download.htm
index 21e522836..07effc605 100644
--- a/package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/download.htm
+++ b/package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/kodexplorer_download.htm
@@ -172,4 +172,4 @@
<% else %>
-
<% end %>
-<%+cbi/valuefooter%>
\ No newline at end of file
+<%+cbi/valuefooter%>
diff --git a/package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/status.htm b/package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/kodexplorer_status.htm
similarity index 98%
rename from package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/status.htm
rename to package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/kodexplorer_status.htm
index 61ab40ff6..d5b9c4ccd 100644
--- a/package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/status.htm
+++ b/package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/kodexplorer_status.htm
@@ -35,4 +35,4 @@ local dsp = require "luci.dispatcher"
var url = window.location.host+":<%=luci.sys.exec("uci -q get kodexplorer.@global[0].port"):gsub("^%s*(.-)%s*$", "%1")%>";
window.open('http://'+url,'target','');
}
-//]]>
\ No newline at end of file
+//]]>
diff --git a/package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/version.htm b/package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/kodexplorer_version.htm
similarity index 97%
rename from package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/version.htm
rename to package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/kodexplorer_version.htm
index c51541733..5529f2449 100644
--- a/package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/version.htm
+++ b/package/lean/luci-app-kodexplorer/luasrc/view/kodexplorer/kodexplorer_version.htm
@@ -14,4 +14,4 @@ local app_version = api.get_version()
-<% end %>
\ No newline at end of file
+<% end %>
diff --git a/package/lean/luci-app-music-remote-center/Makefile b/package/lean/luci-app-music-remote-center/Makefile
index c40909925..0a29b133a 100644
--- a/package/lean/luci-app-music-remote-center/Makefile
+++ b/package/lean/luci-app-music-remote-center/Makefile
@@ -15,4 +15,3 @@ PKG_RELEASE:=6
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
diff --git a/package/lean/luci-app-music-remote-center/luasrc/controller/forked-daapd.lua b/package/lean/luci-app-music-remote-center/luasrc/controller/forked-daapd.lua
index 9f07e77c8..43df94ade 100644
--- a/package/lean/luci-app-music-remote-center/luasrc/controller/forked-daapd.lua
+++ b/package/lean/luci-app-music-remote-center/luasrc/controller/forked-daapd.lua
@@ -1,4 +1,3 @@
-
module("luci.controller.forked-daapd", package.seeall)
function index()
@@ -11,8 +10,8 @@ function index()
end
function act_status()
- local e={}
- e.running=luci.sys.call("pgrep forked-daapd >/dev/null")==0
+ local e = {}
+ e.running = luci.sys.call("pgrep forked-daapd >/dev/null") == 0
luci.http.prepare_content("application/json")
luci.http.write_json(e)
-end
\ No newline at end of file
+end
diff --git a/package/lean/luci-app-music-remote-center/luasrc/model/cbi/forked-daapd.lua b/package/lean/luci-app-music-remote-center/luasrc/model/cbi/forked-daapd.lua
index 188cb1f5b..ef6e5e450 100644
--- a/package/lean/luci-app-music-remote-center/luasrc/model/cbi/forked-daapd.lua
+++ b/package/lean/luci-app-music-remote-center/luasrc/model/cbi/forked-daapd.lua
@@ -1,23 +1,25 @@
-- Copyright 2020 Lean
-- Licensed to the public under the Apache License 2.0.
-m = Map("forked-daapd", translate("Music Remote Center"), translate("Music Remote Center is a DAAP (iTunes Remote), MPD (Music Player Daemon) and RSP (Roku) media server."))
+m = Map("forked-daapd")
+m.title = translate("Music Remote Center")
+m.description = translate("Music Remote Center is a DAAP (iTunes Remote), MPD (Music Player Daemon) and RSP (Roku) media server.")
-m:section(SimpleSection).template = "forked-daapd/forked-daapd_status"
+m:section(SimpleSection).template = "forked-daapd/forked-daapd_status"
s = m:section(TypedSection, "forked-daapd")
s.addremove = false
s.anonymous = true
-enable=s:option(Flag, "enabled", translate("Enabled"))
+enable = s:option(Flag, "enabled", translate("Enabled"))
enable.default = "0"
enable.rmempty = false
-port=s:option(Value, "port", translate("Port"))
+port = s:option(Value, "port", translate("Port"))
port.rmempty = false
port.datatype = "port"
-db_path=s:option(Value, "db_path", translate("Database File Path"))
+db_path = s:option(Value, "db_path", translate("Database File Path"))
db_path.default = "/opt/forked-daapd-songs3.db"
db_path.rmempty = false
@@ -25,7 +27,7 @@ directories=s:option(Value, "directories", translate("Music Directorie Path"))
directories.default = "/opt/music"
directories.rmempty = false
-readme=s:option(DummyValue,"readme",translate("Readme"))
-readme.description=translate("About iOS Remote Pairing:
1. Open the web interface
2. Start iPhone Remote APP, go to Settings, Add Library
3. Enter the pair code in the web interface")
+readme = s:option(DummyValue, "readme", translate("Readme"))
+readme.description = translate("About iOS Remote Pairing:
1. Open the web interface
2. Start iPhone Remote APP, go to Settings, Add Library
3. Enter the pair code in the web interface")
-return m
\ No newline at end of file
+return m
diff --git a/package/lean/luci-app-music-remote-center/luasrc/view/forked-daapd/forked-daapd_status.htm b/package/lean/luci-app-music-remote-center/luasrc/view/forked-daapd/forked-daapd_status.htm
index 2663987d8..3ef1648f5 100644
--- a/package/lean/luci-app-music-remote-center/luasrc/view/forked-daapd/forked-daapd_status.htm
+++ b/package/lean/luci-app-music-remote-center/luasrc/view/forked-daapd/forked-daapd_status.htm
@@ -19,4 +19,4 @@ XHR.poll(3, '<%=url([[admin]], [[nas]], [[forked-daapd]], [[run]])%>', null,
<%:Collecting data...%>
-
\ No newline at end of file
+
diff --git a/package/lean/luci-app-mwan3helper/Makefile b/package/lean/luci-app-mwan3helper/Makefile
index 38dedff05..ad0c900d1 100644
--- a/package/lean/luci-app-mwan3helper/Makefile
+++ b/package/lean/luci-app-mwan3helper/Makefile
@@ -14,5 +14,3 @@ PKG_RELEASE:=3
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
-
diff --git a/package/lean/luci-app-mwan3helper/luasrc/controller/mwan3helper.lua b/package/lean/luci-app-mwan3helper/luasrc/controller/mwan3helper.lua
index 9ddc22219..481405d30 100644
--- a/package/lean/luci-app-mwan3helper/luasrc/controller/mwan3helper.lua
+++ b/package/lean/luci-app-mwan3helper/luasrc/controller/mwan3helper.lua
@@ -15,8 +15,8 @@ function index()
end
function act_status()
- local e={}
- e.running=luci.sys.call("pgrep mwan3dns >/dev/null")==0
+ local e = {}
+ e.running = luci.sys.call("pgrep mwan3dns >/dev/null") == 0
luci.http.prepare_content("application/json")
luci.http.write_json(e)
end
diff --git a/package/lean/luci-app-mwan3helper/luasrc/model/cbi/mwan3helper/client.lua b/package/lean/luci-app-mwan3helper/luasrc/model/cbi/mwan3helper/client.lua
index 466b28c77..8f1a66b91 100644
--- a/package/lean/luci-app-mwan3helper/luasrc/model/cbi/mwan3helper/client.lua
+++ b/package/lean/luci-app-mwan3helper/luasrc/model/cbi/mwan3helper/client.lua
@@ -1,5 +1,3 @@
-
-
m = Map("mwan3helper")
m.title = translate("MWAN3 Helper")
m.description = translate("MWAN3 Helper generate IPSets")
diff --git a/package/lean/luci-app-mwan3helper/luasrc/model/cbi/mwan3helper/list.lua b/package/lean/luci-app-mwan3helper/luasrc/model/cbi/mwan3helper/list.lua
index c908ff19a..2f845aed6 100644
--- a/package/lean/luci-app-mwan3helper/luasrc/model/cbi/mwan3helper/list.lua
+++ b/package/lean/luci-app-mwan3helper/luasrc/model/cbi/mwan3helper/list.lua
@@ -1,5 +1,3 @@
-
-
m = Map("mwan3helper")
m.title = translate("MWAN3 IPSets")
diff --git a/package/lean/luci-app-mwan3helper/luasrc/view/mwan3helper/mwan3helper_status.htm b/package/lean/luci-app-mwan3helper/luasrc/view/mwan3helper/mwan3helper_status.htm
index 44c6a3936..048a8814f 100644
--- a/package/lean/luci-app-mwan3helper/luasrc/view/mwan3helper/mwan3helper_status.htm
+++ b/package/lean/luci-app-mwan3helper/luasrc/view/mwan3helper/mwan3helper_status.htm
@@ -19,4 +19,4 @@ XHR.poll(3, '<%=url([[admin]], [[services]], [[mwan3helper]], [[status]])%>', nu
<%:Collecting data...%>
-
\ No newline at end of file
+
diff --git a/package/lean/luci-app-n2n_v2/luasrc/controller/n2n_v2.lua b/package/lean/luci-app-n2n_v2/luasrc/controller/n2n_v2.lua
index 637aa1ff5..9bce94cc7 100644
--- a/package/lean/luci-app-n2n_v2/luasrc/controller/n2n_v2.lua
+++ b/package/lean/luci-app-n2n_v2/luasrc/controller/n2n_v2.lua
@@ -11,13 +11,13 @@ function index()
end
entry({"admin", "vpn"}, firstchild(), "VPN", 45).dependent = false
- entry({"admin", "vpn", "n2n_v2", "status"}, call("n2n_status")).leaf = true
+ entry({"admin", "vpn", "n2n_v2", "status"}, call("act_status")).leaf = true
entry({"admin", "vpn", "n2n_v2"}, cbi("n2n_v2"), _("N2N v2 VPN"), 45).dependent = true
end
-function n2n_status()
- local status = {}
- status.running = luci.sys.call("pgrep edge >/dev/null")==0
+function act_status()
+ local e = {}
+ e.running = luci.sys.call("pgrep edge >/dev/null") == 0
luci.http.prepare_content("application/json")
- luci.http.write_json(status)
+ luci.http.write_json(e)
end
diff --git a/package/lean/luci-app-n2n_v2/luasrc/model/cbi/n2n_v2.lua b/package/lean/luci-app-n2n_v2/luasrc/model/cbi/n2n_v2.lua
index 5c5a8985b..7ad35e6d0 100644
--- a/package/lean/luci-app-n2n_v2/luasrc/model/cbi/n2n_v2.lua
+++ b/package/lean/luci-app-n2n_v2/luasrc/model/cbi/n2n_v2.lua
@@ -22,12 +22,11 @@ function get_mask(v)
v:value("30", "255.255.255.252(30)")
end
-m = Map("n2n_v2", translate("N2N v2 VPN"), translatef(
- "n2n is a layer-two peer-to-peer virtual private network (VPN) which allows users to exploit features typical of P2P applications at network instead of application level."))
+m = Map("n2n_v2")
+m.title = translate("N2N v2 VPN")
+m.description = translatef("n2n is a layer-two peer-to-peer virtual private network (VPN) which allows users to exploit features typical of P2P applications at network instead of application level.")
--- Basic config
--- edge
-m:section(SimpleSection).template = "n2n_v2/status"
+m:section(SimpleSection).template = "n2n_v2/n2n_v2_status"
s = m:section(TypedSection, "edge", translate("N2N Edge Settings"))
s.anonymous = true
diff --git a/package/lean/luci-app-n2n_v2/luasrc/view/n2n_v2/n2n_v2_status.htm b/package/lean/luci-app-n2n_v2/luasrc/view/n2n_v2/n2n_v2_status.htm
new file mode 100644
index 000000000..204776745
--- /dev/null
+++ b/package/lean/luci-app-n2n_v2/luasrc/view/n2n_v2/n2n_v2_status.htm
@@ -0,0 +1,20 @@
+
+
diff --git a/package/lean/luci-app-n2n_v2/luasrc/view/n2n_v2/status.htm b/package/lean/luci-app-n2n_v2/luasrc/view/n2n_v2/status.htm
deleted file mode 100644
index b6e57da76..000000000
--- a/package/lean/luci-app-n2n_v2/luasrc/view/n2n_v2/status.htm
+++ /dev/null
@@ -1,20 +0,0 @@
-
-
\ No newline at end of file
diff --git a/package/lean/luci-app-netdata/luasrc/controller/netdata.lua b/package/lean/luci-app-netdata/luasrc/controller/netdata.lua
index 975255860..09e9943b2 100644
--- a/package/lean/luci-app-netdata/luasrc/controller/netdata.lua
+++ b/package/lean/luci-app-netdata/luasrc/controller/netdata.lua
@@ -3,4 +3,4 @@ module("luci.controller.netdata", package.seeall)
function index()
entry({"admin", "status", "netdata"}, template("netdata/netdata"), _("NetData"), 10).leaf = true
-end
\ No newline at end of file
+end
diff --git a/package/lean/luci-app-nfs/Makefile b/package/lean/luci-app-nfs/Makefile
index e834be11d..5bf72408a 100644
--- a/package/lean/luci-app-nfs/Makefile
+++ b/package/lean/luci-app-nfs/Makefile
@@ -14,4 +14,3 @@ PKG_RELEASE:=1
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
diff --git a/package/lean/luci-app-nfs/root/etc/uci-defaults/luci-nfs b/package/lean/luci-app-nfs/root/etc/uci-defaults/luci-nfs
old mode 100644
new mode 100755
diff --git a/package/lean/luci-app-nps/luasrc/controller/nps.lua b/package/lean/luci-app-nps/luasrc/controller/nps.lua
index a9d04bc8d..313707fca 100644
--- a/package/lean/luci-app-nps/luasrc/controller/nps.lua
+++ b/package/lean/luci-app-nps/luasrc/controller/nps.lua
@@ -5,7 +5,7 @@ function index()
return
end
- entry({"admin", "services", "nps"}, cbi("nps"), _("Nps"), 100).dependent = true
+ entry({"admin", "services", "nps"}, cbi("nps"), _("Nps Penetrate"), 100).dependent = true
entry({"admin", "services", "nps", "status"}, call("act_status")).leaf = true
end
diff --git a/package/lean/luci-app-nps/luasrc/model/cbi/nps.lua b/package/lean/luci-app-nps/luasrc/model/cbi/nps.lua
index 9c37fc6b6..cd8afb494 100644
--- a/package/lean/luci-app-nps/luasrc/model/cbi/nps.lua
+++ b/package/lean/luci-app-nps/luasrc/model/cbi/nps.lua
@@ -1,5 +1,5 @@
m = Map("nps")
-m.title = translate("Nps")
+m.title = translate("Nps Penetrate")
m.description = translate("Nps is a fast reverse proxy to help you expose a local server behind a NAT or firewall to the internet.")
m:section(SimpleSection).template = "nps/nps_status"
@@ -43,12 +43,12 @@ crypt.description = translate("Encrypted the communication between Npc and Nps,
crypt.default = "1"
crypt.rmempty = false
-log_level = s:option(ListValue,"log_level",translate("Log Level"))
-log_level:value(0,"Emergency", translate("Emergency"))
-log_level:value(2,"Critical", translate("Critical"))
-log_level:value(3,"Error", translate("Error"))
-log_level:value(4,"Warning", translate("Warning"))
-log_level:value(7,"Debug", translate("Debug"))
+log_level = s:option(ListValue, "log_level", translate("Log Level"))
+log_level:value("0", "Emergency")
+log_level:value("2", "Critical")
+log_level:value("3", "Error")
+log_level:value("4", "Warning")
+log_level:value("7", "Debug")
log_level.default = "3"
return m
diff --git a/package/lean/luci-app-nps/luasrc/view/nps/nps_status.htm b/package/lean/luci-app-nps/luasrc/view/nps/nps_status.htm
old mode 100755
new mode 100644
diff --git a/package/lean/luci-app-nps/po/zh-cn/nps.po b/package/lean/luci-app-nps/po/zh-cn/nps.po
index cb89ed59c..571e9d274 100644
--- a/package/lean/luci-app-nps/po/zh-cn/nps.po
+++ b/package/lean/luci-app-nps/po/zh-cn/nps.po
@@ -1,4 +1,4 @@
-msgid "Nps"
+msgid "Nps Penetrate"
msgstr "Nps 内网穿透"
msgid "Nps is a fast reverse proxy to help you expose a local server behind a NAT or firewall to the internet."
diff --git a/package/lean/luci-app-nps/root/etc/config/nps b/package/lean/luci-app-nps/root/etc/config/nps
old mode 100755
new mode 100644
diff --git a/package/lean/luci-app-pppoe-relay/Makefile b/package/lean/luci-app-pppoe-relay/Makefile
index d65d987eb..43d8a97f3 100644
--- a/package/lean/luci-app-pppoe-relay/Makefile
+++ b/package/lean/luci-app-pppoe-relay/Makefile
@@ -14,5 +14,3 @@ PKG_RELEASE:=2
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
-
diff --git a/package/lean/luci-app-pppoe-relay/luasrc/controller/pppoe-relay.lua b/package/lean/luci-app-pppoe-relay/luasrc/controller/pppoe-relay.lua
index 0a23768a6..911925fa4 100644
--- a/package/lean/luci-app-pppoe-relay/luasrc/controller/pppoe-relay.lua
+++ b/package/lean/luci-app-pppoe-relay/luasrc/controller/pppoe-relay.lua
@@ -6,4 +6,4 @@ function index()
end
entry({"admin", "services", "pppoe-relay"}, cbi("pppoe-relay"), _("PPPoE Relay"), 90).dependent = true
-end
\ No newline at end of file
+end
diff --git a/package/lean/luci-app-pppoe-relay/luasrc/model/cbi/pppoe-relay.lua b/package/lean/luci-app-pppoe-relay/luasrc/model/cbi/pppoe-relay.lua
index c43127ec9..779e96538 100644
--- a/package/lean/luci-app-pppoe-relay/luasrc/model/cbi/pppoe-relay.lua
+++ b/package/lean/luci-app-pppoe-relay/luasrc/model/cbi/pppoe-relay.lua
@@ -1,19 +1,21 @@
-local s=require"luci.sys"
+local s = require"luci.sys"
local net = require "luci.model.network".init()
local ifaces = s.net:devices()
local m,s,o
-m=Map("pppoe-relay",translate("PPPoE Relay"))
+m = Map("pppoe-relay")
+m.title = translate("PPPoE Relay")
m.description = translate("Opening the PPPoE relay allows devices in the Intranet to create a separate PPPoE connection that can cross NAT.")
-s=m:section(TypedSection,"service")
-s.addremove=true
-s.anonymous=true
+
+s = m:section(TypedSection, "service")
+s.addremove = true
+s.anonymous = true
s.template="cbi/tblsection"
-o=s:option(Flag,"enabled",translate("Enabled"))
-o.rmempty=false
+o = s:option(Flag,"enabled",translate("Enabled"))
+o.rmempty = false
-o=s:option(ListValue,"server_interface",translate("Server Interface"))
+o = s:option(ListValue, "server_interface", translate("Server Interface"))
for _, iface in ipairs(ifaces) do
if not (iface == "lo" or iface:match("^ifb.*") or iface:match("gre*")) then
local nets = net:get_interface(iface)
@@ -25,9 +27,9 @@ for _, iface in ipairs(ifaces) do
o:value(iface, ((#nets > 0) and "%s (%s)" % {iface, nets} or iface))
end
end
-o.rmempty=true
+o.rmempty = true
-o=s:option(ListValue,"client_interface",translate("Client Interface"))
+o = s:option(ListValue, "client_interface", translate("Client Interface"))
for _, iface in ipairs(ifaces) do
if not (iface == "lo" or iface:match("^ifb.*") or iface:match("gre*")) then
local nets = net:get_interface(iface)
@@ -39,13 +41,13 @@ for _, iface in ipairs(ifaces) do
o:value(iface, ((#nets > 0) and "%s (%s)" % {iface, nets} or iface))
end
end
-o.rmempty=true
+o.rmempty = true
-o=s:option(Button,"is_run",translate("Check"))
+o = s:option(Button, "is_run", translate("Check"))
function o.write(self, section)
local server_interface = m.uci:get('pppoe-relay',section,"server_interface")
local client_interface = m.uci:get('pppoe-relay',section,"client_interface")
- isrun=luci.sys.call("ps | grep '/usr/sbin/pppoe-relay -S "..server_interface.." -C "..client_interface.."' | grep -v 'grep' >/dev/null")
+ isrun = luci.sys.call("ps | grep '/usr/sbin/pppoe-relay -S "..server_interface.." -C "..client_interface.."' | grep -v 'grep' >/dev/null")
if isrun == 1 then
o.description = ""
else
diff --git a/package/lean/luci-app-pptp-server/Makefile b/package/lean/luci-app-pptp-server/Makefile
index 2e13beb86..6792950c2 100644
--- a/package/lean/luci-app-pptp-server/Makefile
+++ b/package/lean/luci-app-pptp-server/Makefile
@@ -15,7 +15,3 @@ PKG_RELEASE:=13
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
-
-
-
diff --git a/package/lean/luci-app-pptp-server/luasrc/controller/pptp-server.lua b/package/lean/luci-app-pptp-server/luasrc/controller/pptp-server.lua
index 5bda83098..9dffebaa0 100644
--- a/package/lean/luci-app-pptp-server/luasrc/controller/pptp-server.lua
+++ b/package/lean/luci-app-pptp-server/luasrc/controller/pptp-server.lua
@@ -1,4 +1,3 @@
-
module("luci.controller.pptp-server", package.seeall)
function index()
@@ -6,14 +5,14 @@ function index()
return
end
- entry({"admin", "vpn"}, firstchild(), "VPN", 45).dependent = false
- entry({"admin", "vpn", "pptp-server"}, cbi("pptp-server/pptp-server"), _("PPTP VPN Server"), 80).dependent=false
- entry({"admin", "vpn", "pptp-server","status"},call("act_status")).leaf=true
+ entry({"admin", "vpn"}, firstchild(), "VPN", 45).dependent = false
+ entry({"admin", "vpn", "pptp-server"}, cbi("pptp-server"), _("PPTP VPN Server"), 80).dependent = false
+ entry({"admin", "vpn", "pptp-server","status"},call("act_status")).leaf = true
end
function act_status()
- local e={}
- e.running=luci.sys.call("pgrep pptpd >/dev/null")==0
+ local e = {}
+ e.running = luci.sys.call("pgrep pptpd >/dev/null") == 0
luci.http.prepare_content("application/json")
luci.http.write_json(e)
end
diff --git a/package/lean/luci-app-pptp-server/luasrc/model/cbi/pptp-server/pptp-server.lua b/package/lean/luci-app-pptp-server/luasrc/model/cbi/pptp-server.lua
similarity index 89%
rename from package/lean/luci-app-pptp-server/luasrc/model/cbi/pptp-server/pptp-server.lua
rename to package/lean/luci-app-pptp-server/luasrc/model/cbi/pptp-server.lua
index 7fa03cfdb..34320a1be 100644
--- a/package/lean/luci-app-pptp-server/luasrc/model/cbi/pptp-server/pptp-server.lua
+++ b/package/lean/luci-app-pptp-server/luasrc/model/cbi/pptp-server.lua
@@ -1,8 +1,8 @@
-
-mp = Map("pptpd", translate("PPTP VPN Server"))
+mp = Map("pptpd")
+mp.title = translate("PPTP VPN Server")
mp.description = translate("PPTP VPN Server connectivity using the native built-in VPN Client on Windows/Linux or Andriod")
-mp:section(SimpleSection).template = "pptp/pptp_status"
+mp:section(SimpleSection).template = "pptp-server/pptp-server_status"
s = mp:section(NamedSection, "pptpd", "service")
s.anonymouse = true
@@ -15,8 +15,8 @@ localip = s:option(Value, "localip", translate("Local IP"))
localip.datatype = "ip4addr"
clientip = s:option(Value, "remoteip", translate("Client IP"))
-clientip.datatype = "string"
clientip.description = translate("LAN DHCP reserved start-to-end IP addresses with the same subnet mask")
+clientip.datatype = "string"
remotedns = s:option(Value, "remotedns", translate("Remote Client DNS"))
remotedns.datatype = "ip4addr"
diff --git a/package/lean/luci-app-pptp-server/luasrc/view/pptp/pptp_status.htm b/package/lean/luci-app-pptp-server/luasrc/view/pptp-server/pptp-server_status.htm
similarity index 85%
rename from package/lean/luci-app-pptp-server/luasrc/view/pptp/pptp_status.htm
rename to package/lean/luci-app-pptp-server/luasrc/view/pptp-server/pptp-server_status.htm
index 11a2852d9..dd4446e0a 100644
--- a/package/lean/luci-app-pptp-server/luasrc/view/pptp/pptp_status.htm
+++ b/package/lean/luci-app-pptp-server/luasrc/view/pptp-server/pptp-server_status.htm
@@ -1,7 +1,7 @@
\ No newline at end of file
+
diff --git a/package/lean/luci-app-pptp-server/root/etc/uci-defaults/pptpd b/package/lean/luci-app-pptp-server/root/etc/uci-defaults/luci-pptpd
similarity index 100%
rename from package/lean/luci-app-pptp-server/root/etc/uci-defaults/pptpd
rename to package/lean/luci-app-pptp-server/root/etc/uci-defaults/luci-pptpd
diff --git a/package/lean/luci-app-ps3netsrv/Makefile b/package/lean/luci-app-ps3netsrv/Makefile
index 89c3dc0fd..3290eb2e4 100644
--- a/package/lean/luci-app-ps3netsrv/Makefile
+++ b/package/lean/luci-app-ps3netsrv/Makefile
@@ -15,4 +15,3 @@ PKG_RELEASE:=2
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
diff --git a/package/lean/luci-app-ps3netsrv/luasrc/controller/ps3netsrv.lua b/package/lean/luci-app-ps3netsrv/luasrc/controller/ps3netsrv.lua
index 737af05fa..cc49a9044 100644
--- a/package/lean/luci-app-ps3netsrv/luasrc/controller/ps3netsrv.lua
+++ b/package/lean/luci-app-ps3netsrv/luasrc/controller/ps3netsrv.lua
@@ -11,8 +11,8 @@ function index()
end
function act_status()
- local e={}
- e.running=luci.sys.call("ps | grep ps3netsrv |grep -v grep >/dev/null") == 0
+ local e = {}
+ e.running = luci.sys.call("ps | grep ps3netsrv |grep -v grep >/dev/null") == 0
luci.http.prepare_content("application/json")
luci.http.write_json(e)
end
diff --git a/package/lean/luci-app-ps3netsrv/luasrc/model/cbi/ps3netsrv.lua b/package/lean/luci-app-ps3netsrv/luasrc/model/cbi/ps3netsrv.lua
index 94db16034..a14dad661 100644
--- a/package/lean/luci-app-ps3netsrv/luasrc/model/cbi/ps3netsrv.lua
+++ b/package/lean/luci-app-ps3netsrv/luasrc/model/cbi/ps3netsrv.lua
@@ -1,24 +1,26 @@
-- Copyright 2020 Lean
-- Licensed to the public under the Apache License 2.0.
-m = Map("ps3netsrv", translate("PS3 NET Server"), translate("PS3NETSRV is ISO/PKG server for Sony PlayStation 3 webMAN-MOD plugin"))
+m = Map("ps3netsrv")
+m.title = translate("PS3 NET Server")
+m.description = translate("PS3NETSRV is ISO/PKG server for Sony PlayStation 3 webMAN-MOD plugin")
-m:section(SimpleSection).template = "ps3netsrv/ps3netsrv_status"
+m:section(SimpleSection).template = "ps3netsrv/ps3netsrv_status"
s = m:section(TypedSection, "ps3netsrv")
s.addremove = false
s.anonymous = true
-enable=s:option(Flag, "enabled", translate("Enabled"))
+enable = s:option(Flag, "enabled", translate("Enabled"))
enable.default = "0"
enable.rmempty = false
-db_path=s:option(Value, "dir", translate("Dir Path"))
+db_path = s:option(Value, "dir", translate("Dir Path"))
db_path.default = "/root"
db_path.rmempty = false
-port=s:option(Value, "port", translate("Port"))
+port = s:option(Value, "port", translate("Port"))
port.rmempty = false
port.datatype = "port"
-return m
\ No newline at end of file
+return m
diff --git a/package/lean/luci-app-ps3netsrv/luasrc/view/ps3netsrv/ps3netsrv_status.htm b/package/lean/luci-app-ps3netsrv/luasrc/view/ps3netsrv/ps3netsrv_status.htm
index ebd057020..60883d4c4 100644
--- a/package/lean/luci-app-ps3netsrv/luasrc/view/ps3netsrv/ps3netsrv_status.htm
+++ b/package/lean/luci-app-ps3netsrv/luasrc/view/ps3netsrv/ps3netsrv_status.htm
@@ -19,4 +19,4 @@ XHR.poll(3, '<%=url([[admin]], [[nas]], [[ps3netsrv]], [[status]])%>', null,
<%:Collecting data...%>
-
\ No newline at end of file
+
diff --git a/package/lean/luci-app-ramfree/Makefile b/package/lean/luci-app-ramfree/Makefile
index cddacda36..0793c3def 100644
--- a/package/lean/luci-app-ramfree/Makefile
+++ b/package/lean/luci-app-ramfree/Makefile
@@ -13,5 +13,3 @@ PKG_RELEASE:=1
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
-
diff --git a/package/lean/luci-app-samba4/luasrc/model/cbi/samba4.lua b/package/lean/luci-app-samba4/luasrc/model/cbi/samba4.lua
index 2a1399b96..2e80096fb 100644
--- a/package/lean/luci-app-samba4/luasrc/model/cbi/samba4.lua
+++ b/package/lean/luci-app-samba4/luasrc/model/cbi/samba4.lua
@@ -16,8 +16,8 @@ h = s:taboption("general", Flag, "homes", translate("Share home-directories"),
"network shares"))
h.rmempty = false
-macos = s:taboption("general", Flag, "macos", translate("Enable macOS compatible shares"),
- translate("Enables Apple's AAPL extension globally and adds macOS compatibility options to all shares."))
+macos = s:taboption("general", Flag, "macos", translate("Enable macOS compatible shares"))
+macos.description = translate("Enables Apple's AAPL extension globally and adds macOS compatibility options to all shares.")
macos.rmempty = false
if nixio.fs.access("/usr/sbin/nmbd") then
diff --git a/package/lean/luci-app-ssrserver-python/Makefile b/package/lean/luci-app-ssrserver-python/Makefile
index 4b0273637..ba6ea6722 100644
--- a/package/lean/luci-app-ssrserver-python/Makefile
+++ b/package/lean/luci-app-ssrserver-python/Makefile
@@ -15,5 +15,3 @@ PKG_RELEASE:=7
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
-
diff --git a/package/lean/luci-app-ssrserver-python/luasrc/controller/ssrs.lua b/package/lean/luci-app-ssrserver-python/luasrc/controller/ssrs.lua
index 29f46f9fb..af6ad1add 100644
--- a/package/lean/luci-app-ssrserver-python/luasrc/controller/ssrs.lua
+++ b/package/lean/luci-app-ssrserver-python/luasrc/controller/ssrs.lua
@@ -11,8 +11,8 @@ function index()
end
function act_status()
- local e={}
- e.running=luci.sys.call("ps -w | grep ssrs.json |grep -v grep >/dev/null") == 0
+ local e = {}
+ e.running = luci.sys.call("ps -w | grep ssrs.json |grep -v grep >/dev/null") == 0
luci.http.prepare_content("application/json")
luci.http.write_json(e)
end
diff --git a/package/lean/luci-app-ssrserver-python/luasrc/model/cbi/ssrs.lua b/package/lean/luci-app-ssrserver-python/luasrc/model/cbi/ssrs.lua
index 95de8b959..41d4411d6 100644
--- a/package/lean/luci-app-ssrserver-python/luasrc/model/cbi/ssrs.lua
+++ b/package/lean/luci-app-ssrserver-python/luasrc/model/cbi/ssrs.lua
@@ -1,7 +1,7 @@
local a,t,e
local m, s
-local o=require"nixio.fs"
-local n={
+local o = require"nixio.fs"
+local n = {
"none",
"aes-128-ctr",
"aes-192-ctr",
@@ -15,7 +15,8 @@ local n={
"chacha20",
"chacha20-ietf-poly1305",
}
-local s={
+
+local s = {
"origin",
"verify_deflate",
"auth_sha1_v4",
@@ -28,6 +29,7 @@ local s={
"auth_chain_e",
"auth_chain_f",
}
+
local i={
"plain",
"http_simple",
@@ -36,42 +38,44 @@ local i={
"tls1.2_ticket_auth",
"tls1.2_ticket_fastauth",
}
+
local o={
"false",
"true",
}
-a= Map("ssrs", translate("ShadowSocksR Server Config"))
+a = Map("ssrs")
+a.title = translate("ShadowSocksR Server Config")
a.description = translate("ShadowsocksR Python Server is a fork of the Shadowsocks project, claimed to be superior in terms of security and stability")
-a:section(SimpleSection).template = "ssrs/ssrs_status"
+a:section(SimpleSection).template = "ssrs/ssrs_status"
-t=a:section(TypedSection,"server",translate(""))
-t.anonymous=true
-t.addremove=false
+t = a:section(TypedSection,"server",translate(""))
+t.anonymous = true
+t.addremove = false
-e=t:option(Flag,"enable",translate("Enable"))
-e.rmempty=false
+e = t:option(Flag, "enable", translate("Enable"))
+e.rmempty = false
-e=t:option(Value,"server_port",translate("Server Port"))
-e.datatype="port"
-e.rmempty=false
-e.default=139
+e = t:option(Value, "server_port", translate("Server Port"))
+e.datatype = "port"
+e.rmempty = false
+e.default = 139
-e=t:option(Value,"password",translate("Password"))
-e.password=true
-e.rmempty=false
+e = t:option(Value, "password", translate("Password"))
+e.password = true
+e.rmempty = false
-e=t:option(ListValue,"encrypt_method",translate("Encrypt Method"))
+e = t:option(ListValue, "encrypt_method", translate("Encrypt Method"))
for a,t in ipairs(n)do e:value(t)end
-e.rmempty=false
+e.rmempty = false
-e=t:option(ListValue,"protocol",translate("Protocol"))
+e = t:option(ListValue, "protocol", translate("Protocol"))
for a,t in ipairs(s)do e:value(t)end
-e.rmempty=false
+e.rmempty = false
-e=t:option(ListValue,"obfs",translate("Obfs"))
+e = t:option(ListValue,"obfs",translate("Obfs"))
for a,t in ipairs(i)do e:value(t)end
-e.rmempty=false
+e.rmempty = false
return a
diff --git a/package/lean/luci-app-ssrserver-python/luasrc/view/ssrs/ssrs_status.htm b/package/lean/luci-app-ssrserver-python/luasrc/view/ssrs/ssrs_status.htm
index 043620d08..dd5c11285 100644
--- a/package/lean/luci-app-ssrserver-python/luasrc/view/ssrs/ssrs_status.htm
+++ b/package/lean/luci-app-ssrserver-python/luasrc/view/ssrs/ssrs_status.htm
@@ -19,4 +19,4 @@ XHR.poll(3, '<%=url([[admin]], [[vpn]], [[ssrs]], [[status]])%>', null,
<%:Collecting data...%>
-
\ No newline at end of file
+
diff --git a/package/lean/luci-app-syncdial/Makefile b/package/lean/luci-app-syncdial/Makefile
old mode 100755
new mode 100644
index 70da33861..5b0abdbf1
--- a/package/lean/luci-app-syncdial/Makefile
+++ b/package/lean/luci-app-syncdial/Makefile
@@ -14,4 +14,3 @@ PKG_RELEASE:=25
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-#Makefile for syncdial
diff --git a/package/lean/luci-app-syncdial/luasrc/controller/syncdial.lua b/package/lean/luci-app-syncdial/luasrc/controller/syncdial.lua
index 1ef74ad0f..f10229d7c 100644
--- a/package/lean/luci-app-syncdial/luasrc/controller/syncdial.lua
+++ b/package/lean/luci-app-syncdial/luasrc/controller/syncdial.lua
@@ -1,4 +1,5 @@
module("luci.controller.syncdial",package.seeall)
+
function index()
if not nixio.fs.access("/etc/config/syncdial") then
return
diff --git a/package/lean/luci-app-syncdial/luasrc/model/cbi/syncdial.lua b/package/lean/luci-app-syncdial/luasrc/model/cbi/syncdial.lua
index 30c7f172c..73be9b6aa 100644
--- a/package/lean/luci-app-syncdial/luasrc/model/cbi/syncdial.lua
+++ b/package/lean/luci-app-syncdial/luasrc/model/cbi/syncdial.lua
@@ -1,62 +1,89 @@
-local e=require"nixio.fs"
+local e = require"nixio.fs"
require("luci.tools.webadmin")
-local e="mwan3 status | grep -c \"is online and tracking is active\""
-local e=io.popen(e,"r")
-local t=e:read("*a")
+local e = "mwan3 status | grep -c \"is online and tracking is active\""
+local e = io.popen(e,"r")
+local t = e:read("*a")
e:close()
-m=Map("syncdial",translate("多线多拨"),
-translate("使用macvlan驱动创建多个虚拟WAN口,支持并发多拨
当前在线接口数量:")..t)
-s=m:section(TypedSection,"syncdial",translate(" "))
-s.anonymous=true
-o=s:option(Flag,"enabled","启用")
-o.rmempty=false
-o=s:option(Flag,"syncon","启用并发多拨")
-o.rmempty=false
-o=s:option(ListValue,"dial_type",translate("多拨类型"))
-o:value("1",translate("单线多拨"))
-o:value("2",translate("双线多拨"))
-o.rmempty=false
-o=s:option(Value,"wanselect",translate("选择外网接口"),translate("指定要多拨的外网接口,如wan"))
+m = Map("syncdial")
+m.title = translate("多线多拨")
+m.description = translate("使用macvlan驱动创建多个虚拟WAN口,支持并发多拨
当前在线接口数量:")..t
+
+s = m:section(TypedSection, "syncdial")
+s.anonymous = true
+
+o = s:option(Flag, "enabled", translate("启用"))
+o.rmempty = false
+
+o = s:option(Flag, "syncon", translate("启用并发多拨"))
+o.rmempty = false
+
+o = s:option(ListValue, "dial_type", translate("多拨类型"))
+o:value("1", translate("单线多拨"))
+o:value("2", translate("双线多拨"))
+o.rmempty = false
+
+o = s:option(Value, "wanselect", translate("选择外网接口"))
+o.description = translate("指定要多拨的外网接口,如wan")
luci.tools.webadmin.cbi_add_networks(o)
-o.optional=false
-o.rmempty=false
-o=s:option(Value,"wannum","虚拟WAN接口数量")
-o.datatype="range(0,249)"
-o.optional=false
-o.default=1
-o=s:option(Flag,"bindwan","绑定物理接口")
-o.rmempty=false
-o=s:option(Value,"wanselect2",translate("选择第二个外网接口"),translate("指定要多拨的第二个外网接口,如wan2"))
+o.optional = false
+o.rmempty = false
+
+o = s:option(Value, "wannum", translate("虚拟WAN接口数量"))
+o.datatype = "range(0,249)"
+o.optional = false
+o.default = 1
+
+o = s:option(Flag, "bindwan", translate("绑定物理接口"))
+o.rmempty = false
+
+o = s:option(Value, "wanselect2", translate("选择第二个外网接口"))
+o.description = translate("指定要多拨的第二个外网接口,如wan2")
luci.tools.webadmin.cbi_add_networks(o)
o.optional=false
o:depends("dial_type","2")
-o=s:option(Value,"wannum2",translate("第二条线虚拟WAN接口数量"),translate("设置第二条线的拨号数"))
-o.datatype="range(0,249)"
-o.optional=false
-o.default=1
+
+o = s:option(Value, "wannum2", translate("第二条线虚拟WAN接口数量"))
+o.description = translate("设置第二条线的拨号数")
+o.datatype = "range(0,249)"
+o.optional = false
+o.default = 1
o:depends("dial_type","2")
-o=s:option(Flag,"bindwan2","绑定物理接口","第二条线生成的虚拟接口绑定当前物理接口")
-o.rmempty=false
+
+o = s:option(Flag, "bindwan2", translate("绑定物理接口"))
+o.description = translate("第二条线生成的虚拟接口绑定当前物理接口")
+o.rmempty = false
o:depends("dial_type","2")
-o=s:option(Flag,"dialchk","启用掉线检测")
-o.rmempty=false
-o=s:option(Value,"dialnum","最低在线接口数量","如果在线接口数量小于这个值则重拨。")
-o.datatype="range(0,248)"
-o.optional=false
-o.default=2
-o=s:option(Value,"dialnum2","第二条线最低在线接口数量","如果第二条线在线接口数量小于这个值则重拨。")
-o.datatype="range(0,248)"
-o.optional=false
-o.default=2
+
+o = s:option(Flag, "dialchk", translate("启用掉线检测"))
+o.rmempty = false
+
+o = s:option(Value, "dialnum", translate("最低在线接口数量"))
+o.description = translate("如果在线接口数量小于这个值则重拨。")
+o.datatype = "range(0,248)"
+o.optional = false
+o.default = 2
+
+o = s:option(Value, "dialnum2", translate("第二条线最低在线接口数量"))
+o.description = translate("如果第二条线在线接口数量小于这个值则重拨。")
+o.datatype = "range(0,248)"
+o.optional = false
+o.default = 2
o:depends("dial_type","2")
-o=s:option(Value,"dialwait","重拨等待时间","重拨时,接口全部下线后下一次拨号前的等待时间。单位:秒 最小值:5秒")
-o.datatype="and(uinteger,min(5))"
-o.optional=false
-o=s:option(Flag,"old_frame","使用旧的macvlan创建方式")
-o.rmempty=false
-o=s:option(Flag,"nomwan","不自动配置MWAN3负载均衡","需要自定义负载均衡设置或者要使用策略路由的用户选择")
-o.rmempty=false
-o=s:option(DummyValue,"_redial","重新并发拨号")
-o.template="syncdial/redial_button"
-o.width="10%"
+
+o = s:option(Value, "dialwait", translate("重拨等待时间"))
+o.description = translate("重拨时,接口全部下线后下一次拨号前的等待时间。单位:秒 最小值:5秒")
+o.datatype = "and(uinteger,min(5))"
+o.optional = false
+
+o = s:option(Flag, "old_frame", translate("使用旧的macvlan创建方式"))
+o.rmempty = false
+
+o = s:option(Flag, "nomwan", translate("不自动配置MWAN3负载均衡"))
+o.description = translate("需要自定义负载均衡设置或者要使用策略路由的用户选择")
+o.rmempty = false
+
+o = s:option(DummyValue, "_redial", translate("重新并发拨号"))
+o.template = "syncdial/redial_button"
+o.width = "10%"
+
return m
diff --git a/package/lean/luci-app-syncdial/root/etc/hotplug.d/iface/01-dialcheck b/package/lean/luci-app-syncdial/root/etc/hotplug.d/iface/01-dialcheck
old mode 100644
new mode 100755
diff --git a/package/lean/luci-app-syncdial/root/etc/hotplug.d/iface/01-mvifcreate b/package/lean/luci-app-syncdial/root/etc/hotplug.d/iface/01-mvifcreate
old mode 100644
new mode 100755
diff --git a/package/lean/luci-app-ttyd/Makefile b/package/lean/luci-app-ttyd/Makefile
index 1554695ce..b44d1fd86 100644
--- a/package/lean/luci-app-ttyd/Makefile
+++ b/package/lean/luci-app-ttyd/Makefile
@@ -14,4 +14,3 @@ PKG_RELEASE:=3
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
diff --git a/package/lean/luci-app-unblockmusic/luasrc/model/cbi/unblockmusic/unblockmusic_log.lua b/package/lean/luci-app-unblockmusic/luasrc/model/cbi/unblockmusic/unblockmusic_log.lua
index c02d1cc4b..6bbbd6a44 100644
--- a/package/lean/luci-app-unblockmusic/luasrc/model/cbi/unblockmusic/unblockmusic_log.lua
+++ b/package/lean/luci-app-unblockmusic/luasrc/model/cbi/unblockmusic/unblockmusic_log.lua
@@ -10,6 +10,6 @@ function t.cfgvalue()
luci.sys.exec("grep -B 1 'http' /tmp/unblockmusic.log | grep -v -e'running' -e'TLS' -e'Transport' -e'POST' -e'github' -e'consumed' -e'starting' -e'error' > /tmp/music.log")
return fs.readfile(conffile) or ""
end
-t.readonly="readonly"
+t.readonly = "readonly"
-return f
\ No newline at end of file
+return f
diff --git a/package/lean/luci-app-unblockmusic/luasrc/view/unblockmusic/unblockmusic_status.htm b/package/lean/luci-app-unblockmusic/luasrc/view/unblockmusic/unblockmusic_status.htm
index 74dd92812..cd5e1e8d2 100644
--- a/package/lean/luci-app-unblockmusic/luasrc/view/unblockmusic/unblockmusic_status.htm
+++ b/package/lean/luci-app-unblockmusic/luasrc/view/unblockmusic/unblockmusic_status.htm
@@ -19,4 +19,4 @@ XHR.poll(3, '<%=url([[admin]], [[services]], [[unblockmusic]], [[status]])%>', n
<%:Collecting data...%>
-
\ No newline at end of file
+
diff --git a/package/lean/luci-app-usb-printer/Makefile b/package/lean/luci-app-usb-printer/Makefile
index b21337681..57d895e66 100644
--- a/package/lean/luci-app-usb-printer/Makefile
+++ b/package/lean/luci-app-usb-printer/Makefile
@@ -8,11 +8,10 @@ include $(TOPDIR)/rules.mk
LUCI_TITLE:=USB Printer Share via TCP/IP
LUCI_DEPENDS:=+p910nd +kmod-usb-printer
+PKG_NAME:=luci-app-usb-printer
PKG_VERSION:=1.0
PKG_RELEASE:=2
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-#applications/luci-app-usb-printer/
-#applications/luci-app-usb-printer/
diff --git a/package/lean/luci-app-uugamebooster/Makefile b/package/lean/luci-app-uugamebooster/Makefile
index 55739ecc5..7a65c294f 100644
--- a/package/lean/luci-app-uugamebooster/Makefile
+++ b/package/lean/luci-app-uugamebooster/Makefile
@@ -14,4 +14,4 @@ PKG_RELEASE:=8
include $(TOPDIR)/feeds/luci/luci.mk
-# call BuildPackage - OpenWrt buildroot signature
\ No newline at end of file
+# call BuildPackage - OpenWrt buildroot signature
diff --git a/package/lean/luci-app-uugamebooster/luasrc/controller/uuplugin.lua b/package/lean/luci-app-uugamebooster/luasrc/controller/uuplugin.lua
index f6325d503..ce8748d1d 100644
--- a/package/lean/luci-app-uugamebooster/luasrc/controller/uuplugin.lua
+++ b/package/lean/luci-app-uugamebooster/luasrc/controller/uuplugin.lua
@@ -10,8 +10,8 @@ function index()
end
function act_status()
- local e={}
- e.running=luci.sys.call("pgrep -f uuplugin >/dev/null")==0
+ local e = {}
+ e.running = luci.sys.call("pgrep -f uuplugin >/dev/null") == 0
luci.http.prepare_content("application/json")
luci.http.write_json(e)
end
diff --git a/package/lean/luci-app-uugamebooster/root/etc/uci-defaults/45_luci-uuplugin b/package/lean/luci-app-uugamebooster/root/etc/uci-defaults/45_luci-uuplugin
old mode 100644
new mode 100755
diff --git a/package/lean/luci-app-v2ray-server/luasrc/controller/v2ray_server.lua b/package/lean/luci-app-v2ray-server/luasrc/controller/v2ray_server.lua
index 9b07df5ab..f7e283662 100644
--- a/package/lean/luci-app-v2ray-server/luasrc/controller/v2ray_server.lua
+++ b/package/lean/luci-app-v2ray-server/luasrc/controller/v2ray_server.lua
@@ -56,4 +56,3 @@ function v2ray_update()
http_write_json(json)
end
-
diff --git a/package/lean/luci-app-v2ray-server/luasrc/model/cbi/v2ray_server/index.lua b/package/lean/luci-app-v2ray-server/luasrc/model/cbi/v2ray_server/index.lua
index 2eea43799..f3383e002 100644
--- a/package/lean/luci-app-v2ray-server/luasrc/model/cbi/v2ray_server/index.lua
+++ b/package/lean/luci-app-v2ray-server/luasrc/model/cbi/v2ray_server/index.lua
@@ -1,11 +1,12 @@
local ds = require "luci.dispatcher"
-local o = "v2ray_server"
-m = Map(o, translate("V2ray Server"))
+m = Map("v2ray_server")
+m.title = translate("V2ray Server")
t = m:section(TypedSection, "global", translate("Global Settings"))
t.anonymous = true
t.addremove = false
+
e = t:option(Flag, "enable", translate("Enable"))
e.rmempty = false
t:append(Template("v2ray_server/v2ray"))
@@ -14,17 +15,17 @@ t = m:section(TypedSection, "user", translate("Users Manager"))
t.anonymous = true
t.addremove = true
t.template = "cbi/tblsection"
-t.extedit = ds.build_url("admin", "services", o, "config", "%s")
+t.extedit = ds.build_url("admin", "services", "v2ray_server", "config", "%s")
function t.create(t, e)
local uuid = luci.sys.exec("echo -n $(cat /proc/sys/kernel/random/uuid)") or ""
uuid = string.gsub(uuid, "-", "")
local e = TypedSection.create(t, uuid)
- luci.http.redirect(ds.build_url("admin", "services", o, "config", uuid))
+ luci.http.redirect(ds.build_url("admin", "services", "v2ray_server", "config", uuid))
end
function t.remove(t, a)
t.map.proceed = true
t.map:del(a)
- luci.http.redirect(ds.build_url("admin", "services", o))
+ luci.http.redirect(ds.build_url("admin", "services", "v2ray_server"))
end
e = t:option(Flag, "enable", translate("Enable"))
@@ -53,5 +54,5 @@ end
m:append(Template("v2ray_server/log"))
m:append(Template("v2ray_server/users_list_status"))
-return m
+return m
diff --git a/package/lean/luci-app-verysync/luasrc/controller/verysync.lua b/package/lean/luci-app-verysync/luasrc/controller/verysync.lua
index 26d0da7ba..f89a2a1c8 100644
--- a/package/lean/luci-app-verysync/luasrc/controller/verysync.lua
+++ b/package/lean/luci-app-verysync/luasrc/controller/verysync.lua
@@ -10,8 +10,8 @@ function index()
end
function act_status()
- local e={}
- e.running=luci.sys.call("pgrep verysync >/dev/null")==0
+ local e = {}
+ e.running = luci.sys.call("pgrep verysync >/dev/null") == 0
luci.http.prepare_content("application/json")
luci.http.write_json(e)
end
diff --git a/package/lean/luci-app-verysync/luasrc/model/cbi/verysync.lua b/package/lean/luci-app-verysync/luasrc/model/cbi/verysync.lua
index 097d6f188..c0f2bf84b 100644
--- a/package/lean/luci-app-verysync/luasrc/model/cbi/verysync.lua
+++ b/package/lean/luci-app-verysync/luasrc/model/cbi/verysync.lua
@@ -6,7 +6,7 @@ m = Map("verysync")
m.title = translate("Verysync")
m.description = translate("Simple and easy-to-use multi-platform file synchronization software, astonishing transmission speed is different from the greatest advantage of other products. Micro-force synchronization of intelligent P2P technology to accelerate synchronization, will split the file into several KB-only data synchronization, and the file will be AES encryption processing.")
-m:section(SimpleSection).template = "verysync/verysync_status"
+m:section(SimpleSection).template = "verysync/verysync_status"
s = m:section(TypedSection, "verysync")
s.addremove = false
diff --git a/package/lean/luci-app-vsftpd/Makefile b/package/lean/luci-app-vsftpd/Makefile
index 49b71c9e9..74dacb529 100644
--- a/package/lean/luci-app-vsftpd/Makefile
+++ b/package/lean/luci-app-vsftpd/Makefile
@@ -14,4 +14,3 @@ PKG_RELEASE:=3
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
diff --git a/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/anonymous.lua b/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/anonymous.lua
index 3ebbb4ba9..a21cdcce1 100644
--- a/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/anonymous.lua
+++ b/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/anonymous.lua
@@ -12,14 +12,16 @@ You may obtain a copy of the License at
$Id$
]]--
-m = Map("vsftpd", translate("FTP Server - Anonymous Settings"))
+m = Map("vsftpd")
+m.title = translate("FTP Server - Anonymous Settings")
sa = m:section(NamedSection, "anonymous", "anonymous", translate("Anonymous Settings"))
o = sa:option(Flag, "enabled", translate("Enabled"))
o.default = false
-o = sa:option(Value, "username", translate("Username"), translate("An actual local user to handle anonymous user"))
+o = sa:option(Value, "username", translate("Username"))
+o.description = translate("An actual local user to handle anonymous user")
o.default = "ftp"
o = sa:option(Value, "root", translate("Root directory"))
@@ -28,7 +30,8 @@ o.default = "/home/ftp"
o = sa:option(Value, "umask", translate("File mode umask"))
o.default = "022"
-o = sa:option(Value, "maxrate", translate("Max transmit rate"), translate("0 means no limitation"))
+o = sa:option(Value, "maxrate", translate("Max transmit rate"))
+o.description = translate("0 means no limitation")
o.default = "0"
o = sa:option(Flag, "writemkdir", translate("Enable write/mkdir"))
@@ -37,8 +40,8 @@ o.default = false
o = sa:option(Flag, "upload", translate("Enable upload"))
o.default = false
-o = sa:option(Flag, "others", translate("Enable other rights"), translate("Include rename, deletion ..."))
+o = sa:option(Flag, "others", translate("Enable other rights"))
+o.description = translate("Include rename, deletion ...")
o.default = false
-
return m
diff --git a/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/general.lua b/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/general.lua
index 2de653c79..0fadcb9f1 100644
--- a/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/general.lua
+++ b/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/general.lua
@@ -12,7 +12,8 @@ You may obtain a copy of the License at
$Id$
]]--
-m = Map("vsftpd", translate("FTP Server - General Settings"))
+m = Map("vsftpd")
+m.description = translate("FTP Server - General Settings")
sl = m:section(NamedSection, "listen", "listen", translate("Listening Settings"))
@@ -50,26 +51,32 @@ o.default = "51000"
sg = m:section(NamedSection, "global", "global", translate("Global Settings"))
-o = sg:option(Flag, "write", translate("Enable write"), translate("When disabled, all write request will give permission denied."));
+o = sg:option(Flag, "write", translate("Enable write"))
+o.description = translate("When disabled, all write request will give permission denied.")
o.default = true
-o = sg:option(Flag, "download", translate("Enable download"), translate("When disabled, all download request will give permission denied."));
+o = sg:option(Flag, "download", translate("Enable download"))
+o.description = translate("When disabled, all download request will give permission denied.")
o.default = true
-o = sg:option(Flag, "dirlist", translate("Enable directory list"), translate("When disabled, list commands will give permission denied."))
+o = sg:option(Flag, "dirlist", translate("Enable directory list"))
+o.description = translate("When disabled, list commands will give permission denied.")
o.default = true
o = sg:option(Flag, "lsrecurse", translate("Allow directory recursely list"))
-o = sg:option(Flag, "dotfile", translate("Show dot files"), translate(". and .. are excluded."));
+o = sg:option(Flag, "dotfile", translate("Show dot files"))
+o.description = translate(". and .. are excluded.")
o.default = true
-o = sg:option(Value, "umask", translate("File mode umask"), translate("Uploaded file mode will be 666 - <umask>; directory mode will be 777 - <umask>."))
+o = sg:option(Value, "umask", translate("File mode umask"))
+o.description = translate("Uploaded file mode will be 666 - <umask>; directory mode will be 777 - <umask>.")
o.default = "022"
o = sg:option(Value, "banner", translate("FTP Banner"))
-o = sg:option(Flag, "dirmessage", translate("Enable directory message"), translate("A message will be displayed when entering a directory."))
+o = sg:option(Flag, "dirmessage", translate("Enable directory message"))
+o.description = translate("A message will be displayed when entering a directory.")
o = sg:option(Value, "dirmsgfile", translate("Directory message filename"))
o.default = ".message"
@@ -80,7 +87,8 @@ sl = m:section(NamedSection, "local", "local", translate("Local Users"))
o = sl:option(Flag, "enabled", translate("Enable local user"))
o.rmempty = false
-o = sl:option(Value, "root", translate("Root directory"), translate("Leave empty will use user's home directory"))
+o = sl:option(Value, "root", translate("Root directory"))
+o.description = translate("Leave empty will use user's home directory")
o.default = ""
@@ -96,27 +104,39 @@ o:value("upload", translate("Upload only"))
o:value("both", translate("Both download and upload"))
o.default = "both"
-o = sc:option(Value, "idletimeout", translate("Idle session timeout"), translate("in seconds"))
+o = sc:option(Value, "idletimeout", translate("Idle session timeout"))
+o.description = translate("in seconds")
o.datatype = "uinteger"
o.default = "1800"
-o = sc:option(Value, "conntimeout", translate("Connection timeout"), translate("in seconds"))
+
+o = sc:option(Value, "conntimeout", translate("Connection timeout"))
+o.description = translate("in seconds")
o.datatype = "uinteger"
o.default = "120"
-o = sc:option(Value, "dataconntimeout", translate("Data connection timeout"), translate("in seconds"))
+
+o = sc:option(Value, "dataconntimeout", translate("Data connection timeout"))
+o.description = translate("in seconds")
o.datatype = "uinteger"
o.default = "120"
-o = sc:option(Value, "maxclient", translate("Max clients"), translate("0 means no limitation"))
+
+o = sc:option(Value, "maxclient", translate("Max clients"))
+o.description = translate("0 means no limitation")
o.datatype = "uinteger"
o.default = "0"
-o = sc:option(Value, "maxperip", translate("Max clients per IP"), translate("0 means no limitation"))
+
+o = sc:option(Value, "maxperip", translate("Max clients per IP"))
+o.description = translate("0 means no limitation")
o.datatype = "uinteger"
o.default = "0"
-o = sc:option(Value, "maxrate", translate("Max transmit rate"), translate("in KB/s, 0 means no limitation"))
+
+o = sc:option(Value, "maxrate", translate("Max transmit rate"))
+o.description = translate("in KB/s, 0 means no limitation")
o.datatype = "uinteger"
o.default = "0"
-o = sc:option(Value, "maxretry", translate("Max login fail count"), translate("Can not be zero, default is 3"))
+
+o = sc:option(Value, "maxretry", translate("Max login fail count"))
+o.description = translate("Can not be zero, default is 3")
o.datatype = "uinteger"
o.default = "3"
-
return m
diff --git a/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/item.lua b/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/item.lua
index 2a0003c8b..dce0f3abc 100644
--- a/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/item.lua
+++ b/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/item.lua
@@ -15,7 +15,8 @@ $Id$
local sid = arg[1]
local utl = require "luci.util"
-m = Map("vsftpd", translate("FTP Server - Virtual User <new>"))
+m = Map("vsftpd")
+m.title = translate("FTP Server - Virtual User <new>")
m.redirect = luci.dispatcher.build_url("admin/nas/vsftpd/users")
@@ -54,7 +55,8 @@ o.default = "/home/ftp"
o = s:option(Value, "umask", translate("File mode umask"))
o.default = "022"
-o = s:option(Value, "maxrate", translate("Max transmit rate"), translate("0 means no limitation"))
+o = s:option(Value, "maxrate", translate("Max transmit rate"))
+o.description = translate("0 means no limitation")
o.default = "0"
o = s:option(Flag, "writemkdir", translate("Enable write/mkdir"))
@@ -63,8 +65,8 @@ o.default = false
o = s:option(Flag, "upload", translate("Enable upload"))
o.default = false
-o = s:option(Flag, "others", translate("Enable other rights"), translate("Include rename, deletion ..."))
+o = s:option(Flag, "others", translate("Enable other rights"))
+o.description = translate("Include rename, deletion ...")
o.default = false
-
return m
diff --git a/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/log.lua b/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/log.lua
index 969ce817c..c2bef6dfd 100644
--- a/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/log.lua
+++ b/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/log.lua
@@ -12,7 +12,8 @@ You may obtain a copy of the License at
$Id$
]]--
-m = Map("vsftpd", translate("FTP Server - Log Settings"))
+m = Map("vsftpd")
+m.title = translate("FTP Server - Log Settings")
sl = m:section(NamedSection, "log", "log", translate("Log Settings"))
@@ -25,5 +26,4 @@ o.default = true
o = sl:option(Value, "file", translate("Log file"))
o.default = "/var/log/vsftpd.log"
-
return m
diff --git a/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/users.lua b/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/users.lua
index 2ffaf759d..abaebae9f 100644
--- a/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/users.lua
+++ b/package/lean/luci-app-vsftpd/luasrc/model/cbi/vsftpd/users.lua
@@ -12,14 +12,16 @@ You may obtain a copy of the License at
$Id$
]]--
-m = Map("vsftpd", translate("FTP Server - Virtual User Settings"))
+m = Map("vsftpd")
+m.title = translate("FTP Server - Virtual User Settings")
sv = m:section(NamedSection, "vuser", "vuser", translate("Settings"))
o = sv:option(Flag, "enabled", translate("Enabled"))
o.default = false
-o = sv:option(Value, "username", translate("Username"), translate("An actual local user to handle virtual users"))
+o = sv:option(Value, "username", translate("Username"))
+o.description = translate("An actual local user to handle virtual users")
o.default = "ftp"
s = m:section(TypedSection, "user", translate("User lists"))
diff --git a/package/lean/luci-app-webadmin/Makefile b/package/lean/luci-app-webadmin/Makefile
index d469a60fd..30a58d9b1 100644
--- a/package/lean/luci-app-webadmin/Makefile
+++ b/package/lean/luci-app-webadmin/Makefile
@@ -14,5 +14,3 @@ PKG_RELEASE:=1
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
-
diff --git a/package/lean/luci-app-webadmin/luasrc/controller/webadmin.lua b/package/lean/luci-app-webadmin/luasrc/controller/webadmin.lua
index 3da17247b..5f173005a 100644
--- a/package/lean/luci-app-webadmin/luasrc/controller/webadmin.lua
+++ b/package/lean/luci-app-webadmin/luasrc/controller/webadmin.lua
@@ -10,4 +10,3 @@ function index()
entry({"admin", "system", "webadmin"}, cbi("webadmin"), _("Web Admin"), 1).leaf = true
end
-
diff --git a/package/lean/luci-app-webadmin/luasrc/model/cbi/webadmin.lua b/package/lean/luci-app-webadmin/luasrc/model/cbi/webadmin.lua
index e1872d20d..dc80851c5 100644
--- a/package/lean/luci-app-webadmin/luasrc/model/cbi/webadmin.lua
+++ b/package/lean/luci-app-webadmin/luasrc/model/cbi/webadmin.lua
@@ -3,14 +3,16 @@
local fs = require("nixio.fs")
-local m = Map("uhttpd", translate("Web Admin Settings"),
- translate("Web Admin Settings Page"))
+m = Map("uhttpd")
+m.title = translate("Web Admin Settings")
+m.description = translate("Web Admin Settings Page")
-local ucs = m:section(TypedSection, "uhttpd")
+ucs = m:section(TypedSection, "uhttpd")
ucs.addremove = false
ucs.anonymous = true
-lhttp = ucs:option(DynamicList, "listen_http", translate("HTTP listeners (address:port)"), translate("Bind to specific interface:port (by specifying interface address"))
+lhttp = ucs:option(DynamicList, "listen_http", translate("HTTP listeners (address:port)"))
+lhttp.description = translate("Bind to specific interface:port (by specifying interface address")
lhttp.datatype = "list(ipaddrport(1))"
function lhttp.validate(self, value, section)
@@ -39,11 +41,12 @@ function lhttp.validate(self, value, section)
end
o = ucs:option(Flag, "redirect_https", translate("Redirect all HTTP to HTTPS"))
+o.description = translate("Redirect all HTTP to HTTPS when SSl cert was installed")
o.default = o.enabled
o.rmempty = false
-o.description = translate("Redirect all HTTP to HTTPS when SSl cert was installed")
-o = ucs:option(Flag, "rfc1918_filter", translate("Ignore private IPs on public interface"), translate("Prevent access from private (RFC1918) IPs on an interface if it has an public IP address"))
+o = ucs:option(Flag, "rfc1918_filter", translate("Ignore private IPs on public interface"))
+o.description = translate("Prevent access from private (RFC1918) IPs on an interface if it has an public IP address")
o.default = o.enabled
o.rmempty = false
diff --git a/package/lean/luci-app-wrtbwmon/Makefile b/package/lean/luci-app-wrtbwmon/Makefile
index 412b35fe5..383506158 100644
--- a/package/lean/luci-app-wrtbwmon/Makefile
+++ b/package/lean/luci-app-wrtbwmon/Makefile
@@ -14,4 +14,3 @@ PKG_RELEASE:=7
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
diff --git a/package/lean/luci-app-wrtbwmon/luasrc/model/cbi/wrtbwmon/config.lua b/package/lean/luci-app-wrtbwmon/luasrc/model/cbi/wrtbwmon/config.lua
index 469d4f8f2..79440ae3c 100644
--- a/package/lean/luci-app-wrtbwmon/luasrc/model/cbi/wrtbwmon/config.lua
+++ b/package/lean/luci-app-wrtbwmon/luasrc/model/cbi/wrtbwmon/config.lua
@@ -1,9 +1,10 @@
-local m = Map("wrtbwmon", translate("Details"))
+m = Map("wrtbwmon")
+m.title = translate("Details")
-local s = m:section(NamedSection, "general", "wrtbwmon", translate("General settings"))
+s = m:section(NamedSection, "general", "wrtbwmon", translate("General settings"))
-local o = s:option(Flag, "persist", translate("Persist database"),
- translate("Check this to persist the database file"))
+o = s:option(Flag, "persist", translate("Persist database"))
+o.description = translate("Check this to persist the database file")
o.rmempty = false
function o.write(self, section, value)
diff --git a/package/lean/luci-app-zerotier/Makefile b/package/lean/luci-app-zerotier/Makefile
index 0b71fb662..80fa08c2a 100644
--- a/package/lean/luci-app-zerotier/Makefile
+++ b/package/lean/luci-app-zerotier/Makefile
@@ -15,5 +15,3 @@ PKG_RELEASE:=20
include $(TOPDIR)/feeds/luci/luci.mk
# call BuildPackage - OpenWrt buildroot signature
-
-
diff --git a/package/lean/luci-app-zerotier/luasrc/controller/zerotier.lua b/package/lean/luci-app-zerotier/luasrc/controller/zerotier.lua
index 3ff3eb208..9c69c063e 100644
--- a/package/lean/luci-app-zerotier/luasrc/controller/zerotier.lua
+++ b/package/lean/luci-app-zerotier/luasrc/controller/zerotier.lua
@@ -16,8 +16,8 @@ function index()
end
function act_status()
- local e={}
- e.running=luci.sys.call("pgrep /usr/bin/zerotier-one >/dev/null")==0
+ local e = {}
+ e.running = luci.sys.call("pgrep /usr/bin/zerotier-one >/dev/null") == 0
luci.http.prepare_content("application/json")
luci.http.write_json(e)
end
diff --git a/package/lean/luci-app-zerotier/luasrc/model/cbi/zerotier/settings.lua b/package/lean/luci-app-zerotier/luasrc/model/cbi/zerotier/settings.lua
index 14f4bdce0..32ef1bbfc 100644
--- a/package/lean/luci-app-zerotier/luasrc/model/cbi/zerotier/settings.lua
+++ b/package/lean/luci-app-zerotier/luasrc/model/cbi/zerotier/settings.lua
@@ -1,26 +1,27 @@
+a = Map("zerotier")
+a.title = translate("ZeroTier")
+a.description = translate("Zerotier is an open source, cross-platform and easy to use virtual LAN")
-a=Map("zerotier",translate("ZeroTier"),translate("Zerotier is an open source, cross-platform and easy to use virtual LAN"))
-a:section(SimpleSection).template = "zerotier/zerotier_status"
+a:section(SimpleSection).template = "zerotier/zerotier_status"
-t=a:section(NamedSection,"sample_config","zerotier")
-t.anonymous=true
-t.addremove=false
+t = a:section(NamedSection, "sample_config", "zerotier")
+t.anonymous = true
+t.addremove = false
-e=t:option(Flag,"enabled",translate("Enable"))
-e.default=0
+e = t:option(Flag, "enabled", translate("Enable"))
+e.default = 0
e.rmempty=false
-e=t:option(DynamicList,"join",translate('ZeroTier Network ID'))
-e.password=true
-e.rmempty=false
+e = t:option(DynamicList, "join", translate('ZeroTier Network ID'))
+e.password = true
+e.rmempty = false
-e=t:option(Flag,"nat",translate("Auto NAT Clients"))
-e.default=0
-e.rmempty=false
+e = t:option(Flag, "nat", translate("Auto NAT Clients"))
e.description = translate("Allow zerotier clients access your LAN network")
+e.default = 0
+e.rmempty = false
-e=t:option(DummyValue,"opennewwindow" ,
- translate(""))
+e = t:option(DummyValue, "opennewwindow", translate(""))
e.description = translate("Create or manage your zerotier network, and auth clients who could access")
return a
diff --git a/package/lean/luci-theme-argon/root/etc/uci-defaults/30_luci-theme-argon b/package/lean/luci-theme-argon/root/etc/uci-defaults/30_luci-theme-argon
old mode 100644
new mode 100755
diff --git a/package/lean/luci-theme-netgear/luasrc/view/themes/netgear/footer.htm b/package/lean/luci-theme-netgear/luasrc/view/themes/netgear/footer.htm
old mode 100755
new mode 100644
diff --git a/package/lean/luci-theme-netgear/luasrc/view/themes/netgear/header.htm b/package/lean/luci-theme-netgear/luasrc/view/themes/netgear/header.htm
old mode 100755
new mode 100644
diff --git a/package/lean/n2n_v2/files/n2n_v2.init b/package/lean/n2n_v2/files/n2n_v2.init
old mode 100644
new mode 100755
diff --git a/package/lean/ntfs3-mount/files/mount.ntfs3 b/package/lean/ntfs3-mount/files/mount.ntfs3
old mode 100644
new mode 100755
diff --git a/package/lean/openwrt-fullconenat/files/Makefile b/package/lean/openwrt-fullconenat/files/Makefile
index da52a2a4e..b2f88db33 100644
--- a/package/lean/openwrt-fullconenat/files/Makefile
+++ b/package/lean/openwrt-fullconenat/files/Makefile
@@ -4,4 +4,3 @@ libipt_FULLCONENAT.o: libipt_FULLCONENAT.c
$(CC) ${CFLAGS} -fPIC -D_INIT=$*_init -c -o $@ $<;
obj-m += xt_FULLCONENAT.o
-
diff --git a/package/lean/pdnsd-alt/files/pdnsd.init b/package/lean/pdnsd-alt/files/pdnsd.init
old mode 100644
new mode 100755
diff --git a/package/lean/ps3netsrv/files/ps3netsrv.init b/package/lean/ps3netsrv/files/ps3netsrv.init
old mode 100644
new mode 100755
diff --git a/package/lean/shortcut-fe/shortcut-fe/files/usr/bin/sfe_dump b/package/lean/shortcut-fe/shortcut-fe/files/usr/bin/sfe_dump
old mode 100644
new mode 100755
diff --git a/package/lean/srelay/files/srelay.init b/package/lean/srelay/files/srelay.init
old mode 100644
new mode 100755
diff --git a/package/lean/tcpping/Makefile b/package/lean/tcpping/Makefile
index 72e79e5b1..77cfc864e 100644
--- a/package/lean/tcpping/Makefile
+++ b/package/lean/tcpping/Makefile
@@ -1,38 +1,38 @@
-include $(TOPDIR)/rules.mk
-
-PKG_NAME:=tcpping
-PKG_VERSION:=0.2
-PKG_RELEASE=$(PKG_SOURCE_VERSION)
-
-PKG_SOURCE_PROTO:=git
-PKG_SOURCE_URL:=https://github.com/coolsnowwolf/tcping
-PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
-PKG_SOURCE_VERSION:=d890cc1bd8e3951390ceeff1ccb092a5d802850c
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/tcpping
- SECTION:=net
- CATEGORY:=Network
- DEPENDS:=+libnet-1.2.x
- TITLE:=Ping look-alike that uses TCP SYN packets to get around firewalls and ICMP blackholes
-endef
-
-define Package/tcpping/description
-Ping look-alike that uses TCP SYN packets to get around firewalls and ICMP blackholes
-endef
-
-define Build/Compile
- $(MAKE) -C $(PKG_BUILD_DIR) \
- $(TARGET_CONFIGURE_OPTS) \
- CFLAGS="$(TARGET_CFLAGS) -I$(STAGING_DIR)/usr/lib/libnet-1.2.x/include -L$(STAGING_DIR)/usr/lib/libnet-1.2.x/lib" \
- INSTALL_PROG=":"
-endef
-
-define Package/tcpping/install
- $(INSTALL_DIR) $(1)/usr/bin
- $(INSTALL_BIN) $(PKG_BUILD_DIR)/tcpping $(1)/usr/bin/tcpping
-endef
-
-$(eval $(call BuildPackage,tcpping))
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=tcpping
+PKG_VERSION:=0.2
+PKG_RELEASE=$(PKG_SOURCE_VERSION)
+
+PKG_SOURCE_PROTO:=git
+PKG_SOURCE_URL:=https://github.com/coolsnowwolf/tcping
+PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
+PKG_SOURCE_VERSION:=d890cc1bd8e3951390ceeff1ccb092a5d802850c
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
+
+include $(INCLUDE_DIR)/package.mk
+
+define Package/tcpping
+ SECTION:=net
+ CATEGORY:=Network
+ DEPENDS:=+libnet-1.2.x
+ TITLE:=Ping look-alike that uses TCP SYN packets to get around firewalls and ICMP blackholes
+endef
+
+define Package/tcpping/description
+Ping look-alike that uses TCP SYN packets to get around firewalls and ICMP blackholes
+endef
+
+define Build/Compile
+ $(MAKE) -C $(PKG_BUILD_DIR) \
+ $(TARGET_CONFIGURE_OPTS) \
+ CFLAGS="$(TARGET_CFLAGS) -I$(STAGING_DIR)/usr/lib/libnet-1.2.x/include -L$(STAGING_DIR)/usr/lib/libnet-1.2.x/lib" \
+ INSTALL_PROG=":"
+endef
+
+define Package/tcpping/install
+ $(INSTALL_DIR) $(1)/usr/bin
+ $(INSTALL_BIN) $(PKG_BUILD_DIR)/tcpping $(1)/usr/bin/tcpping
+endef
+
+$(eval $(call BuildPackage,tcpping))
diff --git a/package/lean/vlmcsd/files/vlmcsd.init b/package/lean/vlmcsd/files/vlmcsd.init
old mode 100644
new mode 100755
diff --git a/package/lean/vsftpd-alt/files/vsftpd-uci.init b/package/lean/vsftpd-alt/files/vsftpd-uci.init
old mode 100644
new mode 100755
diff --git a/package/lean/vsftpd-alt/files/vsftpd.init b/package/lean/vsftpd-alt/files/vsftpd.init
old mode 100644
new mode 100755