ripplo 0.5.1 → 0.5.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.
Files changed (2) hide show
  1. package/dist/index.js +1 -1
  2. package/package.json +3 -3
package/dist/index.js CHANGED
@@ -728,7 +728,7 @@ ${w("create")}`}function ow(e){let t=sw(["run"],e);if(t.code===0)return null;let
728
728
  `).filter(n=>/FAILED/.test(n)).join(`
729
729
  `);return r.length===0?null:`--- Ripplo Run Failures (scope) ---
730
730
  ${r}
731
- Artifacts: .ripplo/debug/<runId>/. ${w("debug")}`}var iw=ur.object({status:ur.number().nullish(),stderr:ur.unknown().optional(),stdout:ur.unknown().optional()});function Xs(e){return e instanceof Buffer?e.toString("utf8"):typeof e=="string"?e:""}function sw(e,t){let r=Ys.argv[1];if(r==null)return{code:1,output:""};try{return{code:0,output:Kh(Ys.execPath,[r,...e],{cwd:t,encoding:"utf8",stdio:["ignore","pipe","pipe"]})}}catch(n){let o=iw.safeParse(n);if(!o.success)return{code:1,output:""};let i=`${Xs(o.data.stdout)}${Xs(o.data.stderr)}`;return{code:o.data.status??1,output:i}}}import{z as Zs}from"zod";var aw=Zs.looseObject({skill:Zs.string()}),ea=I("PostToolUse",e=>{if(e.tool_name!=="Skill")return;let t=aw.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&&A(e.cwd)&&Ls(e.cwd,e.session_id,n)});hw();Fo(process.cwd());$r();var ta={"coverage-nudge":xs,"exit-plan-gate":Cs,"plan-reminder":Ts,"post-edit-flag-stubs":$s,"post-edit-lint":Ns,"pre-bash-hooks-pause-gate":Ds,"pre-bash-run-gate":Fs,"pre-edit-ripplo-skill-gate":Bs,"pre-edit-scope-gate":qs,"pre-edit-watch-gate":Gs,"scope-reminder":Ks,"session-preamble":Js,"stop-enforce":Qs,"track-skill-load":ea};async function uw(){await lw(cw(process.argv)).scriptName("ripplo").version("0.5.1").command("watch","Watch for run requests and execute locally",()=>{},()=>ys()).command("auth <subcommand>","Manage authentication",yw).command("projects <subcommand>","Inspect Ripplo projects",gw).command("hooks <subcommand>","Pause or resume Ripplo hooks",fw).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=>is({appUrl:e["app-url"],engineUrl:e["engine-url"],envFile:e.env,projectId:e.project})).command("run [ids..]","Run tests (defaults to scope; auto-adds dirty tests)",e=>{let t=[];return e.positional("ids",{array:!0,default:t,describe:"Test ids to run (defaults to dev-session scope)",type:"string"}).option("all",{default:!1,describe:"Run every test in the dev session (expensive)",type:"boolean"})},e=>us({all:e.all,ids: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=>ls({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=>Xi({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=>xi({check:e.check})).command("cover","Audit all coverage statements",()=>{},()=>Ii()).command("doctor","Check project health",()=>{},()=>Wi()).command("status","Report unimplemented tests and preconditions",e=>e.option("format",{choices:["json","summary"],default:"json",describe:"Output format"}),e=>ks({format:e.format})).command("scope <subcommand>","Manage testing scope",mw).command("hook <name>","Internal: run a Claude Code plugin hook",e=>e.positional("name",{choices:Object.keys(ta),demandOption:!0,type:"string"}),e=>dw(e.name)).strict().help().parse()}async function dw(e){let t=ta[e];t==null&&(process.stderr.write(`Unknown hook: ${e}
731
+ Artifacts: .ripplo/debug/<runId>/. ${w("debug")}`}var iw=ur.object({status:ur.number().nullish(),stderr:ur.unknown().optional(),stdout:ur.unknown().optional()});function Xs(e){return e instanceof Buffer?e.toString("utf8"):typeof e=="string"?e:""}function sw(e,t){let r=Ys.argv[1];if(r==null)return{code:1,output:""};try{return{code:0,output:Kh(Ys.execPath,[r,...e],{cwd:t,encoding:"utf8",stdio:["ignore","pipe","pipe"]})}}catch(n){let o=iw.safeParse(n);if(!o.success)return{code:1,output:""};let i=`${Xs(o.data.stdout)}${Xs(o.data.stderr)}`;return{code:o.data.status??1,output:i}}}import{z as Zs}from"zod";var aw=Zs.looseObject({skill:Zs.string()}),ea=I("PostToolUse",e=>{if(e.tool_name!=="Skill")return;let t=aw.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&&A(e.cwd)&&Ls(e.cwd,e.session_id,n)});hw();Fo(process.cwd());$r();var ta={"coverage-nudge":xs,"exit-plan-gate":Cs,"plan-reminder":Ts,"post-edit-flag-stubs":$s,"post-edit-lint":Ns,"pre-bash-hooks-pause-gate":Ds,"pre-bash-run-gate":Fs,"pre-edit-ripplo-skill-gate":Bs,"pre-edit-scope-gate":qs,"pre-edit-watch-gate":Gs,"scope-reminder":Ks,"session-preamble":Js,"stop-enforce":Qs,"track-skill-load":ea};async function uw(){await lw(cw(process.argv)).scriptName("ripplo").version("0.5.2").command("watch","Watch for run requests and execute locally",()=>{},()=>ys()).command("auth <subcommand>","Manage authentication",yw).command("projects <subcommand>","Inspect Ripplo projects",gw).command("hooks <subcommand>","Pause or resume Ripplo hooks",fw).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=>is({appUrl:e["app-url"],engineUrl:e["engine-url"],envFile:e.env,projectId:e.project})).command("run [ids..]","Run tests (defaults to scope; auto-adds dirty tests)",e=>{let t=[];return e.positional("ids",{array:!0,default:t,describe:"Test ids to run (defaults to dev-session scope)",type:"string"}).option("all",{default:!1,describe:"Run every test in the dev session (expensive)",type:"boolean"})},e=>us({all:e.all,ids: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=>ls({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=>Xi({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=>xi({check:e.check})).command("cover","Audit all coverage statements",()=>{},()=>Ii()).command("doctor","Check project health",()=>{},()=>Wi()).command("status","Report unimplemented tests and preconditions",e=>e.option("format",{choices:["json","summary"],default:"json",describe:"Output format"}),e=>ks({format:e.format})).command("scope <subcommand>","Manage testing scope",mw).command("hook <name>","Internal: run a Claude Code plugin hook",e=>e.positional("name",{choices:Object.keys(ta),demandOption:!0,type:"string"}),e=>dw(e.name)).strict().help().parse()}async function dw(e){let t=ta[e];t==null&&(process.stderr.write(`Unknown hook: ${e}
732
732
  `),process.exit(1));let r=await pw(),n=r.trim()===""?{}:JSON.parse(r),o=await t.run(n);o!=null&&process.stdout.write(JSON.stringify(o))}function pw(){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)})}uw().catch(e=>{process.stderr.write(`${e instanceof Error?e.message:String(e)}
733
733
  `),process.exit(1)});function mw(e){return e.command("status","Print the current scope",t=>t.option("format",{choices:["json","text"],default:"text",describe:"Output format"}),t=>ws({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=>bs({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=>vs({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=>Ss({ids:t.ids})).demandCommand(1)}function fw(e){return e.command("pause","Disable all Ripplo pre-edit gates and stop enforcement until resumed",()=>{},()=>Qi()).command("resume","Re-enable Ripplo hooks paused via `ripplo hooks pause`",()=>{},()=>Zi()).demandCommand(1)}function gw(e){return e.command("list","List projects you have access to (JSON)",()=>{},()=>cs()).demandCommand(1)}function yw(e){return e.command("login","Authenticate via device flow",()=>{},()=>zo()).command("status","Show authentication status",()=>{},()=>Go()).command("logout","Remove the saved token",()=>{},()=>{Ko()}).demandCommand(1)}function hw(){let e=process.cwd(),t=yr(e);t!=null&&t!==e&&(process.chdir(t),process.stderr.write(`ripplo: resolved .ripplo/ at ${t}
734
734
  `))}export{uw as main};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ripplo",
3
- "version": "0.5.1",
3
+ "version": "0.5.2",
4
4
  "description": "CLI for Ripplo — AI-powered end-to-end testing",
5
5
  "type": "module",
6
6
  "homepage": "https://ripplo.ai",
@@ -48,10 +48,10 @@
48
48
  "eslint": "catalog:",
49
49
  "tsup": "^8.5.1",
50
50
  "@ripplo/eslint-config": "0.0.0",
51
+ "@ripplo/graphql": "^0.0.0",
51
52
  "@ripplo/runtime": "^0.0.0",
52
53
  "@ripplo/spec": "^0.0.0",
53
- "@ripplo/testing": "^0.5.1",
54
- "@ripplo/graphql": "^0.0.0"
54
+ "@ripplo/testing": "^0.5.2"
55
55
  },
56
56
  "scripts": {
57
57
  "dev": "tsx watch src/index.ts",