From 9da98ac9fda6dc3b92d379d4cda09dcdee4b72ea Mon Sep 17 00:00:00 2001 From: Patrick-Ze <19711799+Patrick-Ze@users.noreply.github.com> Date: Wed, 24 Sep 2025 22:18:54 +0800 Subject: [PATCH] =?UTF-8?q?js:=20CD-Aware-AutoGather:=20=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=E8=B7=A8=E5=A4=A9=E8=BF=90=E8=A1=8C=E6=97=B6logFakeScriptEnd?= =?UTF-8?q?=E5=8F=AF=E8=83=BD=E5=BD=B1=E5=93=8D=E6=97=A5=E5=BF=97=E8=A7=A3?= =?UTF-8?q?=E6=9E=90=E7=9A=84=E9=97=AE=E9=A2=98=20(#1989)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- build/author_config.json | 5 ++--- repo/js/CD-Aware-AutoGather/lib/lib.js | 8 ++++++-- repo/js/CD-Aware-AutoGather/manifest.json | 4 ++-- repo/js/CD-Aware-AutoGather/settings.json | 2 +- 4 files changed, 11 insertions(+), 8 deletions(-) diff --git a/build/author_config.json b/build/author_config.json index 4e9463281..e720a90c2 100644 --- a/build/author_config.json +++ b/build/author_config.json @@ -1,6 +1,7 @@ { "rename": { "起个名字好难": "起个名字好难的喵", + "Patrick-Ze (AyakaMain)": "Ayaka-Main", "this-Fish": "蜜柑魚" }, "links": { @@ -21,9 +22,7 @@ "柒叶子": "https://github.com/5117600049", "不瘦五十斤不改名": "https://github.com/PanZic", "½": "https://github.com/Traveler07", - "Patrick-Ze (AyakaMain)": "https://github.com/Patrick-Ze", - "AyakaMain": "https://github.com/Patrick-Ze", - "Patrick-Ze": "https://github.com/Patrick-Ze", + "Ayaka-Main": "https://github.com/Patrick-Ze", "风埠": "https://github.com/jhkif", "jbcaaa": "https://github.com/jbcaaa", "johsang": "https://github.com/johsang", diff --git a/repo/js/CD-Aware-AutoGather/lib/lib.js b/repo/js/CD-Aware-AutoGather/lib/lib.js index 97816f7a3..873a0ae24 100644 --- a/repo/js/CD-Aware-AutoGather/lib/lib.js +++ b/repo/js/CD-Aware-AutoGather/lib/lib.js @@ -7,7 +7,7 @@ let scriptContext = { scriptStartTime: new Date(), - version: "1.1", + version: "1.2", }; /** @@ -504,7 +504,11 @@ function _fakeLogCore(name, isJs = true, dateIn = null) { let logMessage = ""; let logTime = new Date(); if (isJs && isStart) { - logTime = dateIn; + // 传入开始时间是为了在跟踪路径耗时的同时仍然保留对脚本运行时间的统计 + // 但是如果脚本开始时间和结束时间跨天,就不能使用传入时间,否则会影响日志分析(Seconds cannot be negative) + if (logTime.getDay() === dateIn.getDay()) { + logTime = dateIn; + } } const ms = logTime.getMilliseconds().toString().padStart(3, "0"); diff --git a/repo/js/CD-Aware-AutoGather/manifest.json b/repo/js/CD-Aware-AutoGather/manifest.json index 2b68fb53c..e7bba7ae5 100644 --- a/repo/js/CD-Aware-AutoGather/manifest.json +++ b/repo/js/CD-Aware-AutoGather/manifest.json @@ -1,7 +1,7 @@ { "manifest_version": 1, - "name": "带CD管理的自动采", - "version": "1.7.5", + "name": "带CD管理的自动采集", + "version": "1.7.6", "bgi_version": "0.45.0", "description": "自动同步你通过BetterGI订阅的地图追踪任务,执行采集任务,并管理材料刷新时间(支持多账号)。\n首次使用前请先简单阅读说明(可在`全自动`——`JS脚本`页面,点击本脚本名称查看)", "authors": [ diff --git a/repo/js/CD-Aware-AutoGather/settings.json b/repo/js/CD-Aware-AutoGather/settings.json index e6f27169c..e32d58edb 100644 --- a/repo/js/CD-Aware-AutoGather/settings.json +++ b/repo/js/CD-Aware-AutoGather/settings.json @@ -37,7 +37,7 @@ { "name": "iHaveMultipleAccounts", "type": "input-text", - "label": "我肝的账号不止一个\n根据唯一ID区分账号维护对应的材料刷新时间\n填空将使用右下角帐号UID区分账号维护对应的材料刷新时间", + "label": "我肝的账号不止一个\n根据唯一ID区分账号维护对应的材料刷新时间\n留空时将使用右下角UID", "default": "默认账号" }, {