Skip to content

Doubao-powered voice input for Linux, Wayland and Omarchy

fix(macos): 精简更新页面为单一状态操作

quanru332b5b4f1070
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 05fc7b0..913a462 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -8,6 +8,10 @@
- macOS: expose English, Simplified Chinese and system language selection in General settings with immediate switching and persistent preferences.
+## 1.5.1
+
+- Simplify the Mac update page to one state-dependent action, show release notes as a text link, and prevent repeated checks while a request is active.
+
## 1.5.0
- Add personal vocabulary for contextual polishing, a local rolling 30-day input ledger, reviewed AI frequency suggestions, and padded recent-text editors on macOS and Linux.
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 7ac3516..7cd0832 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -79,9 +79,9 @@ For marketplace preparation, use `make marketplace-check` with Gitleaks on PATH
and follow [the publishing checklist](packaging/MARKETPLACE.md). Reports and local
review drafts belong in ignored `artifacts/` and `docs/`, not in release payloads.
-The current public version is `1.5.0`. Keep `pyproject.toml`, `manifest.json` and
+The current public version is `1.5.1`. Keep `pyproject.toml`, `manifest.json` and
`src/doubao_input/product.py` aligned; `python packaging/version_check.py` verifies
-them. A pushed tag such as `v1.5.0` runs all checks and secret scanning, builds app
+them. A pushed tag such as `v1.5.1` runs all checks and secret scanning, builds app
and plugin archives for every supported Python version, creates `SHA256SUMS`, and
publishes the GitHub Release. `workflow_dispatch` performs a non-publishing build.
# Bounded desktop tests
diff --git a/README.md b/README.md
index ed563e2..46ea33e 100644
--- a/README.md
+++ b/README.md
@@ -497,7 +497,7 @@ validate package metadata and scan for secrets. The current whole-package branch
coverage floor is 55%; desktop UI, WebKit and real-device paths remain included
in the denominator.
-The current release version is **1.5.0**. A `v1.5.0` tag must match every embedded
+The current release version is **1.5.1**. A `v1.5.1` tag must match every embedded
version before CI can publish. Tag releases rebuild both offline app and Omarchy
plugin archives for Python 3.11–3.14 and attach SHA-256 checksums. A manually started
release workflow builds artifacts for inspection but does not publish them. Real
diff --git a/README.zh-CN.md b/README.zh-CN.md
index f064136..e8021ee 100644
--- a/README.zh-CN.md
+++ b/README.zh-CN.md
@@ -365,7 +365,7 @@ timeout --kill-after=5s 50s env PYTHONPATH=src python3 tests/manual/x11.py --run
GTK 测试、代码检查、编译、包元数据校验和密钥扫描。覆盖率按整个源码包的分支覆盖率
计算,当前真实门槛为 55%;GTK 界面、WebKit 和实体设备路径没有从分母中排除。
-当前发布版本为 **1.5.0**。只有 `v1.5.0` 标签与所有内置版本完全一致时,CI 才能发布。
+当前发布版本为 **1.5.1**。只有 `v1.5.1` 标签与所有内置版本完全一致时,CI 才能发布。
标签发布会为 Python 3.11–3.14 分别构建独立应用与 Omarchy 插件离线包,并附带 SHA-256
校验文件。手动启动发布工作流只构建供检查的产物,不会公开发布。真实登录、麦克风、
全局按键及桌面行为仍需按人工验收清单检查。
diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md
index cf649d1..2d1e6a7 100644
--- a/RELEASE_NOTES.md
+++ b/RELEASE_NOTES.md
@@ -1,42 +1,28 @@
-# Doubao Say 1.5.0
+# Doubao Say 1.5.1
-## macOS client and in-app updates
+## Simpler macOS updates
-Add a native macOS client for macOS 13 or later, with Apple Silicon and Intel
-DMG installers signed with Developer ID and notarized by Apple. Features include
-Doubao web sign-in, Volcengine Seed ASR 2.0 and Deepgram Nova-3, configurable
-shortcuts and microphones, AI polishing, bilingual settings, guided setup and a
-bottom-screen overlay aligned with Linux.
+The Mac update page now shows one action for the current state:
-macOS and supported Linux installations now check the public GitHub update feed,
-show update availability, verify downloads and install after exit. Settings and
-sign-in data are retained. Mac updates also verify publisher identity and Apple
-notarization. Failed replacement or installation checks restore the previous app.
-The update feed does not use or include Feishu credentials.
+- **Check for updates** when no compatible update is available.
+- **Update and restart** when a compatible newer version is available.
+- **Cancel download** during update download and preparation.
-## Personal vocabulary and history
-
-Both platforms support automatically saved personal vocabulary for contextual
-AI polishing, padded recent-text editors and an optional local rolling 30-day
-input history. Frequency suggestions use polished output; AI organization sends
-only candidate terms and counts to the configured endpoint. Review and select
-suggestions before adding them. This does not train the ASR provider. History
-starts with this version and does not recover entries older versions never saved.
+While checking, the action shows **Checking…**, is disabled, and includes a
+progress indicator. Release notes use a text link. Version information and
+update status remain visible. Both English and Simplified Chinese are supported.
## Download and verification
-On Mac, choose the arm64 or x86_64 DMG for your computer and drag Doubao Say into
-Applications. Existing 1.4.0 Mac previews can discover this release through
-Settings → Updates → Check for updates. Linux users should choose the app or
-Omarchy plugin archive matching their Python 3.11–3.14 runtime. SHA256SUMS covers
-all published Linux archives and Mac DMGs.
-
-Swift behavior tests, loopback protocol/polishing checks, Linux unit and contract
-tests, GTK interface checks, and archive installation checks cover the release.
-Signing, notarization and update staging are checked on the local Mac. These
-checks do not establish real microphone, physical hotkey or live-account
-acceptance on every desktop, or execution on Intel hardware. Marketplace
-verification is a separate publication process.
-
-[Installation guide](https://github.com/quanru/doubao-say/blob/v1.5.0/packaging/INSTALL.md) ·
-[Full changes](https://github.com/quanru/doubao-say/compare/v1.4.0...v1.5.0)
+Existing 1.4.0 previews and 1.5.0 installations can use Settings → Updates to
+upgrade. Choose the signed, notarized arm64 or x86_64 DMG for manual Mac
+installation. Linux app/plugin archives remain available for Python 3.11–3.14;
+Linux already uses a single update action. Settings and login data are retained.
+
+Native before/after interface checks cover both languages and the current,
+available, checking, downloading and unsupported-package states. Swift behavior,
+loopback protocol/polishing, Linux unit/contract/coverage and release archive
+installation checks also cover this release. Cross-built Intel packages are not
+Intel hardware acceptance; live microphone and physical hotkeys remain separate.
+
+[Full changes](https://github.com/quanru/doubao-say/compare/v1.5.0...v1.5.1)
diff --git a/macos/Sources/AppState.swift b/macos/Sources/AppState.swift
index abe338f..365333c 100644
--- a/macos/Sources/AppState.swift
+++ b/macos/Sources/AppState.swift
@@ -22,6 +22,7 @@ class AppState: ObservableObject {
@Published var updateVersion = ""
@Published var updateStatus = ""
@Published var updateBusy = false
+ @Published var updateChecking = false
@Published var updateCanInstall = false
@Published var loginStatus: LoginStatus = .checking
diff --git a/macos/Sources/DoubaoSayApp.swift b/macos/Sources/DoubaoSayApp.swift
index c032abc..861c78f 100644
--- a/macos/Sources/DoubaoSayApp.swift
+++ b/macos/Sources/DoubaoSayApp.swift
@@ -61,6 +61,7 @@ final class AppDelegate: NSObject, NSApplicationDelegate, NSMenuDelegate {
self.rebuildMenu()
}
updates.onStatus = { [weak self] value in self?.state.updateStatus = value }
+ updates.onChecking = { [weak self] value in self?.state.updateChecking = value }
updateInstaller.onStatus = { [weak self] value in self?.state.updateStatus = value }
updateInstaller.onFinished = { [weak self] in self?.state.updateBusy = false }
updateInstaller.onReady = { [weak self] stage in
diff --git a/macos/Sources/SettingsWindow.swift b/macos/Sources/SettingsWindow.swift
index 6dea74a..c3880d1 100644
--- a/macos/Sources/SettingsWindow.swift
+++ b/macos/Sources/SettingsWindow.swift
@@ -291,7 +291,7 @@ struct SettingsView: View {
Divider()
VStack(alignment: .leading, spacing: 0) {
Text(pageTitle).font(.system(size: 20, weight: .semibold)).padding(24)
- if !state.updateVersion.isEmpty {
+ if !state.updateVersion.isEmpty && model.selectedTab != "updates" {
HStack {
Label(L("Update available: ", "发现新版本:") + state.updateVersion, systemImage: "arrow.down.circle.fill")
Spacer()
@@ -331,17 +331,22 @@ struct SettingsView: View {
Form {
Text(L("Current version: ", "当前版本:") + (Bundle.main.infoDictionary?["CFBundleShortVersionString"] as? String ?? "development"))
Text(state.updateStatus.isEmpty ? L("Updates are checked automatically once a day.", "每天自动检查更新。") : state.updateStatus)
- if state.updateBusy {
- ProgressView()
- Button(L("Cancel download", "取消下载")) { model.cancelUpdate?() }
- }
- Button(L("Check for updates", "检查更新")) { model.checkUpdates?() }.disabled(state.updateBusy)
if !state.updateVersion.isEmpty {
Label(L("New version: ", "新版本:") + state.updateVersion, systemImage: "arrow.down.circle")
- Button(L("Download and restart", "下载并重启")) { model.installUpdate?() }
- .disabled(state.updateBusy || !state.updateCanInstall || model.setupBusy)
if !state.updateCanInstall { Text(L("This release has no compatible Mac update package yet.", "此版本暂未提供适合这台 Mac 的更新包。")) }
- Button(L("Release notes", "更新说明")) { model.releaseNotes?() }
+ Button(L("Release notes", "更新说明")) { model.releaseNotes?() }.buttonStyle(.link)
+ }
+ HStack(spacing: 12) {
+ if state.updateBusy || state.updateChecking { ProgressView().controlSize(.small) }
+ if state.updateBusy {
+ Button(L("Cancel download", "取消下载")) { model.cancelUpdate?() }
+ } else if !state.updateVersion.isEmpty && state.updateCanInstall {
+ Button(L("Update and restart", "更新并重启")) { model.installUpdate?() }
+ .buttonStyle(.borderedProminent).disabled(state.updateChecking || model.setupBusy)
+ } else {
+ Button(state.updateChecking ? L("Checking…", "正在检查…") : L("Check for updates", "检查更新")) { model.checkUpdates?() }
+ .buttonStyle(.borderedProminent).disabled(state.updateChecking)
+ }
}
Text(L("Updates preserve your settings and login. Finish dictation before installing; the previous app is kept as a backup.", "更新保留设置和登录。请结束听写后安装,旧应用会保留为备份。"))
}.formStyle(.grouped).padding(8)
diff --git a/macos/Sources/UpdateChecker.swift b/macos/Sources/UpdateChecker.swift
index 8499a66..6e5bd94 100644
--- a/macos/Sources/UpdateChecker.swift
+++ b/macos/Sources/UpdateChecker.swift
@@ -5,6 +5,7 @@ final class UpdateChecker {
private var task: URLSessionDataTask?
var onResult: ((UpdateRelease?) -> Void)?
var onStatus: ((String) -> Void)?
+ var onChecking: ((Bool) -> Void)?
#if arch(arm64)
private let architecture = "arm64"
#else
@@ -21,11 +22,13 @@ final class UpdateChecker {
deliver(data, current: current); return
}
onStatus?(L("Checking for updates…", "正在检查更新…"))
+ onChecking?(true)
var request = URLRequest(url: URL(string: "https://api.github.com/repos/quanru/doubao-say/releases/latest")!, timeoutInterval: 8)
request.setValue("application/vnd.github+json", forHTTPHeaderField: "Accept")
request.setValue("Doubao-Say/" + current, forHTTPHeaderField: "User-Agent")
task = URLSession.shared.dataTask(with: request) { [weak self] data, response, _ in Task { @MainActor in
guard let self = self else { return }; self.task = nil
+ self.onChecking?(false)
guard let http = response as? HTTPURLResponse, http.statusCode == 200, let data = data, data.count <= 1_000_000,
let json = try? JSONSerialization.jsonObject(with: data) as? [String: Any],
let tag = json["tag_name"] as? String, UpdateRelease.version(tag) != nil else {
@@ -42,5 +45,5 @@ final class UpdateChecker {
onResult?(info)
onStatus?(info == nil ? L("You are using the latest version.", "当前已是最新版本。") : L("An update is available.", "发现新版本。"))
}
- func cancel() { task?.cancel(); task = nil }
+ func cancel() { task?.cancel(); task = nil; onChecking?(false) }
}
diff --git a/manifest.json b/manifest.json
index df87c13..e0ff30f 100644
--- a/manifest.json
+++ b/manifest.json
@@ -2,7 +2,7 @@
"schemaVersion": 1,
"id": "md.lifeos.doubao-say",
"name": "Doubao Say",
- "version": "1.5.0",
+ "version": "1.5.1",
"author": "quanru and contributors",
"description": "Doubao Say turns speech into polished text with live captions and configurable tap or hold triggers on Wayland.",
"kinds": [
diff --git a/packaging/INSTALL.md b/packaging/INSTALL.md
index 138e3ce..0ed7ab4 100644
--- a/packaging/INSTALL.md
+++ b/packaging/INSTALL.md
@@ -1,4 +1,4 @@
-# Doubao Say 1.5.0
+# Doubao Say 1.5.1
[Website](https://doubao-say.lifeos.md/) · [简体中文安装指南](https://doubao-say.lifeos.md/zh/guide/install)
diff --git a/pyproject.toml b/pyproject.toml
index b81cc8b..b75689c 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
[project]
name = "doubao-say"
-version = "1.5.0"
+version = "1.5.1"
description = "Global push-to-hold voice input for Linux/Wayland, backed by Doubao ASR"
readme = "README.md"
requires-python = ">=3.11"
diff --git a/src/doubao_input/product.py b/src/doubao_input/product.py
index 7c2dd5d..28545c4 100644
--- a/src/doubao_input/product.py
+++ b/src/doubao_input/product.py
@@ -1,5 +1,5 @@
"""Single runtime source for Doubao Say release identity."""
-VERSION = "1.5.0"
+VERSION = "1.5.1"
REPOSITORY_URL = "https://github.com/quanru/doubao-say"
LATEST_RELEASE_API = "https://api.github.com/repos/quanru/doubao-say/releases/latest"
diff --git a/tests/contracts/test_release.py b/tests/contracts/test_release.py
index d17f254..f7b494e 100644
--- a/tests/contracts/test_release.py
+++ b/tests/contracts/test_release.py
@@ -49,7 +49,7 @@ class ReleaseTest(unittest.TestCase):
notes = (ROOT / "RELEASE_NOTES.md").read_text()
self.assertIn("--notes-file RELEASE_NOTES.md", workflow)
self.assertNotIn("--generate-notes", workflow)
- for expected in ("Doubao Say 1.5.0", "Volcengine Seed ASR 2.0", "Deepgram Nova-3"):
+ for expected in ("Doubao Say 1.5.1", "Check for updates", "Update and restart"):
self.assertIn(expected, notes)
def test_both_archives_exclude_ignored_source_files(self):
diff --git a/tests/contracts/test_version_check.py b/tests/contracts/test_version_check.py
index 016d0d1..657a9e1 100644
--- a/tests/contracts/test_version_check.py
+++ b/tests/contracts/test_version_check.py
@@ -11,13 +11,13 @@ SPEC.loader.exec_module(VERSION_CHECK)
class VersionCheckTests(unittest.TestCase):
def test_sources_are_aligned_at_current_release(self):
- self.assertEqual(VERSION_CHECK.validate(root=ROOT), "1.5.0")
+ self.assertEqual(VERSION_CHECK.validate(root=ROOT), "1.5.1")
def test_exact_release_tag_is_accepted(self):
- self.assertEqual(VERSION_CHECK.validate("v1.5.0", ROOT), "1.5.0")
+ self.assertEqual(VERSION_CHECK.validate("v1.5.1", ROOT), "1.5.1")
def test_wrong_release_tag_is_rejected(self):
- with self.assertRaisesRegex(ValueError, "must be 'v1.5.0'"):
+ with self.assertRaisesRegex(ValueError, "must be 'v1.5.1'"):
VERSION_CHECK.validate("v1.1.0", ROOT)
diff --git a/tests/unit/test_product.py b/tests/unit/test_product.py
index 7264c47..cc022f2 100644
--- a/tests/unit/test_product.py
+++ b/tests/unit/test_product.py
@@ -51,7 +51,7 @@ class ProductTest(TestCase):
self.assertNotIn("private-device-identifier", data)
self.assertNotIn("cookies", data)
self.assertNotIn("transcript", data)
- self.assertEqual(json.loads(data)["product_version"], "1.5.0")
+ self.assertEqual(json.loads(data)["product_version"], "1.5.1")
self.assertEqual(json.loads(data)["recognition_provider"], "volcengine")
self.assertEqual(json.loads(data)["recent_stages"], [
{"stage": "first_result", "after_ms": 125}])