nofax 0.2.20 → 0.2.21

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nofax",
3
- "version": "0.2.20",
3
+ "version": "0.2.21",
4
4
  "mcpName": "io.github.AKzar1el/nofax",
5
5
  "description": "Human-in-the-loop approvals and notifications for AI coding agents via CLI, MCP, and agent hooks.",
6
6
  "type": "module",
package/src/cli.mjs CHANGED
@@ -196,7 +196,16 @@ export async function runCli(args, overrides = {}) {
196
196
  if (command === 'hook') {
197
197
  const adapter = args[1];
198
198
  if (!adapter) throw new Error('NOFAX_HOOK_REQUIRED');
199
- return runHook(adapter, deps);
199
+ try {
200
+ return await runHook(adapter, deps);
201
+ } catch (error) {
202
+ if (adapter === 'gemini') {
203
+ deps.stderr.write(`nofax: ${error.message}\n`);
204
+ writeJson(deps.stdout, { decision: 'ask' });
205
+ return 0;
206
+ }
207
+ throw error;
208
+ }
200
209
  }
201
210
 
202
211
  throw new Error(`NOFAX_UNKNOWN_COMMAND:${command}`);
@@ -74,7 +74,7 @@ const LIST_PENDING_OUTPUT_SCHEMA = z.object({
74
74
 
75
75
  export function buildMcpServer({ handlers = createMcpToolHandlers() } = {}) {
76
76
  const server = new McpServer(
77
- { name: 'nofax', version: '0.2.20' },
77
+ { name: 'nofax', version: '0.2.21' },
78
78
  { instructions: SERVER_INSTRUCTIONS }
79
79
  );
80
80