Repository navigation
feat(desktop): 设置新增“关于”页,更新改为 Motty 式检查与一键更新,版本区分正式版与预览版 - #1900
Merged
Merged
Conversation
- 设置侧栏在 AI 之后新增一级页面“关于”:图标、名称、简介和复制按钮;版本信息 (版本、平台、构建、运行时);与更新页共用的更新卡片;加入交流(QQ 群、微信群 飞书页);项目(源码仓库、Issue)。不再显示 Core C ABI 版本。 - 更新参照 Motty:启动 5 秒后第一次检查,之后每小时一次;窗口在后台时推迟到回到 前台再补;同一版本只通知一次;“立即检查”与一键“更新”(下载、校验、安装、重启), 下载中可取消。项目标签页共用一份更新状态。 - 版本号来自 desktop/viva.toml。只有 Desktop Release 为 desktop-v<版本> 标签的提交 打包时传 package-desktop.sh --stable(lithe_stable 构建标签),应用内显示纯版本号; 其余构建显示“<版本> 预览版”。package-release.sh 校验标签在 HEAD 上且每个打包程序 都带 lithe_stable。 - 修复关于页在纯文字上挂 Tooltip 导致的崩溃。 - 设置窗口的失败带上真实操作名写日志(settings_about_copy、keymap_schemes、 editor_preferences、plugin_settings_surface),不再全部记成 plugin_settings_surface; 打开链接失败记 settings_open_link 并提示用户。 - 修复 TestProjectTreeCreatesRenamesAndDeletes 在高负载下偶发找不到“永久删除”: 打开对话框后请求重绘,并有界等待按钮出现再点击。 - 补关于页、更新器和欢迎页版本标识的测试,日志目录测试覆盖新增事件;更新设置分类 Note、发布 Skill、迁移文档和功能矩阵。
xiaoyumuxi
marked this pull request as ready for review
November 14, 2026 05:51
This was referenced Nov 14, 2026
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
关联 Issue / Linked issue
PR 类型 / Type
改动说明 / What changes
背景 / Why
Viva 设置里没有“关于”页(#1620),用户看不到自己用的是哪个版本、怎样更新、去哪里交流。原来的更新只在启动时每天检查一次、只提示,要到更新页手动下载安装。欢迎页和设置里显示的“Core 0.1.0”其实是 Core C ABI 的版本,不是应用版本,会误导用户;而且没有任何地方能区分正式版和预览版。
做法参照 Motty:新增一级“关于”页;更新改为启动后不久检查、之后每小时检查,一键“更新”;版本统一显示为
desktop/viva.toml里的应用版本(0.7.0),只有 Desktop Release 用desktop-v<版本>标签构建的包显示纯版本号,其余构建都显示“0.7.0 预览版”。改动 / Changes
关于页(
desktop/internal/settingswindow)model.go:新增一级页面pageAbout,固定在侧栏 AI 之后,面包屑只有“关于”一级;palette.go给它配了青色的 Info 图标。about_view.go(新):settings_about_copy记日志。vcs.revision/vcs.time;没有记录时页面显示“未记录”,复制内容省略这一行);运行时(Go 版本)。updates_view.go:Options.SettingsError由func(error)改为func(operation string, err error)。以前快捷键方案、编辑器偏好、关于页复制的失败都被记成plugin_settings_surface,现在分别记keymap_schemes、editor_preferences、settings_about_copy;插件设置仍记plugin_settings_surface。更新(
desktop/internal/workbench/updates.go)window_sessions.go在激活时调用resumeUpdateCheck),空闲的 Lithe 不会每小时为没人看的窗口读 feed。update_check;用户点“立即检查”时才显示原因。Lithe/Updates/<版本>。appupdate。*updater:app.go里新标签复用first.updates。saveSettings写入updater.store,所以无论哪个标签保存,写下的都是窗口的“自动检查”开关和上次检查时间。窗口关闭时stopUpdates撤销定时器并停止下载。update_check、update。updates.check、updates.update、updates.cancel。版本标识(正式版 / 预览版)
desktop/internal/buildinfo:新增Stable,由lithe_stable构建标签决定(stable.go/preview.go)。scripts/desktop/package-desktop.sh:新增--stable,打包时加上lithe_stable标签。scripts/ci/desktop-release/package-release.sh:--stable,macOS、Windows、Linux 都传。desktop-v<版本>标签就在 HEAD 上。go version -m确认带有lithe_stable,没有就失败。welcome_view.go)、关于页、更新页和复制内容按同一规则显示版本:正式版显示“0.7.0”,其余(desktop-AutoBuild、本地打包、go run)显示“0.7.0 预览版”。Kernel.Version(),不再显示 Core C ABI 版本“0.1.0”。其他
settings.go:新增openSettingsLink,关于页的链接都从这里打开。打开失败时通知用户并记日志settings_open_link,成功记用户操作settings.openLink。generate-desktop-icons.sh里加入 lucide 的 github、monitor、external-link、message-circle、messages-square,并重新生成icons.go。shared/i18n/,生成文件已重新生成。i18n.App.Version(version, stable)统一拼出版本文字。TestProjectTreeCreatesRenamesAndDeletes(feat(desktop): 右键删除改为弹窗选择移到废纸篓或永久删除,复制路径收进二级菜单 #1894 引入):高负载下打开删除对话框后没有请求重绘,测试点击时那一帧里还没有“永久删除”按钮。现在先请求重绘,并有界等待按钮出现再点击。--stable。docs/viva-migration.md的发布工作流一行同步更新。settings-about-page.json,更新updates-check-download.json。不在本 PR 范围内 / Out of scope
buildinfo/update.go链接时注入),所以发行包目前仍不会检查更新;这部分沿用原状,本 PR 不改。类型专属:feat
多平台对齐
package-release.sh三个平台都传--stable。Windows 只有无头测试覆盖,未在实机验证(见“验证”)。范围检查 / Scope checks
功能矩阵 / Feature matrix
shared/platform-feature-matrix/features/<id>.json:新增settings-about-page,两端implemented/pending(无实机验收);updates-check-download补证据路径、自动化测试说明和新行为,验证状态保持不变./scripts/platform-feature-matrix/verify-platform-feature-matrix.sh和./scripts/platform-feature-matrix/verify-platform-feature-matrix-change.sh origin/preview HEAD.artifacts/下生成的矩阵视图统一日志系统 / Structured logging
app.operation.failed与app.action.performed,通过a.emit/a.performed记录,没有手写事件 ID、直接写 stderr 或print。新增的操作名和用户操作都加进了TestLogEventsMatchCatalog,由测试按 Core 目录校验:update_check、update、settings_about_copy、settings_open_link、editor_preferences、keymap_schemes、plugin_settings_surface,以及updates.check、updates.update、updates.cancel、settings.openLinkerror类型node scripts/logging/generate-log-events.mjs --check、node scripts/logging/verify-log-usage.mjs:两个脚本已随 Epic(0.7.0): 基于 Viva 框架的跨平台方案的迁移(#1794) #1799 删除,恢复由 [Feature] 恢复 Viva 日志事件类型生成和目录使用门禁 #1802 跟进;改为由TestLogEventsMatchCatalog校验界面文案 / i18n
shared/i18n/,已运行node scripts/i18n/generate-i18n.mjs并提交生成结果,没有手改生成文件node scripts/i18n/verify-app-language-localization.mjs和node scripts/i18n/generate-i18n.mjs --check,没有放宽脚本或扩大豁免名单逻辑归属 / Logic placement
appupdate。性能与内存 / Performance and memory
post回到窗口线程。每次检查后保存设置时,沿用原有saveSettings在窗口线程写设置文件(改动前的更新器就是这样,每小时最多一次);设置持久化的所有权由 [Feature] 统一 Viva 应用偏好所有权与多窗口发布,避免独立快照继续使用或覆盖旧设置 #1851 处理设置 / Settings
插件契约 / Plugin contract
N/A:不涉及插件契约、能力版本、插件函数协议或宿主方法。
发行包与资源 / Bundle and resources
Lithe/Updates/<版本>(os.UserCacheDir),生命周期为下载到安装,属于更新器;已运行./scripts/desktop/verify/verify-runtime-bundle-immutability.sh无用代码与重构 / Dead code and refactoring
Kernel.Version()及 Core ABI 版本显示、旧的“每天检查一次”逻辑TestProjectTreeCreatesRenamesAndDeletes;设置窗口的失败全部记成plugin_settings_surface。验证 / Verification
scripts/desktop/desktop-go.sh test -count=1 ./internal/settingswindow ./internal/buildinfo ./internal/i18nscripts/desktop/desktop-go.sh test -count=1 ./internal/workbenchscripts/desktop/desktop-go.sh test ./...(在设置失败操作名改动之前的版本上;之后 settingswindow 与 workbench 已重跑)scripts/desktop/desktop-go.sh test -race -count=1 ./internal/settingswindow ./internal/workbench -run 'TestAbout|TestUpdatesPageNames|TestUpdateLineSays|TestWelcomeTitleAndVersion|TestAutomaticUpdateCheck|TestUpdateCheckFailure|TestCancelledUpdateDownload|TestTurningOffTheAutomaticCheck|TestLogEventsMatchCatalog'scripts/desktop/desktop-go.sh vet ./internal/settingswindow ./internal/workbench ./internal/buildinfo(默认,以及-tags lithe_stable)node scripts/i18n/generate-i18n.mjs --check、node scripts/i18n/verify-app-language-localization.mjs./scripts/platform-feature-matrix/verify-platform-feature-matrix.sh、verify-platform-feature-matrix-change.sh origin/preview HEAD./scripts/agent-notes/verify-agent-notes.sh./scripts/desktop/verify/verify-runtime-bundle-immutability.sh.agents/skills/write-stable-tests/scripts/verify-test-stability.sh --base origin/previewtest-stability-macos.sh:workbenchTestProjectTreeCreatesRenamesAndDeletes|TestLogEventsMatchCatalog,settingswindowTestAbout|TestUpdatesPageNames|TestUpdateLineSaysvisual_capture_test生成36-settings-about中英文、浅色与深色无头截图未能执行的检查和原因:
--stable和is_stable_program校验没有在 CI 实跑。提交前确认 / Final checks
preview创建;目标分支:preview.build/、target/、dist/、.artifacts/等产物,没有凭据、个人路径和未脱敏的日志或截图