prjct-cli 1.38.1 → 1.38.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/CHANGELOG.md +7 -0
- package/dist/bin/prjct-core.mjs +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/dist/bin/prjct-core.mjs
CHANGED
|
@@ -1656,7 +1656,7 @@ ${X.yellow(`Command '${r}' not found.`)}
|
|
|
1656
1656
|
|
|
1657
1657
|
Run 'prjct help' to see all available commands.
|
|
1658
1658
|
`}function gk(){let r=[];r.push(""),r.push(X.cyan.bold("All Commands")),r.push("");let e=Object.entries(Uo).sort((t,n)=>t[1].order-n[1].order);for(let[t,n]of e){let s=Rr.filter(o=>o.group===t);if(s.length!==0){r.push(`${X.bold(n.title)} ${X.dim(`(${s.length} commands)`)}`),r.push(X.dim(n.description)),r.push("");for(let o of s){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(`
|
|
1659
|
-
`)}function $j(r){return r?r==="commands"||r==="all"?gk():mk(r):uk()}var lk,Dj,hk=y(()=>{"use strict";ip();pt();lk=[{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:"linear",description:"Linear issue tracker CLI",example:"prjct linear list",subcommands:["list","get","create","update"]},{name:"uninstall",description:"Complete system removal of prjct",example:"prjct uninstall --backup",options:["--force","--backup","--dry-run","--keep-package"]}],Dj=[{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(uk,"formatMainHelp");l(dk,"formatTerminalCommandHelp");l(pk,"formatAgentCommandHelp");l(mk,"formatCommandHelp");l(gk,"formatCommandList");l($j,"getHelp")});var yk=Ik((b3,Mj)=>{Mj.exports={name:"prjct-cli",version:"1.38.
|
|
1659
|
+
`)}function $j(r){return r?r==="commands"||r==="all"?gk():mk(r):uk()}var lk,Dj,hk=y(()=>{"use strict";ip();pt();lk=[{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:"linear",description:"Linear issue tracker CLI",example:"prjct linear list",subcommands:["list","get","create","update"]},{name:"uninstall",description:"Complete system removal of prjct",example:"prjct uninstall --backup",options:["--force","--backup","--dry-run","--keep-package"]}],Dj=[{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(uk,"formatMainHelp");l(dk,"formatTerminalCommandHelp");l(pk,"formatAgentCommandHelp");l(mk,"formatCommandHelp");l(gk,"formatCommandList");l($j,"getHelp")});var yk=Ik((b3,Mj)=>{Mj.exports={name:"prjct-cli",version:"1.38.2",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","@linear/sdk":"^29.0.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:{node:">=18.0.0",bun:">=1.0.0"},files:["assets/","bin/prjct","dist/","scripts/postinstall.js","scripts/install.sh","LICENSE","README.md","CHANGELOG.md"],prepublishOnly:"node scripts/build.js",trustedDependencies:["chalk"]}});var Gj={};import wk from"node:os";import uc from"node:path";import Le from"chalk";async function Oj(){let[r,...e]=process.argv.slice(2);if(["-v","--version","version"].includes(r)){let t=await Promise.resolve().then(()=>jk(yk()));await Hj(t.version),process.exit(0)}["-h","--help",void 0].includes(r)&&(Uj(),process.exit(0)),h.start();try{let t=W.getByName(r);if(!t){let d=Nj(r),m=d?`Did you mean 'prjct ${d}'? Run 'prjct --help' for all commands`:"Run 'prjct --help' to see available commands";h.failWithHint(cs("UNKNOWN_COMMAND",{message:`Unknown command: ${r}`,hint:m})),h.end(),process.exit(1)}if(t.deprecated){let d=t.replacedBy?`Use 'prjct ${t.replacedBy}' instead`:"Run 'prjct --help' to see available commands";h.failWithHint({message:`Command '${r}' is deprecated`,hint:d}),h.end(),process.exit(1)}t.implemented||(h.failWithHint({message:`Command '${r}' is not yet implemented`,hint:"Run 'prjct --help' to see available commands",docs:"https://github.com/jlopezlira/prjct-cli"}),h.end(),process.exit(1));let{parsedArgs:n,options:s}=Lj(t,e),o=Fj(t,n);o&&(h.failWithHint(o),h.end(),process.exit(1));let i=null,a=Date.now();try{i=await $.getProjectId(process.cwd()),i&&(await zn.expireIfStale(i),await zn.touch(i))}catch{}let c=new Mn,u;if(r==="design"){let d=n.join(" ");u=await c.design(d,s)}else if(r==="analyze")u=await c.analyze(s);else if(r==="cleanup")u=await c.cleanup(s);else if(r==="setup")u=await c.setup(s);else if(r==="update")u=await c.update(s);else{let d=n.join(" ")||null,m=s.md===!0,g={task:l(f=>c.task(f,process.cwd(),{md:m}),"task"),done:l(()=>c.done(process.cwd(),{md:m}),"done"),next:l(()=>c.next(process.cwd(),{md:m}),"next"),pause:l(f=>c.pause(f||"",process.cwd(),{md:m}),"pause"),resume:l(f=>c.resume(f,process.cwd(),{md:m}),"resume"),init:l(f=>c.init(f),"init"),bug:l(f=>c.bug(f||"",process.cwd(),{md:m}),"bug"),idea:l(f=>c.idea(f||"",process.cwd(),{md:m}),"idea"),spec:l(f=>c.spec(f),"spec"),ship:l(f=>c.ship(f,process.cwd(),{md:m}),"ship"),workflow:l(f=>c.workflowPrefs(f,process.cwd(),{md:m}),"workflow"),sessions:l(()=>c.sessions(process.cwd(),{md:m,cleanup:s.cleanup===!0}),"sessions"),dash:l(f=>c.dash(f||"default",process.cwd(),{md:m}),"dash"),stats:l(()=>c.stats(process.cwd(),{json:s.json===!0,export:s.export===!0}),"stats"),status:l(()=>c.status(process.cwd(),{json:s.json===!0,md:m}),"status"),help:l(f=>c.help(f||""),"help"),perf:l(f=>c.perf(f||"7"),"perf"),velocity:l(f=>c.velocity(f||"0"),"velocity"),recover:l(()=>c.recover(),"recover"),undo:l(()=>c.undo(),"undo"),redo:l(()=>c.redo(),"redo"),history:l(()=>c.history(),"history"),sync:l(()=>c.sync(process.cwd(),{aiTools:s.agents?String(s.agents).split(","):void 0,preview:s.preview===!0||s["dry-run"]===!0,yes:s.yes===!0,json:s.json===!0,md:m,package:s.package?String(s.package):void 0,full:s.full===!0}),"sync"),diff:l(()=>c.diff(process.cwd(),{json:s.json===!0,md:m}),"diff"),seal:l(()=>c.seal(process.cwd(),{json:s.json===!0}),"seal"),rollback:l(()=>c.rollback(process.cwd(),{json:s.json===!0,md:m}),"rollback"),verify:l(()=>c.verify(process.cwd(),{json:s.json===!0,semantic:s.semantic===!0}),"verify"),"analysis-payload":l(()=>c.analysisPayload(process.cwd(),{json:s.json===!0,md:m}),"analysis-payload"),"analysis-save-llm":l(f=>c.saveLlmAnalysis(f||"",process.cwd(),{md:m}),"analysis-save-llm"),"analysis-llm":l(()=>c.getLlmAnalysis(process.cwd(),{json:s.json===!0,md:m}),"analysis-llm"),start:l(()=>c.start(),"start"),context:l(f=>c.context(f),"context")}[r];if(g)u=await g(d);else throw new Error(`Command '${r}' has no handler`)}if(i){let d=Date.now()-a;try{await zn.trackCommand(i,r,d)}catch{}try{await ls.recordTiming(i,"command_duration",d,{command:r});let m=globalThis.__perfStartNs;if(m){let p=Number(process.hrtime.bigint()-m)/1e6;await ls.recordTiming(i,"startup_time",p)}await ls.recordMemory(i,{command:r})}catch{}}u?.message&&console.log(u.message),h.end(),process.exit(u?.success?0:1)}catch(t){console.error("Error:",w(t)),process.env.DEBUG&&console.error(Jo(t)),h.end(),process.exit(1)}}function Fj(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 n=t.map(o=>o.slice(1,-1)).join(", "),s=r.usage.terminal||`prjct ${r.name} ${r.params}`;return cs("MISSING_PARAM",{message:`Missing required parameter: ${n}`,hint:`Usage: ${s}`})}return null}function Nj(r){let e=W.getAll().map(s=>s.name),t=null,n=1/0;for(let s of e){let o=_j(r.toLowerCase(),s.toLowerCase());o<n&&(n=o,t=s)}return n<=2?t:null}function _j(r,e){let t=r.length,n=e.length,s=Array.from({length:t+1},()=>Array(n+1).fill(0));for(let o=0;o<=t;o++)s[o][0]=o;for(let o=0;o<=n;o++)s[0][o]=o;for(let o=1;o<=t;o++)for(let i=1;i<=n;i++)s[o][i]=r[o-1]===e[i-1]?s[o-1][i-1]:1+Math.min(s[o-1][i],s[o][i-1],s[o-1][i-1]);return s[t][n]}function Lj(r,e){let t=[],n={};for(let s=0;s<e.length;s++){let o=e[s];if(o.startsWith("--")){let i=o.slice(2);s+1<e.length&&!e[s+1].startsWith("--")?n[i]=e[++s]:n[i]=!0}else t.push(o)}return{parsedArgs:t,options:n}}async function Hj(r){let e=await xn(),t=uc.join(wk.homedir(),".claude","commands","p.md"),n=uc.join(wk.homedir(),".gemini","commands","p.toml"),[s,o,i,a]=await Promise.all([P(t),P(n),P(uc.join(process.cwd(),".cursor","commands","sync.md")),P(uc.join(process.cwd(),".cursor"))]),c=await _s();if(console.log(`
|
|
1660
1660
|
${Le.cyan("p/")} prjct v${r}
|
|
1661
1661
|
${Le.dim("Context layer for AI coding agents")}
|
|
1662
1662
|
|