🔧 fix(vscode): worktree 目录配置改用插件自带设置面板,撤销 VS Code 原生配置
上一版误把 worktree 目录模板注册成 VS Code 原生设置(contributes.configuration + workspace.getConfiguration),但本插件有自己的设置面板(SettingsModal,存 globalState)。 改为: - Settings 新增 worktreeDirectory 字段(默认 ~/Sources/worktree/$project_name/$feature_name, 留空回退默认),贯穿 store/handler/两端 messages/useIssues/App/SettingsModal - SettingsModal「钩子」分组新增「工作树目录」输入项,走既有 save/load 流程 - handleImplement 改从 getSettings(panel.context).worktreeDirectory 读模板 - 删除 package.json 的 contributes.configuration(meta.ts 为 gitignore 生成物,已本地还原) deriveSlug / resolveWorktreeDir / ~ 展开 / 绝对路径 / feature/<slug> 逻辑不变。 Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
+1
-11
@@ -2,7 +2,7 @@
|
||||
"publisher": "clurdra",
|
||||
"name": "superpowers-vscode-clurdra",
|
||||
"displayName": "Superpowers-clurdra",
|
||||
"version": "0.2.43",
|
||||
"version": "0.2.44",
|
||||
"packageManager": "pnpm@10.27.0",
|
||||
"description": "Superpowers specs and plans Kanban explorer",
|
||||
"author": "clurdra",
|
||||
@@ -93,16 +93,6 @@
|
||||
"group": "navigation"
|
||||
}
|
||||
]
|
||||
},
|
||||
"configuration": {
|
||||
"title": "Superpowers",
|
||||
"properties": {
|
||||
"superpowers.worktreeDirectory": {
|
||||
"type": "string",
|
||||
"default": "~/Sources/worktree/$project_name/$feature_name",
|
||||
"markdownDescription": "运行 Plan 时创建 worktree 的目录模板。支持占位符 `$project_root`(工作区根目录的绝对路径)、`$project_name`(工作区目录名)、`$feature_name`(spec/plan 的 slug)。开头的 `~` 会展开为当前用户主目录。默认会把 worktree 建到 `~/Sources/worktree/<项目名>/<slug>`。"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"scripts": {
|
||||
|
||||
Reference in New Issue
Block a user