@bangdao-ai/acw-tools 1.7.3 → 1.8.0-beta.2

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/manifest.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "ACW工具集",
3
3
  "description": "ACW平台工具集:智能下载规则/技能到项目、上传技能到Skills广场、搜索技能、检查技能更新",
4
- "version": "1.7.3",
4
+ "version": "1.8.0",
5
5
  "author": "邦道科技 - 产品技术中心",
6
6
  "homepage": "https://www.npmjs.com/package/@bangdao-ai/acw-tools",
7
7
  "repository": "https://www.npmjs.com/package/@bangdao-ai/acw-tools?activeTab=readme",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bangdao-ai/acw-tools",
3
- "version": "1.7.3",
3
+ "version": "1.8.0-beta.2",
4
4
  "type": "module",
5
5
  "description": "MCP (Model Context Protocol) tools for ACW - download rules and initialize Common Admin projects",
6
6
  "main": "index.js",
package/postinstall.js CHANGED
@@ -1,2 +1,2 @@
1
1
  #!/usr/bin/env node
2
- const _0x59e891=_0x1dd7;(function(_0x3dee9d,_0x4d96d7){const _0x42f147=_0x1dd7,_0x309cee=_0x3dee9d();while(!![]){try{const _0x2f1bdf=-parseInt(_0x42f147(0x11d))/0x1*(-parseInt(_0x42f147(0xdb))/0x2)+-parseInt(_0x42f147(0xe0))/0x3+-parseInt(_0x42f147(0xf8))/0x4+parseInt(_0x42f147(0xe8))/0x5+parseInt(_0x42f147(0x101))/0x6+parseInt(_0x42f147(0x11c))/0x7*(-parseInt(_0x42f147(0xee))/0x8)+-parseInt(_0x42f147(0x105))/0x9;if(_0x2f1bdf===_0x4d96d7)break;else _0x309cee['push'](_0x309cee['shift']());}catch(_0x5102f3){_0x309cee['push'](_0x309cee['shift']());}}}(_0x5b3c,0xdbe8d));function _0x5b3c(){const _0x23d776=['versions','win32','parse','━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━','未知错误','-node-v','3530895yoeIRL','[INFO]\x20Node.js\x20','default','darwin','[OK]\x20better-sqlite3\x20加载成功','better-sqlite3-v','1160qMEcnL','https://bd-acw.oss-cn-beijing.aliyuncs.com/prebuilds/better-sqlite3','toString','headers','push','trim','[WARN]\x20OSS\x20预编译包下载失败:\x20','existsSync','warn','\x20(ABI\x20','2004936NgoGQb','\x20(ABI\x20v','我的\x20ACW\x20MCP\x20工具安装失败,better-sqlite3\x20模块加载失败,错误信息:','basename','message','platform','[INFO]\x20预编译包已安装到:\x20','fromCharCode','cwd','10691976YRhjMy','[INFO]\x20建议升级到\x20Node.js\x2020/22/23/24\x20以获得最佳兼容性','node_modules','131','786429MEpfWY','writeFileSync','then','exit','replace','error','catch','slice','destroy','[ERROR]\x20postinstall\x20脚本执行出错:','location','dirname','。请帮我在终端执行以下命令修复:1)\x20xcode-select\x20--install\x20安装编译工具;2)\x20npm\x20cache\x20clean\x20--force\x20清除缓存;3)\x20npm\x20install\x20-g\x20@bangdao-ai/acw-tools\x20重新安装。','statusCode','[OK]\x20安装完成','arch','package.json','utf8','was\x20compiled\x20against','end','join','[INFO]\x20better-sqlite3\x20原生加载失败:\x20','log','10031pVIdTW','61DeShlo','better-sqlite3','复制以下提示词发送给\x20Cursor,让\x20AI\x20帮你修复:','unknown','concat','version','4478Zpfzdl','NODE_MODULE_VERSION','108','[INFO]\x20尝试从\x20OSS\x20下载预编译包:\x20','modules','2782815cYYHSD','readFileSync'];_0x5b3c=function(){return _0x23d776;};return _0x5b3c();}import _0x57a01a from'fs';import _0x2fded3 from'path';import{fileURLToPath as _0x567b94}from'url';import{execSync as _0x49b994}from'child_process';import _0x208bd0 from'https';import _0x366eec from'http';import _0x5ca1b4 from'zlib';var h='12.4.1',N=_0x59e891(0xef),I={0x12:_0x59e891(0xdd),0x13:'111',0x14:'115',0x15:'120',0x16:'127',0x17:_0x59e891(0x104),0x18:'137',0x19:'137'},q=['115','127',_0x59e891(0x104),'137'];function u(){const _0x153331=_0x59e891;let _0xe975fd=parseInt(process['version']['slice'](0x1)['split']('.')[0x0],0xa);return I[_0xe975fd]||process[_0x153331(0xe2)][_0x153331(0xdf)];}function E(){const _0x5f4535=_0x59e891;let _0x3f30fc=h,_0x4bdf48=u(),_0x578024=process['platform'],_0x3dfadd=process[_0x5f4535(0x114)];return _0x5f4535(0xed)+_0x3f30fc+_0x5f4535(0xe7)+_0x4bdf48+'-'+_0x578024+'-'+_0x3dfadd+'.tar.gz';}function b(_0x3ab7c3){return new Promise((_0x5c0122,_0x3fb1a8)=>{const _0x2ef06a=_0x1dd7;let _0x17b86a=(_0x3ab7c3['startsWith']('https')?_0x208bd0:_0x366eec)['get'](_0x3ab7c3,{'timeout':0x7530},_0xb5abda=>{const _0x23c9f3=_0x1dd7;if(_0xb5abda['statusCode']===0x12d||_0xb5abda[_0x23c9f3(0x112)]===0x12e){b(_0xb5abda[_0x23c9f3(0xf1)][_0x23c9f3(0x10f)])[_0x23c9f3(0x107)](_0x5c0122)[_0x23c9f3(0x10b)](_0x3fb1a8);return;}if(_0xb5abda['statusCode']!==0xc8){_0x3fb1a8(new Error('HTTP\x20'+_0xb5abda[_0x23c9f3(0x112)]));return;}let _0x31adc2=[];_0xb5abda['on']('data',_0x2fa552=>_0x31adc2[_0x23c9f3(0xf2)](_0x2fa552)),_0xb5abda['on'](_0x23c9f3(0x118),()=>_0x5c0122(Buffer[_0x23c9f3(0xd9)](_0x31adc2))),_0xb5abda['on'](_0x23c9f3(0x10a),_0x3fb1a8);});_0x17b86a['on'](_0x2ef06a(0x10a),_0x3fb1a8),_0x17b86a['on']('timeout',()=>{const _0x131c32=_0x2ef06a;_0x17b86a[_0x131c32(0x10d)](),_0x3fb1a8(new Error('Request\x20timeout'));});});}async function P(_0xc6279,_0x4b64ba){const _0x1956cd=_0x59e891;let _0x1ee1c7=_0x5ca1b4['gunzipSync'](_0xc6279),_0x217648=0x200,_0x43f422=0x0;for(;_0x43f422<_0x1ee1c7['length']-_0x217648;){let _0x42d49e=_0x1ee1c7['slice'](_0x43f422,_0x43f422+_0x217648);if(_0x42d49e[0x0]===0x0)break;let _0x426581=_0x42d49e['slice'](0x0,0x64)['toString'](_0x1956cd(0x116))['replace'](/\0/g,'')['trim'](),_0x9f1065=_0x42d49e['slice'](0x7c,0x88)[_0x1956cd(0xf0)]('utf8')[_0x1956cd(0x109)](/\0/g,'')[_0x1956cd(0xf3)](),_0x1439b0=parseInt(_0x9f1065,0x8)||0x0,_0xe7b3a6=String[_0x1956cd(0xff)](_0x42d49e[0x9c]);if(_0x43f422+=_0x217648,_0x426581&&_0xe7b3a6==='0'||_0xe7b3a6==='\x00'){let _0x54d5bc=_0x1ee1c7[_0x1956cd(0x10c)](_0x43f422,_0x43f422+_0x1439b0),_0x49f63a=_0x2fded3[_0x1956cd(0x119)](_0x4b64ba,_0x2fded3[_0x1956cd(0xfb)](_0x426581));_0x57a01a['mkdirSync'](_0x2fded3['dirname'](_0x49f63a),{'recursive':!0x0}),_0x57a01a[_0x1956cd(0x106)](_0x49f63a,_0x54d5bc);}_0x43f422+=Math['ceil'](_0x1439b0/_0x217648)*_0x217648;}}function d(){const _0x5392e2=_0x59e891;let _0x285d61=[_0x2fded3['join'](process[_0x5392e2(0x100)](),_0x5392e2(0x103),'better-sqlite3'),_0x2fded3[_0x5392e2(0x119)](_0x567b94(import.meta.url),'..','node_modules','better-sqlite3')];try{let _0x46dbc4=import.meta.resolve('better-sqlite3');if(_0x46dbc4){let _0x2c1c60=_0x567b94(_0x46dbc4);_0x285d61['unshift'](_0x2fded3[_0x5392e2(0x110)](_0x2fded3[_0x5392e2(0x110)](_0x2c1c60)));}}catch{}for(let _0x4541b1 of _0x285d61)if(_0x57a01a[_0x5392e2(0xf5)](_0x2fded3['join'](_0x4541b1,'package.json')))return _0x4541b1;return null;}async function _(){const _0x294c25=_0x59e891;let _0x31faee=E(),_0x3c4a74=N+'/v'+h+'/'+_0x31faee;console['log'](_0x294c25(0xde)+_0x31faee);let _0x43d629=await b(_0x3c4a74);console['log']('[INFO]\x20下载成功\x20('+(_0x43d629['length']/0x400)['toFixed'](0x1)+'\x20KB)');let _0x613c69=d();if(!_0x613c69)throw new Error('无法找到\x20better-sqlite3\x20模块路径');let _0x46d576=_0x2fded3['join'](_0x613c69,'prebuilds',process['platform']+'-'+process[_0x294c25(0x114)]);return _0x57a01a['mkdirSync'](_0x46d576,{'recursive':!0x0}),await P(_0x43d629,_0x46d576),console['log'](_0x294c25(0xfe)+_0x46d576),!0x0;}function _0x1dd7(_0x173989,_0x340100){_0x173989=_0x173989-0xd8;const _0x5b3c2e=_0x5b3c();let _0x1dd7d9=_0x5b3c2e[_0x173989];return _0x1dd7d9;}async function v(){const _0x5995b2=_0x59e891;let _0x1ff8e1=(await import(_0x5995b2(0x11e)))[_0x5995b2(0xea)];return new _0x1ff8e1(':memory:')['close'](),!0x0;}((async()=>{const _0x44679e=_0x59e891;try{let _0x2a26be=_0x567b94(import.meta.url),_0x23237d=_0x2fded3['dirname'](_0x2a26be),_0x255b16=_0x44679e(0xd8);try{let _0xd3bd1f=_0x2fded3[_0x44679e(0x119)](_0x23237d,_0x44679e(0x115));_0x57a01a['existsSync'](_0xd3bd1f)&&(_0x255b16=JSON[_0x44679e(0xe4)](_0x57a01a[_0x44679e(0xe1)](_0xd3bd1f,'utf8'))['version']||'unknown');}catch{}console[_0x44679e(0x11b)]('ACW\x20Tools\x20MCP\x20安装后检查...'),console[_0x44679e(0x11b)]('v'+_0x255b16+'\x20|\x20Node\x20'+process[_0x44679e(0xda)]+_0x44679e(0xf7)+u()+')\x20|\x20'+process[_0x44679e(0xfd)]+'/'+process[_0x44679e(0x114)]);let _0x495e0d=!0x1,_0x10f289=null;try{await v(),console[_0x44679e(0x11b)](_0x44679e(0xec)),_0x495e0d=!0x0;}catch(_0x59e90c){if(_0x10f289=_0x59e90c,console['log'](_0x44679e(0x11a)+_0x59e90c['message']),_0x59e90c[_0x44679e(0xfc)]['includes'](_0x44679e(0xdc))||_0x59e90c['message']['includes'](_0x44679e(0x117))){let _0x356b5c=u();q['includes'](_0x356b5c)||(console['log'](_0x44679e(0xe9)+process[_0x44679e(0xda)]+_0x44679e(0xf9)+_0x356b5c+')\x20没有预编译包,需要本地编译'),console[_0x44679e(0x11b)](_0x44679e(0x102))),console['log']('[INFO]\x20检测到\x20Node.js\x20版本不匹配,尝试修复...');try{await _(),console['log']('[INFO]\x20预编译包已安装,重新测试...');try{_0x49b994('node\x20-e\x20\x22require(\x27better-sqlite3\x27)(\x27:memory:\x27).close()\x22',{'cwd':d()?_0x2fded3[_0x44679e(0x110)](d()):process[_0x44679e(0x100)](),'stdio':'pipe','env':{...process['env']}}),console[_0x44679e(0x11b)]('[OK]\x20better-sqlite3\x20修复成功!'),_0x495e0d=!0x0;}catch(_0x1e4471){console[_0x44679e(0xf6)]('[WARN]\x20预编译包安装后测试失败:\x20'+_0x1e4471[_0x44679e(0xfc)]);}}catch(_0x402f96){console[_0x44679e(0xf6)](_0x44679e(0xf4)+_0x402f96[_0x44679e(0xfc)]);}}}if(!_0x495e0d){let _0x535168=_0x10f289?.[_0x44679e(0xfc)]||_0x44679e(0xe6);console['error'](''),console[_0x44679e(0x10a)]('━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━'),console['error']('[ERROR]\x20better-sqlite3\x20模块加载失败,安装中止'),console[_0x44679e(0x10a)]('━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━'),console[_0x44679e(0x10a)](''),console['error']('错误信息:\x20'+_0x535168),console[_0x44679e(0x10a)](''),console[_0x44679e(0x10a)](_0x44679e(0x11f)),console[_0x44679e(0x10a)](''),process['platform']===_0x44679e(0xe3)?console[_0x44679e(0x10a)](_0x44679e(0xfa)+_0x535168+'。请帮我在终端执行以下命令修复:1)\x20以管理员身份运行\x20npm\x20install\x20--global\x20windows-build-tools\x20安装编译工具;2)\x20npm\x20cache\x20clean\x20--force\x20清除缓存;3)\x20npm\x20install\x20-g\x20@bangdao-ai/acw-tools\x20重新安装。'):process[_0x44679e(0xfd)]===_0x44679e(0xeb)?console[_0x44679e(0x10a)]('我的\x20ACW\x20MCP\x20工具安装失败,better-sqlite3\x20模块加载失败,错误信息:'+_0x535168+_0x44679e(0x111)):console['error']('我的\x20ACW\x20MCP\x20工具安装失败,better-sqlite3\x20模块加载失败,错误信息:'+_0x535168+'。请帮我在终端执行以下命令修复:1)\x20sudo\x20apt-get\x20install\x20build-essential\x20python3\x20安装编译工具;2)\x20npm\x20cache\x20clean\x20--force\x20清除缓存;3)\x20npm\x20install\x20-g\x20@bangdao-ai/acw-tools\x20重新安装。'),console[_0x44679e(0x10a)](''),console[_0x44679e(0x10a)](_0x44679e(0xe5)),process['exit'](0x1);}console[_0x44679e(0x11b)](_0x44679e(0x113));}catch(_0x27495d){console['error'](_0x44679e(0x10e),_0x27495d[_0x44679e(0xfc)]),process[_0x44679e(0x108)](0x1);}})());
2
+ const _0x212e4e=_0x4633;(function(_0x4f8552,_0x5c41bc){const _0x8468b0=_0x4633,_0x596d8c=_0x4f8552();while(!![]){try{const _0x44623=-parseInt(_0x8468b0(0xd0))/0x1+-parseInt(_0x8468b0(0xd4))/0x2+parseInt(_0x8468b0(0xe9))/0x3*(-parseInt(_0x8468b0(0xcc))/0x4)+-parseInt(_0x8468b0(0xf2))/0x5+parseInt(_0x8468b0(0xde))/0x6+-parseInt(_0x8468b0(0xc8))/0x7*(-parseInt(_0x8468b0(0x100))/0x8)+parseInt(_0x8468b0(0xd9))/0x9;if(_0x44623===_0x5c41bc)break;else _0x596d8c['push'](_0x596d8c['shift']());}catch(_0x3f4efd){_0x596d8c['push'](_0x596d8c['shift']());}}}(_0x1a85,0x5e068));import _0x39846d from'fs';import _0x5b984c from'path';import{fileURLToPath as _0x6313a}from'url';import{execSync as _0x4d9ec7}from'child_process';import _0xe73b9c from'https';import _0x26bff0 from'http';function _0x4633(_0x4edaf2,_0x18f6c5){_0x4edaf2=_0x4edaf2-0xc8;const _0x1a85a9=_0x1a85();let _0x4633b5=_0x1a85a9[_0x4edaf2];return _0x4633b5;}import _0x563cd6 from'zlib';var h='12.4.1',N=_0x212e4e(0xd1),I={0x12:_0x212e4e(0xd2),0x13:_0x212e4e(0xd3),0x14:_0x212e4e(0xff),0x15:'120',0x16:'127',0x17:_0x212e4e(0xf0),0x18:_0x212e4e(0xe6),0x19:'137'},q=['115',_0x212e4e(0xf5),_0x212e4e(0xf0),_0x212e4e(0xe6)];function u(){const _0x27e09d=_0x212e4e;let _0x135176=parseInt(process[_0x27e09d(0xce)]['slice'](0x1)[_0x27e09d(0xdc)]('.')[0x0],0xa);return I[_0x135176]||process['versions'][_0x27e09d(0xd8)];}function E(){const _0x403c3a=_0x212e4e;let _0x7d958a=h,_0x3626d4=u(),_0x17b93d=process['platform'],_0x3c464c=process[_0x403c3a(0xf6)];return'better-sqlite3-v'+_0x7d958a+'-node-v'+_0x3626d4+'-'+_0x17b93d+'-'+_0x3c464c+'.tar.gz';}function b(_0x2333ec){return new Promise((_0x57872b,_0x2d5c15)=>{const _0x4e60fa=_0x4633;let _0x467450=(_0x2333ec['startsWith']('https')?_0xe73b9c:_0x26bff0)['get'](_0x2333ec,{'timeout':0x7530},_0x47a984=>{const _0xb58414=_0x4633;if(_0x47a984[_0xb58414(0xdb)]===0x12d||_0x47a984['statusCode']===0x12e){b(_0x47a984['headers']['location'])['then'](_0x57872b)[_0xb58414(0x107)](_0x2d5c15);return;}if(_0x47a984[_0xb58414(0xdb)]!==0xc8){_0x2d5c15(new Error('HTTP\x20'+_0x47a984[_0xb58414(0xdb)]));return;}let _0x355f86=[];_0x47a984['on']('data',_0x2e6faf=>_0x355f86['push'](_0x2e6faf)),_0x47a984['on']('end',()=>_0x57872b(Buffer['concat'](_0x355f86))),_0x47a984['on']('error',_0x2d5c15);});_0x467450['on'](_0x4e60fa(0xcb),_0x2d5c15),_0x467450['on']('timeout',()=>{const _0x576b36=_0x4e60fa;_0x467450[_0x576b36(0xc9)](),_0x2d5c15(new Error(_0x576b36(0x101)));});});}async function P(_0x1cdc8c,_0x289d0c){const _0x2d5dc8=_0x212e4e;let _0x523bd9=_0x563cd6[_0x2d5dc8(0xef)](_0x1cdc8c),_0x45a7f8=0x200,_0x43e931=0x0;for(;_0x43e931<_0x523bd9['length']-_0x45a7f8;){let _0x1b3f95=_0x523bd9['slice'](_0x43e931,_0x43e931+_0x45a7f8);if(_0x1b3f95[0x0]===0x0)break;let _0x2677a1=_0x1b3f95['slice'](0x0,0x64)['toString'](_0x2d5dc8(0xcd))['replace'](/\0/g,'')['trim'](),_0x4b2014=_0x1b3f95[_0x2d5dc8(0xf7)](0x7c,0x88)[_0x2d5dc8(0xe5)]('utf8')[_0x2d5dc8(0xdf)](/\0/g,'')['trim'](),_0x44045d=parseInt(_0x4b2014,0x8)||0x0,_0x1c860d=String[_0x2d5dc8(0xdd)](_0x1b3f95[0x9c]);if(_0x43e931+=_0x45a7f8,_0x2677a1&&_0x1c860d==='0'||_0x1c860d==='\x00'){let _0x1c07cd=_0x523bd9['slice'](_0x43e931,_0x43e931+_0x44045d),_0x1a469f=_0x5b984c[_0x2d5dc8(0xe3)](_0x289d0c,_0x5b984c[_0x2d5dc8(0xfb)](_0x2677a1));_0x39846d[_0x2d5dc8(0xd7)](_0x5b984c['dirname'](_0x1a469f),{'recursive':!0x0}),_0x39846d[_0x2d5dc8(0xf9)](_0x1a469f,_0x1c07cd);}_0x43e931+=Math[_0x2d5dc8(0xda)](_0x44045d/_0x45a7f8)*_0x45a7f8;}}function d(){const _0xda7d80=_0x212e4e;let _0x18a6cd=[_0x5b984c[_0xda7d80(0xe3)](process['cwd'](),_0xda7d80(0x105),_0xda7d80(0x102)),_0x5b984c[_0xda7d80(0xe3)](_0x6313a(import.meta.url),'..','node_modules',_0xda7d80(0x102))];try{let _0xffb73c=import.meta.resolve('better-sqlite3');if(_0xffb73c){let _0xa455c0=_0x6313a(_0xffb73c);_0x18a6cd[_0xda7d80(0x10b)](_0x5b984c['dirname'](_0x5b984c['dirname'](_0xa455c0)));}}catch{}for(let _0x5f43d3 of _0x18a6cd)if(_0x39846d['existsSync'](_0x5b984c['join'](_0x5f43d3,'package.json')))return _0x5f43d3;return null;}async function _(){const _0x408ec6=_0x212e4e;let _0x572cd8=E(),_0x2af1f1=N+'/v'+h+'/'+_0x572cd8;console[_0x408ec6(0x10d)]('[INFO]\x20尝试从\x20OSS\x20下载预编译包:\x20'+_0x572cd8);let _0x4c358d=await b(_0x2af1f1);console['log']('[INFO]\x20下载成功\x20('+(_0x4c358d['length']/0x400)['toFixed'](0x1)+_0x408ec6(0xd5));let _0x15e4ea=d();if(!_0x15e4ea)throw new Error(_0x408ec6(0xeb));let _0x1e76a1=_0x5b984c[_0x408ec6(0xe3)](_0x15e4ea,_0x408ec6(0xcf),process[_0x408ec6(0x103)]+'-'+process[_0x408ec6(0xf6)]);return _0x39846d['mkdirSync'](_0x1e76a1,{'recursive':!0x0}),await P(_0x4c358d,_0x1e76a1),console[_0x408ec6(0x10d)](_0x408ec6(0x104)+_0x1e76a1),!0x0;}function _0x1a85(){const _0x53e3ae=['fromCharCode','1349832xlZDtr','replace','ACW\x20Tools\x20MCP\x20安装后检查...','[WARN]\x20预编译包安装后测试失败:\x20','错误信息:\x20','join','dirname','toString','137','NODE_MODULE_VERSION','includes','459izMzOj','。请帮我在终端执行以下命令修复:1)\x20sudo\x20apt-get\x20install\x20build-essential\x20python3\x20安装编译工具;2)\x20npm\x20cache\x20clean\x20--force\x20清除缓存;3)\x20npm\x20install\x20-g\x20@bangdao-ai/acw-tools\x20重新安装。','无法找到\x20better-sqlite3\x20模块路径','[INFO]\x20预编译包已安装,重新测试...','[WARN]\x20OSS\x20预编译包下载失败:\x20','pipe','gunzipSync','131','parse','287430DIogkV','exit','win32','127','arch','slice','[INFO]\x20检测到\x20Node.js\x20版本不匹配,尝试修复...','writeFileSync','━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━','basename',')\x20|\x20','message','。请帮我在终端执行以下命令修复:1)\x20以管理员身份运行\x20npm\x20install\x20--global\x20windows-build-tools\x20安装编译工具;2)\x20npm\x20cache\x20clean\x20--force\x20清除缓存;3)\x20npm\x20install\x20-g\x20@bangdao-ai/acw-tools\x20重新安装。','115','1072VdETuX','Request\x20timeout','better-sqlite3','platform','[INFO]\x20预编译包已安装到:\x20','node_modules','。请帮我在终端执行以下命令修复:1)\x20xcode-select\x20--install\x20安装编译工具;2)\x20npm\x20cache\x20clean\x20--force\x20清除缓存;3)\x20npm\x20install\x20-g\x20@bangdao-ai/acw-tools\x20重新安装。','catch','未知错误','existsSync','我的\x20ACW\x20MCP\x20工具安装失败,better-sqlite3\x20模块加载失败,错误信息:','unshift','close','log','19012sCscPC','destroy','env','error','14708pOUxzS','utf8','version','prebuilds','212074LLweEv','https://bd-acw.oss-cn-beijing.aliyuncs.com/prebuilds/better-sqlite3','108','111','906276tGitbh','\x20KB)','node\x20-e\x20\x22require(\x27better-sqlite3\x27)(\x27:memory:\x27).close()\x22','mkdirSync','modules','9733419ulIvih','ceil','statusCode','split'];_0x1a85=function(){return _0x53e3ae;};return _0x1a85();}async function v(){const _0x4633c9=_0x212e4e;let _0x591b16=(await import(_0x4633c9(0x102)))['default'];return new _0x591b16(':memory:')[_0x4633c9(0x10c)](),!0x0;}((async()=>{const _0x12b702=_0x212e4e;try{let _0x51be1e=_0x6313a(import.meta.url),_0xebd16c=_0x5b984c[_0x12b702(0xe4)](_0x51be1e),_0x2513f2='unknown';try{let _0x35aaed=_0x5b984c['join'](_0xebd16c,'package.json');_0x39846d[_0x12b702(0x109)](_0x35aaed)&&(_0x2513f2=JSON[_0x12b702(0xf1)](_0x39846d['readFileSync'](_0x35aaed,'utf8'))[_0x12b702(0xce)]||'unknown');}catch{}console[_0x12b702(0x10d)](_0x12b702(0xe0)),console['log']('v'+_0x2513f2+'\x20|\x20Node\x20'+process[_0x12b702(0xce)]+'\x20(ABI\x20'+u()+_0x12b702(0xfc)+process[_0x12b702(0x103)]+'/'+process[_0x12b702(0xf6)]);let _0x16f5d2=!0x1,_0x5a7ce5=null;try{await v(),console[_0x12b702(0x10d)]('[OK]\x20better-sqlite3\x20加载成功'),_0x16f5d2=!0x0;}catch(_0x2e0566){if(_0x5a7ce5=_0x2e0566,console[_0x12b702(0x10d)]('[INFO]\x20better-sqlite3\x20原生加载失败:\x20'+_0x2e0566['message']),_0x2e0566[_0x12b702(0xfd)]['includes'](_0x12b702(0xe7))||_0x2e0566[_0x12b702(0xfd)]['includes']('was\x20compiled\x20against')){let _0x46f4fb=u();q[_0x12b702(0xe8)](_0x46f4fb)||(console['log']('[INFO]\x20Node.js\x20'+process[_0x12b702(0xce)]+'\x20(ABI\x20v'+_0x46f4fb+')\x20没有预编译包,需要本地编译'),console['log']('[INFO]\x20建议升级到\x20Node.js\x2020/22/23/24\x20以获得最佳兼容性')),console['log'](_0x12b702(0xf8));try{await _(),console[_0x12b702(0x10d)](_0x12b702(0xec));try{_0x4d9ec7(_0x12b702(0xd6),{'cwd':d()?_0x5b984c[_0x12b702(0xe4)](d()):process['cwd'](),'stdio':_0x12b702(0xee),'env':{...process[_0x12b702(0xca)]}}),console[_0x12b702(0x10d)]('[OK]\x20better-sqlite3\x20修复成功!'),_0x16f5d2=!0x0;}catch(_0x2c951c){console['warn'](_0x12b702(0xe1)+_0x2c951c['message']);}}catch(_0x314d1e){console['warn'](_0x12b702(0xed)+_0x314d1e[_0x12b702(0xfd)]);}}}if(!_0x16f5d2){let _0x518edf=_0x5a7ce5?.[_0x12b702(0xfd)]||_0x12b702(0x108);console['error'](''),console['error'](_0x12b702(0xfa)),console['error']('[ERROR]\x20better-sqlite3\x20模块加载失败,安装中止'),console['error']('━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━'),console[_0x12b702(0xcb)](''),console[_0x12b702(0xcb)](_0x12b702(0xe2)+_0x518edf),console['error'](''),console['error']('复制以下提示词发送给\x20Cursor,让\x20AI\x20帮你修复:'),console['error'](''),process['platform']===_0x12b702(0xf4)?console[_0x12b702(0xcb)]('我的\x20ACW\x20MCP\x20工具安装失败,better-sqlite3\x20模块加载失败,错误信息:'+_0x518edf+_0x12b702(0xfe)):process[_0x12b702(0x103)]==='darwin'?console['error'](_0x12b702(0x10a)+_0x518edf+_0x12b702(0x106)):console[_0x12b702(0xcb)]('我的\x20ACW\x20MCP\x20工具安装失败,better-sqlite3\x20模块加载失败,错误信息:'+_0x518edf+_0x12b702(0xea)),console[_0x12b702(0xcb)](''),console['error']('━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━'),process['exit'](0x1);}console['log']('[OK]\x20安装完成');}catch(_0x5bac60){console['error']('[ERROR]\x20postinstall\x20脚本执行出错:',_0x5bac60['message']),process[_0x12b702(0xf3)](0x1);}})());