eser 4.1.47 → 4.1.48
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/chunks/{add-V7YYHLFH.js → add-HBUORTI5.js} +1 -1
- package/chunks/{ajan-JKACPKCP.js → ajan-CL22MZYV.js} +1 -1
- package/chunks/{approve-URMQ77UE.js → approve-UWBYGXCF.js} +1 -1
- package/chunks/{ask-UCPMMIAF.js → ask-M3VS3GIJ.js} +1 -1
- package/chunks/{block-5NWZBEXW.js → block-W76WKMS3.js} +1 -1
- package/chunks/{browser-JGBNWUEQ.js → browser-D536WJU3.js} +1 -1
- package/chunks/{build-BUB6OJCI.js → build-DPBRNANI.js} +2 -2
- package/chunks/{bun-HIMXX54I.js → bun-7XJSUU6Z.js} +1 -1
- package/chunks/{cancel-V6OK6U73.js → cancel-46C7E5N7.js} +1 -1
- package/chunks/{changelog-gen-TEI4IBNO.js → changelog-gen-627BV77Z.js} +1 -1
- package/chunks/{chunk-W7OYXLGD.js → chunk-2LF7QSIN.js} +1 -1
- package/chunks/{chunk-BJLUDX4R.js → chunk-2TANTKYS.js} +1 -1
- package/chunks/{chunk-W724KQYO.js → chunk-2YTW3JQ6.js} +1 -1
- package/chunks/{chunk-3AA3RXKD.js → chunk-2ZYCRMUT.js} +1 -1
- package/chunks/{chunk-26ZFSXSK.js → chunk-3D5TBTM3.js} +1 -1
- package/chunks/{chunk-3IZX4OZ7.js → chunk-3OG2MEF2.js} +1 -1
- package/chunks/{chunk-R7FADWXC.js → chunk-4LQG2WOJ.js} +1 -1
- package/chunks/{chunk-L2E2H7YT.js → chunk-4X4NHXFE.js} +1 -1
- package/chunks/{chunk-F44CX3KC.js → chunk-5JV6KQMP.js} +2 -2
- package/chunks/{chunk-MCWDLVWU.js → chunk-6BILFSH2.js} +1 -1
- package/chunks/{chunk-WJKE6XHF.js → chunk-6DBKPC2O.js} +1 -1
- package/chunks/{chunk-BQT5RJZB.js → chunk-6G6UVWJN.js} +1 -1
- package/chunks/{chunk-RHEYIO4O.js → chunk-73IMECRI.js} +1 -1
- package/chunks/{chunk-HCYIL6IJ.js → chunk-7KFSTOXR.js} +1 -1
- package/chunks/{chunk-PLMZ3FYS.js → chunk-7NKYCWAA.js} +1 -1
- package/chunks/{chunk-6E6JUBFH.js → chunk-ALFFE37K.js} +1 -1
- package/chunks/{chunk-JLRVMMMH.js → chunk-ATYDQCCJ.js} +1 -1
- package/chunks/{chunk-A2IW6BXT.js → chunk-C2IORZTF.js} +1 -1
- package/chunks/{chunk-SRWZLNT6.js → chunk-C7NZBKCW.js} +1 -1
- package/chunks/{chunk-YBCZC5KZ.js → chunk-CVDLYIOW.js} +1 -1
- package/chunks/{chunk-37GFWQQ3.js → chunk-DLBRD3UT.js} +1 -1
- package/chunks/{chunk-3QH27NOC.js → chunk-DM6U63HP.js} +1 -1
- package/chunks/{chunk-ORAOSL2W.js → chunk-DPZJWN2Y.js} +1 -1
- package/chunks/{chunk-GWZUQPFD.js → chunk-EQUPVWVY.js} +1 -1
- package/chunks/{chunk-JUOSGSVB.js → chunk-FNPBHLLZ.js} +1 -1
- package/chunks/{chunk-HVTJ5LVU.js → chunk-FZ5WFU6R.js} +1 -1
- package/chunks/{chunk-BLXGL5MA.js → chunk-GVTM4EOU.js} +1 -1
- package/chunks/{chunk-7XVIW7H6.js → chunk-H6P3EACV.js} +1 -1
- package/chunks/{chunk-EGEJQP7D.js → chunk-IIFFSCDJ.js} +1 -1
- package/chunks/{chunk-4QDEJUAF.js → chunk-IZUADMIU.js} +1 -1
- package/chunks/{chunk-LWWZT2AB.js → chunk-J5HFD7AQ.js} +1 -1
- package/chunks/{chunk-ZCQ5CISX.js → chunk-JFKHBLJB.js} +1 -1
- package/chunks/{chunk-YA4IPF62.js → chunk-JO4JKJ7R.js} +1 -1
- package/chunks/{chunk-5PH7JRXR.js → chunk-KHBIOZJE.js} +1 -1
- package/chunks/{chunk-MBCPGD5L.js → chunk-L5OC7F24.js} +1 -1
- package/chunks/{chunk-EKUJSZIR.js → chunk-LJ7A5HYR.js} +1 -1
- package/chunks/{chunk-OWV223WQ.js → chunk-LLA75EMV.js} +1 -1
- package/chunks/{chunk-6PRIUPN4.js → chunk-LWQPFCWC.js} +1 -1
- package/chunks/{chunk-NFZWSVJM.js → chunk-LYPDFFKK.js} +1 -1
- package/chunks/{chunk-ENTSZDR6.js → chunk-MTCPFQ5I.js} +1 -1
- package/chunks/{chunk-CXTOTN4Z.js → chunk-MW3RJU6I.js} +1 -1
- package/chunks/{chunk-JHEL4OFF.js → chunk-N4NDBIQS.js} +1 -1
- package/chunks/{chunk-G5VGZMKA.js → chunk-NMEPQK3T.js} +1 -1
- package/chunks/{chunk-TEOMM3RD.js → chunk-NMSD4ZXJ.js} +1 -1
- package/chunks/{chunk-RVJZFWN7.js → chunk-NTY267SI.js} +1 -1
- package/chunks/{chunk-3QF3I2RD.js → chunk-NVPQJFAI.js} +1 -1
- package/chunks/{chunk-LGNGLAV3.js → chunk-O325ZU5M.js} +1 -1
- package/chunks/{chunk-3PCHQM4S.js → chunk-OLHBVIWG.js} +1 -1
- package/chunks/{chunk-5QRJ7OJK.js → chunk-R3UCRXDC.js} +1 -1
- package/chunks/{chunk-4ZVFKZ5S.js → chunk-R4GKIRAI.js} +1 -1
- package/chunks/{chunk-CNHUVWV5.js → chunk-RHVDIXOM.js} +1 -1
- package/chunks/{chunk-MJ2IPSAE.js → chunk-RNFCAHVL.js} +1 -1
- package/chunks/{chunk-ZC4F4MYU.js → chunk-SHN5MT56.js} +1 -1
- package/chunks/{chunk-Z5P6PXQV.js → chunk-TFRONHJA.js} +1 -1
- package/chunks/{chunk-YW377352.js → chunk-TMMAF763.js} +1 -1
- package/chunks/{chunk-VWQLQJVX.js → chunk-TW23CULJ.js} +1 -1
- package/chunks/{chunk-F2YHX6DL.js → chunk-TZDEJTLC.js} +1 -1
- package/chunks/{chunk-OAT2D23A.js → chunk-UEMWZOIU.js} +1 -1
- package/chunks/{chunk-TYUSWY27.js → chunk-UGYRUVUH.js} +1 -1
- package/chunks/{chunk-AP7A6Y5Z.js → chunk-ULIMXXRY.js} +1 -1
- package/chunks/{chunk-4HXAC4WN.js → chunk-WI2RW3YL.js} +1 -1
- package/chunks/{chunk-Y3XXSUFP.js → chunk-WTMV5GTZ.js} +1 -1
- package/chunks/{chunk-FW3ETRQ5.js → chunk-WZHVKEPB.js} +1 -1
- package/chunks/{chunk-F35K7YVH.js → chunk-X3L6GBUX.js} +1 -1
- package/chunks/{chunk-RGT7SMKJ.js → chunk-XOMPQOI6.js} +1 -1
- package/chunks/{chunk-VSTGSR3G.js → chunk-XUV7CW3L.js} +1 -1
- package/chunks/chunk-YACXTCWF.js +2 -0
- package/chunks/{chunk-F4G6QSSJ.js → chunk-YKEVDAWS.js} +1 -1
- package/chunks/{chunk-HP5W5XT6.js → chunk-ZNP3NXAD.js} +1 -1
- package/chunks/claude-code-UJYCO6CN.js +2 -0
- package/chunks/{clone-YEBQK7CG.js → clone-455UAECS.js} +1 -1
- package/chunks/{cmd-2DAVTVOF.js → cmd-QE4P4DS4.js} +1 -1
- package/chunks/{commitmsg-3NLTGBA7.js → commitmsg-57EMHAFY.js} +2 -2
- package/chunks/{concern-RNNRCADI.js → concern-I6LCWEIC.js} +1 -1
- package/chunks/{deno-XQHOVHKR.js → deno-JAQWMICD.js} +1 -1
- package/chunks/{dev-GHSKFRDU.js → dev-JM7NU24M.js} +2 -2
- package/chunks/{done-VSVUSYIS.js → done-A5VWIFOF.js} +1 -1
- package/chunks/{file-tools-shared-BGQUI7QP.js → file-tools-shared-YKDNDDHR.js} +1 -1
- package/chunks/{free-L4KB3WSS.js → free-5NMWMMYS.js} +1 -1
- package/chunks/{gh-L3FPMN5H.js → gh-DJ2YTDQX.js} +2 -2
- package/chunks/{gh-contributors-NT5WW72V.js → gh-contributors-SXUFX3SO.js} +1 -1
- package/chunks/{init-EL6YCHIE.js → init-GBMYF3YG.js} +3 -3
- package/chunks/{init-II65LYMV.js → init-M3P2QCX2.js} +1 -1
- package/chunks/{install-YVHT6UAG.js → install-USGLFPAU.js} +1 -1
- package/chunks/{invoke-hook-QEE3PJBH.js → invoke-hook-6BKTP2JY.js} +1 -1
- package/chunks/kiro-V6SMU4OL.js +2 -0
- package/chunks/{list-BOLPKAEY.js → list-M5DGQG46.js} +1 -1
- package/chunks/{list-VEGVTAKQ.js → list-NX7RRO6R.js} +1 -1
- package/chunks/{list-AKS7CUO3.js → list-ZVCGDRUH.js} +1 -1
- package/chunks/{load-config-G4DHKB5K.js → load-config-JZNJVJXH.js} +1 -1
- package/chunks/{main-PTEEAWXX.js → main-JAGIKKVD.js} +2 -2
- package/chunks/{manager-ARXVYR4H.js → manager-GN6J4AUV.js} +5 -5
- package/chunks/manifest-3GT2RMQL.js +2 -0
- package/chunks/{mod-RF5F5WS2.js → mod-2WMXZZGJ.js} +2 -2
- package/chunks/{mod-DXA25A4J.js → mod-4XKQZL6W.js} +1 -1
- package/chunks/{mod-MVH3RFS3.js → mod-5NDTGNVM.js} +1 -1
- package/chunks/{mod-ICWGLZBQ.js → mod-7ICCX4OY.js} +1 -1
- package/chunks/{mod-AD5UWQSM.js → mod-KPIOBBDD.js} +1 -1
- package/chunks/{mod-RMDGRCBK.js → mod-NSL6IJRQ.js} +1 -1
- package/chunks/{mod-QWYXFGRG.js → mod-OG7BBJP4.js} +1 -1
- package/chunks/mod-QCXWBSGJ.js +2 -0
- package/chunks/{mod-YH5Z6G4Q.js → mod-TRSW5SEU.js} +1 -1
- package/chunks/{mod-BKHQAEVL.js → mod-VZT7JWPZ.js} +1 -1
- package/chunks/{mod-PZSJGUM7.js → mod-W225AUFE.js} +1 -1
- package/chunks/{new-VGL3IRFP.js → new-SS67ZKMK.js} +1 -1
- package/chunks/{next-RYENG2XC.js → next-TIUOHHFS.js} +2 -2
- package/chunks/{node-ZGM6SXXI.js → node-WWA6BHRC.js} +1 -1
- package/chunks/ollama-DFG5G467.js +2 -0
- package/chunks/opencode-UA45VV3W.js +2 -0
- package/chunks/pack-7TGKWDRO.js +6 -0
- package/chunks/{purge-6IOKNHG6.js → purge-IKPQWHBC.js} +1 -1
- package/chunks/{recipe-applier-TTZEZGSC.js → recipe-applier-I2VBGHZU.js} +1 -1
- package/chunks/{registry-fetcher-SPENFEOH.js → registry-fetcher-TGWYJ5GN.js} +1 -1
- package/chunks/{release-6GDD5THZ.js → release-SEKFNXRA.js} +2 -2
- package/chunks/{release-notes-MZFILXWE.js → release-notes-UUCPVHBQ.js} +1 -1
- package/chunks/{release-tag-LGZEFMKJ.js → release-tag-F4B6ICW4.js} +1 -1
- package/chunks/{reopen-XDNX2XRX.js → reopen-G4IUIH73.js} +1 -1
- package/chunks/{reset-TDBHFTWW.js → reset-BJZ263XC.js} +1 -1
- package/chunks/{rule-DUOZIDNM.js → rule-PQ6WRV5W.js} +1 -1
- package/chunks/{run-OCYNXRVD.js → run-DAKF5SJN.js} +1 -1
- package/chunks/{run-YK7DTHKW.js → run-Y4ESAQUK.js} +1 -1
- package/chunks/{scripts-7VDHDKFK.js → scripts-VRQQ24O3.js} +1 -1
- package/chunks/{serve-5V65OPB2.js → serve-OGJIE344.js} +2 -2
- package/chunks/{server-R347ON4B.js → server-VCPSLFZ2.js} +1 -1
- package/chunks/{session-SOIP6NHS.js → session-CFDY73RJ.js} +1 -1
- package/chunks/{spec-Y6K7CSBK.js → spec-CYRR2XUA.js} +1 -1
- package/chunks/{status-SXWEDQTL.js → status-ZE2SA6FP.js} +1 -1
- package/chunks/{sync-5XW5FTWS.js → sync-N5STAT6M.js} +1 -1
- package/chunks/system-3236RFTI.js +2 -0
- package/chunks/{system-HNZLRJLH.js → system-6GEEPUXD.js} +1 -1
- package/chunks/{update-522VXIKX.js → update-VLYRDEH4.js} +1 -1
- package/chunks/validate-bom-ME2NQAP3.js +2 -0
- package/chunks/validate-case-conflict-QUNIB43P.js +2 -0
- package/chunks/validate-circular-deps-DLUCIW7T.js +2 -0
- package/chunks/validate-commit-msg-SRLJRTKU.js +2 -0
- package/chunks/validate-docs-43LWHLVW.js +2 -0
- package/chunks/validate-eof-RV3IK6ZM.js +2 -0
- package/chunks/validate-export-names-D5I5DZTN.js +2 -0
- package/chunks/validate-filenames-WNLZI2S6.js +2 -0
- package/chunks/validate-json-6KIMBNBJ.js +2 -0
- package/chunks/validate-large-files-UXP7AZCW.js +2 -0
- package/chunks/validate-licenses-BL6PNSBP.js +2 -0
- package/chunks/validate-line-endings-NYHXORRG.js +2 -0
- package/chunks/validate-merge-conflict-IWUP4ZMW.js +2 -0
- package/chunks/validate-mod-exports-VCV4VZ5F.js +2 -0
- package/chunks/validate-package-configs-6PGL2YGD.js +2 -0
- package/chunks/validate-secrets-JV4ZSOVR.js +2 -0
- package/chunks/validate-shebangs-YACNWUG7.js +2 -0
- package/chunks/validate-submodules-ZXID3VEK.js +2 -0
- package/chunks/validate-symlinks-QNMKPYUY.js +2 -0
- package/chunks/validate-toml-PV3G7EFD.js +2 -0
- package/chunks/validate-trailing-whitespace-5Q5SEHOD.js +2 -0
- package/chunks/validate-yaml-IOMFQTSQ.js +2 -0
- package/chunks/{versions-MFY62V25.js → versions-ROLQITT5.js} +1 -1
- package/chunks/{watch-DBB4W5AE.js → watch-4NXY7JEX.js} +1 -1
- package/chunks/{wontfix-D2ZHBGNH.js → wontfix-YSXRDPKA.js} +1 -1
- package/chunks/{workerd-LOWXXQEU.js → workerd-LH2MLWIF.js} +1 -1
- package/eser.js +1 -1
- package/package.json +7 -8
- package/chunks/chunk-ZER2RYWJ.js +0 -2
- package/chunks/claude-code-S2SGKOBE.js +0 -2
- package/chunks/kiro-LNQTCWQU.js +0 -2
- package/chunks/manifest-3VJ4O6HR.js +0 -2
- package/chunks/mod-GXNNOTTG.js +0 -2
- package/chunks/ollama-IRQSLTDB.js +0 -2
- package/chunks/opencode-74XXXUQ2.js +0 -2
- package/chunks/system-WX4PNZSQ.js +0 -2
- package/chunks/validate-bom-XA7KZWTH.js +0 -2
- package/chunks/validate-case-conflict-QWOT7276.js +0 -2
- package/chunks/validate-circular-deps-IAC3BSYO.js +0 -2
- package/chunks/validate-commit-msg-M42NIQLD.js +0 -2
- package/chunks/validate-docs-DXY4C23P.js +0 -2
- package/chunks/validate-eof-M3LGJL64.js +0 -2
- package/chunks/validate-export-names-BQAH7J4F.js +0 -2
- package/chunks/validate-filenames-WYIWPR5V.js +0 -2
- package/chunks/validate-json-S2J5SSZS.js +0 -2
- package/chunks/validate-large-files-X4D3CL42.js +0 -2
- package/chunks/validate-licenses-6LB6MLQU.js +0 -2
- package/chunks/validate-line-endings-NX2XXGTH.js +0 -2
- package/chunks/validate-merge-conflict-3ZNS7HS2.js +0 -2
- package/chunks/validate-mod-exports-72EWWWMT.js +0 -2
- package/chunks/validate-package-configs-55XAXICZ.js +0 -2
- package/chunks/validate-secrets-5V7V65JA.js +0 -2
- package/chunks/validate-shebangs-XVHLZJKY.js +0 -2
- package/chunks/validate-submodules-Z6WRSMS5.js +0 -2
- package/chunks/validate-symlinks-FWV2RFCM.js +0 -2
- package/chunks/validate-toml-DTGDAUSH.js +0 -2
- package/chunks/validate-trailing-whitespace-5QSYKA6L.js +0 -2
- package/chunks/validate-yaml-SKE7CDCP.js +0 -2
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{b as v}from"./chunk-
|
|
2
|
+
import{b as v}from"./chunk-6G6UVWJN.js";import*as t from"node:fs/promises";import*as w from"node:fs";import*as i from"node:path";import*as F from"node:os";import n from"node:process";import{Readable as b,Writable as g}from"node:stream";var p=e=>({isFile:e.isFile(),isDirectory:e.isDirectory(),isSymlink:e.isSymbolicLink(),size:e.size,mtime:e.mtime,atime:e.atime,birthtime:e.birthtime}),l=(e,r)=>{throw e instanceof Error&&"code"in e&&e.code==="ENOENT"?new v(r):e},x=()=>({async readFile(e,r){try{let s=await t.readFile(e,{signal:r?.signal});return new Uint8Array(s)}catch(s){return l(s,e)}},async readTextFile(e,r){try{return await t.readFile(e,{encoding:"utf-8",signal:r?.signal})}catch(s){return l(s,e)}},async writeFile(e,r,s){let a=s?.append?"a":"w";await t.writeFile(e,r,{signal:s?.signal,mode:s?.mode,flag:a})},async writeTextFile(e,r,s){let a=s?.append?"a":"w";await t.writeFile(e,r,{encoding:"utf-8",signal:s?.signal,mode:s?.mode,flag:a})},async exists(e){try{return await t.access(e),!0}catch{return!1}},async stat(e){try{let r=await t.stat(e);return p(r)}catch(r){return l(r,e)}},async lstat(e){try{let r=await t.lstat(e);return p(r)}catch(r){return l(r,e)}},async mkdir(e,r){await t.mkdir(e,{recursive:r?.recursive??!1,mode:r?.mode})},async ensureDir(e){await t.mkdir(e,{recursive:!0})},async remove(e,r){try{await t.rm(e,{recursive:r?.recursive??!1,force:!1})}catch(s){l(s,e)}},async*readDir(e){try{let r=await t.readdir(e,{withFileTypes:!0});for(let s of r)yield{name:s.name,isFile:s.isFile(),isDirectory:s.isDirectory(),isSymlink:s.isSymbolicLink()}}catch(r){l(r,e)}},async copyFile(e,r){await t.copyFile(e,r)},async rename(e,r){await t.rename(e,r)},async makeTempDir(e){let r=e?.dir??F.tmpdir(),s=e?.prefix??"",a=e?.suffix??"",c=await t.mkdtemp(i.join(r,s));if(a){let m=c+a;return await t.rename(c,m),m}return c},async realPath(e){try{return await t.realpath(e)}catch(r){return l(r,e)}},watch(e,r){let s=r?.recursive??!0,a=[],c=[],m=[],u=!1,f=o=>{u||(m.length>0?m.shift()({value:o,done:!1}):c.push(o))};for(let o of e)try{let d=w.watch(o,{recursive:s},(y,P)=>{P!==null&&f({kind:y==="rename"?"create":"modify",paths:[i.join(o,P)]})});a.push(d)}catch{}return{close:()=>{u=!0;for(let o of a)o.close();for(let o of m)o({value:void 0,done:!0});m=[]},[Symbol.asyncIterator]:()=>({next:()=>u?Promise.resolve({value:void 0,done:!0}):c.length>0?Promise.resolve({value:c.shift(),done:!1}):new Promise(o=>{m.push(o)})})}},async chmod(e,r){await t.chmod(e,r)},async*walk(e,r){let s=r?.includeDirs??!0,a=r?.includeFiles??!0,c=r?.exts,m=r?.skip,u=async function*(f){let o=await t.readdir(f,{withFileTypes:!0});for(let d of o){let y=i.join(f,d.name);if(m?.some(h=>h.test(y)))continue;let P=d.isSymbolicLink();if(d.isDirectory())s&&(yield{path:y,name:d.name,isFile:!1,isDirectory:!0,isSymlink:P}),yield*u(y);else if(d.isFile()||P){if(!a||c&&!c.some(h=>d.name.endsWith(h.startsWith(".")?h:`.${h}`)))continue;yield{path:y,name:d.name,isFile:d.isFile(),isDirectory:!1,isSymlink:P}}}};yield*u(e)}}),W=()=>({join:i.join,resolve:i.resolve,dirname:i.dirname,basename:i.basename,extname:i.extname,normalize:i.normalize,isAbsolute:i.isAbsolute,relative:i.relative,parse:i.parse,format:i.format,sep:i.sep,delimiter:i.delimiter}),R=()=>({get(e){return n.env[e]},set(e,r){n.env[e]=r},delete(e){delete n.env[e]},has(e){return e in n.env},toObject(){let e={};for(let[r,s]of Object.entries(n.env))s!==void 0&&(e[r]=s);return e}}),T=()=>({exit(e){n.exit(e)},setExitCode(e){n.exitCode=e},cwd(){return n.cwd()},chdir(e){n.chdir(e)},hostname(){return F.hostname()},execPath(){return n.execPath},argv:n.argv,argv0:n.argv0,args:n.argv.slice(2),pid:n.pid,stdin:b.toWeb(n.stdin),stdout:g.toWeb(n.stdout),stderr:g.toWeb(n.stderr),isTerminal(e){switch(e){case"stdin":return n.stdin.isTTY===!0;case"stdout":return n.stdout.isTTY===!0;case"stderr":return n.stderr.isTTY===!0}},setStdinRaw(e){n.stdin.setRawMode(e)},writeToStdout(e){n.stdout.write(e)},consoleSize(){return{columns:n.stdout.columns??80,rows:n.stdout.rows??24}}});export{x as a,W as b,R as c,T as d};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{a as S,b as G,c as R}from"./chunk-
|
|
2
|
+
import{a as S,b as G,c as R}from"./chunk-L5OC7F24.js";import{e as ee}from"./chunk-J2Z7NG2X.js";import{f as p,h as u,k as d}from"./chunk-SHN5MT56.js";import{b as r,d as i,f as w,g as y,h as Z,k as l}from"./chunk-YVN2NZL4.js";import{d as v}from"./chunk-GVTM4EOU.js";import{a as k}from"./chunk-DM6U63HP.js";import{a as f,b as g}from"./chunk-FFWPJP7A.js";import{g as T,i as m}from"./chunk-6DBKPC2O.js";import{g as ie,m as O,n as K,o as I,p as le}from"./chunk-6G6UVWJN.js";var de="# eser CLI completions",B="eser",te=async e=>{try{return await m.fs.readTextFile(e)}catch{return""}},me=async e=>{try{return await m.fs.stat(e),!0}catch{return!1}},se=async e=>{let t=R(e,B);if(t.completionType==="file")return await me(t.completionsFile);let s=await te(t.rcFile),n=G(e,B);return s.includes(n)},ne=async e=>{let t=R(e,B),s=p({renderer:d.ansi(),sink:u.stdout()});try{if(t.completionType==="file"){let n=t.completionsFile,o=m.path.dirname(n);try{await m.fs.mkdir(o,{recursive:!0})}catch{}await m.fs.writeTextFile(n,`# eser CLI completions
|
|
3
3
|
# This file is auto-generated. Run 'eser system completions --shell fish' to regenerate.
|
|
4
4
|
complete -c eser -f
|
|
5
5
|
complete -c eser -n "__fish_use_subcommand" -a "codebase" -d "Codebase management tools"
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{f as e}from"./chunk-
|
|
2
|
+
import{f as e}from"./chunk-6DBKPC2O.js";var n={command:"eser",devCommand:"deno task cli",npmPackage:"eser",jsrPackage:"@eser/cli"},r="npx eser@latest noskills",t=r,i=s=>{t=s},m=()=>t,a=s=>`${t} ${s}`,c=async()=>await e(n,["noskills","nos"])??r;export{i as a,m as b,a as c,c as d};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{a as o}from"./chunk-
|
|
2
|
+
import{a as o}from"./chunk-ATYDQCCJ.js";var n=o({name:"validate-trailing-whitespace",description:"Remove trailing whitespace from lines",canFix:!0,stacks:[],defaults:{},checkFile(a,i){if(i===void 0)return[];let t=[],r=i.split(`
|
|
3
3
|
`);for(let e=0;e<r.length;e++)/[ \t]+$/.test(r[e])&&t.push({path:a.path,line:e+1,message:"trailing whitespace"});return t},fixFile(a,i){let t=i.replace(/[ \t]+$/gm,"");if(t!==i)return{path:a.path,oldContent:i,newContent:t}}}),c=n.run,u=n.validator,d=n.main;export{n as a,c as b,u as c,d};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{a as i}from"./chunk-
|
|
2
|
+
import{a as i}from"./chunk-ATYDQCCJ.js";import{i as t}from"./chunk-6DBKPC2O.js";var s=i({name:"validate-submodules",description:"Detect new git submodules",canFix:!1,stacks:[],defaults:{},async checkAll(n,a){let o=t.path.join(a.root,".gitmodules");if(!await t.fs.exists(o))return[];let e=((await t.fs.readTextFile(o)).match(/\[submodule\s/g)??[]).length;return e>0?[{path:o,message:`found ${e} submodule(s) \u2014 submodules are not allowed`}]:[]}}),p=s.run,f=s.validator,x=s.main;export{s as a,p as b,f as c,x as d};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{a as w}from"./chunk-
|
|
2
|
+
import{a as w}from"./chunk-IIFFSCDJ.js";import{a as v}from"./chunk-LFNUSULJ.js";import{b as y}from"./chunk-O325ZU5M.js";import{f as k}from"./chunk-P2MUEKFT.js";import{b as l,f,g as h,h as C,i as m}from"./chunk-YVN2NZL4.js";import{g as a}from"./chunk-FFWPJP7A.js";var p=y(),D=e=>{let s=new Map,r=new Set(e.map(i=>i.name));for(let i of e){let n=[];for(let d of i.config._loadedFiles){let t=d.content,u=t.dependencies;if(u!==void 0)for(let c of Object.keys(u))r.has(c)&&n.push(c);let o=t.imports;if(o!==void 0)for(let c of Object.values(o))r.has(c)&&n.push(c)}s.set(i.name,[...new Set(n)])}return s},x=e=>{let s=[],r=new Set,i=new Set,n=[],d=t=>{r.add(t),i.add(t),n.push(t);let u=e.get(t)??[];for(let o of u)if(!r.has(o))d(o);else if(i.has(o)){let c=n.indexOf(o),g=n.slice(c);g.push(o),s.push(g)}n.pop(),i.delete(t)};for(let t of e.keys())r.has(t)||d(t);return s},R=async(e={})=>{let{root:s="."}=e,r=await w(s),i=D(r),n=x(i);return{hasCycles:n.length>0,cycles:n,packagesChecked:r.length}},O=e=>k.fromPromise(()=>R(e)),b=e=>a.ok({root:"."}),A=e=>{if(a.isFail(e))return p.writeln(f("\u2717"),l(" "+(e.error instanceof Error?e.error.message:String(e.error)))),a.fail({exitCode:1});let{value:s}=e;if(p.writeln(m("\u2139"),l(` Checked ${s.packagesChecked} packages.`)),s.hasCycles){p.writeln(f("\u2717"),l(` Found ${s.cycles.length} circular dependencies:`));for(let r of s.cycles)p.writeln(C("\u26A0"),l(` ${r.join(" \u2192 ")}`));return a.fail({exitCode:1})}return p.writeln(h("\u2713"),l(" No circular dependencies found.")),a.ok(void 0)},M=v.createTrigger({handler:O,adaptInput:b,adaptOutput:A}),_=async e=>await M({command:"validate-circular-deps",args:[],flags:{}});export{R as a,O as b,M as c,_ as d};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{b as w}from"./chunk-
|
|
2
|
+
import{b as w}from"./chunk-4X4NHXFE.js";import{a as p}from"./chunk-2XNFZXHY.js";import{b as c}from"./chunk-GVTM4EOU.js";import{e as y}from"./chunk-5WJ6AUNY.js";var C=()=>{let e=new Map;return{register:o=>{e.set(o.name,o)},registerAll:o=>{for(let r of o)e.set(r.name,r)},get:o=>e.get(o),getAll:()=>[...e.values()],has:o=>e.has(o),names:()=>[...e.keys()]}};var k=y(p(),1);var h=e=>{let o=e.workflows;if(!Array.isArray(o))throw new Error("Invalid config: 'workflows' must be an array");for(let r=0;r<o.length;r++){let n=o[r],t=n?.id!==void 0&&n.id!==""?`workflow '${n.id}'`:`workflow at index ${r}`;if(typeof n?.id!="string"||n.id==="")throw new Error(`Invalid config: ${t} must have a non-empty 'id' string`);if(!Array.isArray(n.on)||n.on.length===0)throw new Error(`Invalid config: ${t} must have a non-empty 'on' array`);if(!Array.isArray(n.steps)||n.steps.length===0)throw new Error(`Invalid config: ${t} must have a non-empty 'steps' array`);for(let s=0;s<n.steps.length;s++){let i=n.steps[s];if(typeof i=="string")continue;if(typeof i!="object"||i===null||Array.isArray(i))throw new Error(`Invalid config: ${t}, step ${s} must be a string or an object with exactly one key`);let l=Object.keys(i);if(l.length!==1)throw new Error(`Invalid config: ${t}, step ${s} must be an object with exactly one key (got ${l.length})`)}}};var b=async e=>{let o=await w(e);if(o===null)return null;let r={stack:o.stack,workflows:o.workflows??[],scripts:o.scripts};return h(r),r};var I={name:"shell",description:"Execute shell commands",run:async e=>{let o=e.command,r=e.fixCommand,n=e.name??o??"shell",t=e.fix??!1,s=e.root??".",i=e.workingDirectory??s;if(o===void 0||o.length===0)throw new Error(`Shell tool requires a 'command' option. Usage: { shell: { command: "deno fmt --check" } }`);let l=t&&r!==void 0?r:o,a=await new c("sh",["-c",l]).cwd(i).noThrow().spawn(),f=a.code;if(f===0)return{name:n,passed:!0,issues:[],mutations:[],stats:{exitCode:0}};let d=new TextDecoder,g=d.decode(a.stderr).trim(),m=[d.decode(a.stdout).trim(),g].filter(u=>u.length>0).join(`
|
|
3
3
|
`);return{name:n,passed:!1,issues:[{message:m||`Command exited with code ${f}`}],mutations:[],stats:{exitCode:f}}}};export{C as a,b,I as c};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{a as q}from"./chunk-NY4W44PI.js";import{a as S,c as N,d as T,e as L}from"./chunk-2HSGE3TL.js";import{c as U}from"./chunk-
|
|
2
|
+
import{a as q}from"./chunk-NY4W44PI.js";import{a as S,c as N,d as T,e as L}from"./chunk-2HSGE3TL.js";import{c as U}from"./chunk-UEMWZOIU.js";var _=[{id:"status_quo",text:"What does the user do today without this feature?",concerns:["product:status_quo","eng:replace_scope","qa:regression_risk"]},{id:"ambition",text:"Describe the 1-star and 10-star versions.",concerns:["product:scope_direction","eng:complexity_tier","qa:test_depth"]},{id:"reversibility",text:"Does this change involve an irreversible decision?",concerns:["product:one_way_door","eng:migration_strategy","qa:verification_stringency"]},{id:"user_impact",text:"Does this change affect existing users' behavior?",concerns:["product:breaking_change","eng:backward_compat","qa:regression_tests"]},{id:"verification",text:"How do you verify this works correctly?",concerns:["product:success_metric","eng:test_strategy","qa:acceptance_criteria"]},{id:"scope_boundary",text:"What should this feature NOT do?",concerns:["product:focus","eng:out_of_scope","qa:negative_tests"]}],B=[{questionId:"verification",text:"What tests should be written? (unit, integration, e2e \u2014 be specific about what behavior to test)"},{questionId:"verification",text:"What documentation needs updating? (README, API docs, CHANGELOG, inline comments)"}],C=e=>_.map(t=>{let s=B.filter(r=>r.questionId===t.id),n=N(e,t.id);return{...t,extras:[...s,...n]}});var F=e=>{let t=new Set(e.map(s=>s.questionId));return _.every(s=>t.has(s.id))};var x=e=>U(e),o=(e,t)=>x(t===null?e:`spec ${t} ${e}`),j="NEVER run git write commands (commit, add, push, checkout, stash, reset, merge, rebase, cherry-pick). Git is read-only for agents. The user controls git. You may read: git log, git diff, git status, git show, git blame.",Y={hasAskUserTool:!0,optionPresentation:"tool",hasSubAgentDelegation:!0,subAgentMethod:"task"},G=(e,t,s,n,r=Y)=>{let m=e.execution.iteration>=t,l="You are a senior engineer and a scrum master who takes pride in honest reporting. Your reputation depends on accuracy, not speed. You are responsible for others' toil, and you are a perfect example of a servant leader. When reporting progress: if something is NOT implemented, say so \u2014 don't hide it. If partially done, say 'partially done: [what works] / [what doesn't]'. If untested, say 'implemented but untested'. NEVER say 'done' for something you haven't verified yourself. Underpromise \u2014 4 of 6 done means '4 of 6 done, 2 remaining', not 'almost done'.",u="Never skip steps or make decisions without asking the user. If you think something can be skipped or inferred, ask first. Explicit > Clever.",y=r.hasAskUserTool?"At every decision point (discovery questions, classification, spec approval, expansion proposals, architectural decisions, rule promotion), you MUST use AskUserQuestion to get the user's input. You MUST NOT make decisions, infer preferences, or assume the user's intent. If you're unsure whether something is a decision point, it is \u2014 ask.":"At every decision point (discovery questions, classification, spec approval, expansion proposals, architectural decisions, rule promotion), you MUST ask the user. Present options as a numbered list and ask the user to pick a number. You MUST NOT make decisions, infer preferences, or assume the user's intent. If you're unsure whether something is a decision point, it is \u2014 ask.",g="At every decision point where you present options to the user, share your recommendation BEFORE asking. Say what you think and why, then ask if the user agrees. Format: 'I'd recommend X because [reason]. Agree, or would you prefer Y?' The user always has the final word, but you save them cognitive load by proposing first.",w="noskills is a live state machine the user watches in real-time. Call noskills ONCE per interaction. Ask ONE question, wait for the user's answer, submit it. Never batch-submit, never backfill, never answer questions yourself.",c=s?[l,u,y,g,w]:[j,l,u,y,g,w];c.push("When noskills output contains a `roadmap` field, display it to the user BEFORE any other content. When output contains a `gate` field, display the gate message prominently \u2014 do NOT bury it in prose.");let v=n?.outOfScope??[],a=e.spec;switch(e.phase){case"FREE":return{rules:[],tone:"Quiet. No enforcement."};case"IDLE":{let i=r.optionPresentation==="tool"?["When interactiveOptions are present, pass them DIRECTLY as the `options` array in AskUserQuestion \u2014 they are already in the correct {label, description} format. You MUST also provide a `header` field (max 12 chars, e.g. 'Action') and a `question` field. When the user picks an option, look up its label in the `commandMap` object to find the command to execute.","For availableConcerns: use AskUserQuestion with multiSelect:true. AskUserQuestion supports max 4 options per question and max 4 questions per call. If there are more than 4 concerns, split them across two questions within the same AskUserQuestion call (e.g., first 3 in question 1, remaining in question 2). NEVER silently drop concerns \u2014 present ALL available concerns to the user, even if it requires multiple questions."]:[`When interactiveOptions are present, present them as a numbered list. For each option show the number, label, and description. Ask the user to pick a number. When the user picks an option, look up its label in the \`commandMap\` object to find the command to execute. Example format:
|
|
3
3
|
|
|
4
4
|
1. Start a new spec \u2014 Begin discovery questions for a new feature
|
|
5
5
|
2. Add concerns \u2014 Shape how discovery and specs work
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{m as w,o as R}from"./chunk-
|
|
2
|
+
import{m as w,o as R}from"./chunk-NMSD4ZXJ.js";import{i as g}from"./chunk-6DBKPC2O.js";var p=class extends Error{constructor(r){super(`Required variable '${r}' has no value and no default`),this.name="MissingVariableError"}},m=(e,r)=>{let t={};for(let n of e){let a=r[n.name];if(a!==void 0)t[n.name]=a;else if(n.default!==void 0)t[n.name]=n.default;else throw new p(n.name)}return t},v=(e,r)=>e.replace(/\{\{\s*\.(\w+)\s*\}\}/g,(t,n)=>n in r?r[n]:t);var y=class extends Error{constructor(r){super(`Circular dependency detected: ${r.join(" \u2192 ")}`),this.name="CyclicDependencyError"}},f=class extends Error{constructor(r,t){super(`Recipe '${r}' requires '${t}', which is not in the registry`),this.name="MissingDependencyError"}},b=(e,r)=>{let t=new Map;for(let s of r)t.set(s.name,s);if(t.get(e)===void 0)throw new f("<root>",e);let a=[],i=new Set,o=new Set,l=(s,d)=>{if(i.has(s))return;if(o.has(s))throw new y([...d,s]);let c=t.get(s);if(c===void 0)throw new f(d[d.length-1]??"<root>",s);if(o.add(s),c.requires!==void 0)for(let u of c.requires)l(u,[...d,s]);o.delete(s),i.add(s),a.push(c)};return l(e,[]),a};var $=(e,r)=>{let t=e.endsWith("/")?e:`${e}/`,n=new URL(r,`file://${t}`).pathname;return n.startsWith(t)||n===e},x=async e=>{let r=e.split("/");r.pop();let t=r.join("/");t!==""&&t!=="."&&await g.fs.mkdir(t,{recursive:!0})},h=async e=>{try{return await g.fs.stat(e),!0}catch{return!1}},k=(e,r)=>r===void 0||Object.keys(r).length===0?e:v(e,r),F=async(e,r,t,n)=>{let a=`${r.cwd}/${e.target}`;if(n.includes(e.target))return;if(r.skipExisting===!0&&await h(a)){r.verbose===!0&&console.log(` [skip] ${e.target} (already exists)`),n.push(e.target);return}if(r.dryRun===!0){console.log(` [dry-run] would write ${e.target}`),t.push(e.target);return}r.verbose===!0&&console.log(` [write] ${e.target}`);let i=await w(r.registryUrl,e.source),o=k(i,r.variables);await x(a),await g.fs.writeTextFile(a,o),t.push(e.target)},E=async(e,r,t,n)=>{let a=await R(r.registryUrl,e.source);for(let i of a){let o=`${e.target}/${i.path}`;if(!$(r.cwd,o))throw new Error(`Folder recipe contains path traversal in '${o}'. Aborting.`)}for(let i of a){let o=`${e.target}/${i.path}`,l=`${r.cwd}/${o}`;if(r.skipExisting===!0&&await h(l)){n.push(o);continue}if(r.dryRun===!0){console.log(` [dry-run] would write ${o}`),t.push(o);continue}r.verbose===!0&&console.log(` [write] ${o}`);let s=k(i.content,r.variables);await x(l),await g.fs.writeTextFile(l,s),t.push(o)}},S=async(e,r,t,n)=>{let a=[];for(let i of e){if(t===!0){console.log(` [dry-run] would run: ${i}`),a.push(i);continue}n===!0&&console.log(` [post-install] ${i}`);let o=i.split(/\s+/),l=await g.exec.spawn(o[0],o.slice(1),{cwd:r,stdout:"inherit",stderr:"inherit"});if(!l.success)throw new Error(`Post-install command failed: '${i}' (exit code ${l.code})`);a.push(i)}return a},q=async(e,r)=>{let t=[],n=[],a=e.files.length,i=r.variables;e.variables!==void 0&&e.variables.length>0&&(i=m(e.variables,r.variables??{}));let o={...r,variables:i};for(let s of e.files)if((s.kind??"file")==="file"&&!$(r.cwd,s.target))throw new Error(`Recipe '${e.name}' contains path traversal in target '${s.target}'. Aborting.`);if(r.force!==!0&&r.skipExisting!==!0)for(let s of e.files){if((s.kind??"file")!=="file")continue;let c=`${r.cwd}/${s.target}`;await h(c)&&(r.dryRun===!0?console.log(` [conflict] ${s.target} (already exists)`):(console.warn(` Warning: ${s.target} already exists. Use --force to overwrite or --skip-existing to skip.`),n.push(s.target)))}for(let s of e.files){let d=s.kind??"file";try{d==="folder"?await E(s,o,t,n):await F(s,o,t,n)}catch(c){let u=c instanceof Error?c.message:String(c);throw new Error(`Failed applying '${s.target}'. ${t.length} files written so far. Retry with \`eser kit add ${e.name} --force\`. Cause: ${u}`)}}let l=[];return e.postInstall!==void 0&&e.postInstall.length>0&&(l=await S(e.postInstall,r.cwd,r.dryRun,r.verbose)),{written:t,skipped:n,total:a,postInstallRan:l}},V=async(e,r,t)=>{let n=b(e,r),a=[];for(let i of n){t.verbose===!0&&console.log(`
|
|
3
3
|
Applying recipe: ${i.name}`);let o=await q(i,t);a.push({name:i.name,result:o})}return{recipes:a}};export{$ as a,h as b,k as c,S as d,q as e,V as f};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{b as f}from"./chunk-
|
|
2
|
+
import{b as f}from"./chunk-IZUADMIU.js";import{c as d}from"./chunk-TMMAF763.js";import{i as u}from"./chunk-6DBKPC2O.js";var m=r=>{let n=r.split(/\n/).flatMap(t=>t.trim().length>0?[t.trim()]:[]);return n.length>1?n:r.split(/\.(?=\s+[A-Z])|;\s+/).map(t=>t.trim()).filter(t=>t.length>5)},v=(r,n=[])=>{let t=[],o=r.find(e=>e.questionId==="ambition");if(o!==void 0){let e=o.answer,c=e.match(/10[- ]?star[:\s]+(.+?)(?:\n|$)/is),a=e.match(/5[- ]?star[:\s]+(.+?)(?:\n|$)/is),s=(c!==null?c[1].trim():a!==null?a[1].trim():e.replace(/1[- ]?star[:\s]+[^.]*\.\s*/i,"").trim()).replace(/^(the|a|an|with|plus|also)\s+/i,"").replace(/^(the\s+)?(target|goal|objective)[:\s]+/i,"").trim();s.length>0&&(s=s.charAt(0).toUpperCase()+s.slice(1)),s=s.replace(/[.\u2026]+$/,"").trim(),s.length>140&&(s=s.slice(0,137)+"..."),s.length>3&&t.push(s)}let i=r.find(e=>e.questionId==="verification");if(i!==void 0){let e=i.answer.split(/\n/).map(c=>c.replace(/^\s*[-\u2022*]\s*/,"").trim()).filter(c=>c.length>0);for(let c of e)t.push(c)}for(let e of n){let c=e.choice.toLowerCase();if(c.includes("accepted")||c.includes("add to scope")){let a=e.question.replace(/^should\s+(we|i)\s+/i,"").replace(/\?+$/,"").trim(),l=a.charAt(0).toUpperCase()+a.slice(1);t.push(l)}}return t.length===0&&t.push("_Tasks need to be defined before execution. Add tasks manually or run discovery with more detail._"),t.push("Write or update tests for all new and changed behavior"),t.push("Update documentation for all public-facing changes (README, API docs, CHANGELOG)"),t},w=(r,n)=>{let t={};if(n===null){for(let o of r.specSections)t[o]=!1;return t}for(let o of r.specSections){let i=o.toLowerCase();i.includes("design")||i.includes("mobile")||i.includes("layout")||i.includes("interaction")?t[o]=n.involvesWebUI:i.includes("contributor")||i.includes("public api")||i.includes("api surface")?t[o]=n.involvesPublicAPI:i.includes("migration")||i.includes("deprecation")||i.includes("backward")||i.includes("compatibility")?t[o]=n.involvesMigration:i.includes("audit")||i.includes("access control")||i.includes("data handling")?t[o]=n.involvesDataHandling:t[o]=!0}return t},g=(r,n,t,o,i)=>{let e=[];e.push(`# Spec: ${r}`),e.push(""),e.push("## Status: draft"),e.push(""),t.length>0&&(e.push(`## Concerns: ${t.map(s=>s.id).join(", ")}`),e.push("")),e.push("## Discovery Answers"),e.push("");for(let s of n)e.push(`### ${s.questionId}`),e.push(""),e.push(s.answer),e.push("");for(let s of t)if(s.specSections.length>0){let p=w(s,i??null);for(let h of s.specSections)p[h]!==!1&&(e.push(`## ${h} (${s.id})`),e.push(""),e.push("_To be addressed during execution._"),e.push(""))}if(o.length>0){e.push("## Decisions"),e.push(""),e.push("| # | Decision | Choice | Promoted |"),e.push("|---|----------|--------|----------|");for(let s=0;s<o.length;s++){let p=o[s];e.push(`| ${s+1} | ${p.question} | ${p.choice} | ${p.promoted?"yes":"no"} |`)}e.push("")}let c=n.find(s=>s.questionId==="scope_boundary");if(c!==void 0){e.push("## Out of Scope"),e.push("");let s=m(c.answer);for(let p of s)e.push(`- ${p}`);e.push("")}let a=v(n,o);e.push("## Tasks"),e.push("");for(let s=0;s<a.length;s++)e.push(`- [ ] task-${s+1}: ${a[s]}`);e.push("");let l=n.find(s=>s.questionId==="verification");if(e.push("## Verification"),e.push(""),l!==void 0){let s=m(l.answer);for(let p of s)e.push(`- ${p}`)}else e.push("_To be defined._");return e.push(""),e.join(`
|
|
3
3
|
`)};var D=async(r,n,t)=>{if(n.spec===null)throw new Error("No active spec");let o=`${r}/${d.specDir(n.spec)}`,i=`${r}/${d.specFile(n.spec)}`;await u.fs.mkdir(o,{recursive:!0});let e=g(n.spec,n.discovery.answers,t,n.decisions,n.classification);await u.fs.writeTextFile(i,e);let c=f(n.spec,e),a=`${o}/progress.json`,l={spec:n.spec,status:"draft",tasks:c.tasks.map(s=>({id:s.id,title:s.title,status:"pending"})),decisions:n.decisions.map(s=>({question:s.question,choice:s.choice,promoted:s.promoted})),debt:[],updatedAt:new Date().toISOString()};return await u.fs.writeTextFile(a,JSON.stringify(l,null,2)+`
|
|
4
4
|
`),i};export{D as a};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{a as n}from"./chunk-3XJLLDR5.js";import{a as r}from"./chunk-
|
|
2
|
+
import{a as n}from"./chunk-3XJLLDR5.js";import{a as r}from"./chunk-ATYDQCCJ.js";var o=r({name:"validate-json",description:"Validate JSON syntax",canFix:!1,stacks:[],defaults:{},extensions:["json","jsonc"],checkFile(e,a,t){if(a===void 0)return[];if((t.exclude??[]).some(s=>e.path.includes(s)))return[];try{return e.name.endsWith(".jsonc")?n(a):JSON.parse(a),[]}catch(s){let i=s instanceof SyntaxError?s.message:"invalid JSON";return[{path:e.path,message:i}]}}}),p=o.run,f=o.validator,x=o.main;export{o as a,p as b,f as c,x as d};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
+
import{f as ge,h as re,k as se}from"./chunk-SHN5MT56.js";import{b as u,c as Le,d as p,e as $,f as S,g,h as L,i as Be,k as R,l as _,n as ye,o as U}from"./chunk-YVN2NZL4.js";import{i as x}from"./chunk-6DBKPC2O.js";import{d as N}from"./chunk-5WJ6AUNY.js";var m=Symbol("tui.cancel"),We=e=>e===m,Me={ctrlC:"exit",escape:"cancel"},je=()=>{try{return x.process.stdin}catch{return new ReadableStream}},ze=e=>{let t=e?.interaction??(e?.target==="non-interactive"?"non-interactive":"interactive"),r=e?.audience??"human",s=t==="non-interactive"?"non-interactive":"interactive",i=t==="interactive";return{output:e?.output??ge({renderer:i?se.ansi():se.plain(),sink:i?re.stdout():re.stderr()}),input:e?.input??je(),target:s,interaction:t,audience:r,signals:{...Me,...e?.signals},stderr:e?.stderr??ge({renderer:se.plain(),sink:re.stderr()})}};var Ie={};N(Ie,{disableMouse:()=>Ye,enableMouse:()=>Xe,isSGRMouseSequence:()=>xe,parseMouseEvent:()=>be});var Xe=()=>"\x1B[?1000h\x1B[?1002h\x1B[?1006h",Ye=()=>"\x1B[?1006l\x1B[?1002l\x1B[?1000l",Je=/^\x1b\[<(\d+);(\d+);(\d+)([Mm])$/,be=e=>{let t=e.match(Je);if(t===null)return null;let r=parseInt(t[1],10),s=parseInt(t[2],10)-1,i=parseInt(t[3],10)-1,n=t[4]==="m",o=r&3,a=(r&4)!==0,c=(r&16)!==0,d=(r&32)!==0;return(r&64)!==0?{type:"wheel",button:0,x:s,y:i,shift:a,ctrl:c,direction:r&1?"down":"up"}:d?{type:"mousemove",button:o,x:s,y:i,shift:a,ctrl:c}:{type:n?"mouseup":"mousedown",button:o,x:s,y:i,shift:a,ctrl:c}},xe=e=>e.length>=4&&e[0]===27&&e[1]===91&&e[2]===60;var O=async e=>{let t=!1;if(x.capabilities.stdin&&x.process.isTerminal("stdin"))try{x.process.setStdinRaw(!0),t=!0}catch{}try{return await e()}finally{if(t)try{x.process.setStdinRaw(!1)}catch{}}},E=e=>{e.write(u("\x1B[?25l"))},k=e=>{e.write(u("\x1B[?25h"))},h=(e,t)=>{t>0&&e.write(u(`\x1B[${t}A\x1B[J`))},ne=e=>{e.write(u("\r\x1B[2K"))},Ne=e=>{let t=new Uint8Array(e);if(e.length===1&&e[0]===3)return{name:"c",ctrl:!0,meta:!1,shift:!1,raw:t};if(e.length===1&&e[0]===27)return{name:"escape",ctrl:!1,meta:!1,shift:!1,raw:t};if(e.length===1&&(e[0]===13||e[0]===10))return{name:"return",ctrl:!1,meta:!1,shift:!1,raw:t};if(e.length===1&&e[0]===9)return{name:"tab",ctrl:!1,meta:!1,shift:!1,raw:t};if(e.length===1&&e[0]===127)return{name:"backspace",ctrl:!1,meta:!1,shift:!1,raw:t};if(e.length>=3&&e[0]===27&&e[1]===91)switch(e[2]){case 65:return{name:"up",ctrl:!1,meta:!1,shift:!1,raw:t};case 66:return{name:"down",ctrl:!1,meta:!1,shift:!1,raw:t};case 67:return{name:"right",ctrl:!1,meta:!1,shift:!1,raw:t};case 68:return{name:"left",ctrl:!1,meta:!1,shift:!1,raw:t};case 72:return{name:"home",ctrl:!1,meta:!1,shift:!1,raw:t};case 70:return{name:"end",ctrl:!1,meta:!1,shift:!1,raw:t}}if(e.length===1&&e[0]>=1&&e[0]<=26)return{name:String.fromCharCode(e[0]+96),ctrl:!0,meta:!1,shift:!1,raw:t};if(e.length===1&&e[0]===32)return{name:"space",char:" ",ctrl:!1,meta:!1,shift:!1,raw:t};if(e.length===1&&e[0]>=33&&e[0]<=126){let r=String.fromCharCode(e[0]);return{name:r,char:r,ctrl:!1,meta:!1,shift:!1,raw:t}}if(e.length>0&&e[0]>=192){let r=new TextDecoder().decode(e);return{name:r,char:r,ctrl:!1,meta:!1,shift:!1,raw:t}}return{name:"unknown",ctrl:!1,meta:!1,shift:!1,raw:t}};async function*P(e,t){let r=e.getReader();try{for(;!t?.aborted;){let{done:s,value:i}=await r.read();if(s||i===void 0)break;yield Ne(i)}}finally{r.releaseLock()}}async function*Ze(e,t){let r=e.getReader(),s=new TextDecoder;try{for(;!t?.aborted;){let{done:i,value:n}=await r.read();if(i||n===void 0)break;if(xe(n)){let o=s.decode(n),a=be(o);if(a!==null){yield{kind:"mouse",event:a};continue}}yield{kind:"key",event:Ne(n)}}}finally{r.releaseLock()}}var w=(e,t)=>{if(e==="exit"){k(t.output);try{x.process.setStdinRaw(!1)}catch{}x.process.exit(130)}return e==="cancel"?"cancel":"continue"};var y="\u2502",_e="\u250C",C="\u2514";var F="\u25CF",H="\u25CB",De="\u25FC",Ge="\u25FB",B="\u25C6",v="\u25C7",A="\u25A0",$e="\u25CF";var D="\u25B2";var Ue="\u25C7";var ie=(e,t,r,s)=>{if(s==="done"){let o=r?"Yes":"No";return e.output.writeln(g(v),u(` ${t}`),p(` \xB7 ${o}`)),1}if(s==="cancel")return e.output.writeln(S(A),u(` ${t}`)),1;let i=r?$(g(F),u(" Yes")):$(p(H),p(" Yes")),n=r?$(p(H),p(" No")):$(g(F),u(" No"));return e.output.writeln(R(B),u(` ${t}`)),e.output.writeln(p(y),u(" "),i,p(" / "),n),e.output.writeln(p(C)),3},Qe=async(e,t)=>{let r=t.initialValue??!0,s=0;E(e.output);try{return await O(async()=>{s=ie(e,t.message,r,"active"),await e.output.flush();let i=()=>{h(e.output,s),ie(e,t.message,r,"cancel")};for await(let n of P(e.input)){if(n.name==="c"&&n.ctrl){if(w(e.signals.ctrlC,e)==="cancel")return i(),await e.output.flush(),m;continue}if(n.name==="escape"){if(w(e.signals.escape,e)==="cancel")return i(),await e.output.flush(),m;continue}if(n.name==="return")return h(e.output,s),ie(e,t.message,r,"done"),await e.output.flush(),r;let o=!1;(n.name==="left"||n.name==="right")&&(r=!r,o=!0),(n.name==="y"||n.name==="Y")&&(r=!0,o=!0),(n.name==="n"||n.name==="N")&&(r=!1,o=!0),o&&(h(e.output,s),s=ie(e,t.message,r,"active"),await e.output.flush())}return m})}finally{k(e.output),await e.output.flush()}};var q=(e,t,r,s,i,n)=>{if(n==="done")return e.output.writeln(g(v),u(` ${t}`),p(` \xB7 ${r}`)),1;if(n==="cancel")return e.output.writeln(S(A),u(` ${t}`)),1;let o=r.length>0?u(r):s!==void 0?p(s):u(""),a=i!==void 0?L(D):R(B);e.output.writeln(a,u(` ${t}`)),e.output.writeln(p(y),u(" "),o);let c=2;return i!==void 0?(e.output.writeln(p(C),u(" "),L(i)),c=3):(e.output.writeln(p(C)),c=3),c},et=async(e,t)=>{let r=t.initialValue??"",s=r.length,i,n=0;E(e.output);try{return await O(async()=>{n=q(e,t.message,r,t.placeholder,i,"active"),await e.output.flush();let o=()=>{h(e.output,n),q(e,t.message,r,t.placeholder,void 0,"cancel")};for await(let a of P(e.input)){if(a.name==="c"&&a.ctrl){if(w(e.signals.ctrlC,e)==="cancel")return o(),await e.output.flush(),m;continue}if(a.name==="escape"){if(w(e.signals.escape,e)==="cancel")return o(),await e.output.flush(),m;continue}if(a.name==="return"){if(t.validate!==void 0){let c=t.validate(r);if(c!==void 0){i=c,h(e.output,n),n=q(e,t.message,r,t.placeholder,i,"active"),await e.output.flush();continue}}return h(e.output,n),q(e,t.message,r,t.placeholder,void 0,"done"),await e.output.flush(),r}if(i=void 0,a.name==="backspace")s>0&&(r=r.slice(0,s-1)+r.slice(s),s--);else if(a.name==="left")s>0&&s--;else if(a.name==="right")s<r.length&&s++;else if(a.name==="home")s=0;else if(a.name==="end")s=r.length;else if(a.char!==void 0)r=r.slice(0,s)+a.char+r.slice(s),s++;else continue;h(e.output,n),n=q(e,t.message,r,t.placeholder,i,"active"),await e.output.flush()}return m})}finally{k(e.output),await e.output.flush()}};var oe=(e,t,r,s,i)=>{if(i==="done"){let n=r[s];return e.output.writeln(g(v),u(` ${t}`),p(` \xB7 ${n?.label??""}`)),1}if(i==="cancel")return e.output.writeln(S(A),u(` ${t}`)),1;e.output.writeln(R(B),u(` ${t}`));for(let n=0;n<r.length;n++){let o=r[n],a=n===s,c=o.disabled===!0,d=a?g(F):p(H),l=c?p(` ${o.label}`):a?u(` ${o.label}`):p(` ${o.label}`),f=o.hint!==void 0?p(` (${o.hint})`):u("");e.output.writeln(p(y),u(" "),d,l,f)}return e.output.writeln(p(C)),r.length+2},we=(e,t,r)=>{let s=e.length,i=t;for(let n=0;n<s;n++)if(i=(i+r+s)%s,e[i]?.disabled!==!0)return i;return t},tt=async(e,t)=>{let r=0;if(t.initialValue!==void 0){let i=t.options.findIndex(n=>n.value===t.initialValue);i>=0&&(r=i)}t.options[r]?.disabled===!0&&(r=we(t.options,r,1));let s=0;E(e.output);try{return await O(async()=>{s=oe(e,t.message,t.options,r,"active"),await e.output.flush();let i=()=>{h(e.output,s),oe(e,t.message,t.options,r,"cancel")};for await(let n of P(e.input)){if(n.name==="c"&&n.ctrl){if(w(e.signals.ctrlC,e)==="cancel")return i(),await e.output.flush(),m;continue}if(n.name==="escape"){if(w(e.signals.escape,e)==="cancel")return i(),await e.output.flush(),m;continue}if(n.name==="return")return h(e.output,s),oe(e,t.message,t.options,r,"done"),await e.output.flush(),t.options[r].value;let o=!1;(n.name==="up"||n.name==="k")&&(r=we(t.options,r,-1),o=!0),(n.name==="down"||n.name==="j")&&(r=we(t.options,r,1),o=!0),o&&(h(e.output,s),s=oe(e,t.message,t.options,r,"active"),await e.output.flush())}return m})}finally{k(e.output),await e.output.flush()}};var W=(e,t,r,s,i,n,o)=>{if(o==="done"){let d=[...i].sort((l,f)=>l-f).map(l=>r[l]?.label??"").join(", ");return e.output.writeln(g(v),u(` ${t}`),p(` \xB7 ${d}`)),1}if(o==="cancel")return e.output.writeln(S(A),u(` ${t}`)),1;let a=n!==void 0?L(D):R(B);e.output.writeln(a,u(` ${t}`));for(let d=0;d<r.length;d++){let l=r[d],f=d===s,b=i.has(d),G=l.disabled===!0,de=b?g(De):p(Ge),me=G?p(` ${l.label}`):f?u(` ${l.label}`):p(` ${l.label}`),he=l.hint!==void 0?p(` (${l.hint})`):u("");e.output.writeln(p(y),u(" "),de,me,he)}let c=r.length+2;return n!==void 0?e.output.writeln(p(C),u(" "),L(n)):e.output.writeln(p(C)),c},Ce=(e,t,r)=>{let s=e.length,i=t;for(let n=0;n<s;n++)if(i=(i+r+s)%s,e[i]?.disabled!==!0)return i;return t},rt=async(e,t)=>{let r=0,s=new Set;if(t.initialValues!==void 0)for(let o of t.initialValues){let a=t.options.findIndex(c=>c.value===o);a>=0&&s.add(a)}t.options[r]?.disabled===!0&&(r=Ce(t.options,r,1));let i=0,n;E(e.output);try{return await O(async()=>{i=W(e,t.message,t.options,r,s,n,"active"),await e.output.flush();let o=()=>{h(e.output,i),W(e,t.message,t.options,r,s,void 0,"cancel")};for await(let a of P(e.input)){if(a.name==="c"&&a.ctrl){if(w(e.signals.ctrlC,e)==="cancel")return o(),await e.output.flush(),m;continue}if(a.name==="escape"){if(w(e.signals.escape,e)==="cancel")return o(),await e.output.flush(),m;continue}if(a.name==="return"){if(t.required!==!1&&s.size===0){n="Please select at least one option.",h(e.output,i),i=W(e,t.message,t.options,r,s,n,"active"),await e.output.flush();continue}return h(e.output,i),W(e,t.message,t.options,r,s,void 0,"done"),await e.output.flush(),[...s].sort((d,l)=>d-l).map(d=>t.options[d].value)}n=void 0;let c=!1;if((a.name==="up"||a.name==="k")&&(r=Ce(t.options,r,-1),c=!0),(a.name==="down"||a.name==="j")&&(r=Ce(t.options,r,1),c=!0),a.name==="space"&&t.options[r]?.disabled!==!0&&(s.has(r)?s.delete(r):s.add(r),c=!0),a.name==="a"){let d=t.options.every((l,f)=>l.disabled===!0||s.has(f));for(let l=0;l<t.options.length;l++)t.options[l]?.disabled!==!0&&(d?s.delete(l):s.add(l));c=!0}c&&(h(e.output,i),i=W(e,t.message,t.options,r,s,n,"active"),await e.output.flush())}return m})}finally{k(e.output),await e.output.flush()}};var st=(e,t)=>{e.output.writeln(_(_e),u(" "),Le(t)),e.output.writeln(_(y))},nt=(e,t)=>{e.output.writeln(_(y)),e.output.writeln(_(C),u(" "),u(t))},it=e=>{e.output.writeln(u(""))},ot=(e,t)=>{e.output.writeln(u(" "),p(t))},at=e=>{e.output.writeln(_(y))},lt={info:(e,t)=>{e.output.writeln(U("info",t))},success:(e,t)=>{e.output.writeln(U("success",t))},warn:(e,t)=>{e.output.writeln(U("warning",t))},error:(e,t)=>{e.output.writeln(U("error",t))},step:(e,t)=>{e.output.writeln(p(Ue),u(" "),p(t))},message:(e,t,r)=>{e.output.writeln(p(r??y),u(" "),u(t))}};var ut=["\u280B","\u2819","\u2839","\u2838","\u283C","\u2834","\u2826","\u2827","\u2807","\u280F"],ct=80,pt=(e,t,r)=>{let s=r?.frames??ut,i=r?.interval??ct,n=t,o=0,a,c=()=>{e.output.write(u(`\r${" ".repeat(n.length+4)}\r`))},d=()=>{a!==void 0&&(clearInterval(a),a=void 0,c())};return{start:l=>{l!==void 0&&(n=l),a=setInterval(()=>{let f=s[o%s.length];e.output.write(u("\r"),R(f??""),u(` ${n}`)),o++},i)},stop:l=>{d(),l!==void 0&&(n=l)},update:l=>{n=l},succeed:l=>{d(),e.output.writeln(g(v),u(` ${l??n}`))},fail:l=>{d(),e.output.writeln(S(A),u(` ${l??n}`))},warn:l=>{d(),e.output.writeln(L(D),u(` ${l??n}`))},info:l=>{d(),e.output.writeln(Be($e),u(` ${l??n}`))}}};var dt=(e,t)=>{let r=0,s=t.label??"",i=!1,n=()=>{let o=t.total>0?Math.round(r/t.total*100):0;ne(e.output),e.output.write(p(y),u(" "),ye(o,{width:t.width??20,label:s}))};return{start:o=>{o!==void 0&&(s=o),i=!0,e.output.writeln(p(v),u(` ${s}`)),n()},advance:(o,a)=>{i&&(r=Math.min(r+o,t.total),a!==void 0&&(s=a),n())},stop:o=>{i&&(i=!1,r=t.total,o!==void 0&&(s=o),ne(e.output),e.output.writeln(p(y),u(" "),ye(100,{width:t.width??20,label:s})))}}};var Ve={};N(Ve,{clearScreenSeq:()=>gt,enterAlternateScreen:()=>mt,exitAlternateScreen:()=>ht,getTerminalSize:()=>bt,hideCursorSeq:()=>ft,showCursorSeq:()=>yt});var mt=()=>"\x1B[?1049h",ht=()=>"\x1B[?1049l",ft=()=>"\x1B[?25l",yt=()=>"\x1B[?25h",gt=()=>"\x1B[2J\x1B[H",bt=()=>{try{let{columns:e,rows:t}=x.process.consoleSize();return{cols:e,rows:t}}catch{return{cols:80,rows:24}}};var ce={};N(ce,{bgBlue:()=>vt,bgGreen:()=>Ct,bold:()=>xt,cyan:()=>Se,dim:()=>ae,green:()=>le,inverse:()=>Re,moveTo:()=>T,red:()=>Te,reset:()=>ue,stripAnsi:()=>ke,truncate:()=>z,visibleLength:()=>j,white:()=>wt,yellow:()=>ve});var T=(e,t)=>`\x1B[${e};${t}H`,xt=e=>`\x1B[1m${e}\x1B[22m`,ae=e=>`\x1B[2m${e}\x1B[22m`,le=e=>`\x1B[32m${e}\x1B[39m`,ve=e=>`\x1B[33m${e}\x1B[39m`,Te=e=>`\x1B[31m${e}\x1B[39m`,Se=e=>`\x1B[36m${e}\x1B[39m`,wt=e=>`\x1B[37m${e}\x1B[39m`,Ct=e=>`\x1B[42m${e}\x1B[49m`,vt=e=>`\x1B[44m${e}\x1B[49m`,Re=e=>`\x1B[7m${e}\x1B[27m`,ue=()=>"\x1B[0m",Tt=/\x1b\[[0-9;]*[a-zA-Z]/g,ke=e=>e.replace(Tt,""),j=e=>ke(e).length,z=(e,t)=>{if(ke(e).length<=t)return e;let s=0,i=0,n=e;for(;i<n.length&&s<t-1;){if(n[i]==="\x1B"){let o=n.indexOf("m",i);if(o!==-1){i=o+1;continue}}s++,i++}return n.slice(0,i)+"\u2026"+ue()};var Ke={};N(Ke,{calculateLayout:()=>St});var St=(e,t,r)=>{let s=r.leftWidth<=1?Math.floor(e*r.leftWidth):Math.min(Math.floor(r.leftWidth),e),i=e-s,n=t-1,o=r.rightTopHeight<=1?Math.floor(n*r.rightTopHeight):Math.min(Math.floor(r.rightTopHeight),n),a=n-o;return{left:{id:"left",x:1,y:1,width:s,height:n},rightTop:{id:"rightTop",x:s+1,y:1,width:i,height:o},rightBottom:{id:"rightBottom",x:s+1,y:o+1,width:i,height:a},statusBar:{id:"statusBar",x:1,y:t,width:e,height:1}}};var Fe={};N(Fe,{nextSelectableIndex:()=>kt,renderList:()=>At});var Rt=(e,t)=>{switch(t){case"green":return le(e);case"yellow":return ve(e);case"red":return Te(e);case"cyan":return Se(e);case"dim":return ae(e);default:return e}},kt=(e,t,r)=>{let s=r==="up"?-1:1,i=t+s;for(;i>=0&&i<e.length;){if(e[i].selectable!==!1)return i;i+=s}return t},At=(e,t,r)=>{let s=[],i=r.width-2,n=r.height-2,o=0;t>=n&&(o=t-n+1);for(let a=0;a<n;a++){let c=o+a,d=r.y+1+a;if(c>=e.length){s.push(T(d,r.x+1)+" ".repeat(i));continue}let l=e[c],f=l.selectable!==!1,b=c===t&&f,G=l.active?le("\u25CF"):b?"\u25B8":" ",de=l.badge!==void 0?" "+Rt(`[${l.badge}]`,l.badgeColor??"dim"):"",me=l.dimmed?ae(l.label):l.label,he=` ${G} ${me}${de}`,fe=z(he,i),Pe=Math.max(0,i-j(fe));b?s.push(T(d,r.x+1)+Re(fe+" ".repeat(Pe))):s.push(T(d,r.x+1)+fe+" ".repeat(Pe))}return s.join("")};var Y=()=>({char:" ",fg:-1,bg:-1,fgRGB:null,bgRGB:null,bold:!1,dim:!1,italic:!1,underline:!1,inverse:!1}),pe=(e,t)=>{let r=[];for(let s=0;s<e;s++){let i=[];for(let n=0;n<t;n++)i.push(Y());r.push(i)}return r},X=e=>{let t=[];for(let r=0;r<e;r++)t.push(Y());return t},J=class{#e;#t;#r;#i=null;#o=0;#n;#s=new Set;constructor(t,r){this.#e=t,this.#t=r,this.#r=pe(t,r),this.#n=t-1}get rows(){return this.#e}get cols(){return this.#t}getCell(t,r){return t<0||t>=this.#e||r<0||r>=this.#t?Y():this.#r[t][r]}setCell(t,r,s,i){t<0||t>=this.#e||r<0||r>=this.#t||(this.#r[t][r]={char:i,fg:s.fg,bg:s.bg,fgRGB:s.fgRGB,bgRGB:s.bgRGB,bold:s.bold,dim:s.dim,italic:s.italic,underline:s.underline,inverse:s.inverse},this.#s.add(t))}scrollUp(t=1){for(let r=0;r<t;r++)this.#r.splice(this.#o,1),this.#r.splice(this.#n,0,X(this.#t));for(let r=this.#o;r<=this.#n;r++)this.#s.add(r)}scrollDown(t=1){for(let r=0;r<t;r++)this.#r.splice(this.#n,1),this.#r.splice(this.#o,0,X(this.#t));for(let r=this.#o;r<=this.#n;r++)this.#s.add(r)}setScrollRegion(t,r){this.#o=Math.max(0,t),this.#n=Math.min(this.#e-1,r)}insertLines(t,r){for(let s=0;s<t;s++)this.#r.splice(this.#n,1),this.#r.splice(r,0,X(this.#t));for(let s=r;s<=this.#n;s++)this.#s.add(s)}deleteLines(t,r){for(let s=0;s<t;s++)this.#r.splice(r,1),this.#r.splice(this.#n,0,X(this.#t));for(let s=r;s<=this.#n;s++)this.#s.add(s)}clearLine(t,r){if(t<0||t>=this.#e)return;let s=this.#r[t];if(r===2)for(let i=0;i<this.#t;i++)s[i]=Y();this.#s.add(t)}clearLineRange(t,r,s){if(t<0||t>=this.#e)return;let i=this.#r[t];for(let n=r;n<=Math.min(s,this.#t-1);n++)i[n]=Y();this.#s.add(t)}clearDisplay(t,r,s){if(t===0){this.clearLineRange(r,s,this.#t-1);for(let i=r+1;i<this.#e;i++)this.clearLine(i,2)}else if(t===1){for(let i=0;i<r;i++)this.clearLine(i,2);this.clearLineRange(r,0,s)}else{this.#r=pe(this.#e,this.#t);for(let i=0;i<this.#e;i++)this.#s.add(i)}}enterAlternateScreen(){this.#i=this.#r,this.#r=pe(this.#e,this.#t);for(let t=0;t<this.#e;t++)this.#s.add(t)}exitAlternateScreen(){if(this.#i!==null){this.#r=this.#i,this.#i=null;for(let t=0;t<this.#e;t++)this.#s.add(t)}}resize(t,r){let s=pe(t,r),i=Math.min(t,this.#e),n=Math.min(r,this.#t);for(let o=0;o<i;o++)for(let a=0;a<n;a++)s[o][a]=this.#r[o][a];this.#e=t,this.#t=r,this.#r=s,this.#n=t-1;for(let o=0;o<t;o++)this.#s.add(o)}getLine(t){return t<0||t>=this.#e?X(this.#t):this.#r[t]}getGrid(){return this.#r}getDirtyLines(){return this.#s}clearDirty(){this.#s.clear()}markAllDirty(){for(let t=0;t<this.#e;t++)this.#s.add(t)}};var Z=class{row=0;col=0;visible=!0;#e=0;#t=0;moveTo(t,r){this.row=t,this.col=r}moveUp(t=1){this.row=Math.max(0,this.row-t)}moveDown(t=1){this.row+=t}moveForward(t=1){this.col+=t}moveBack(t=1){this.col=Math.max(0,this.col-t)}moveToColumn(t){this.col=t}save(){this.#e=this.row,this.#t=this.col}restore(){this.row=this.#e,this.col=this.#t}clamp(t,r){this.row=Math.max(0,Math.min(this.row,t-1)),this.col=Math.max(0,Math.min(this.col,r-1))}};var Q=()=>({fg:-1,bg:-1,fgRGB:null,bgRGB:null,bold:!1,dim:!1,italic:!1,underline:!1,inverse:!1}),Ae=(e,t)=>{let r={...t},s=0;for(;s<e.length;){let i=e[s];switch(i){case 0:Object.assign(r,Q());break;case 1:r.bold=!0;break;case 2:r.dim=!0;break;case 3:r.italic=!0;break;case 4:r.underline=!0;break;case 7:r.inverse=!0;break;case 22:r.bold=!1,r.dim=!1;break;case 23:r.italic=!1;break;case 24:r.underline=!1;break;case 27:r.inverse=!1;break;case 30:case 31:case 32:case 33:case 34:case 35:case 36:case 37:r.fg=i-30;break;case 39:r.fg=-1;break;case 40:case 41:case 42:case 43:case 44:case 45:case 46:case 47:r.bg=i-40;break;case 49:r.bg=-1;break;case 90:case 91:case 92:case 93:case 94:case 95:case 96:case 97:r.fg=i-90+8;break;case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:r.bg=i-100+8;break;case 38:s+1<e.length&&e[s+1]===5&&s+2<e.length?(r.fg=e[s+2],r.fgRGB=null,s+=2):s+1<e.length&&e[s+1]===2&&s+4<e.length&&(r.fgRGB={r:e[s+2],g:e[s+3],b:e[s+4]},r.fg=-1,s+=4);break;case 48:s+1<e.length&&e[s+1]===5&&s+2<e.length?(r.bg=e[s+2],r.bgRGB=null,s+=2):s+1<e.length&&e[s+1]===2&&s+4<e.length&&(r.bgRGB={r:e[s+2],g:e[s+3],b:e[s+4]},r.bg=-1,s+=4);break}s++}return r};var ee=class{#e="GROUND";#t="";#r="";#i="";feed(t){let r=[],s=()=>{this.#i.length>0&&(r.push({type:"text",text:this.#i}),this.#i="")};for(let i=0;i<t.length;i++){let n=t[i],o=n.charCodeAt(0);switch(this.#e){case"GROUND":n==="\x1B"?(s(),this.#e="ESC"):o<32&&o!==27?(s(),r.push({type:"control",code:o})):this.#i+=n;break;case"ESC":n==="["?(this.#e="CSI_PARAM",this.#t=""):n==="]"?(this.#e="OSC",this.#r=""):(r.push({type:"esc",command:n}),this.#e="GROUND");break;case"CSI_PARAM":if(o>=48&&o<=63||n===";"||n==="?")this.#t+=n;else if(o>=64&&o<=126){let a=this.#t.replace(/^\?/,""),c=this.#t.startsWith("?"),d=a.length>0?a.split(";").map(f=>{let b=parseInt(f,10);return isNaN(b)?0:b}):[],l=(c?"?":"")+n;r.push({type:"csi",command:l,params:d}),this.#e="GROUND"}else this.#t+=n;break;case"OSC":if(n==="\x07"||n==="\\"&&this.#r.endsWith("\x1B")){let a=n==="\\"?this.#r.slice(0,-1):this.#r,c=a.indexOf(";"),d=c>=0?parseInt(a.slice(0,c),10):0,l=c>=0?a.slice(c+1):a;r.push({type:"osc",command:isNaN(d)?0:d,data:l}),this.#e="GROUND"}else this.#r+=n;break}}return s(),r}};var te=class{screen;cursor;#e;#t;constructor(t,r){this.screen=new J(t,r),this.cursor=new Z,this.#e=new ee,this.#t=Q()}write(t){let r=this.#e.feed(t);for(let s of r)switch(s.type){case"text":this.#r(s.text);break;case"csi":this.#o(s.command,s.params);break;case"esc":this.#n(s.command);break;case"control":this.#i(s.code);break;case"osc":break}}resize(t,r){this.screen.resize(t,r),this.cursor.clamp(t,r)}getScreen(){return this.screen}getCursor(){return this.cursor}#r(t){for(let r of t)this.cursor.col>=this.screen.cols&&(this.cursor.col=0,this.cursor.row++,this.cursor.row>=this.screen.rows&&(this.screen.scrollUp(),this.cursor.row=this.screen.rows-1)),this.screen.setCell(this.cursor.row,this.cursor.col,this.#t,r),this.cursor.col++}#i(t){switch(t){case 13:this.cursor.col=0;break;case 10:this.cursor.row++,this.cursor.row>=this.screen.rows&&(this.screen.scrollUp(),this.cursor.row=this.screen.rows-1);break;case 9:this.cursor.col=Math.min(this.screen.cols-1,(Math.floor(this.cursor.col/8)+1)*8);break;case 8:this.cursor.moveBack();break;case 7:break}}#o(t,r){let s=r[0]??0,i=r[1]??0,n=s||1;switch(t){case"A":this.cursor.moveUp(n);break;case"B":this.cursor.moveDown(n);break;case"C":this.cursor.moveForward(n);break;case"D":this.cursor.moveBack(n);break;case"H":case"f":this.cursor.moveTo((s||1)-1,(i||1)-1);break;case"G":this.cursor.moveToColumn((s||1)-1);break;case"d":this.cursor.moveTo((s||1)-1,this.cursor.col);break;case"J":this.screen.clearDisplay(s,this.cursor.row,this.cursor.col);break;case"K":s===0?this.screen.clearLineRange(this.cursor.row,this.cursor.col,this.screen.cols-1):s===1?this.screen.clearLineRange(this.cursor.row,0,this.cursor.col):this.screen.clearLine(this.cursor.row,2);break;case"m":this.#t=Ae(r.length>0?r:[0],this.#t);break;case"S":this.screen.scrollUp(n);break;case"T":this.screen.scrollDown(n);break;case"L":this.screen.insertLines(n,this.cursor.row);break;case"M":this.screen.deleteLines(n,this.cursor.row);break;case"s":this.cursor.save();break;case"u":this.cursor.restore();break;case"r":this.screen.setScrollRegion((s||1)-1,(i||this.screen.rows)-1);break;case"?h":s===25&&(this.cursor.visible=!0),s===1049&&this.screen.enterAlternateScreen();break;case"?l":s===25&&(this.cursor.visible=!1),s===1049&&this.screen.exitAlternateScreen();break}this.cursor.clamp(this.screen.rows,this.screen.cols)}#n(t){switch(t){case"7":this.cursor.save();break;case"8":this.cursor.restore();break;case"M":this.cursor.row===0?this.screen.scrollDown():this.cursor.moveUp();break;case"c":this.screen.clearDisplay(2,0,0),this.cursor.moveTo(0,0),this.#t=Q();break}}};var Bt=e=>{let t=[];return e.bold&&t.push(1),e.dim&&t.push(2),e.italic&&t.push(3),e.underline&&t.push(4),e.fgRGB!==null?t.push(38,2,e.fgRGB.r,e.fgRGB.g,e.fgRGB.b):e.fg>=0&&e.fg<8?t.push(30+e.fg):e.fg>=8&&e.fg<16?t.push(90+(e.fg-8)):e.fg>=16&&t.push(38,5,e.fg),t.length===0?"":`\x1B[${t.join(";")}m`},Mt=e=>e.fg===-1&&e.fgRGB===null&&!e.bold&&!e.dim&&!e.italic&&!e.underline,Oe=(e,t,r)=>{let s=[],i=e.getDirtyLines(),n=r.fullRedraw===!0||i.size>=r.height,o=Math.min(r.height,e.rows),a=Math.min(r.width,e.cols);for(let c=0;c<o;c++){if(!n&&!i.has(c))continue;s.push(`\x1B[${r.offsetRow+c};${r.offsetCol}H`);let d=e.getLine(c),l=!1,f=0;for(;f<a;f++){let b=f<d.length?d[f]:void 0;if(b===void 0||Mt(b))l&&(s.push("\x1B[0m"),l=!1),s.push(b?.char??" ");else{let G=Bt(b);s.push(G),l=!0,s.push(b.char)}}l&&s.push("\x1B[0m")}return e.clearDirty(),s.join("")};var Ee=class{#e;#t=!1;constructor(t,r){this.#e=new te(t,r)}write(t){this.#e.write(t),this.#t=!0}render(t,r=!1){let s={offsetRow:t.y+1,offsetCol:t.x+1,width:t.width-2,height:t.height-2,fullRedraw:r};return this.#t=!1,Oe(this.#e.getScreen(),this.#e.getCursor(),s)}resize(t,r){this.#e.resize(t,r),this.#t=!0}get dirty(){return this.#t}clearDirty(){this.#t=!1}get terminal(){return this.#e}};var qe={};N(qe,{drawBox:()=>He,fillBox:()=>Nt});var It={single:{tl:"\u250C",tr:"\u2510",bl:"\u2514",br:"\u2518",h:"\u2500",v:"\u2502"},double:{tl:"\u2554",tr:"\u2557",bl:"\u255A",br:"\u255D",h:"\u2550",v:"\u2551"},rounded:{tl:"\u256D",tr:"\u256E",bl:"\u2570",br:"\u256F",h:"\u2500",v:"\u2502"}},He=e=>{let t=e.borderStyle??"single",r=It[t],s=e.width-2,i=[],n=r.tl;if(e.title!==void 0){let o=` ${e.title} `;n+=o+r.h.repeat(Math.max(0,s-o.length))}else n+=r.h.repeat(s);if(n+=r.tr,i.push(T(e.y,e.x)+n),e.skipInterior===!0)for(let o=1;o<e.height-1;o++)i.push(T(e.y+o,e.x)+r.v+T(e.y+o,e.x+e.width-1)+r.v);else for(let o=1;o<e.height-1;o++)i.push(T(e.y+o,e.x)+r.v+ue()+" ".repeat(s)+r.v);return i.push(T(e.y+e.height-1,e.x)+r.bl+r.h.repeat(s)+r.br),i.join("")},Nt=(e,t)=>{let r=He(e),s=e.width-2,i=e.height-2,n=[];for(let o=0;o<i;o++){let a=o<t.length?t[o]:"",c=z(a??"",s),d=Math.max(0,s-j(c));n.push(T(e.y+1+o,e.x+1)+c+" ".repeat(d))}return r+n.join("")};export{We as a,ze as b,Ie as c,O as d,Ze as e,Qe as f,et as g,tt as h,rt as i,st as j,nt as k,it as l,ot as m,at as n,lt as o,pt as p,dt as q,Ve as r,ce as s,qe as t,Ke as u,Fe as v,Ee as w};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{a as b,b as w,d as F,f as D}from"./chunk-
|
|
2
|
+
import{a as b,b as w,d as F,f as D}from"./chunk-3D5TBTM3.js";import{a as C}from"./chunk-LFNUSULJ.js";import{b as h}from"./chunk-O325ZU5M.js";import{f as R}from"./chunk-P2MUEKFT.js";import{b as l,f as m,g as k,h as A,i as g}from"./chunk-YVN2NZL4.js";import{g as d}from"./chunk-FFWPJP7A.js";var x=(e,r)=>{let o={},t=e.length;for(let s=0;s<t;s++){let n=e[s],a=r(n);o[a]===void 0?o[a]=[n]:o[a].push(n)}return o};var u=h(),P=(e,r)=>e===r?!0:typeof e!=typeof r||typeof e!="object"||e===null||r===null?!1:JSON.stringify(e)===JSON.stringify(r),O=(e,r)=>e[r],j=e=>e.startsWith("npm:@jsr/"),B=e=>{let r=e.slice(9),o=r.indexOf("__");if(o===-1)throw new Error(`Invalid npm JSR format: ${e}`);let t=r.slice(0,o),s=r.slice(o+2),n=s.indexOf("@"),a,p;return n===-1?(a=s,p=""):(a=s.slice(0,n),p=s.slice(n)),`jsr:@${t}/${a}${p}`},_=(e,r)=>j(r)?B(r):r.startsWith("npm:")?r:`npm:${e}@${r}`,S=e=>e==="workspace:*"||e.startsWith("workspace:"),M=(e,r,o)=>{let t=[],s=r.dependencies??{},n=r.devDependencies??{},a={...s,...n},p=o.imports??{};for(let[y,c]of Object.entries(a)){if(S(c))continue;let f=_(y,c),i=p[y];i===void 0?t.push({packageName:e,dependencyName:y,issue:"missing_in_deno",expected:f}):i!==f&&t.push({packageName:e,dependencyName:y,issue:"version_mismatch",expected:f,actual:i})}for(let[y,c]of Object.entries(p))a[y]===void 0&&t.push({packageName:e,dependencyName:y,issue:"missing_in_package",actual:p[y]});return t},G=async(e,r)=>{let o=[],t=[],s=await w({baseDir:e,includeFiles:[b.DenoJson,b.PackageJson]}),n=s._loadedFiles.find(c=>c.fileType===b.DenoJson),a=s._loadedFiles.find(c=>c.fileType===b.PackageJson);if(n===void 0||a===void 0)return{inconsistencies:[],dependencyInconsistencies:[]};let p=["name","version","exports"];for(let c of p){let f=O(n.content,c),i=O(a.content,c);f===void 0||i===void 0||P(f,i)||o.push({packageName:r,field:c,denoValue:f,packageValue:i})}let y=M(r,a.content,n.content);return t.push(...y),{inconsistencies:o,dependencyInconsistencies:t}},K=async(e={})=>{let{root:r=".",failFast:o=!1}=e,[t,s]=await D(r),n=[],a=[],p=0;for(let c of s){let f=F(c.config);try{let i=await G(f,c.name);if(p++,i.inconsistencies.length>0&&n.push(...i.inconsistencies),i.dependencyInconsistencies.length>0&&a.push(...i.dependencyInconsistencies),o&&(i.inconsistencies.length>0||i.dependencyInconsistencies.length>0))return{isConsistent:!1,inconsistencies:n,dependencyInconsistencies:a,packagesChecked:p}}catch{continue}}return{isConsistent:!(n.length>0||a.length>0),inconsistencies:n,dependencyInconsistencies:a,packagesChecked:p}},v=e=>typeof e=="string"?`"${e}"`:JSON.stringify(e,null,2),H=e=>{switch(e.issue){case"missing_in_deno":return`Missing in deno.json imports. Expected: ${e.expected}`;case"missing_in_package":return`Extra in deno.json imports (not in package.json): ${e.actual}`;case"version_mismatch":return`Version mismatch. Expected: ${e.expected}, Actual: ${e.actual}`}},L=e=>R.fromPromise(()=>K(e)),$=e=>d.ok({root:"."}),N=e=>{if(d.isFail(e))return u.writeln(m("\u2717"),l(" "+String(e.error))),d.fail({exitCode:1});let{value:r}=e;if(u.writeln(g("\u2139"),l(` Checked ${r.packagesChecked} packages.`)),!r.isConsistent){if(r.inconsistencies.length>0){u.writeln(m("\u2717"),l(` Found ${r.inconsistencies.length} field inconsistencies:`));let o=x(r.inconsistencies,t=>t.packageName);for(let[t,s]of Object.entries(o)){u.writeln(A("\u26A0"),l(" "+t));for(let n of s)u.writeln(m("\u2717"),l(` ${n.field} mismatch:`)),u.writeln(g("\u2139"),l(` deno.json: ${v(n.denoValue)}`)),u.writeln(g("\u2139"),l(` package.json: ${v(n.packageValue)}`))}}if(r.dependencyInconsistencies.length>0){u.writeln(m("\u2717"),l(` Found ${r.dependencyInconsistencies.length} dependency inconsistencies:`));let o=x(r.dependencyInconsistencies,t=>t.packageName);for(let[t,s]of Object.entries(o)){u.writeln(A("\u26A0"),l(" "+t));for(let n of s)u.writeln(m("\u2717"),l(` ${n.dependencyName}:`)),u.writeln(g("\u2139"),l(` ${H(n)}`))}}return d.fail({exitCode:1})}return u.writeln(k("\u2713"),l(" All package configs are consistent.")),d.ok(void 0)},J=C.createTrigger({handler:L,adaptInput:$,adaptOutput:N}),qn=async e=>await J({command:"validate-package-configs",args:[],flags:{}});export{K as a,L as b,J as c,qn as d};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{i as d}from"./chunk-
|
|
2
|
+
import{i as d}from"./chunk-6DBKPC2O.js";var l=[["go.mod","go"],["deno.json","deno"],["deno.jsonc","deno"],["package.json","node"]],g=async r=>{for(let[c,n]of l)try{return await d.fs.stat(`${r}/${c}`),{type:n,configFile:c}}catch{}return{type:"unknown",configFile:void 0}},f=(r,c)=>{let n=[],t=[],e=r.dependencies;if(e===void 0)return{instructions:n,warnings:t};let i=r.language,o=c.type;if(o!=="unknown"&&(i==="go"&&o==="go"||i==="typescript"&&(o==="deno"||o==="node")||i==="javascript"&&(o==="deno"||o==="node")||t.push(`Recipe '${r.name}' is for ${i}, but detected ${o} project (${c.configFile}).`)),e.go!==void 0&&e.go.length>0)for(let s of e.go)n.push(`go get ${s}`);if(e.jsr!==void 0&&e.jsr.length>0)for(let s of e.jsr)n.push(`deno add ${s}`);if(e.npm!==void 0&&e.npm.length>0)for(let s of e.npm)n.push(`npm install ${s}`);return{instructions:n,warnings:t}},y=async(r,c,n)=>{let t=[];for(let e of r){if(n?.dryRun===!0){t.push({command:e,success:!0});continue}n?.verbose===!0&&console.log(` [install] ${e}`);let i=e.split(/\s+/),o=i[0],s=i.slice(1);try{let a=await d.exec.spawn(o,s,{cwd:c,stdout:"inherit",stderr:"inherit"});if(!a.success){t.push({command:e,success:!1,error:`Exit code ${a.code}`});break}t.push({command:e,success:!0})}catch(a){let u=a instanceof Error?a.message:String(a);t.push({command:e,success:!1,error:u});break}}return t};export{g as a,f as b,y as c};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
+
import{a,b}from"./chunk-EQUPVWVY.js";import"./chunk-2TANTKYS.js";import"./chunk-J7YTWK67.js";import"./chunk-GVTM4EOU.js";import"./chunk-6DBKPC2O.js";import"./chunk-ALFFE37K.js";import"./chunk-6G6UVWJN.js";import"./chunk-5WJ6AUNY.js";export{a as ClaudeCodeModel,b as claudeCodeFactory};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{a as E,b as A}from"./chunk-
|
|
2
|
+
import{a as E,b as A}from"./chunk-ZNP3NXAD.js";import{e as x}from"./chunk-X3L6GBUX.js";import{a as P,d as $}from"./chunk-P2MUEKFT.js";import{h as j,p as S}from"./chunk-NMSD4ZXJ.js";import{f as k,h as b,k as C}from"./chunk-SHN5MT56.js";import{d,f as R,g as v,k as h}from"./chunk-YVN2NZL4.js";import{a as w}from"./chunk-MG65QJY6.js";import{a as c,b as l,c as y}from"./chunk-FFWPJP7A.js";import{i as f}from"./chunk-6DBKPC2O.js";import"./chunk-ALFFE37K.js";import"./chunk-6G6UVWJN.js";import"./chunk-5WJ6AUNY.js";var I=r=>{let t=j(r);if(t.kind==="repo")return t},H=r=>P(async t=>{try{let{specifier:n}=r,e=r.recipePath??"recipe.json",s=await S(n.owner,n.repo,n.ref,e),o=r.cwd;r.projectName!==void 0&&(o=`${r.cwd}/${r.projectName}`,await f.fs.mkdir(o,{recursive:!0}));let a={...r.variables};r.projectName!==void 0&&a.project_name===void 0&&(a.project_name=r.projectName);let m=`https://raw.githubusercontent.com/${n.owner}/${n.repo}/${n.ref}`,i=await x(s,{cwd:o,registryUrl:m,force:r.force,skipExisting:r.skipExisting,dryRun:r.dryRun,verbose:r.verbose,variables:a}),u=await E(o),g=A(s,u),O=r.dryRun?"Would write":"Cloned";t.out.writeln(v(`\u2713 ${O} ${i.written.length} file(s) from ${s.name}`));for(let p of i.written)t.out.writeln(` \u2192 ${p}`);if(i.postInstallRan.length>0){t.out.writeln(d(`
|
|
3
3
|
Post-install:`));for(let p of i.postInstallRan)t.out.writeln(d(` \u2713 ${p}`))}if(g.instructions.length>0){t.out.writeln(d(`
|
|
4
4
|
Dependencies:`));for(let p of g.instructions)t.out.writeln(d(` Run: ${p}`))}return c({recipe:s,result:i,depInfo:g,targetDir:o})}catch(n){let e=n instanceof Error?n.message:String(n);return l({_tag:"ApplyError",message:e})}});var J=async r=>{let t=w(r??[],{string:["recipe","name","var"],boolean:["force","dry-run","skip-existing","verbose"],collect:["var"],alias:{p:"name"}}),n=t._[0],e=k({renderer:C.ansi(),sink:b.stdout()});if(n===void 0)return e.writeln("Usage: eser kit clone <specifier> [options]"),e.writeln(),e.writeln("Specifier formats:"),e.writeln(" owner/repo GitHub repo (default branch)"),e.writeln(" owner/repo#ref GitHub repo at specific tag/branch"),e.writeln(),e.writeln("Options:"),e.writeln(" --recipe <path> Path to recipe.json (default: recipe.json)"),e.writeln(" --name, -p <dir> Target directory"),e.writeln(" --var key=value Template variable (repeatable)"),e.writeln(" --force Overwrite existing files"),e.writeln(" --dry-run Preview without writing"),await e.close(),c(void 0);let s=I(n);if(s===void 0)return e.writeln(R(`Invalid specifier: '${n}'. Use format: owner/repo or gh:owner/repo#ref`)),await e.close(),l({exitCode:1});let o={};for(let m of t.var){let[i,...u]=String(m).split("=");i!==void 0&&i!==""&&(o[i]=u.join("="))}e.writeln(h(`
|
|
5
5
|
Cloning from ${s.owner}/${s.repo}@${s.ref}...
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{a,b,c,d}from"./chunk-
|
|
2
|
+
import{a,b,c,d}from"./chunk-UEMWZOIU.js";import"./chunk-6DBKPC2O.js";import"./chunk-ALFFE37K.js";import"./chunk-6G6UVWJN.js";import"./chunk-5WJ6AUNY.js";export{c as cmd,b as cmdPrefix,d as extractPrefix,a as setCommandPrefix};
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import"./chunk-7ZYDAZBD.js";import{a as w,b as x}from"./chunk-GE3LJ6QM.js";import"./chunk-
|
|
2
|
+
import"./chunk-7ZYDAZBD.js";import{a as w,b as x}from"./chunk-GE3LJ6QM.js";import"./chunk-N4NDBIQS.js";import{a as h}from"./chunk-BNQAZLIQ.js";import{f,h as g,k as p}from"./chunk-SHN5MT56.js";import{c as n,d,f as u}from"./chunk-YVN2NZL4.js";import"./chunk-J7YTWK67.js";import{d as o}from"./chunk-GVTM4EOU.js";import"./chunk-6BILFSH2.js";import"./chunk-NMEPQK3T.js";import"./chunk-RNFCAHVL.js";import"./chunk-MG65QJY6.js";import{a as l,b as m}from"./chunk-FFWPJP7A.js";import"./chunk-6DBKPC2O.js";import"./chunk-ALFFE37K.js";import"./chunk-6G6UVWJN.js";import"./chunk-5WJ6AUNY.js";var b=`Output ONLY a conventional commit message. No explanation, no markdown, no code blocks, no bullet points.
|
|
3
3
|
|
|
4
4
|
Format: type(scope): description
|
|
5
5
|
Types: feat, fix, chore, docs, refactor, test, style, perf, ci, build
|
|
6
6
|
Max 72 characters. One line only. No body. No quotes. No backticks.
|
|
7
7
|
|
|
8
8
|
Example output:
|
|
9
|
-
feat(ai): add streaming support for Claude Code adapter`,v=async i=>{let e=f({renderer:p.ansi(),sink:g.stdout()});try{let t=await o`git diff --cached`.noThrow().text();if(t.length===0&&(t=await o`git diff`.noThrow().text()),t.length===0)return e.writeln(d("No changes detected (nothing staged or modified).")),await e.close(),l(void 0);let s=await y(t),r=s.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/`/g,"\\`").replace(/\$/g,"\\$").replace(/!/g,"\\!");return e.writeln(""),e.writeln(n("Plain Format:")),e.writeln("```"),e.writeln(s),e.writeln("```"),e.writeln(""),e.writeln(n("Shell Command:")),e.writeln("```"),e.writeln(`git commit -m "${r}"`),e.writeln("```"),e.writeln(""),e.writeln(n("Copy to Clipboard:")),e.writeln("```"),e.writeln(`echo "${r}" | pbcopy`),e.writeln("```"),await e.close(),l(void 0)}catch(t){let s=t instanceof Error?t.message:String(t);return e.writeln(u(`Error: ${s}`)),await e.close(),m({message:s,exitCode:1})}},y=async(i,e)=>{let s=await(await import("./mod-
|
|
9
|
+
feat(ai): add streaming support for Claude Code adapter`,v=async i=>{let e=f({renderer:p.ansi(),sink:g.stdout()});try{let t=await o`git diff --cached`.noThrow().text();if(t.length===0&&(t=await o`git diff`.noThrow().text()),t.length===0)return e.writeln(d("No changes detected (nothing staged or modified).")),await e.close(),l(void 0);let s=await y(t),r=s.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/`/g,"\\`").replace(/\$/g,"\\$").replace(/!/g,"\\!");return e.writeln(""),e.writeln(n("Plain Format:")),e.writeln("```"),e.writeln(s),e.writeln("```"),e.writeln(""),e.writeln(n("Shell Command:")),e.writeln("```"),e.writeln(`git commit -m "${r}"`),e.writeln("```"),e.writeln(""),e.writeln(n("Copy to Clipboard:")),e.writeln("```"),e.writeln(`echo "${r}" | pbcopy`),e.writeln("```"),await e.close(),l(void 0)}catch(t){let s=t instanceof Error?t.message:String(t);return e.writeln(u(`Error: ${s}`)),await e.close(),m({message:s,exitCode:1})}},y=async(i,e)=>{let s=await(await import("./mod-KPIOBBDD.js")).defaultFactories(),r=new w({factories:s}),a=e;if(a===void 0)try{await o`which claude`.noThrow().code()===0&&(a="claude-code")}catch{}a===void 0&&(a="anthropic"),await r.addModel("default",{provider:a,model:"default"});let c=r.getDefault();if(c===null)throw new Error("No AI model available for commit message generation");let k=await c.generateText({system:b,messages:[h("user",`Generate a commit message for this diff:
|
|
10
10
|
|
|
11
11
|
${i}`)],maxTokens:256});return await r.close(),x(k).trim()},O={name:"ai-commitmsg",description:"Generate commit message from git diff using AI",run:async i=>{try{let e=i.provider,t=await o`git diff --cached`.noThrow().text();return t.length===0&&(t=await o`git diff`.noThrow().text()),t.length===0?{name:"ai-commitmsg",passed:!0,issues:[],mutations:[],stats:{skipped:1}}:{name:"ai-commitmsg",passed:!0,issues:[{message:`Suggested: ${await y(t,e)}`}],mutations:[],stats:{generated:1}}}catch(e){return{name:"ai-commitmsg",passed:!1,issues:[{message:e instanceof Error?e.message:String(e)}],mutations:[],stats:{errors:1}}}}};export{y as generateCommitMessage,v as main,O as workflowTool};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{b as A}from"./chunk-2HSGE3TL.js";import{k,l as y,m as x,n as P}from"./chunk-
|
|
2
|
+
import{b as A}from"./chunk-2HSGE3TL.js";import{k,l as y,m as x,n as P}from"./chunk-TMMAF763.js";import{b as $,c as b}from"./chunk-UEMWZOIU.js";import"./chunk-2XNFZXHY.js";import{f as m,h as w,k as g}from"./chunk-SHN5MT56.js";import{c as d,d as c,f as u,g as C}from"./chunk-YVN2NZL4.js";import{a as l,b as p}from"./chunk-FFWPJP7A.js";import{i as v}from"./chunk-6DBKPC2O.js";import"./chunk-ALFFE37K.js";import"./chunk-6G6UVWJN.js";import"./chunk-5WJ6AUNY.js";var q=async s=>{let e=s?.[0];if(e==="add")return await I(s?.slice(1));if(e==="remove")return await M(s?.slice(1));if(e==="list")return await R();let r=$(),n=m({renderer:g.ansi(),sink:w.stdout()});return n.writeln(`Usage: ${r} concern <add <id> | remove <id> | list>`),await n.close(),l(void 0)},I=async s=>{let e=m({renderer:g.ansi(),sink:w.stdout()}),r=v.process.cwd(),n=(s??[]).filter(i=>!i.startsWith("-")),t=await k(r);if(n.length===0)return e.writeln(u("Please provide concern ID(s): "),d(b("concern add open-source beautiful-product"))),await e.close(),p({exitCode:1});if(t===null)return e.writeln(u("noskills not initialized.")),await e.close(),p({exitCode:1});let a=await A(),o=[];for(let i of n){let f=await x(r,i);if(f===null&&(f=a.find(h=>h.id===i)??null,f!==null&&await P(r,f)),f===null){e.writeln(u(`Unknown concern: ${i}`)),e.writeln(c(` Available: ${a.map(h=>h.id).join(", ")}`));continue}if(t.concerns.includes(i)||o.includes(i)){e.writeln(c(`Concern "${i}" is already active.`));continue}o.push(i)}if(o.length>0){let i={...t,concerns:[...t.concerns,...o]};await y(r,i),e.writeln(C("\u2714"),` Activated concerns: ${o.join(", ")}`)}return await e.close(),l(void 0)},M=async s=>{let e=m({renderer:g.ansi(),sink:w.stdout()}),r=v.process.cwd(),n=s?.[0],t=await k(r);if(n===void 0||n.length===0)return e.writeln(u("Please provide a concern ID: "),d(b("concern remove move-fast"))),await e.close(),p({exitCode:1});if(t===null)return e.writeln(u("noskills not initialized.")),await e.close(),p({exitCode:1});if(!t.concerns.includes(n))return e.writeln(c(`Concern "${n}" is not active.`)),await e.close(),l(void 0);let a={...t,concerns:t.concerns.filter(o=>o!==n)};return await y(r,a),e.writeln(C("\u2714")," Deactivated concern: ",d(n)),await e.close(),l(void 0)},R=async()=>{let s=m({renderer:g.ansi(),sink:w.stdout()}),e=v.process.cwd(),r=await k(e),n=await A(),t=r?.concerns??[];if(s.writeln(d("Concerns")),s.writeln(""),n.length===0)s.writeln(c(" No concerns defined."));else for(let a of n){let o=t.includes(a.id);s.writeln(" ",o?C("\u25CF"):c("\u25CB")," ",o?d(a.id):c(a.id),c(` ${a.description.slice(0,60)}...`))}return await s.close(),l(void 0)};export{q as main};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{a as P,b as v,c as
|
|
2
|
+
import{a as P,b as v,c as S,d as b}from"./chunk-2BOCLC67.js";import"./chunk-N7DXBY3O.js";import{d as h,e as p,f as g,g as f,i as F,j as y,k,n as x}from"./chunk-7ATUODBM.js";import"./chunk-AP72BKVG.js";import{b as d,d as D,r as w}from"./chunk-6G6UVWJN.js";import"./chunk-5WJ6AUNY.js";import O from"node:process";var R={fs:!0,fsSync:!0,exec:!0,process:!0,env:!0,stdin:!0,stdout:!0,kv:!0},E=()=>{let n=t=>({isFile:t.isFile,isDirectory:t.isDirectory,isSymlink:t.isSymlink,size:t.size,mtime:t.mtime,atime:t.atime,birthtime:t.birthtime});return{async readFile(t,e){try{return await Deno.readFile(t,{signal:e?.signal})}catch(r){throw r instanceof Deno.errors.NotFound?new d(t):r}},async readTextFile(t,e){try{return await Deno.readTextFile(t,{signal:e?.signal})}catch(r){throw r instanceof Deno.errors.NotFound?new d(t):r}},async writeFile(t,e,r){await Deno.writeFile(t,e,{signal:r?.signal,mode:r?.mode,create:r?.create??!0,append:r?.append??!1})},async writeTextFile(t,e,r){await Deno.writeTextFile(t,e,{signal:r?.signal,mode:r?.mode,create:r?.create??!0,append:r?.append??!1})},async exists(t){try{return await Deno.stat(t),!0}catch(e){if(e instanceof Deno.errors.NotFound)return!1;throw e}},async stat(t){try{let e=await Deno.stat(t);return n(e)}catch(e){throw e instanceof Deno.errors.NotFound?new d(t):e}},async lstat(t){try{let e=await Deno.lstat(t);return n(e)}catch(e){throw e instanceof Deno.errors.NotFound?new d(t):e}},async mkdir(t,e){await Deno.mkdir(t,{recursive:e?.recursive??!1,mode:e?.mode})},async ensureDir(t){try{await Deno.mkdir(t,{recursive:!0})}catch(e){if(!(e instanceof Deno.errors.AlreadyExists))throw e}},async remove(t,e){try{await Deno.remove(t,{recursive:e?.recursive??!1})}catch(r){throw r instanceof Deno.errors.NotFound?new d(t):r}},async*readDir(t){try{for await(let e of Deno.readDir(t))yield{name:e.name,isFile:e.isFile,isDirectory:e.isDirectory,isSymlink:e.isSymlink}}catch(e){throw e instanceof Deno.errors.NotFound?new d(t):e}},async copyFile(t,e){await Deno.copyFile(t,e)},async rename(t,e){await Deno.rename(t,e)},async makeTempDir(t){return await Deno.makeTempDir({dir:t?.dir,prefix:t?.prefix,suffix:t?.suffix})},async realPath(t){try{return await Deno.realPath(t)}catch(e){throw e instanceof Deno.errors.NotFound?new d(t):e}},watch(t,e){let r=e?.recursive??!0,a=Deno.watchFs(t,{recursive:r}),s=c=>({kind:c.kind,paths:c.paths,flag:c.flag});return{close:()=>a.close(),[Symbol.asyncIterator]:async function*(){for await(let c of a)yield s(c)}}},async*walk(t,e){let r=e?.includeDirs??!0,a=e?.includeFiles??!0,s=e?.exts,c=e?.skip,o=async function*(l){for await(let i of Deno.readDir(l)){let m=y(l,i.name);if(!c?.some(u=>u.test(m))){if(i.isDirectory)r&&(yield{path:m,name:i.name,isFile:!1,isDirectory:!0,isSymlink:i.isSymlink}),yield*o(m);else if(i.isFile||i.isSymlink){if(!a||s&&!s.some(u=>i.name.endsWith(u.startsWith(".")?u:`.${u}`)))continue;yield{path:m,name:i.name,isFile:i.isFile,isDirectory:!1,isSymlink:i.isSymlink}}}}};yield*o(t)},async chmod(t,e){let{chmod:r}=await import("./unstable_chmod-2W47KJY3.js");await r(t,e)}}},T=()=>({join:y,resolve:x,dirname:f,basename:h,extname:P,normalize:k,isAbsolute:F,relative:b,parse:S,format:v,sep:g,delimiter:p}),A=()=>({async spawn(n,t=[],e){let r=w(e),s=await new Deno.Command(n,{args:t,cwd:e?.cwd,env:e?.env,stdin:r.stdin,stdout:r.stdout,stderr:r.stderr,signal:e?.signal}).output();return{success:s.success,code:s.code,stdout:r.stdout==="piped"?s.stdout:new Uint8Array,stderr:r.stderr==="piped"?s.stderr:new Uint8Array}},async exec(n,t=[],e){let r=await this.spawn(n,t,e);if(!r.success){let a=new TextDecoder().decode(r.stderr);throw new D(n,r.code,a)}return new TextDecoder().decode(r.stdout).trim()},async execJson(n,t=[],e){let r=await this.exec(n,t,e);return JSON.parse(r)},spawnChild(n,t=[],e){let r=w(e),s=new Deno.Command(n,{args:t,cwd:e?.cwd,env:e?.env,stdin:r.stdin,stdout:r.stdout,stderr:r.stderr,signal:e?.signal}).spawn(),c=(o,l)=>l!=="piped"||!o?Promise.resolve(new Uint8Array):new Response(o).arrayBuffer().then(i=>new Uint8Array(i));return{pid:s.pid,stdin:r.stdin==="piped"?s.stdin:null,stdout:r.stdout==="piped"?s.stdout:null,stderr:r.stderr==="piped"?s.stderr:null,status:s.status.then(o=>({success:o.success,code:o.code,signal:o.signal??void 0})),output:async()=>{let o=r.stdout==="piped"?s.stdout:null,l=r.stderr==="piped"?s.stderr:null,[i,m,u]=await Promise.all([s.status,c(o,r.stdout),c(l,r.stderr)]);return{success:i.success,code:i.code,stdout:m,stderr:u}},kill:o=>{s.kill(o)}}}}),I=()=>({get(n){return Deno.env.get(n)},set(n,t){Deno.env.set(n,t)},delete(n){Deno.env.delete(n)},has(n){return Deno.env.get(n)!==void 0},toObject(){return Deno.env.toObject()}}),W=()=>({exit(n){Deno.exit(n)},setExitCode(n){Deno.exitCode=n},cwd(){return Deno.cwd()},chdir(n){Deno.chdir(n)},hostname(){return Deno.hostname()},execPath(){return Deno.execPath()},argv:O.argv,argv0:O.argv0,args:Deno.args,pid:Deno.pid,stdin:Deno.stdin.readable,stdout:Deno.stdout.writable,stderr:Deno.stderr.writable,isTerminal(n){try{switch(n){case"stdin":return Deno.stdin.isTerminal();case"stdout":return Deno.stdout.isTerminal();case"stderr":return Deno.stderr.isTerminal()}}catch{return!1}},setStdinRaw(n){Deno.stdin.setRaw(n)},writeToStdout(n){Deno.stdout.writeSync(n)},consoleSize(){try{return Deno.consoleSize()}catch{return{columns:80,rows:24}}}}),z=()=>{let n=E(),t=T(),e=A(),r=I(),a=W();return{name:"deno",version:Deno.version.deno,capabilities:R,fs:n,path:t,exec:e,env:r,process:a}};export{R as DENO_CAPABILITIES,z as createDenoRuntime};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{f as a,h as l,k as i}from"./chunk-
|
|
2
|
+
import{f as a,h as l,k as i}from"./chunk-SHN5MT56.js";import{k as n}from"./chunk-YVN2NZL4.js";import"./chunk-PWLF3WXM.js";import{a as t}from"./chunk-RNFCAHVL.js";import"./chunk-MG65QJY6.js";import{a as o}from"./chunk-FFWPJP7A.js";import"./chunk-6DBKPC2O.js";import"./chunk-ALFFE37K.js";import"./chunk-6G6UVWJN.js";import"./chunk-5WJ6AUNY.js";var h=["trace","debug","info","warn","error","fatal"],k=async m=>{let{flags:e}=t(m??[],[{name:"port",short:"p",type:"number",default:8e3,description:"Server port"},{name:"no-hmr",type:"boolean",description:"Disable HMR"},{name:"log-level",type:"string",default:"info",description:"Log level"},{name:"open",short:"o",type:"boolean",description:"Open browser"}]),r=a({renderer:i.ansi(),sink:l.stdout()});r.writeln(n(`
|
|
3
3
|
\u26A1 Starting development server...
|
|
4
|
-
`));let p=e.port,s=e["log-level"]??"info",c=!e["no-hmr"],g=e.open??!1,d=h.includes(s.toLowerCase())?s.toLowerCase():"info",[{startServer:u},{reactRenderer:L,reactHtmlShellBuilder:f},{reactPlugin:v},{createTailwindPlugin:b}]=await Promise.all([import("./main-
|
|
4
|
+
`));let p=e.port,s=e["log-level"]??"info",c=!e["no-hmr"],g=e.open??!1,d=h.includes(s.toLowerCase())?s.toLowerCase():"info",[{startServer:u},{reactRenderer:L,reactHtmlShellBuilder:f},{reactPlugin:v},{createTailwindPlugin:b}]=await Promise.all([import("./main-JAGIKKVD.js"),import("./mod-OG7BBJP4.js"),import("./mod-NSL6IJRQ.js"),import("./mod-VZT7JWPZ.js")]);return await r.close(),await u({mode:"dev",port:p,logLevel:d,hmr:c,open:g,renderer:L,htmlShell:f,frameworkPlugin:v,cssPlugin:b({globalCssPath:"src/app/styles/global.css"})}),o(void 0)};export{k as main};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{a as x,d as D}from"./chunk-
|
|
2
|
+
import{a as x,d as D}from"./chunk-7NKYCWAA.js";import{n as k}from"./chunk-DPZJWN2Y.js";import{c as S,e as g,g as C,h as y,i as E}from"./chunk-TMMAF763.js";import{c as $}from"./chunk-UEMWZOIU.js";import"./chunk-2XNFZXHY.js";import{f as w,h as f,k as h}from"./chunk-SHN5MT56.js";import{c as m,d as o,f as a,g as u}from"./chunk-YVN2NZL4.js";import{a as d,b as n}from"./chunk-FFWPJP7A.js";import{i as l}from"./chunk-6DBKPC2O.js";import"./chunk-ALFFE37K.js";import"./chunk-6G6UVWJN.js";import"./chunk-5WJ6AUNY.js";var G=async U=>{let e=w({renderer:h.ansi(),sink:f.stdout()}),i=l.process.cwd(),p=C(U);if(!p.ok)return e.writeln(a(p.error)),await e.close(),n({exitCode:1});let t;try{t=await g(i,p.spec)}catch(s){let c=s instanceof Error?s.message:String(s);return e.writeln(a(c)),await e.close(),n({exitCode:1})}if(t.phase!=="EXECUTING")return e.writeln(a(`Cannot complete in phase: ${t.phase}`)),e.writeln(o("Only EXECUTING phase can transition to COMPLETED.")),await e.close(),n({exitCode:1});if(t.spec!==null){let s=`${i}/${S.specDir(t.spec)}`;try{await l.fs.stat(s)}catch{return e.writeln(a(`Active spec '${t.spec}' directory not found.`)),e.writeln(o("Run `noskills reset` to return to IDLE.")),await e.close(),n({exitCode:1})}}let r=k(t,"done");if(await y(i,r),r.spec!==null&&await E(i,r.spec,r),r.spec!==null&&(await x(i,r.spec,"completed"),await D(i,r.spec,"completed")),e.writeln(u("\u2714")," Spec completed!"),e.writeln(""),e.writeln(" Spec: ",m(t.spec??"unknown")),e.writeln(` Iterations: ${t.execution.iteration}`),e.writeln(` Decisions: ${t.decisions.length}`),t.decisions.length>0){let s=t.decisions.filter(c=>c.promoted);s.length>0&&e.writeln(o(` Promoted to rules: ${s.length}`))}return e.writeln(""),e.writeln("Start a new spec with: ",m(`${$('spec new "..."')}`)),await e.close(),d(void 0)};export{G as main};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{a,b,c,d,e,f,g,h}from"./chunk-
|
|
2
|
+
import{a,b,c,d,e,f,g,h}from"./chunk-KHBIOZJE.js";import"./chunk-NBA6EFWU.js";import"./chunk-GVTM4EOU.js";import"./chunk-6DBKPC2O.js";import"./chunk-ALFFE37K.js";import"./chunk-6G6UVWJN.js";import"./chunk-5WJ6AUNY.js";export{a as DEFAULT_EXCLUDES,g as applyMutations,e as isBinaryBytes,d as loadBytes,c as loadContent,f as matchesAnyPattern,b as walkSourceFiles,h as writeMutations};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{c as x,d as g}from"./chunk-
|
|
2
|
+
import{c as x,d as g}from"./chunk-DPZJWN2Y.js";import{d as E,h as p}from"./chunk-TMMAF763.js";import{c}from"./chunk-UEMWZOIU.js";import"./chunk-2XNFZXHY.js";import{f,h as u,k as h}from"./chunk-SHN5MT56.js";import{c as o,d as m,f as n,g as l}from"./chunk-YVN2NZL4.js";import{a as i,b as r}from"./chunk-FFWPJP7A.js";import{i as w}from"./chunk-6DBKPC2O.js";import"./chunk-ALFFE37K.js";import"./chunk-6G6UVWJN.js";import"./chunk-5WJ6AUNY.js";var b=async d=>{let e=f({renderer:h.ansi(),sink:u.stdout()}),a=w.process.cwd(),S=d!==void 0&&d.some(s=>s==="--exit"),t;try{t=await E(a)}catch(s){let y=s instanceof Error?s.message:String(s);return e.writeln(n(y)),await e.close(),r({exitCode:1})}if(S){if(t.phase!=="FREE")return e.writeln(n(`Cannot exit free mode in phase: ${t.phase}`)),e.writeln(m("Only FREE phase can transition back to IDLE.")),await e.close(),r({exitCode:1});let s=g(t);return await p(a,s),e.writeln(l("\u2714")," Exited free mode. Back to IDLE."),e.writeln(""),e.writeln("Start a spec with: ",o(`${c('spec new "..."')}`)),await e.close(),i(void 0)}if(t.phase!=="IDLE")return e.writeln(n(`Cannot enter free mode in phase: ${t.phase}`)),e.writeln(m("Only IDLE phase can transition to FREE.")),await e.close(),r({exitCode:1});let k=x(t);return await p(a,k),e.writeln(l("\u2714")," Free mode active \u2014 no enforcement."),e.writeln(""),e.writeln("Exit free mode with: ",o(`${c("free --exit")}`)),await e.close(),i(void 0)};export{b as main};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{a}from"./chunk-
|
|
2
|
+
import{a}from"./chunk-O325ZU5M.js";import{o as t}from"./chunk-YACXTCWF.js";import"./chunk-VV47GXU5.js";import"./chunk-J2Z7NG2X.js";import"./chunk-YTF3BAQS.js";import"./chunk-S7S2I2K5.js";import"./chunk-NBA6EFWU.js";import"./chunk-SHN5MT56.js";import"./chunk-7DPLGQHN.js";import"./chunk-YVN2NZL4.js";import{g as o}from"./chunk-FFWPJP7A.js";import"./chunk-6DBKPC2O.js";import"./chunk-ALFFE37K.js";import"./chunk-6G6UVWJN.js";import"./chunk-5WJ6AUNY.js";var{ctx:l,output:h}=a(),n=()=>{t.info(l,`eser codebase gh \u2014 GitHub operations
|
|
3
3
|
`),console.log("Subcommands:"),console.log(" contributors Update contributor list in README.md"),console.log(" release-notes Sync CHANGELOG to GitHub Releases"),console.log(" release-tag Create and push release git tags"),console.log(`
|
|
4
|
-
Run 'eser codebase gh <subcommand> --help' for details.`)},b=async m=>{let r=m??[],e=r[0],s=r.slice(1);if(e===void 0||e==="--help"||e==="-h")return n(),o.ok(void 0);switch(e){case"contributors":return await(await import("./gh-contributors-
|
|
4
|
+
Run 'eser codebase gh <subcommand> --help' for details.`)},b=async m=>{let r=m??[],e=r[0],s=r.slice(1);if(e===void 0||e==="--help"||e==="-h")return n(),o.ok(void 0);switch(e){case"contributors":return await(await import("./gh-contributors-SXUFX3SO.js")).main(s);case"release-notes":return await(await import("./release-notes-UUCPVHBQ.js")).main(s);case"release-tag":return await(await import("./release-tag-F4B6ICW4.js")).main(s);default:return t.error(l,`Unknown gh subcommand: ${e}`),n(),o.fail({exitCode:1})}};export{b as main};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import"./chunk-SOSF762G.js";import{a as R}from"./chunk-LFNUSULJ.js";import{a as w,c as x}from"./chunk-
|
|
2
|
+
import"./chunk-SOSF762G.js";import{a as R}from"./chunk-LFNUSULJ.js";import{a as w,c as x}from"./chunk-O325ZU5M.js";import{o as c}from"./chunk-YACXTCWF.js";import"./chunk-VV47GXU5.js";import"./chunk-J2Z7NG2X.js";import"./chunk-YTF3BAQS.js";import"./chunk-S7S2I2K5.js";import"./chunk-NBA6EFWU.js";import{f as C}from"./chunk-P2MUEKFT.js";import"./chunk-SHN5MT56.js";import"./chunk-7DPLGQHN.js";import"./chunk-YVN2NZL4.js";import{g as l}from"./chunk-GVTM4EOU.js";import"./chunk-PWLF3WXM.js";import"./chunk-NMEPQK3T.js";import"./chunk-RNFCAHVL.js";import{a as b}from"./chunk-MG65QJY6.js";import{g as a}from"./chunk-FFWPJP7A.js";import"./chunk-2BOCLC67.js";import"./chunk-N7DXBY3O.js";import{n as f}from"./chunk-7ATUODBM.js";import"./chunk-AP72BKVG.js";import{j as p}from"./chunk-6DBKPC2O.js";import"./chunk-ALFFE37K.js";import"./chunk-6G6UVWJN.js";import"./chunk-5WJ6AUNY.js";var{ctx:d,output:K}=w(),m="<!-- CONTRIBUTORS:START -->",u="<!-- CONTRIBUTORS:END -->",E=async()=>{let t=await l.exec`gh repo view --json owner,name`.text(),e=JSON.parse(t);return{owner:e.owner.login,name:e.name}},P=async(t,e)=>{let o=await l.exec`gh api repos/${t}/${e}/contributors --paginate`.text();return JSON.parse(o).filter(n=>!n.login.includes("[bot]"))},v=(t,e=8)=>{if(t.length===0)return`${m}
|
|
3
3
|
${u}`;let o=[];for(let r=0;r<t.length;r+=e){let i=t.slice(r,r+e).map(s=>` <td align="center"><a href="${s.html_url}"><img src="${s.avatar_url}?s=80" width="80" /><br /><sub>${s.login}</sub></a></td>`);o.push(` <tr>
|
|
4
4
|
${i.join(`
|
|
5
5
|
`)}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{f as P,h as R,k as F}from"./chunk-
|
|
2
|
+
import{f as P,h as R,k as F}from"./chunk-SHN5MT56.js";import{b as t,c as E,d as s,f as o,g as x,k as v}from"./chunk-YVN2NZL4.js";import"./chunk-PWLF3WXM.js";import{a as T}from"./chunk-RNFCAHVL.js";import"./chunk-MG65QJY6.js";import{a as A,b as i,f as $}from"./chunk-FFWPJP7A.js";import{i as b}from"./chunk-6DBKPC2O.js";import"./chunk-ALFFE37K.js";import"./chunk-6G6UVWJN.js";import"./chunk-5WJ6AUNY.js";var S=["minimal","blog","dashboard","docs"],V=async O=>{let{positional:N,flags:m}=T(O??[],[{name:"template",short:"t",type:"string",default:"minimal",description:"Project template"},{name:"force",short:"f",type:"boolean",description:"Overwrite"},{name:"no-git",type:"boolean",description:"Skip git"},{name:"no-install",type:"boolean",description:"Skip install"}]),r=N[0]??"my-laroux-app",l=m.template,j=m.force,L=m["no-git"],n=F.ansi(),e=P({renderer:n,sink:R.stdout()});if(!S.includes(l))return await e.close(),i({message:`${n.render([o(`
|
|
3
3
|
Error: Invalid template "${l}"`)])}
|
|
4
4
|
Available templates: ${S.join(", ")}`,exitCode:1});e.writeln(v(`
|
|
5
5
|
\u2728 Creating new laroux.js project in ./${r}
|
|
6
6
|
`)),e.writeln(s(` Template: ${l}`));let c="eser",p=`laroux-template-${l}`,k="main",d=`${b.process.cwd()}/${r}`;try{await b.fs.mkdir(d,{recursive:!0})}catch{return await e.close(),i({message:n.render([o(`
|
|
7
7
|
Could not create directory: ${d}`)]),exitCode:1})}e.writeln(s(` Fetching from gh:${c}/${p}...
|
|
8
|
-
`));try{let a=await import("./registry-fetcher-
|
|
9
|
-
\u{1F389} Project created successfully!`)),e.writeln(s(` ${w.written.length} files written`))}else{let g=await import("./mod-
|
|
8
|
+
`));try{let a=await import("./registry-fetcher-TGWYJ5GN.js"),u=await import("./recipe-applier-I2VBGHZU.js"),f=await $(()=>a.fetchRecipeFromRepo(c,p,k,"recipe.json"),()=>{});if(f._tag==="Ok"&&f.value!==void 0){let g=`https://raw.githubusercontent.com/${c}/${p}/${k}`,w=await u.applyRecipe(f.value,{cwd:d,registryUrl:g,force:j,variables:{project_name:r}});e.writeln(x(`
|
|
9
|
+
\u{1F389} Project created successfully!`)),e.writeln(s(` ${w.written.length} files written`))}else{let g=await import("./mod-5NDTGNVM.js"),w=`gh:${c}/${p}`,y=await $(()=>g.scaffold({specifier:w,targetDir:r,force:j,skipPostInstall:L,interactive:!0}),h=>({message:h.message}));if(y._tag==="Fail")return await e.close(),i({message:n.render([o(`
|
|
10
10
|
Scaffolding failed: ${y.error.message}`)]),exitCode:1});let C=y.value;if(e.writeln(x(`
|
|
11
11
|
\u{1F389} Project created successfully!`)),Object.keys(C.variables).length>0){e.writeln(t(`
|
|
12
12
|
Variables applied:`));for(let[h,_]of Object.entries(C.variables))e.writeln(t(" "),s(h),t(`: ${_}`))}}}catch(a){let u=a instanceof Error?a.message:String(a);return await e.close(),i({message:n.render([o(`
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{a as oe,b as ie}from"./chunk-
|
|
2
|
+
import{a as oe,b as ie}from"./chunk-NTY267SI.js";import{d as ne}from"./chunk-L5OC7F24.js";import{d as Y}from"./chunk-WZHVKEPB.js";import"./chunk-NY4W44PI.js";import{b as P}from"./chunk-2HSGE3TL.js";import{d as se}from"./chunk-2ZYCRMUT.js";import{c as Z,d as ee,e as te}from"./chunk-2LF7QSIN.js";import{a as H,b as _,h as q,l as B,n as K,p as U,z as V}from"./chunk-TMMAF763.js";import{a as Q,c as S,d as X}from"./chunk-UEMWZOIU.js";import"./chunk-2XNFZXHY.js";import"./chunk-7ZYDAZBD.js";import{a as k,b as M,i as I,j as W,k as z,l as J,m as G,n as h,o as r,p as w}from"./chunk-YACXTCWF.js";import"./chunk-GE3LJ6QM.js";import{a as F}from"./chunk-N4NDBIQS.js";import"./chunk-BNQAZLIQ.js";import"./chunk-SHN5MT56.js";import"./chunk-YVN2NZL4.js";import"./chunk-J7YTWK67.js";import"./chunk-GVTM4EOU.js";import"./chunk-6BILFSH2.js";import"./chunk-NMEPQK3T.js";import"./chunk-RNFCAHVL.js";import"./chunk-MG65QJY6.js";import{a as b}from"./chunk-FFWPJP7A.js";import{i as f}from"./chunk-6DBKPC2O.js";import"./chunk-ALFFE37K.js";import"./chunk-6G6UVWJN.js";import"./chunk-5WJ6AUNY.js";var re=F;var me=async t=>{try{return await f.fs.stat(t),!0}catch{return!1}},he=[{id:"claude-code",paths:["CLAUDE.md",".claude"]},{id:"cursor",paths:[".cursorrules",".cursor"]},{id:"kiro",paths:[".kiro"]},{id:"copilot",paths:[".github/copilot-instructions.md"]},{id:"windsurf",paths:[".windsurfrules"]},{id:"codex",paths:[".codex",".codex/config.toml"]},{id:"copilot-cli",paths:[".copilot",".github/hooks"]}],ae=async t=>{let e=[];for(let o of he)for(let s of o.paths)if(await me(`${t}/${s}`)){e.push(o.id);break}return e};var a=async t=>{try{return await f.fs.stat(t),!0}catch{return!1}},ce=async(t,e)=>{try{let o=await f.fs.readTextFile(t);return JSON.parse(o)[e]??null}catch{return null}},ye=async t=>{let e=[];return(await a(`${t}/package.json`)||await a(`${t}/deno.json`))&&e.push("typescript"),await a(`${t}/go.mod`)&&e.push("go"),await a(`${t}/Cargo.toml`)&&e.push("rust"),(await a(`${t}/pyproject.toml`)||await a(`${t}/setup.py`))&&e.push("python"),e},Ce=async t=>{let e=[],o=await ce(`${t}/package.json`,"dependencies");return o!==null&&("react"in o&&e.push("react"),"vue"in o&&e.push("vue"),"svelte"in o&&e.push("svelte"),"next"in o&&e.push("nextjs"),"express"in o&&e.push("express"),"hono"in o&&e.push("hono")),e},ve=async t=>{let e=[];return await a(`${t}/.github/workflows`)&&e.push("github-actions"),await a(`${t}/.gitlab-ci.yml`)&&e.push("gitlab-ci"),await a(`${t}/Jenkinsfile`)&&e.push("jenkins"),await a(`${t}/.circleci`)&&e.push("circleci"),e},$e=async t=>{if(await a(`${t}/deno.json`))return"deno";let e=await ce(`${t}/package.json`,"devDependencies");if(e!==null){if("vitest"in e)return"vitest";if("jest"in e)return"jest";if("playwright"in e)return"playwright"}return null},le=async t=>{let[e,o,s,d]=await Promise.all([ye(t),Ce(t),ve(t),$e(t)]);return{languages:e,frameworks:o,ci:s,testRunner:d}};var Ge=async t=>{let e=f.process.cwd(),o=oe(t),s=M({target:o==="agent"?"non-interactive":"interactive"}),d=ie(t),y=de(d,"--concerns"),g=de(d,"--tools"),u=d.includes("--non-interactive")||o==="agent";if(await V(e))return r.warn(s,"noskills is already initialized in this project."),r.info(s,`Run \`${S("sync")}\` to regenerate tool files.`),b(void 0);W(s,"noskills init");let D=w(s,"Scanning project...");D.start();let m=await le(e);D.succeed("Project scanned");for(let n of m.languages)r.step(s,` ${n}`);for(let n of m.frameworks)r.step(s,` ${n}`);for(let n of m.ci)r.step(s,` ${n}`);m.testRunner!==null&&r.step(s,` test runner: ${m.testRunner}`),h(s);let j=w(s,"Detecting coding tools...");j.start();let A=await ae(e),C=ne(),L=C!==null&&!A.includes(C)?[C]:[],v=[...new Set([...L,...A])];j.succeed(`${v.length} coding tool(s) detected`);for(let n of v){let i=n===C?" (current)":"";r.step(s,` ${n}${i}`)}let p;if(g!==null){let n=["claude-code","cursor","kiro","copilot","windsurf","opencode","codex","copilot-cli"],i=g.filter(l=>n.includes(l));p=[...new Set([...L,...i])]}else u?p=[...v]:(h(s),p=await be(s,v,C));h(s);let O=w(s,"Detecting AI providers...");O.start();let x=(await re()).filter(n=>n.available).map(n=>n.name);O.succeed(`${x.length} provider(s) detected`),h(s);let T=await P(),c;if(y!==null){let n=T.map(i=>i.id);c=y.filter(i=>n.includes(i)).sort((i,l)=>n.indexOf(i)-n.indexOf(l))}else if(u)c=[];else{let n=T.map(l=>({value:l.id,label:l.name,hint:l.description.slice(0,60)})),i=await I(s,{message:"What kind of project is this? (space to toggle, enter to confirm)",options:n});c=k(i)?[]:[...i]}c.length>0?r.success(s,` Concerns: ${c.join(", ")}`):r.info(s,"No concerns selected. Add later with `concern add <id> [<id2> ...]`."),h(s);let E=w(s,"Initializing...");E.start(),await U(e);let ue=T.filter(n=>c.includes(n.id));for(let n of ue)await K(e,n);let N=await X();Q(N);let $={..._(c,p,x,m),command:N};await B(e,$);let R=H();if(await q(e,R),E.succeed("Scaffolded `.eser/`"),p.length>0){let n=w(s,"Syncing tool files...");n.start();let i=await te(e,p,$);n.succeed(`Synced ${i.length} tool(s)`)}else r.warn(s,"No tools selected. noskills will work in agentless CLI mode only."),r.info(s,"Add tools later with `noskills sync`.");if(z(s,`Done. ${p.length} tool(s), ${x.length} provider(s), ${c.length} concern(s).`),o==="agent"){let i=(await P()).filter(ge=>c.includes(ge.id)),l=await Z(e),pe=ee($?.tools??[]),fe=Y(R,i,l,$,void 0,void 0,void 0,pe);await se(fe,"json")}else J(s),G(s,`Start a spec with: ${S('spec new "..."')}`);return b(void 0)},Te=[{value:"claude-code",label:"Claude Code"},{value:"cursor",label:"Cursor"},{value:"kiro",label:"Kiro"},{value:"copilot",label:"GitHub Copilot"},{value:"windsurf",label:"Windsurf"},{value:"opencode",label:"OpenCode"},{value:"codex",label:"Codex CLI"},{value:"copilot-cli",label:"Copilot CLI"}],be=async(t,e,o)=>{let s=e.length===0?"No coding tools detected. Which tools do you use? (space to toggle)":"Any additional tools? (space to toggle, enter to skip)",d=new Set(e),y=await I(t,{message:s,options:Te.map(u=>({...u,hint:u.value===o?"you're running inside it":d.has(u.value)?"detected":void 0,disabled:u.value===o})),initialValues:[...e],required:!1});if(k(y))return[...e];let g=[...y];return o!==null&&!g.includes(o)&&g.unshift(o),g},de=(t,e)=>{if(t===void 0)return null;for(let o of t)if(o.startsWith(`${e}=`))return o.slice(e.length+1).split(",").map(s=>s.trim()).filter(Boolean);return null};export{Ge as main};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { createRequire } from "node:module"; const require = createRequire(import.meta.url);
|
|
2
|
-
import{b as j}from"./chunk-
|
|
2
|
+
import{b as j}from"./chunk-4X4NHXFE.js";import"./chunk-2XNFZXHY.js";import"./chunk-VV47GXU5.js";import"./chunk-J2Z7NG2X.js";import"./chunk-YTF3BAQS.js";import"./chunk-S7S2I2K5.js";import"./chunk-NBA6EFWU.js";import{f as A,h as P,k as H}from"./chunk-SHN5MT56.js";import"./chunk-7DPLGQHN.js";import{b,c as O,d,f as k,g as w,h as y,i as E}from"./chunk-YVN2NZL4.js";import{a as $}from"./chunk-MG65QJY6.js";import{g as r}from"./chunk-FFWPJP7A.js";import{j as e}from"./chunk-6DBKPC2O.js";import"./chunk-ALFFE37K.js";import"./chunk-6G6UVWJN.js";import"./chunk-5WJ6AUNY.js";var M={precommit:{hookName:"pre-commit",args:""},commitmsg:{hookName:"commit-msg",args:'-- "$1"'},prepush:{hookName:"pre-push",args:""}},C="# @eser managed hook",I=async(i,n)=>{let t=(await e.detectExecutionContext({command:"eser",devCommand:"deno task cli",npmPackage:"eser",jsrPackage:"@eser/cli"})).command,o=n.length>0?` ${n}`:"",a=`${t} workflows run -e ${i}${o}`;return["#!/bin/sh",`${C} \u2014 generated by \`eser codebase install\``,"# Do not edit. Re-run `eser codebase install` to update.","",a,""].join(`
|
|
3
3
|
`)},S=async()=>{try{let t=(await e.runtime.exec.exec("git",["rev-parse","--git-dir"])).trim();if(t.length>0)return t}catch{}let i=e.runtime.process.cwd(),n=e.runtime.path.join(i,".git");try{if((await e.runtime.fs.stat(n)).isDirectory)return n}catch{}return null},G=i=>{let n=i.workflows;if(!Array.isArray(n))return[];let s=new Set;for(let t of n)if(Array.isArray(t.on))for(let o of t.on)typeof o=="string"&&s.add(o);return[...s]},T=H.ansi(),U=async i=>{let n=$(i??[],{boolean:["force","dry-run","help"],alias:{h:"help",f:"force",n:"dry-run"}});if(n.help)return console.log("eser codebase install \u2014 Install git hooks from .eser/manifest.yml"),console.log(""),console.log("Flags:"),console.log(" --force, -f Overwrite non-managed hooks"),console.log(" --dry-run, -n Show what would happen without writing"),console.log(" --help, -h Show this help"),r.ok(void 0);let s=A({renderer:T,sink:P.stdout()}),t=n.force,o=n["dry-run"],a=await S();if(a===null)return s.writeln(k("Error: not inside a git repository")),await s.close(),r.fail({exitCode:1});let p=e.runtime.path.join(a,"hooks"),g=e.runtime.process.cwd(),l=await j(g);if(l===null)return s.writeln(k("Error: no .eser/manifest.yml found in current directory")),await s.close(),r.fail({exitCode:1});let c=G(l);if(c.length===0)return s.writeln(y("No workflow events found \u2014 nothing to install.")),await s.close(),r.ok(void 0);o||await e.runtime.fs.ensureDir(p);let f=0,v=0,u=0;for(let N of c){let F=M[N];if(F===void 0){s.writeln(d(` skip ${N} (unknown event, no hook mapping)`));continue}let{hookName:m,args:K}=F,D=e.runtime.path.join(p,m),_=await I(N,K),R=!1,x=!1;try{let q=await e.runtime.fs.readTextFile(D);R=!0,x=q.includes(C)}catch{}if(o){R?x?s.writeln(E(` would update ${m} (managed)`)):t?s.writeln(y(` would overwrite ${m} (--force)`)):s.writeln(y(` would skip ${m} (user hook; use --force to overwrite)`)):s.writeln(E(` would create ${m}`));continue}if(R&&!x&&!t){s.writeln(y(` skip ${m} \u2014 user hook exists (use --force to overwrite)`)),v++;continue}await e.runtime.fs.writeTextFile(D,_);try{await e.runtime.fs.chmod(D,493)}catch{}R&&x?(s.writeln(w(` updated ${m}`)),u++):(s.writeln(w(` installed ${m}`)),f++)}s.writeln();let h=[];return f>0&&h.push(`${f} installed`),u>0&&h.push(`${u} updated`),v>0&&h.push(`${v} skipped`),o?s.writeln(d("(dry run \u2014 no changes made)")):h.length>0?s.writeln(w(`Done: ${h.join(", ")}.`)):s.writeln(d("Nothing to do.")),await s.close(),r.ok(void 0)},W=async i=>{if($(i??[],{boolean:["help"],alias:{h:"help"}}).help)return console.log("eser codebase uninstall \u2014 Remove managed git hooks"),r.ok(void 0);let s=A({renderer:T,sink:P.stdout()}),t=await S();if(t===null)return s.writeln(k("Error: not inside a git repository")),await s.close(),r.fail({exitCode:1});let o=e.runtime.path.join(t,"hooks"),a=0,p=Object.values(M).map(l=>l.hookName),g=[...new Set(p)];for(let l of g){let c=e.runtime.path.join(o,l);try{(await e.runtime.fs.readTextFile(c)).includes(C)&&(await e.runtime.fs.remove(c),s.writeln(w(` removed ${l}`)),a++)}catch{}}return s.writeln(),a>0?s.writeln(w(`Done: ${a} hook(s) removed.`)):s.writeln(d("No managed hooks found.")),await s.close(),r.ok(void 0)},X=async i=>{if($(i??[],{boolean:["help"],alias:{h:"help"}}).help)return console.log("eser codebase status \u2014 Show git hook installation status"),r.ok(void 0);let s=A({renderer:T,sink:P.stdout()}),t=await S();if(t===null)return s.writeln(k("Error: not inside a git repository")),await s.close(),r.fail({exitCode:1});let o=e.runtime.path.join(t,"hooks"),a=e.runtime.process.cwd(),p=await j(a);if(p===null)return s.writeln(k("Error: no .eser/manifest.yml found in current directory")),await s.close(),r.fail({exitCode:1});let g=G(p);if(g.length===0)return s.writeln(d("No workflow events found in manifest.")),await s.close(),r.ok(void 0);s.writeln(O("Git hook status:")),s.writeln();for(let l of g){let c=M[l];if(c===void 0){s.writeln(b(" "),d(l.padEnd(14)),b(" "),d("(no hook mapping)"));continue}let{hookName:f}=c,v=e.runtime.path.join(o,f),u;try{(await e.runtime.fs.readTextFile(v)).includes(C)?u=w("managed (@eser)"):u=y("user hook")}catch{u=d("not installed")}s.writeln(b(` ${f.padEnd(14)} `),u)}return s.writeln(),await s.close(),r.ok(void 0)};export{U as main,X as statusMain,W as uninstallMain};
|