@synkro-sh/cli 1.4.4 → 1.4.6
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/bootstrap.js +52 -14
- package/dist/bootstrap.js.map +1 -1
- package/package.json +1 -1
package/dist/bootstrap.js
CHANGED
|
@@ -3679,9 +3679,21 @@ function patchClaudeJson() {
|
|
|
3679
3679
|
});
|
|
3680
3680
|
}
|
|
3681
3681
|
function installLocalCC() {
|
|
3682
|
-
|
|
3682
|
+
let bunCheck = spawnSync("bun", ["--version"], { encoding: "utf-8" });
|
|
3683
3683
|
if (bunCheck.status !== 0) {
|
|
3684
|
-
|
|
3684
|
+
if (process.platform === "darwin") {
|
|
3685
|
+
console.log(" Installing bun via brew...");
|
|
3686
|
+
const brewR = spawnSync("brew", ["install", "oven-sh/bun/bun"], { encoding: "utf-8", stdio: "inherit", timeout: 12e4 });
|
|
3687
|
+
if (brewR.status !== 0) {
|
|
3688
|
+
throw new LocalCCInstallError("bun auto-install failed. Install manually: curl -fsSL https://bun.sh/install | bash");
|
|
3689
|
+
}
|
|
3690
|
+
bunCheck = spawnSync("bun", ["--version"], { encoding: "utf-8" });
|
|
3691
|
+
if (bunCheck.status !== 0) {
|
|
3692
|
+
throw new LocalCCInstallError("bun installed but not found on PATH. Restart your terminal and re-run install.");
|
|
3693
|
+
}
|
|
3694
|
+
} else {
|
|
3695
|
+
throw new LocalCCInstallError("bun is required. Install it: curl -fsSL https://bun.sh/install | bash");
|
|
3696
|
+
}
|
|
3685
3697
|
}
|
|
3686
3698
|
writePluginFiles();
|
|
3687
3699
|
runBunInstall();
|
|
@@ -3767,7 +3779,7 @@ done
|
|
|
3767
3779
|
});
|
|
3768
3780
|
|
|
3769
3781
|
// cli/local-cc/pueue.ts
|
|
3770
|
-
import { execFileSync, spawnSync as spawnSync2 } from "child_process";
|
|
3782
|
+
import { execFileSync, spawnSync as spawnSync2, spawn } from "child_process";
|
|
3771
3783
|
import { homedir as homedir8 } from "os";
|
|
3772
3784
|
import { join as join9 } from "path";
|
|
3773
3785
|
import { connect } from "net";
|
|
@@ -3890,12 +3902,33 @@ async function waitForChannelReady(port, timeoutMs = 6e4, host = "127.0.0.1") {
|
|
|
3890
3902
|
}
|
|
3891
3903
|
return probePort(host, port);
|
|
3892
3904
|
}
|
|
3905
|
+
function brewInstall(pkg) {
|
|
3906
|
+
const brew = spawnSync2("brew", ["--version"], { encoding: "utf-8" });
|
|
3907
|
+
if (brew.status !== 0) return false;
|
|
3908
|
+
console.log(` Installing ${pkg} via brew...`);
|
|
3909
|
+
const r = spawnSync2("brew", ["install", pkg], { encoding: "utf-8", stdio: "inherit", timeout: 12e4 });
|
|
3910
|
+
return r.status === 0;
|
|
3911
|
+
}
|
|
3893
3912
|
function assertPueueInstalled() {
|
|
3894
|
-
|
|
3895
|
-
|
|
3896
|
-
|
|
3897
|
-
|
|
3898
|
-
|
|
3913
|
+
let r = spawnSync2("pueue", ["--version"], { encoding: "utf-8" });
|
|
3914
|
+
if (r.status !== 0) {
|
|
3915
|
+
if (process.platform === "darwin" && brewInstall("pueue")) {
|
|
3916
|
+
r = spawnSync2("pueue", ["--version"], { encoding: "utf-8" });
|
|
3917
|
+
if (r.status !== 0) throw new PueueError("pueue install succeeded but binary not found on PATH.");
|
|
3918
|
+
} else {
|
|
3919
|
+
throw new PueueError("pueue not found. Install it: brew install pueue (macOS) or https://github.com/Nukesor/pueue");
|
|
3920
|
+
}
|
|
3921
|
+
}
|
|
3922
|
+
const status = spawnSync2("pueue", ["status", "--json"], { encoding: "utf-8", timeout: 5e3 });
|
|
3923
|
+
if (status.status !== 0) {
|
|
3924
|
+
console.log(" Starting pueued daemon...");
|
|
3925
|
+
const child = spawn("pueued", ["-d"], { stdio: "ignore", detached: true });
|
|
3926
|
+
child.unref();
|
|
3927
|
+
spawnSync2("sleep", ["1"]);
|
|
3928
|
+
const retry = spawnSync2("pueue", ["status", "--json"], { encoding: "utf-8", timeout: 5e3 });
|
|
3929
|
+
if (retry.status !== 0) {
|
|
3930
|
+
throw new PueueError("pueue daemon not reachable after starting pueued. Check `pueued` manually.");
|
|
3931
|
+
}
|
|
3899
3932
|
}
|
|
3900
3933
|
}
|
|
3901
3934
|
function assertClaudeInstalled() {
|
|
@@ -3905,9 +3938,14 @@ function assertClaudeInstalled() {
|
|
|
3905
3938
|
}
|
|
3906
3939
|
}
|
|
3907
3940
|
function assertTmuxInstalled() {
|
|
3908
|
-
|
|
3941
|
+
let r = spawnSync2("tmux", ["-V"], { encoding: "utf-8" });
|
|
3909
3942
|
if (r.status !== 0) {
|
|
3910
|
-
|
|
3943
|
+
if (process.platform === "darwin" && brewInstall("tmux")) {
|
|
3944
|
+
r = spawnSync2("tmux", ["-V"], { encoding: "utf-8" });
|
|
3945
|
+
if (r.status !== 0) throw new PueueError("tmux install succeeded but binary not found on PATH.");
|
|
3946
|
+
} else {
|
|
3947
|
+
throw new PueueError("tmux not found. Install it: brew install tmux (macOS) or apt install tmux (Linux)");
|
|
3948
|
+
}
|
|
3911
3949
|
}
|
|
3912
3950
|
}
|
|
3913
3951
|
var TASK_LABEL, TMUX_SESSION, SESSION_DIR2, PueueError;
|
|
@@ -4302,7 +4340,7 @@ function writeConfigEnv(opts) {
|
|
|
4302
4340
|
`SYNKRO_CREDENTIALS_PATH=${shellQuoteSingle(credsPath)}`,
|
|
4303
4341
|
`SYNKRO_TIER=${shellQuoteSingle(safeTier)}`,
|
|
4304
4342
|
`SYNKRO_INFERENCE=${shellQuoteSingle(safeInference)}`,
|
|
4305
|
-
`SYNKRO_VERSION=${shellQuoteSingle("1.4.
|
|
4343
|
+
`SYNKRO_VERSION=${shellQuoteSingle("1.4.6")}`
|
|
4306
4344
|
];
|
|
4307
4345
|
if (safeSynkroBin) lines.push(`SYNKRO_CLI_BIN=${shellQuoteSingle(safeSynkroBin)}`);
|
|
4308
4346
|
if (safeUserId) lines.push(`SYNKRO_USER_ID=${shellQuoteSingle(safeUserId)}`);
|
|
@@ -5296,7 +5334,7 @@ var scanPr_exports = {};
|
|
|
5296
5334
|
__export(scanPr_exports, {
|
|
5297
5335
|
scanPrCommand: () => scanPrCommand
|
|
5298
5336
|
});
|
|
5299
|
-
import { execSync as execSync6, spawn } from "child_process";
|
|
5337
|
+
import { execSync as execSync6, spawn as spawn2 } from "child_process";
|
|
5300
5338
|
import { readFileSync as readFileSync13, existsSync as existsSync15 } from "fs";
|
|
5301
5339
|
import { join as join15 } from "path";
|
|
5302
5340
|
function parseMatchSpec(condition) {
|
|
@@ -5507,7 +5545,7 @@ ${hunks}`;
|
|
|
5507
5545
|
const fullPrompt = promptHeader + userMessage;
|
|
5508
5546
|
return new Promise((resolve2) => {
|
|
5509
5547
|
const t0 = Date.now();
|
|
5510
|
-
const proc =
|
|
5548
|
+
const proc = spawn2(
|
|
5511
5549
|
"claude",
|
|
5512
5550
|
["--print", "--model", "claude-sonnet-4-6", "--output-format", "json", "--no-session-persistence"],
|
|
5513
5551
|
{
|
|
@@ -5606,7 +5644,7 @@ ${JSON.stringify(findings, null, 2)}
|
|
|
5606
5644
|
function spawnOpusConsolidator(findings, claudeToken) {
|
|
5607
5645
|
return new Promise((resolve2) => {
|
|
5608
5646
|
const prompt2 = buildConsolidationPrompt(findings);
|
|
5609
|
-
const proc =
|
|
5647
|
+
const proc = spawn2(
|
|
5610
5648
|
"claude",
|
|
5611
5649
|
["--print", "--model", "claude-opus-4-7", "--output-format", "json", "--no-session-persistence"],
|
|
5612
5650
|
{
|