Merge Lean's source

This commit is contained in:
CN_SZTL 2020-02-17 00:00:47 +08:00
commit a9757c83ac
No known key found for this signature in database
GPG Key ID: 6850B6345C862176
4 changed files with 6 additions and 15 deletions

View File

@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=autocore
PKG_VERSION:=1
PKG_RELEASE:=28
PKG_RELEASE:=29
include $(INCLUDE_DIR)/package.mk

View File

@ -52,13 +52,7 @@
local user_info = tonumber(luci.sys.exec("cat /proc/net/arp | grep '0x2' | wc -l")) or 0
local cpu_usage
if fs.readfile("/tmp/cpuusage") then
cpu_usage = luci.sys.exec("cat /tmp/cpuusage")
else
cpu_usage = "6.6%"
end
local cpu_usage = fs.readfile("/tmp/cpuusage") or "6.6%"
luci.sys.exec("/sbin/getcpu &")

View File

@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=autosamba
PKG_VERSION:=1
PKG_RELEASE:=10
PKG_RELEASE:=11
PKG_ARCH:=all
include $(INCLUDE_DIR)/package.mk
@ -17,7 +17,7 @@ include $(INCLUDE_DIR)/package.mk
define Package/autosamba
TITLE:=Samba autoconfig hotplug script.
MAINTAINER:=Lean
DEPENDS:=+luci-app-samba
DEPENDS:=+luci-app-samba +wsdd2
endef
define Package/autosamba/description

View File

@ -5,11 +5,8 @@ START=99
start()
{
a=$(cat /tmp/sysinfo/model)
a=$(awk 'BEGIN{FS="[ \t]+:[ \t]"} /machine/ {print $2}' /proc/cpuinfo)
b=$(dmesg | awk -F 'CPU:|MHz' '/Clocks:/{print $2+0}')
c=${a}" CPU:"${b}Mhz
c=${a}" CPU "${b}Mhz
echo -n $c > /tmp/sysinfo/model
}