mirror of
https://github.com/sirpdboy/sirpdboy-package.git
synced 2025-01-08 11:57:57 +08:00
up autotimeset 2.0.2
This commit is contained in:
parent
2731c504c8
commit
7bbc4d0cee
@ -9,7 +9,7 @@ LUCI_TITLE:=LuCI support for Scheduled Time setting
|
||||
LUCI_PKGARCH:=all
|
||||
|
||||
PKG_VERSION:=2.0.2
|
||||
PKG_RELEASE:=20230715
|
||||
PKG_RELEASE:=20230718
|
||||
|
||||
|
||||
define Package/$(PKG_NAME)/conffiles
|
||||
|
@ -27,7 +27,7 @@ msgid "Startup task"
|
||||
msgstr "开机启动任务"
|
||||
|
||||
msgid "Startup delay time"
|
||||
msgstr "延迟时间【开机任务用】"
|
||||
msgstr "延迟时间【开机用】"
|
||||
|
||||
msgid "Log"
|
||||
msgstr "日志"
|
||||
@ -75,17 +75,17 @@ msgid "Only by editing the content of the custom script well and scheduling the
|
||||
msgstr "编辑好自定义脚本内容,自定义脚本任务才能有效执行。"
|
||||
|
||||
msgid "Month(0~11)"
|
||||
msgstr "月份(0~11)【定时任务用】"
|
||||
msgstr "月份(0~11)【定时用】"
|
||||
|
||||
msgid "Week Day(0~6)"
|
||||
msgstr "星期(0~6)【定时任务用】"
|
||||
msgstr "星期(0~6)【定时用】"
|
||||
|
||||
msgid "Everyday"
|
||||
msgstr "每天【定时任务用】"
|
||||
msgstr "每天【定时用】"
|
||||
|
||||
msgid "Hour(0~23)"
|
||||
msgstr "小时(0~23)【定时任务用】"
|
||||
msgstr "小时(0~23)【定时用】"
|
||||
|
||||
msgid "Minute(0~59)"
|
||||
msgstr "分钟(0~59)【定时任务用】"
|
||||
msgstr "分钟(0~59)【定时用】"
|
||||
|
||||
|
@ -16,7 +16,7 @@ customscript=$(uci -q get autotimeset.@global[0].customscript ) || customscript
|
||||
script=`echo $customscript | grep '#!/bin/sh'` >/dev/null 2>&1
|
||||
[ $script ] && echo $script > /etc/autotimeset/timesetcustomscript || {
|
||||
echo '#!/bin/sh' >/etc/autotimeset/timesetcustomscript
|
||||
echo $script >>/etc/autotimeset/timesetcustomscript
|
||||
echo $customscript >>/etc/autotimeset/timesetcustomscript
|
||||
}
|
||||
echo 'start(){' >>$TT
|
||||
for i in $(seq 0 $((ssum-1)))
|
||||
|
@ -75,14 +75,10 @@ trigger() {
|
||||
sysfree)
|
||||
cd /overlay
|
||||
rm -rf `ls | egrep -v '(upper|.fs_state)'`
|
||||
cd /overlay/upper
|
||||
rm -rf `ls | egrep -v '(etc|usr)'`
|
||||
cd /overlay/upper/usr
|
||||
rm -rf `ls | egrep -v '(share)'`
|
||||
cd /overlay/upper/usr/share
|
||||
rm -rf `ls | egrep -v '(unblockneteasemusic|passwall|AdGuardHome|openclash|softethervpn|bypass|)'`
|
||||
cd /overlay/upper/etc
|
||||
rm -rf `ls | egrep -v '(config|init.d|uci-defaults|hotplug.d|nginx|rc.d|ppp|smartdns|ssrplus|bench.log|shadow|openclash|firewall.user)'`
|
||||
cd upper
|
||||
rm -rf `ls | egrep -v '(etc)'`
|
||||
cd etc
|
||||
rm -rf `ls | egrep -v '(config|ssr|bench.log|shadow)'`
|
||||
rm -rf /var/luci-modulecache
|
||||
rm -rf /var/luci-indexcache
|
||||
rm -rf /tmp/cache/*
|
||||
@ -115,16 +111,11 @@ trigger() {
|
||||
fi
|
||||
;;
|
||||
restartmwan3)
|
||||
remwan3
|
||||
[ -s /usr/sbin/mwan3 ] && remwan3
|
||||
;;
|
||||
customscript)
|
||||
script=`cat /etc/autotimeset/timesetcustomscript | grep '#!/bin/sh'` >/dev/null 2>&1
|
||||
[ $script ] || {
|
||||
script=` cat /etc/autotimeset/timesetcustomscript `
|
||||
echo '#!/bin/sh' >/etc/autotimeset/timesetcustomscript
|
||||
echo $script >>/etc/autotimeset/timesetcustomscript
|
||||
}
|
||||
source /etc/autotimeset/timesetcustomscript
|
||||
script=`cat /etc/autotimeset/timesetcustomscript ` >/dev/null 2>&1
|
||||
[ $script ] && source /etc/autotimeset/timesetcustomscript
|
||||
log "CustomScript succeeded!"
|
||||
;;
|
||||
esac
|
||||
|
Loading…
Reference in New Issue
Block a user