prjct-cli 1.53.0 → 1.54.0

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/CHANGELOG.md CHANGED
@@ -1,5 +1,21 @@
1
1
  # Changelog
2
2
 
3
+ ## [1.54.0] - 2026-04-05
4
+
5
+ ### Features
6
+
7
+ - multi-agent parallel sessions with auto-worktree isolation (#237)
8
+
9
+ ### Bug Fixes
10
+
11
+ - guard feedback array spreads preventing s.push crash (#236)
12
+
13
+
14
+ ## [1.53.1] - 2026-04-04
15
+
16
+ ### Docs
17
+ - update README with full command reference, Windsurf support, MCP server, parallel sessions, code intelligence, web dashboard, cloud sync, and architecture overview
18
+
3
19
  ## [1.52.4] - 2026-03-26
4
20
 
5
21
  ### Bug Fixes
package/README.md CHANGED
@@ -2,13 +2,14 @@
2
2
 
3
3
  **Context layer for AI coding agents.**
4
4
 
5
- Works with Claude Code, Gemini CLI, OpenAI Codex, Antigravity, Cursor IDE, and more.
5
+ Works with Claude Code, Gemini CLI, OpenAI Codex, Antigravity, Cursor IDE, Windsurf, and more.
6
6
 
7
7
  [![Claude Code](https://img.shields.io/badge/Claude%20Code-Ready-6366f1)](CLAUDE.md)
8
8
  [![Gemini CLI](https://img.shields.io/badge/Gemini%20CLI-Ready-4285F4)]()
9
9
  [![OpenAI Codex](https://img.shields.io/badge/OpenAI%20Codex-Ready-10A37F)]()
10
10
  [![Antigravity](https://img.shields.io/badge/Antigravity-Ready-EA4335)]()
11
11
  [![Cursor IDE](https://img.shields.io/badge/Cursor%20IDE-Ready-00D4AA)]()
12
+ [![Windsurf](https://img.shields.io/badge/Windsurf-Ready-7C3AED)]()
12
13
  [![npm](https://img.shields.io/npm/v/prjct-cli)](https://www.npmjs.com/package/prjct-cli)
13
14
 
14
15
  ## What is prjct?
@@ -17,18 +18,18 @@ prjct gives AI coding agents the context they need about your project. It mainta
17
18
 
18
19
  ```
19
20
  Your AI Agent prjct
20
- (Claude/Gemini/Antigravity/Cursor)
21
-
22
- "What am I working on?"
23
- ────────────────────────────────►
24
- Reads project context
25
- Task: "Add user auth"
26
- Branch: feature/auth
27
- Subtask 2/5: API routes
28
- ◄────────────────────────────────
29
-
30
-
31
- Writes code with full context
21
+ (Claude/Gemini/Codex/Cursor/Windsurf) |
22
+ | |
23
+ | "What am I working on?" |
24
+ | --------------------------------> |
25
+ | | Reads project context
26
+ | Task: "Add user auth" |
27
+ | Branch: feature/auth |
28
+ | Subtask 2/5: API routes |
29
+ | <-------------------------------- |
30
+ | |
31
+ v |
32
+ Writes code with full context |
32
33
  ```
33
34
 
34
35
  ## Install
@@ -52,232 +53,245 @@ prjct init
52
53
  # 3. Open in Claude Code, Gemini CLI, or Codex and use:
53
54
  p. sync # Analyze project
54
55
  p. task "add user auth" # Start a task
55
- p. done # Complete subtask
56
+ p. done # Complete task
56
57
  p. ship # Ship with PR
57
58
  ```
58
59
 
59
- > **Note (Codex):** `prjct sync` generates `AGENTS.md` for project-level Codex context, `prjct start` installs `~/.codex/skills/prjct/SKILL.md`, and `prjct doctor` validates the `p.` router health.
60
-
61
- ### Google Antigravity
62
-
63
- ```bash
64
- # 1. One-time global setup (installs prjct as a skill)
65
- prjct start
66
-
67
- # 2. Initialize your project
68
- cd my-project
69
- prjct init
70
-
71
- # 3. Open in Antigravity and use:
72
- p. sync # Analyze project
73
- p. task "add user auth" # Start a task
74
- p. done # Complete subtask
75
- p. ship # Ship with PR
76
- ```
77
-
78
- > **Note:** prjct integrates as a Skill (not MCP server) for zero-overhead operation.
79
-
80
- ### Cursor IDE
60
+ ### Cursor IDE / Windsurf
81
61
 
82
62
  ```bash
83
63
  # 1. Initialize your project (no global setup needed)
84
64
  cd my-project
85
65
  prjct init
86
66
 
87
- # 2. Open in Cursor and use:
67
+ # 2. Open in Cursor or Windsurf and use:
88
68
  /sync # Analyze project
89
69
  /task "add user auth" # Start a task
90
- /done # Complete subtask
70
+ /done # Complete task
91
71
  /ship # Ship with PR
92
72
  ```
93
73
 
94
- > **Note:** Cursor uses `/command` syntax. Commands are installed per-project in `.cursor/commands/`. If deleted, run `/sync` to regenerate.
74
+ > Cursor uses `.cursor/commands/`, Windsurf uses `.windsurf/` with YAML frontmatter. Run `/sync` to regenerate if deleted.
95
75
 
96
76
  ### Core Workflow
97
77
 
98
78
  ```
99
- Claude/Gemini/Codex/Antigravity: p. sync p. task "..." [code] p. done p. ship
100
- Cursor: /sync /task "..." [code] /done /ship
79
+ Claude/Gemini/Codex: p. sync -> p. task "..." -> [code] -> p. done -> p. ship
80
+ Cursor/Windsurf: /sync -> /task "..." -> [code] -> /done -> /ship
101
81
  ```
102
82
 
103
83
  ## How It Works
104
84
 
105
- | Component | Claude Code | Gemini CLI | OpenAI Codex | Antigravity | Cursor IDE |
106
- |-----------|-------------|------------|--------------|-------------|------------|
107
- | Router | `~/.claude/commands/p.md` | `~/.gemini/commands/p.toml` | Skill (`~/.codex/skills/prjct/SKILL.md`) | Skill | `.cursor/commands/*.md` |
108
- | Config | `~/.claude/CLAUDE.md` | `~/.gemini/GEMINI.md` | `AGENTS.md` | `~/.gemini/antigravity/skills/prjct/` | `.cursor/rules/prjct.mdc` |
109
- | Storage | `~/.prjct-cli/projects/` | `~/.prjct-cli/projects/` | `~/.prjct-cli/projects/` | `~/.prjct-cli/projects/` | `~/.prjct-cli/projects/` |
110
- | Scope | Global | Global | Project + Global skill | Global | Per-project |
111
- | Syntax | `p. command` | `p. command` | `p. command` | `p. command` | `/command` |
85
+ | Component | Claude Code | Gemini CLI | OpenAI Codex | Antigravity | Cursor IDE | Windsurf |
86
+ |-----------|-------------|------------|--------------|-------------|------------|----------|
87
+ | Router | `~/.claude/commands/p.md` | `~/.gemini/commands/p.toml` | `~/.codex/skills/prjct/SKILL.md` | Skill | `.cursor/commands/*.md` | `.windsurf/*.md` |
88
+ | Config | `~/.claude/CLAUDE.md` | `~/.gemini/GEMINI.md` | `AGENTS.md` | `~/.gemini/antigravity/skills/prjct/` | `.cursor/rules/prjct.mdc` | `.windsurf/` (YAML) |
89
+ | Storage | `~/.prjct-cli/projects/` | `~/.prjct-cli/projects/` | `~/.prjct-cli/projects/` | `~/.prjct-cli/projects/` | `~/.prjct-cli/projects/` | `~/.prjct-cli/projects/` |
90
+ | Syntax | `p. command` | `p. command` | `p. command` | `p. command` | `/command` | `/command` |
112
91
 
113
- All agents share the same project storage, so you can switch between them freely.
92
+ All agents share the same SQLite-backed project storage, so you can switch between them freely.
114
93
 
115
94
  ## Commands
116
95
 
117
- | Claude/Gemini | Cursor | Description |
118
- |---------------|--------|-------------|
119
- | `p. sync` | `/sync` | Analyze project, generate domain agents |
96
+ ### Core Workflow
97
+
98
+ | Claude/Gemini | Cursor/Windsurf | Description |
99
+ |---------------|-----------------|-------------|
100
+ | `p. sync` | `/sync` | Analyze project, build indexes, generate skills |
120
101
  | `p. task "desc"` | `/task "desc"` | Start task with auto-classification |
121
- | `p. done` | `/done` | Complete current subtask |
102
+ | `p. done` | `/done` | Complete current task |
122
103
  | `p. ship "name"` | `/ship "name"` | Ship feature with PR + version bump |
123
104
  | `p. pause` | `/pause` | Pause current task |
124
105
  | `p. resume` | `/resume` | Resume paused task |
125
- | `p. bug "desc"` | `/bug "desc"` | Report a bug |
126
- | `p. linear` | - | Linear integration |
127
- | `p. github` | - | GitHub Issues integration |
106
+ | `p. next` | `/next` | Show priority queue or roadmap |
107
+ | `p. bug "desc"` | `/bug "desc"` | Report and track a bug |
108
+ | `p. idea "desc"` | `/idea "desc"` | Transform idea into technical architecture |
109
+ | `p. spec` | `/spec` | Create detailed spec for complex features |
110
+ | `p. dash` | `/dash` | Unified dashboard (status, progress, roadmap) |
111
+ | `p. suggest` | `/suggest` | Smart recommendations based on project state |
128
112
 
129
- ## Task History
113
+ ### Analysis & Performance
130
114
 
131
- prjct automatically tracks your completed tasks to help AI agents learn from patterns and make better decisions across sessions.
132
-
133
- ### How It Works
115
+ | Command | Description |
116
+ |---------|-------------|
117
+ | `p. status` | Check if context is stale |
118
+ | `p. perf` | Performance dashboard (startup, memory, context) |
119
+ | `p. velocity` | Sprint-based velocity with trend detection |
120
+ | `p. tokens <in> <out>` | Record token usage on active task |
121
+ | `p. stats` | Value dashboard (token savings, impact) |
122
+ | `p. sessions` | Show recent sessions across projects |
123
+ | `p. diff` | Diff between draft and sealed analysis |
124
+ | `p. seal` | Seal analysis with commit-hash signature |
125
+ | `p. verify` | Verify integrity (cryptographic or `--semantic`) |
126
+ | `p. rollback` | Rollback to previous sealed analysis |
127
+
128
+ ### Advanced
134
129
 
135
- When you complete a task (`p. done` / `/done`), prjct stores:
136
- - Task description and classification (feature, bug, improvement, chore)
137
- - Start and completion timestamps
138
- - Number of subtasks and their summaries
139
- - Git branch name and Linear issue ID (if linked)
140
- - PR URL (if shipped)
130
+ | Command | Description |
131
+ |---------|-------------|
132
+ | `p. design` | Design system architecture, APIs, components |
133
+ | `p. enrich "issue"` | Build enrichment context for an issue |
134
+ | `p. workflow` | Configure workflow hooks via natural language |
135
+ | `p. git` | Smart git operations with context |
136
+ | `p. test` | Run tests with auto-fix |
137
+ | `p. undo` / `p. redo` | Snapshot-based undo/redo |
138
+ | `p. recover` | Recover abandoned session with context |
139
+ | `p. linear` | Linear integration via MCP |
140
+ | `p. jira` | Jira integration via MCP |
141
141
 
142
- This history is:
143
- - **Bounded**: Maximum 20 entries with FIFO (First-In-First-Out) eviction
144
- - **Contextual**: Filtered by task type when starting similar work
145
- - **Persistent**: Survives across sessions and agent types
142
+ ### Parallel Agent Sessions
146
143
 
147
- ### Context Injection
144
+ Run multiple AI agents on different tasks simultaneously, each in an isolated git worktree.
148
145
 
149
- Task history is automatically injected into the AI agent's context:
150
- - When **starting a task**: Shows 3 most recent tasks of the same type (e.g., recent bug fixes when starting a new bug)
151
- - When **idle**: Shows 5 most recent tasks across all types
152
- - **Purpose**: Helps agents identify patterns, avoid repeating mistakes, and build on previous solutions
146
+ | Command | Description |
147
+ |---------|-------------|
148
+ | `p. parallel spawn "task"` | Spawn agent in isolated worktree |
149
+ | `p. parallel status` | Show all active agents |
150
+ | `p. parallel join` | Merge completed branches back |
151
+ | `p. worktree create` | Create worktree (auto-copies .env, installs deps) |
152
+ | `p. worktree list` | List active worktrees |
153
+ | `p. worktree remove` | Clean up completed worktrees |
154
+ | `p. conductor init` | Scaffold Conductor.build integration |
153
155
 
154
- ### Accessor Methods (for developers)
156
+ ## CLI Commands
155
157
 
156
- ```typescript
157
- import { stateStorage } from './storage/state-storage'
158
+ Commands you run directly in the terminal (outside your AI agent):
158
159
 
159
- // Get full task history (max 20 entries, newest first)
160
- const history = await stateStorage.getTaskHistory(projectId)
160
+ ```bash
161
+ prjct start # First-time setup wizard
162
+ prjct init # Initialize project
163
+ prjct sync # Analyze project and build indexes
164
+ prjct doctor # Check system health and dependencies
165
+ prjct serve # Start web dashboard (port 3478)
166
+ prjct watch # Auto-sync on file changes
167
+ prjct hooks # Manage git hooks for auto-sync
168
+ prjct context # Smart context filtering tools
169
+ prjct enrich # Prepare issue enrichment context
170
+ prjct linear # Linear MCP gateway
171
+ prjct jira # Jira MCP gateway
172
+ prjct login # Authenticate with prjct cloud (opens browser)
173
+ prjct logout # Sign out from prjct cloud
174
+ prjct update # Update CLI system-wide
175
+ prjct stop # Stop the background daemon
176
+ prjct restart # Restart the background daemon
177
+ prjct uninstall # Complete system removal
178
+ prjct --version # Show version + provider status
179
+ prjct --help # Show help
180
+ ```
161
181
 
162
- // Get most recent completed task
163
- const recent = await stateStorage.getMostRecentTask(projectId)
182
+ ## Code Intelligence
164
183
 
165
- // Get tasks by classification
166
- const bugs = await stateStorage.getTaskHistoryByType(projectId, 'bug')
167
- const features = await stateStorage.getTaskHistoryByType(projectId, 'feature')
168
- ```
184
+ `prjct sync` builds a triple-index system over your codebase:
169
185
 
170
- ## CLI Commands
186
+ | Index | Purpose |
187
+ |-------|---------|
188
+ | **BM25** | Full-text search over file names, symbols, comments |
189
+ | **Import Graph** | Dependency graph with forward and reverse edges |
190
+ | **Git Co-change** | Files that frequently change together |
171
191
 
172
- ```bash
173
- prjct start # First-time setup (Claude/Gemini/Codex skill install)
174
- prjct init # Initialize project (+ AI tool setup)
175
- prjct sync # Analyze project and generate context
176
- prjct verify # Verify analysis integrity (cryptographic)
177
- prjct verify --semantic # Verify analysis consistency (semantic)
178
- prjct --version # Show version + provider status
179
- prjct --help # Show help
180
- ```
192
+ These indexes power file ranking, impact analysis, and related-context suggestions for your AI agent.
181
193
 
182
- ### Analysis Verification
194
+ ## MCP Server
183
195
 
184
- prjct provides two types of analysis verification to ensure data integrity and logical consistency:
196
+ prjct exposes an MCP server with tools that AI agents can call directly:
185
197
 
186
- #### Cryptographic Verification (Default)
187
- ```bash
188
- prjct verify [--json]
189
- ```
198
+ | Category | Tools | Examples |
199
+ |----------|-------|---------|
200
+ | **Memory** | 8 | Save/search memories, record decisions, manage preferences |
201
+ | **Session** | 4 | Start sessions, recover context, record outcomes |
202
+ | **Code Intelligence** | 3 | Impact analysis, related files, staleness check |
203
+ | **Workflow** | 4 | Task and session management |
204
+ | **File** | 3 | File reading and filtering |
205
+ | **Pattern** | 3 | Pattern extraction and matching |
206
+ | **Review** | 3 | Code review context |
207
+ | **Project** | 4 | Project-level operations |
190
208
 
191
- Verifies the integrity of sealed analysis results using cryptographic signatures. This ensures:
192
- - Analysis data hasn't been tampered with
193
- - Sealed analysis matches the original analysis
194
- - Hash signatures are valid
209
+ The memory system uses FTS5 full-text search, tracks decision outcomes ("did this work before?"), and auto-captures patterns during normal workflow.
195
210
 
196
- **When to use:** After sealing an analysis (`prjct seal`) to confirm data integrity.
211
+ ## Web Dashboard
197
212
 
198
- #### Semantic Verification (PRJ-270)
199
213
  ```bash
200
- prjct verify --semantic [--json]
214
+ prjct serve
201
215
  ```
202
216
 
203
- Validates that analysis results match the actual project state. This checks:
204
- - ✓ **Frameworks** exist in `package.json` dependencies
205
- - ✓ **Languages** match actual file extensions (.ts → TypeScript)
206
- - ✓ **Pattern locations** reference real files in the project
207
- - ✓ **File count** is accurate (within 10% tolerance)
208
- - ✓ **Anti-pattern files** exist when referenced
217
+ Starts an HTTP server on port 3478 with:
209
218
 
210
- **When to use:** Before sealing an analysis to catch logical inconsistencies or after project changes to validate analysis accuracy.
219
+ - REST API for project state, task queue, ideas, roadmap, shipped features
220
+ - SSE (Server-Sent Events) for real-time updates
221
+ - Status bar endpoint for IDE integration (`/api/status-bar/compact`)
222
+ - Global statistics across all projects
211
223
 
212
- **Example output:**
213
- ```
214
- Semantic Verification Report
215
- ────────────────────────────
216
- ✓ Framework verification: passed (2 frameworks validated)
217
- ✓ Language verification: passed (1 language validated)
218
- ✓ Pattern locations: passed (12 patterns verified)
219
- ✓ File count verification: passed (324 files, within tolerance)
220
- ✓ Anti-pattern files: passed (3 anti-patterns verified)
221
-
222
- Result: PASSED (5/5 checks)
223
- Total time: 145ms
224
- ```
225
-
226
- Both verification modes support `--json` flag for programmatic use.
224
+ Built with Hono, supports both Bun and Node.js runtimes.
227
225
 
228
- ## Environment Variables
226
+ ## Cloud Sync
229
227
 
230
- ### Configuration
228
+ ```bash
229
+ prjct login # Browser-based OTP authentication
230
+ prjct sync # Bidirectional push/pull with prjct cloud
231
+ ```
231
232
 
232
- | Variable | Default | Description |
233
- |----------|---------|-------------|
234
- | `PRJCT_CLI_HOME` | `~/.prjct-cli` | Override global storage location. Useful for tests or sandboxed environments. |
235
- | `PRJCT_DEBUG` | _(unset)_ | Enable debug logging. Values: `1`, `true`, or a log level (`error`, `warn`, `info`, `debug`). |
236
- | `DEBUG` | _(unset)_ | Fallback debug flag (used if `PRJCT_DEBUG` is not set). Values: `1`, `true`, or `prjct`. |
237
- | `CI` | _(unset)_ | Set automatically in CI environments. Skips interactive prompts. |
233
+ Cloud sync enables:
234
+ - Cross-device project state synchronization
235
+ - Event-sourced bidirectional push/pull
236
+ - Automatic sync on task completion
238
237
 
239
- ### Issue Tracker MCP (Linear + Jira)
238
+ ## Issue Tracker Integration
240
239
 
241
240
  Issue trackers are configured via MCP (OAuth in your AI client), not API tokens.
242
241
 
243
- | Command | Description |
244
- |---------|-------------|
245
- | `prjct linear setup` | Configure Linear MCP server in `~/.claude/mcp.json`. |
246
- | `prjct linear status` | Verify Linear MCP config. |
247
- | `prjct linear <sync|list|get|create|update|start|done|comment>` | Delegate Linear operation to MCP tools in your AI client. |
248
- | `prjct jira setup` | Configure Jira MCP server in `~/.claude/mcp.json`. |
249
- | `prjct jira status` | Verify Jira MCP config. |
250
- | `prjct jira <sync|list|get|create|update|start|done|transition|comment>` | Delegate Jira operation to MCP tools in your AI client. |
242
+ ```bash
243
+ # Linear
244
+ prjct linear setup # Configure Linear MCP server
245
+ prjct linear status # Verify config
246
+ # Then use: p. linear sync|list|get|create|update|start|done|comment
247
+
248
+ # Jira
249
+ prjct jira setup # Configure Jira MCP server
250
+ prjct jira status # Verify config
251
+ # Then use: p. jira sync|list|get|create|update|start|done|transition|comment
252
+ ```
251
253
 
252
- ### Agent Detection (Auto-set)
254
+ ## Analysis Verification
253
255
 
254
- These are typically set by the AI agent runtime, not by users:
256
+ ```bash
257
+ prjct verify # Cryptographic: hash signature integrity
258
+ prjct verify --semantic # Semantic: frameworks, languages, file counts match reality
259
+ ```
255
260
 
256
- | Variable | Description |
257
- |----------|-------------|
258
- | `CLAUDE_AGENT` | Set when running inside Claude Code. |
259
- | `ANTHROPIC_CLAUDE` | Alternative Claude environment indicator. |
260
- | `MCP_AVAILABLE` | Set when MCP (Model Context Protocol) is available. |
261
- | `HOME` / `USERPROFILE` | Standard OS home directory (used for path resolution). |
261
+ Both modes support `--json` for programmatic use.
262
262
 
263
- ### Usage Examples
263
+ ## Environment Variables
264
264
 
265
- ```bash
266
- # Enable debug logging
267
- PRJCT_DEBUG=1 prjct sync
265
+ | Variable | Default | Description |
266
+ |----------|---------|-------------|
267
+ | `PRJCT_CLI_HOME` | `~/.prjct-cli` | Override global storage location |
268
+ | `PRJCT_DEBUG` | _(unset)_ | Enable debug logging (`1`, `true`, or log level) |
269
+ | `DEBUG` | _(unset)_ | Fallback debug flag (`1`, `true`, or `prjct`) |
270
+ | `CI` | _(unset)_ | Set in CI environments; skips interactive prompts |
268
271
 
269
- # Use a custom storage location
270
- PRJCT_CLI_HOME=/tmp/prjct-test prjct init
272
+ ## Architecture
271
273
 
272
- # Configure Linear + Jira via MCP
273
- prjct linear setup
274
- prjct jira setup
274
+ ```
275
+ prjct-cli/
276
+ core/
277
+ commands/ # CLI command handlers
278
+ domain/ # BM25, import graph, co-change, velocity
279
+ infrastructure/ # Config, path manager, AI provider detection
280
+ mcp/ # MCP server (48 tools)
281
+ schemas/ # Zod schemas (PRD, model, etc.)
282
+ server/ # Hono HTTP server + SSE
283
+ services/ # Memory, sync, code intel, skills, doctor
284
+ storage/ # SQLite via better-sqlite3
285
+ sync/ # Cloud sync client + event mapping
286
+ types/ # TypeScript type definitions
287
+ utils/ # Shared utilities
288
+ templates/ # Skill templates per editor
275
289
  ```
276
290
 
277
291
  ## Requirements
278
292
 
279
293
  - Node.js 18+ or Bun 1.0+
280
- - One of: Claude Code, Gemini CLI, Antigravity, or Cursor IDE
294
+ - One of: Claude Code, Gemini CLI, OpenAI Codex, Antigravity, Cursor IDE, or Windsurf
281
295
 
282
296
  ## Links
283
297
 
@@ -1781,7 +1781,7 @@ ${X.yellow(`Command '${r}' not found.`)}
1781
1781
 
1782
1782
  Run 'prjct help' to see all available commands.
1783
1783
  `}function Ry(){let r=[];r.push(""),r.push(X.cyan.bold("All Commands")),r.push("");let e=Object.entries(Po).sort((t,s)=>t[1].order-s[1].order);for(let[t,s]of e){let n=Dr.filter(o=>o.group===t);if(n.length!==0){r.push(`${X.bold(s.title)} ${X.dim(`(${n.length} commands)`)}`),r.push(X.dim(s.description)),r.push("");for(let o of n){let i=`p. ${o.name}`.padEnd(18),a=o.description.length>45?`${o.description.slice(0,42)}...`:o.description;r.push(` ${i} ${a}`)}r.push("")}}return r.push(X.dim("Run 'prjct help <command>' for detailed help on a specific command.")),r.push(""),r.join(`
1784
- `)}function zC(r){return r?r==="commands"||r==="all"?Ry():xy(r):Ey()}var Ty,qC,jy=S(()=>{"use strict";fd();ot();Ty=[{name:"start",description:"First-time setup wizard",example:"prjct start"},{name:"init",description:"Initialize project in current directory",example:"prjct init"},{name:"sync",description:"Sync project state and update context files",example:"prjct sync"},{name:"watch",description:"Auto-sync on file changes",example:"prjct watch",options:["--verbose","--debounce=<ms>","--interval=<sec>"]},{name:"hooks",description:"Manage git hooks for auto-sync",example:"prjct hooks install",subcommands:["install","uninstall","status"]},{name:"doctor",description:"Check system health and dependencies",example:"prjct doctor"},{name:"serve",description:"Start web dashboard server",example:"prjct serve [port]"},{name:"context",description:"Smart context filtering tools for AI",example:'prjct context files "add auth"',subcommands:["files","signatures","imports","recent","summary"]},{name:"enrich",description:"Prepare issue enrichment context from local code",example:'prjct enrich "PROJ-123 improve auth flow" --md'},{name:"linear",description:"Linear issue tracker MCP gateway",example:"prjct linear setup",subcommands:["setup","status","sync","list","get","create","update","start","done","comment"]},{name:"jira",description:"Jira issue tracker MCP gateway",example:"prjct jira setup",subcommands:["setup","status","sync","list","get","create","update","start","done","transition","comment"]},{name:"stop",description:"Stop the background daemon",example:"prjct stop",options:["--force"]},{name:"restart",description:"Restart the background daemon",example:"prjct restart"},{name:"uninstall",description:"Complete system removal of prjct",example:"prjct uninstall --backup",options:["--force","--backup","--dry-run","--keep-package"]}],qC=[{flag:"-q, --quiet",description:"Suppress all output (errors to stderr only)"},{flag:"-v, --version",description:"Show version and provider status"},{flag:"-h, --help",description:"Show this help message"}];l(Ey,"formatMainHelp");l(Cy,"formatTerminalCommandHelp");l(Py,"formatAgentCommandHelp");l(xy,"formatCommandHelp");l(Ry,"formatCommandList");l(zC,"getHelp")});var Iy=Uy((YV,JC)=>{JC.exports={name:"prjct-cli",version:"1.53.0",description:"Context layer for AI agents. Project context for Claude Code, Gemini CLI, and more.",main:"dist/bin/prjct.mjs",bin:{prjct:"bin/prjct"},publishConfig:{access:"public",registry:"https://registry.npmjs.org"},scripts:{build:"node scripts/build.js","build:node":"node scripts/build.js",release:"node scripts/release.js","release:patch":"node scripts/release.js patch","release:minor":"node scripts/release.js minor","release:major":"node scripts/release.js major",postinstall:"node scripts/postinstall.js",prepare:"lefthook install","update-commands":`bun -e "const installer = require('./core/infrastructure/command-installer'); installer.syncCommands().then(r => console.log('Commands updated:', r)).catch(e => console.error('Error:', e.message))"`,"install-global":"./scripts/install.sh",update:"./scripts/update.sh",test:"bun test","test:watch":"bun test --watch","test:coverage":"bun test --coverage",typecheck:"tsc --noEmit -p core/tsconfig.json","typecheck:watch":"tsc --noEmit -p core/tsconfig.json --watch",validate:"bun scripts/validate-commands.js",lint:"biome lint .","lint:fix":"biome lint --write .","lint:meta":"bun core/cli/lint-meta-commentary.ts",format:"biome format --write .","format:check":"biome format .",check:"biome check .","check:fix":"biome check --write ."},keywords:["claude-code","gemini-cli","ai-agents","context-layer","developer-tools","ai-assistant","productivity","mcp","llm","coding-agents"],author:"prjct.app",license:"MIT",dependencies:{"@clack/prompts":"^1.0.0","@hono/node-server":"^1.13.7","@modelcontextprotocol/sdk":"^1.28.0","better-sqlite3":"^12.6.2",chalk:"^4.1.2",chokidar:"^5.0.0","date-fns":"^4.1.0",glob:"^13.0.1",hono:"^4.11.3","jsonc-parser":"^3.3.1",zod:"^3.24.1"},devDependencies:{"@biomejs/biome":"^2.3.13","@types/better-sqlite3":"^7.6.13","@types/bun":"latest","@types/chokidar":"^2.1.7",esbuild:"^0.25.0",lefthook:"^2.1.0",typescript:"^5.9.3"},repository:{type:"git",url:"git+https://github.com/jlopezlira/prjct-cli.git"},bugs:{url:"https://github.com/jlopezlira/prjct-cli/issues"},homepage:"https://prjct.app",packageManager:"bun@1.2.23",engines:{bun:">=1.0.0",node:">=18.0.0"},files:["assets/","bin/prjct","dist/","templates/","scripts/postinstall.js","scripts/ensure-bun.sh","scripts/install.sh","LICENSE","README.md","CHANGELOG.md"],prepublishOnly:"node scripts/build.js",trustedDependencies:["chalk"]}});var sP={};import Dy from"node:os";import ja from"node:path";import He from"chalk";async function KC(){let[r,...e]=process.argv.slice(2);if(["-v","--version","version"].includes(r)){let s=await Promise.resolve().then(()=>Hy(Iy()));await eP(s.version),process.exit(0)}["-h","--help",void 0].includes(r)&&(tP(),process.exit(0));let t=e.includes("--md");t||f.start();try{let s=W.getByName(r);if(!s){let m=YC(r),g=m?`Did you mean 'prjct ${m}'? Run 'prjct --help' for all commands`:"Run 'prjct --help' to see available commands";f.failWithHint(yn("UNKNOWN_COMMAND",{message:`Unknown command: ${r}`,hint:g})),t||f.end(),process.exit(1)}if(s.deprecated){let m=s.replacedBy?`Use 'prjct ${s.replacedBy}' instead`:"Run 'prjct --help' to see available commands";f.failWithHint({message:`Command '${r}' is deprecated`,hint:m}),t||f.end(),process.exit(1)}s.implemented||(f.failWithHint({message:`Command '${r}' is not yet implemented`,hint:"Run 'prjct --help' to see available commands",docs:"https://github.com/jlopezlira/prjct-cli"}),t||f.end(),process.exit(1));let{parsedArgs:n,options:o}=ZC(s,e),i=!process.stdin.isTTY||o.md===!0||o.json===!0;s.requiresLlm&&!i&&(f.failWithHint({message:`'prjct ${r}' requires an AI agent to process its output`,hint:`Use 'p. ${r}' inside Claude/Cursor, or add --md flag`}),t||f.end(),process.exit(1));let a=XC(s,n);a&&(f.failWithHint(a),t||f.end(),process.exit(1));let c=null,u=Date.now();try{c=await _.getProjectId(process.cwd()),c&&(await Us.expireIfStale(c),await Us.touch(c))}catch{}let d=new Zs,p;if(r==="parallel"&&n[0]==="spawn"&&n.length>1){let m=n.slice(1).join(" ");p=await d.parallelSpawn(m,process.cwd(),{md:o.md===!0})}else if(r==="parallel"&&n[0]==="batch"){let m=n.slice(1);m.length===0&&(f.failWithHint({message:"No tasks provided",hint:'Usage: prjct parallel batch "task1" "task2" "task3"'}),process.exit(1)),p=await d.parallelBatch(m,process.cwd())}else if(r==="design"){let m=n.join(" ");p=await d.design(m,o)}else if(r==="analyze")p=await d.analyze(o);else if(r==="cleanup")p=await d.cleanup(o);else if(r==="cleanup-projects")p=await d.cleanupProjects({dryRun:o["dry-run"]===!0,md:o.md===!0});else if(r==="setup")p=await d.setup(o);else if(r==="update")p=await d.update(o);else{let m=n.join(" ")||null,g=o.md===!0,v={task:l(h=>d.task(h,process.cwd(),{md:g}),"task"),done:l(()=>d.done(process.cwd(),{md:g}),"done"),next:l(()=>d.next(process.cwd(),{md:g}),"next"),pause:l(h=>d.pause(h||"",process.cwd(),{md:g}),"pause"),resume:l(h=>d.resume(h,process.cwd(),{md:g}),"resume"),init:l(h=>d.init(h),"init"),bug:l(h=>d.bug(h||"",process.cwd(),{md:g}),"bug"),idea:l(h=>d.idea(h||"",process.cwd(),{md:g}),"idea"),spec:l(h=>d.spec(h),"spec"),ship:l(h=>d.ship(h,process.cwd(),{md:g}),"ship"),workflow:l(h=>d.workflowPrefs(h,process.cwd(),{md:g}),"workflow"),sessions:l(()=>d.sessions(process.cwd(),{md:g,cleanup:o.cleanup===!0}),"sessions"),dash:l(h=>d.dash(h||"default",process.cwd(),{md:g}),"dash"),stats:l(()=>d.stats(process.cwd(),{json:o.json===!0,export:o.export===!0}),"stats"),status:l(()=>d.status(process.cwd(),{json:o.json===!0,md:g}),"status"),help:l(h=>d.help(h||""),"help"),perf:l(h=>d.perf(h||"7"),"perf"),velocity:l(h=>d.velocity(h||"0"),"velocity"),recover:l(()=>d.recover(),"recover"),undo:l(()=>d.undo(),"undo"),redo:l(()=>d.redo(),"redo"),history:l(()=>d.history(),"history"),enrich:l(h=>d.enrich(h,process.cwd(),{md:g,json:o.json===!0}),"enrich"),sync:l(()=>d.sync(process.cwd(),{preview:o.preview===!0||o["dry-run"]===!0,yes:o.yes===!0,json:o.json===!0,md:g,package:o.package?String(o.package):void 0,full:o.full===!0}),"sync"),diff:l(()=>d.diff(process.cwd(),{json:o.json===!0,md:g}),"diff"),seal:l(()=>d.seal(process.cwd(),{json:o.json===!0}),"seal"),rollback:l(()=>d.rollback(process.cwd(),{json:o.json===!0,md:g}),"rollback"),verify:l(()=>d.verify(process.cwd(),{json:o.json===!0,semantic:o.semantic===!0}),"verify"),"analysis-payload":l(()=>d.analysisPayload(process.cwd(),{json:o.json===!0,md:g}),"analysis-payload"),"analysis-save-llm":l(h=>d.saveLlmAnalysis(h||"",process.cwd(),{md:g}),"analysis-save-llm"),"analysis-llm":l(()=>d.getLlmAnalysis(process.cwd(),{json:o.json===!0,md:g}),"analysis-llm"),start:l(()=>d.start(),"start"),context:l(h=>d.context(h),"context"),login:l(()=>d.login({md:g,url:o.url?String(o.url):void 0}),"login"),logout:l(()=>d.logout(),"logout"),auth:l(h=>d.auth(h,{md:g}),"auth"),parallel:l(h=>d.parallel(h,process.cwd(),{md:g,max:o.max?Number(o.max):void 0,fromQueue:o["from-queue"]===!0,fromLinear:o["from-linear"]===!0,fromJira:o["from-jira"]===!0,includeBacklog:o["include-backlog"]===!0}),"parallel"),worktree:l(h=>d.parallel(h,process.cwd(),{md:g}),"worktree"),conductor:l(h=>d.parallel(h,process.cwd(),{md:g}),"conductor")}[r];if(v)p=await v(m);else throw new Error(`Command '${r}' has no handler`)}if(c){let m=Date.now()-u;try{await Us.trackCommand(c,r,m)}catch{}try{await wn.recordTiming(c,"command_duration",m,{command:r});let g=globalThis.__perfStartNs;if(g){let w=Number(process.hrtime.bigint()-g)/1e6;await wn.recordTiming(c,"startup_time",w)}await wn.recordMemory(c,{command:r})}catch{}}p?.message&&console.log(p.message),t||f.end(),process.exit(p?.success?0:1)}catch(s){console.error("Error:",k(s)),process.env.DEBUG&&console.error(Ga(s)),t||f.end(),process.exit(1)}}function XC(r,e){if(!r.params)return null;let t=r.params.match(/<[^>]+>/g);if(!t||t.length===0)return null;if(e.length<t.length){let s=t.map(o=>o.slice(1,-1)).join(", "),n=r.usage.terminal||`prjct ${r.name} ${r.params}`;return yn("MISSING_PARAM",{message:`Missing required parameter: ${s}`,hint:`Usage: ${n}`})}return null}function YC(r){let e=W.getAll().map(n=>n.name),t=null,s=1/0;for(let n of e){let o=QC(r.toLowerCase(),n.toLowerCase());o<s&&(s=o,t=n)}return s<=2?t:null}function QC(r,e){let t=r.length,s=e.length,n=Array.from({length:t+1},()=>Array(s+1).fill(0));for(let o=0;o<=t;o++)n[o][0]=o;for(let o=0;o<=s;o++)n[0][o]=o;for(let o=1;o<=t;o++)for(let i=1;i<=s;i++)n[o][i]=r[o-1]===e[i-1]?n[o-1][i-1]:1+Math.min(n[o-1][i],n[o][i-1],n[o-1][i-1]);return n[t][s]}function ZC(r,e){let t=[],s={};for(let n=0;n<e.length;n++){let o=e[n];if(o.startsWith("--")){let i=o.slice(2);n+1<e.length&&!e[n+1].startsWith("--")?s[i]=e[++n]:s[i]=!0}else t.push(o)}return{parsedArgs:t,options:s}}async function eP(r){let e=await ws(),t=ja.join(Dy.homedir(),".claude","commands","p.md"),s=ja.join(Dy.homedir(),".gemini","commands","p.toml"),[n,o,i,a]=await Promise.all([E(t),E(s),E(ja.join(process.cwd(),".cursor","commands","sync.md")),E(ja.join(process.cwd(),".cursor"))]),c=await Ln();if(console.log(`
1784
+ `)}function zC(r){return r?r==="commands"||r==="all"?Ry():xy(r):Ey()}var Ty,qC,jy=S(()=>{"use strict";fd();ot();Ty=[{name:"start",description:"First-time setup wizard",example:"prjct start"},{name:"init",description:"Initialize project in current directory",example:"prjct init"},{name:"sync",description:"Sync project state and update context files",example:"prjct sync"},{name:"watch",description:"Auto-sync on file changes",example:"prjct watch",options:["--verbose","--debounce=<ms>","--interval=<sec>"]},{name:"hooks",description:"Manage git hooks for auto-sync",example:"prjct hooks install",subcommands:["install","uninstall","status"]},{name:"doctor",description:"Check system health and dependencies",example:"prjct doctor"},{name:"serve",description:"Start web dashboard server",example:"prjct serve [port]"},{name:"context",description:"Smart context filtering tools for AI",example:'prjct context files "add auth"',subcommands:["files","signatures","imports","recent","summary"]},{name:"enrich",description:"Prepare issue enrichment context from local code",example:'prjct enrich "PROJ-123 improve auth flow" --md'},{name:"linear",description:"Linear issue tracker MCP gateway",example:"prjct linear setup",subcommands:["setup","status","sync","list","get","create","update","start","done","comment"]},{name:"jira",description:"Jira issue tracker MCP gateway",example:"prjct jira setup",subcommands:["setup","status","sync","list","get","create","update","start","done","transition","comment"]},{name:"stop",description:"Stop the background daemon",example:"prjct stop",options:["--force"]},{name:"restart",description:"Restart the background daemon",example:"prjct restart"},{name:"uninstall",description:"Complete system removal of prjct",example:"prjct uninstall --backup",options:["--force","--backup","--dry-run","--keep-package"]}],qC=[{flag:"-q, --quiet",description:"Suppress all output (errors to stderr only)"},{flag:"-v, --version",description:"Show version and provider status"},{flag:"-h, --help",description:"Show this help message"}];l(Ey,"formatMainHelp");l(Cy,"formatTerminalCommandHelp");l(Py,"formatAgentCommandHelp");l(xy,"formatCommandHelp");l(Ry,"formatCommandList");l(zC,"getHelp")});var Iy=Uy((YV,JC)=>{JC.exports={name:"prjct-cli",version:"1.54.0",description:"Context layer for AI agents. Project context for Claude Code, Gemini CLI, and more.",main:"dist/bin/prjct.mjs",bin:{prjct:"bin/prjct"},publishConfig:{access:"public",registry:"https://registry.npmjs.org"},scripts:{build:"node scripts/build.js","build:node":"node scripts/build.js",release:"node scripts/release.js","release:patch":"node scripts/release.js patch","release:minor":"node scripts/release.js minor","release:major":"node scripts/release.js major",postinstall:"node scripts/postinstall.js",prepare:"lefthook install","update-commands":`bun -e "const installer = require('./core/infrastructure/command-installer'); installer.syncCommands().then(r => console.log('Commands updated:', r)).catch(e => console.error('Error:', e.message))"`,"install-global":"./scripts/install.sh",update:"./scripts/update.sh",test:"bun test","test:watch":"bun test --watch","test:coverage":"bun test --coverage",typecheck:"tsc --noEmit -p core/tsconfig.json","typecheck:watch":"tsc --noEmit -p core/tsconfig.json --watch",validate:"bun scripts/validate-commands.js",lint:"biome lint .","lint:fix":"biome lint --write .","lint:meta":"bun core/cli/lint-meta-commentary.ts",format:"biome format --write .","format:check":"biome format .",check:"biome check .","check:fix":"biome check --write ."},keywords:["claude-code","gemini-cli","ai-agents","context-layer","developer-tools","ai-assistant","productivity","mcp","llm","coding-agents"],author:"prjct.app",license:"MIT",dependencies:{"@clack/prompts":"^1.0.0","@hono/node-server":"^1.13.7","@modelcontextprotocol/sdk":"^1.28.0","better-sqlite3":"^12.6.2",chalk:"^4.1.2",chokidar:"^5.0.0","date-fns":"^4.1.0",glob:"^13.0.1",hono:"^4.11.3","jsonc-parser":"^3.3.1",zod:"^3.24.1"},devDependencies:{"@biomejs/biome":"^2.3.13","@types/better-sqlite3":"^7.6.13","@types/bun":"latest","@types/chokidar":"^2.1.7",esbuild:"^0.25.0",lefthook:"^2.1.0",typescript:"^5.9.3"},repository:{type:"git",url:"git+https://github.com/jlopezlira/prjct-cli.git"},bugs:{url:"https://github.com/jlopezlira/prjct-cli/issues"},homepage:"https://prjct.app",packageManager:"bun@1.2.23",engines:{bun:">=1.0.0",node:">=18.0.0"},files:["assets/","bin/prjct","dist/","templates/","scripts/postinstall.js","scripts/ensure-bun.sh","scripts/install.sh","LICENSE","README.md","CHANGELOG.md"],prepublishOnly:"node scripts/build.js",trustedDependencies:["chalk"]}});var sP={};import Dy from"node:os";import ja from"node:path";import He from"chalk";async function KC(){let[r,...e]=process.argv.slice(2);if(["-v","--version","version"].includes(r)){let s=await Promise.resolve().then(()=>Hy(Iy()));await eP(s.version),process.exit(0)}["-h","--help",void 0].includes(r)&&(tP(),process.exit(0));let t=e.includes("--md");t||f.start();try{let s=W.getByName(r);if(!s){let m=YC(r),g=m?`Did you mean 'prjct ${m}'? Run 'prjct --help' for all commands`:"Run 'prjct --help' to see available commands";f.failWithHint(yn("UNKNOWN_COMMAND",{message:`Unknown command: ${r}`,hint:g})),t||f.end(),process.exit(1)}if(s.deprecated){let m=s.replacedBy?`Use 'prjct ${s.replacedBy}' instead`:"Run 'prjct --help' to see available commands";f.failWithHint({message:`Command '${r}' is deprecated`,hint:m}),t||f.end(),process.exit(1)}s.implemented||(f.failWithHint({message:`Command '${r}' is not yet implemented`,hint:"Run 'prjct --help' to see available commands",docs:"https://github.com/jlopezlira/prjct-cli"}),t||f.end(),process.exit(1));let{parsedArgs:n,options:o}=ZC(s,e),i=!process.stdin.isTTY||o.md===!0||o.json===!0;s.requiresLlm&&!i&&(f.failWithHint({message:`'prjct ${r}' requires an AI agent to process its output`,hint:`Use 'p. ${r}' inside Claude/Cursor, or add --md flag`}),t||f.end(),process.exit(1));let a=XC(s,n);a&&(f.failWithHint(a),t||f.end(),process.exit(1));let c=null,u=Date.now();try{c=await _.getProjectId(process.cwd()),c&&(await Us.expireIfStale(c),await Us.touch(c))}catch{}let d=new Zs,p;if(r==="parallel"&&n[0]==="spawn"&&n.length>1){let m=n.slice(1).join(" ");p=await d.parallelSpawn(m,process.cwd(),{md:o.md===!0})}else if(r==="parallel"&&n[0]==="batch"){let m=n.slice(1);m.length===0&&(f.failWithHint({message:"No tasks provided",hint:'Usage: prjct parallel batch "task1" "task2" "task3"'}),process.exit(1)),p=await d.parallelBatch(m,process.cwd())}else if(r==="design"){let m=n.join(" ");p=await d.design(m,o)}else if(r==="analyze")p=await d.analyze(o);else if(r==="cleanup")p=await d.cleanup(o);else if(r==="cleanup-projects")p=await d.cleanupProjects({dryRun:o["dry-run"]===!0,md:o.md===!0});else if(r==="setup")p=await d.setup(o);else if(r==="update")p=await d.update(o);else{let m=n.join(" ")||null,g=o.md===!0,v={task:l(h=>d.task(h,process.cwd(),{md:g}),"task"),done:l(()=>d.done(process.cwd(),{md:g}),"done"),next:l(()=>d.next(process.cwd(),{md:g}),"next"),pause:l(h=>d.pause(h||"",process.cwd(),{md:g}),"pause"),resume:l(h=>d.resume(h,process.cwd(),{md:g}),"resume"),init:l(h=>d.init(h),"init"),bug:l(h=>d.bug(h||"",process.cwd(),{md:g}),"bug"),idea:l(h=>d.idea(h||"",process.cwd(),{md:g}),"idea"),spec:l(h=>d.spec(h),"spec"),ship:l(h=>d.ship(h,process.cwd(),{md:g}),"ship"),workflow:l(h=>d.workflowPrefs(h,process.cwd(),{md:g}),"workflow"),sessions:l(()=>d.sessions(process.cwd(),{md:g,cleanup:o.cleanup===!0}),"sessions"),dash:l(h=>d.dash(h||"default",process.cwd(),{md:g}),"dash"),stats:l(()=>d.stats(process.cwd(),{json:o.json===!0,export:o.export===!0}),"stats"),status:l(()=>d.status(process.cwd(),{json:o.json===!0,md:g}),"status"),help:l(h=>d.help(h||""),"help"),perf:l(h=>d.perf(h||"7"),"perf"),velocity:l(h=>d.velocity(h||"0"),"velocity"),recover:l(()=>d.recover(),"recover"),undo:l(()=>d.undo(),"undo"),redo:l(()=>d.redo(),"redo"),history:l(()=>d.history(),"history"),enrich:l(h=>d.enrich(h,process.cwd(),{md:g,json:o.json===!0}),"enrich"),sync:l(()=>d.sync(process.cwd(),{preview:o.preview===!0||o["dry-run"]===!0,yes:o.yes===!0,json:o.json===!0,md:g,package:o.package?String(o.package):void 0,full:o.full===!0}),"sync"),diff:l(()=>d.diff(process.cwd(),{json:o.json===!0,md:g}),"diff"),seal:l(()=>d.seal(process.cwd(),{json:o.json===!0}),"seal"),rollback:l(()=>d.rollback(process.cwd(),{json:o.json===!0,md:g}),"rollback"),verify:l(()=>d.verify(process.cwd(),{json:o.json===!0,semantic:o.semantic===!0}),"verify"),"analysis-payload":l(()=>d.analysisPayload(process.cwd(),{json:o.json===!0,md:g}),"analysis-payload"),"analysis-save-llm":l(h=>d.saveLlmAnalysis(h||"",process.cwd(),{md:g}),"analysis-save-llm"),"analysis-llm":l(()=>d.getLlmAnalysis(process.cwd(),{json:o.json===!0,md:g}),"analysis-llm"),start:l(()=>d.start(),"start"),context:l(h=>d.context(h),"context"),login:l(()=>d.login({md:g,url:o.url?String(o.url):void 0}),"login"),logout:l(()=>d.logout(),"logout"),auth:l(h=>d.auth(h,{md:g}),"auth"),parallel:l(h=>d.parallel(h,process.cwd(),{md:g,max:o.max?Number(o.max):void 0,fromQueue:o["from-queue"]===!0,fromLinear:o["from-linear"]===!0,fromJira:o["from-jira"]===!0,includeBacklog:o["include-backlog"]===!0}),"parallel"),worktree:l(h=>d.parallel(h,process.cwd(),{md:g}),"worktree"),conductor:l(h=>d.parallel(h,process.cwd(),{md:g}),"conductor")}[r];if(v)p=await v(m);else throw new Error(`Command '${r}' has no handler`)}if(c){let m=Date.now()-u;try{await Us.trackCommand(c,r,m)}catch{}try{await wn.recordTiming(c,"command_duration",m,{command:r});let g=globalThis.__perfStartNs;if(g){let w=Number(process.hrtime.bigint()-g)/1e6;await wn.recordTiming(c,"startup_time",w)}await wn.recordMemory(c,{command:r})}catch{}}p?.message&&console.log(p.message),t||f.end(),process.exit(p?.success?0:1)}catch(s){console.error("Error:",k(s)),process.env.DEBUG&&console.error(Ga(s)),t||f.end(),process.exit(1)}}function XC(r,e){if(!r.params)return null;let t=r.params.match(/<[^>]+>/g);if(!t||t.length===0)return null;if(e.length<t.length){let s=t.map(o=>o.slice(1,-1)).join(", "),n=r.usage.terminal||`prjct ${r.name} ${r.params}`;return yn("MISSING_PARAM",{message:`Missing required parameter: ${s}`,hint:`Usage: ${n}`})}return null}function YC(r){let e=W.getAll().map(n=>n.name),t=null,s=1/0;for(let n of e){let o=QC(r.toLowerCase(),n.toLowerCase());o<s&&(s=o,t=n)}return s<=2?t:null}function QC(r,e){let t=r.length,s=e.length,n=Array.from({length:t+1},()=>Array(s+1).fill(0));for(let o=0;o<=t;o++)n[o][0]=o;for(let o=0;o<=s;o++)n[0][o]=o;for(let o=1;o<=t;o++)for(let i=1;i<=s;i++)n[o][i]=r[o-1]===e[i-1]?n[o-1][i-1]:1+Math.min(n[o-1][i],n[o][i-1],n[o-1][i-1]);return n[t][s]}function ZC(r,e){let t=[],s={};for(let n=0;n<e.length;n++){let o=e[n];if(o.startsWith("--")){let i=o.slice(2);n+1<e.length&&!e[n+1].startsWith("--")?s[i]=e[++n]:s[i]=!0}else t.push(o)}return{parsedArgs:t,options:s}}async function eP(r){let e=await ws(),t=ja.join(Dy.homedir(),".claude","commands","p.md"),s=ja.join(Dy.homedir(),".gemini","commands","p.toml"),[n,o,i,a]=await Promise.all([E(t),E(s),E(ja.join(process.cwd(),".cursor","commands","sync.md")),E(ja.join(process.cwd(),".cursor"))]),c=await Ln();if(console.log(`
1785
1785
  ${He.cyan("p/")} prjct v${r}
1786
1786
  ${He.dim("Context layer for AI coding agents")}
1787
1787
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "prjct-cli",
3
- "version": "1.53.0",
3
+ "version": "1.54.0",
4
4
  "description": "Context layer for AI agents. Project context for Claude Code, Gemini CLI, and more.",
5
5
  "main": "dist/bin/prjct.mjs",
6
6
  "bin": {