Skip to content

DeepSeek Harness Tauri 桌面版 | Only 8mb installer, zero environment setup, preset plugins, Windows / macOS / Linux.

feat(plugin): add dsh-tauri and dsh-notification presets with defaultChecked

hairyf55bed8e3df8d
diff --git a/src-tauri/resources/preset-plugins.json b/src-tauri/resources/preset-plugins.json
index 30f76f7e..e0299827 100644
--- a/src-tauri/resources/preset-plugins.json
+++ b/src-tauri/resources/preset-plugins.json
@@ -1,4 +1,12 @@
[
+ {
+ "id": "dsh-tauri",
+ "spec": "github:hairyf/dsh-tauri",
+ "name": "DSH Tauri",
+ "description": "Native top nav bar for the desktop shell: sidebar/back/forward route control plus minimize/maximize/background window controls, driven by iframe events. · 桌面端顶部原生导航栏:侧边栏/后退/前进路由控制 + 最小化/最大化/后台化窗口控制(iframe 事件驱动,接管系统标题栏)。",
+ "repoUrl": "https://github.com/hairyf/dsh-tauri",
+ "recommended": true
+ },
{
"id": "dsh-win-terminal-inspector",
"spec": "github:clearkurt/dsh-win-terminal-inspector",
@@ -16,5 +24,14 @@
"description": "Visual plugin market inside DeepSeek Harness — browse, search, and one-click install community plugins. · DSH 可视化插件市场:逛一逛,点一下,装好。",
"repoUrl": "https://github.com/dsh-market/dsh-market",
"recommended": true
+ },
+ {
+ "id": "dsh-notification",
+ "spec": "github:omdsh-dev/dsh-notification",
+ "name": "DSH Notification",
+ "description": "Desktop notifications when a turn finishes — per-outcome toggles plus include/exclude keyword rules, delivered via the browser Notification API. · 回合完成时桌面通知:按结果分别开关,支持包含/排除关键词规则,经浏览器 Notification API 弹出。",
+ "repoUrl": "https://github.com/omdsh-dev/dsh-notification",
+ "recommended": false,
+ "defaultChecked": true
}
]
diff --git a/src-tauri/src/service/plugin/installed.rs b/src-tauri/src/service/plugin/installed.rs
index d8c010b8..5fc48b0e 100644
--- a/src-tauri/src/service/plugin/installed.rs
+++ b/src-tauri/src/service/plugin/installed.rs
@@ -71,6 +71,8 @@ pub struct PreinstallPlugin {
pub recommended: bool,
/// 是否为「修复」类项(前端渲染黄色 chip,默认勾选)
pub fix: bool,
+ /// 无 chip 但默认勾选(首次引导直接勾上,不标「推荐」)
+ pub default_checked: bool,
pub installed: bool,
}
@@ -91,6 +93,7 @@ pub fn list(app_handle: &AppHandle) -> Vec<PreinstallPlugin> {
repo_url: p.repo_url,
recommended: p.recommended,
fix: p.fix,
+ default_checked: p.default_checked,
installed: is_installed,
}
})
diff --git a/src-tauri/src/service/plugin/preset.rs b/src-tauri/src/service/plugin/preset.rs
index 15f1a389..0fa42d3d 100644
--- a/src-tauri/src/service/plugin/preset.rs
+++ b/src-tauri/src/service/plugin/preset.rs
@@ -27,6 +27,9 @@ pub struct PreinstallPluginInfo {
/// 黄色「修复」chip,默认勾选(Windows 极简模式修复项)
#[serde(default)]
pub fix: bool,
+ /// 无 chip 但默认勾选(如 dsh-notification:不标「推荐」,首次引导仍直接勾上)
+ #[serde(default)]
+ pub default_checked: bool,
/// 仅 Windows 平台列出
#[serde(default)]
pub win_only: bool,
diff --git a/src/components/preinstall-setup.tsx b/src/components/preinstall-setup.tsx
index c7817ef4..8c6b3be7 100644
--- a/src/components/preinstall-setup.tsx
+++ b/src/components/preinstall-setup.tsx
@@ -134,11 +134,11 @@ export default function PreinstallSetup() {
void harness.loadPreinstallPlugins()
}, [])
- // 默认勾选:未安装的推荐插件 +「修复」类项(当前为 Windows 极简模式修复)。
+ // 默认勾选:未安装的推荐插件 +「修复」类项 + 无 chip 但标记默认勾选的项(如 dsh-notification)。
// 派生计算而非在加载回调里 setState,避免与 store 的加载去重守卫竞争,
// 保证插件到位后默认勾选必定生效(用户手动调整后以用户选择为准)。
const effectiveSelected = !touched
- ? new Set(preinstall.plugins.filter(p => !p.installed && (p.recommended || p.fix)).map(p => p.id))
+ ? new Set(preinstall.plugins.filter(p => !p.installed && (p.recommended || p.fix || p.defaultChecked)).map(p => p.id))
: selected
function toggle(id: string, checked: boolean) {
diff --git a/src/store/modules/harness/types.ts b/src/store/modules/harness/types.ts
index fc1a7abe..d3673718 100644
--- a/src/store/modules/harness/types.ts
+++ b/src/store/modules/harness/types.ts
@@ -13,6 +13,8 @@ export interface PreinstallPlugin {
recommended: boolean
/** “修复”类项(Windows 极简模式修复):黄色 chip,默认勾选 */
fix: boolean
+ /** 无 chip 但默认勾选(首次引导直接勾上,不标「推荐」) */
+ defaultChecked: boolean
installed: boolean
}