flyspace-cli 0.1.46 → 0.1.48
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/{chunk-5MCLO4QM.js → chunk-2V33REYC.js} +5 -1
- package/dist/cli.js +18 -7
- package/dist/index.js +1 -1
- package/package.json +1 -1
|
@@ -1884,6 +1884,10 @@ function buildHookSettings(runtime, builtInStyleName) {
|
|
|
1884
1884
|
}
|
|
1885
1885
|
});
|
|
1886
1886
|
}
|
|
1887
|
+
function isModelForGateway(model, pinned) {
|
|
1888
|
+
if (!pinned) return true;
|
|
1889
|
+
return model.split("-")[0].toLowerCase() === pinned.split("-")[0].toLowerCase();
|
|
1890
|
+
}
|
|
1887
1891
|
function buildArgs(prompt, botName, options, resumeSessionId, isolatedStyle) {
|
|
1888
1892
|
const args = [
|
|
1889
1893
|
"--print",
|
|
@@ -1927,7 +1931,7 @@ function buildArgs(prompt, botName, options, resumeSessionId, isolatedStyle) {
|
|
|
1927
1931
|
if (options.mcpConfigPath) {
|
|
1928
1932
|
args.push("--mcp-config", options.mcpConfigPath);
|
|
1929
1933
|
}
|
|
1930
|
-
if (options.model) {
|
|
1934
|
+
if (options.model && isModelForGateway(options.model, process.env["ANTHROPIC_MODEL"])) {
|
|
1931
1935
|
args.push("--model", resolveModelAlias(options.model));
|
|
1932
1936
|
}
|
|
1933
1937
|
if (options.effort) {
|
package/dist/cli.js
CHANGED
|
@@ -191,7 +191,7 @@ import {
|
|
|
191
191
|
warnOnBrokenChannelCwds,
|
|
192
192
|
workspaceSkillsDir,
|
|
193
193
|
writeSkillFile
|
|
194
|
-
} from "./chunk-
|
|
194
|
+
} from "./chunk-2V33REYC.js";
|
|
195
195
|
import {
|
|
196
196
|
firstReplyBody,
|
|
197
197
|
getThread,
|
|
@@ -18901,7 +18901,7 @@ function codexDir() {
|
|
|
18901
18901
|
return process.env["CODEX_HOME"] || join7(homedir3(), ".codex");
|
|
18902
18902
|
}
|
|
18903
18903
|
function claudeLoggedIn() {
|
|
18904
|
-
if (
|
|
18904
|
+
if (["ANTHROPIC_API_KEY", "ANTHROPIC_AUTH_TOKEN", "CLAUDE_CODE_OAUTH_TOKEN"].some((k) => process.env[k])) return true;
|
|
18905
18905
|
if (existsSync6(join7(claudeDir(), ".credentials.json"))) return true;
|
|
18906
18906
|
try {
|
|
18907
18907
|
const raw = JSON.parse(readFileSync7(join7(homedir3(), ".claude.json"), "utf-8"));
|
|
@@ -19492,7 +19492,7 @@ async function runAuthCmd(args) {
|
|
|
19492
19492
|
|
|
19493
19493
|
// ../api/src/version.ts
|
|
19494
19494
|
import { readFileSync as readFileSync8 } from "fs";
|
|
19495
|
-
var CLI_VERSION = true ? "0.1.
|
|
19495
|
+
var CLI_VERSION = true ? "0.1.48" : devVersion();
|
|
19496
19496
|
function isOlderVersion(a, b) {
|
|
19497
19497
|
const parse = (v) => v.replace(/^v/, "").split("-")[0].split(".").map(Number);
|
|
19498
19498
|
const [pa, pb] = [parse(a), parse(b)];
|
|
@@ -20120,7 +20120,7 @@ function npmEnv(target) {
|
|
|
20120
20120
|
return nodeBin ? { ...process.env, PATH: `${nodeBin}:${process.env.PATH ?? ""}` } : process.env;
|
|
20121
20121
|
}
|
|
20122
20122
|
async function runUpgrade() {
|
|
20123
|
-
const current = "0.1.
|
|
20123
|
+
const current = "0.1.48";
|
|
20124
20124
|
console.log(`Current version: ${current}`);
|
|
20125
20125
|
console.log("Checking for updates...\n");
|
|
20126
20126
|
try {
|
|
@@ -32584,6 +32584,7 @@ function registerDataRoutes(api, agent = {}) {
|
|
|
32584
32584
|
return c.json({
|
|
32585
32585
|
online: !paused,
|
|
32586
32586
|
cliVersion,
|
|
32587
|
+
pinnedModel: agent.getHostPinnedModel?.(getProfile()) ?? null,
|
|
32587
32588
|
selfUpgrade,
|
|
32588
32589
|
...outdated ? { latestCliVersion: latest2 } : {}
|
|
32589
32590
|
});
|
|
@@ -38183,7 +38184,8 @@ function localAgentCallbacks(chatAgent) {
|
|
|
38183
38184
|
linkProjectFolders: (slug, items) => linkProjectFolders(slug, items),
|
|
38184
38185
|
sessionImportRequest: (req) => handleSessionImportRequest(req),
|
|
38185
38186
|
isHostOnline: () => true,
|
|
38186
|
-
getHostCliVersion: () => CLI_VERSION
|
|
38187
|
+
getHostCliVersion: () => CLI_VERSION,
|
|
38188
|
+
getHostPinnedModel: () => process.env["ANTHROPIC_MODEL"] || null
|
|
38187
38189
|
};
|
|
38188
38190
|
}
|
|
38189
38191
|
var HOST_CONFIG_PUSH_INTERVAL_MS = 6e4;
|
|
@@ -38238,7 +38240,11 @@ function connectHostSocket(url, callbacks, onAuthenticated, onWorkspaces) {
|
|
|
38238
38240
|
if (!msg) return;
|
|
38239
38241
|
if (msg.type === "challenge") {
|
|
38240
38242
|
const signature = signRaw(null, Buffer.from(msg.nonce, "base64"), privateKey).toString("base64");
|
|
38241
|
-
const
|
|
38243
|
+
const pinnedModel = process.env["ANTHROPIC_MODEL"];
|
|
38244
|
+
const version = {
|
|
38245
|
+
...CLI_VERSION ? { cliVersion: CLI_VERSION } : {},
|
|
38246
|
+
...pinnedModel ? { pinnedModel } : {}
|
|
38247
|
+
};
|
|
38242
38248
|
send(ws, deviceId ? { type: "auth", signature, deviceId, ...version } : { type: "auth", signature, ...version });
|
|
38243
38249
|
return;
|
|
38244
38250
|
}
|
|
@@ -38852,6 +38858,11 @@ async function provisionChannels(specs) {
|
|
|
38852
38858
|
console.log(` channel "${spec.name}" exists`);
|
|
38853
38859
|
continue;
|
|
38854
38860
|
}
|
|
38861
|
+
if (spec.name === "general") {
|
|
38862
|
+
await ensureGeneralChannel();
|
|
38863
|
+
console.log(' channel "general" created (default)');
|
|
38864
|
+
continue;
|
|
38865
|
+
}
|
|
38855
38866
|
const cwd = expandPath(spec.cwd);
|
|
38856
38867
|
if (!existsSync36(cwd)) {
|
|
38857
38868
|
mkdirSync14(cwd, { recursive: true });
|
|
@@ -39072,7 +39083,7 @@ async function main() {
|
|
|
39072
39083
|
break;
|
|
39073
39084
|
case "-v":
|
|
39074
39085
|
case "--version":
|
|
39075
|
-
printRaw("0.1.
|
|
39086
|
+
printRaw("0.1.48");
|
|
39076
39087
|
break;
|
|
39077
39088
|
case "-h":
|
|
39078
39089
|
case "--help":
|
package/dist/index.js
CHANGED
|
@@ -3,7 +3,7 @@ import { createRequire as __flyspaceCreateRequire } from 'node:module';
|
|
|
3
3
|
const require = __flyspaceCreateRequire(import.meta.url);
|
|
4
4
|
import {
|
|
5
5
|
startServer
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-2V33REYC.js";
|
|
7
7
|
import "./chunk-F5CXKDZV.js";
|
|
8
8
|
export {
|
|
9
9
|
startServer
|