()
| 292 | await fs.unlink(EXIT_MSG_FILE_PATH); |
| 293 | } catch (error) { |
| 294 | // 文件不存在时忽略错误 |
| 295 | if (error.code !== 'ENOENT') { |
| 296 | console.error("[autodelcmd] 清除退出消息文件失败:", error); |
| 297 | } |
| 298 | } |
| 299 | } |
| 300 | |
| 301 | private async autoDeleteOnStartup() { |
| 302 | const exitMsgs = await this.loadExitMessages(); |
| 303 | |
| 304 | if (exitMsgs.length === 0) { |
| 305 | console.log(`[autodelcmd] 没有未完成的删除任务`); |
| 306 | return; |
no test coverage detected