ripplo 0.4.8 → 0.4.9

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.
Files changed (2) hide show
  1. package/dist/index.js +1 -1
  2. package/package.json +3 -3
package/dist/index.js CHANGED
@@ -683,7 +683,7 @@ ${R("create")}`}function lw(e,t){if(t.length===0)return null;let r=dw(["run",...
683
683
  `).filter(o=>/FAILED/.test(o)).join(`
684
684
  `);return n.length===0?null:`--- Ripplo Run Failures (${t.join(" ")}) ---
685
685
  ${n}
686
- Artifacts: .ripplo/debug/<runId>/. ${R("debug")}`}var cw=Zt.object({status:Zt.number().nullish(),stderr:Zt.unknown().optional(),stdout:Zt.unknown().optional()});function Sa(e){return e instanceof Buffer?e.toString("utf8"):typeof e=="string"?e:""}function dw(e,t){let r=ba.argv[1];if(r==null)return{code:1,output:""};try{return{code:0,output:Qh(ba.execPath,[r,...e],{cwd:t,encoding:"utf8",stdio:["ignore","pipe","pipe"]})}}catch(n){let o=cw.safeParse(n);if(!o.success)return{code:1,output:""};let i=`${Sa(o.data.stdout)}${Sa(o.data.stderr)}`;return{code:o.data.status??1,output:i}}}import{z as ka}from"zod";var uw=ka.looseObject({skill:ka.string()}),Ra=N("PostToolUse",e=>{if(e.tool_name!=="Skill")return;let t=uw.safeParse(e.tool_input);if(!t.success)return;let r=/^ripplo:(.+)$/.exec(t.data.skill);if(r==null)return;let n=r[1];n!=null&&I(e.cwd)&&ia(e.cwd,e.session_id,n)});vw();$n(process.cwd());var Pa={"coverage-nudge":Js,"exit-plan-gate":Ys,"plan-reminder":Xs,"post-edit-flag-stubs":ea,"post-edit-lint":ra,"pre-bash-hooks-pause-gate":oa,"pre-bash-run-gate":ca,"pre-edit-ripplo-skill-gate":ua,"pre-edit-scope-gate":fa,"pre-edit-watch-gate":ya,"scope-reminder":ha,"session-preamble":wa,"stop-enforce":va,"track-skill-load":Ra};async function fw(){await pw(mw(process.argv)).scriptName("ripplo").command("watch","Watch for run requests and execute locally",()=>{},()=>Us()).command("auth <subcommand>","Manage authentication",Sw).command("projects <subcommand>","Inspect Ripplo projects",bw).command("hooks <subcommand>","Pause or resume Ripplo hooks",ww).command("init","Scaffold .ripplo/ in this project",e=>e.option("project",{type:"string"}).option("env",{type:"string"}).option("app-url",{type:"string"}).option("engine-url",{type:"string"}),e=>$s({appUrl:e["app-url"],engineUrl:e["engine-url"],envFile:e.env,projectId:e.project})).command("run [ids..]","Run tests in parallel",e=>{let t=[];return e.positional("ids",{array:!0,default:t,describe:"Test ids to run (all if omitted)",type:"string"})},e=>Os(e.ids)).command("lint [ids..]","Compile and lint tests (all or specific ids)",e=>{let t=[];return e.positional("ids",{array:!0,default:t,describe:"Test ids to lint (all if omitted)",type:"string"}).option("require-implemented",{array:!0,default:t,describe:"Test ids that must not be .notImplemented() \u2014 fails if any still are",type:"string"})},e=>js({ids:e.ids,requireImplemented:e["require-implemented"]})).command("flake-detect <id>","Run N times to detect flakiness",e=>e.positional("id",{demandOption:!0,type:"string"}).option("runs",{default:10,type:"number"}),e=>vs({id:e.id,runs:e.runs})).command("sync","Push the compiled .ripplo/ resources to the server (no run)",()=>{},()=>Ds()).command("compile","Compile the DSL and write .ripplo/ripplo.lock",e=>e.option("check",{default:!1,describe:"Exit non-zero if the lockfile is missing or stale (does not write)",type:"boolean"}),e=>Zi({check:e.check})).command("cover","Audit all coverage statements",()=>{},()=>os()).command("doctor","Check project health",()=>{},()=>hs()).command("status","Report unimplemented tests and preconditions",e=>e.option("format",{choices:["json","summary"],default:"json",describe:"Output format"}),e=>qs({format:e.format})).command("scope <subcommand>","Manage testing scope",hw).command("hook <name>","Internal: run a Claude Code plugin hook",e=>e.positional("name",{choices:Object.keys(Pa),demandOption:!0,type:"string"}),e=>gw(e.name)).strict().help().parse()}async function gw(e){let t=Pa[e];t==null&&(process.stderr.write(`Unknown hook: ${e}
686
+ Artifacts: .ripplo/debug/<runId>/. ${R("debug")}`}var cw=Zt.object({status:Zt.number().nullish(),stderr:Zt.unknown().optional(),stdout:Zt.unknown().optional()});function Sa(e){return e instanceof Buffer?e.toString("utf8"):typeof e=="string"?e:""}function dw(e,t){let r=ba.argv[1];if(r==null)return{code:1,output:""};try{return{code:0,output:Qh(ba.execPath,[r,...e],{cwd:t,encoding:"utf8",stdio:["ignore","pipe","pipe"]})}}catch(n){let o=cw.safeParse(n);if(!o.success)return{code:1,output:""};let i=`${Sa(o.data.stdout)}${Sa(o.data.stderr)}`;return{code:o.data.status??1,output:i}}}import{z as ka}from"zod";var uw=ka.looseObject({skill:ka.string()}),Ra=N("PostToolUse",e=>{if(e.tool_name!=="Skill")return;let t=uw.safeParse(e.tool_input);if(!t.success)return;let r=/^ripplo:(.+)$/.exec(t.data.skill);if(r==null)return;let n=r[1];n!=null&&I(e.cwd)&&ia(e.cwd,e.session_id,n)});vw();$n(process.cwd());var Pa={"coverage-nudge":Js,"exit-plan-gate":Ys,"plan-reminder":Xs,"post-edit-flag-stubs":ea,"post-edit-lint":ra,"pre-bash-hooks-pause-gate":oa,"pre-bash-run-gate":ca,"pre-edit-ripplo-skill-gate":ua,"pre-edit-scope-gate":fa,"pre-edit-watch-gate":ya,"scope-reminder":ha,"session-preamble":wa,"stop-enforce":va,"track-skill-load":Ra};async function fw(){await pw(mw(process.argv)).scriptName("ripplo").version("0.4.9").command("watch","Watch for run requests and execute locally",()=>{},()=>Us()).command("auth <subcommand>","Manage authentication",Sw).command("projects <subcommand>","Inspect Ripplo projects",bw).command("hooks <subcommand>","Pause or resume Ripplo hooks",ww).command("init","Scaffold .ripplo/ in this project",e=>e.option("project",{type:"string"}).option("env",{type:"string"}).option("app-url",{type:"string"}).option("engine-url",{type:"string"}),e=>$s({appUrl:e["app-url"],engineUrl:e["engine-url"],envFile:e.env,projectId:e.project})).command("run [ids..]","Run tests in parallel",e=>{let t=[];return e.positional("ids",{array:!0,default:t,describe:"Test ids to run (all if omitted)",type:"string"})},e=>Os(e.ids)).command("lint [ids..]","Compile and lint tests (all or specific ids)",e=>{let t=[];return e.positional("ids",{array:!0,default:t,describe:"Test ids to lint (all if omitted)",type:"string"}).option("require-implemented",{array:!0,default:t,describe:"Test ids that must not be .notImplemented() \u2014 fails if any still are",type:"string"})},e=>js({ids:e.ids,requireImplemented:e["require-implemented"]})).command("flake-detect <id>","Run N times to detect flakiness",e=>e.positional("id",{demandOption:!0,type:"string"}).option("runs",{default:10,type:"number"}),e=>vs({id:e.id,runs:e.runs})).command("sync","Push the compiled .ripplo/ resources to the server (no run)",()=>{},()=>Ds()).command("compile","Compile the DSL and write .ripplo/ripplo.lock",e=>e.option("check",{default:!1,describe:"Exit non-zero if the lockfile is missing or stale (does not write)",type:"boolean"}),e=>Zi({check:e.check})).command("cover","Audit all coverage statements",()=>{},()=>os()).command("doctor","Check project health",()=>{},()=>hs()).command("status","Report unimplemented tests and preconditions",e=>e.option("format",{choices:["json","summary"],default:"json",describe:"Output format"}),e=>qs({format:e.format})).command("scope <subcommand>","Manage testing scope",hw).command("hook <name>","Internal: run a Claude Code plugin hook",e=>e.positional("name",{choices:Object.keys(Pa),demandOption:!0,type:"string"}),e=>gw(e.name)).strict().help().parse()}async function gw(e){let t=Pa[e];t==null&&(process.stderr.write(`Unknown hook: ${e}
687
687
  `),process.exit(1));let r=await yw(),n=r.trim()===""?{}:JSON.parse(r),o=await t.run(n);o!=null&&process.stdout.write(JSON.stringify(o))}function yw(){return new Promise((e,t)=>{if(process.stdin.isTTY){e("");return}let r=[];process.stdin.on("data",n=>r.push(n)),process.stdin.on("end",()=>{e(Buffer.concat(r).toString("utf8"))}),process.stdin.on("error",t)})}fw().catch(e=>{process.stderr.write(`${e instanceof Error?e.message:String(e)}
688
688
  `),process.exit(1)});function hw(e){return e.command("status","Print the current scope",t=>t.option("format",{choices:["json","text"],default:"text",describe:"Output format"}),t=>Vs({format:t.format})).command("add <test-ids..>","Bind one or more existing tests (stubs or implemented) to scope as agent intent",t=>{let r=[];return t.positional("test-ids",{array:!0,default:r,demandOption:!0,describe:"Slugs of existing workflows",type:"string"})},t=>Fs({testIds:t["test-ids"]})).command("link <id> <test-id>","Link an existing scope item to a test",t=>t.positional("id",{demandOption:!0,describe:"Scope item id",type:"string"}).positional("test-id",{demandOption:!0,describe:"Slug of the workflow to link",type:"string"}),t=>Ms({id:t.id,testId:t["test-id"]})).command("remove <ids..>","Remove one or more scope items by id",t=>{let r=[];return t.positional("ids",{array:!0,default:r,demandOption:!0,describe:"Scope item ids",type:"string"})},t=>Hs({ids:t.ids})).demandCommand(1)}function ww(e){return e.command("pause","Disable all Ripplo pre-edit gates and stop enforcement until resumed",()=>{},()=>ks()).command("resume","Re-enable Ripplo hooks paused via `ripplo hooks pause`",()=>{},()=>Rs()).demandCommand(1)}function bw(e){return e.command("list","List projects you have access to (JSON)",()=>{},()=>Ns()).demandCommand(1)}function Sw(e){return e.command("login","Authenticate via device flow",()=>{},()=>Ci()).command("status","Show authentication status",()=>{},()=>Ei()).command("logout","Remove the saved token",()=>{},()=>{Ti()}).demandCommand(1)}function vw(){let e=process.cwd(),t=er(e);t!=null&&t!==e&&(process.chdir(t),process.stderr.write(`ripplo: resolved .ripplo/ at ${t}
689
689
  `))}export{fw as main};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ripplo",
3
- "version": "0.4.8",
3
+ "version": "0.4.9",
4
4
  "description": "CLI for Ripplo — AI-powered end-to-end testing",
5
5
  "type": "module",
6
6
  "homepage": "https://ripplo.ai",
@@ -50,9 +50,9 @@
50
50
  "tsup": "^8.5.1",
51
51
  "@ripplo/eslint-config": "0.0.0",
52
52
  "@ripplo/spec": "^0.0.0",
53
- "@ripplo/graphql": "^0.0.0",
53
+ "@ripplo/testing": "^0.4.4",
54
54
  "@ripplo/runtime": "^0.0.0",
55
- "@ripplo/testing": "^0.4.4"
55
+ "@ripplo/graphql": "^0.0.0"
56
56
  },
57
57
  "scripts": {
58
58
  "dev": "tsx watch src/index.ts",