@aerostack/gateway 0.13.1 → 0.13.2
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/hook-server.js +4 -3
- package/package.json +1 -1
package/dist/hook-server.js
CHANGED
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
import { createServer } from 'node:http';
|
|
13
13
|
import { readFile, writeFile, appendFile, stat } from 'node:fs/promises';
|
|
14
14
|
import { watch } from 'node:fs';
|
|
15
|
-
import { homedir
|
|
15
|
+
import { homedir } from 'node:os';
|
|
16
16
|
import { join } from 'node:path';
|
|
17
17
|
import { info, warn, debug } from './logger.js';
|
|
18
18
|
// ─── Config ───────────────────────────────────────────────────────────────
|
|
@@ -266,8 +266,9 @@ export function stopHookServer() {
|
|
|
266
266
|
}
|
|
267
267
|
// ─── Claude Code hook management ──────────────────────────────────────────
|
|
268
268
|
const HOOK_MARKER = '/* aerostack-guardian-hook */';
|
|
269
|
-
/** Path where hook events are written as JSONL (one JSON object per line).
|
|
270
|
-
|
|
269
|
+
/** Path where hook events are written as JSONL (one JSON object per line).
|
|
270
|
+
* Use /tmp/ explicitly — macOS tmpdir() returns /var/folders/... which differs between processes. */
|
|
271
|
+
export const HOOK_EVENTS_FILE = '/tmp/aerostack-guardian-events.jsonl';
|
|
271
272
|
export async function installClaudeHook(_port) {
|
|
272
273
|
const settingsPath = join(homedir(), '.claude', 'settings.json');
|
|
273
274
|
try {
|