@max-null/dsh-plugin-center 0.2.9 → 0.2.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/update.js +9 -0
- package/package.json +1 -1
package/dist/update.js
CHANGED
|
@@ -275,6 +275,15 @@ export async function runPnpm(args, cwd) {
|
|
|
275
275
|
if (last.ok)
|
|
276
276
|
break;
|
|
277
277
|
}
|
|
278
|
+
// 自更新鸡生蛋兜底提示:所有候选都失败且是 store 版本不匹配时,把可复制
|
|
279
|
+
// 的手动命令放进 detail,用户按提示在 profile 目录执行即可(2026-08-23
|
|
280
|
+
// 另一台电脑 v10/v11 实测——旧 host 无自动兜底,需要一条显式命令)。
|
|
281
|
+
if (!last.ok && last.detail.includes('ERR_PNPM_UNEXPECTED_STORE')) {
|
|
282
|
+
const major = detectStoreMajor(cwd);
|
|
283
|
+
if (major !== undefined) {
|
|
284
|
+
last.detail += `\n\nHint: 在 profile 目录(${cwd})执行:\n npx --yes pnpm@${major} ${args.join(' ')}`;
|
|
285
|
+
}
|
|
286
|
+
}
|
|
278
287
|
logPnpm(cwd, args, last);
|
|
279
288
|
return last;
|
|
280
289
|
}
|
package/package.json
CHANGED