blade-code 0.10.117 → 0.10.118

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (41) hide show
  1. package/dist/blade.js +2 -2
  2. package/dist/{chunk-hy20r5ze.js → chunk-1w74gwns.js} +1 -1
  3. package/dist/{chunk-jcxpq57d.js → chunk-2aysvx6k.js} +1 -1
  4. package/dist/{chunk-0msthyzv.js → chunk-53aapkv1.js} +1 -1
  5. package/dist/chunk-5j419kbp.js +1 -0
  6. package/dist/{chunk-bh7bswhj.js → chunk-74m1zc1r.js} +1 -1
  7. package/dist/{chunk-1tshkx4p.js → chunk-90q4206c.js} +1 -1
  8. package/dist/{chunk-bp4s6mbz.js → chunk-9aqs02va.js} +4 -4
  9. package/dist/{chunk-b1w2mtq8.js → chunk-9n9506vy.js} +1 -1
  10. package/dist/chunk-bpz7a5yn.js +1 -0
  11. package/dist/{chunk-fgmwse2v.js → chunk-bxjc7pg7.js} +1 -1
  12. package/dist/{chunk-53rm14qc.js → chunk-c5wrmq2e.js} +1 -1
  13. package/dist/{chunk-ymcekh5x.js → chunk-cxbrqnqs.js} +1 -1
  14. package/dist/{chunk-n9ws6dzb.js → chunk-fys5xx87.js} +3 -3
  15. package/dist/{chunk-gmcwgmnr.js → chunk-gbjk078c.js} +1 -1
  16. package/dist/{chunk-c3evbzpa.js → chunk-gjw8100g.js} +1 -1
  17. package/dist/{chunk-vpz847k8.js → chunk-j3cmytrt.js} +1 -1
  18. package/dist/{chunk-erqfqfcj.js → chunk-jdm0jffr.js} +1 -1
  19. package/dist/{chunk-yxg6xbr1.js → chunk-jhsdden6.js} +1 -1
  20. package/dist/{chunk-yt629r3s.js → chunk-k3tqna1w.js} +1 -1
  21. package/dist/{chunk-khtbjdf7.js → chunk-kbkdhvk7.js} +1 -1
  22. package/dist/{chunk-y9vh6qxz.js → chunk-kk6rg27n.js} +1 -1
  23. package/dist/{chunk-k5nfe6pe.js → chunk-kr8rv2b9.js} +1 -1
  24. package/dist/{chunk-zbkr8pvx.js → chunk-m56bj6c6.js} +1 -1
  25. package/dist/{chunk-c3mdtd39.js → chunk-mdczqnc0.js} +1 -1
  26. package/dist/{chunk-1dttmp46.js → chunk-mnkdxt1v.js} +1 -1
  27. package/dist/{chunk-rsc9mwdw.js → chunk-nbhgg5p2.js} +1 -1
  28. package/dist/{chunk-ttv1n12k.js → chunk-nha6m2tx.js} +1 -1
  29. package/dist/{chunk-cz9mrg18.js → chunk-nyhqdpb6.js} +1 -1
  30. package/dist/{chunk-ae7bcbmy.js → chunk-qw4hh3sv.js} +1 -1
  31. package/dist/{chunk-3fsr03k4.js → chunk-scc9kbd1.js} +1 -1
  32. package/dist/{chunk-6rj0ek81.js → chunk-swtap0bs.js} +1 -1
  33. package/dist/{chunk-j0pjrq3v.js → chunk-vnbsq6ps.js} +2 -2
  34. package/dist/{chunk-2gcwzk6m.js → chunk-y1msyved.js} +1 -1
  35. package/dist/{chunk-4cq70wxs.js → chunk-y21nw7g1.js} +1 -1
  36. package/dist/{chunk-psatd34r.js → chunk-yqygarpr.js} +1 -1
  37. package/dist/{chunk-b54vham2.js → chunk-z8xgk0m6.js} +1 -1
  38. package/dist/{chunk-5dgnnf3n.js → chunk-z9g2x0vm.js} +1 -1
  39. package/package.json +1 -1
  40. package/dist/chunk-8p475et7.js +0 -1
  41. package/dist/chunk-97qjsb8n.js +0 -1
