@node9/proxy 1.1.2 → 1.1.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
@@ -4297,6 +4297,19 @@ data: ${JSON.stringify({
4297
4297
  data: ${JSON.stringify(readPersistentDecisions())}
4298
4298
 
4299
4299
  `);
4300
+ const activeShields = readActiveShields();
4301
+ res.write(
4302
+ `event: shields-status
4303
+ data: ${JSON.stringify({
4304
+ shields: Object.values(SHIELDS).map((s) => ({
4305
+ name: s.name,
4306
+ description: s.description,
4307
+ active: activeShields.includes(s.name)
4308
+ }))
4309
+ })}
4310
+
4311
+ `
4312
+ );
4300
4313
  for (const item of activityRing) {
4301
4314
  res.write(`event: ${item.event}
4302
4315
  data: ${JSON.stringify(item.data)}
@@ -6696,9 +6709,9 @@ var HOOK_BASED_AGENTS = {
6696
6709
  };
6697
6710
  program.argument("[command...]", "The agent command to run (e.g., gemini)").action(async (commandArgs) => {
6698
6711
  if (commandArgs && commandArgs.length > 0) {
6699
- const firstArg = commandArgs[0].toLowerCase();
6700
- if (HOOK_BASED_AGENTS[firstArg] !== void 0) {
6701
- const target = HOOK_BASED_AGENTS[firstArg];
6712
+ const firstArg2 = commandArgs[0].toLowerCase();
6713
+ if (HOOK_BASED_AGENTS[firstArg2] !== void 0) {
6714
+ const target = HOOK_BASED_AGENTS[firstArg2];
6702
6715
  console.error(
6703
6716
  import_chalk6.default.yellow(`
6704
6717
  \u26A0\uFE0F Node9 proxy mode does not support "${target}" directly.`)
@@ -6926,4 +6939,9 @@ process.on("unhandledRejection", (reason) => {
6926
6939
  process.exit(1);
6927
6940
  }
6928
6941
  });
6942
+ var knownSubcommands = new Set(program.commands.map((c) => c.name()));
6943
+ var firstArg = process.argv[2];
6944
+ if (firstArg && firstArg !== "--" && !firstArg.startsWith("-") && !knownSubcommands.has(firstArg)) {
6945
+ process.argv.splice(2, 0, "--");
6946
+ }
6929
6947
  program.parse();
package/dist/cli.mjs CHANGED
@@ -4284,6 +4284,19 @@ data: ${JSON.stringify({
4284
4284
  data: ${JSON.stringify(readPersistentDecisions())}
4285
4285
 
4286
4286
  `);
4287
+ const activeShields = readActiveShields();
4288
+ res.write(
4289
+ `event: shields-status
4290
+ data: ${JSON.stringify({
4291
+ shields: Object.values(SHIELDS).map((s) => ({
4292
+ name: s.name,
4293
+ description: s.description,
4294
+ active: activeShields.includes(s.name)
4295
+ }))
4296
+ })}
4297
+
4298
+ `
4299
+ );
4287
4300
  for (const item of activityRing) {
4288
4301
  res.write(`event: ${item.event}
4289
4302
  data: ${JSON.stringify(item.data)}
@@ -6675,9 +6688,9 @@ var HOOK_BASED_AGENTS = {
6675
6688
  };
6676
6689
  program.argument("[command...]", "The agent command to run (e.g., gemini)").action(async (commandArgs) => {
6677
6690
  if (commandArgs && commandArgs.length > 0) {
6678
- const firstArg = commandArgs[0].toLowerCase();
6679
- if (HOOK_BASED_AGENTS[firstArg] !== void 0) {
6680
- const target = HOOK_BASED_AGENTS[firstArg];
6691
+ const firstArg2 = commandArgs[0].toLowerCase();
6692
+ if (HOOK_BASED_AGENTS[firstArg2] !== void 0) {
6693
+ const target = HOOK_BASED_AGENTS[firstArg2];
6681
6694
  console.error(
6682
6695
  chalk6.yellow(`
6683
6696
  \u26A0\uFE0F Node9 proxy mode does not support "${target}" directly.`)
@@ -6905,4 +6918,9 @@ process.on("unhandledRejection", (reason) => {
6905
6918
  process.exit(1);
6906
6919
  }
6907
6920
  });
6921
+ var knownSubcommands = new Set(program.commands.map((c) => c.name()));
6922
+ var firstArg = process.argv[2];
6923
+ if (firstArg && firstArg !== "--" && !firstArg.startsWith("-") && !knownSubcommands.has(firstArg)) {
6924
+ process.argv.splice(2, 0, "--");
6925
+ }
6908
6926
  program.parse();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@node9/proxy",
3
- "version": "1.1.2",
3
+ "version": "1.1.3",
4
4
  "description": "The Sudo Command for AI Agents. Execution Security for Claude Code & MCP.",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",