@univer-cli/resource-library-command 1.0.0-rc.0 → 1.0.0

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 (2) hide show
  1. package/dist/index.mjs +1 -1
  2. package/package.json +2 -2
package/dist/index.mjs CHANGED
@@ -1 +1 @@
1
- (function(_0x1cd075,_0x1e16d6){const _0x41d3bb=_0x1769,_0x34a823=_0x1cd075();while(!![]){try{const _0x2b2759=parseInt(_0x41d3bb(0x15c))/0x1*(-parseInt(_0x41d3bb(0x158))/0x2)+parseInt(_0x41d3bb(0x149))/0x3*(-parseInt(_0x41d3bb(0x148))/0x4)+-parseInt(_0x41d3bb(0x17c))/0x5*(parseInt(_0x41d3bb(0x165))/0x6)+-parseInt(_0x41d3bb(0x166))/0x7*(-parseInt(_0x41d3bb(0x195))/0x8)+parseInt(_0x41d3bb(0x177))/0x9+-parseInt(_0x41d3bb(0x163))/0xa*(parseInt(_0x41d3bb(0x19a))/0xb)+parseInt(_0x41d3bb(0x14a))/0xc;if(_0x2b2759===_0x1e16d6)break;else _0x34a823['push'](_0x34a823['shift']());}catch(_0x1200a8){_0x34a823['push'](_0x34a823['shift']());}}}(_0xfd21,0x47db9));import{isResourceLibraryError as _0x443908}from'@univer-cli/resource-library';import{Command as _0xa89f07,InvalidArgumentError as _0x5001c2,Option as _0x50161d}from'commander';var i=0x1e;function a(_0x500400){const _0x2d6cab=_0x1769;let _0x1d1ad3=new _0xa89f07(_0x2d6cab(0x164))['description'](_0x2d6cab(0x176))['action'](()=>_0x1d1ad3[_0x2d6cab(0x184)]());_0x1d1ad3[_0x2d6cab(0x190)]('registries')[_0x2d6cab(0x13d)](_0x2d6cab(0x189))[_0x2d6cab(0x18c)](_0x2d6cab(0x146),_0x2d6cab(0x186))['action'](async _0x309483=>{const _0x116535=_0x2d6cab;let _0x5a60b9=await c(_0x1d1ad3,async()=>_0x500400[_0x116535(0x162)]()['listRegistries']());l(_0x1d1ad3,_0x309483,{'registries':_0x5a60b9},d(_0x5a60b9));}),_0x1d1ad3[_0x2d6cab(0x190)]('find')['description']('Find\x20resources\x20by\x20name,\x20description,\x20group,\x20tag,\x20or\x20keyword')['argument'](_0x2d6cab(0x19b),_0x2d6cab(0x179))[_0x2d6cab(0x194)](new _0x50161d(_0x2d6cab(0x159),_0x2d6cab(0x172))[_0x2d6cab(0x167)](o)[_0x2d6cab(0x199)]([]))['addOption'](new _0x50161d(_0x2d6cab(0x17a),_0x2d6cab(0x175))[_0x2d6cab(0x167)](s)[_0x2d6cab(0x199)](i))[_0x2d6cab(0x18c)](_0x2d6cab(0x146),_0x2d6cab(0x186))[_0x2d6cab(0x169)](async(_0x359523,_0x4a4193)=>{const _0x1e95b3=_0x2d6cab;let _0x235662=await c(_0x1d1ad3,async()=>_0x500400[_0x1e95b3(0x162)]()[_0x1e95b3(0x150)]({'queries':_0x359523,'registries':_0x4a4193[_0x1e95b3(0x161)],'limit':_0x4a4193[_0x1e95b3(0x174)]}));l(_0x1d1ad3,_0x4a4193,{'query':{'queries':_0x359523,'registries':_0x4a4193[_0x1e95b3(0x161)]},'resources':_0x235662[_0x1e95b3(0x164)],'total':_0x235662[_0x1e95b3(0x14e)],'limit':_0x4a4193['limit']},f(_0x235662[_0x1e95b3(0x164)],_0x235662[_0x1e95b3(0x14e)]));}),_0x1d1ad3['command'](_0x2d6cab(0x147))[_0x2d6cab(0x13d)]('Read\x20one\x20SVG\x20or\x20export\x20resources\x20to\x20a\x20directory')[_0x2d6cab(0x14f)](_0x2d6cab(0x140),_0x2d6cab(0x144))['option']('--out\x20<directory>',_0x2d6cab(0x17e))[_0x2d6cab(0x18c)]('--json',_0x2d6cab(0x186))['action'](async(_0x33b7a7,_0xc0891e)=>{const _0x5bb636=_0x2d6cab;if(_0xc0891e[_0x5bb636(0x173)]===void 0x0){_0x33b7a7[_0x5bb636(0x191)]!==0x1&&_0x1d1ad3[_0x5bb636(0x170)](_0x5bb636(0x15d),{'code':_0x5bb636(0x18a),'exitCode':0x1});let _0x1b857a=await c(_0x1d1ad3,async()=>_0x500400[_0x5bb636(0x162)]()[_0x5bb636(0x17d)]({'handle':_0x33b7a7[0x0]}));_0xc0891e[_0x5bb636(0x182)]===!0x0?u(_0x1d1ad3,_0x1b857a):_0x1d1ad3[_0x5bb636(0x156)]()[_0x5bb636(0x168)]?.(_0x1b857a['svg']);return;}let _0x2083e0=await c(_0x1d1ad3,async()=>_0x500400[_0x5bb636(0x162)]()[_0x5bb636(0x147)]({'handles':_0x33b7a7,'destination':_0xc0891e[_0x5bb636(0x173)]}));if(_0xc0891e[_0x5bb636(0x182)]===!0x0)u(_0x1d1ad3,_0x2083e0);else{let _0x18c0a8=_0x1d1ad3[_0x5bb636(0x156)]();for(let _0x36a1b9 of _0x2083e0[_0x5bb636(0x13f)])_0x18c0a8[_0x5bb636(0x168)]?.(_0x36a1b9[_0x5bb636(0x16c)]+'\x0a');for(let _0x4da167 of _0x2083e0['failed'])_0x18c0a8[_0x5bb636(0x16e)]?.(_0x4da167[_0x5bb636(0x14d)]+':\x20'+_0x4da167[_0x5bb636(0x185)]+':\x20'+_0x4da167[_0x5bb636(0x16b)]+'\x0a');}_0x2083e0[_0x5bb636(0x17b)]['length']>0x0&&_0x1d1ad3[_0x5bb636(0x170)](_0x2083e0[_0x5bb636(0x17b)]['length']+_0x5bb636(0x13e)+(_0x2083e0[_0x5bb636(0x17b)][_0x5bb636(0x191)]===0x1?'':'s')+_0x5bb636(0x145),{'code':_0x5bb636(0x152),'exitCode':0x1});});let _0x2dbb29=_0x1d1ad3[_0x2d6cab(0x190)]('cache')[_0x2d6cab(0x13d)](_0x2d6cab(0x153));return _0x2dbb29[_0x2d6cab(0x169)](()=>_0x2dbb29[_0x2d6cab(0x184)]()),_0x2dbb29[_0x2d6cab(0x190)](_0x2d6cab(0x16c))[_0x2d6cab(0x13d)](_0x2d6cab(0x14b))[_0x2d6cab(0x18c)]('--json','write\x20structured\x20JSON')['action'](_0x41b871=>{const _0x3259cc=_0x2d6cab;let _0x2d53c2=_0x500400[_0x3259cc(0x162)]()['cacheLocation'];l(_0x1d1ad3,_0x41b871,{'path':_0x2d53c2},_0x2d53c2);}),_0x2dbb29['command'](_0x2d6cab(0x16a))[_0x2d6cab(0x13d)](_0x2d6cab(0x16d))[_0x2d6cab(0x18c)]('--json',_0x2d6cab(0x186))['action'](async _0x590740=>{const _0x355fab=_0x2d6cab;let _0x3f29fb=await c(_0x1d1ad3,async()=>_0x500400['openLibrary']()[_0x355fab(0x155)]());l(_0x1d1ad3,_0x590740,{'cleared':_0x3f29fb},_0x355fab(0x193)+_0x3f29fb[_0x355fab(0x141)]+'\x20resources\x20('+p(_0x3f29fb[_0x355fab(0x18b)])+_0x355fab(0x14c)+_0x3f29fb[_0x355fab(0x16c)]+'.');}),_0x1d1ad3;}function o(_0x3988ac,_0x2d634b){return[..._0x2d634b,_0x3988ac];}function s(_0x45cd1e){const _0x4ab15b=_0x1769;let _0x1ca878=Number(_0x45cd1e);if(!Number[_0x4ab15b(0x181)](_0x1ca878)||_0x1ca878<0x1)throw new _0x5001c2(_0x4ab15b(0x18d)+_0x45cd1e+'\x22.');return _0x1ca878;}async function c(_0x5ec51b,_0x1fcb67){const _0x4d9394=_0x1769;try{return await _0x1fcb67();}catch(_0x39885b){throw _0x443908(_0x39885b)&&_0x5ec51b[_0x4d9394(0x170)](_0x39885b[_0x4d9394(0x185)]+':\x20'+_0x39885b[_0x4d9394(0x16b)],{'code':'resources.failed','exitCode':0x1}),_0x39885b;}}function l(_0x5f177a,_0x3a70b8,_0xb4109b,_0x3dc3c8){const _0x4d9ba0=_0x1769;_0x3a70b8['json']===!0x0?u(_0x5f177a,_0xb4109b):_0x5f177a[_0x4d9ba0(0x156)]()[_0x4d9ba0(0x168)]?.(_0x3dc3c8+'\x0a');}function u(_0x424562,_0x3a14ab){const _0x4524b9=_0x1769;_0x424562[_0x4524b9(0x156)]()[_0x4524b9(0x168)]?.(JSON[_0x4524b9(0x171)](_0x3a14ab,null,0x2)+'\x0a');}function d(_0x5950f4){const _0x3a0abd=_0x1769;return['REGISTRY'[_0x3a0abd(0x13a)](0x22)+'\x20\x20'+_0x3a0abd(0x17f)[_0x3a0abd(0x142)](0x9)+'\x20\x20'+_0x3a0abd(0x157)['padStart'](0x7)+'\x20\x20'+_0x3a0abd(0x180)['padStart'](0x6)+'\x20\x20'+_0x3a0abd(0x15b)[_0x3a0abd(0x142)](0xa),..._0x5950f4['map'](_0x4b6f38=>[_0x4b6f38['id'][_0x3a0abd(0x13a)](0x22),String(_0x4b6f38[_0x3a0abd(0x141)])[_0x3a0abd(0x142)](0x9),String(_0x4b6f38[_0x3a0abd(0x187)])[_0x3a0abd(0x142)](0x7),String(_0x4b6f38[_0x3a0abd(0x154)])[_0x3a0abd(0x142)](0x6),(_0x4b6f38[_0x3a0abd(0x15e)]+'/'+_0x4b6f38[_0x3a0abd(0x141)])[_0x3a0abd(0x142)](0xa)]['join']('\x20\x20'))]['join']('\x0a');}function _0x1769(_0x74e62e,_0x1e2cc3){_0x74e62e=_0x74e62e-0x13a;const _0xfd21eb=_0xfd21();let _0x1769a7=_0xfd21eb[_0x74e62e];return _0x1769a7;}function f(_0x281b66,_0x5b2954){const _0x12dbef=_0x1769;if(_0x281b66[_0x12dbef(0x191)]===0x0)return _0x12dbef(0x143);let _0x4dd16b=[_0x12dbef(0x18f)[_0x12dbef(0x13a)](0x32)+'\x20\x20'+_0x12dbef(0x196)[_0x12dbef(0x13a)](0x1c)+'\x20\x20'+'GROUP'['padEnd'](0x12)+'\x20\x20'+_0x12dbef(0x13b)[_0x12dbef(0x13a)](0x8)+_0x12dbef(0x198),..._0x281b66[_0x12dbef(0x13c)](_0x33d953=>{const _0x769709=_0x12dbef;let _0x2906e0=_0x33d953[_0x769709(0x188)]?.['label']??'-',_0x1f2b76=_0x33d953['colorEditable']?'editable':_0x769709(0x197),_0x4e23d7=_0x33d953[_0x769709(0x192)][_0x769709(0x18e)]+'×'+_0x33d953[_0x769709(0x192)][_0x769709(0x183)];return _0x33d953[_0x769709(0x14d)][_0x769709(0x13a)](0x32)+'\x20\x20'+_0x33d953[_0x769709(0x151)][_0x769709(0x13a)](0x1c)+'\x20\x20'+_0x2906e0[_0x769709(0x13a)](0x12)+'\x20\x20'+_0x1f2b76[_0x769709(0x13a)](0x8)+'\x20\x20'+_0x4e23d7;})];return _0x5b2954>_0x281b66[_0x12dbef(0x191)]&&_0x4dd16b['push']('…\x20'+(_0x5b2954-_0x281b66['length'])+_0x12dbef(0x15f)),_0x4dd16b[_0x12dbef(0x178)]('\x0a');}function p(_0xbca49a){const _0x5e2846=_0x1769;return _0xbca49a<0x400?_0xbca49a+'\x20B':_0xbca49a<0x100000?(_0xbca49a/0x400)[_0x5e2846(0x160)](0x1)+_0x5e2846(0x16f):(_0xbca49a/0x100000)['toFixed'](0x1)+_0x5e2846(0x15a);}export{a as createResourcesCommand};function _0xfd21(){const _0xa8c2e4=['handle','total','argument','find','name','resources.export.failed','Inspect\x20or\x20clear\x20the\x20resource\x20cache','tagCount','clearCache','configureOutput','GROUPS','12wwbVts','--registry\x20<id>','\x20MB','EDITABLE','28874cnsaPB','Exporting\x20more\x20than\x20one\x20resource\x20requires\x20--out\x20<directory>.','colorEditableCount','\x20more;\x20raise\x20--limit\x20or\x20narrow\x20the\x20query.','toFixed','registry','openLibrary','280RVbYRZ','resources','354tudOAO','161BZFxyH','argParser','writeOut','action','clear','message','path','Clear\x20all\x20cached\x20resources','writeErr','\x20KB','error','stringify','restrict\x20results\x20to\x20a\x20registry;\x20repeatable','out','limit','maximum\x20number\x20of\x20results','Find\x20and\x20export\x20SVG\x20resources\x20from\x20a\x20multi-registry\x20catalog','4385691PhFleJ','join','one\x20or\x20more\x20queries,\x20searched\x20independently','--limit\x20<number>','failed','26545BLWaRt','read','write\x20flat\x20<registry>--<resource>.svg\x20files','RESOURCES','TAGS','isInteger','json','height','outputHelp','code','write\x20structured\x20JSON','groupCount','group','List\x20available\x20resource\x20registries','resources.invalid-input','byteCount','option','Expected\x20a\x20positive\x20integer;\x20received\x20\x22','width','HANDLE','command','length','intrinsicSize','Cleared\x20','addOption','117848EVfRwc','NAME','fixed','\x20\x20SIZE','default','222761xhlUDA','<queries...>','padEnd','COLOR','map','description','\x20resource','exported','<handles...>','resourceCount','padStart','No\x20resources\x20matched;\x20try\x20a\x20shorter\x20substring,\x20a\x20synonym,\x20or\x20another\x20registry.','canonical\x20<registryId>/<resourceId>\x20handles','\x20could\x20not\x20be\x20exported.','--json','export','12604yyymCF','471qDCrXk','12197124FPNJTy','Show\x20the\x20resource\x20cache\x20path',')\x20from\x20'];_0xfd21=function(){return _0xa8c2e4;};return _0xfd21();}
1
+ (function(_0x1133b0,_0x43eb6d){const _0x5b7044=_0x1f2b,_0x40d898=_0x1133b0();while(!![]){try{const _0x59f9c0=parseInt(_0x5b7044(0x1ec))/0x1*(parseInt(_0x5b7044(0x21c))/0x2)+-parseInt(_0x5b7044(0x1cc))/0x3+parseInt(_0x5b7044(0x1dd))/0x4*(parseInt(_0x5b7044(0x1f6))/0x5)+parseInt(_0x5b7044(0x21d))/0x6*(parseInt(_0x5b7044(0x201))/0x7)+-parseInt(_0x5b7044(0x212))/0x8*(parseInt(_0x5b7044(0x1c7))/0x9)+-parseInt(_0x5b7044(0x204))/0xa*(parseInt(_0x5b7044(0x211))/0xb)+parseInt(_0x5b7044(0x1e3))/0xc;if(_0x59f9c0===_0x43eb6d)break;else _0x40d898['push'](_0x40d898['shift']());}catch(_0x384f34){_0x40d898['push'](_0x40d898['shift']());}}}(_0x556a,0x3a3a9));import{isResourceLibraryError as _0x5c2d40}from'@univer-cli/resource-library';function _0x1f2b(_0x4fd3d2,_0x4e6903){_0x4fd3d2=_0x4fd3d2-0x1c7;const _0x556a49=_0x556a();let _0x1f2bf9=_0x556a49[_0x4fd3d2];return _0x1f2bf9;}import{Command as _0x542f69,InvalidArgumentError as _0x3bc59e,Option as _0x19e94a}from'commander';var i=0x1e;function _0x556a(){const _0x7833cd=['52166zWydzR','1972878IGhGvg','byteCount','<handles...>','openLibrary','Clear\x20all\x20cached\x20resources','height','write\x20structured\x20JSON','error','json','write\x20flat\x20<registry>--<resource>.svg\x20files','handle','\x20MB','Find\x20and\x20export\x20SVG\x20resources\x20from\x20a\x20multi-registry\x20catalog','Cleared\x20','27mDkKkd','EDITABLE','--json','maximum\x20number\x20of\x20results','argParser','188619kLcUaK','group','colorEditableCount','TAGS','configureOutput','resources.failed','failed','code','default','action','push','resources','Expected\x20a\x20positive\x20integer;\x20received\x20\x22','--registry\x20<id>','Read\x20one\x20SVG\x20or\x20export\x20resources\x20to\x20a\x20directory','--out\x20<directory>','\x20more;\x20raise\x20--limit\x20or\x20narrow\x20the\x20query.','5252hwAPmu','editable','isInteger','\x20resources\x20(','No\x20resources\x20matched;\x20try\x20a\x20shorter\x20substring,\x20a\x20synonym,\x20or\x20another\x20registry.',')\x20from\x20','4965168SUeRdG','limit','label','\x20resource','total','description','fixed','registry','argument','2tdyDml','length','addOption','restrict\x20results\x20to\x20a\x20registry;\x20repeatable','toFixed','writeErr','--limit\x20<number>','map','padStart','resourceCount','60tadzgZ','read','NAME','command','outputHelp','Exporting\x20more\x20than\x20one\x20resource\x20requires\x20--out\x20<directory>.','\x20\x20SIZE','padEnd','Show\x20the\x20resource\x20cache\x20path','GROUPS','writeOut','7JSBCDO','join','HANDLE','2490vgejGM','resources.export.failed','<queries...>','out','path','List\x20available\x20resource\x20registries','colorEditable','stringify','GROUP','Find\x20resources\x20by\x20name,\x20description,\x20group,\x20tag,\x20or\x20keyword','intrinsicSize','\x20could\x20not\x20be\x20exported.','option','4796OIaSCE','1068152eucOaC','canonical\x20<registryId>/<resourceId>\x20handles','REGISTRY','COLOR','export','RESOURCES','exported','message','listRegistries','find'];_0x556a=function(){return _0x7833cd;};return _0x556a();}function a(_0x4e0b8b){const _0x2e4823=_0x1f2b;let _0x1f8cdc=new _0x542f69(_0x2e4823(0x1d7))['description'](_0x2e4823(0x229))[_0x2e4823(0x1d5)](()=>_0x1f8cdc[_0x2e4823(0x1fa)]());_0x1f8cdc[_0x2e4823(0x1f9)]('registries')['description'](_0x2e4823(0x209))[_0x2e4823(0x210)](_0x2e4823(0x1c9),_0x2e4823(0x223))[_0x2e4823(0x1d5)](async _0xfaf87b=>{const _0x3b7413=_0x2e4823;let _0x11d983=await c(_0x1f8cdc,async()=>_0x4e0b8b['openLibrary']()[_0x3b7413(0x21a)]());l(_0x1f8cdc,_0xfaf87b,{'registries':_0x11d983},d(_0x11d983));}),_0x1f8cdc[_0x2e4823(0x1f9)](_0x2e4823(0x21b))[_0x2e4823(0x1e8)](_0x2e4823(0x20d))['argument'](_0x2e4823(0x206),'one\x20or\x20more\x20queries,\x20searched\x20independently')[_0x2e4823(0x1ee)](new _0x19e94a(_0x2e4823(0x1d9),_0x2e4823(0x1ef))[_0x2e4823(0x1cb)](o)['default']([]))[_0x2e4823(0x1ee)](new _0x19e94a(_0x2e4823(0x1f2),_0x2e4823(0x1ca))[_0x2e4823(0x1cb)](s)[_0x2e4823(0x1d4)](i))[_0x2e4823(0x210)](_0x2e4823(0x1c9),_0x2e4823(0x223))[_0x2e4823(0x1d5)](async(_0x561157,_0x5bd931)=>{const _0x4b0eba=_0x2e4823;let _0x3b855f=await c(_0x1f8cdc,async()=>_0x4e0b8b[_0x4b0eba(0x220)]()[_0x4b0eba(0x21b)]({'queries':_0x561157,'registries':_0x5bd931[_0x4b0eba(0x1ea)],'limit':_0x5bd931['limit']}));l(_0x1f8cdc,_0x5bd931,{'query':{'queries':_0x561157,'registries':_0x5bd931[_0x4b0eba(0x1ea)]},'resources':_0x3b855f['resources'],'total':_0x3b855f[_0x4b0eba(0x1e7)],'limit':_0x5bd931[_0x4b0eba(0x1e4)]},f(_0x3b855f[_0x4b0eba(0x1d7)],_0x3b855f[_0x4b0eba(0x1e7)]));}),_0x1f8cdc[_0x2e4823(0x1f9)](_0x2e4823(0x216))[_0x2e4823(0x1e8)](_0x2e4823(0x1da))[_0x2e4823(0x1eb)](_0x2e4823(0x21f),_0x2e4823(0x213))[_0x2e4823(0x210)](_0x2e4823(0x1db),_0x2e4823(0x226))[_0x2e4823(0x210)](_0x2e4823(0x1c9),_0x2e4823(0x223))[_0x2e4823(0x1d5)](async(_0x37ae5d,_0x217312)=>{const _0x59f398=_0x2e4823;if(_0x217312[_0x59f398(0x207)]===void 0x0){_0x37ae5d[_0x59f398(0x1ed)]!==0x1&&_0x1f8cdc[_0x59f398(0x224)](_0x59f398(0x1fb),{'code':'resources.invalid-input','exitCode':0x1});let _0x41148b=await c(_0x1f8cdc,async()=>_0x4e0b8b[_0x59f398(0x220)]()[_0x59f398(0x1f7)]({'handle':_0x37ae5d[0x0]}));_0x217312[_0x59f398(0x225)]===!0x0?u(_0x1f8cdc,_0x41148b):_0x1f8cdc[_0x59f398(0x1d0)]()[_0x59f398(0x200)]?.(_0x41148b['svg']);return;}let _0x4f3be4=await c(_0x1f8cdc,async()=>_0x4e0b8b[_0x59f398(0x220)]()['export']({'handles':_0x37ae5d,'destination':_0x217312[_0x59f398(0x207)]}));if(_0x217312[_0x59f398(0x225)]===!0x0)u(_0x1f8cdc,_0x4f3be4);else{let _0x29d961=_0x1f8cdc[_0x59f398(0x1d0)]();for(let _0x2ddd2e of _0x4f3be4[_0x59f398(0x218)])_0x29d961[_0x59f398(0x200)]?.(_0x2ddd2e['path']+'\x0a');for(let _0x492cb5 of _0x4f3be4[_0x59f398(0x1d2)])_0x29d961[_0x59f398(0x1f1)]?.(_0x492cb5[_0x59f398(0x227)]+':\x20'+_0x492cb5[_0x59f398(0x1d3)]+':\x20'+_0x492cb5['message']+'\x0a');}_0x4f3be4['failed'][_0x59f398(0x1ed)]>0x0&&_0x1f8cdc['error'](_0x4f3be4['failed'][_0x59f398(0x1ed)]+_0x59f398(0x1e6)+(_0x4f3be4[_0x59f398(0x1d2)][_0x59f398(0x1ed)]===0x1?'':'s')+_0x59f398(0x20f),{'code':_0x59f398(0x205),'exitCode':0x1});});let _0x1ef4b4=_0x1f8cdc['command']('cache')[_0x2e4823(0x1e8)]('Inspect\x20or\x20clear\x20the\x20resource\x20cache');return _0x1ef4b4[_0x2e4823(0x1d5)](()=>_0x1ef4b4[_0x2e4823(0x1fa)]()),_0x1ef4b4[_0x2e4823(0x1f9)]('path')['description'](_0x2e4823(0x1fe))[_0x2e4823(0x210)](_0x2e4823(0x1c9),_0x2e4823(0x223))['action'](_0x458c58=>{const _0x5e266f=_0x2e4823;let _0x5260bd=_0x4e0b8b[_0x5e266f(0x220)]()['cacheLocation'];l(_0x1f8cdc,_0x458c58,{'path':_0x5260bd},_0x5260bd);}),_0x1ef4b4[_0x2e4823(0x1f9)]('clear')[_0x2e4823(0x1e8)](_0x2e4823(0x221))[_0x2e4823(0x210)](_0x2e4823(0x1c9),_0x2e4823(0x223))[_0x2e4823(0x1d5)](async _0x2c7688=>{const _0x29f98f=_0x2e4823;let _0x38f883=await c(_0x1f8cdc,async()=>_0x4e0b8b[_0x29f98f(0x220)]()['clearCache']());l(_0x1f8cdc,_0x2c7688,{'cleared':_0x38f883},_0x29f98f(0x22a)+_0x38f883[_0x29f98f(0x1f5)]+_0x29f98f(0x1e0)+p(_0x38f883[_0x29f98f(0x21e)])+_0x29f98f(0x1e2)+_0x38f883[_0x29f98f(0x208)]+'.');}),_0x1f8cdc;}function o(_0x32be2d,_0x34247){return[..._0x34247,_0x32be2d];}function s(_0x805c6e){const _0x3257cc=_0x1f2b;let _0x2bef70=Number(_0x805c6e);if(!Number[_0x3257cc(0x1df)](_0x2bef70)||_0x2bef70<0x1)throw new _0x3bc59e(_0x3257cc(0x1d8)+_0x805c6e+'\x22.');return _0x2bef70;}async function c(_0x4a3a65,_0x2a0622){const _0x28e1a6=_0x1f2b;try{return await _0x2a0622();}catch(_0xdaee90){throw _0x5c2d40(_0xdaee90)&&_0x4a3a65[_0x28e1a6(0x224)](_0xdaee90['code']+':\x20'+_0xdaee90[_0x28e1a6(0x219)],{'code':_0x28e1a6(0x1d1),'exitCode':0x1}),_0xdaee90;}}function l(_0x540249,_0x1bbfe6,_0x239ad2,_0x56378f){const _0x3cb80b=_0x1f2b;_0x1bbfe6[_0x3cb80b(0x225)]===!0x0?u(_0x540249,_0x239ad2):_0x540249[_0x3cb80b(0x1d0)]()[_0x3cb80b(0x200)]?.(_0x56378f+'\x0a');}function u(_0x12f239,_0x32d94c){const _0x1da153=_0x1f2b;_0x12f239['configureOutput']()['writeOut']?.(JSON[_0x1da153(0x20b)](_0x32d94c,null,0x2)+'\x0a');}function d(_0x3121b8){const _0x5d0103=_0x1f2b;return[_0x5d0103(0x214)[_0x5d0103(0x1fd)](0x22)+'\x20\x20'+_0x5d0103(0x217)['padStart'](0x9)+'\x20\x20'+_0x5d0103(0x1ff)[_0x5d0103(0x1f4)](0x7)+'\x20\x20'+_0x5d0103(0x1cf)[_0x5d0103(0x1f4)](0x6)+'\x20\x20'+_0x5d0103(0x1c8)['padStart'](0xa),..._0x3121b8['map'](_0x456d2c=>[_0x456d2c['id'][_0x5d0103(0x1fd)](0x22),String(_0x456d2c[_0x5d0103(0x1f5)])[_0x5d0103(0x1f4)](0x9),String(_0x456d2c['groupCount'])[_0x5d0103(0x1f4)](0x7),String(_0x456d2c['tagCount'])[_0x5d0103(0x1f4)](0x6),(_0x456d2c[_0x5d0103(0x1ce)]+'/'+_0x456d2c[_0x5d0103(0x1f5)])[_0x5d0103(0x1f4)](0xa)][_0x5d0103(0x202)]('\x20\x20'))][_0x5d0103(0x202)]('\x0a');}function f(_0x9c5168,_0x22101f){const _0x119d35=_0x1f2b;if(_0x9c5168[_0x119d35(0x1ed)]===0x0)return _0x119d35(0x1e1);let _0x292c84=[_0x119d35(0x203)[_0x119d35(0x1fd)](0x32)+'\x20\x20'+_0x119d35(0x1f8)[_0x119d35(0x1fd)](0x1c)+'\x20\x20'+_0x119d35(0x20c)[_0x119d35(0x1fd)](0x12)+'\x20\x20'+_0x119d35(0x215)[_0x119d35(0x1fd)](0x8)+_0x119d35(0x1fc),..._0x9c5168[_0x119d35(0x1f3)](_0x25d867=>{const _0x35a5b9=_0x119d35;let _0x1a1bc5=_0x25d867[_0x35a5b9(0x1cd)]?.[_0x35a5b9(0x1e5)]??'-',_0x34db69=_0x25d867[_0x35a5b9(0x20a)]?_0x35a5b9(0x1de):_0x35a5b9(0x1e9),_0x1a079b=_0x25d867[_0x35a5b9(0x20e)]['width']+'×'+_0x25d867[_0x35a5b9(0x20e)][_0x35a5b9(0x222)];return _0x25d867[_0x35a5b9(0x227)][_0x35a5b9(0x1fd)](0x32)+'\x20\x20'+_0x25d867['name'][_0x35a5b9(0x1fd)](0x1c)+'\x20\x20'+_0x1a1bc5['padEnd'](0x12)+'\x20\x20'+_0x34db69[_0x35a5b9(0x1fd)](0x8)+'\x20\x20'+_0x1a079b;})];return _0x22101f>_0x9c5168[_0x119d35(0x1ed)]&&_0x292c84[_0x119d35(0x1d6)]('…\x20'+(_0x22101f-_0x9c5168[_0x119d35(0x1ed)])+_0x119d35(0x1dc)),_0x292c84['join']('\x0a');}function p(_0x1843b8){const _0x26fe75=_0x1f2b;return _0x1843b8<0x400?_0x1843b8+'\x20B':_0x1843b8<0x100000?(_0x1843b8/0x400)[_0x26fe75(0x1f0)](0x1)+'\x20KB':(_0x1843b8/0x100000)['toFixed'](0x1)+_0x26fe75(0x228);}export{a as createResourcesCommand};
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@univer-cli/resource-library-command",
3
3
  "type": "module",
4
- "version": "1.0.0-rc.0",
4
+ "version": "1.0.0",
5
5
  "main": "./dist/index.cjs",
6
6
  "module": "./dist/index.mjs",
7
7
  "types": "./dist/index.d.ts",
@@ -18,7 +18,7 @@
18
18
  "README.zh-CN.md"
19
19
  ],
20
20
  "dependencies": {
21
- "@univer-cli/resource-library": "1.0.0-rc.0"
21
+ "@univer-cli/resource-library": "1.0.0"
22
22
  },
23
23
  "peerDependencies": {
24
24
  "commander": "^15.0.0"