claude-session-continuity-mcp 1.17.1 → 1.17.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/README.md CHANGED
@@ -11,9 +11,11 @@
11
11
 
12
12
  ![Session continuity demo — Claude auto-restores your project context on session start](assets/demo.gif)
13
13
 
14
+ > **Name note:** the package is called `claude-session-continuity-mcp` for historical reasons, but it is **agent-agnostic** — Claude Code, Codex CLI, and Gemini CLI are first-class and share one local memory.
15
+
14
16
  ## The Problem
15
17
 
16
- Every new Claude Code session:
18
+ Every new session — whether you're in Claude Code, Codex CLI, or Gemini CLI:
17
19
 
18
20
  ```
19
21
  "This is a Next.js 15 project with App Router..."
@@ -96,7 +98,7 @@ Use search when you want to *look something up*. Use this when you want your con
96
98
 
97
99
  ---
98
100
 
99
- ## Works with Codex CLI too (v1.16.0+)
101
+ ## Codex CLI support (v1.16.0+)
100
102
 
101
103
  Beyond Claude Code, this also supports **OpenAI Codex CLI**. If `~/.codex` exists,
102
104
  the installer registers the same hooks in `~/.codex/hooks.json` (SessionStart,
@@ -114,7 +116,7 @@ interface (it can be null at startup), so host detection uses an installer-injec
114
116
 
115
117
  ---
116
118
 
117
- ## Works with Gemini CLI too (v1.17.0+)
119
+ ## Gemini CLI support (v1.17.0+)
118
120
 
119
121
  Also supports **Google Gemini CLI**. If `~/.gemini` exists, the installer registers
120
122
  the hooks in `~/.gemini/settings.json` (SessionStart, BeforeAgent, PreCompress,
package/dist/index.js CHANGED
@@ -20,7 +20,8 @@ import { ListToolsRequestSchema, CallToolRequestSchema, ListPromptsRequestSchema
20
20
  import * as fs from 'fs/promises';
21
21
  import { mkdirSync, existsSync } from 'fs';
22
22
  import * as path from 'path';
23
- import { execSync } from 'child_process';
23
+ import { execSync, spawnSync } from 'child_process';
24
+ import { fileURLToPath } from 'url';
24
25
  import Database from 'better-sqlite3';
25
26
  import { tokenizeQuery, buildFtsQuery } from './utils/tokenize.js';
26
27
  // @xenova/transformers - 동적 import (sharp 의존성 문제 방지)
@@ -2173,4 +2174,25 @@ async function main() {
2173
2174
  await server.connect(transport);
2174
2175
  console.error('Project Manager MCP v5 started (24 tools + 3 prompts for auto-injection)');
2175
2176
  }
2176
- main().catch(console.error);
2177
+ // CLI subcommands (install/uninstall/status/help) → delegate to the hooks installer.
2178
+ // Without this, `npx claude-session-continuity-mcp install` runs the default bin
2179
+ // (the MCP server), which ignores the arg and hangs on stdio — looks broken to users.
2180
+ const CLI_COMMANDS = new Set(['install', 'uninstall', 'remove', 'status']);
2181
+ const cliArg = process.argv[2];
2182
+ if (cliArg && (CLI_COMMANDS.has(cliArg) || cliArg === 'help' || cliArg === '--help' || cliArg === '-h')) {
2183
+ if (cliArg === 'help' || cliArg === '--help' || cliArg === '-h') {
2184
+ console.log('Usage: npx claude-session-continuity-mcp [install|uninstall|status]');
2185
+ console.log(' install Register lifecycle hooks for Claude Code / Codex CLI / Gemini CLI');
2186
+ console.log(' uninstall Remove the hooks');
2187
+ console.log(' status Show installed hooks');
2188
+ console.log(' (no arg) Start the MCP server (stdio) — used by the hook runtime');
2189
+ process.exit(0);
2190
+ }
2191
+ const here = path.dirname(fileURLToPath(import.meta.url));
2192
+ const installerPath = path.join(here, 'hooks', 'install.js');
2193
+ const result = spawnSync(process.execPath, [installerPath, cliArg], { stdio: 'inherit' });
2194
+ process.exit(result.status ?? 0);
2195
+ }
2196
+ else {
2197
+ main().catch(console.error);
2198
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "claude-session-continuity-mcp",
3
- "version": "1.17.1",
3
+ "version": "1.17.2",
4
4
  "description": "Session continuity for Claude Code, OpenAI Codex CLI & Google Gemini CLI - never re-explain your project again. 100% local, zero config, auto context injection.",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",