diff --git a/利用Github Actions自动同步Fork.md b/利用Github Actions自动同步Fork.md index 306e92b..fe4607f 100644 --- a/利用Github Actions自动同步Fork.md +++ b/利用Github Actions自动同步Fork.md @@ -94,6 +94,15 @@ base: 本地仓库 branch 第七个位置:Year 年:区间1970-2099,代表具体年份,但是一般不用,可以直接不写。(为什么到了2099年就停了?) +补充:cron表达式 +例1:@scheduled (cron="0 0 2 2 * ? *") 表示:每月二号凌晨两点执行。 + +例2:@scheduled (cron="15,20,40 15-20 2/5 L * ?") 表示:每月的最后一天的凌晨2点开始每隔5小时的第15分钟到第20分钟之间的每分钟的第15,20,40秒执行一次。 + +例3:@scheduled (cron="0 0 0 15W * ?") 表示:每月离15号最近的工作日。 + +例4:@scheduled (cron= "0 0 0 0 * 2#3 ") 表示:每月的第三个周一。 + 下面是网上找的表格,方便记忆 ![QQ图片20230918160242](https://github.com/dlgt7/TVbox-interface/assets/102397160/a0929c25-19ef-4b77-8480-a8f516491454)