mirror of
https://github.com/YuJunZhiXue/dsh-purge.git
synced 2026-11-28 13:10:22 +08:00
fix: 发布 1.1.21,修复 #43、#9、#15、#23、#42 报必需补丁失败
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
1 parent
232c9e2461
commit
4ef30254f2
7 files changed
+55
-26
No files matched your search
+9
-6
@@ -63,7 +63,11 @@ function isSubPath(child, root) {
|
||||
return c === r || c.startsWith(`${r}/`);
|
||||
}
|
||||
|
||||
/** 文件夹名带 DSH Desktop / dsh-desktop 时,任意盘符都算桌面安装树。 */
|
||||
/**
|
||||
* 社区桌面、官方 exe、.app 包才算安装树。
|
||||
* 只是上级文件夹叫 DeepSeek Harness 不算:npm 前缀和配置目录经常用这个名字,
|
||||
* 按名字整棵排除的话,Web 的身份句和 complete 注入补丁会被跳过。
|
||||
*/
|
||||
export function looksLikeDesktopName(p) {
|
||||
const n = slashNorm(p);
|
||||
if (!n) return false;
|
||||
@@ -73,12 +77,11 @@ export function looksLikeDesktopName(p) {
|
||||
n.endsWith("/dsh desktop") ||
|
||||
n.endsWith("/dsh desktop.app") ||
|
||||
n.includes("dsh-desktop") ||
|
||||
n.includes("/deepseek harness/") ||
|
||||
n.includes("/deepseek harness.app/") ||
|
||||
n.endsWith("/deepseek harness") ||
|
||||
n.includes("deepseek-harness") ||
|
||||
n.endsWith("/deepseek harness.app") ||
|
||||
/\/dsh desktop\.exe$/i.test(n) ||
|
||||
/\/deepseek harness\.exe$/i.test(n)
|
||||
/\/deepseek harness\.exe$/i.test(n) ||
|
||||
/\/deepseek-harness\.exe$/i.test(n)
|
||||
);
|
||||
}
|
||||
|
||||
@@ -304,7 +307,7 @@ export function listDesktopInstallRoots(input = {}) {
|
||||
/**
|
||||
* 是否落在社区 Desktop 安装树。
|
||||
* 不依赖盘符、也不要求文件夹叫 “DSH Desktop”:
|
||||
* 当前进程的 exe / resources / host-process-entry、旁边真有 DSH Desktop.exe、或名字启发式。
|
||||
* 当前进程的 exe / resources / host-process-entry、旁边真有桌面 exe,或社区安装目录名。
|
||||
*/
|
||||
export function isInsideDesktopInstall(p, input = {}) {
|
||||
if (!p) return false;
|
||||
|
||||
Reference in new issue
Block a user