@@ -1,4 +1,4 @@
1
- import{$b as En,_b as Xt,ac as yn,bc as bn}from"./chunk-cnhw5mqv.js";import{tg as Bt}from"./chunk-6rj0ek81.js";import{Ag as sn,Bg as zt,Cg as U,Dg as en,Eg as gt,Fg as mt,Hg as rn,Ig as Tn,Jg as B,Kg as dn,Lg as on,Mg as pn,Ng as lt,Og as un,Pg as cn,Qg as Mn,Sg as S,Vg as wn,Wg as Gt,Xg as Ut,Yg as h,Zg as Ht,yg as xt,zg as vi}from"./chunk-4cq70wxs.js";import{Eh as X,Gh as x}from"./chunk-6k5k40p8.js";import{Sh as It}from"./chunk-ecd727xh.js";import{Gi as tn,Hi as nn}from"./chunk-0msthyzv.js";import{_i as ns}from"./chunk-tf7ezqew.js";import{EventEmitter as fs}from"events";import Un from"node:path";function hn(t){if(t===void 0)return"undefined";if(typeof t==="string")return t;try{let i=JSON.stringify(t);return i===void 0?String(t):i}catch{return String(t)}}function An(t){let i=t;switch(t.code){case"type":return`类型错误:${t.message}`;case"required":return"缺少必需参数";case"minLength":return`字符串过短:${t.message}`;case"maxLength":return`字符串过长:${t.message}`;case"minimum":case"exclusiveMinimum":return`数值太小:${t.message}`;case"maximum":case"exclusiveMaximum":return`数值太大:${t.message}`;case"minItems":return`数组元素过少:${t.message}`;case"maxItems":return`数组元素过多:${t.message}`;case"format":return`格式错误:${t.message}`;case"enum":return`必须是枚举允许的值之一:${t.message}`;case"const":return`必须是指定的字面量值:${t.message}`;case"additionalProperties":case"unevaluatedProperties":return`包含未知参数:${t.message}`;case"anyOf":case"oneOf":return"不符合任何有效的类型定义";case"~refine":return t.message||"自定义验证失败";default:return t.message||`验证失败:${hn(i)}`}}class Jt extends Error{issues;type;constructor(t,i,n="validation_error"){super(t);this.issues=i;this.type=n;this.name="ToolValidationError"}}function Vt(t,i){let n=X(t,i);if(n.success)return n.data;let s=n.error.issues.map((r)=>({field:r.path.length>0?r.path.join("."):"root",message:An(r),value:r.value})),e=s.length===1?`参数验证失败 [${s[0].field}]: ${s[0].message}`:`参数验证失败 (${s.length} 个错误):
1
+ import{$b as En,_b as Xt,ac as yn,bc as bn}from"./chunk-cnhw5mqv.js";import{tg as Bt}from"./chunk-swtap0bs.js";import{Ag as sn,Bg as zt,Cg as U,Dg as en,Eg as gt,Fg as mt,Hg as rn,Ig as Tn,Jg as B,Kg as dn,Lg as on,Mg as pn,Ng as lt,Og as un,Pg as cn,Qg as Mn,Sg as S,Vg as wn,Wg as Gt,Xg as Ut,Yg as h,Zg as Ht,yg as xt,zg as vi}from"./chunk-y21nw7g1.js";import{Eh as X,Gh as x}from"./chunk-6k5k40p8.js";import{Sh as It}from"./chunk-ecd727xh.js";import{Gi as tn,Hi as nn}from"./chunk-53aapkv1.js";import{_i as ns}from"./chunk-tf7ezqew.js";import{EventEmitter as fs}from"events";import Un from"node:path";function hn(t){if(t===void 0)return"undefined";if(typeof t==="string")return t;try{let i=JSON.stringify(t);return i===void 0?String(t):i}catch{return String(t)}}function An(t){let i=t;switch(t.code){case"type":return`类型错误:${t.message}`;case"required":return"缺少必需参数";case"minLength":return`字符串过短:${t.message}`;case"maxLength":return`字符串过长:${t.message}`;case"minimum":case"exclusiveMinimum":return`数值太小:${t.message}`;case"maximum":case"exclusiveMaximum":return`数值太大:${t.message}`;case"minItems":return`数组元素过少:${t.message}`;case"maxItems":return`数组元素过多:${t.message}`;case"format":return`格式错误:${t.message}`;case"enum":return`必须是枚举允许的值之一:${t.message}`;case"const":return`必须是指定的字面量值:${t.message}`;case"additionalProperties":case"unevaluatedProperties":return`包含未知参数:${t.message}`;case"anyOf":case"oneOf":return"不符合任何有效的类型定义";case"~refine":return t.message||"自定义验证失败";default:return t.message||`验证失败:${hn(i)}`}}class Jt extends Error{issues;type;constructor(t,i,n="validation_error"){super(t);this.issues=i;this.type=n;this.name="ToolValidationError"}}function Vt(t,i){let n=X(t,i);if(n.success)return n.data;let s=n.error.issues.map((r)=>({field:r.path.length>0?r.path.join("."):"root",message:An(r),value:r.value})),e=s.length===1?`参数验证失败 [${s[0].field}]: ${s[0].message}`:`参数验证失败 (${s.length} 个错误):
2
2
  ${s.map((r)=>` - ${r.field}: ${r.message}`).join(`
3
3
  `)}`;throw new Jt(e,s)}function st(t){if(!t||typeof t!=="object")return;let i=t;if(i.type==="object"&&i.properties)i.required??=[],i.additionalProperties??=!1;for(let n of Object.values(i))if(Array.isArray(n))for(let s of n)st(s);else st(n)}function et(t){let i=JSON.parse(JSON.stringify(t,(n,s)=>n.startsWith("~")?void 0:s));return st(i),i}class rt{toolName;params;executeFn;descriptionFn;affectedPathsFn;isRetrySafe;constructor(t,i,n,s,e,r=!1){this.toolName=t;this.params=i;this.executeFn=n;this.descriptionFn=s;this.affectedPathsFn=e;this.isRetrySafe=r}getDescription(){if(this.descriptionFn)return this.descriptionFn(this.params);return`执行工具: ${this.toolName}`}getAffectedPaths(){if(this.affectedPathsFn)return this.affectedPathsFn(this.params);return[]}async execute(t,i,n){let s={signal:t,updateOutput:i,...n};return this.executeFn(this.params,s)}}function jt(t){return{name:t.name,displayName:t.displayName,kind:t.kind,isConcurrencySafe:t.isConcurrencySafe??!1,isRetrySafe:t.isRetrySafe??!1,parallelism:t.parallelism??(t.isConcurrencySafe?"shared":"exclusive"),strict:t.strict??!1,description:t.description,version:t.version||"1.0.0",category:t.category,tags:t.tags||[],getFunctionDeclaration(){let i=et(t.schema),n=t.description.short;if(t.description.long)n+=`
4
4
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "blade-code",
3
- "version": "0.10.117",
3
+ "version": "0.10.118",
4
4
  "private": false,
5
5
  "description": "🗡️ Blade Code - 智能代码助手命令行工具",
6
6
  "type": "module",
@@ -1 +0,0 @@
1
- import{h as a,i as b,j as c,k as d,l as e}from"./chunk-y9vh6qxz.js";import"./chunk-0msthyzv.js";import"./chunk-tf7ezqew.js";export{b as setSkipUntilVersion,d as performUpgrade,c as getUpgradeCommand,e as checkVersionOnStartup,a as checkVersion};
@@ -1 +0,0 @@
1
- import{re as a,se as b}from"./chunk-hy20r5ze.js";import"./chunk-0msthyzv.js";import"./chunk-tf7ezqew.js";export{a as globalOptions,b as cliConfig};