create-cooktype-app 0.0.13 → 0.0.14
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/dist/cli.js
CHANGED
|
@@ -22,7 +22,7 @@ import"./chunk-WOPP5T3O.js";function se(e,n){let t=e.env?.[n];return typeof t=="
|
|
|
22
22
|
`)+`
|
|
23
23
|
`,usesFlag:r=>r in n||r in t}}function*ct(e,n,t){let{brief:c,fullDescription:r,hideRoute:i}=n,{headers:o}=t.text;yield t.ansiColor?`\x1B[1m${o.usage}\x1B[22m`:o.usage;for(let[a,f]of Object.entries(e))if(!i||!i[a]||t.includeHidden){let m=t.config.caseStyle==="convert-camel-to-kebab"?A(a):a;yield` ${f.formatUsageLine({...t,prefix:[...t.prefix,m]})}`}let u=t.prefix.join(" ");for(let a of pe(t))yield` ${u} ${a}`;if(yield"",yield r??c,t.aliases&&t.aliases.length>0){let a=t.prefix.slice(0,-1).join(" ");yield"",yield t.ansiColor?`\x1B[1m${o.aliases}\x1B[22m`:o.aliases;for(let f of t.aliases)yield` ${a} ${f}`}yield"",yield t.ansiColor?`\x1B[1m${o.flags}\x1B[22m`:o.flags;for(let a of me({},{},t))yield` ${a}`;yield"",yield t.ansiColor?`\x1B[1m${o.commands}\x1B[22m`:o.commands;let s=Object.entries(e).filter(([a])=>!i||!i[a]||t.includeHidden).map(([a,f])=>({routeName:T(a,t.config.caseStyle),brief:f.brief,hidden:i&&i[a]})),d=O(s.map(a=>t.ansiColor?[a.hidden?`\x1B[90m${a.routeName}\x1B[39m`:`\x1B[97m${a.routeName}\x1B[39m`,a.hidden?`\x1B[90m${a.brief}\x1B[39m`:`\x1B[03m${a.brief}\x1B[23m`]:[a.routeName,a.brief]),[" "]);for(let a of d)yield` ${a}`}function ye({routes:e,defaultCommand:n,docs:t,aliases:c}){if(Object.entries(e).length===0)throw new g("Route map must contain at least one route");let r=c??{},i=new Map;for(let[l,s]of Object.entries(r)){if(l in e)throw new g(`Cannot use "${l}" as an alias when a route with that name already exists`);let d=i.get(s)??[];i.set(s,[...d,l])}let o=n?e[n]:void 0;if(o&&o.kind===P)throw new g(`Cannot use "${n}" as the default command because it is not a Command`);let u=l=>{if(l in r)return r[l];if(l in e)return l};return{kind:P,get brief(){return t.brief},get fullDescription(){return t.fullDescription},formatUsageLine(l){let s=this.getAllEntries().filter(d=>!d.hidden).map(d=>d.name[l.config.caseStyle]);return`${l.prefix.join(" ")} ${s.join("|")} ...`},formatHelp:l=>[...ct(e,t,l)].join(`
|
|
24
24
|
`)+`
|
|
25
|
-
`,getDefaultCommand:()=>o,getOtherAliasesForInput:(l,s)=>{if(n){if(l===n)return{original:[""],"convert-camel-to-kebab":[""]};if(l==="")return{original:[n],"convert-camel-to-kebab":[n]}}let d=_(l),a=u(l);if(!a&&s==="allow-kebab-for-camel"&&(a=u(d)),!a)return{original:[],"convert-camel-to-kebab":[]};let f=[a,...i.get(a)??[]].filter(m=>m!==l&&m!==d);return{original:f,"convert-camel-to-kebab":f.map(A)}},getRoutingTargetForInput:l=>{let s=l in r?r[l]:l;return e[s]},getAllEntries(){let l=t.hideRoute;return Object.entries(e).map(([s,d])=>({name:{original:s,"convert-camel-to-kebab":A(s)},target:d,aliases:i.get(s)??[],hidden:l?.[s]??!1}))}}}async function be(e,n,t){let c=await Ye(e,n,t);t.process.exitCode=c}import ut from"node:fs";import dt from"node:os";import ft from"node:path";function ve(e){return{process:e,os:dt,fs:ut,path:ft}}var xe="create-cooktype-app";var ge="CLI to scaffold AI-promptable monorepos with Next.js, Convex, and Shadcn/ui";var we="0.0.
|
|
25
|
+
`,getDefaultCommand:()=>o,getOtherAliasesForInput:(l,s)=>{if(n){if(l===n)return{original:[""],"convert-camel-to-kebab":[""]};if(l==="")return{original:[n],"convert-camel-to-kebab":[n]}}let d=_(l),a=u(l);if(!a&&s==="allow-kebab-for-camel"&&(a=u(d)),!a)return{original:[],"convert-camel-to-kebab":[]};let f=[a,...i.get(a)??[]].filter(m=>m!==l&&m!==d);return{original:f,"convert-camel-to-kebab":f.map(A)}},getRoutingTargetForInput:l=>{let s=l in r?r[l]:l;return e[s]},getAllEntries(){let l=t.hideRoute;return Object.entries(e).map(([s,d])=>({name:{original:s,"convert-camel-to-kebab":A(s)},target:d,aliases:i.get(s)??[],hidden:l?.[s]??!1}))}}}async function be(e,n,t){let c=await Ye(e,n,t);t.process.exitCode=c}import ut from"node:fs";import dt from"node:os";import ft from"node:path";function ve(e){return{process:e,os:dt,fs:ut,path:ft}}var xe="create-cooktype-app";var ge="CLI to scaffold AI-promptable monorepos with Next.js, Convex, and Shadcn/ui";var we="0.0.14";var $e=he({loader:async()=>import("./impl-7BY4KOWL.js"),parameters:{positional:{kind:"tuple",parameters:[{brief:"project-name",parse:String,optional:!0}]},flags:{git:{kind:"boolean",brief:"Initialize git repository",default:!0},install:{kind:"boolean",brief:"Run pnpm install after scaffold",default:!0},"convex-init":{kind:"boolean",brief:"Run Convex setup",default:!0}}},docs:{brief:"Create a new AI-promptable monorepo"}});var mt=ye({routes:{create:$e},docs:{brief:ge},aliases:{}}),Ce=ue(mt,{name:xe,versionInfo:{currentVersion:we}});var Q=process.argv.slice(2),Y=Q[0],pt=["create","help","--help","-h","version","--version","-v"];(!Y||!Y.startsWith("-")&&!pt.includes(Y))&&Q.unshift("create");await be(Ce,Q,ve(process));
|
|
26
26
|
/*! Bundled license information:
|
|
27
27
|
|
|
28
28
|
@stricli/core/dist/index.js:
|