create-agentic-starter 0.1.2 → 0.1.3
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/index.js +32 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{mkdir as
|
|
2
|
+
import{mkdir as f,readFile as h,rm as k,writeFile as c}from"fs/promises";import i from"path";var y="README.md",j=".gitignore",p="<!-- from create-agentic-starter:start -->",l="<!-- from create-agentic-starter:end -->",u="# from create-agentic-starter:start",g="# from create-agentic-starter:end",v=[".agentic","AGENTS.md"],x=()=>({"AGENTS.md":`# Agentic Starter Guide
|
|
3
3
|
|
|
4
4
|
This scaffold creates a reusable AI working area under \`.agentic/\` for project kick-off and pre-delivery documentation.
|
|
5
5
|
|
|
@@ -248,4 +248,34 @@ Read:
|
|
|
248
248
|
4. Ask only the minimum blocking questions.
|
|
249
249
|
|
|
250
250
|
When done, tell the user the v1 workflow is complete and list the generated files.
|
|
251
|
-
`}),
|
|
251
|
+
`}),b=`${p}
|
|
252
|
+
## Agentic Starter
|
|
253
|
+
|
|
254
|
+
This project includes a reusable AI workflow scaffold under \`.agentic/\`.
|
|
255
|
+
|
|
256
|
+
Start every new AI session with:
|
|
257
|
+
|
|
258
|
+
\`@.agentic/init.md\`
|
|
259
|
+
|
|
260
|
+
Command flow:
|
|
261
|
+
|
|
262
|
+
1. \`@.agentic/init.md\`
|
|
263
|
+
2. \`@.agentic/commands/project-requirements.md\`
|
|
264
|
+
3. \`@.agentic/commands/architecture.md\`
|
|
265
|
+
4. \`@.agentic/commands/create-brd.md\`
|
|
266
|
+
5. \`@.agentic/commands/create-frd.md\`
|
|
267
|
+
6. \`@.agentic/commands/create-estimate.md\`
|
|
268
|
+
7. \`@.agentic/commands/create-proposal.md\`
|
|
269
|
+
${l}
|
|
270
|
+
`,A=`${u}
|
|
271
|
+
.agentic/workspace/documents/
|
|
272
|
+
.agentic/workspace/memory/
|
|
273
|
+
${g}
|
|
274
|
+
`,R=[".agentic",".agentic/commands",".agentic/workspace",".agentic/workspace/project",".agentic/workspace/memory",".agentic/workspace/documents"];async function q(e){await Promise.all(v.map(t=>k(i.join(e,t),{recursive:!0,force:!0})))}async function E(e){await Promise.all(R.map(t=>f(i.join(e,t),{recursive:!0})))}async function I(e){let t=x();await Promise.all(Object.entries(t).map(([r,n])=>c(i.join(e,r),n,"utf8")))}function T(e,t,r,n){let a=new RegExp(`${m(r)}[\\s\\S]*?${m(n)}\\n?`,"m");if(a.test(e))return e.replace(a,`${t}
|
|
275
|
+
`);let o=e.endsWith(`
|
|
276
|
+
`)?`
|
|
277
|
+
`:`
|
|
278
|
+
|
|
279
|
+
`;return`${e}${o}${t}
|
|
280
|
+
`}function m(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}async function d(e,t,r,n,a){let o=i.join(e,t);try{let s=await h(o,"utf8"),w=T(s,r,n,a);await c(o,w,"utf8")}catch(s){if(s.code!=="ENOENT")throw s;await c(o,`${r}
|
|
281
|
+
`,"utf8")}}async function S(){let e=process.cwd();await q(e),await E(e),await I(e),await d(e,y,b,p,l),await d(e,j,A,u,g),console.log(""),console.log("create-agentic-starter: scaffold created successfully."),console.log(`Project folder: ${e}`),console.log(""),console.log("Next steps:"),console.log("1. Open your AI tool in this folder."),console.log("2. Start a new chat with @.agentic/init.md"),console.log("")}S().catch(e=>{let t=e instanceof Error?e.message:String(e);console.error(`create-agentic-starter: failed to scaffold project. ${t}`),process.exitCode=1});
|