@easbot/skills 0.3.12 → 0.3.13
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/README.en.md +2 -2
- package/README.md +2 -2
- package/dist/chunks/blob-3PZEQWTP.mjs +1 -0
- package/dist/chunks/blob-ZDEX2HRV.cjs +1 -0
- package/dist/chunks/chunk-4D5RQDWJ.mjs +5 -0
- package/dist/chunks/{chunk-OWG6N2K6.cjs → chunk-5BL3KG26.cjs} +2 -2
- package/dist/chunks/chunk-5W7HC7BY.mjs +22 -0
- package/dist/chunks/chunk-CXH3OTTQ.cjs +22 -0
- package/dist/chunks/{chunk-2VZUPTI7.cjs → chunk-CY6UI6SJ.cjs} +1 -1
- package/dist/chunks/chunk-E7AHWFZN.cjs +2 -0
- package/dist/chunks/chunk-ISMGLHYS.cjs +1 -0
- package/dist/chunks/chunk-K2XGYOXP.mjs +267 -0
- package/dist/chunks/chunk-ML6B4IQL.mjs +1 -0
- package/dist/chunks/{chunk-4R6NKPNW.mjs → chunk-NKIQLESR.mjs} +2 -2
- package/dist/chunks/chunk-ROCFLAYZ.mjs +2 -0
- package/dist/chunks/chunk-RVR3DSD2.cjs +2 -0
- package/dist/chunks/{chunk-RWSBKHQ2.cjs → chunk-SXUY2J75.cjs} +2 -2
- package/dist/chunks/chunk-UJWB7QQ6.cjs +267 -0
- package/dist/chunks/chunk-ZBKGF7PA.mjs +1 -0
- package/dist/chunks/chunk-ZYDDQV73.mjs +2 -0
- package/dist/chunks/cli-handler-667TYY4I.cjs +1 -0
- package/dist/chunks/cli-handler-YSDUNKKZ.mjs +1 -0
- package/dist/chunks/{installer-FB26E7JZ.mjs → installer-REG45DC2.mjs} +1 -1
- package/dist/chunks/installer-SOVGUW3M.cjs +1 -0
- package/dist/chunks/local-lock-AWD3LLEY.mjs +1 -0
- package/dist/chunks/local-lock-GIZDVF3X.cjs +1 -0
- package/dist/chunks/scan-57D2H7LP.cjs +1 -0
- package/dist/chunks/scan-WAXGJM5N.mjs +1 -0
- package/dist/chunks/{skill-lock-KHPVP7AD.mjs → skill-lock-DZMA75MY.mjs} +1 -1
- package/dist/chunks/skill-lock-XTWQYBRG.cjs +1 -0
- package/dist/chunks/store-F7PGGZIO.cjs +1 -0
- package/dist/chunks/store-IVDLGLET.mjs +1 -0
- package/dist/cli.cjs +1 -1
- package/dist/cli.mjs +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +51 -7
- package/dist/index.d.ts +51 -7
- package/dist/index.mjs +1 -1
- package/package.json +4 -5
- package/dist/chunks/blob-DOVEGVIE.cjs +0 -1
- package/dist/chunks/blob-JSMTOYEN.mjs +0 -1
- package/dist/chunks/chunk-2YVJ7YP6.mjs +0 -22
- package/dist/chunks/chunk-676OG55M.mjs +0 -5
- package/dist/chunks/chunk-6PJ3YQA7.mjs +0 -2
- package/dist/chunks/chunk-72DXY4B7.mjs +0 -1
- package/dist/chunks/chunk-GR2NJUJ6.mjs +0 -255
- package/dist/chunks/chunk-JFEBB5CL.cjs +0 -22
- package/dist/chunks/chunk-KV7EP6AW.cjs +0 -255
- package/dist/chunks/chunk-TCFGU43L.cjs +0 -2
- package/dist/chunks/cli-handler-RAJ42VDN.mjs +0 -1
- package/dist/chunks/cli-handler-YAJ5J5VA.cjs +0 -1
- package/dist/chunks/installer-GOQTCUJ4.cjs +0 -1
- package/dist/chunks/local-lock-4AA55ORE.cjs +0 -1
- package/dist/chunks/local-lock-LG5YL33V.mjs +0 -1
- package/dist/chunks/scan-QEVID2TF.mjs +0 -1
- package/dist/chunks/scan-XWU3FCE3.cjs +0 -1
- package/dist/chunks/skill-lock-LET33FVT.cjs +0 -1
- package/dist/chunks/store-3NRBE47N.mjs +0 -1
- package/dist/chunks/store-EHYH46YY.cjs +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import {g}from'./chunk-4D5RQDWJ.mjs';import {y}from'./chunk-5W7HC7BY.mjs';import {r,s,b}from'./chunk-ML6B4IQL.mjs';import {Glob}from'@easbot/utils';import {stat,realpath}from'fs/promises';import {dirname,join}from'path';async function v(i={}){let o=i.cwd??process.cwd(),e=i.scope??"project",r$1=r({cwd:o,agentFilter:i.agentFilter}),s$1;if(e==="project"?s$1=r$1.project:e==="global"?s$1=r$1.global:s$1=r$1.all,s$1.length===0)return [];let a=new Set,c=[],T=await Promise.all(s$1.map(n=>Glob.scan(n,{cwd:o,absolute:true,ignore:Glob.DEFAULT_IGNORE_PATTERNS,follow:true})));for(let n of T)for(let l of n)a.has(l)||(a.add(l),c.push(l));let $=Object.keys(b),G="/",m=[],F=o.replace(/\\/g,"/"),M=s();for(let n of c){let l=dirname(n),g$1=l.replace(/\\/g,"/"),p=g$1.split(G),B=p.length>=3?`${p[p.length-3]??""}/${p[p.length-2]??""}`:"",d=await y(n);if(!d)continue;let E=g$1.startsWith(`${F}/`),I=M.some(t=>t!==""&&g$1.startsWith(`${t}/`)),f=E&&!I?"project":"global",k=[],R=e==="both"?f==="project":e==="project",C=e==="both"?f==="global":e==="global",b$1=t=>t.replace(/\\/g,"/"),L=b$1(l).replace(/\/[^/]+\/?$/,"");for(let t of $){let P=b[t],S=[];R&&P.skillsDir!==void 0&&S.push(g(t,false,o)),C&&P.globalSkillsDir!==void 0&&S.push(g(t,true,o));for(let w of S)if(b$1(w).replace(/\/+$/,"")===L)try{let D=join(w,d.name);if(!(await stat(D)).isDirectory())continue;await realpath(D),k.includes(t)||k.push(t);break}catch{}}m.push({name:d.name,skillDir:l,skillMdPath:n,parentDir:B,scope:f,agents:k});}return m}async function Z(i={}){let o=await v(i),e=new Set,r=[];for(let s of o){let a=`${s.scope}:${s.name}`;if(e.has(a))continue;e.add(a);let c=await y(s.skillMdPath);c&&r.push(c);}return r}export{v as a,Z as b};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import {parse}from'yaml';import {createHash}from'crypto';import {readdir,readFile}from'fs/promises';import {join,relative,sep}from'path';function S(s){let r=s.match(/^---\r?\n([\s\S]*?)\r?\n---\r?\n?([\s\S]*)$/);return r?{data:parse(r[1])??{},content:r[2]??""}:{data:{},content:s}}var R=new Set([".git","node_modules"]);async function c(s,r,e){let n=await readdir(r,{withFileTypes:true});await Promise.all(n.map(async t=>{let o=join(r,t.name);if(t.isDirectory()){if(R.has(t.name))return;await c(s,o,e);}else if(t.isFile()){let h=await readFile(o),f=relative(s,o).split(sep).join("/");e.push({path:f,contents:h});}}));}function p(s){let r=[...s].sort((n,t)=>n.path.localeCompare(t.path)),e=createHash("sha256");for(let n of r){let t=n.path.split(sep).join("/");e.update(t);let o=typeof n.contents=="string"?Buffer.from(n.contents,"utf8"):n.contents;e.update(o);}return e.digest("hex")}async function B(s){let r=[];return await c(s,s,r),p(r)}function j(s){return p(s)}function M(s){let r=[];if(s instanceof Map)for(let[n,t]of s)typeof t=="string"&&t.length>0&&r.push([n,t]);else for(let n of s){let t=n?.snapshotHash,o=n?.name;t&&t.length>0&&o&&r.push([o,t]);}r.sort((n,t)=>n[0].localeCompare(t[0]));let e=createHash("sha256");for(let[n,t]of r)e.update(`${n}=${t}
|
|
2
|
+
`);return e.digest("hex")}export{S as a,B as b,j as c,M as d};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
'use strict';var chunkUJWB7QQ6_cjs=require('./chunk-UJWB7QQ6.cjs');require('./chunk-S6YNGR7S.cjs'),require('./chunk-SXUY2J75.cjs'),require('./chunk-CY6UI6SJ.cjs'),require('./chunk-5BL3KG26.cjs'),require('./chunk-CXH3OTTQ.cjs'),require('./chunk-ISMGLHYS.cjs'),require('./chunk-XGUPIAAF.cjs'),require('./chunk-RVR3DSD2.cjs'),require('./chunk-E7AHWFZN.cjs'),require('./chunk-VRHWDHQV.cjs');Object.defineProperty(exports,"handleSkillsCli",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.M}});Object.defineProperty(exports,"renderBanner",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.K}});Object.defineProperty(exports,"renderHelp",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.L}});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{M as handleSkillsCli,K as renderBanner,L as renderHelp}from'./chunk-K2XGYOXP.mjs';import'./chunk-CFMOYU7R.mjs';import'./chunk-NKIQLESR.mjs';import'./chunk-ZBKGF7PA.mjs';import'./chunk-4D5RQDWJ.mjs';import'./chunk-5W7HC7BY.mjs';import'./chunk-ML6B4IQL.mjs';import'./chunk-RWZ4LFSN.mjs';import'./chunk-ROCFLAYZ.mjs';import'./chunk-ZYDDQV73.mjs';import'./chunk-WQGSYA5D.mjs';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{j as copySkillDir,n as ensureCanonicalFromFiles,g as getAgentBaseDir,o as getCanonicalPath,e as getCanonicalSkillsDir,f as getEveSubagentSkillsDir,m as getInstallPath,l as getInstallStatus,r as installBlobSkillForAgent,p as installRemoteSkillForAgent,h as installSkillForAgent,q as installWellKnownSkillForAgent,k as isSkillInstalled,i as linkSkillDir,s as listInstalledSkills,d as sanitizeName}from'./chunk-
|
|
1
|
+
export{j as copySkillDir,n as ensureCanonicalFromFiles,g as getAgentBaseDir,o as getCanonicalPath,e as getCanonicalSkillsDir,f as getEveSubagentSkillsDir,m as getInstallPath,l as getInstallStatus,r as installBlobSkillForAgent,p as installRemoteSkillForAgent,h as installSkillForAgent,q as installWellKnownSkillForAgent,k as isSkillInstalled,i as linkSkillDir,s as listInstalledSkills,d as sanitizeName}from'./chunk-4D5RQDWJ.mjs';import'./chunk-ML6B4IQL.mjs';import'./chunk-RWZ4LFSN.mjs';import'./chunk-ZYDDQV73.mjs';import'./chunk-WQGSYA5D.mjs';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
'use strict';var chunk5BL3KG26_cjs=require('./chunk-5BL3KG26.cjs');require('./chunk-ISMGLHYS.cjs'),require('./chunk-XGUPIAAF.cjs'),require('./chunk-E7AHWFZN.cjs'),require('./chunk-VRHWDHQV.cjs');Object.defineProperty(exports,"copySkillDir",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.j}});Object.defineProperty(exports,"ensureCanonicalFromFiles",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.n}});Object.defineProperty(exports,"getAgentBaseDir",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.g}});Object.defineProperty(exports,"getCanonicalPath",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.o}});Object.defineProperty(exports,"getCanonicalSkillsDir",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.e}});Object.defineProperty(exports,"getEveSubagentSkillsDir",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.f}});Object.defineProperty(exports,"getInstallPath",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.m}});Object.defineProperty(exports,"getInstallStatus",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.l}});Object.defineProperty(exports,"installBlobSkillForAgent",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.r}});Object.defineProperty(exports,"installRemoteSkillForAgent",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.p}});Object.defineProperty(exports,"installSkillForAgent",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.h}});Object.defineProperty(exports,"installWellKnownSkillForAgent",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.q}});Object.defineProperty(exports,"isSkillInstalled",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.k}});Object.defineProperty(exports,"linkSkillDir",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.i}});Object.defineProperty(exports,"listInstalledSkills",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.s}});Object.defineProperty(exports,"sanitizeName",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.d}});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{q as CURRENT_VERSION,v as addSkillToLocalLock,r as getLocalLockPath,t as readLocalLock,w as removeSkillFromLocalLock,s as storePathFromLocalLockEntry,u as writeLocalLock}from'./chunk-5W7HC7BY.mjs';import'./chunk-ML6B4IQL.mjs';import'./chunk-RWZ4LFSN.mjs';import'./chunk-ROCFLAYZ.mjs';import'./chunk-ZYDDQV73.mjs';import'./chunk-WQGSYA5D.mjs';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
'use strict';var chunkCXH3OTTQ_cjs=require('./chunk-CXH3OTTQ.cjs');require('./chunk-ISMGLHYS.cjs'),require('./chunk-XGUPIAAF.cjs'),require('./chunk-RVR3DSD2.cjs'),require('./chunk-E7AHWFZN.cjs'),require('./chunk-VRHWDHQV.cjs');Object.defineProperty(exports,"CURRENT_VERSION",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.q}});Object.defineProperty(exports,"addSkillToLocalLock",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.v}});Object.defineProperty(exports,"getLocalLockPath",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.r}});Object.defineProperty(exports,"readLocalLock",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.t}});Object.defineProperty(exports,"removeSkillFromLocalLock",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.w}});Object.defineProperty(exports,"storePathFromLocalLockEntry",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.s}});Object.defineProperty(exports,"writeLocalLock",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.u}});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
'use strict';var chunkCY6UI6SJ_cjs=require('./chunk-CY6UI6SJ.cjs');require('./chunk-5BL3KG26.cjs'),require('./chunk-CXH3OTTQ.cjs'),require('./chunk-ISMGLHYS.cjs'),require('./chunk-XGUPIAAF.cjs'),require('./chunk-RVR3DSD2.cjs'),require('./chunk-E7AHWFZN.cjs'),require('./chunk-VRHWDHQV.cjs');Object.defineProperty(exports,"scanInstalledSkillDirs",{enumerable:true,get:function(){return chunkCY6UI6SJ_cjs.a}});Object.defineProperty(exports,"scanInstalledSkills",{enumerable:true,get:function(){return chunkCY6UI6SJ_cjs.b}});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{a as scanInstalledSkillDirs,b as scanInstalledSkills}from'./chunk-ZBKGF7PA.mjs';import'./chunk-4D5RQDWJ.mjs';import'./chunk-5W7HC7BY.mjs';import'./chunk-ML6B4IQL.mjs';import'./chunk-RWZ4LFSN.mjs';import'./chunk-ROCFLAYZ.mjs';import'./chunk-ZYDDQV73.mjs';import'./chunk-WQGSYA5D.mjs';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{a as CURRENT_VERSION,i as addSkillToLock,e as computeContentHash,p as dismissPrompt,h as fetchSkillFolderHash,l as getAllLockedSkills,g as getGitHubToken,k as getSkillFromLock,b as getSkillLockPath,m as getSkillsBySource,n as isPromptDismissed,c as readSkillLock,j as removeSkillFromLock,f as resetGhAuthWarning,o as storePathFromLockEntry,d as writeSkillLock}from'./chunk-
|
|
1
|
+
export{a as CURRENT_VERSION,i as addSkillToLock,e as computeContentHash,p as dismissPrompt,h as fetchSkillFolderHash,l as getAllLockedSkills,g as getGitHubToken,k as getSkillFromLock,b as getSkillLockPath,m as getSkillsBySource,n as isPromptDismissed,c as readSkillLock,j as removeSkillFromLock,f as resetGhAuthWarning,o as storePathFromLockEntry,d as writeSkillLock}from'./chunk-NKIQLESR.mjs';import'./chunk-5W7HC7BY.mjs';import'./chunk-ML6B4IQL.mjs';import'./chunk-RWZ4LFSN.mjs';import'./chunk-ROCFLAYZ.mjs';import'./chunk-ZYDDQV73.mjs';import'./chunk-WQGSYA5D.mjs';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
'use strict';var chunkSXUY2J75_cjs=require('./chunk-SXUY2J75.cjs');require('./chunk-CXH3OTTQ.cjs'),require('./chunk-ISMGLHYS.cjs'),require('./chunk-XGUPIAAF.cjs'),require('./chunk-RVR3DSD2.cjs'),require('./chunk-E7AHWFZN.cjs'),require('./chunk-VRHWDHQV.cjs');Object.defineProperty(exports,"CURRENT_VERSION",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.a}});Object.defineProperty(exports,"addSkillToLock",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.i}});Object.defineProperty(exports,"computeContentHash",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.e}});Object.defineProperty(exports,"dismissPrompt",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.p}});Object.defineProperty(exports,"fetchSkillFolderHash",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.h}});Object.defineProperty(exports,"getAllLockedSkills",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.l}});Object.defineProperty(exports,"getGitHubToken",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.g}});Object.defineProperty(exports,"getSkillFromLock",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.k}});Object.defineProperty(exports,"getSkillLockPath",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.b}});Object.defineProperty(exports,"getSkillsBySource",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.m}});Object.defineProperty(exports,"isPromptDismissed",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.n}});Object.defineProperty(exports,"readSkillLock",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.c}});Object.defineProperty(exports,"removeSkillFromLock",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.j}});Object.defineProperty(exports,"resetGhAuthWarning",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.f}});Object.defineProperty(exports,"storePathFromLockEntry",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.o}});Object.defineProperty(exports,"writeSkillLock",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.d}});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
'use strict';var chunkCXH3OTTQ_cjs=require('./chunk-CXH3OTTQ.cjs');require('./chunk-ISMGLHYS.cjs'),require('./chunk-XGUPIAAF.cjs'),require('./chunk-RVR3DSD2.cjs'),require('./chunk-E7AHWFZN.cjs'),require('./chunk-VRHWDHQV.cjs');Object.defineProperty(exports,"DEFAULT_SKILL_SOURCE",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.F}});Object.defineProperty(exports,"LocalPathNotFoundError",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.R}});Object.defineProperty(exports,"STORE_INDEX_VERSION",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.o}});Object.defineProperty(exports,"acquireSourceClone",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.Q}});Object.defineProperty(exports,"cleanCache",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.ja}});Object.defineProperty(exports,"cleanCachedRepo",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.ia}});Object.defineProperty(exports,"derivePluginSlug",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.O}});Object.defineProperty(exports,"deriveSourceKey",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.L}});Object.defineProperty(exports,"ensureCachedSource",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.ca}});Object.defineProperty(exports,"findSkillByLocation",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.Y}});Object.defineProperty(exports,"findSkillByName",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.X}});Object.defineProperty(exports,"getCacheRepoDir",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.P}});Object.defineProperty(exports,"getCacheRoot",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.N}});Object.defineProperty(exports,"getSourceDir",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.I}});Object.defineProperty(exports,"getStoreDefinitionsFile",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.K}});Object.defineProperty(exports,"getStoreDir",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.M}});Object.defineProperty(exports,"getStoreRoot",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.J}});Object.defineProperty(exports,"installFromCache",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.ha}});Object.defineProperty(exports,"isCachePath",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.ga}});Object.defineProperty(exports,"isDirNonEmpty",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.fa}});Object.defineProperty(exports,"listAllSkills",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.W}});Object.defineProperty(exports,"listSourceSkills",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.da}});Object.defineProperty(exports,"parseDefaultPluginConfig",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.H}});Object.defineProperty(exports,"readStoreDefinitions",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.U}});Object.defineProperty(exports,"readStoreIndex",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.S}});Object.defineProperty(exports,"removeSkillFromAllPlugins",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs._}});Object.defineProperty(exports,"removeSkillFromPlugin",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.Z}});Object.defineProperty(exports,"removeStoreDefinition",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.ba}});Object.defineProperty(exports,"resolveDefaultSource",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.G}});Object.defineProperty(exports,"toPosixRelative",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.ea}});Object.defineProperty(exports,"writeSkillToPlugin",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.V}});Object.defineProperty(exports,"writeStoreDefinition",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.$}});Object.defineProperty(exports,"writeStoreDefinitionsBatch",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.aa}});Object.defineProperty(exports,"writeStoreIndex",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.T}});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{F as DEFAULT_SKILL_SOURCE,R as LocalPathNotFoundError,o as STORE_INDEX_VERSION,Q as acquireSourceClone,ja as cleanCache,ia as cleanCachedRepo,O as derivePluginSlug,L as deriveSourceKey,ca as ensureCachedSource,Y as findSkillByLocation,X as findSkillByName,P as getCacheRepoDir,N as getCacheRoot,I as getSourceDir,K as getStoreDefinitionsFile,M as getStoreDir,J as getStoreRoot,ha as installFromCache,ga as isCachePath,fa as isDirNonEmpty,W as listAllSkills,da as listSourceSkills,H as parseDefaultPluginConfig,U as readStoreDefinitions,S as readStoreIndex,_ as removeSkillFromAllPlugins,Z as removeSkillFromPlugin,ba as removeStoreDefinition,G as resolveDefaultSource,ea as toPosixRelative,V as writeSkillToPlugin,$ as writeStoreDefinition,aa as writeStoreDefinitionsBatch,T as writeStoreIndex}from'./chunk-5W7HC7BY.mjs';import'./chunk-ML6B4IQL.mjs';import'./chunk-RWZ4LFSN.mjs';import'./chunk-ROCFLAYZ.mjs';import'./chunk-ZYDDQV73.mjs';import'./chunk-WQGSYA5D.mjs';
|
package/dist/cli.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
'use strict';var chunkVRHWDHQV_cjs=require('./chunks/chunk-VRHWDHQV.cjs'),fs=require('fs'),path=require('path'),url=require('url');var h=path.dirname(url.fileURLToPath(chunkVRHWDHQV_cjs.c));function b(){try{let e=path.join(h,"..","package.json");return JSON.parse(fs.readFileSync(e,"utf-8")).version}catch{return "0.0.0"}}var c=new Set(["DEBUG","INFO","WARN","ERROR"]);function O(e){let t={logLevel:"INFO",printLogs:false,debug:false};for(let n=0;n<e.length;n++){let o=e[n];if(o)if(o==="--log-level"&&n+1<e.length){let s=e[n+1];if(s&&!s.startsWith("-")){let i=s.toUpperCase();c.has(i)&&(t.logLevel=i,n++);}}else if(o.startsWith("--log-level=")){let s=o.slice(12).toUpperCase();c.has(s)&&(t.logLevel=s);}else o==="--print-logs"?t.printLogs=true:o==="--debug"&&(t.debug=true);}return t}async function w(){let e=process.argv.slice(2),t=b(),{loadEnv:n}=await import('@easbot/utils');if(n(),process.env.EASBOT_LANG||(process.env.EASBOT_LANG="en-US"),e.length===0){let{renderBanner:l}=await import('./chunks/cli-handler-
|
|
2
|
+
'use strict';var chunkVRHWDHQV_cjs=require('./chunks/chunk-VRHWDHQV.cjs'),fs=require('fs'),path=require('path'),url=require('url');var h=path.dirname(url.fileURLToPath(chunkVRHWDHQV_cjs.c));function b(){try{let e=path.join(h,"..","package.json");return JSON.parse(fs.readFileSync(e,"utf-8")).version}catch{return "0.0.0"}}var c=new Set(["DEBUG","INFO","WARN","ERROR"]);function O(e){let t={logLevel:"INFO",printLogs:false,debug:false};for(let n=0;n<e.length;n++){let o=e[n];if(o)if(o==="--log-level"&&n+1<e.length){let s=e[n+1];if(s&&!s.startsWith("-")){let i=s.toUpperCase();c.has(i)&&(t.logLevel=i,n++);}}else if(o.startsWith("--log-level=")){let s=o.slice(12).toUpperCase();c.has(s)&&(t.logLevel=s);}else o==="--print-logs"?t.printLogs=true:o==="--debug"&&(t.debug=true);}return t}async function w(){let e=process.argv.slice(2),t=b(),{loadEnv:n}=await import('@easbot/utils');if(n(),process.env.EASBOT_LANG||(process.env.EASBOT_LANG="en-US"),e.length===0){let{renderBanner:l}=await import('./chunks/cli-handler-667TYY4I.cjs');l();return}if(e[0]==="--help"||e[0]==="-h"){let{renderHelp:l}=await import('./chunks/cli-handler-667TYY4I.cjs');l();return}if(e[0]==="--version"||e[0]==="-v"){console.log(t);return}let o=O(e),{Log:s}=await import('@easbot/utils'),{getXdgData:i,setGlobalAdapter:g,resetGlobalAdapter:d}=await import('./chunks/interfaces-UIS44Q7A.cjs'),f=path.join(i(),"log");await s.init({logDir:f,print:o.printLogs,dev:o.debug||false,level:o.logLevel});let{handleSkillsCli:L}=await import('./chunks/cli-handler-667TYY4I.cjs'),r=await L(e,{version:t});r.code!==0&&(process.exitCode=r.code);}w().catch(e=>{console.error(e),process.exitCode=1;}).finally(async()=>{try{let{flushTelemetry:e}=await import('./chunks/telemetry-LCGTSJDM.cjs');await e();}catch{}try{let{Log:e}=await import('@easbot/utils');await e.close();}catch{}process.exit(process.exitCode??0);});
|
package/dist/cli.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import {readFileSync}from'fs';import {dirname,join}from'path';import {fileURLToPath}from'url';var m=dirname(fileURLToPath(import.meta.url));function h(){try{let e=join(m,"..","package.json");return JSON.parse(readFileSync(e,"utf-8")).version}catch{return "0.0.0"}}var a=new Set(["DEBUG","INFO","WARN","ERROR"]);function b(e){let t={logLevel:"INFO",printLogs:false,debug:false};for(let n=0;n<e.length;n++){let o=e[n];if(o)if(o==="--log-level"&&n+1<e.length){let s=e[n+1];if(s&&!s.startsWith("-")){let i=s.toUpperCase();a.has(i)&&(t.logLevel=i,n++);}}else if(o.startsWith("--log-level=")){let s=o.slice(12).toUpperCase();a.has(s)&&(t.logLevel=s);}else o==="--print-logs"?t.printLogs=true:o==="--debug"&&(t.debug=true);}return t}async function O(){let e=process.argv.slice(2),t=h(),{loadEnv:n}=await import('@easbot/utils');if(n(),process.env.EASBOT_LANG||(process.env.EASBOT_LANG="en-US"),e.length===0){let{renderBanner:l}=await import('./chunks/cli-handler-
|
|
2
|
+
import {readFileSync}from'fs';import {dirname,join}from'path';import {fileURLToPath}from'url';var m=dirname(fileURLToPath(import.meta.url));function h(){try{let e=join(m,"..","package.json");return JSON.parse(readFileSync(e,"utf-8")).version}catch{return "0.0.0"}}var a=new Set(["DEBUG","INFO","WARN","ERROR"]);function b(e){let t={logLevel:"INFO",printLogs:false,debug:false};for(let n=0;n<e.length;n++){let o=e[n];if(o)if(o==="--log-level"&&n+1<e.length){let s=e[n+1];if(s&&!s.startsWith("-")){let i=s.toUpperCase();a.has(i)&&(t.logLevel=i,n++);}}else if(o.startsWith("--log-level=")){let s=o.slice(12).toUpperCase();a.has(s)&&(t.logLevel=s);}else o==="--print-logs"?t.printLogs=true:o==="--debug"&&(t.debug=true);}return t}async function O(){let e=process.argv.slice(2),t=h(),{loadEnv:n}=await import('@easbot/utils');if(n(),process.env.EASBOT_LANG||(process.env.EASBOT_LANG="en-US"),e.length===0){let{renderBanner:l}=await import('./chunks/cli-handler-YSDUNKKZ.mjs');l();return}if(e[0]==="--help"||e[0]==="-h"){let{renderHelp:l}=await import('./chunks/cli-handler-YSDUNKKZ.mjs');l();return}if(e[0]==="--version"||e[0]==="-v"){console.log(t);return}let o=b(e),{Log:s}=await import('@easbot/utils'),{getXdgData:i,setGlobalAdapter:p,resetGlobalAdapter:g}=await import('./chunks/interfaces-S47ZGORM.mjs'),d=join(i(),"log");await s.init({logDir:d,print:o.printLogs,dev:o.debug||false,level:o.logLevel});let{handleSkillsCli:f}=await import('./chunks/cli-handler-YSDUNKKZ.mjs'),r=await f(e,{version:t});r.code!==0&&(process.exitCode=r.code);}O().catch(e=>{console.error(e),process.exitCode=1;}).finally(async()=>{try{let{flushTelemetry:e}=await import('./chunks/telemetry-7T6MUW5A.mjs');await e();}catch{}try{let{Log:e}=await import('@easbot/utils');await e.close();}catch{}process.exit(process.exitCode??0);});
|
package/dist/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';var chunkKV7EP6AW_cjs=require('./chunks/chunk-KV7EP6AW.cjs'),chunkS6YNGR7S_cjs=require('./chunks/chunk-S6YNGR7S.cjs'),chunkRWSBKHQ2_cjs=require('./chunks/chunk-RWSBKHQ2.cjs');require('./chunks/chunk-2VZUPTI7.cjs');var chunkOWG6N2K6_cjs=require('./chunks/chunk-OWG6N2K6.cjs'),chunkJFEBB5CL_cjs=require('./chunks/chunk-JFEBB5CL.cjs'),chunkTCFGU43L_cjs=require('./chunks/chunk-TCFGU43L.cjs'),chunkXGUPIAAF_cjs=require('./chunks/chunk-XGUPIAAF.cjs'),chunkVRHWDHQV_cjs=require('./chunks/chunk-VRHWDHQV.cjs'),path=require('path');var g=class{constructor(){chunkVRHWDHQV_cjs.b(this,"providers",[]);}register(o){if(this.providers.some(t=>t.id===o.id))throw new Error(`Provider with id "${o.id}" already registered`);this.providers.push(o);}findProvider(o){for(let t of this.providers)if(t.match(o).matches)return t;return null}getProviders(){return [...this.providers]}},u=new g;function st(e){u.register(e);}function at(e){return u.findProvider(e)}function ct(){return u.getProviders()}var c=new Map;function f(e){if(c.has(e.id))throw new Error(`PluginSource with id "${e.id}" already registered`);c.set(e.id,e);}function d(){return Array.from(c.values()).map(e=>e)}function k(e){return c.get(e)??null}function P(e){return Array.from(c.values()).filter(o=>o.category===e)}async function y(){let e=d();return await Promise.all(e.map(async t=>{try{let r=await t.fetch();return {sourceId:t.id,entries:r}}catch(r){return {sourceId:t.id,error:r instanceof Error?r:new Error(String(r))}}}))}function ut(e){return {name:e.name,description:e.description,scope:"all"}}function x(e){return {id:e.id??`well-known:${new URL(e.url).hostname}`,category:"well-known",async fetch(){return (await chunkJFEBB5CL_cjs.n.fetchAllSkills(e.url)).map(r=>({id:r.name,name:r.name,description:r.description,location:r.sourceUrl,category:"well-known",metadata:{installName:r.installName,sourceIdentifier:chunkJFEBB5CL_cjs.n.getSourceIdentifier(e.url),sourceUrl:r.sourceUrl}}))},async load(t){let l=(await chunkJFEBB5CL_cjs.n.fetchAllSkills(e.url)).find(n=>n.name===t.id);if(!l)throw new Error(`Skill "${t.id}" not found in well-known source ${e.url}`);return {skills:[ut(l)],version:"well-known",author:{name:new URL(e.url).hostname}}}}}async function h(e){try{let t=await(await import('fs/promises')).readFile(e,"utf-8");return JSON.parse(t)}catch{return null}}function A(e){let o=e.basePath.split(/[\\/]/).filter(Boolean).pop()??"local";return {id:e.id??`local:${o}`,category:"file",async fetch(){let r=[],l=await h(path.join(e.basePath,".claude-plugin/plugin.json"));l?.name&&r.push({id:l.name,name:l.name,description:l.description,location:e.basePath,category:"file",metadata:{skills:l.skills,manifest:"plugin.json"}});let n=await h(path.join(e.basePath,".claude-plugin/marketplace.json"));if(n?.plugins)for(let i of n.plugins)i.name&&(typeof i.source!="string"&&i.source!==void 0||r.push({id:i.name,name:i.name,description:i.description,location:i.source?path.join(e.basePath,n.metadata?.pluginRoot??"",i.source):e.basePath,category:"file",metadata:{skills:i.skills,manifest:"marketplace.json",pluginRoot:n.metadata?.pluginRoot}}));return r},async load(r){return {skills:(await chunkJFEBB5CL_cjs.B(r.location)).map(i=>({name:i.name,description:i.description,scope:"all"})),version:"local",author:{name:o}}}}}Object.defineProperty(exports,"applyActions",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.c}});Object.defineProperty(exports,"buildMatrix",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.d}});Object.defineProperty(exports,"buildUsePrompt",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.G}});Object.defineProperty(exports,"detectAgent",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.f}});Object.defineProperty(exports,"getAgentName",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.h}});Object.defineProperty(exports,"getAgentType",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.i}});Object.defineProperty(exports,"handleSkillsCli",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.M}});Object.defineProperty(exports,"hasProjectSkills",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.k}});Object.defineProperty(exports,"initTelemetry",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.o}});Object.defineProperty(exports,"isRunningInAgent",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.g}});Object.defineProperty(exports,"launchAgentInteractively",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.J}});Object.defineProperty(exports,"matchesSkillFilter",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.m}});Object.defineProperty(exports,"materializeUseSkill",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.H}});Object.defineProperty(exports,"parseAddOptions",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.q}});Object.defineProperty(exports,"parseFindOptions",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.x}});Object.defineProperty(exports,"parseListOptions",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.A}});Object.defineProperty(exports,"parseRemoveOptions",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.D}});Object.defineProperty(exports,"parseStoreOptions",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.r}});Object.defineProperty(exports,"parseUpdateOptions",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.j}});Object.defineProperty(exports,"parseUseOptions",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.F}});Object.defineProperty(exports,"planActions",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.b}});Object.defineProperty(exports,"probeCell",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.a}});Object.defineProperty(exports,"removeCommand",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.C}});Object.defineProperty(exports,"renderBanner",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.K}});Object.defineProperty(exports,"renderHelp",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.L}});Object.defineProperty(exports,"resolveUpdateScope",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.l}});Object.defineProperty(exports,"runAdd",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.p}});Object.defineProperty(exports,"runDoctor",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.E}});Object.defineProperty(exports,"runFind",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.z}});Object.defineProperty(exports,"runList",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.B}});Object.defineProperty(exports,"runPostInstallReconcile",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.e}});Object.defineProperty(exports,"runStore",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.s}});Object.defineProperty(exports,"runStoreClean",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.u}});Object.defineProperty(exports,"runStoreList",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.t}});Object.defineProperty(exports,"runStoreRemove",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.w}});Object.defineProperty(exports,"runStoreUpdate",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.v}});Object.defineProperty(exports,"runUpdate",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.n}});Object.defineProperty(exports,"runUse",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.I}});Object.defineProperty(exports,"searchSkillsAPI",{enumerable:true,get:function(){return chunkKV7EP6AW_cjs.y}});Object.defineProperty(exports,"fetchAuditData",{enumerable:true,get:function(){return chunkS6YNGR7S_cjs.c}});Object.defineProperty(exports,"flushTelemetry",{enumerable:true,get:function(){return chunkS6YNGR7S_cjs.e}});Object.defineProperty(exports,"setDetectedAgent",{enumerable:true,get:function(){return chunkS6YNGR7S_cjs.a}});Object.defineProperty(exports,"setVersion",{enumerable:true,get:function(){return chunkS6YNGR7S_cjs.b}});Object.defineProperty(exports,"track",{enumerable:true,get:function(){return chunkS6YNGR7S_cjs.d}});Object.defineProperty(exports,"addSkillToLock",{enumerable:true,get:function(){return chunkRWSBKHQ2_cjs.i}});Object.defineProperty(exports,"computeContentHash",{enumerable:true,get:function(){return chunkRWSBKHQ2_cjs.e}});Object.defineProperty(exports,"dismissPrompt",{enumerable:true,get:function(){return chunkRWSBKHQ2_cjs.p}});Object.defineProperty(exports,"fetchSkillFolderHash",{enumerable:true,get:function(){return chunkRWSBKHQ2_cjs.h}});Object.defineProperty(exports,"getAllLockedSkills",{enumerable:true,get:function(){return chunkRWSBKHQ2_cjs.l}});Object.defineProperty(exports,"getGitHubToken",{enumerable:true,get:function(){return chunkRWSBKHQ2_cjs.g}});Object.defineProperty(exports,"getSkillFromLock",{enumerable:true,get:function(){return chunkRWSBKHQ2_cjs.k}});Object.defineProperty(exports,"getSkillLockPath",{enumerable:true,get:function(){return chunkRWSBKHQ2_cjs.b}});Object.defineProperty(exports,"getSkillsBySource",{enumerable:true,get:function(){return chunkRWSBKHQ2_cjs.m}});Object.defineProperty(exports,"isPromptDismissed",{enumerable:true,get:function(){return chunkRWSBKHQ2_cjs.n}});Object.defineProperty(exports,"readSkillLock",{enumerable:true,get:function(){return chunkRWSBKHQ2_cjs.c}});Object.defineProperty(exports,"removeSkillFromLock",{enumerable:true,get:function(){return chunkRWSBKHQ2_cjs.j}});Object.defineProperty(exports,"resetGhAuthWarning",{enumerable:true,get:function(){return chunkRWSBKHQ2_cjs.f}});Object.defineProperty(exports,"writeSkillLock",{enumerable:true,get:function(){return chunkRWSBKHQ2_cjs.d}});Object.defineProperty(exports,"AGENTS_DIR",{enumerable:true,get:function(){return chunkOWG6N2K6_cjs.a}});Object.defineProperty(exports,"SKILLS_SUBDIR",{enumerable:true,get:function(){return chunkOWG6N2K6_cjs.b}});Object.defineProperty(exports,"UNIVERSAL_SKILLS_DIR",{enumerable:true,get:function(){return chunkOWG6N2K6_cjs.c}});Object.defineProperty(exports,"getAgentBaseDir",{enumerable:true,get:function(){return chunkOWG6N2K6_cjs.g}});Object.defineProperty(exports,"getCanonicalPath",{enumerable:true,get:function(){return chunkOWG6N2K6_cjs.o}});Object.defineProperty(exports,"getCanonicalSkillsDir",{enumerable:true,get:function(){return chunkOWG6N2K6_cjs.e}});Object.defineProperty(exports,"getEveSubagentSkillsDir",{enumerable:true,get:function(){return chunkOWG6N2K6_cjs.f}});Object.defineProperty(exports,"getInstallPath",{enumerable:true,get:function(){return chunkOWG6N2K6_cjs.m}});Object.defineProperty(exports,"installBlobSkillForAgent",{enumerable:true,get:function(){return chunkOWG6N2K6_cjs.r}});Object.defineProperty(exports,"installRemoteSkillForAgent",{enumerable:true,get:function(){return chunkOWG6N2K6_cjs.p}});Object.defineProperty(exports,"installSkillForAgent",{enumerable:true,get:function(){return chunkOWG6N2K6_cjs.h}});Object.defineProperty(exports,"installWellKnownSkillForAgent",{enumerable:true,get:function(){return chunkOWG6N2K6_cjs.q}});Object.defineProperty(exports,"isSkillInstalled",{enumerable:true,get:function(){return chunkOWG6N2K6_cjs.k}});Object.defineProperty(exports,"listInstalledSkills",{enumerable:true,get:function(){return chunkOWG6N2K6_cjs.s}});Object.defineProperty(exports,"sanitizeName",{enumerable:true,get:function(){return chunkOWG6N2K6_cjs.d}});Object.defineProperty(exports,"DEFAULT_CLONE_TIMEOUT",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.f}});Object.defineProperty(exports,"GitCloneError",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.g}});Object.defineProperty(exports,"WellKnownProvider",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.m}});Object.defineProperty(exports,"acquireSourceClone",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.R}});Object.defineProperty(exports,"addSkillToLocalLock",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.w}});Object.defineProperty(exports,"cleanCache",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.ka}});Object.defineProperty(exports,"cleanCachedRepo",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.ja}});Object.defineProperty(exports,"cleanupTempDir",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.l}});Object.defineProperty(exports,"cloneRepo",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.k}});Object.defineProperty(exports,"computeSkillFolderHash",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.v}});Object.defineProperty(exports,"discoverSkills",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.B}});Object.defineProperty(exports,"ensureCachedSource",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.da}});Object.defineProperty(exports,"filterSkills",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.D}});Object.defineProperty(exports,"getCacheRepoDir",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.Q}});Object.defineProperty(exports,"getCacheRoot",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.O}});Object.defineProperty(exports,"getLocalLockPath",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.r}});Object.defineProperty(exports,"getOwnerRepo",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.a}});Object.defineProperty(exports,"getSkillDisplayName",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.C}});Object.defineProperty(exports,"getSourceDir",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.J}});Object.defineProperty(exports,"installFromCache",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.ia}});Object.defineProperty(exports,"isGitHubHttpsCloneUrl",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.i}});Object.defineProperty(exports,"isGitHubSsoAuthError",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.j}});Object.defineProperty(exports,"isRepoPrivate",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.c}});Object.defineProperty(exports,"isSubpathSafe",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.A}});Object.defineProperty(exports,"parseGitHubRepoUrl",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.h}});Object.defineProperty(exports,"parseOwnerRepo",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.b}});Object.defineProperty(exports,"parseSkillMd",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.z}});Object.defineProperty(exports,"parseSource",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.e}});Object.defineProperty(exports,"readLocalLock",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.t}});Object.defineProperty(exports,"removeSkillFromLocalLock",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.x}});Object.defineProperty(exports,"sanitizeSubpath",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.d}});Object.defineProperty(exports,"shouldInstallInternalSkills",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.y}});Object.defineProperty(exports,"wellKnownProvider",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.n}});Object.defineProperty(exports,"writeLocalLock",{enumerable:true,get:function(){return chunkJFEBB5CL_cjs.u}});Object.defineProperty(exports,"BLOB_ALLOWED_REPOS",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.w}});Object.defineProperty(exports,"EVE_SUBAGENTS_DIR",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.h}});Object.defineProperty(exports,"PROJECT_SKILLS_DIR_PATTERN",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.m}});Object.defineProperty(exports,"agents",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.e}});Object.defineProperty(exports,"detectInstalledAgents",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.f}});Object.defineProperty(exports,"fetchRepoTree",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.A}});Object.defineProperty(exports,"findSkillMdPaths",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.C}});Object.defineProperty(exports,"getAgentConfig",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.g}});Object.defineProperty(exports,"getAgentGlobalSkillDirs",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.o}});Object.defineProperty(exports,"getAgentProjectSkillContainerPrefixes",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.q}});Object.defineProperty(exports,"getAgentProjectSkillDirs",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.n}});Object.defineProperty(exports,"getAgentSkillDirs",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.p}});Object.defineProperty(exports,"getEveSubagents",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.i}});Object.defineProperty(exports,"getNonUniversalAgents",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.l}});Object.defineProperty(exports,"getOpenClawGlobalSkillsDir",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.d}});Object.defineProperty(exports,"getSkillFolderHashFromTree",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.B}});Object.defineProperty(exports,"getUniversalAgents",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.k}});Object.defineProperty(exports,"isUniversalAgent",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.r}});Object.defineProperty(exports,"matchesUniversalScope",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.j}});Object.defineProperty(exports,"parseFrontmatter",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.c}});Object.defineProperty(exports,"resetRepoTreeAuthState",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.z}});Object.defineProperty(exports,"sanitizeMetadata",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.b}});Object.defineProperty(exports,"stripTerminalEscapes",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.a}});Object.defineProperty(exports,"toSkillSlug",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.y}});Object.defineProperty(exports,"tryBlobInstall",{enumerable:true,get:function(){return chunkTCFGU43L_cjs.D}});Object.defineProperty(exports,"getAgentAdapter",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.h}});Object.defineProperty(exports,"getGlobal",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.c}});Object.defineProperty(exports,"getHomeDir",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.k}});Object.defineProperty(exports,"getInstance",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.f}});Object.defineProperty(exports,"getProjectDirectory",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.p}});Object.defineProperty(exports,"getXdgCache",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.o}});Object.defineProperty(exports,"getXdgConfig",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.l}});Object.defineProperty(exports,"getXdgData",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.m}});Object.defineProperty(exports,"getXdgState",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.n}});Object.defineProperty(exports,"hasAgentAdapter",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.i}});Object.defineProperty(exports,"requireAgentAdapter",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.j}});Object.defineProperty(exports,"resetGlobalAdapter",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.b}});Object.defineProperty(exports,"resetInstanceAdapter",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.e}});Object.defineProperty(exports,"setAgentAdapter",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.g}});Object.defineProperty(exports,"setGlobalAdapter",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.a}});Object.defineProperty(exports,"setInstanceAdapter",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.d}});exports.createLocalPluginSource=A;exports.createWellKnownSource=x;exports.findProvider=at;exports.findSource=k;exports.findSourcesByCategory=P;exports.getProviders=ct;exports.listAllEntries=y;exports.listSources=d;exports.registerProvider=st;exports.registerSource=f;exports.registry=u;
|
|
1
|
+
'use strict';var chunkUJWB7QQ6_cjs=require('./chunks/chunk-UJWB7QQ6.cjs'),chunkS6YNGR7S_cjs=require('./chunks/chunk-S6YNGR7S.cjs'),chunkSXUY2J75_cjs=require('./chunks/chunk-SXUY2J75.cjs');require('./chunks/chunk-CY6UI6SJ.cjs');var chunk5BL3KG26_cjs=require('./chunks/chunk-5BL3KG26.cjs'),chunkCXH3OTTQ_cjs=require('./chunks/chunk-CXH3OTTQ.cjs'),chunkISMGLHYS_cjs=require('./chunks/chunk-ISMGLHYS.cjs'),chunkXGUPIAAF_cjs=require('./chunks/chunk-XGUPIAAF.cjs'),chunkRVR3DSD2_cjs=require('./chunks/chunk-RVR3DSD2.cjs'),chunkE7AHWFZN_cjs=require('./chunks/chunk-E7AHWFZN.cjs'),chunkVRHWDHQV_cjs=require('./chunks/chunk-VRHWDHQV.cjs'),path=require('path');var g=class{constructor(){chunkVRHWDHQV_cjs.b(this,"providers",[]);}register(o){if(this.providers.some(t=>t.id===o.id))throw new Error(`Provider with id "${o.id}" already registered`);this.providers.push(o);}findProvider(o){for(let t of this.providers)if(t.match(o).matches)return t;return null}getProviders(){return [...this.providers]}},u=new g;function at(e){u.register(e);}function ct(e){return u.findProvider(e)}function ut(){return u.getProviders()}var c=new Map;function f(e){if(c.has(e.id))throw new Error(`PluginSource with id "${e.id}" already registered`);c.set(e.id,e);}function d(){return Array.from(c.values()).map(e=>e)}function k(e){return c.get(e)??null}function P(e){return Array.from(c.values()).filter(o=>o.category===e)}async function y(){let e=d();return await Promise.all(e.map(async t=>{try{let r=await t.fetch();return {sourceId:t.id,entries:r}}catch(r){return {sourceId:t.id,error:r instanceof Error?r:new Error(String(r))}}}))}function pt(e){return {name:e.name,description:e.description,scope:"all"}}function x(e){return {id:e.id??`well-known:${new URL(e.url).hostname}`,category:"well-known",async fetch(){return (await chunkCXH3OTTQ_cjs.n.fetchAllSkills(e.url)).map(r=>({id:r.name,name:r.name,description:r.description,location:r.sourceUrl,category:"well-known",metadata:{installName:r.installName,sourceIdentifier:chunkCXH3OTTQ_cjs.n.getSourceIdentifier(e.url),sourceUrl:r.sourceUrl}}))},async load(t){let l=(await chunkCXH3OTTQ_cjs.n.fetchAllSkills(e.url)).find(n=>n.name===t.id);if(!l)throw new Error(`Skill "${t.id}" not found in well-known source ${e.url}`);return {skills:[pt(l)],version:"well-known",author:{name:new URL(e.url).hostname}}}}}async function h(e){try{let t=await(await import('fs/promises')).readFile(e,"utf-8");return JSON.parse(t)}catch{return null}}function A(e){let o=e.basePath.split(/[\\/]/).filter(Boolean).pop()??"local";return {id:e.id??`local:${o}`,category:"file",async fetch(){let r=[],l=await h(path.join(e.basePath,".claude-plugin/plugin.json"));l?.name&&r.push({id:l.name,name:l.name,description:l.description,location:e.basePath,category:"file",metadata:{skills:l.skills,manifest:"plugin.json"}});let n=await h(path.join(e.basePath,".claude-plugin/marketplace.json"));if(n?.plugins)for(let i of n.plugins)i.name&&(typeof i.source!="string"&&i.source!==void 0||r.push({id:i.name,name:i.name,description:i.description,location:i.source?path.join(e.basePath,n.metadata?.pluginRoot??"",i.source):e.basePath,category:"file",metadata:{skills:i.skills,manifest:"marketplace.json",pluginRoot:n.metadata?.pluginRoot}}));return r},async load(r){return {skills:(await chunkCXH3OTTQ_cjs.A(r.location)).map(i=>({name:i.name,description:i.description,scope:"all"})),version:"local",author:{name:o}}}}}Object.defineProperty(exports,"applyActions",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.c}});Object.defineProperty(exports,"buildMatrix",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.d}});Object.defineProperty(exports,"buildUsePrompt",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.G}});Object.defineProperty(exports,"detectAgent",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.f}});Object.defineProperty(exports,"getAgentName",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.h}});Object.defineProperty(exports,"getAgentType",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.i}});Object.defineProperty(exports,"handleSkillsCli",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.M}});Object.defineProperty(exports,"hasProjectSkills",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.k}});Object.defineProperty(exports,"initTelemetry",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.o}});Object.defineProperty(exports,"isRunningInAgent",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.g}});Object.defineProperty(exports,"launchAgentInteractively",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.J}});Object.defineProperty(exports,"matchesSkillFilter",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.m}});Object.defineProperty(exports,"materializeUseSkill",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.H}});Object.defineProperty(exports,"parseAddOptions",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.q}});Object.defineProperty(exports,"parseFindOptions",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.x}});Object.defineProperty(exports,"parseListOptions",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.A}});Object.defineProperty(exports,"parseRemoveOptions",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.D}});Object.defineProperty(exports,"parseStoreOptions",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.r}});Object.defineProperty(exports,"parseUpdateOptions",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.j}});Object.defineProperty(exports,"parseUseOptions",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.F}});Object.defineProperty(exports,"planActions",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.b}});Object.defineProperty(exports,"probeCell",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.a}});Object.defineProperty(exports,"removeCommand",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.C}});Object.defineProperty(exports,"renderBanner",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.K}});Object.defineProperty(exports,"renderHelp",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.L}});Object.defineProperty(exports,"resolveUpdateScope",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.l}});Object.defineProperty(exports,"runAdd",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.p}});Object.defineProperty(exports,"runDoctor",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.E}});Object.defineProperty(exports,"runFind",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.z}});Object.defineProperty(exports,"runList",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.B}});Object.defineProperty(exports,"runPostInstallReconcile",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.e}});Object.defineProperty(exports,"runStore",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.s}});Object.defineProperty(exports,"runStoreClean",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.u}});Object.defineProperty(exports,"runStoreList",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.t}});Object.defineProperty(exports,"runStoreRemove",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.w}});Object.defineProperty(exports,"runStoreUpdate",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.v}});Object.defineProperty(exports,"runUpdate",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.n}});Object.defineProperty(exports,"runUse",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.I}});Object.defineProperty(exports,"searchSkillsAPI",{enumerable:true,get:function(){return chunkUJWB7QQ6_cjs.y}});Object.defineProperty(exports,"fetchAuditData",{enumerable:true,get:function(){return chunkS6YNGR7S_cjs.c}});Object.defineProperty(exports,"flushTelemetry",{enumerable:true,get:function(){return chunkS6YNGR7S_cjs.e}});Object.defineProperty(exports,"setDetectedAgent",{enumerable:true,get:function(){return chunkS6YNGR7S_cjs.a}});Object.defineProperty(exports,"setVersion",{enumerable:true,get:function(){return chunkS6YNGR7S_cjs.b}});Object.defineProperty(exports,"track",{enumerable:true,get:function(){return chunkS6YNGR7S_cjs.d}});Object.defineProperty(exports,"addSkillToLock",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.i}});Object.defineProperty(exports,"computeContentHash",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.e}});Object.defineProperty(exports,"dismissPrompt",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.p}});Object.defineProperty(exports,"fetchSkillFolderHash",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.h}});Object.defineProperty(exports,"getAllLockedSkills",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.l}});Object.defineProperty(exports,"getGitHubToken",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.g}});Object.defineProperty(exports,"getSkillFromLock",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.k}});Object.defineProperty(exports,"getSkillLockPath",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.b}});Object.defineProperty(exports,"getSkillsBySource",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.m}});Object.defineProperty(exports,"isPromptDismissed",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.n}});Object.defineProperty(exports,"readSkillLock",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.c}});Object.defineProperty(exports,"removeSkillFromLock",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.j}});Object.defineProperty(exports,"resetGhAuthWarning",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.f}});Object.defineProperty(exports,"writeSkillLock",{enumerable:true,get:function(){return chunkSXUY2J75_cjs.d}});Object.defineProperty(exports,"AGENTS_DIR",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.a}});Object.defineProperty(exports,"SKILLS_SUBDIR",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.b}});Object.defineProperty(exports,"UNIVERSAL_SKILLS_DIR",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.c}});Object.defineProperty(exports,"getAgentBaseDir",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.g}});Object.defineProperty(exports,"getCanonicalPath",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.o}});Object.defineProperty(exports,"getCanonicalSkillsDir",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.e}});Object.defineProperty(exports,"getEveSubagentSkillsDir",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.f}});Object.defineProperty(exports,"getInstallPath",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.m}});Object.defineProperty(exports,"installBlobSkillForAgent",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.r}});Object.defineProperty(exports,"installRemoteSkillForAgent",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.p}});Object.defineProperty(exports,"installSkillForAgent",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.h}});Object.defineProperty(exports,"installWellKnownSkillForAgent",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.q}});Object.defineProperty(exports,"isSkillInstalled",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.k}});Object.defineProperty(exports,"listInstalledSkills",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.s}});Object.defineProperty(exports,"sanitizeName",{enumerable:true,get:function(){return chunk5BL3KG26_cjs.d}});Object.defineProperty(exports,"DEFAULT_CLONE_TIMEOUT",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.f}});Object.defineProperty(exports,"GitCloneError",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.g}});Object.defineProperty(exports,"WellKnownProvider",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.m}});Object.defineProperty(exports,"acquireSourceClone",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.Q}});Object.defineProperty(exports,"addSkillToLocalLock",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.v}});Object.defineProperty(exports,"cleanCache",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.ja}});Object.defineProperty(exports,"cleanCachedRepo",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.ia}});Object.defineProperty(exports,"cleanupTempDir",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.l}});Object.defineProperty(exports,"cloneRepo",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.k}});Object.defineProperty(exports,"discoverSkills",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.A}});Object.defineProperty(exports,"ensureCachedSource",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.ca}});Object.defineProperty(exports,"filterSkills",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.C}});Object.defineProperty(exports,"getCacheRepoDir",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.P}});Object.defineProperty(exports,"getCacheRoot",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.N}});Object.defineProperty(exports,"getLocalLockPath",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.r}});Object.defineProperty(exports,"getOwnerRepo",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.a}});Object.defineProperty(exports,"getSkillDisplayName",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.B}});Object.defineProperty(exports,"getSourceDir",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.I}});Object.defineProperty(exports,"installFromCache",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.ha}});Object.defineProperty(exports,"isGitHubHttpsCloneUrl",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.i}});Object.defineProperty(exports,"isGitHubSsoAuthError",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.j}});Object.defineProperty(exports,"isRepoPrivate",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.c}});Object.defineProperty(exports,"isSubpathSafe",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.z}});Object.defineProperty(exports,"parseGitHubRepoUrl",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.h}});Object.defineProperty(exports,"parseOwnerRepo",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.b}});Object.defineProperty(exports,"parseSkillMd",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.y}});Object.defineProperty(exports,"parseSource",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.e}});Object.defineProperty(exports,"readLocalLock",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.t}});Object.defineProperty(exports,"removeSkillFromLocalLock",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.w}});Object.defineProperty(exports,"sanitizeSubpath",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.d}});Object.defineProperty(exports,"shouldInstallInternalSkills",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.x}});Object.defineProperty(exports,"wellKnownProvider",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.n}});Object.defineProperty(exports,"writeLocalLock",{enumerable:true,get:function(){return chunkCXH3OTTQ_cjs.u}});Object.defineProperty(exports,"EVE_SUBAGENTS_DIR",{enumerable:true,get:function(){return chunkISMGLHYS_cjs.e}});Object.defineProperty(exports,"PROJECT_SKILLS_DIR_PATTERN",{enumerable:true,get:function(){return chunkISMGLHYS_cjs.j}});Object.defineProperty(exports,"agents",{enumerable:true,get:function(){return chunkISMGLHYS_cjs.b}});Object.defineProperty(exports,"detectInstalledAgents",{enumerable:true,get:function(){return chunkISMGLHYS_cjs.c}});Object.defineProperty(exports,"getAgentConfig",{enumerable:true,get:function(){return chunkISMGLHYS_cjs.d}});Object.defineProperty(exports,"getAgentGlobalSkillDirs",{enumerable:true,get:function(){return chunkISMGLHYS_cjs.l}});Object.defineProperty(exports,"getAgentProjectSkillContainerPrefixes",{enumerable:true,get:function(){return chunkISMGLHYS_cjs.n}});Object.defineProperty(exports,"getAgentProjectSkillDirs",{enumerable:true,get:function(){return chunkISMGLHYS_cjs.k}});Object.defineProperty(exports,"getAgentSkillDirs",{enumerable:true,get:function(){return chunkISMGLHYS_cjs.m}});Object.defineProperty(exports,"getEveSubagents",{enumerable:true,get:function(){return chunkISMGLHYS_cjs.f}});Object.defineProperty(exports,"getNonUniversalAgents",{enumerable:true,get:function(){return chunkISMGLHYS_cjs.i}});Object.defineProperty(exports,"getOpenClawGlobalSkillsDir",{enumerable:true,get:function(){return chunkISMGLHYS_cjs.a}});Object.defineProperty(exports,"getUniversalAgents",{enumerable:true,get:function(){return chunkISMGLHYS_cjs.h}});Object.defineProperty(exports,"isUniversalAgent",{enumerable:true,get:function(){return chunkISMGLHYS_cjs.o}});Object.defineProperty(exports,"matchesUniversalScope",{enumerable:true,get:function(){return chunkISMGLHYS_cjs.g}});Object.defineProperty(exports,"getAgentAdapter",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.h}});Object.defineProperty(exports,"getGlobal",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.c}});Object.defineProperty(exports,"getHomeDir",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.k}});Object.defineProperty(exports,"getInstance",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.f}});Object.defineProperty(exports,"getProjectDirectory",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.p}});Object.defineProperty(exports,"getXdgCache",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.o}});Object.defineProperty(exports,"getXdgConfig",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.l}});Object.defineProperty(exports,"getXdgData",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.m}});Object.defineProperty(exports,"getXdgState",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.n}});Object.defineProperty(exports,"hasAgentAdapter",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.i}});Object.defineProperty(exports,"requireAgentAdapter",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.j}});Object.defineProperty(exports,"resetGlobalAdapter",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.b}});Object.defineProperty(exports,"resetInstanceAdapter",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.e}});Object.defineProperty(exports,"setAgentAdapter",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.g}});Object.defineProperty(exports,"setGlobalAdapter",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.a}});Object.defineProperty(exports,"setInstanceAdapter",{enumerable:true,get:function(){return chunkXGUPIAAF_cjs.d}});Object.defineProperty(exports,"BLOB_ALLOWED_REPOS",{enumerable:true,get:function(){return chunkRVR3DSD2_cjs.c}});Object.defineProperty(exports,"fetchRepoTree",{enumerable:true,get:function(){return chunkRVR3DSD2_cjs.g}});Object.defineProperty(exports,"findSkillMdPaths",{enumerable:true,get:function(){return chunkRVR3DSD2_cjs.k}});Object.defineProperty(exports,"getSkillFolderHashFromTree",{enumerable:true,get:function(){return chunkRVR3DSD2_cjs.i}});Object.defineProperty(exports,"resetRepoTreeAuthState",{enumerable:true,get:function(){return chunkRVR3DSD2_cjs.f}});Object.defineProperty(exports,"sanitizeMetadata",{enumerable:true,get:function(){return chunkRVR3DSD2_cjs.b}});Object.defineProperty(exports,"stripTerminalEscapes",{enumerable:true,get:function(){return chunkRVR3DSD2_cjs.a}});Object.defineProperty(exports,"toSkillSlug",{enumerable:true,get:function(){return chunkRVR3DSD2_cjs.e}});Object.defineProperty(exports,"tryBlobInstall",{enumerable:true,get:function(){return chunkRVR3DSD2_cjs.l}});Object.defineProperty(exports,"computeFromDir",{enumerable:true,get:function(){return chunkE7AHWFZN_cjs.b}});Object.defineProperty(exports,"computeSnapshotHash",{enumerable:true,get:function(){return chunkE7AHWFZN_cjs.c}});Object.defineProperty(exports,"parseFrontmatter",{enumerable:true,get:function(){return chunkE7AHWFZN_cjs.a}});exports.createLocalPluginSource=A;exports.createWellKnownSource=x;exports.findProvider=ct;exports.findSource=k;exports.findSourcesByCategory=P;exports.getProviders=ut;exports.listAllEntries=y;exports.listSources=d;exports.registerProvider=at;exports.registerSource=f;exports.registry=u;
|
package/dist/index.d.cts
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { AgentResult } from '@vercel/detect-agent';
|
|
2
1
|
import { Lang } from '@easbot/utils';
|
|
3
2
|
import { IGlobal, IInstance, ISubAgentRunner } from '@easbot/types';
|
|
4
3
|
|
|
@@ -68,7 +67,10 @@ interface DiscoverSkillsOptions {
|
|
|
68
67
|
}
|
|
69
68
|
declare function isSubpathSafe(basePath: string, subpath: string): boolean;
|
|
70
69
|
declare function discoverSkills(basePath: string, subpath?: string, options?: DiscoverSkillsOptions): Promise<Skill[]>;
|
|
71
|
-
declare function getSkillDisplayName(skill:
|
|
70
|
+
declare function getSkillDisplayName(skill: {
|
|
71
|
+
name: string;
|
|
72
|
+
path?: string;
|
|
73
|
+
}): string;
|
|
72
74
|
declare function filterSkills(skills: Skill[], inputNames: string[]): Skill[];
|
|
73
75
|
|
|
74
76
|
type InstallState = 'absent' | 'symlinked' | 'copied' | 'orphan' | 'divergent';
|
|
@@ -370,6 +372,7 @@ interface AddOptions {
|
|
|
370
372
|
fullDepth?: boolean;
|
|
371
373
|
copy?: boolean;
|
|
372
374
|
subagent?: string[];
|
|
375
|
+
json?: boolean;
|
|
373
376
|
}
|
|
374
377
|
declare function runAdd(args: string[], options?: AddOptions): Promise<void>;
|
|
375
378
|
declare function parseAddOptions(args: string[]): {
|
|
@@ -432,7 +435,7 @@ declare function cleanupTempDir(dir: string): Promise<void>;
|
|
|
432
435
|
|
|
433
436
|
interface SkillSnapshotFile {
|
|
434
437
|
path: string;
|
|
435
|
-
contents: string;
|
|
438
|
+
contents: string | Buffer;
|
|
436
439
|
}
|
|
437
440
|
interface SkillDownloadResponse {
|
|
438
441
|
files: SkillSnapshotFile[];
|
|
@@ -442,6 +445,7 @@ interface BlobSkill extends Skill {
|
|
|
442
445
|
files: SkillSnapshotFile[];
|
|
443
446
|
snapshotHash: string;
|
|
444
447
|
repoPath: string;
|
|
448
|
+
repoSubpath?: string;
|
|
445
449
|
}
|
|
446
450
|
declare const BLOB_ALLOWED_REPOS: Record<string, {
|
|
447
451
|
downloadUrl: (slug: string) => string;
|
|
@@ -461,10 +465,16 @@ interface RepoTree {
|
|
|
461
465
|
declare function resetRepoTreeAuthState(): void;
|
|
462
466
|
declare function fetchRepoTree(ownerRepo: string, ref?: string, getToken?: () => string | null): Promise<RepoTree | null>;
|
|
463
467
|
declare function getSkillFolderHashFromTree(tree: RepoTree, skillPath: string): string | null;
|
|
464
|
-
declare function findSkillMdPaths(tree: RepoTree,
|
|
468
|
+
declare function findSkillMdPaths(tree: RepoTree, options?: {
|
|
469
|
+
subpath?: string;
|
|
470
|
+
maxDepth?: number;
|
|
471
|
+
limit?: number;
|
|
472
|
+
}): string[];
|
|
465
473
|
interface BlobInstallResult {
|
|
466
474
|
skills: BlobSkill[];
|
|
467
475
|
tree: RepoTree;
|
|
476
|
+
subpath?: string;
|
|
477
|
+
snapshotHash?: string;
|
|
468
478
|
}
|
|
469
479
|
declare function tryBlobInstall(ownerRepo: string, options?: {
|
|
470
480
|
subpath?: string;
|
|
@@ -511,6 +521,7 @@ interface RemoveOptions {
|
|
|
511
521
|
skill?: string[];
|
|
512
522
|
yes?: boolean;
|
|
513
523
|
all?: boolean;
|
|
524
|
+
json?: boolean;
|
|
514
525
|
}
|
|
515
526
|
declare function removeCommand(skillNames: string[], options: RemoveOptions): Promise<void>;
|
|
516
527
|
declare function parseRemoveOptions(args: string[]): {
|
|
@@ -576,7 +587,6 @@ interface LocalSkillLockFile {
|
|
|
576
587
|
declare function getLocalLockPath(cwd?: string): string;
|
|
577
588
|
declare function readLocalLock(cwd?: string): Promise<LocalSkillLockFile>;
|
|
578
589
|
declare function writeLocalLock(lock: LocalSkillLockFile, cwd?: string): Promise<void>;
|
|
579
|
-
declare function computeSkillFolderHash(skillDir: string): Promise<string>;
|
|
580
590
|
declare function addSkillToLocalLock(skillName: string, entry: Omit<LocalSkillLockEntry, 'installedAt' | 'updatedAt'>, cwd?: string): Promise<void>;
|
|
581
591
|
declare function removeSkillFromLocalLock(skillName: string, cwd?: string): Promise<boolean>;
|
|
582
592
|
|
|
@@ -586,6 +596,7 @@ interface UpdateCheckOptions {
|
|
|
586
596
|
global?: boolean;
|
|
587
597
|
project?: boolean;
|
|
588
598
|
yes?: boolean;
|
|
599
|
+
json?: boolean;
|
|
589
600
|
all?: boolean;
|
|
590
601
|
agent?: string[];
|
|
591
602
|
force?: boolean;
|
|
@@ -626,6 +637,7 @@ interface UseOptions {
|
|
|
626
637
|
fullDepth?: boolean;
|
|
627
638
|
dangerouslyAcceptOpenclawRisks?: boolean;
|
|
628
639
|
help?: boolean;
|
|
640
|
+
json?: boolean;
|
|
629
641
|
}
|
|
630
642
|
interface ParseUseOptionsResult {
|
|
631
643
|
source: string[];
|
|
@@ -639,7 +651,7 @@ type UseSkill = {
|
|
|
639
651
|
rawContent: string;
|
|
640
652
|
files: Array<{
|
|
641
653
|
path: string;
|
|
642
|
-
contents: string;
|
|
654
|
+
contents: string | Buffer;
|
|
643
655
|
}>;
|
|
644
656
|
} | {
|
|
645
657
|
kind: 'disk';
|
|
@@ -676,6 +688,12 @@ declare function materializeUseSkill(skill: UseSkill): Promise<MaterializedUseSk
|
|
|
676
688
|
declare function runUse(sourceArgs: string[], options?: UseOptions, parseErrors?: string[]): Promise<void>;
|
|
677
689
|
declare function launchAgentInteractively(agent: AgentType, prompt: string, spawnImpl?: AgentSpawn): Promise<number>;
|
|
678
690
|
|
|
691
|
+
declare function computeFromDir(skillDir: string): Promise<string>;
|
|
692
|
+
declare function computeSnapshotHash(files: ReadonlyArray<{
|
|
693
|
+
path: string;
|
|
694
|
+
contents: string | Buffer;
|
|
695
|
+
}>): string;
|
|
696
|
+
|
|
679
697
|
interface InstallTelemetryData {
|
|
680
698
|
event: 'install';
|
|
681
699
|
source: string;
|
|
@@ -763,6 +781,32 @@ declare function flushTelemetry(timeoutMs?: number): Promise<void>;
|
|
|
763
781
|
declare function stripTerminalEscapes(str: string): string;
|
|
764
782
|
declare function sanitizeMetadata(str: string): string;
|
|
765
783
|
|
|
784
|
+
declare const EASBOT: "easbot";
|
|
785
|
+
declare const CURSOR: "cursor";
|
|
786
|
+
declare const CURSOR_CLI: "cursor-cli";
|
|
787
|
+
declare const CLAUDE: "claude";
|
|
788
|
+
declare const COWORK: "cowork";
|
|
789
|
+
declare const DEVIN: "devin";
|
|
790
|
+
declare const REPLIT: "replit";
|
|
791
|
+
declare const GEMINI: "gemini";
|
|
792
|
+
declare const CODEX: "codex";
|
|
793
|
+
declare const ANTIGRAVITY: "antigravity";
|
|
794
|
+
declare const AUGMENT_CLI: "augment-cli";
|
|
795
|
+
declare const OPENCODE: "opencode";
|
|
796
|
+
declare const GITHUB_COPILOT: "github-copilot";
|
|
797
|
+
declare const V0: "v0";
|
|
798
|
+
type KnownAgentNames = typeof EASBOT | typeof CURSOR | typeof CURSOR_CLI | typeof CLAUDE | typeof COWORK | typeof DEVIN | typeof REPLIT | typeof GEMINI | typeof CODEX | typeof ANTIGRAVITY | typeof AUGMENT_CLI | typeof OPENCODE | typeof GITHUB_COPILOT | typeof V0;
|
|
799
|
+
interface KnownAgentDetails {
|
|
800
|
+
name: KnownAgentNames;
|
|
801
|
+
}
|
|
802
|
+
type AgentResult = {
|
|
803
|
+
isAgent: true;
|
|
804
|
+
agent: KnownAgentDetails;
|
|
805
|
+
} | {
|
|
806
|
+
isAgent: false;
|
|
807
|
+
agent: undefined;
|
|
808
|
+
};
|
|
809
|
+
|
|
766
810
|
declare function detectAgent(): Promise<AgentResult>;
|
|
767
811
|
declare function isRunningInAgent(): Promise<boolean>;
|
|
768
812
|
declare function getAgentName(): Promise<string | null>;
|
|
@@ -886,4 +930,4 @@ declare function listAllEntries(): Promise<Array<{
|
|
|
886
930
|
error: Error;
|
|
887
931
|
}>>;
|
|
888
932
|
|
|
889
|
-
export { AGENTS_DIR, type AddOptions, type AgentConfig, type AgentInstallMatrix, type AgentProcess, type AgentSkillDirsResult, type AgentSpawn, type AgentType, type AuditResponse, BLOB_ALLOWED_REPOS, type BlobInstallResult, type BlobSkill, type CellAction, type CellScope, DEFAULT_CLONE_TIMEOUT, type DiscoverSkillsOptions, type DismissedPrompts, EVE_SUBAGENTS_DIR, type FindOptions, GitCloneError, type HostProvider, type InstallCell, type InstallMode, type InstallScope, type InstallState, type InstalledSkill, type LocalPluginSourceOptions, type LocalSkillLockEntry, type LocalSkillLockFile, type MaterializedUseSkill, PROJECT_SKILLS_DIR_PATTERN, type ParseFindOptionsResult, type ParseUseOptionsResult, type ParsedSource, type PartnerAudit, type PluginSource, type PluginSourceCategory, type PluginSourceEntry, type PluginSourceLoadResult, type PostInstallInput, type PostInstallResult, type ProviderMatch, type ProviderRegistry, type RemoteSkill as ProviderRemoteSkill, type RemoteSkill$1 as RemoteSkill, type RemoveOptions, type RepoTree, SKILLS_SUBDIR, type SearchSkill, type Skill, type SkillAuditData, type SkillDownloadResponse, type SkillLockEntry, type SkillLockFile, type SkillSnapshotFile, type SkillsAgentAdapter, type SkillsCliDeps, type SkillsCliResult, type StoreOptions, type TreeEntry, UNIVERSAL_SKILLS_DIR, type UniversalScope, type UpdateCheckOptions, type UpdateScope, type UseOptions, type UseSkill, type WellKnownFileContent, type WellKnownIndex, type WellKnownIndexV1, type WellKnownIndexV2, WellKnownProvider, type WellKnownSkill, type WellKnownSkillEntry, type WellKnownSkillEntryV1, type WellKnownSkillEntryV2, type WellKnownSourceOptions, acquireSourceClone, addSkillToLocalLock, addSkillToLock, agents, applyActions, buildMatrix, buildUsePrompt, cleanCache, cleanCachedRepo, cleanupTempDir, cloneRepo, computeContentHash,
|
|
933
|
+
export { AGENTS_DIR, type AddOptions, type AgentConfig, type AgentInstallMatrix, type AgentProcess, type AgentSkillDirsResult, type AgentSpawn, type AgentType, type AuditResponse, BLOB_ALLOWED_REPOS, type BlobInstallResult, type BlobSkill, type CellAction, type CellScope, DEFAULT_CLONE_TIMEOUT, type DiscoverSkillsOptions, type DismissedPrompts, EVE_SUBAGENTS_DIR, type FindOptions, GitCloneError, type HostProvider, type InstallCell, type InstallMode, type InstallScope, type InstallState, type InstalledSkill, type LocalPluginSourceOptions, type LocalSkillLockEntry, type LocalSkillLockFile, type MaterializedUseSkill, PROJECT_SKILLS_DIR_PATTERN, type ParseFindOptionsResult, type ParseUseOptionsResult, type ParsedSource, type PartnerAudit, type PluginSource, type PluginSourceCategory, type PluginSourceEntry, type PluginSourceLoadResult, type PostInstallInput, type PostInstallResult, type ProviderMatch, type ProviderRegistry, type RemoteSkill as ProviderRemoteSkill, type RemoteSkill$1 as RemoteSkill, type RemoveOptions, type RepoTree, SKILLS_SUBDIR, type SearchSkill, type Skill, type SkillAuditData, type SkillDownloadResponse, type SkillLockEntry, type SkillLockFile, type SkillSnapshotFile, type SkillsAgentAdapter, type SkillsCliDeps, type SkillsCliResult, type StoreOptions, type TreeEntry, UNIVERSAL_SKILLS_DIR, type UniversalScope, type UpdateCheckOptions, type UpdateScope, type UseOptions, type UseSkill, type WellKnownFileContent, type WellKnownIndex, type WellKnownIndexV1, type WellKnownIndexV2, WellKnownProvider, type WellKnownSkill, type WellKnownSkillEntry, type WellKnownSkillEntryV1, type WellKnownSkillEntryV2, type WellKnownSourceOptions, acquireSourceClone, addSkillToLocalLock, addSkillToLock, agents, applyActions, buildMatrix, buildUsePrompt, cleanCache, cleanCachedRepo, cleanupTempDir, cloneRepo, computeContentHash, computeFromDir, computeSnapshotHash, createLocalPluginSource, createWellKnownSource, detectAgent, detectInstalledAgents, discoverSkills, dismissPrompt, ensureCachedSource, fetchAuditData, fetchRepoTree, fetchSkillFolderHash, filterSkills, findProvider, findSkillMdPaths, findSource, findSourcesByCategory, flushTelemetry, getAgentAdapter, getAgentBaseDir, getAgentConfig, getAgentGlobalSkillDirs, getAgentName, getAgentProjectSkillContainerPrefixes, getAgentProjectSkillDirs, getAgentSkillDirs, getAgentType, getAllLockedSkills, getCacheRepoDir, getCacheRoot, getCanonicalPath, getCanonicalSkillsDir, getEveSubagentSkillsDir, getEveSubagents, getGitHubToken, getGlobal, getHomeDir, getInstallPath, getInstance, getLocalLockPath, getNonUniversalAgents, getOpenClawGlobalSkillsDir, getOwnerRepo, getProjectDirectory, getProviders, getSkillDisplayName, getSkillFolderHashFromTree, getSkillFromLock, getSkillLockPath, getSkillsBySource, getSourceDir, getUniversalAgents, getXdgCache, getXdgConfig, getXdgData, getXdgState, handleSkillsCli, hasAgentAdapter, hasProjectSkills, initTelemetry, installBlobSkillForAgent, installFromCache, installRemoteSkillForAgent, installSkillForAgent, installWellKnownSkillForAgent, isGitHubHttpsCloneUrl, isGitHubSsoAuthError, isPromptDismissed, isRepoPrivate, isRunningInAgent, isSkillInstalled, isSubpathSafe, isUniversalAgent, launchAgentInteractively, listAllEntries, listInstalledSkills, listSources, matchesSkillFilter, matchesUniversalScope, materializeUseSkill, parseAddOptions, parseFindOptions, parseFrontmatter, parseGitHubRepoUrl, parseListOptions, parseOwnerRepo, parseRemoveOptions, parseSkillMd, parseSource, parseStoreOptions, parseUpdateOptions, parseUseOptions, planActions, probeCell, readLocalLock, readSkillLock, registerProvider, registerSource, registry, removeCommand, removeSkillFromLocalLock, removeSkillFromLock, renderBanner, renderHelp, requireAgentAdapter, resetGhAuthWarning, resetGlobalAdapter, resetInstanceAdapter, resetRepoTreeAuthState, resolveUpdateScope, runAdd, runDoctor, runFind, runList, runPostInstallReconcile, runStore, runStoreClean, runStoreList, runStoreRemove, runStoreUpdate, runUpdate, runUse, sanitizeMetadata, sanitizeName, sanitizeSubpath, searchSkillsAPI, setAgentAdapter, setDetectedAgent, setGlobalAdapter, setInstanceAdapter, setVersion, shouldInstallInternalSkills, stripTerminalEscapes, toSkillSlug, track, tryBlobInstall, wellKnownProvider, writeLocalLock, writeSkillLock };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { AgentResult } from '@vercel/detect-agent';
|
|
2
1
|
import { Lang } from '@easbot/utils';
|
|
3
2
|
import { IGlobal, IInstance, ISubAgentRunner } from '@easbot/types';
|
|
4
3
|
|
|
@@ -68,7 +67,10 @@ interface DiscoverSkillsOptions {
|
|
|
68
67
|
}
|
|
69
68
|
declare function isSubpathSafe(basePath: string, subpath: string): boolean;
|
|
70
69
|
declare function discoverSkills(basePath: string, subpath?: string, options?: DiscoverSkillsOptions): Promise<Skill[]>;
|
|
71
|
-
declare function getSkillDisplayName(skill:
|
|
70
|
+
declare function getSkillDisplayName(skill: {
|
|
71
|
+
name: string;
|
|
72
|
+
path?: string;
|
|
73
|
+
}): string;
|
|
72
74
|
declare function filterSkills(skills: Skill[], inputNames: string[]): Skill[];
|
|
73
75
|
|
|
74
76
|
type InstallState = 'absent' | 'symlinked' | 'copied' | 'orphan' | 'divergent';
|
|
@@ -370,6 +372,7 @@ interface AddOptions {
|
|
|
370
372
|
fullDepth?: boolean;
|
|
371
373
|
copy?: boolean;
|
|
372
374
|
subagent?: string[];
|
|
375
|
+
json?: boolean;
|
|
373
376
|
}
|
|
374
377
|
declare function runAdd(args: string[], options?: AddOptions): Promise<void>;
|
|
375
378
|
declare function parseAddOptions(args: string[]): {
|
|
@@ -432,7 +435,7 @@ declare function cleanupTempDir(dir: string): Promise<void>;
|
|
|
432
435
|
|
|
433
436
|
interface SkillSnapshotFile {
|
|
434
437
|
path: string;
|
|
435
|
-
contents: string;
|
|
438
|
+
contents: string | Buffer;
|
|
436
439
|
}
|
|
437
440
|
interface SkillDownloadResponse {
|
|
438
441
|
files: SkillSnapshotFile[];
|
|
@@ -442,6 +445,7 @@ interface BlobSkill extends Skill {
|
|
|
442
445
|
files: SkillSnapshotFile[];
|
|
443
446
|
snapshotHash: string;
|
|
444
447
|
repoPath: string;
|
|
448
|
+
repoSubpath?: string;
|
|
445
449
|
}
|
|
446
450
|
declare const BLOB_ALLOWED_REPOS: Record<string, {
|
|
447
451
|
downloadUrl: (slug: string) => string;
|
|
@@ -461,10 +465,16 @@ interface RepoTree {
|
|
|
461
465
|
declare function resetRepoTreeAuthState(): void;
|
|
462
466
|
declare function fetchRepoTree(ownerRepo: string, ref?: string, getToken?: () => string | null): Promise<RepoTree | null>;
|
|
463
467
|
declare function getSkillFolderHashFromTree(tree: RepoTree, skillPath: string): string | null;
|
|
464
|
-
declare function findSkillMdPaths(tree: RepoTree,
|
|
468
|
+
declare function findSkillMdPaths(tree: RepoTree, options?: {
|
|
469
|
+
subpath?: string;
|
|
470
|
+
maxDepth?: number;
|
|
471
|
+
limit?: number;
|
|
472
|
+
}): string[];
|
|
465
473
|
interface BlobInstallResult {
|
|
466
474
|
skills: BlobSkill[];
|
|
467
475
|
tree: RepoTree;
|
|
476
|
+
subpath?: string;
|
|
477
|
+
snapshotHash?: string;
|
|
468
478
|
}
|
|
469
479
|
declare function tryBlobInstall(ownerRepo: string, options?: {
|
|
470
480
|
subpath?: string;
|
|
@@ -511,6 +521,7 @@ interface RemoveOptions {
|
|
|
511
521
|
skill?: string[];
|
|
512
522
|
yes?: boolean;
|
|
513
523
|
all?: boolean;
|
|
524
|
+
json?: boolean;
|
|
514
525
|
}
|
|
515
526
|
declare function removeCommand(skillNames: string[], options: RemoveOptions): Promise<void>;
|
|
516
527
|
declare function parseRemoveOptions(args: string[]): {
|
|
@@ -576,7 +587,6 @@ interface LocalSkillLockFile {
|
|
|
576
587
|
declare function getLocalLockPath(cwd?: string): string;
|
|
577
588
|
declare function readLocalLock(cwd?: string): Promise<LocalSkillLockFile>;
|
|
578
589
|
declare function writeLocalLock(lock: LocalSkillLockFile, cwd?: string): Promise<void>;
|
|
579
|
-
declare function computeSkillFolderHash(skillDir: string): Promise<string>;
|
|
580
590
|
declare function addSkillToLocalLock(skillName: string, entry: Omit<LocalSkillLockEntry, 'installedAt' | 'updatedAt'>, cwd?: string): Promise<void>;
|
|
581
591
|
declare function removeSkillFromLocalLock(skillName: string, cwd?: string): Promise<boolean>;
|
|
582
592
|
|
|
@@ -586,6 +596,7 @@ interface UpdateCheckOptions {
|
|
|
586
596
|
global?: boolean;
|
|
587
597
|
project?: boolean;
|
|
588
598
|
yes?: boolean;
|
|
599
|
+
json?: boolean;
|
|
589
600
|
all?: boolean;
|
|
590
601
|
agent?: string[];
|
|
591
602
|
force?: boolean;
|
|
@@ -626,6 +637,7 @@ interface UseOptions {
|
|
|
626
637
|
fullDepth?: boolean;
|
|
627
638
|
dangerouslyAcceptOpenclawRisks?: boolean;
|
|
628
639
|
help?: boolean;
|
|
640
|
+
json?: boolean;
|
|
629
641
|
}
|
|
630
642
|
interface ParseUseOptionsResult {
|
|
631
643
|
source: string[];
|
|
@@ -639,7 +651,7 @@ type UseSkill = {
|
|
|
639
651
|
rawContent: string;
|
|
640
652
|
files: Array<{
|
|
641
653
|
path: string;
|
|
642
|
-
contents: string;
|
|
654
|
+
contents: string | Buffer;
|
|
643
655
|
}>;
|
|
644
656
|
} | {
|
|
645
657
|
kind: 'disk';
|
|
@@ -676,6 +688,12 @@ declare function materializeUseSkill(skill: UseSkill): Promise<MaterializedUseSk
|
|
|
676
688
|
declare function runUse(sourceArgs: string[], options?: UseOptions, parseErrors?: string[]): Promise<void>;
|
|
677
689
|
declare function launchAgentInteractively(agent: AgentType, prompt: string, spawnImpl?: AgentSpawn): Promise<number>;
|
|
678
690
|
|
|
691
|
+
declare function computeFromDir(skillDir: string): Promise<string>;
|
|
692
|
+
declare function computeSnapshotHash(files: ReadonlyArray<{
|
|
693
|
+
path: string;
|
|
694
|
+
contents: string | Buffer;
|
|
695
|
+
}>): string;
|
|
696
|
+
|
|
679
697
|
interface InstallTelemetryData {
|
|
680
698
|
event: 'install';
|
|
681
699
|
source: string;
|
|
@@ -763,6 +781,32 @@ declare function flushTelemetry(timeoutMs?: number): Promise<void>;
|
|
|
763
781
|
declare function stripTerminalEscapes(str: string): string;
|
|
764
782
|
declare function sanitizeMetadata(str: string): string;
|
|
765
783
|
|
|
784
|
+
declare const EASBOT: "easbot";
|
|
785
|
+
declare const CURSOR: "cursor";
|
|
786
|
+
declare const CURSOR_CLI: "cursor-cli";
|
|
787
|
+
declare const CLAUDE: "claude";
|
|
788
|
+
declare const COWORK: "cowork";
|
|
789
|
+
declare const DEVIN: "devin";
|
|
790
|
+
declare const REPLIT: "replit";
|
|
791
|
+
declare const GEMINI: "gemini";
|
|
792
|
+
declare const CODEX: "codex";
|
|
793
|
+
declare const ANTIGRAVITY: "antigravity";
|
|
794
|
+
declare const AUGMENT_CLI: "augment-cli";
|
|
795
|
+
declare const OPENCODE: "opencode";
|
|
796
|
+
declare const GITHUB_COPILOT: "github-copilot";
|
|
797
|
+
declare const V0: "v0";
|
|
798
|
+
type KnownAgentNames = typeof EASBOT | typeof CURSOR | typeof CURSOR_CLI | typeof CLAUDE | typeof COWORK | typeof DEVIN | typeof REPLIT | typeof GEMINI | typeof CODEX | typeof ANTIGRAVITY | typeof AUGMENT_CLI | typeof OPENCODE | typeof GITHUB_COPILOT | typeof V0;
|
|
799
|
+
interface KnownAgentDetails {
|
|
800
|
+
name: KnownAgentNames;
|
|
801
|
+
}
|
|
802
|
+
type AgentResult = {
|
|
803
|
+
isAgent: true;
|
|
804
|
+
agent: KnownAgentDetails;
|
|
805
|
+
} | {
|
|
806
|
+
isAgent: false;
|
|
807
|
+
agent: undefined;
|
|
808
|
+
};
|
|
809
|
+
|
|
766
810
|
declare function detectAgent(): Promise<AgentResult>;
|
|
767
811
|
declare function isRunningInAgent(): Promise<boolean>;
|
|
768
812
|
declare function getAgentName(): Promise<string | null>;
|
|
@@ -886,4 +930,4 @@ declare function listAllEntries(): Promise<Array<{
|
|
|
886
930
|
error: Error;
|
|
887
931
|
}>>;
|
|
888
932
|
|
|
889
|
-
export { AGENTS_DIR, type AddOptions, type AgentConfig, type AgentInstallMatrix, type AgentProcess, type AgentSkillDirsResult, type AgentSpawn, type AgentType, type AuditResponse, BLOB_ALLOWED_REPOS, type BlobInstallResult, type BlobSkill, type CellAction, type CellScope, DEFAULT_CLONE_TIMEOUT, type DiscoverSkillsOptions, type DismissedPrompts, EVE_SUBAGENTS_DIR, type FindOptions, GitCloneError, type HostProvider, type InstallCell, type InstallMode, type InstallScope, type InstallState, type InstalledSkill, type LocalPluginSourceOptions, type LocalSkillLockEntry, type LocalSkillLockFile, type MaterializedUseSkill, PROJECT_SKILLS_DIR_PATTERN, type ParseFindOptionsResult, type ParseUseOptionsResult, type ParsedSource, type PartnerAudit, type PluginSource, type PluginSourceCategory, type PluginSourceEntry, type PluginSourceLoadResult, type PostInstallInput, type PostInstallResult, type ProviderMatch, type ProviderRegistry, type RemoteSkill as ProviderRemoteSkill, type RemoteSkill$1 as RemoteSkill, type RemoveOptions, type RepoTree, SKILLS_SUBDIR, type SearchSkill, type Skill, type SkillAuditData, type SkillDownloadResponse, type SkillLockEntry, type SkillLockFile, type SkillSnapshotFile, type SkillsAgentAdapter, type SkillsCliDeps, type SkillsCliResult, type StoreOptions, type TreeEntry, UNIVERSAL_SKILLS_DIR, type UniversalScope, type UpdateCheckOptions, type UpdateScope, type UseOptions, type UseSkill, type WellKnownFileContent, type WellKnownIndex, type WellKnownIndexV1, type WellKnownIndexV2, WellKnownProvider, type WellKnownSkill, type WellKnownSkillEntry, type WellKnownSkillEntryV1, type WellKnownSkillEntryV2, type WellKnownSourceOptions, acquireSourceClone, addSkillToLocalLock, addSkillToLock, agents, applyActions, buildMatrix, buildUsePrompt, cleanCache, cleanCachedRepo, cleanupTempDir, cloneRepo, computeContentHash,
|
|
933
|
+
export { AGENTS_DIR, type AddOptions, type AgentConfig, type AgentInstallMatrix, type AgentProcess, type AgentSkillDirsResult, type AgentSpawn, type AgentType, type AuditResponse, BLOB_ALLOWED_REPOS, type BlobInstallResult, type BlobSkill, type CellAction, type CellScope, DEFAULT_CLONE_TIMEOUT, type DiscoverSkillsOptions, type DismissedPrompts, EVE_SUBAGENTS_DIR, type FindOptions, GitCloneError, type HostProvider, type InstallCell, type InstallMode, type InstallScope, type InstallState, type InstalledSkill, type LocalPluginSourceOptions, type LocalSkillLockEntry, type LocalSkillLockFile, type MaterializedUseSkill, PROJECT_SKILLS_DIR_PATTERN, type ParseFindOptionsResult, type ParseUseOptionsResult, type ParsedSource, type PartnerAudit, type PluginSource, type PluginSourceCategory, type PluginSourceEntry, type PluginSourceLoadResult, type PostInstallInput, type PostInstallResult, type ProviderMatch, type ProviderRegistry, type RemoteSkill as ProviderRemoteSkill, type RemoteSkill$1 as RemoteSkill, type RemoveOptions, type RepoTree, SKILLS_SUBDIR, type SearchSkill, type Skill, type SkillAuditData, type SkillDownloadResponse, type SkillLockEntry, type SkillLockFile, type SkillSnapshotFile, type SkillsAgentAdapter, type SkillsCliDeps, type SkillsCliResult, type StoreOptions, type TreeEntry, UNIVERSAL_SKILLS_DIR, type UniversalScope, type UpdateCheckOptions, type UpdateScope, type UseOptions, type UseSkill, type WellKnownFileContent, type WellKnownIndex, type WellKnownIndexV1, type WellKnownIndexV2, WellKnownProvider, type WellKnownSkill, type WellKnownSkillEntry, type WellKnownSkillEntryV1, type WellKnownSkillEntryV2, type WellKnownSourceOptions, acquireSourceClone, addSkillToLocalLock, addSkillToLock, agents, applyActions, buildMatrix, buildUsePrompt, cleanCache, cleanCachedRepo, cleanupTempDir, cloneRepo, computeContentHash, computeFromDir, computeSnapshotHash, createLocalPluginSource, createWellKnownSource, detectAgent, detectInstalledAgents, discoverSkills, dismissPrompt, ensureCachedSource, fetchAuditData, fetchRepoTree, fetchSkillFolderHash, filterSkills, findProvider, findSkillMdPaths, findSource, findSourcesByCategory, flushTelemetry, getAgentAdapter, getAgentBaseDir, getAgentConfig, getAgentGlobalSkillDirs, getAgentName, getAgentProjectSkillContainerPrefixes, getAgentProjectSkillDirs, getAgentSkillDirs, getAgentType, getAllLockedSkills, getCacheRepoDir, getCacheRoot, getCanonicalPath, getCanonicalSkillsDir, getEveSubagentSkillsDir, getEveSubagents, getGitHubToken, getGlobal, getHomeDir, getInstallPath, getInstance, getLocalLockPath, getNonUniversalAgents, getOpenClawGlobalSkillsDir, getOwnerRepo, getProjectDirectory, getProviders, getSkillDisplayName, getSkillFolderHashFromTree, getSkillFromLock, getSkillLockPath, getSkillsBySource, getSourceDir, getUniversalAgents, getXdgCache, getXdgConfig, getXdgData, getXdgState, handleSkillsCli, hasAgentAdapter, hasProjectSkills, initTelemetry, installBlobSkillForAgent, installFromCache, installRemoteSkillForAgent, installSkillForAgent, installWellKnownSkillForAgent, isGitHubHttpsCloneUrl, isGitHubSsoAuthError, isPromptDismissed, isRepoPrivate, isRunningInAgent, isSkillInstalled, isSubpathSafe, isUniversalAgent, launchAgentInteractively, listAllEntries, listInstalledSkills, listSources, matchesSkillFilter, matchesUniversalScope, materializeUseSkill, parseAddOptions, parseFindOptions, parseFrontmatter, parseGitHubRepoUrl, parseListOptions, parseOwnerRepo, parseRemoveOptions, parseSkillMd, parseSource, parseStoreOptions, parseUpdateOptions, parseUseOptions, planActions, probeCell, readLocalLock, readSkillLock, registerProvider, registerSource, registry, removeCommand, removeSkillFromLocalLock, removeSkillFromLock, renderBanner, renderHelp, requireAgentAdapter, resetGhAuthWarning, resetGlobalAdapter, resetInstanceAdapter, resetRepoTreeAuthState, resolveUpdateScope, runAdd, runDoctor, runFind, runList, runPostInstallReconcile, runStore, runStoreClean, runStoreList, runStoreRemove, runStoreUpdate, runUpdate, runUse, sanitizeMetadata, sanitizeName, sanitizeSubpath, searchSkillsAPI, setAgentAdapter, setDetectedAgent, setGlobalAdapter, setInstanceAdapter, setVersion, shouldInstallInternalSkills, stripTerminalEscapes, toSkillSlug, track, tryBlobInstall, wellKnownProvider, writeLocalLock, writeSkillLock };
|
package/dist/index.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{c as applyActions,d as buildMatrix,G as buildUsePrompt,f as detectAgent,h as getAgentName,i as getAgentType,M as handleSkillsCli,k as hasProjectSkills,o as initTelemetry,g as isRunningInAgent,J as launchAgentInteractively,m as matchesSkillFilter,H as materializeUseSkill,q as parseAddOptions,x as parseFindOptions,A as parseListOptions,D as parseRemoveOptions,r as parseStoreOptions,j as parseUpdateOptions,F as parseUseOptions,b as planActions,a as probeCell,C as removeCommand,K as renderBanner,L as renderHelp,l as resolveUpdateScope,p as runAdd,E as runDoctor,z as runFind,B as runList,e as runPostInstallReconcile,s as runStore,u as runStoreClean,t as runStoreList,w as runStoreRemove,v as runStoreUpdate,n as runUpdate,I as runUse,y as searchSkillsAPI}from'./chunks/chunk-
|
|
1
|
+
export{c as applyActions,d as buildMatrix,G as buildUsePrompt,f as detectAgent,h as getAgentName,i as getAgentType,M as handleSkillsCli,k as hasProjectSkills,o as initTelemetry,g as isRunningInAgent,J as launchAgentInteractively,m as matchesSkillFilter,H as materializeUseSkill,q as parseAddOptions,x as parseFindOptions,A as parseListOptions,D as parseRemoveOptions,r as parseStoreOptions,j as parseUpdateOptions,F as parseUseOptions,b as planActions,a as probeCell,C as removeCommand,K as renderBanner,L as renderHelp,l as resolveUpdateScope,p as runAdd,E as runDoctor,z as runFind,B as runList,e as runPostInstallReconcile,s as runStore,u as runStoreClean,t as runStoreList,w as runStoreRemove,v as runStoreUpdate,n as runUpdate,I as runUse,y as searchSkillsAPI}from'./chunks/chunk-K2XGYOXP.mjs';export{c as fetchAuditData,e as flushTelemetry,a as setDetectedAgent,b as setVersion,d as track}from'./chunks/chunk-CFMOYU7R.mjs';export{i as addSkillToLock,e as computeContentHash,p as dismissPrompt,h as fetchSkillFolderHash,l as getAllLockedSkills,g as getGitHubToken,k as getSkillFromLock,b as getSkillLockPath,m as getSkillsBySource,n as isPromptDismissed,c as readSkillLock,j as removeSkillFromLock,f as resetGhAuthWarning,d as writeSkillLock}from'./chunks/chunk-NKIQLESR.mjs';import'./chunks/chunk-ZBKGF7PA.mjs';export{a as AGENTS_DIR,b as SKILLS_SUBDIR,c as UNIVERSAL_SKILLS_DIR,g as getAgentBaseDir,o as getCanonicalPath,e as getCanonicalSkillsDir,f as getEveSubagentSkillsDir,m as getInstallPath,r as installBlobSkillForAgent,p as installRemoteSkillForAgent,h as installSkillForAgent,q as installWellKnownSkillForAgent,k as isSkillInstalled,s as listInstalledSkills,d as sanitizeName}from'./chunks/chunk-4D5RQDWJ.mjs';import {n,A as A$1}from'./chunks/chunk-5W7HC7BY.mjs';export{f as DEFAULT_CLONE_TIMEOUT,g as GitCloneError,m as WellKnownProvider,Q as acquireSourceClone,v as addSkillToLocalLock,ja as cleanCache,ia as cleanCachedRepo,l as cleanupTempDir,k as cloneRepo,A as discoverSkills,ca as ensureCachedSource,C as filterSkills,P as getCacheRepoDir,N as getCacheRoot,r as getLocalLockPath,a as getOwnerRepo,B as getSkillDisplayName,I as getSourceDir,ha as installFromCache,i as isGitHubHttpsCloneUrl,j as isGitHubSsoAuthError,c as isRepoPrivate,z as isSubpathSafe,h as parseGitHubRepoUrl,b as parseOwnerRepo,y as parseSkillMd,e as parseSource,t as readLocalLock,w as removeSkillFromLocalLock,d as sanitizeSubpath,x as shouldInstallInternalSkills,n as wellKnownProvider,u as writeLocalLock}from'./chunks/chunk-5W7HC7BY.mjs';export{e as EVE_SUBAGENTS_DIR,j as PROJECT_SKILLS_DIR_PATTERN,b as agents,c as detectInstalledAgents,d as getAgentConfig,l as getAgentGlobalSkillDirs,n as getAgentProjectSkillContainerPrefixes,k as getAgentProjectSkillDirs,m as getAgentSkillDirs,f as getEveSubagents,i as getNonUniversalAgents,a as getOpenClawGlobalSkillsDir,h as getUniversalAgents,o as isUniversalAgent,g as matchesUniversalScope}from'./chunks/chunk-ML6B4IQL.mjs';export{h as getAgentAdapter,c as getGlobal,k as getHomeDir,f as getInstance,p as getProjectDirectory,o as getXdgCache,l as getXdgConfig,m as getXdgData,n as getXdgState,i as hasAgentAdapter,j as requireAgentAdapter,b as resetGlobalAdapter,e as resetInstanceAdapter,g as setAgentAdapter,a as setGlobalAdapter,d as setInstanceAdapter}from'./chunks/chunk-RWZ4LFSN.mjs';export{c as BLOB_ALLOWED_REPOS,g as fetchRepoTree,k as findSkillMdPaths,i as getSkillFolderHashFromTree,f as resetRepoTreeAuthState,b as sanitizeMetadata,a as stripTerminalEscapes,e as toSkillSlug,l as tryBlobInstall}from'./chunks/chunk-ROCFLAYZ.mjs';export{b as computeFromDir,c as computeSnapshotHash,a as parseFrontmatter}from'./chunks/chunk-ZYDDQV73.mjs';import {b}from'./chunks/chunk-WQGSYA5D.mjs';import {join}from'path';var d=class{constructor(){b(this,"providers",[]);}register(o){if(this.providers.some(t=>t.id===o.id))throw new Error(`Provider with id "${o.id}" already registered`);this.providers.push(o);}findProvider(o){for(let t of this.providers)if(t.match(o).matches)return t;return null}getProviders(){return [...this.providers]}},p=new d;function ct(e){p.register(e);}function ut(e){return p.findProvider(e)}function pt(){return p.getProviders()}var u=new Map;function k(e){if(u.has(e.id))throw new Error(`PluginSource with id "${e.id}" already registered`);u.set(e.id,e);}function S(){return Array.from(u.values()).map(e=>e)}function P(e){return u.get(e)??null}function y(e){return Array.from(u.values()).filter(o=>o.category===e)}async function x(){let e=S();return await Promise.all(e.map(async t=>{try{let r=await t.fetch();return {sourceId:t.id,entries:r}}catch(r){return {sourceId:t.id,error:r instanceof Error?r:new Error(String(r))}}}))}function gt(e){return {name:e.name,description:e.description,scope:"all"}}function h(e){return {id:e.id??`well-known:${new URL(e.url).hostname}`,category:"well-known",async fetch(){return (await n.fetchAllSkills(e.url)).map(r=>({id:r.name,name:r.name,description:r.description,location:r.sourceUrl,category:"well-known",metadata:{installName:r.installName,sourceIdentifier:n.getSourceIdentifier(e.url),sourceUrl:r.sourceUrl}}))},async load(t){let l=(await n.fetchAllSkills(e.url)).find(n=>n.name===t.id);if(!l)throw new Error(`Skill "${t.id}" not found in well-known source ${e.url}`);return {skills:[gt(l)],version:"well-known",author:{name:new URL(e.url).hostname}}}}}async function A(e){try{let t=await(await import('fs/promises')).readFile(e,"utf-8");return JSON.parse(t)}catch{return null}}function w(e){let o=e.basePath.split(/[\\/]/).filter(Boolean).pop()??"local";return {id:e.id??`local:${o}`,category:"file",async fetch(){let r=[],l=await A(join(e.basePath,".claude-plugin/plugin.json"));l?.name&&r.push({id:l.name,name:l.name,description:l.description,location:e.basePath,category:"file",metadata:{skills:l.skills,manifest:"plugin.json"}});let n=await A(join(e.basePath,".claude-plugin/marketplace.json"));if(n?.plugins)for(let i of n.plugins)i.name&&(typeof i.source!="string"&&i.source!==void 0||r.push({id:i.name,name:i.name,description:i.description,location:i.source?join(e.basePath,n.metadata?.pluginRoot??"",i.source):e.basePath,category:"file",metadata:{skills:i.skills,manifest:"marketplace.json",pluginRoot:n.metadata?.pluginRoot}}));return r},async load(r){return {skills:(await A$1(r.location)).map(i=>({name:i.name,description:i.description,scope:"all"})),version:"local",author:{name:o}}}}}export{w as createLocalPluginSource,h as createWellKnownSource,ut as findProvider,P as findSource,y as findSourcesByCategory,pt as getProviders,x as listAllEntries,S as listSources,ct as registerProvider,k as registerSource,p as registry};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@easbot/skills",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.13",
|
|
4
4
|
"description": "Skills management system for EAS Agent ecosystem (add / remove / list / find / update / sync / use)",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.cjs",
|
|
@@ -47,16 +47,15 @@
|
|
|
47
47
|
"LICENSE"
|
|
48
48
|
],
|
|
49
49
|
"dependencies": {
|
|
50
|
-
"@vercel/detect-agent": "^1.2.3",
|
|
51
50
|
"@clack/prompts": "^1.7.0",
|
|
52
51
|
"picocolors": "^1.1.1",
|
|
53
52
|
"simple-git": "^3.36.0",
|
|
54
53
|
"xdg-basedir": "^5.1.0",
|
|
55
54
|
"yaml": "^2.9.0",
|
|
56
55
|
"zod": "^4.4.3",
|
|
57
|
-
"@easbot/utils": "0.3.
|
|
58
|
-
"@easbot/types": "0.3.
|
|
59
|
-
"@easbot/mcp": "0.3.
|
|
56
|
+
"@easbot/utils": "0.3.13",
|
|
57
|
+
"@easbot/types": "0.3.13",
|
|
58
|
+
"@easbot/mcp": "0.3.13"
|
|
60
59
|
},
|
|
61
60
|
"devDependencies": {
|
|
62
61
|
"@types/node": "^25.6.2",
|