CodeWhale icon indicating copy to clipboard operation
CodeWhale copied to clipboard

建议:自动更新通知 + Release 正文包含 changelog + README 补全 update 文档

Open windcat2333 opened this issue 6 months ago • 1 comments

建议概述

提三个相互关联的建议,目的是让用户更容易感知和获取新版本。


1. README 补全 deepseek update 命令文档

deepseek update 命令已在 crates/cli/src/update.rs 中完整实现(拉取最新 Release、SHA256 校验、Windows-safe 原子替换),但在 README 的命令列表中未被列出。用户不知道这个命令的存在。

建议在 README 命令列表中加入一行:

deepseek update check for and apply updates to the deepseek binary

2. 启动时自动检查更新(非阻塞通知)

当前用户需要主动执行 deepseek update 才能发现新版本。建议在 TUI 启动时异步检查 GitHub Releases 的最新版本,有新版本时在界面中提示。

大致思路:

  • 启动后在后台线程请求 GitHub API 获取 latest release
  • 将当前版本与最新 tag 比较
  • 有新版本时非阻塞提示,例如状态栏信息或欢迎界面一行提示
  • 本地记录上次检查时间,避免每次启动都请求 API

已有 update.rs 中的 Release 解析逻辑可以复用。

3. Release 正文直接包含 changelog 内容

当前每个 Release 正文只有安装说明 + 指向 CHANGELOG.md 的链接。建议发布时将 CHANGELOG.md 对应版本的内容直接粘贴到 Release 正文中。

同时存在版本已 bump 但 CHANGELOG.md 未同步更新的情况(如 v0.8.14 已发布但 CHANGELOG.md 尚无 [0.8.14] 条目)。建议在发版流程中增加一个检查步骤,确保版本 bump 前 CHANGELOG.md 已更新对齐。

涉及文件

  • README.md
  • crates/cli/src/update.rs
  • crates/tui/src/
  • docs/RELEASE_RUNBOOK.md

windcat2333 avatar May 06 '26 04:05 windcat2333

hi i think your proposal is very usefull , regarding your proposal , i push a PR as a solution , please check https://github.com/Hmbown/DeepSeek-TUI/pull/838.

the main workflow as following: TUI Startup └─ Spawn a background Tokio task └─ Check the local cache (~/.deepseek/update_check.json) ├─ If it's less than 24 hours since the last check → Skip └─ Expired → GET https://api.github.com/repos/Hmbown/DeepSeek-TUI/releases/latest ├─ If the latest version is greater than the current version → Send an Event to the TUI status bar to display a prompt └─ Write the cache timestamp

mac119 avatar May 06 '26 08:05 mac119