oh-my-customcode 0.87.1 → 0.87.2
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/cli/index.js +50 -19
- package/dist/index.js +2 -1
- package/package.json +1 -1
- package/templates/manifest.json +1 -1
package/dist/cli/index.js
CHANGED
|
@@ -2301,7 +2301,7 @@ var init_package = __esm(() => {
|
|
|
2301
2301
|
workspaces: [
|
|
2302
2302
|
"packages/*"
|
|
2303
2303
|
],
|
|
2304
|
-
version: "0.87.
|
|
2304
|
+
version: "0.87.2",
|
|
2305
2305
|
description: "Batteries-included agent harness for Claude Code",
|
|
2306
2306
|
type: "module",
|
|
2307
2307
|
bin: {
|
|
@@ -25031,6 +25031,8 @@ var en_default = {
|
|
|
25031
25031
|
newVersionAvailable: "[Info] oh-my-customcode v{{latest}} available (current: v{{current}}). Run 'npm i -g oh-my-customcode' to upgrade.",
|
|
25032
25032
|
selfUpdateDone: "✓ oh-my-customcode updated ({{from}} → {{to}})",
|
|
25033
25033
|
selfUpdateFailed: "⚠ Self-update check failed — continuing with external updates",
|
|
25034
|
+
selfUpdateReexec: "↻ Re-executing with updated CLI (v{{version}})...",
|
|
25035
|
+
allProjectSkippedSource: " ℹ Skipped: {{name}} (source project cannot self-update)",
|
|
25034
25036
|
rtkMissing: "[RTK] RTK is not installed. Attempting installation...",
|
|
25035
25037
|
rtkInstalled: "[RTK] ✓ RTK installed — 60-90% token savings activated",
|
|
25036
25038
|
codexMissing: "[Codex] Codex CLI is not installed. Attempting installation...",
|
|
@@ -25446,6 +25448,8 @@ var ko_default = {
|
|
|
25446
25448
|
newVersionAvailable: "[정보] oh-my-customcode v{{latest}} 사용 가능 (현재: v{{current}}). 'npm i -g oh-my-customcode'를 실행하여 업그레이드하세요.",
|
|
25447
25449
|
selfUpdateDone: "✓ oh-my-customcode 업데이트 완료 ({{from}} → {{to}})",
|
|
25448
25450
|
selfUpdateFailed: "⚠ 자체 업데이트 확인 실패 — 외부 업데이트를 계속 진행합니다",
|
|
25451
|
+
selfUpdateReexec: "↻ 새 CLI(v{{version}})로 재실행 중...",
|
|
25452
|
+
allProjectSkippedSource: " ℹ 스킵: {{name}} (소스 프로젝트는 자체 업데이트할 수 없음)",
|
|
25449
25453
|
rtkMissing: "[RTK] RTK가 설치되지 않았습니다. 설치를 시도합니다...",
|
|
25450
25454
|
rtkInstalled: "[RTK] ✓ RTK 설치 완료 — 토큰 60-90% 절감 활성화",
|
|
25451
25455
|
codexMissing: "[Codex] Codex CLI가 설치되지 않았습니다. 설치를 시도합니다...",
|
|
@@ -31038,6 +31042,7 @@ async function shouldSkipSelfUpdate2(targetDir, result) {
|
|
|
31038
31042
|
if (targetPkg.name === "oh-my-customcode") {
|
|
31039
31043
|
warn("update.self_update_skipped");
|
|
31040
31044
|
result.success = true;
|
|
31045
|
+
result.skippedSource = true;
|
|
31041
31046
|
result.warnings.push("Skipped: source project cannot update itself");
|
|
31042
31047
|
return true;
|
|
31043
31048
|
}
|
|
@@ -31455,19 +31460,34 @@ async function checkCliVersion(checkFn) {
|
|
|
31455
31460
|
}
|
|
31456
31461
|
} catch {}
|
|
31457
31462
|
}
|
|
31458
|
-
async function
|
|
31459
|
-
|
|
31460
|
-
|
|
31461
|
-
|
|
31462
|
-
|
|
31463
|
-
|
|
31464
|
-
|
|
31465
|
-
|
|
31466
|
-
|
|
31463
|
+
async function reexecUpdatedCli(toVersion) {
|
|
31464
|
+
console.log(i18n.t("cli.update.selfUpdateReexec", { version: toVersion }));
|
|
31465
|
+
const { spawnSync: spawnSync4 } = await import("node:child_process");
|
|
31466
|
+
const child = spawnSync4(process.execPath, [process.argv[1] ?? "", ...process.argv.slice(2)], {
|
|
31467
|
+
stdio: "inherit",
|
|
31468
|
+
env: { ...process.env, OMCUSTOM_SKIP_SELF_UPDATE: "true" }
|
|
31469
|
+
});
|
|
31470
|
+
process.exit(child.status ?? 1);
|
|
31471
|
+
}
|
|
31472
|
+
async function handleSelfUpdate() {
|
|
31473
|
+
try {
|
|
31474
|
+
const selfUpdateResult = executeSelfUpdate();
|
|
31475
|
+
if (selfUpdateResult.updated) {
|
|
31476
|
+
console.log(i18n.t("cli.update.selfUpdateDone", {
|
|
31477
|
+
from: selfUpdateResult.fromVersion,
|
|
31478
|
+
to: selfUpdateResult.toVersion
|
|
31479
|
+
}));
|
|
31480
|
+
if (process.env.OMCUSTOM_SKIP_SELF_UPDATE !== "true") {
|
|
31481
|
+
await reexecUpdatedCli(selfUpdateResult.toVersion);
|
|
31467
31482
|
}
|
|
31468
|
-
} catch {
|
|
31469
|
-
console.warn(i18n.t("cli.update.selfUpdateFailed"));
|
|
31470
31483
|
}
|
|
31484
|
+
} catch {
|
|
31485
|
+
console.warn(i18n.t("cli.update.selfUpdateFailed"));
|
|
31486
|
+
}
|
|
31487
|
+
}
|
|
31488
|
+
async function updateCommand(options = {}, cliVersionCheck = checkSelfUpdate) {
|
|
31489
|
+
if (!options.skipSelf) {
|
|
31490
|
+
await handleSelfUpdate();
|
|
31471
31491
|
} else {
|
|
31472
31492
|
await checkCliVersion(cliVersionCheck);
|
|
31473
31493
|
}
|
|
@@ -31510,6 +31530,21 @@ async function updateSingleProject(targetDir, options) {
|
|
|
31510
31530
|
}
|
|
31511
31531
|
return true;
|
|
31512
31532
|
}
|
|
31533
|
+
function reportProjectUpdateResult(project, result, currentVersion) {
|
|
31534
|
+
if (result.success) {
|
|
31535
|
+
if (result.skippedSource) {
|
|
31536
|
+
console.log(i18n.t("cli.update.allProjectSkippedSource", { name: project.name }));
|
|
31537
|
+
return "skipped";
|
|
31538
|
+
}
|
|
31539
|
+
const from = result.previousVersion || project.version || "unknown";
|
|
31540
|
+
const to = result.newVersion || currentVersion;
|
|
31541
|
+
console.log(i18n.t("cli.update.allProjectUpdated", { from, to }));
|
|
31542
|
+
return "updated";
|
|
31543
|
+
}
|
|
31544
|
+
const errorMsg = result.error ?? "unknown error";
|
|
31545
|
+
console.log(i18n.t("cli.update.allProjectFailed", { error: errorMsg }));
|
|
31546
|
+
return "failed";
|
|
31547
|
+
}
|
|
31513
31548
|
async function updateAllProjects(options) {
|
|
31514
31549
|
const { findProjects: findProjects2 } = await Promise.resolve().then(() => (init_projects(), exports_projects));
|
|
31515
31550
|
const currentVersion = package_default.version;
|
|
@@ -31544,14 +31579,10 @@ async function updateAllProjects(options) {
|
|
|
31544
31579
|
hard: options.hard
|
|
31545
31580
|
};
|
|
31546
31581
|
const result = await update(updateOptions);
|
|
31547
|
-
|
|
31548
|
-
|
|
31549
|
-
const to = result.newVersion || currentVersion;
|
|
31550
|
-
console.log(i18n.t("cli.update.allProjectUpdated", { from, to }));
|
|
31582
|
+
const outcome = reportProjectUpdateResult(project, result, currentVersion);
|
|
31583
|
+
if (outcome === "updated") {
|
|
31551
31584
|
updatedCount++;
|
|
31552
|
-
} else {
|
|
31553
|
-
const errorMsg = result.error ?? "unknown error";
|
|
31554
|
-
console.log(i18n.t("cli.update.allProjectFailed", { error: errorMsg }));
|
|
31585
|
+
} else if (outcome === "failed") {
|
|
31555
31586
|
failedCount++;
|
|
31556
31587
|
}
|
|
31557
31588
|
} catch (error2) {
|
package/dist/index.js
CHANGED
|
@@ -1974,7 +1974,7 @@ var package_default = {
|
|
|
1974
1974
|
workspaces: [
|
|
1975
1975
|
"packages/*"
|
|
1976
1976
|
],
|
|
1977
|
-
version: "0.87.
|
|
1977
|
+
version: "0.87.2",
|
|
1978
1978
|
description: "Batteries-included agent harness for Claude Code",
|
|
1979
1979
|
type: "module",
|
|
1980
1980
|
bin: {
|
|
@@ -4843,6 +4843,7 @@ async function shouldSkipSelfUpdate(targetDir, result) {
|
|
|
4843
4843
|
if (targetPkg.name === "oh-my-customcode") {
|
|
4844
4844
|
warn("update.self_update_skipped");
|
|
4845
4845
|
result.success = true;
|
|
4846
|
+
result.skippedSource = true;
|
|
4846
4847
|
result.warnings.push("Skipped: source project cannot update itself");
|
|
4847
4848
|
return true;
|
|
4848
4849
|
}
|
package/package.json
CHANGED
package/templates/manifest.json
CHANGED