@openape/apes 1.28.2 → 1.28.3
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.js
CHANGED
|
@@ -5689,6 +5689,16 @@ function getUserMode() {
|
|
|
5689
5689
|
return "human";
|
|
5690
5690
|
return "agent";
|
|
5691
5691
|
}
|
|
5692
|
+
var writeRealStdout = (s) => {
|
|
5693
|
+
process.stdout.write(s);
|
|
5694
|
+
};
|
|
5695
|
+
function routeDiagnosticsToStderrForWrappedAgentRun() {
|
|
5696
|
+
const original = process.stdout.write.bind(process.stdout);
|
|
5697
|
+
writeRealStdout = (s) => {
|
|
5698
|
+
original(s);
|
|
5699
|
+
};
|
|
5700
|
+
process.stdout.write = ((chunk, ...rest) => process.stderr.write(chunk, ...rest));
|
|
5701
|
+
}
|
|
5692
5702
|
function getAsyncExitCode() {
|
|
5693
5703
|
const envValue = process.env.APES_ASYNC_EXIT_CODE;
|
|
5694
5704
|
if (envValue !== void 0 && envValue !== "") {
|
|
@@ -5797,6 +5807,9 @@ var runCommand = defineCommand46({
|
|
|
5797
5807
|
},
|
|
5798
5808
|
async run({ rawArgs, args }) {
|
|
5799
5809
|
const wrappedCommand = extractWrappedCommand(rawArgs ?? []);
|
|
5810
|
+
if (wrappedCommand.length > 0 && getUserMode() === "agent") {
|
|
5811
|
+
routeDiagnosticsToStderrForWrappedAgentRun();
|
|
5812
|
+
}
|
|
5800
5813
|
if (args.shell && wrappedCommand.length > 0) {
|
|
5801
5814
|
await runShellMode(wrappedCommand, args);
|
|
5802
5815
|
return;
|
|
@@ -6126,7 +6139,7 @@ function executeWithGrantToken(opts) {
|
|
|
6126
6139
|
throw new CliExit(exitCode);
|
|
6127
6140
|
}
|
|
6128
6141
|
} else {
|
|
6129
|
-
|
|
6142
|
+
writeRealStdout(token);
|
|
6130
6143
|
}
|
|
6131
6144
|
}
|
|
6132
6145
|
async function findReusableAudienceGrant(opts) {
|
|
@@ -6716,7 +6729,7 @@ var mcpCommand = defineCommand52({
|
|
|
6716
6729
|
if (transport !== "stdio" && transport !== "sse") {
|
|
6717
6730
|
throw new Error('Transport must be "stdio" or "sse"');
|
|
6718
6731
|
}
|
|
6719
|
-
const { startMcpServer } = await import("./server-
|
|
6732
|
+
const { startMcpServer } = await import("./server-5N27B7F2.js");
|
|
6720
6733
|
await startMcpServer(transport, port);
|
|
6721
6734
|
}
|
|
6722
6735
|
});
|
|
@@ -7354,7 +7367,7 @@ async function bestEffortGrantCount(idp) {
|
|
|
7354
7367
|
}
|
|
7355
7368
|
}
|
|
7356
7369
|
async function runHealth(args) {
|
|
7357
|
-
const version = true ? "1.28.
|
|
7370
|
+
const version = true ? "1.28.3" : "0.0.0";
|
|
7358
7371
|
const auth = loadAuth();
|
|
7359
7372
|
if (!auth) {
|
|
7360
7373
|
throw new CliError("Not logged in. Run `apes login` first.", 1);
|
|
@@ -7627,10 +7640,10 @@ if (shellRewrite) {
|
|
|
7627
7640
|
if (shellRewrite.action === "rewrite") {
|
|
7628
7641
|
process.argv = shellRewrite.argv;
|
|
7629
7642
|
} else if (shellRewrite.action === "version") {
|
|
7630
|
-
console.log(`ape-shell ${"1.28.
|
|
7643
|
+
console.log(`ape-shell ${"1.28.3"} (OpenApe DDISA shell wrapper)`);
|
|
7631
7644
|
process.exit(0);
|
|
7632
7645
|
} else if (shellRewrite.action === "help") {
|
|
7633
|
-
console.log(`ape-shell ${"1.28.
|
|
7646
|
+
console.log(`ape-shell ${"1.28.3"} \u2014 OpenApe DDISA shell wrapper`);
|
|
7634
7647
|
console.log("");
|
|
7635
7648
|
console.log("Usage:");
|
|
7636
7649
|
console.log(" ape-shell Start interactive grant-mediated REPL");
|
|
@@ -7688,7 +7701,7 @@ var configCommand = defineCommand64({
|
|
|
7688
7701
|
var main = defineCommand64({
|
|
7689
7702
|
meta: {
|
|
7690
7703
|
name: "apes",
|
|
7691
|
-
version: "1.28.
|
|
7704
|
+
version: "1.28.3",
|
|
7692
7705
|
description: "Unified CLI for OpenApe"
|
|
7693
7706
|
},
|
|
7694
7707
|
subCommands: {
|
|
@@ -7746,7 +7759,7 @@ async function maybeRefreshAuth() {
|
|
|
7746
7759
|
}
|
|
7747
7760
|
}
|
|
7748
7761
|
await maybeRefreshAuth();
|
|
7749
|
-
await maybeWarnStaleVersion("1.28.
|
|
7762
|
+
await maybeWarnStaleVersion("1.28.3").catch(() => {
|
|
7750
7763
|
});
|
|
7751
7764
|
runMain(main).catch((err) => {
|
|
7752
7765
|
if (err instanceof CliExit) {
|