mirror of
https://github.com/binaricat/Netcatty.git
synced 2026-11-17 04:50:52 +00:00
* feat(settings): 支持一键清空所有会话日志 在系统设置的会话日志卡片中新增清空按钮,删除保存目录下的 所有日志文件及主机子目录;操作前弹窗二次确认,完成后展示 删除/失败数量。 Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> * fix(session-logs): restrict clear-all to known log artifacts Clearing the session logs directory no longer recursively deletes every top-level entry. Only files matching Netcatty auto-save / export naming patterns and host folders that exclusively contain those artifacts are removed, so a shared Documents/Downloads save path cannot wipe unrelated user files (Codex P1 on #2738). * fix(session-logs): skip active auto-save streams during clear-all Clear-all must not rm host dirs or log files still open by sessionLogStreamManager write streams (orphan inode / silent stop). Expose getActiveLogPaths and preserve those targets while still deleting inactive siblings and pure host folders. * fix(session-logs): preserve active snapshot-only host dirs on clear-all txt/html streams may not create a file until the first snapshot, so treat any active log path whose parent is the host directory as live work before removing pure session-log folders. * fix(session-logs): preserve worker-owned active streams on clear-all Clear-all only queried the main-process sessionLogStreamManager, so worker-owned auto-save files were invisible and could be deleted while live. Union active paths from a running terminal worker via netcatty:sessionLogs:getActivePaths, and skip cold-starting a stopped worker. --------- Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com> Co-authored-by: bincxz <16399091+binaricat@users.noreply.github.com>