@lovrabet/lovrabet-cli 2.1.23-beta.3 → 2.1.23

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 (136) hide show
  1. package/lib/cli.js +1 -1
  2. package/lib/commands/api-doc/index.js +1 -1
  3. package/lib/commands/app/cache.js +1 -1
  4. package/lib/commands/app/definitions.js +1 -1
  5. package/lib/commands/app/eligibility.js +1 -1
  6. package/lib/commands/app/mock-loader.js +1 -1
  7. package/lib/commands/app/remote-source.js +1 -1
  8. package/lib/commands/app/shared.js +1 -1
  9. package/lib/commands/app-config/get.js +1 -1
  10. package/lib/commands/app-config/index.js +1 -1
  11. package/lib/commands/artifact/index.js +1 -1
  12. package/lib/commands/auth/device.js +1 -1
  13. package/lib/commands/auth/index.js +1 -1
  14. package/lib/commands/auth/prompt.js +1 -1
  15. package/lib/commands/bff/detail.js +1 -1
  16. package/lib/commands/bff/exec.js +1 -1
  17. package/lib/commands/bff/index.js +1 -1
  18. package/lib/commands/cli-skill/index.js +1 -1
  19. package/lib/commands/common/config-policy.js +1 -1
  20. package/lib/commands/common/constraints.js +1 -1
  21. package/lib/commands/common/flags.js +1 -1
  22. package/lib/commands/common/local-file.js +1 -1
  23. package/lib/commands/config/definitions.js +1 -1
  24. package/lib/commands/config/shared.js +1 -1
  25. package/lib/commands/data/index.js +1 -1
  26. package/lib/commands/dataset/detail.js +1 -1
  27. package/lib/commands/dataset/index.js +1 -1
  28. package/lib/commands/dataset/list.js +1 -1
  29. package/lib/commands/dataset/sdk-doc.js +1 -1
  30. package/lib/commands/doctor.js +1 -1
  31. package/lib/commands/file/index.js +1 -1
  32. package/lib/commands/init.js +1 -1
  33. package/lib/commands/kb/index.js +1 -1
  34. package/lib/commands/logs/index.d.ts +2 -8
  35. package/lib/commands/logs/index.js +1 -1
  36. package/lib/commands/ocr/index.js +1 -1
  37. package/lib/commands/personal-bff/index.js +1 -1
  38. package/lib/commands/registry.js +1 -1
  39. package/lib/commands/schedule/index.js +1 -1
  40. package/lib/commands/schema.js +1 -1
  41. package/lib/commands/service/dynamic.js +1 -1
  42. package/lib/commands/service/function-name-adapter.js +1 -1
  43. package/lib/commands/service/index.js +1 -1
  44. package/lib/commands/service/registry.js +1 -1
  45. package/lib/commands/skill/commands/create.js +1 -1
  46. package/lib/commands/skill/commands/diagram.js +1 -1
  47. package/lib/commands/skill/commands/install.js +1 -1
  48. package/lib/commands/skill/commands/list.js +1 -1
  49. package/lib/commands/skill/commands/push.js +1 -1
  50. package/lib/commands/skill/commands/validate.js +1 -1
  51. package/lib/commands/skill/diagram.d.ts +6 -0
  52. package/lib/commands/skill/diagram.js +1 -1
  53. package/lib/commands/skill/flags.js +1 -1
  54. package/lib/commands/skill/index.js +1 -1
  55. package/lib/commands/skill/manifest-helpers.js +1 -1
  56. package/lib/commands/skill/push-execute.js +1 -1
  57. package/lib/commands/skill/push-flow-helpers.js +1 -1
  58. package/lib/commands/skill/push-retarget.js +1 -1
  59. package/lib/commands/skill/scopes.js +1 -1
  60. package/lib/commands/skill/summary.js +1 -1
  61. package/lib/commands/skill/templates.js +1 -1
  62. package/lib/commands/skill/validate.js +1 -1
  63. package/lib/commands/sql/detail.js +1 -1
  64. package/lib/commands/sql/exec.js +1 -1
  65. package/lib/commands/sql/index.js +1 -1
  66. package/lib/commands/update.js +1 -1
  67. package/lib/commands/workspace/index.js +1 -1
  68. package/lib/config/schema.js +1 -1
  69. package/lib/constant/app.js +1 -1
  70. package/lib/constant/auth-mode.js +1 -1
  71. package/lib/constant/cli.js +1 -1
  72. package/lib/constant/defaults.js +1 -1
  73. package/lib/constant/distribution.js +1 -1
  74. package/lib/constant/domain.js +1 -1
  75. package/lib/constant/env.js +1 -1
  76. package/lib/constant/output.js +1 -1
  77. package/lib/constant/product.js +1 -1
  78. package/lib/constant/risk.js +1 -1
  79. package/lib/constant/url.js +1 -1
  80. package/lib/context.js +1 -1
  81. package/lib/core/api-client.js +1 -1
  82. package/lib/core/db-resolver.js +1 -1
  83. package/lib/core/sdk-client.js +1 -1
  84. package/lib/errors.js +1 -1
  85. package/lib/framework/build-all-flags.js +1 -1
  86. package/lib/framework/dryrun.js +1 -1
  87. package/lib/framework/flags.js +1 -1
  88. package/lib/framework/help.js +1 -1
  89. package/lib/framework/index.js +1 -1
  90. package/lib/framework/output.js +1 -1
  91. package/lib/framework/preparse.js +1 -1
  92. package/lib/framework/rate-limit.js +1 -1
  93. package/lib/framework/raw-flags.js +1 -1
  94. package/lib/framework/response.js +1 -1
  95. package/lib/framework/runner-confirmation.js +1 -1
  96. package/lib/framework/runner-error.js +1 -1
  97. package/lib/framework/runner.js +1 -1
  98. package/lib/framework/schema-export.js +1 -1
  99. package/lib/framework/service-order.js +1 -1
  100. package/lib/framework/types.js +1 -1
  101. package/lib/generated/build-info.d.ts +4 -4
  102. package/lib/generated/build-info.js +1 -1
  103. package/lib/help.js +1 -1
  104. package/lib/runtime/confirmation.js +1 -1
  105. package/lib/runtime/event.js +1 -1
  106. package/lib/runtime/index.js +1 -1
  107. package/lib/runtime/queue.js +1 -1
  108. package/lib/runtime/resolve.js +1 -1
  109. package/lib/skills/npx-skills-add.js +1 -1
  110. package/lib/skills/runtime-skill-sync/constants.js +1 -1
  111. package/lib/skills/runtime-skill-sync/fs-utils.js +1 -1
  112. package/lib/skills/runtime-skill-sync/hashing.js +1 -1
  113. package/lib/skills/runtime-skill-sync/install-target.js +1 -1
  114. package/lib/skills/runtime-skill-sync/links.js +1 -1
  115. package/lib/skills/runtime-skill-sync/list-local.js +1 -1
  116. package/lib/skills/runtime-skill-sync/local-files.d.ts +4 -1
  117. package/lib/skills/runtime-skill-sync/local-files.js +1 -1
  118. package/lib/skills/runtime-skill-sync/materialize.js +1 -1
  119. package/lib/skills/runtime-skill-sync/metadata.js +1 -1
  120. package/lib/skills/runtime-skill-sync/paths.js +1 -1
  121. package/lib/skills/runtime-skill-sync/push.d.ts +1 -0
  122. package/lib/skills/runtime-skill-sync/push.js +1 -1
  123. package/lib/skills/runtime-skill-sync/scopes.js +1 -1
  124. package/lib/skills/runtime-skill-sync/zip-codec.js +1 -1
  125. package/lib/skills/runtime-skill-sync/zip-package.js +1 -1
  126. package/lib/skills/runtime-skill-sync.js +1 -1
  127. package/lib/skills/skill-presence.js +1 -1
  128. package/lib/utils/apply-jq-filter.js +1 -1
  129. package/lib/utils/logger.js +1 -1
  130. package/lib/utils/lossless-json.js +1 -1
  131. package/lib/utils/params.js +1 -1
  132. package/lib/utils/platform.js +1 -1
  133. package/lib/utils/update-notice.js +1 -1
  134. package/lib/utils/version.js +1 -1
  135. package/lib/utils/write-cli-side-channel.js +1 -1
  136. package/package.json +1 -1
@@ -1 +1 @@
1
- (function(_0x586a47,_0x42dc0c){const _0x3089d5=a113_0x45a5,_0x32329f=_0x586a47();while(!![]){try{const _0x524c6b=-parseInt(_0x3089d5(0xef))/0x1*(parseInt(_0x3089d5(0xe3))/0x2)+parseInt(_0x3089d5(0xfd))/0x3*(parseInt(_0x3089d5(0xe1))/0x4)+-parseInt(_0x3089d5(0xd2))/0x5*(parseInt(_0x3089d5(0xf2))/0x6)+-parseInt(_0x3089d5(0xf3))/0x7+-parseInt(_0x3089d5(0xf7))/0x8*(parseInt(_0x3089d5(0xf4))/0x9)+-parseInt(_0x3089d5(0xf9))/0xa*(parseInt(_0x3089d5(0x100))/0xb)+parseInt(_0x3089d5(0xdf))/0xc*(parseInt(_0x3089d5(0xea))/0xd);if(_0x524c6b===_0x42dc0c)break;else _0x32329f['push'](_0x32329f['shift']());}catch(_0x5bdfca){_0x32329f['push'](_0x32329f['shift']());}}}(a113_0x2ebf,0xc8a88));import{readFileSync,readdirSync,realpathSync}from'node:fs';import{relative,resolve}from'node:path';import{CliErrors}from'../../errors.js';import{IGNORED_DIR_NAMES,IGNORED_FILE_NAMES,SKILL_FILE}from'./constants.js';function a113_0x2ebf(){const _0x4e186e=['9023320vAZHmP','toLowerCase','60QfsRpA','string','Duplicate\x20Skill\x20file\x20path:\x20','Skill\x20file\x20sha256\x20is\x20invalid:\x20','86673PjSGWk','Skill\x20file\x20bytes\x20must\x20be\x20a\x20Buffer:\x20','isFile','911119bJGbqT','startsWith','isBuffer','isDirectory','object','15cpekDC','set','sha256','from','trim','replace','split','push','localeCompare','isArray','values','bytes','content','12PABgRi','Skill\x20file\x20size\x20is\x20invalid:\x20','124icCAJP','name','2JjQccK','has','isSafeInteger','Skill\x20file\x20path\x20must\x20be\x20text.','validation','length','sort','56736537GVYHuE','isSymbolicLink','path','toString','utf8','581323PQKwgz','size','Skill\x20directory\x20contains\x20unsupported\x20symlink:\x20','1854276EDvgXm','9133068vnVSLg','9aGPuQr','Unsafe\x20Skill\x20file\x20path:\x20','compare'];a113_0x2ebf=function(){return _0x4e186e;};return a113_0x2ebf();}export function fileContent(_0x26452c){const _0x48c31f=a113_0x45a5;return _0x26452c[_0x48c31f(0xdd)]??Buffer[_0x48c31f(0xd5)](_0x26452c[_0x48c31f(0xde)]??'',_0x48c31f(0xee));}export function fileText(_0x576424){const _0x54fe3d=a113_0x45a5;return fileContent(_0x576424)[_0x54fe3d(0xed)](_0x54fe3d(0xee));}export function normalizeLocalFiles(_0x1f7a82){const _0x5092de=a113_0x45a5;if(!Array[_0x5092de(0xdb)](_0x1f7a82)||_0x1f7a82['length']===0x0)return[];const _0x5cad52=new Map();for(const _0x1f4dcd of _0x1f7a82){if(!_0x1f4dcd||typeof _0x1f4dcd!==_0x5092de(0xd1)||typeof _0x1f4dcd[_0x5092de(0xec)]!==_0x5092de(0xfa))throw CliErrors[_0x5092de(0xe7)](_0x5092de(0xe6));const _0x538c06=normalizeSkillRelativePath(_0x1f4dcd[_0x5092de(0xec)]);if(_0x5cad52[_0x5092de(0xe4)](_0x538c06))throw CliErrors[_0x5092de(0xe7)](_0x5092de(0xfb)+_0x538c06);if(_0x1f4dcd[_0x5092de(0xdd)]!==undefined&&!Buffer[_0x5092de(0xcf)](_0x1f4dcd[_0x5092de(0xdd)]))throw CliErrors[_0x5092de(0xe7)](_0x5092de(0xfe)+_0x538c06);if(_0x1f4dcd[_0x5092de(0xdd)]===undefined&&typeof _0x1f4dcd[_0x5092de(0xde)]!==_0x5092de(0xfa))throw CliErrors['validation']('Skill\x20file\x20content\x20must\x20be\x20text\x20or\x20bytes:\x20'+_0x538c06);const _0x2d8863=fileContent(_0x1f4dcd);_0x5cad52[_0x5092de(0xd3)](_0x538c06,{'path':_0x538c06,'bytes':_0x2d8863});}return Array[_0x5092de(0xd5)](_0x5cad52[_0x5092de(0xdc)]())[_0x5092de(0xe9)](compareSkillFiles);}export function normalizeManifestFiles(_0x4a8445){const _0x4a3c82=a113_0x45a5;if(!Array[_0x4a3c82(0xdb)](_0x4a8445)||_0x4a8445[_0x4a3c82(0xe8)]===0x0)return[];const _0x3a0269=new Map();for(const _0x8537e3 of _0x4a8445){if(!_0x8537e3||typeof _0x8537e3!==_0x4a3c82(0xd1)||typeof _0x8537e3['path']!=='string')throw CliErrors['validation'](_0x4a3c82(0xe6));const _0x5c1dfc=normalizeSkillRelativePath(_0x8537e3['path']);if(_0x3a0269[_0x4a3c82(0xe4)](_0x5c1dfc))throw CliErrors[_0x4a3c82(0xe7)]('Duplicate\x20Skill\x20file\x20path:\x20'+_0x5c1dfc);if(!isSha256Hex(_0x8537e3[_0x4a3c82(0xd4)]))throw CliErrors[_0x4a3c82(0xe7)](_0x4a3c82(0xfc)+_0x5c1dfc);if(!Number[_0x4a3c82(0xe5)](_0x8537e3[_0x4a3c82(0xf0)])||_0x8537e3[_0x4a3c82(0xf0)]<0x0)throw CliErrors['validation'](_0x4a3c82(0xe0)+_0x5c1dfc);_0x3a0269[_0x4a3c82(0xd3)](_0x5c1dfc,{'path':_0x5c1dfc,'sha256':_0x8537e3[_0x4a3c82(0xd4)][_0x4a3c82(0xf8)](),'size':_0x8537e3[_0x4a3c82(0xf0)]});}return Array[_0x4a3c82(0xd5)](_0x3a0269[_0x4a3c82(0xdc)]())[_0x4a3c82(0xe9)](compareSkillFiles);}function a113_0x45a5(_0x3e6a30,_0x35ea0b){_0x3e6a30=_0x3e6a30-0xcf;const _0x2ebf04=a113_0x2ebf();let _0x45a50d=_0x2ebf04[_0x3e6a30];return _0x45a50d;}export function scanSkillDirectory(_0xc57209){const _0x43adf1=realpathSync(_0xc57209),_0x171fe=[];function _0x182587(_0x1069a6){const _0x46f128=a113_0x45a5,_0x1e5f40=readdirSync(_0x1069a6,{'withFileTypes':!![]})[_0x46f128(0xe9)]((_0x44b35a,_0x34042f)=>_0x44b35a[_0x46f128(0xe2)][_0x46f128(0xda)](_0x34042f['name']));for(const _0x5db31f of _0x1e5f40){if(_0x5db31f[_0x46f128(0xd0)]()&&IGNORED_DIR_NAMES[_0x46f128(0xe4)](_0x5db31f[_0x46f128(0xe2)]))continue;if(IGNORED_FILE_NAMES[_0x46f128(0xe4)](_0x5db31f[_0x46f128(0xe2)]))continue;const _0x130fb0=resolve(_0x1069a6,_0x5db31f[_0x46f128(0xe2)]);if(_0x5db31f[_0x46f128(0xeb)]())throw CliErrors['validation'](_0x46f128(0xf1)+_0x130fb0);const _0x22e07d=toPosixPath(relative(_0x43adf1,_0x130fb0));if(_0x5db31f[_0x46f128(0xd0)]()){_0x182587(_0x130fb0);continue;}if(!_0x5db31f[_0x46f128(0xff)]())continue;validateSkillRelativePath(_0x22e07d);const _0x1127c4=readFileSync(_0x130fb0);_0x171fe[_0x46f128(0xd9)]({'path':_0x22e07d,'bytes':_0x1127c4});}}return _0x182587(_0x43adf1),normalizeLocalFiles(_0x171fe);}export function compareSkillFiles(_0x23d35a,_0x155d86){const _0x241836=a113_0x45a5;if(_0x23d35a[_0x241836(0xec)]===SKILL_FILE)return _0x155d86['path']===SKILL_FILE?0x0:-0x1;if(_0x155d86[_0x241836(0xec)]===SKILL_FILE)return 0x1;return Buffer[_0x241836(0xf6)](Buffer[_0x241836(0xd5)](_0x23d35a[_0x241836(0xec)],_0x241836(0xee)),Buffer[_0x241836(0xd5)](_0x155d86[_0x241836(0xec)],'utf8'));}export function normalizeSkillRelativePath(_0x3657a4){const _0x2eaa31=a113_0x45a5,_0x2a8908=toPosixPath(_0x3657a4[_0x2eaa31(0xd6)]());return validateSkillRelativePath(_0x2a8908),_0x2a8908;}export function validateSkillRelativePath(_0x14c9e1){const _0x420441=a113_0x45a5;if(!_0x14c9e1||_0x14c9e1[_0x420441(0x101)]('/')||_0x14c9e1['includes']('//'))throw CliErrors[_0x420441(0xe7)](_0x420441(0xf5)+_0x14c9e1);for(const _0x51072e of _0x14c9e1[_0x420441(0xd8)]('/')){if(!_0x51072e||_0x51072e==='.'||_0x51072e==='..')throw CliErrors[_0x420441(0xe7)](_0x420441(0xf5)+_0x14c9e1);}}export function toPosixPath(_0x1c730b){const _0x3261e4=a113_0x45a5;return _0x1c730b[_0x3261e4(0xd7)](/\\/g,'/');}export function isSha256Hex(_0x1bb7d3){const _0x30778e=a113_0x45a5;return typeof _0x1bb7d3===_0x30778e(0xfa)&&/^[a-fA-F0-9]{64}$/['test'](_0x1bb7d3);}
1
+ (function(_0x2c066c,_0x48d30c){const _0xfb6b5d=a113_0x2ee8,_0x2d19ca=_0x2c066c();while(!![]){try{const _0x42e779=parseInt(_0xfb6b5d(0x13f))/0x1+-parseInt(_0xfb6b5d(0x13e))/0x2+parseInt(_0xfb6b5d(0x122))/0x3*(parseInt(_0xfb6b5d(0x131))/0x4)+-parseInt(_0xfb6b5d(0x11b))/0x5*(parseInt(_0xfb6b5d(0x123))/0x6)+parseInt(_0xfb6b5d(0x126))/0x7*(-parseInt(_0xfb6b5d(0x11d))/0x8)+parseInt(_0xfb6b5d(0x119))/0x9*(parseInt(_0xfb6b5d(0x133))/0xa)+parseInt(_0xfb6b5d(0x12b))/0xb;if(_0x42e779===_0x48d30c)break;else _0x2d19ca['push'](_0x2d19ca['shift']());}catch(_0x20568d){_0x2d19ca['push'](_0x2d19ca['shift']());}}}(a113_0x36a5,0x7578f));import{readFileSync,readdirSync,realpathSync}from'node:fs';import{relative,resolve}from'node:path';import{CliErrors}from'../../errors.js';import{IGNORED_DIR_NAMES,IGNORED_FILE_NAMES,SKILL_FILE}from'./constants.js';export function fileContent(_0x562e7c){const _0x404280=a113_0x2ee8;return _0x562e7c['bytes']??Buffer['from'](_0x562e7c['content']??'',_0x404280(0x138));}export function fileText(_0x26a3c8){const _0x272f11=a113_0x2ee8;return fileContent(_0x26a3c8)[_0x272f11(0x140)](_0x272f11(0x138));}export function normalizeLocalFiles(_0x2bc939){const _0x4b16d1=a113_0x2ee8;if(!Array[_0x4b16d1(0x121)](_0x2bc939)||_0x2bc939[_0x4b16d1(0x120)]===0x0)return[];const _0x11f84f=new Map();for(const _0x257031 of _0x2bc939){if(!_0x257031||typeof _0x257031!==_0x4b16d1(0x118)||typeof _0x257031['path']!==_0x4b16d1(0x11c))throw CliErrors[_0x4b16d1(0x132)]('Skill\x20file\x20path\x20must\x20be\x20text.');const _0x2d91e3=normalizeSkillRelativePath(_0x257031[_0x4b16d1(0x117)]);if(_0x11f84f[_0x4b16d1(0x12c)](_0x2d91e3))throw CliErrors['validation'](_0x4b16d1(0x145)+_0x2d91e3);if(_0x257031[_0x4b16d1(0x12f)]!==undefined&&!Buffer[_0x4b16d1(0x13a)](_0x257031[_0x4b16d1(0x12f)]))throw CliErrors['validation'](_0x4b16d1(0x124)+_0x2d91e3);if(_0x257031[_0x4b16d1(0x12f)]===undefined&&typeof _0x257031['content']!==_0x4b16d1(0x11c))throw CliErrors[_0x4b16d1(0x132)](_0x4b16d1(0x11a)+_0x2d91e3);const _0x47f185=fileContent(_0x257031);_0x11f84f[_0x4b16d1(0x136)](_0x2d91e3,{'path':_0x2d91e3,'bytes':_0x47f185});}return Array[_0x4b16d1(0x13d)](_0x11f84f[_0x4b16d1(0x144)]())[_0x4b16d1(0x11f)](compareSkillFiles);}function a113_0x36a5(){const _0xfe6cee=['isBuffer','trim','split','from','1801676vjbNmi','754193IkhbTF','toString','includes','sha256','name','values','Duplicate\x20Skill\x20file\x20path:\x20','path','object','4443651hIUMyO','Skill\x20file\x20content\x20must\x20be\x20text\x20or\x20bytes:\x20','375bynemr','string','16jWEMaQ','replace','sort','length','isArray','6CqVMNc','1662Fvhatj','Skill\x20file\x20bytes\x20must\x20be\x20a\x20Buffer:\x20','compare','2131661TqPgnO','Skill\x20file\x20size\x20is\x20invalid:\x20','test','isSymbolicLink','isSafeInteger','8179072mokKeh','has','Skill\x20file\x20sha256\x20is\x20invalid:\x20','isFile','bytes','excludedFilePaths','40684pMkfpx','validation','10bpFnYI','isDirectory','size','set','add','utf8','Unsafe\x20Skill\x20file\x20path:\x20'];a113_0x36a5=function(){return _0xfe6cee;};return a113_0x36a5();}export function normalizeManifestFiles(_0x166b69){const _0x443e66=a113_0x2ee8;if(!Array[_0x443e66(0x121)](_0x166b69)||_0x166b69['length']===0x0)return[];const _0x30e41a=new Map();for(const _0x586c7b of _0x166b69){if(!_0x586c7b||typeof _0x586c7b!=='object'||typeof _0x586c7b[_0x443e66(0x117)]!=='string')throw CliErrors['validation']('Skill\x20file\x20path\x20must\x20be\x20text.');const _0x58e2f7=normalizeSkillRelativePath(_0x586c7b[_0x443e66(0x117)]);if(_0x30e41a['has'](_0x58e2f7))throw CliErrors[_0x443e66(0x132)](_0x443e66(0x145)+_0x58e2f7);if(!isSha256Hex(_0x586c7b['sha256']))throw CliErrors[_0x443e66(0x132)](_0x443e66(0x12d)+_0x58e2f7);if(!Number[_0x443e66(0x12a)](_0x586c7b[_0x443e66(0x135)])||_0x586c7b[_0x443e66(0x135)]<0x0)throw CliErrors[_0x443e66(0x132)](_0x443e66(0x127)+_0x58e2f7);_0x30e41a[_0x443e66(0x136)](_0x58e2f7,{'path':_0x58e2f7,'sha256':_0x586c7b[_0x443e66(0x142)]['toLowerCase'](),'size':_0x586c7b[_0x443e66(0x135)]});}return Array[_0x443e66(0x13d)](_0x30e41a['values']())[_0x443e66(0x11f)](compareSkillFiles);}export function scanSkillDirectory(_0x1f58b3,_0x3a3aa4={}){const _0x14267e=a113_0x2ee8,_0x183a09=realpathSync(_0x1f58b3),_0x32c864=canonicalExcludedFilePaths(_0x3a3aa4[_0x14267e(0x130)]),_0x50de5b=[];function _0x17bef7(_0x582c3c){const _0x2742ba=_0x14267e,_0x13e2ef=readdirSync(_0x582c3c,{'withFileTypes':!![]})['sort']((_0x471194,_0x52ad7a)=>_0x471194['name']['localeCompare'](_0x52ad7a['name']));for(const _0x230558 of _0x13e2ef){if(_0x230558[_0x2742ba(0x134)]()&&IGNORED_DIR_NAMES[_0x2742ba(0x12c)](_0x230558[_0x2742ba(0x143)]))continue;if(IGNORED_FILE_NAMES[_0x2742ba(0x12c)](_0x230558[_0x2742ba(0x143)]))continue;const _0x15cbfd=resolve(_0x582c3c,_0x230558[_0x2742ba(0x143)]);if(isExcludedFilePath(_0x15cbfd,_0x32c864))continue;if(_0x230558[_0x2742ba(0x129)]())throw CliErrors[_0x2742ba(0x132)]('Skill\x20directory\x20contains\x20unsupported\x20symlink:\x20'+_0x15cbfd);const _0x51fe7e=toPosixPath(relative(_0x183a09,_0x15cbfd));if(_0x230558[_0x2742ba(0x134)]()){_0x17bef7(_0x15cbfd);continue;}if(!_0x230558[_0x2742ba(0x12e)]())continue;validateSkillRelativePath(_0x51fe7e);const _0x3a72d5=readFileSync(_0x15cbfd);_0x50de5b['push']({'path':_0x51fe7e,'bytes':_0x3a72d5});}}return _0x17bef7(_0x183a09),normalizeLocalFiles(_0x50de5b);}function a113_0x2ee8(_0x440d8d,_0x4e08d7){_0x440d8d=_0x440d8d-0x117;const _0x36a53a=a113_0x36a5();let _0x2ee867=_0x36a53a[_0x440d8d];return _0x2ee867;}function canonicalExcludedFilePaths(_0xcb5006){const _0x508947=a113_0x2ee8,_0x422d9a=new Set();for(const _0x11b541 of _0xcb5006??[]){const _0xc48b5c=resolve(_0x11b541);_0x422d9a[_0x508947(0x137)](_0xc48b5c);try{_0x422d9a[_0x508947(0x137)](realpathSync(_0xc48b5c));}catch{}}return _0x422d9a;}function isExcludedFilePath(_0x27bba7,_0x49369d){const _0x5189d6=a113_0x2ee8;if(_0x49369d[_0x5189d6(0x12c)](_0x27bba7))return!![];if(_0x49369d[_0x5189d6(0x135)]===0x0)return![];try{return _0x49369d[_0x5189d6(0x12c)](realpathSync(_0x27bba7));}catch{return![];}}export function compareSkillFiles(_0x183493,_0x304e95){const _0x1efa88=a113_0x2ee8;if(_0x183493[_0x1efa88(0x117)]===SKILL_FILE)return _0x304e95[_0x1efa88(0x117)]===SKILL_FILE?0x0:-0x1;if(_0x304e95[_0x1efa88(0x117)]===SKILL_FILE)return 0x1;return Buffer[_0x1efa88(0x125)](Buffer['from'](_0x183493['path'],'utf8'),Buffer['from'](_0x304e95[_0x1efa88(0x117)],_0x1efa88(0x138)));}export function normalizeSkillRelativePath(_0x2a5635){const _0x529d89=a113_0x2ee8,_0x6573b4=toPosixPath(_0x2a5635[_0x529d89(0x13b)]());return validateSkillRelativePath(_0x6573b4),_0x6573b4;}export function validateSkillRelativePath(_0x3e030d){const _0x60972a=a113_0x2ee8;if(!_0x3e030d||_0x3e030d['startsWith']('/')||_0x3e030d[_0x60972a(0x141)]('//'))throw CliErrors[_0x60972a(0x132)](_0x60972a(0x139)+_0x3e030d);for(const _0x410fc6 of _0x3e030d[_0x60972a(0x13c)]('/')){if(!_0x410fc6||_0x410fc6==='.'||_0x410fc6==='..')throw CliErrors[_0x60972a(0x132)]('Unsafe\x20Skill\x20file\x20path:\x20'+_0x3e030d);}}export function toPosixPath(_0x1cba31){const _0x286852=a113_0x2ee8;return _0x1cba31[_0x286852(0x11e)](/\\/g,'/');}export function isSha256Hex(_0x2d7654){const _0x737272=a113_0x2ee8;return typeof _0x2d7654===_0x737272(0x11c)&&/^[a-fA-F0-9]{64}$/[_0x737272(0x128)](_0x2d7654);}
@@ -1 +1 @@
1
- (function(_0x16a30f,_0x5051f7){const _0x1e8f5c=a114_0x41db,_0x28c6fe=_0x16a30f();while(!![]){try{const _0x49cb7c=-parseInt(_0x1e8f5c(0x83))/0x1*(parseInt(_0x1e8f5c(0x75))/0x2)+-parseInt(_0x1e8f5c(0x94))/0x3+parseInt(_0x1e8f5c(0x8c))/0x4+-parseInt(_0x1e8f5c(0x76))/0x5*(parseInt(_0x1e8f5c(0x99))/0x6)+parseInt(_0x1e8f5c(0x95))/0x7+-parseInt(_0x1e8f5c(0x92))/0x8+parseInt(_0x1e8f5c(0xa1))/0x9;if(_0x49cb7c===_0x5051f7)break;else _0x28c6fe['push'](_0x28c6fe['shift']());}catch(_0x1b5ee9){_0x28c6fe['push'](_0x28c6fe['shift']());}}}(a114_0x3955,0x64ea3));import{existsSync,lstatSync,mkdirSync,readFileSync,rmSync}from'node:fs';import{dirname,resolve}from'node:path';import{isCollection,isMap,isNode,parseDocument,visit}from'yaml';import{CliErrors}from'../../errors.js';import{METADATA_FILE,SKILL_FILE}from'./constants.js';import{resolveManagedFilePath,writeBytesAtomic,writeJsonAtomic}from'./fs-utils.js';import{bufferSha256,contentHash,fileHash}from'./hashing.js';import{fileContent,fileText,normalizeLocalFiles}from'./local-files.js';import{buildMetadata,readMetadataIfPresent,requireSkillCode}from'./metadata.js';import{getRuntimeSkillDir}from'./paths.js';import{extractDownloadedPackage,requirePackageBytes}from'./zip-package.js';export function materializeRuntimeSkill(_0x3cb54f,_0x187810,_0x1697e4){const _0x11a50a=a114_0x41db,_0xf8ead6=requireSkillCode(_0x3cb54f),_0x2e2ee7=requirePackageBytes(_0xf8ead6,_0x1697e4[_0x11a50a(0x84)]),_0x425bf5=extractDownloadedPackage(_0x2e2ee7),_0x13efe6=_0x425bf5[_0x11a50a(0x78)](_0x4545fb=>_0x4545fb[_0x11a50a(0x69)]===SKILL_FILE);if(!_0x13efe6)throw CliErrors['validation'](_0x11a50a(0x82)+SKILL_FILE+':\x20'+_0xf8ead6);const _0x410b8b=withMaterializedSkillFrontmatter(_0x425bf5,_0x3cb54f,_0xf8ead6),_0x58a95e=_0x410b8b[_0x11a50a(0x78)](_0x4c7e5f=>_0x4c7e5f[_0x11a50a(0x69)]===SKILL_FILE),_0x554986=fileText(_0x58a95e),_0x590aea=getRuntimeSkillDir(_0x1697e4[_0x11a50a(0x96)],_0x1697e4[_0x11a50a(0x7f)],_0x1697e4[_0x11a50a(0x9b)],_0x187810,_0xf8ead6,_0x1697e4[_0x11a50a(0x98)]),_0x4cc619=resolve(_0x590aea,SKILL_FILE),_0x55603a=resolve(_0x590aea,METADATA_FILE),_0x2eee6d=contentHash(_0x554986),_0x5cd0aa=readMetadataIfPresent(_0x55603a)?.[_0x11a50a(0x81)];ensurePulledFilesCanBeOverwritten(_0x590aea,_0x55603a,_0x410b8b,_0x1697e4[_0x11a50a(0x6d)]===!![]),mkdirSync(_0x590aea,{'recursive':!![],'mode':0x1c0});const _0x42eef7=existsSync(_0x4cc619)?readFileSync(_0x4cc619,'utf8'):undefined;return materializeFiles(_0x590aea,_0x410b8b),removeStaleManagedFiles(_0x590aea,_0x5cd0aa,_0x410b8b),writeJsonAtomic(_0x55603a,buildMetadata(_0x3cb54f,_0x187810,_0x1697e4[_0x11a50a(0x9b)],_0x2eee6d,_0x1697e4[_0x11a50a(0xa0)],_0x410b8b,_0x2e2ee7)),{'skill':_0x3cb54f,'scope':_0x187810,'dir':_0x590aea,'skillMdPath':_0x4cc619,'metadataPath':_0x55603a,'contentHash':_0x2eee6d,'changed':_0x42eef7!==_0x554986};}function withMaterializedSkillFrontmatter(_0x27bcec,_0x102003,_0x2b9a02){const _0x4bc87f=a114_0x41db,_0x1b92a0=skillDisplayName(_0x102003,_0x2b9a02),_0x1aec58=_0x102003['description']?.[_0x4bc87f(0x8f)]()||_0x1b92a0||_0x2b9a02;return normalizeLocalFiles(_0x27bcec)[_0x4bc87f(0x6a)](_0x17f11b=>{const _0x5e819c=_0x4bc87f,_0x151333=fileText(_0x17f11b);if(_0x17f11b[_0x5e819c(0x69)]!==SKILL_FILE)return _0x17f11b;if(hasYamlFrontmatter(_0x151333))return{'path':_0x17f11b[_0x5e819c(0x69)],'content':withSyncedDisplayName(_0x151333,_0x1b92a0)};return{'path':_0x17f11b['path'],'content':prependSkillFrontmatter(_0x151333,{'name':_0x2b9a02,'displayName':_0x1b92a0,'description':_0x1aec58})};});}function hasYamlFrontmatter(_0x38a2a8){const _0x4ec363=a114_0x41db;return/^\uFEFF?---\s*\r?\n/[_0x4ec363(0x7d)](_0x38a2a8);}function prependSkillFrontmatter(_0x534e3a,_0x23d7ee){const _0xecd071=a114_0x41db,_0x69050a=_0x534e3a['replace'](/^\uFEFF/,'');return[_0xecd071(0x9e),_0xecd071(0x71)+yamlString(_0x23d7ee[_0xecd071(0x7c)]),_0x23d7ee[_0xecd071(0x8b)]?_0xecd071(0x7a)+yamlString(_0x23d7ee['displayName']):undefined,_0xecd071(0x6b)+yamlString(_0x23d7ee['description']),_0xecd071(0x9e),'',_0x69050a][_0xecd071(0x8d)](_0x5944ae=>_0x5944ae!==undefined)['join']('\x0a');}function yamlString(_0x346c02){const _0x37d2f5=a114_0x41db;return JSON[_0x37d2f5(0x72)](_0x346c02[_0x37d2f5(0x91)](/\r/g,'')[_0x37d2f5(0x8f)]());}function skillDisplayName(_0x55a5af,_0x118584){const _0x5f0aa2=a114_0x41db,_0x4d08ba=_0x55a5af[_0x5f0aa2(0x89)]?.[_0x5f0aa2(0x8f)]();return _0x4d08ba||_0x118584;}function withSyncedDisplayName(_0x4006f0,_0x3462b2){const _0x47816d=a114_0x41db,_0x325836=_0x4006f0[_0x47816d(0x7e)](/^(\uFEFF?)---\s*\r?\n([\s\S]*?)\r?\n---(?:\r?\n|$)/);if(!_0x325836)return _0x4006f0;const _0x3a0aa7=_0x325836[0x1]??'',_0x57a4c2=_0x325836[0x2]??'',_0x44c77e=parseDocument(_0x57a4c2);if(_0x44c77e[_0x47816d(0x79)][_0x47816d(0x90)]>0x0||!isMap(_0x44c77e['contents']))return _0x4006f0;if(_0x3462b2)_0x44c77e[_0x47816d(0x87)](_0x47816d(0x8b),_0x3462b2);else{if(_0x44c77e['has']('displayName'))_0x44c77e[_0x47816d(0x93)](_0x47816d(0x8b));else return _0x4006f0;}forceBlockCollections(_0x44c77e['contents']);const _0x4efee4=_0x44c77e[_0x47816d(0x8e)]({'lineWidth':0x0})[_0x47816d(0x77)](),_0x518ed0=_0x4006f0[_0x47816d(0x74)](_0x325836[0x0]['length'])[_0x47816d(0x91)](/^\r?\n/,'');return _0x3a0aa7+_0x47816d(0x6c)+_0x4efee4+_0x47816d(0x70)+_0x518ed0;}function a114_0x3955(){const _0x2154c1=['Managed\x20file\x20was\x20removed\x20locally:\x20','name','test','match','accessKey','has','fileHashes','Runtime\x20Skill\x20package\x20is\x20missing\x20','76547QKacmc','packageBytes','Remote\x20Skill\x20would\x20overwrite\x20a\x20local\x20non-file\x20path:\x20','flow','set','keys','skillName','.\x20Changed\x20file:\x20','displayName','2393496WcMRWx','filter','toString','trim','length','replace','4683832fZusMY','delete','960792JuNUdz','3526656qgtiNk','env','entries','paths','42bXcwoc','Local\x20Skill\x20files\x20have\x20unpushed\x20edits:\x20','appCode','validation','isFile','---','Remote\x20Skill\x20would\x20overwrite\x20an\x20unmanaged\x20local\x20file:\x20','pulledAt','13266378bEgkFN','Push\x20the\x20directory\x20first,\x20then\x20rerun\x20skill\x20install.','path','map','description:\x20','---\x0a','force','Managed\x20file\x20is\x20no\x20longer\x20a\x20regular\x20file:\x20','Push\x20the\x20directory\x20first,\x20then\x20rerun\x20skill\x20install.\x20Changed\x20file:\x20','\x0a---\x0a\x0a','name:\x20','stringify','contentHash','slice','18WNqyNl','405865ElDHug','trimEnd','find','errors','displayName:\x20'];a114_0x3955=function(){return _0x2154c1;};return a114_0x3955();}function forceBlockCollections(_0x3acf0f){if(!isNode(_0x3acf0f))return;visit(_0x3acf0f,(_0x5425f4,_0x485c36)=>{const _0x152d40=a114_0x41db;isCollection(_0x485c36)&&(_0x485c36[_0x152d40(0x86)]=![]);});}function ensurePulledFilesCanBeOverwritten(_0x4e3d5f,_0x3c2e7c,_0x5a70eb,_0x518cc9){const _0x598e9e=a114_0x41db;if(_0x518cc9||!existsSync(_0x3c2e7c))return;const _0x40e7c2=readMetadataIfPresent(_0x3c2e7c);if(!_0x40e7c2)return;const _0x3ce0d4=_0x40e7c2[_0x598e9e(0x81)]&&Object[_0x598e9e(0x88)](_0x40e7c2[_0x598e9e(0x81)])['length']>0x0?_0x40e7c2['fileHashes']:undefined;if(_0x3ce0d4)for(const [_0x4242b6,_0x51a4ca]of Object[_0x598e9e(0x97)](_0x3ce0d4)){const _0x2b1e90=resolveManagedFilePath(_0x4e3d5f,_0x4242b6);if(!existsSync(_0x2b1e90))throw CliErrors[_0x598e9e(0x9c)](_0x598e9e(0x9a)+_0x4e3d5f,_0x598e9e(0x7b)+_0x4242b6);const _0x55a39f=lstatSync(_0x2b1e90);if(!_0x55a39f[_0x598e9e(0x9d)]())throw CliErrors[_0x598e9e(0x9c)](_0x598e9e(0x9a)+_0x4e3d5f,_0x598e9e(0x6e)+_0x4242b6);const _0x4856f6=bufferSha256(readFileSync(_0x2b1e90));if(_0x4856f6!==_0x51a4ca)throw CliErrors['validation']('Local\x20Skill\x20files\x20have\x20unpushed\x20edits:\x20'+_0x4e3d5f+_0x598e9e(0x8a)+_0x4242b6,_0x598e9e(0x6f)+_0x4242b6);}else{const _0x5868ad=resolve(_0x4e3d5f,SKILL_FILE);if(existsSync(_0x5868ad)&&_0x40e7c2[_0x598e9e(0x73)]){const _0x1cadda=contentHash(readFileSync(_0x5868ad,'utf8'));if(_0x1cadda!==_0x40e7c2[_0x598e9e(0x73)])throw CliErrors['validation']('Local\x20SKILL.md\x20has\x20unpushed\x20edits:\x20'+_0x5868ad,_0x598e9e(0x68));}}for(const _0x50d886 of normalizeLocalFiles(_0x5a70eb)){if(_0x3ce0d4?.[_0x50d886[_0x598e9e(0x69)]])continue;if(!_0x3ce0d4&&_0x50d886[_0x598e9e(0x69)]===SKILL_FILE)continue;const _0x1a72b6=resolveManagedFilePath(_0x4e3d5f,_0x50d886[_0x598e9e(0x69)]);if(!existsSync(_0x1a72b6))continue;const _0x3c88cd=lstatSync(_0x1a72b6);if(!_0x3c88cd[_0x598e9e(0x9d)]())throw CliErrors[_0x598e9e(0x9c)](_0x598e9e(0x9a)+_0x4e3d5f,_0x598e9e(0x85)+_0x50d886['path']);const _0x4f3a3b=bufferSha256(readFileSync(_0x1a72b6));if(_0x4f3a3b!==fileHash(_0x50d886))throw CliErrors[_0x598e9e(0x9c)](_0x598e9e(0x9a)+_0x4e3d5f,_0x598e9e(0x9f)+_0x50d886[_0x598e9e(0x69)]);}}function a114_0x41db(_0x20c85d,_0x54ef92){_0x20c85d=_0x20c85d-0x68;const _0x3955d4=a114_0x3955();let _0x41dba4=_0x3955d4[_0x20c85d];return _0x41dba4;}function materializeFiles(_0x112db7,_0x4b99df){const _0x2b6dca=a114_0x41db;for(const _0x52a409 of normalizeLocalFiles(_0x4b99df)){const _0x2e9a55=resolveManagedFilePath(_0x112db7,_0x52a409[_0x2b6dca(0x69)]);mkdirSync(dirname(_0x2e9a55),{'recursive':!![],'mode':0x1c0}),writeBytesAtomic(_0x2e9a55,fileContent(_0x52a409),0x180);}}function removeStaleManagedFiles(_0x516532,_0x47beb8,_0x990ee7){const _0x6f343c=a114_0x41db;if(!_0x47beb8)return;const _0x39ac68=new Set(normalizeLocalFiles(_0x990ee7)[_0x6f343c(0x6a)](_0x764aa4=>_0x764aa4[_0x6f343c(0x69)]));for(const _0x541c8f of Object[_0x6f343c(0x88)](_0x47beb8)){if(_0x39ac68[_0x6f343c(0x80)](_0x541c8f))continue;const _0x4a8911=resolveManagedFilePath(_0x516532,_0x541c8f);existsSync(_0x4a8911)&&lstatSync(_0x4a8911)[_0x6f343c(0x9d)]()&&rmSync(_0x4a8911,{'force':!![]});}}
1
+ (function(_0x3577ed,_0x3c062a){const _0x29036f=a114_0x5160,_0x438be2=_0x3577ed();while(!![]){try{const _0x3b3001=parseInt(_0x29036f(0x9a))/0x1+parseInt(_0x29036f(0xa3))/0x2+parseInt(_0x29036f(0xb6))/0x3*(-parseInt(_0x29036f(0x8f))/0x4)+-parseInt(_0x29036f(0x91))/0x5*(parseInt(_0x29036f(0xba))/0x6)+-parseInt(_0x29036f(0x99))/0x7*(parseInt(_0x29036f(0xa0))/0x8)+-parseInt(_0x29036f(0xac))/0x9*(-parseInt(_0x29036f(0xa1))/0xa)+parseInt(_0x29036f(0xb1))/0xb;if(_0x3b3001===_0x3c062a)break;else _0x438be2['push'](_0x438be2['shift']());}catch(_0x1d57ea){_0x438be2['push'](_0x438be2['shift']());}}}(a114_0x6460,0x6f372));function a114_0x6460(){const _0x45a4f1=['6odLVZM','flow','Push\x20the\x20directory\x20first,\x20then\x20rerun\x20skill\x20install.','set','---','errors','join','find','contents','replace','name','---\x0a','filter','6836zmPhtb','name:\x20','2673485AqJjNc','Push\x20the\x20directory\x20first,\x20then\x20rerun\x20skill\x20install.\x20Changed\x20file:\x20','Managed\x20file\x20is\x20no\x20longer\x20a\x20regular\x20file:\x20','path','accessKey','validation','Runtime\x20Skill\x20package\x20is\x20missing\x20','Managed\x20file\x20was\x20removed\x20locally:\x20','5948124IbMEBf','39039BzOvZG','appCode','slice','utf8','map','entries','8jddcmL','10oPEHCb','displayName','1697030LVQkuF','has','packageBytes','trim','length','skillName','toString','displayName:\x20','Local\x20Skill\x20files\x20have\x20unpushed\x20edits:\x20','3029139edUuwc','keys','Remote\x20Skill\x20would\x20overwrite\x20a\x20local\x20non-file\x20path:\x20','description','paths','12921535lXbxMN','Remote\x20Skill\x20would\x20overwrite\x20an\x20unmanaged\x20local\x20file:\x20','fileHashes','contentHash','trimEnd','981VIkMIU','env','isFile','\x0a---\x0a\x0a'];a114_0x6460=function(){return _0x45a4f1;};return a114_0x6460();}import{existsSync,lstatSync,mkdirSync,readFileSync,rmSync}from'node:fs';import{dirname,resolve}from'node:path';import{isCollection,isMap,isNode,parseDocument,visit}from'yaml';import{CliErrors}from'../../errors.js';import{METADATA_FILE,SKILL_FILE}from'./constants.js';import{resolveManagedFilePath,writeBytesAtomic,writeJsonAtomic}from'./fs-utils.js';import{bufferSha256,contentHash,fileHash}from'./hashing.js';import{fileContent,fileText,normalizeLocalFiles}from'./local-files.js';function a114_0x5160(_0x16473f,_0x57c357){_0x16473f=_0x16473f-0x8e;const _0x646038=a114_0x6460();let _0x516063=_0x646038[_0x16473f];return _0x516063;}import{buildMetadata,readMetadataIfPresent,requireSkillCode}from'./metadata.js';import{getRuntimeSkillDir}from'./paths.js';import{extractDownloadedPackage,requirePackageBytes}from'./zip-package.js';export function materializeRuntimeSkill(_0x2ed8d0,_0x48bc0c,_0x3d2230){const _0x5f4211=a114_0x5160,_0x23a216=requireSkillCode(_0x2ed8d0),_0x1a74d5=requirePackageBytes(_0x23a216,_0x3d2230[_0x5f4211(0xa5)]),_0x3c2284=extractDownloadedPackage(_0x1a74d5),_0x39a76d=_0x3c2284[_0x5f4211(0xc1)](_0x24eb87=>_0x24eb87[_0x5f4211(0x94)]===SKILL_FILE);if(!_0x39a76d)throw CliErrors['validation'](_0x5f4211(0x97)+SKILL_FILE+':\x20'+_0x23a216);const _0x4c248c=withMaterializedSkillFrontmatter(_0x3c2284,_0x2ed8d0,_0x23a216),_0x1c3a8f=_0x4c248c['find'](_0x11a742=>_0x11a742[_0x5f4211(0x94)]===SKILL_FILE),_0xf2aa7e=fileText(_0x1c3a8f),_0x1c22b3=getRuntimeSkillDir(_0x3d2230[_0x5f4211(0xb7)],_0x3d2230[_0x5f4211(0x95)],_0x3d2230[_0x5f4211(0x9b)],_0x48bc0c,_0x23a216,_0x3d2230[_0x5f4211(0xb0)]),_0x460752=resolve(_0x1c22b3,SKILL_FILE),_0x585458=resolve(_0x1c22b3,METADATA_FILE),_0x527177=contentHash(_0xf2aa7e),_0x8bf846=readMetadataIfPresent(_0x585458)?.[_0x5f4211(0xb3)];ensurePulledFilesCanBeOverwritten(_0x1c22b3,_0x585458,_0x4c248c,_0x3d2230['force']===!![]),mkdirSync(_0x1c22b3,{'recursive':!![],'mode':0x1c0});const _0x2c0539=existsSync(_0x460752)?readFileSync(_0x460752,_0x5f4211(0x9d)):undefined;return materializeFiles(_0x1c22b3,_0x4c248c),removeStaleManagedFiles(_0x1c22b3,_0x8bf846,_0x4c248c),writeJsonAtomic(_0x585458,buildMetadata(_0x2ed8d0,_0x48bc0c,_0x3d2230[_0x5f4211(0x9b)],_0x527177,_0x3d2230['pulledAt'],_0x4c248c,_0x1a74d5)),{'skill':_0x2ed8d0,'scope':_0x48bc0c,'dir':_0x1c22b3,'skillMdPath':_0x460752,'metadataPath':_0x585458,'contentHash':_0x527177,'changed':_0x2c0539!==_0xf2aa7e};}function withMaterializedSkillFrontmatter(_0x4f6e3a,_0x4f0632,_0x484393){const _0x3cbceb=a114_0x5160,_0x553e81=skillDisplayName(_0x4f0632,_0x484393),_0x501b7a=_0x4f0632[_0x3cbceb(0xaf)]?.['trim']()||_0x553e81||_0x484393;return normalizeLocalFiles(_0x4f6e3a)[_0x3cbceb(0x9e)](_0x272be0=>{const _0x27a52d=_0x3cbceb,_0x45620e=fileText(_0x272be0);if(_0x272be0['path']!==SKILL_FILE)return _0x272be0;if(hasYamlFrontmatter(_0x45620e))return{'path':_0x272be0[_0x27a52d(0x94)],'content':withSyncedDisplayName(_0x45620e,_0x553e81)};return{'path':_0x272be0[_0x27a52d(0x94)],'content':prependSkillFrontmatter(_0x45620e,{'name':_0x484393,'displayName':_0x553e81,'description':_0x501b7a})};});}function hasYamlFrontmatter(_0x58d83c){return/^\uFEFF?---\s*\r?\n/['test'](_0x58d83c);}function prependSkillFrontmatter(_0x43c30f,_0x19e4f8){const _0x42ff7c=a114_0x5160,_0x154ca7=_0x43c30f[_0x42ff7c(0xc3)](/^\uFEFF/,'');return['---',_0x42ff7c(0x90)+yamlString(_0x19e4f8[_0x42ff7c(0xc4)]),_0x19e4f8[_0x42ff7c(0xa2)]?_0x42ff7c(0xaa)+yamlString(_0x19e4f8[_0x42ff7c(0xa2)]):undefined,'description:\x20'+yamlString(_0x19e4f8[_0x42ff7c(0xaf)]),_0x42ff7c(0xbe),'',_0x154ca7][_0x42ff7c(0x8e)](_0x2c255c=>_0x2c255c!==undefined)[_0x42ff7c(0xc0)]('\x0a');}function yamlString(_0x330396){const _0x5cd924=a114_0x5160;return JSON['stringify'](_0x330396[_0x5cd924(0xc3)](/\r/g,'')[_0x5cd924(0xa6)]());}function skillDisplayName(_0x374613,_0x2da2db){const _0x17e259=a114_0x5160,_0x44396d=_0x374613[_0x17e259(0xa8)]?.[_0x17e259(0xa6)]();return _0x44396d||_0x2da2db;}function withSyncedDisplayName(_0x2763a9,_0x2deac2){const _0x4bf730=a114_0x5160,_0x3cce70=_0x2763a9['match'](/^(\uFEFF?)---\s*\r?\n([\s\S]*?)\r?\n---(?:\r?\n|$)/);if(!_0x3cce70)return _0x2763a9;const _0x532a54=_0x3cce70[0x1]??'',_0x4c676e=_0x3cce70[0x2]??'',_0x1f30ea=parseDocument(_0x4c676e);if(_0x1f30ea[_0x4bf730(0xbf)][_0x4bf730(0xa7)]>0x0||!isMap(_0x1f30ea['contents']))return _0x2763a9;if(_0x2deac2)_0x1f30ea[_0x4bf730(0xbd)](_0x4bf730(0xa2),_0x2deac2);else{if(_0x1f30ea[_0x4bf730(0xa4)](_0x4bf730(0xa2)))_0x1f30ea['delete'](_0x4bf730(0xa2));else return _0x2763a9;}forceBlockCollections(_0x1f30ea[_0x4bf730(0xc2)]);const _0x47feea=_0x1f30ea[_0x4bf730(0xa9)]({'lineWidth':0x0})[_0x4bf730(0xb5)](),_0x10e646=_0x2763a9[_0x4bf730(0x9c)](_0x3cce70[0x0]['length'])[_0x4bf730(0xc3)](/^\r?\n/,'');return _0x532a54+_0x4bf730(0xc5)+_0x47feea+_0x4bf730(0xb9)+_0x10e646;}function forceBlockCollections(_0x10dbd8){if(!isNode(_0x10dbd8))return;visit(_0x10dbd8,(_0x4e7c2e,_0x475501)=>{const _0x64ba92=a114_0x5160;isCollection(_0x475501)&&(_0x475501[_0x64ba92(0xbb)]=![]);});}function ensurePulledFilesCanBeOverwritten(_0x9ed722,_0x1e0b25,_0x307d13,_0x309aaf){const _0x499ffa=a114_0x5160;if(_0x309aaf||!existsSync(_0x1e0b25))return;const _0xe1d97=readMetadataIfPresent(_0x1e0b25);if(!_0xe1d97)return;const _0x4ccbb0=_0xe1d97[_0x499ffa(0xb3)]&&Object[_0x499ffa(0xad)](_0xe1d97[_0x499ffa(0xb3)])[_0x499ffa(0xa7)]>0x0?_0xe1d97[_0x499ffa(0xb3)]:undefined;if(_0x4ccbb0)for(const [_0xf6b675,_0x2c67a4]of Object[_0x499ffa(0x9f)](_0x4ccbb0)){const _0x4efbed=resolveManagedFilePath(_0x9ed722,_0xf6b675);if(!existsSync(_0x4efbed))throw CliErrors['validation'](_0x499ffa(0xab)+_0x9ed722,_0x499ffa(0x98)+_0xf6b675);const _0x47893f=lstatSync(_0x4efbed);if(!_0x47893f[_0x499ffa(0xb8)]())throw CliErrors[_0x499ffa(0x96)](_0x499ffa(0xab)+_0x9ed722,_0x499ffa(0x93)+_0xf6b675);const _0x292823=bufferSha256(readFileSync(_0x4efbed));if(_0x292823!==_0x2c67a4)throw CliErrors[_0x499ffa(0x96)](_0x499ffa(0xab)+_0x9ed722+'.\x20Changed\x20file:\x20'+_0xf6b675,_0x499ffa(0x92)+_0xf6b675);}else{const _0xb31692=resolve(_0x9ed722,SKILL_FILE);if(existsSync(_0xb31692)&&_0xe1d97[_0x499ffa(0xb4)]){const _0x1982d7=contentHash(readFileSync(_0xb31692,_0x499ffa(0x9d)));if(_0x1982d7!==_0xe1d97[_0x499ffa(0xb4)])throw CliErrors[_0x499ffa(0x96)]('Local\x20SKILL.md\x20has\x20unpushed\x20edits:\x20'+_0xb31692,_0x499ffa(0xbc));}}for(const _0xf33346 of normalizeLocalFiles(_0x307d13)){if(_0x4ccbb0?.[_0xf33346[_0x499ffa(0x94)]])continue;if(!_0x4ccbb0&&_0xf33346[_0x499ffa(0x94)]===SKILL_FILE)continue;const _0x595074=resolveManagedFilePath(_0x9ed722,_0xf33346[_0x499ffa(0x94)]);if(!existsSync(_0x595074))continue;const _0x136756=lstatSync(_0x595074);if(!_0x136756[_0x499ffa(0xb8)]())throw CliErrors[_0x499ffa(0x96)]('Local\x20Skill\x20files\x20have\x20unpushed\x20edits:\x20'+_0x9ed722,_0x499ffa(0xae)+_0xf33346[_0x499ffa(0x94)]);const _0x5bee17=bufferSha256(readFileSync(_0x595074));if(_0x5bee17!==fileHash(_0xf33346))throw CliErrors[_0x499ffa(0x96)](_0x499ffa(0xab)+_0x9ed722,_0x499ffa(0xb2)+_0xf33346['path']);}}function materializeFiles(_0x204b5c,_0x2ab194){const _0x3d4fce=a114_0x5160;for(const _0x677f04 of normalizeLocalFiles(_0x2ab194)){const _0x1dea57=resolveManagedFilePath(_0x204b5c,_0x677f04[_0x3d4fce(0x94)]);mkdirSync(dirname(_0x1dea57),{'recursive':!![],'mode':0x1c0}),writeBytesAtomic(_0x1dea57,fileContent(_0x677f04),0x180);}}function removeStaleManagedFiles(_0x21b275,_0x5241ea,_0x5e3217){const _0x5e67d7=a114_0x5160;if(!_0x5241ea)return;const _0x3cc7c7=new Set(normalizeLocalFiles(_0x5e3217)[_0x5e67d7(0x9e)](_0x3edd9b=>_0x3edd9b['path']));for(const _0x548e2c of Object[_0x5e67d7(0xad)](_0x5241ea)){if(_0x3cc7c7['has'](_0x548e2c))continue;const _0x17fb4d=resolveManagedFilePath(_0x21b275,_0x548e2c);existsSync(_0x17fb4d)&&lstatSync(_0x17fb4d)[_0x5e67d7(0xb8)]()&&rmSync(_0x17fb4d,{'force':!![]});}}
@@ -1 +1 @@
1
- (function(_0x447466,_0x2ef466){const _0x59ebe0=a115_0xa9c6,_0x23e703=_0x447466();while(!![]){try{const _0x50bc8a=-parseInt(_0x59ebe0(0x1f5))/0x1+parseInt(_0x59ebe0(0x1ed))/0x2*(parseInt(_0x59ebe0(0x1e0))/0x3)+parseInt(_0x59ebe0(0x1df))/0x4*(parseInt(_0x59ebe0(0x1fa))/0x5)+parseInt(_0x59ebe0(0x1e4))/0x6+-parseInt(_0x59ebe0(0x1d7))/0x7+-parseInt(_0x59ebe0(0x1e7))/0x8*(parseInt(_0x59ebe0(0x1f1))/0x9)+-parseInt(_0x59ebe0(0x1fd))/0xa*(-parseInt(_0x59ebe0(0x1f9))/0xb);if(_0x50bc8a===_0x2ef466)break;else _0x23e703['push'](_0x23e703['shift']());}catch(_0x4cd9c9){_0x23e703['push'](_0x23e703['shift']());}}}(a115_0x4d61,0x2bd20));function a115_0xa9c6(_0x59de47,_0x434e02){_0x59de47=_0x59de47-0x1d7;const _0x4d6110=a115_0x4d61();let _0xa9c634=_0x4d6110[_0x59de47];return _0xa9c634;}import{existsSync,readFileSync}from'node:fs';import{CliErrors}from'../../errors.js';import{METADATA_FILE}from'./constants.js';import{bufferSha256,fileHash,fileTreeHash}from'./hashing.js';import{fileContent,normalizeLocalFiles}from'./local-files.js';import{buildSkillPackage,localFilesToManifestFiles}from'./zip-package.js';export function buildMetadata(_0xa1d8da,_0x212628,_0x283f0a,_0x1e527c,_0x51212d,_0x367de5,_0x35b35c){const _0x4e3c51=a115_0xa9c6,_0x43056e=_0x367de5?normalizeLocalFiles(_0x367de5):[],_0x1ebc3b=!_0x35b35c&&_0x43056e['length']>0x0?buildSkillPackage(_0x43056e):undefined,_0x1d1d03=_0x35b35c?bufferSha256(_0x35b35c):_0x1ebc3b?.[_0x4e3c51(0x1e5)]['zipSha256'],_0x4a7e73=_0x35b35c?.[_0x4e3c51(0x1f2)]??_0x1ebc3b?.['manifest'][_0x4e3c51(0x1f6)],_0x1f182e=_0x43056e['length']>0x0?Object[_0x4e3c51(0x1e9)](_0x43056e['map'](_0x453b46=>[_0x453b46[_0x4e3c51(0x1f8)],fileHash(_0x453b46)])):undefined;return{'schemaVersion':_0x43056e[_0x4e3c51(0x1f2)]>0x0?0x2:0x1,'id':_0xa1d8da['id'],'appCode':_0x283f0a,'skillCode':requireSkillCode(_0xa1d8da),'skillName':_0xa1d8da[_0x4e3c51(0x1d8)],'description':_0xa1d8da[_0x4e3c51(0x1f4)],'scope':_0x212628,'readonly':_0x212628!==_0x4e3c51(0x1e6)||_0xa1d8da[_0x4e3c51(0x1e8)]===!![],'tenantCode':_0xa1d8da[_0x4e3c51(0x1ef)],'userId':_0xa1d8da['userId'],'version':_0xa1d8da[_0x4e3c51(0x1f7)],'status':_0xa1d8da[_0x4e3c51(0x1f3)],'tags':Array[_0x4e3c51(0x1dd)](_0xa1d8da[_0x4e3c51(0x1d9)])?_0xa1d8da[_0x4e3c51(0x1d9)]:[],'hasUpstreamUpdate':_0xa1d8da[_0x4e3c51(0x1e3)],'forkedFromSkillId':_0xa1d8da[_0x4e3c51(0x1dc)],'forkedFromVersion':_0xa1d8da[_0x4e3c51(0x1da)],'sourceSessionId':_0xa1d8da[_0x4e3c51(0x1f0)],'contentHash':_0x1e527c,'fileHashes':_0x1f182e,'treeHash':_0x43056e[_0x4e3c51(0x1f2)]>0x0?fileTreeHash(localFilesToManifestFiles(_0x43056e)):undefined,'ossPath':remoteManifestOssPath(_0xa1d8da[_0x4e3c51(0x1db)]),'zipSha256':_0x1d1d03,'zipSize':_0x4a7e73,'files':_0x43056e[_0x4e3c51(0x1f2)]>0x0?_0x43056e[_0x4e3c51(0x1ec)](_0x5d86ed=>({'path':_0x5d86ed[_0x4e3c51(0x1f8)],'hash':fileHash(_0x5d86ed),'size':fileContent(_0x5d86ed)[_0x4e3c51(0x1f2)]})):undefined,'pulledAt':_0x51212d??new Date()[_0x4e3c51(0x1fb)]()};}export function requireSkillCode(_0x5ec7b7){const _0x5b2fb7=a115_0xa9c6,_0x543b33=_0x5ec7b7[_0x5b2fb7(0x1e1)]?.[_0x5b2fb7(0x1e2)]();if(!_0x543b33)throw CliErrors[_0x5b2fb7(0x1eb)](_0x5b2fb7(0x1fc));return _0x543b33;}export function readMetadataIfPresent(_0x3326d6){const _0x2fba22=a115_0xa9c6;if(!existsSync(_0x3326d6))return undefined;try{const _0x2d1e04=JSON['parse'](readFileSync(_0x3326d6,_0x2fba22(0x1ea)));return _0x2d1e04;}catch{throw CliErrors[_0x2fba22(0x1eb)]('Invalid\x20'+METADATA_FILE+':\x20'+_0x3326d6);}}function a115_0x4d61(){const _0x57742a=['zipSize','version','path','935mNwXyb','55ugdlPb','toISOString','Runtime\x20Skill\x20is\x20missing\x20skillCode.','44130wFcOji','1973048onYRZW','skillName','tags','forkedFromVersion','files','forkedFromSkillId','isArray','ossPath','52424FvAlov','424803NeklyG','skillCode','trim','hasUpstreamUpdate','806988Mbekdb','manifest','personal','883096eKbqHg','readonly','fromEntries','utf8','validation','map','2FjlpCw','object','tenantCode','sourceSessionId','9JGWwID','length','status','description','223631MXXpAZ'];a115_0x4d61=function(){return _0x57742a;};return a115_0x4d61();}function remoteManifestOssPath(_0x29429b){const _0xfa530c=a115_0xa9c6;if(!_0x29429b||typeof _0x29429b!==_0xfa530c(0x1ee)||Array[_0xfa530c(0x1dd)](_0x29429b))return undefined;const _0x455975=_0x29429b[_0xfa530c(0x1de)];return typeof _0x455975==='string'&&_0x455975[_0xfa530c(0x1e2)]()?_0x455975[_0xfa530c(0x1e2)]():undefined;}
1
+ (function(_0x37a6a6,_0x528f0d){const _0x196331=a115_0x3b90,_0x55214c=_0x37a6a6();while(!![]){try{const _0x47425f=parseInt(_0x196331(0x103))/0x1*(parseInt(_0x196331(0xfa))/0x2)+parseInt(_0x196331(0xf5))/0x3*(-parseInt(_0x196331(0x10a))/0x4)+parseInt(_0x196331(0x112))/0x5+-parseInt(_0x196331(0xfd))/0x6*(-parseInt(_0x196331(0x10c))/0x7)+parseInt(_0x196331(0x105))/0x8*(parseInt(_0x196331(0x104))/0x9)+parseInt(_0x196331(0xfb))/0xa+-parseInt(_0x196331(0x116))/0xb*(parseInt(_0x196331(0x115))/0xc);if(_0x47425f===_0x528f0d)break;else _0x55214c['push'](_0x55214c['shift']());}catch(_0x101998){_0x55214c['push'](_0x55214c['shift']());}}}(a115_0x253b,0x47d38));import{existsSync,readFileSync}from'node:fs';import{CliErrors}from'../../errors.js';import{METADATA_FILE}from'./constants.js';import{bufferSha256,fileHash,fileTreeHash}from'./hashing.js';import{fileContent,normalizeLocalFiles}from'./local-files.js';function a115_0x3b90(_0x510feb,_0x4f44c5){_0x510feb=_0x510feb-0xf5;const _0x253bef=a115_0x253b();let _0x3b90e7=_0x253bef[_0x510feb];return _0x3b90e7;}import{buildSkillPackage,localFilesToManifestFiles}from'./zip-package.js';export function buildMetadata(_0x455dbb,_0x5f14ef,_0x26b2f7,_0x43743d,_0x14fb6b,_0x5ee133,_0x4d58b5){const _0x22535a=a115_0x3b90,_0x360c91=_0x5ee133?normalizeLocalFiles(_0x5ee133):[],_0x262890=!_0x4d58b5&&_0x360c91[_0x22535a(0x102)]>0x0?buildSkillPackage(_0x360c91):undefined,_0x5338ff=_0x4d58b5?bufferSha256(_0x4d58b5):_0x262890?.[_0x22535a(0x111)][_0x22535a(0x110)],_0x5e7d20=_0x4d58b5?.[_0x22535a(0x102)]??_0x262890?.[_0x22535a(0x111)]['zipSize'],_0x241bcb=_0x360c91[_0x22535a(0x102)]>0x0?Object['fromEntries'](_0x360c91[_0x22535a(0x107)](_0x2aece1=>[_0x2aece1[_0x22535a(0x101)],fileHash(_0x2aece1)])):undefined;return{'schemaVersion':_0x360c91[_0x22535a(0x102)]>0x0?0x2:0x1,'id':_0x455dbb['id'],'appCode':_0x26b2f7,'skillCode':requireSkillCode(_0x455dbb),'skillName':_0x455dbb[_0x22535a(0xf8)],'description':_0x455dbb[_0x22535a(0x119)],'scope':_0x5f14ef,'readonly':_0x5f14ef!==_0x22535a(0x117)||_0x455dbb['readonly']===!![],'tenantCode':_0x455dbb[_0x22535a(0xfe)],'userId':_0x455dbb[_0x22535a(0xff)],'version':_0x455dbb['version'],'status':_0x455dbb[_0x22535a(0x108)],'tags':Array[_0x22535a(0x100)](_0x455dbb['tags'])?_0x455dbb['tags']:[],'hasUpstreamUpdate':_0x455dbb[_0x22535a(0x10f)],'forkedFromSkillId':_0x455dbb[_0x22535a(0x10e)],'forkedFromVersion':_0x455dbb[_0x22535a(0x113)],'sourceSessionId':_0x455dbb[_0x22535a(0x10d)],'contentHash':_0x43743d,'fileHashes':_0x241bcb,'treeHash':_0x360c91['length']>0x0?fileTreeHash(localFilesToManifestFiles(_0x360c91)):undefined,'ossPath':remoteManifestOssPath(_0x455dbb[_0x22535a(0xf9)]),'zipSha256':_0x5338ff,'zipSize':_0x5e7d20,'files':_0x360c91[_0x22535a(0x102)]>0x0?_0x360c91[_0x22535a(0x107)](_0x2dc06e=>({'path':_0x2dc06e[_0x22535a(0x101)],'hash':fileHash(_0x2dc06e),'size':fileContent(_0x2dc06e)['length']})):undefined,'pulledAt':_0x14fb6b??new Date()[_0x22535a(0x118)]()};}function a115_0x253b(){const _0x23fb49=['description','3cBZhJD','utf8','object','skillName','files','240010uMXSXx','5113720jCaoGs','skillCode','6HLDZCG','tenantCode','userId','isArray','path','length','3hubWPI','508347jejLdd','64fIaJvW','trim','map','status','validation','988772cDNsFq','ossPath','3350571cuiBDP','sourceSessionId','forkedFromSkillId','hasUpstreamUpdate','zipSha256','manifest','1968820KRpzcG','forkedFromVersion','parse','60eXkGuO','3639405SUFUMu','personal','toISOString'];a115_0x253b=function(){return _0x23fb49;};return a115_0x253b();}export function requireSkillCode(_0x35b41d){const _0x15ecbb=a115_0x3b90,_0x47038b=_0x35b41d[_0x15ecbb(0xfc)]?.['trim']();if(!_0x47038b)throw CliErrors[_0x15ecbb(0x109)]('Runtime\x20Skill\x20is\x20missing\x20skillCode.');return _0x47038b;}export function readMetadataIfPresent(_0x29f72f){const _0x5d86ba=a115_0x3b90;if(!existsSync(_0x29f72f))return undefined;try{const _0x5d1e04=JSON[_0x5d86ba(0x114)](readFileSync(_0x29f72f,_0x5d86ba(0xf6)));return _0x5d1e04;}catch{throw CliErrors['validation']('Invalid\x20'+METADATA_FILE+':\x20'+_0x29f72f);}}function remoteManifestOssPath(_0x58c60a){const _0xb2896f=a115_0x3b90;if(!_0x58c60a||typeof _0x58c60a!==_0xb2896f(0xf7)||Array['isArray'](_0x58c60a))return undefined;const _0x310a21=_0x58c60a[_0xb2896f(0x10b)];return typeof _0x310a21==='string'&&_0x310a21[_0xb2896f(0x106)]()?_0x310a21[_0xb2896f(0x106)]():undefined;}
@@ -1 +1 @@
1
- (function(_0x5bb123,_0x17b3e1){const _0x25f400=a116_0x14d9,_0x428e18=_0x5bb123();while(!![]){try{const _0x1a1b41=-parseInt(_0x25f400(0x193))/0x1+parseInt(_0x25f400(0x184))/0x2+-parseInt(_0x25f400(0x195))/0x3*(parseInt(_0x25f400(0x18d))/0x4)+parseInt(_0x25f400(0x187))/0x5*(parseInt(_0x25f400(0x194))/0x6)+parseInt(_0x25f400(0x182))/0x7+-parseInt(_0x25f400(0x18e))/0x8+parseInt(_0x25f400(0x183))/0x9;if(_0x1a1b41===_0x17b3e1)break;else _0x428e18['push'](_0x428e18['shift']());}catch(_0x10f44c){_0x428e18['push'](_0x428e18['shift']());}}}(a116_0x5427,0x3cefd));import{existsSync}from'node:fs';import{homedir}from'node:os';import{resolve}from'node:path';function a116_0x14d9(_0xcf86bb,_0x5edb82){_0xcf86bb=_0xcf86bb-0x182;const _0x542733=a116_0x5427();let _0x14d9eb=_0x542733[_0xcf86bb];return _0x14d9eb;}import{fingerprintAccessKey}from'../../commands/app/cache.js';import{PRODUCT_CONFIG,productEnv}from'../../constant/product.js';import{CliErrors}from'../../errors.js';export function resolveSkillSyncPaths(_0x491e1a={}){const _0x2e028f=a116_0x14d9,_0xec94f3=_0x491e1a[_0x2e028f(0x196)]??homedir(),_0x17d536=resolve(_0xec94f3,PRODUCT_CONFIG[_0x2e028f(0x189)],_0x2e028f(0x188)),_0x527794=trimmedEnv('SKILL_ROOT'),_0x364a90=trimmedEnv(_0x2e028f(0x18a)),_0x3a6dda=resolve(_0xec94f3,_0x2e028f(0x18c)),_0x1f81c9=_0x491e1a['workbuddySkillsDir']??(existsSync(_0x3a6dda)?resolve(_0x3a6dda,_0x2e028f(0x190)):undefined);return{'homeDir':_0xec94f3,'cacheRoot':_0x17d536,'managedRoot':resolve(_0xec94f3,PRODUCT_CONFIG['homeDirName']),'agentsSkillsDir':_0x491e1a[_0x2e028f(0x198)]??_0x527794??resolve(_0xec94f3,_0x2e028f(0x18b),_0x2e028f(0x190)),'claudeSkillsDir':_0x491e1a['claudeSkillsDir']??_0x364a90??resolve(_0xec94f3,_0x2e028f(0x199),_0x2e028f(0x190)),'workbuddySkillsDir':_0x1f81c9};}export function runtimeAgentSkillRoots(_0x53cde9){const _0x273e60=a116_0x14d9;return[_0x53cde9[_0x273e60(0x198)],_0x53cde9[_0x273e60(0x197)],_0x53cde9[_0x273e60(0x191)]]['filter'](_0x1bab17=>Boolean(_0x1bab17));}export function getRuntimeSkillCacheRoot(_0x2d4390,_0x46abf2,_0x191b6c={}){const _0x48cb8a=a116_0x14d9,_0x36015d=resolveSkillSyncPaths(_0x191b6c);return resolve(_0x36015d['cacheRoot'],_0x2d4390,fingerprintAccessKey(_0x46abf2),_0x48cb8a(0x190));}export function getRuntimeSkillDir(_0x308ac6,_0x523e8a,_0xd135c0,_0x3b334c,_0xd38cd,_0x56532f={}){const _0x47c4d6=a116_0x14d9;return resolve(getRuntimeSkillCacheRoot(_0x308ac6,_0x523e8a,_0x56532f),safePathSegment(_0xd135c0,_0x47c4d6(0x192)),_0x3b334c,safePathSegment(_0xd38cd,'skillCode'));}function a116_0x5427(){const _0x435ae0=['1504531SdtWCE','2781081HTTnYu','943934fcpQjD','includes','Unsafe\x20','55qlfoKu','cache','homeDirName','CLAUDE_SKILL_ROOT','.agents','.workbuddy','294776cSiBZl','2990016DbFsov','trim','skills','workbuddySkillsDir','appCode','406545iEKHsg','58734qGwuSI','3dVKClj','homeDir','claudeSkillsDir','agentsSkillsDir','.claude'];a116_0x5427=function(){return _0x435ae0;};return a116_0x5427();}export function safePathSegment(_0x2957ee,_0x44b25c='path\x20segment'){const _0x3b0e4f=a116_0x14d9;if(!_0x2957ee||_0x2957ee[_0x3b0e4f(0x185)]('/')||_0x2957ee[_0x3b0e4f(0x185)]('\x5c')||_0x2957ee[_0x3b0e4f(0x185)]('..'))throw CliErrors['validation'](_0x3b0e4f(0x186)+_0x44b25c+'\x20for\x20local\x20path:\x20'+_0x2957ee);return _0x2957ee;}function trimmedEnv(_0x49a8f9){const _0xf9e040=a116_0x14d9,_0x5b2747=productEnv(_0x49a8f9)?.[_0xf9e040(0x18f)]();return _0x5b2747?_0x5b2747:undefined;}
1
+ const a116_0x19bda2=a116_0x34f2;function a116_0x34f2(_0x3d34b0,_0x4db176){_0x3d34b0=_0x3d34b0-0x1a6;const _0x490cb1=a116_0x490c();let _0x34f273=_0x490cb1[_0x3d34b0];return _0x34f273;}(function(_0x40ef44,_0x34560b){const _0x6e0531=a116_0x34f2,_0x2fed25=_0x40ef44();while(!![]){try{const _0x15cb69=-parseInt(_0x6e0531(0x1b2))/0x1+parseInt(_0x6e0531(0x1a7))/0x2+-parseInt(_0x6e0531(0x1a9))/0x3*(parseInt(_0x6e0531(0x1c0))/0x4)+-parseInt(_0x6e0531(0x1bf))/0x5+parseInt(_0x6e0531(0x1b9))/0x6*(parseInt(_0x6e0531(0x1af))/0x7)+parseInt(_0x6e0531(0x1c1))/0x8+-parseInt(_0x6e0531(0x1bb))/0x9;if(_0x15cb69===_0x34560b)break;else _0x2fed25['push'](_0x2fed25['shift']());}catch(_0x42e3ad){_0x2fed25['push'](_0x2fed25['shift']());}}}(a116_0x490c,0x71116));import{existsSync}from'node:fs';import{homedir}from'node:os';import{resolve}from'node:path';function a116_0x490c(){const _0x2aa42f=['agentsSkillsDir','2563825sHTQmG','356HRKnjA','2252992DbLhck','path\x20segment','claudeSkillsDir','815148ltgWlc','.claude','3681aEICMI','\x20for\x20local\x20path:\x20','Unsafe\x20','validation','cacheRoot','trim','6178144TXQhoT','appCode','filter','297370rYBVlr','homeDir','homeDirName','cache','includes','skills','.agents','6aLsfao','skillCode','1703934LXJwoK','SKILL_ROOT','workbuddySkillsDir'];a116_0x490c=function(){return _0x2aa42f;};return a116_0x490c();}import{fingerprintAccessKey}from'../../commands/app/cache.js';import{PRODUCT_CONFIG,productEnv}from'../../constant/product.js';import{CliErrors}from'../../errors.js';export function resolveSkillSyncPaths(_0x26adfd={}){const _0x354b34=a116_0x34f2,_0x25dc09=_0x26adfd[_0x354b34(0x1b3)]??homedir(),_0x5ca2fa=resolve(_0x25dc09,PRODUCT_CONFIG[_0x354b34(0x1b4)],_0x354b34(0x1b5)),_0x31004c=trimmedEnv(_0x354b34(0x1bc)),_0x2bc4a6=trimmedEnv('CLAUDE_SKILL_ROOT'),_0x2961f9=resolve(_0x25dc09,'.workbuddy'),_0x52e9d9=_0x26adfd['workbuddySkillsDir']??(existsSync(_0x2961f9)?resolve(_0x2961f9,_0x354b34(0x1b7)):undefined);return{'homeDir':_0x25dc09,'cacheRoot':_0x5ca2fa,'managedRoot':resolve(_0x25dc09,PRODUCT_CONFIG[_0x354b34(0x1b4)]),'agentsSkillsDir':_0x26adfd[_0x354b34(0x1be)]??_0x31004c??resolve(_0x25dc09,_0x354b34(0x1b8),_0x354b34(0x1b7)),'claudeSkillsDir':_0x26adfd['claudeSkillsDir']??_0x2bc4a6??resolve(_0x25dc09,_0x354b34(0x1a8),_0x354b34(0x1b7)),'workbuddySkillsDir':_0x52e9d9};}export function runtimeAgentSkillRoots(_0x2ef032){const _0x523125=a116_0x34f2;return[_0x2ef032[_0x523125(0x1be)],_0x2ef032[_0x523125(0x1a6)],_0x2ef032[_0x523125(0x1bd)]][_0x523125(0x1b1)](_0x530fbe=>Boolean(_0x530fbe));}export function getRuntimeSkillCacheRoot(_0x364fda,_0x3718dd,_0x3e5b7e={}){const _0x32983b=a116_0x34f2,_0x2bbf1d=resolveSkillSyncPaths(_0x3e5b7e);return resolve(_0x2bbf1d[_0x32983b(0x1ad)],_0x364fda,fingerprintAccessKey(_0x3718dd),_0x32983b(0x1b7));}export function getRuntimeSkillDir(_0x27bf0c,_0x400afe,_0x17fa78,_0x5ba9f4,_0x2ee1e3,_0x2cda0e={}){const _0x1ae76c=a116_0x34f2;return resolve(getRuntimeSkillCacheRoot(_0x27bf0c,_0x400afe,_0x2cda0e),safePathSegment(_0x17fa78,_0x1ae76c(0x1b0)),_0x5ba9f4,safePathSegment(_0x2ee1e3,_0x1ae76c(0x1ba)));}export function safePathSegment(_0x5dd16e,_0x525c7f=a116_0x19bda2(0x1c2)){const _0x1728a1=a116_0x19bda2;if(!_0x5dd16e||_0x5dd16e[_0x1728a1(0x1b6)]('/')||_0x5dd16e[_0x1728a1(0x1b6)]('\x5c')||_0x5dd16e['includes']('..'))throw CliErrors[_0x1728a1(0x1ac)](_0x1728a1(0x1ab)+_0x525c7f+_0x1728a1(0x1aa)+_0x5dd16e);return _0x5dd16e;}function trimmedEnv(_0x2ed962){const _0x590912=a116_0x19bda2,_0x18d779=productEnv(_0x2ed962)?.[_0x590912(0x1ae)]();return _0x18d779?_0x18d779:undefined;}
@@ -11,6 +11,7 @@ export interface PushDirectoryIdentityOptions {
11
11
  ignoreMetadataSkillCode?: boolean;
12
12
  }
13
13
  interface ReadPushDirectoryOptions extends PushDirectoryIdentityOptions {
14
+ excludedFilePaths?: readonly string[];
14
15
  ignoreMetadataForPayload?: boolean;
15
16
  ignoreMetadataScope?: boolean;
16
17
  targetScope?: Extract<RuntimeSkillScope, "personal" | "company">;
@@ -1 +1 @@
1
- (function(_0x7fca68,_0x23da61){const _0x731dfd=a117_0xb41a,_0xf013e0=_0x7fca68();while(!![]){try{const _0x13c666=parseInt(_0x731dfd(0x178))/0x1*(-parseInt(_0x731dfd(0x18a))/0x2)+-parseInt(_0x731dfd(0x18b))/0x3*(-parseInt(_0x731dfd(0x158))/0x4)+-parseInt(_0x731dfd(0x183))/0x5*(parseInt(_0x731dfd(0x160))/0x6)+-parseInt(_0x731dfd(0x149))/0x7+parseInt(_0x731dfd(0x182))/0x8*(parseInt(_0x731dfd(0x157))/0x9)+-parseInt(_0x731dfd(0x15c))/0xa*(parseInt(_0x731dfd(0x176))/0xb)+parseInt(_0x731dfd(0x14c))/0xc;if(_0x13c666===_0x23da61)break;else _0xf013e0['push'](_0xf013e0['shift']());}catch(_0x74d6e5){_0xf013e0['push'](_0xf013e0['shift']());}}}(a117_0x3146,0x673e5));import{existsSync,lstatSync,readFileSync,realpathSync}from'node:fs';import{basename,resolve}from'node:path';import{parse as a117_0x39d0b4}from'yaml';import{CliErrors}from'../../errors.js';import{METADATA_FILE,SKILL_FILE}from'./constants.js';import{writeJsonAtomic}from'./fs-utils.js';import{contentHash}from'./hashing.js';import{fileText,normalizeLocalFiles,scanSkillDirectory}from'./local-files.js';import{buildMetadata,readMetadataIfPresent}from'./metadata.js';import{buildSkillPackage,tryNormalizePackageManifest}from'./zip-package.js';export function resolvePushDirectoryIdentity(_0x3bbdef,_0x4e5499,_0x5daca9={}){const _0x69c10=a117_0xb41a,_0x196f87=resolvePushDirectoryRoot(_0x3bbdef),_0x360cef=readPushMetadataIfPresent(resolve(_0x196f87,METADATA_FILE),{'ignoreInvalidMetadata':_0x5daca9[_0x69c10(0x16a)]});if(_0x360cef?.['appCode']&&_0x360cef[_0x69c10(0x173)]!==_0x4e5499&&!_0x5daca9[_0x69c10(0x17e)]&&!_0x5daca9[_0x69c10(0x161)])throw CliErrors[_0x69c10(0x185)](_0x69c10(0x189)+_0x360cef[_0x69c10(0x173)]+_0x69c10(0x16c)+_0x4e5499+'\x22.');const _0x805176=resolvePushSkillCode(_0x196f87,_0x4e5499,_0x360cef,_0x5daca9);if(!_0x805176)throw CliErrors[_0x69c10(0x185)](_0x69c10(0x172)+SKILL_FILE+',\x20'+METADATA_FILE+_0x69c10(0x16f));return{'dir':_0x196f87,'skillCode':_0x805176,'metadata':_0x360cef};}export function readPushDirectory(_0x479138,_0x25f71e,_0x410abe={}){const _0x3660b5=a117_0xb41a,_0x4118b5=resolvePushDirectoryIdentity(_0x479138,_0x25f71e,_0x410abe),_0x5969b6=_0x4118b5[_0x3660b5(0x16b)],_0x418e3b=resolve(_0x5969b6,SKILL_FILE);if(!existsSync(_0x418e3b)||!lstatSync(_0x418e3b)[_0x3660b5(0x14f)]())throw CliErrors[_0x3660b5(0x185)](_0x3660b5(0x17d)+SKILL_FILE+':\x20'+_0x418e3b);const _0xc069de=_0x4118b5[_0x3660b5(0x17a)],_0x1c9cfa=_0x410abe[_0x3660b5(0x166)]??_0x3660b5(0x175);if(!_0x410abe[_0x3660b5(0x156)]&&_0xc069de?.[_0x3660b5(0x170)]==='builtin')throw CliErrors[_0x3660b5(0x185)](_0x3660b5(0x165)+METADATA_FILE+_0x3660b5(0x16d)+_0xc069de[_0x3660b5(0x170)]+'\x22.');if(!_0x410abe['ignoreMetadataScope']&&_0x1c9cfa===_0x3660b5(0x175)&&_0xc069de?.['scope']&&_0xc069de[_0x3660b5(0x170)]!==_0x3660b5(0x175))throw CliErrors[_0x3660b5(0x185)](_0x3660b5(0x16e)+METADATA_FILE+_0x3660b5(0x16d)+_0xc069de['scope']+'\x22.',_0x3660b5(0x17b)+_0x5969b6+'\x20to\x20submit\x20company\x20Skills\x20for\x20review.');const _0x3b9710=scanSkillDirectory(_0x5969b6),_0x1ec6b2=buildSkillPackage(_0x3b9710),_0x2026d7=readFileSync(_0x418e3b,_0x3660b5(0x15e)),_0x40fca2=_0x4118b5[_0x3660b5(0x14b)],_0x53d2fe=_0x410abe[_0x3660b5(0x14d)]?undefined:_0xc069de,_0x3deb30=readSkillDisplayName(_0x2026d7);return{'skillCode':_0x40fca2,'metadata':_0xc069de,'frontmatterDisplayName':_0x3deb30,'input':{'skillCode':_0x40fca2,'skillName':_0x3deb30??_0x53d2fe?.['skillName'],'description':_0x53d2fe?.['description'],'content':_0x2026d7,'files':_0x1ec6b2['manifest'],'packageBase64':_0x1ec6b2['packageBase64'],'tags':_0x53d2fe?.[_0x3660b5(0x154)],'version':_0x53d2fe?.[_0x3660b5(0x179)],'sourceSessionId':_0x53d2fe?.['sourceSessionId']}};}export function refreshPushDirectoryMetadataFromRemote(_0x5bd974,_0xd15159,_0x2b99f2,_0x1bde3b={}){const _0x47b7ad=a117_0xb41a,_0x55c504=resolvePushDirectoryRoot(_0x5bd974),_0x567913=readPushMetadataIfPresent(resolve(_0x55c504,METADATA_FILE),{'ignoreInvalidMetadata':!![]}),_0x42bce3=requireRemoteScope(_0xd15159),_0x391695=readLocalSkillContent(_0x55c504),_0x40eb5f={..._0xd15159,'appCode':_0xd15159[_0x47b7ad(0x173)]??_0x2b99f2,'skillName':_0xd15159[_0x47b7ad(0x174)]??_0x567913?.[_0x47b7ad(0x174)],'description':_0xd15159[_0x47b7ad(0x187)]??_0x567913?.['description'],'tags':Array[_0x47b7ad(0x186)](_0xd15159[_0x47b7ad(0x154)])?_0xd15159[_0x47b7ad(0x154)]:_0x567913?.[_0x47b7ad(0x154)],'sourceSessionId':_0xd15159['sourceSessionId']??_0x567913?.['sourceSessionId'],'content':_0xd15159[_0x47b7ad(0x169)]??_0x391695},_0x56fd22=buildMetadata(_0x40eb5f,_0x42bce3,_0x2b99f2,contentHash(_0x391695),_0x1bde3b['refreshedAt']);writeJsonAtomic(resolve(_0x55c504,METADATA_FILE),_0x56fd22);}export function recordPushedRuntimeSkill(_0xe501b3,_0x4bccb4,_0x2dbfd6,_0x308f37={}){const _0x39a50f=a117_0xb41a,_0x31c433=resolvePushDirectoryRoot(_0xe501b3),_0x322b74=scanSkillDirectory(_0x31c433),_0x3f5f02=_0x322b74[_0x39a50f(0x14e)](_0x22241a=>_0x22241a[_0x39a50f(0x164)]===SKILL_FILE),_0x43bf2f=_0x3f5f02?fileText(_0x3f5f02):'',_0x416dac=tryNormalizePackageManifest(_0x4bccb4[_0x39a50f(0x181)]),_0x1120bc={..._0x4bccb4,'content':_0x4bccb4[_0x39a50f(0x169)]??_0x43bf2f,'files':_0x416dac},_0x93e133=_0x416dac?normalizeLocalFiles(_0x322b74)[_0x39a50f(0x14a)](_0x192d53=>_0x416dac['files'][_0x39a50f(0x163)](_0x159323=>_0x159323[_0x39a50f(0x164)]===_0x192d53[_0x39a50f(0x164)])):undefined,_0x34fd75=buildMetadata(_0x1120bc,_0x308f37[_0x39a50f(0x170)]??_0x39a50f(0x175),_0x2dbfd6,contentHash(_0x1120bc['content']??''),_0x308f37['pushedAt'],_0x93e133);writeJsonAtomic(resolve(_0x31c433,METADATA_FILE),_0x34fd75);}function a117_0xb41a(_0x2f4d72,_0x4ef2e5){_0x2f4d72=_0x2f4d72-0x149;const _0x31460c=a117_0x3146();let _0xb41aca=_0x31460c[_0x2f4d72];return _0xb41aca;}export function deriveSkillCodeFromDirectory(_0x323f7d,_0x141be5){const _0x15f48c=a117_0xb41a,_0x17f247=basename(resolve(_0x323f7d)),_0x11acdd=_0x141be5+'--';return _0x17f247[_0x15f48c(0x188)](_0x11acdd)?_0x17f247[_0x15f48c(0x184)](_0x11acdd[_0x15f48c(0x180)]):_0x17f247;}function resolvePushSkillCode(_0x13b215,_0x3bcee5,_0x4be9a4,_0x720046){const _0x2db7ff=a117_0xb41a,_0x262b22=deriveSkillCodeFromSkillFile(_0x13b215)||deriveSkillCodeFromDirectory(_0x13b215,_0x3bcee5);if(_0x720046['ignoreMetadataSkillCode'])return _0x262b22;return _0x4be9a4?.[_0x2db7ff(0x14b)]?.['trim']()||_0x262b22;}function deriveSkillCodeFromSkillFile(_0x347e55){const _0x3f5ec3=a117_0xb41a,_0x165c18=resolve(_0x347e55,SKILL_FILE);if(!existsSync(_0x165c18)||!lstatSync(_0x165c18)[_0x3f5ec3(0x14f)]())return undefined;const _0x5deda2=readFileSync(_0x165c18,_0x3f5ec3(0x15e)),_0x25f997=_0x5deda2[_0x3f5ec3(0x15d)](/^---\r?\n([\s\S]*?)\r?\n---(?:\r?\n|$)/);if(!_0x25f997)return undefined;const _0x5d9989=parseFrontmatterObject(_0x25f997[0x1]??''),_0x544740=scalarToString(_0x5d9989?.[_0x3f5ec3(0x168)]);return _0x544740?slugifySkillName(_0x544740):undefined;}function a117_0x3146(){const _0x5800ff=['startsWith','Skill\x20metadata\x20appCode\x20\x22','800TdVQBw','1851288TgLbmf','4597131VEOMkm','filter','skillCode','11884668xdyUSy','ignoreMetadataForPayload','find','isFile','Skill\x20directory\x20not\x20found:\x20','isDirectory','builtin','unknown','tags','displayName','ignoreMetadataScope','13329hMZsMi','4RyHkts','(unknown)','number','company','2808350dkHxPa','match','utf8','replace','18EKjojx','ignoreMetadataAppCodeMismatch','object','some','path','Builtin\x20Skills\x20cannot\x20be\x20pushed;\x20','targetScope','toLowerCase','name','content','ignoreInvalidMetadata','dir','\x22\x20does\x20not\x20match\x20current\x20appCode\x20\x22','\x20has\x20scope=\x22','Only\x20personal\x20Skills\x20can\x20be\x20pushed;\x20',',\x20or\x20directory\x20name.','scope','trim','Unable\x20to\x20resolve\x20skillCode\x20from\x20','appCode','skillName','personal','11UzqhZk','string','1024tIfgGq','version','metadata','Use\x20lovrabet\x20skill\x20push\x20--scope\x20company\x20--dir\x20','isSymbolicLink','Missing\x20','allowAppCodeRetarget','\x20has\x20unsupported\x20scope\x20\x22','length','files','1120qJNKUj','74620ukUrNb','slice','validation','isArray','description'];a117_0x3146=function(){return _0x5800ff;};return a117_0x3146();}function readSkillDisplayName(_0x777f55){const _0x427667=a117_0xb41a,_0xb5906d=_0x777f55[_0x427667(0x15d)](/^---\r?\n([\s\S]*?)\r?\n---(?:\r?\n|$)/);if(!_0xb5906d)return undefined;const _0x2d7a9a=parseFrontmatterObject(_0xb5906d[0x1]??'');return scalarToString(_0x2d7a9a?.[_0x427667(0x155)]);}function slugifySkillName(_0x331630){const _0x55c40a=a117_0xb41a,_0x4924d6=_0x331630[_0x55c40a(0x171)]()[_0x55c40a(0x167)]()[_0x55c40a(0x15f)](/[^\p{L}\p{N}\p{So}]+/gu,'-')['replace'](/^-+/,'')[_0x55c40a(0x15f)](/-+$/,'')[_0x55c40a(0x15f)](/-{2,}/g,'-');if(!_0x4924d6)throw CliErrors[_0x55c40a(0x185)]('Invalid\x20'+SKILL_FILE+'\x20name\x20for\x20SkillHub\x20slug\x20generation.');return _0x4924d6;}function parseFrontmatterObject(_0xd249bc){const _0x2e779e=a117_0xb41a;try{const _0x3f4a2c=a117_0x39d0b4(_0xd249bc);return _0x3f4a2c&&typeof _0x3f4a2c===_0x2e779e(0x162)&&!Array[_0x2e779e(0x186)](_0x3f4a2c)?_0x3f4a2c:undefined;}catch{return undefined;}}function scalarToString(_0x16c8a2){const _0x3e2120=a117_0xb41a;if(typeof _0x16c8a2===_0x3e2120(0x177))return _0x16c8a2[_0x3e2120(0x171)]();if(typeof _0x16c8a2===_0x3e2120(0x15a)||typeof _0x16c8a2==='boolean')return String(_0x16c8a2);return undefined;}function resolvePushDirectoryRoot(_0x495d29){const _0x59f2a5=a117_0xb41a,_0x4d4ef0=resolve(_0x495d29);if(!existsSync(_0x4d4ef0))throw CliErrors['validation'](_0x59f2a5(0x150)+_0x495d29);const _0x192407=lstatSync(_0x4d4ef0);if(_0x192407['isDirectory']())return _0x4d4ef0;if(_0x192407[_0x59f2a5(0x17c)]()){const _0x50e8f3=realpathSync(_0x4d4ef0);if(lstatSync(_0x50e8f3)[_0x59f2a5(0x151)]())return _0x50e8f3;}throw CliErrors[_0x59f2a5(0x185)](_0x59f2a5(0x150)+_0x495d29);}function requireRemoteScope(_0x4a5c79){const _0x32a6f5=a117_0xb41a;if(_0x4a5c79[_0x32a6f5(0x170)]===_0x32a6f5(0x175)||_0x4a5c79[_0x32a6f5(0x170)]===_0x32a6f5(0x15b)||_0x4a5c79[_0x32a6f5(0x170)]===_0x32a6f5(0x152))return _0x4a5c79['scope'];throw CliErrors[_0x32a6f5(0x185)]('Remote\x20Skill\x20'+(_0x4a5c79[_0x32a6f5(0x14b)]||_0x32a6f5(0x159))+_0x32a6f5(0x17f)+(_0x4a5c79[_0x32a6f5(0x170)]??_0x32a6f5(0x153))+'\x22.');}function readLocalSkillContent(_0x47d39a){const _0x1b98c0=a117_0xb41a,_0x22d462=resolve(_0x47d39a,SKILL_FILE);return existsSync(_0x22d462)&&lstatSync(_0x22d462)[_0x1b98c0(0x14f)]()?readFileSync(_0x22d462,_0x1b98c0(0x15e)):'';}function readPushMetadataIfPresent(_0x29f793,_0x546809={}){const _0x2045aa=a117_0xb41a;try{return readMetadataIfPresent(_0x29f793);}catch(_0x242785){if(_0x546809[_0x2045aa(0x16a)])return undefined;throw _0x242785;}}
1
+ (function(_0x620bf0,_0x4a4eed){const _0x44aa52=a117_0x533a,_0x5252af=_0x620bf0();while(!![]){try{const _0x1fb4ee=parseInt(_0x44aa52(0xc2))/0x1+-parseInt(_0x44aa52(0xf3))/0x2*(-parseInt(_0x44aa52(0xc5))/0x3)+parseInt(_0x44aa52(0xc6))/0x4*(parseInt(_0x44aa52(0xe1))/0x5)+-parseInt(_0x44aa52(0xc7))/0x6*(-parseInt(_0x44aa52(0xd7))/0x7)+parseInt(_0x44aa52(0xc3))/0x8*(parseInt(_0x44aa52(0xf7))/0x9)+-parseInt(_0x44aa52(0xed))/0xa+-parseInt(_0x44aa52(0xcd))/0xb;if(_0x1fb4ee===_0x4a4eed)break;else _0x5252af['push'](_0x5252af['shift']());}catch(_0x4a4a07){_0x5252af['push'](_0x5252af['shift']());}}}(a117_0x1791,0x84478));import{existsSync,lstatSync,readFileSync,realpathSync}from'node:fs';import{basename,resolve}from'node:path';import{parse as a117_0xbc08f1}from'yaml';import{CliErrors}from'../../errors.js';import{METADATA_FILE,SKILL_FILE}from'./constants.js';import{writeJsonAtomic}from'./fs-utils.js';import{contentHash}from'./hashing.js';import{fileText,normalizeLocalFiles,scanSkillDirectory}from'./local-files.js';import{buildMetadata,readMetadataIfPresent}from'./metadata.js';function a117_0x1791(){const _0x2c6d64=['displayName','4360RZeydR','number','isFile','isArray','614277UOtxMr','ignoreMetadataScope','(unknown)','utf8','match','sourceSessionId','tags','replace','isDirectory','\x20to\x20submit\x20company\x20Skills\x20for\x20review.','ignoreMetadataForPayload','allowAppCodeRetarget','1057241bMyQVl','24QSNGph','description','420YfemSz','2891516iDAbTN','59082pasDaJ','ignoreMetadataAppCodeMismatch','builtin','length','validation','Remote\x20Skill\x20','25262314QpVRhe','string','object','isSymbolicLink','unknown','version','skillName','Unable\x20to\x20resolve\x20skillCode\x20from\x20','toLowerCase','name','441rMpDep','refreshedAt','personal','trim','skillCode','dir','company','\x22\x20does\x20not\x20match\x20current\x20appCode\x20\x22','ignoreInvalidMetadata','files','5cwrUfJ','path','\x20has\x20unsupported\x20scope\x20\x22','Skill\x20metadata\x20appCode\x20\x22','scope','startsWith','excludedFilePaths','content','Builtin\x20Skills\x20cannot\x20be\x20pushed;\x20','slice','appCode','Skill\x20directory\x20not\x20found:\x20','720500gTDvXY','Use\x20lovrabet\x20skill\x20push\x20--scope\x20company\x20--dir\x20','pushedAt','some','boolean'];a117_0x1791=function(){return _0x2c6d64;};return a117_0x1791();}import{buildSkillPackage,tryNormalizePackageManifest}from'./zip-package.js';export function resolvePushDirectoryIdentity(_0x1075ab,_0x435f49,_0x35fde2={}){const _0x540976=a117_0x533a,_0x5cea1d=resolvePushDirectoryRoot(_0x1075ab),_0x2b1564=readPushMetadataIfPresent(resolve(_0x5cea1d,METADATA_FILE),{'ignoreInvalidMetadata':_0x35fde2[_0x540976(0xdf)]});if(_0x2b1564?.[_0x540976(0xeb)]&&_0x2b1564[_0x540976(0xeb)]!==_0x435f49&&!_0x35fde2[_0x540976(0xc1)]&&!_0x35fde2[_0x540976(0xc8)])throw CliErrors[_0x540976(0xcb)](_0x540976(0xe4)+_0x2b1564[_0x540976(0xeb)]+_0x540976(0xde)+_0x435f49+'\x22.');const _0x1dab02=resolvePushSkillCode(_0x5cea1d,_0x435f49,_0x2b1564,_0x35fde2);if(!_0x1dab02)throw CliErrors[_0x540976(0xcb)](_0x540976(0xd4)+SKILL_FILE+',\x20'+METADATA_FILE+',\x20or\x20directory\x20name.');return{'dir':_0x5cea1d,'skillCode':_0x1dab02,'metadata':_0x2b1564};}export function readPushDirectory(_0x522733,_0x2356ed,_0x2acdc7={}){const _0x4f7b40=a117_0x533a,_0x5f10b5=resolvePushDirectoryIdentity(_0x522733,_0x2356ed,_0x2acdc7),_0x5bc4f7=_0x5f10b5[_0x4f7b40(0xdc)],_0x658122=resolve(_0x5bc4f7,SKILL_FILE);if(!existsSync(_0x658122)||!lstatSync(_0x658122)[_0x4f7b40(0xf5)]())throw CliErrors[_0x4f7b40(0xcb)]('Missing\x20'+SKILL_FILE+':\x20'+_0x658122);const _0x8662a=_0x5f10b5['metadata'],_0x28447c=_0x2acdc7['targetScope']??_0x4f7b40(0xd9);if(!_0x2acdc7[_0x4f7b40(0xf8)]&&_0x8662a?.[_0x4f7b40(0xe5)]===_0x4f7b40(0xc9))throw CliErrors[_0x4f7b40(0xcb)](_0x4f7b40(0xe9)+METADATA_FILE+'\x20has\x20scope=\x22'+_0x8662a[_0x4f7b40(0xe5)]+'\x22.');if(!_0x2acdc7['ignoreMetadataScope']&&_0x28447c===_0x4f7b40(0xd9)&&_0x8662a?.[_0x4f7b40(0xe5)]&&_0x8662a['scope']!==_0x4f7b40(0xd9))throw CliErrors['validation']('Only\x20personal\x20Skills\x20can\x20be\x20pushed;\x20'+METADATA_FILE+'\x20has\x20scope=\x22'+_0x8662a[_0x4f7b40(0xe5)]+'\x22.',_0x4f7b40(0xee)+_0x5bc4f7+_0x4f7b40(0xbf));const _0x1dbe4a=scanSkillDirectory(_0x5bc4f7,{'excludedFilePaths':_0x2acdc7[_0x4f7b40(0xe7)]}),_0x4ad6bf=buildSkillPackage(_0x1dbe4a),_0x40cd97=readFileSync(_0x658122,'utf8'),_0x412397=_0x5f10b5['skillCode'],_0x2b56dd=_0x2acdc7[_0x4f7b40(0xc0)]?undefined:_0x8662a,_0x3b3ca8=readSkillDisplayName(_0x40cd97);return{'skillCode':_0x412397,'metadata':_0x8662a,'frontmatterDisplayName':_0x3b3ca8,'input':{'skillCode':_0x412397,'skillName':_0x3b3ca8??_0x2b56dd?.['skillName'],'description':_0x2b56dd?.[_0x4f7b40(0xc4)],'content':_0x40cd97,'files':_0x4ad6bf['manifest'],'packageBase64':_0x4ad6bf['packageBase64'],'tags':_0x2b56dd?.['tags'],'version':_0x2b56dd?.[_0x4f7b40(0xd2)],'sourceSessionId':_0x2b56dd?.[_0x4f7b40(0xfc)]}};}export function refreshPushDirectoryMetadataFromRemote(_0x46c6fb,_0x385e00,_0x40833a,_0xe3d0f6={}){const _0x126ef1=a117_0x533a,_0x10aa13=resolvePushDirectoryRoot(_0x46c6fb),_0x27ab99=readPushMetadataIfPresent(resolve(_0x10aa13,METADATA_FILE),{'ignoreInvalidMetadata':!![]}),_0x1287a6=requireRemoteScope(_0x385e00),_0x1b7d10=readLocalSkillContent(_0x10aa13),_0x292545={..._0x385e00,'appCode':_0x385e00[_0x126ef1(0xeb)]??_0x40833a,'skillName':_0x385e00[_0x126ef1(0xd3)]??_0x27ab99?.['skillName'],'description':_0x385e00[_0x126ef1(0xc4)]??_0x27ab99?.['description'],'tags':Array['isArray'](_0x385e00[_0x126ef1(0xfd)])?_0x385e00[_0x126ef1(0xfd)]:_0x27ab99?.[_0x126ef1(0xfd)],'sourceSessionId':_0x385e00[_0x126ef1(0xfc)]??_0x27ab99?.[_0x126ef1(0xfc)],'content':_0x385e00[_0x126ef1(0xe8)]??_0x1b7d10},_0x135708=buildMetadata(_0x292545,_0x1287a6,_0x40833a,contentHash(_0x1b7d10),_0xe3d0f6[_0x126ef1(0xd8)]);writeJsonAtomic(resolve(_0x10aa13,METADATA_FILE),_0x135708);}export function recordPushedRuntimeSkill(_0x1c3946,_0x1a53ba,_0x5f37dd,_0x587206={}){const _0x33a0a2=a117_0x533a,_0x44d114=resolvePushDirectoryRoot(_0x1c3946),_0x26433f=scanSkillDirectory(_0x44d114),_0x155a20=_0x26433f['find'](_0x1bd387=>_0x1bd387['path']===SKILL_FILE),_0x579220=_0x155a20?fileText(_0x155a20):'',_0x41054a=tryNormalizePackageManifest(_0x1a53ba[_0x33a0a2(0xe0)]),_0x4787b7={..._0x1a53ba,'content':_0x1a53ba[_0x33a0a2(0xe8)]??_0x579220,'files':_0x41054a},_0x3f360a=_0x41054a?normalizeLocalFiles(_0x26433f)['filter'](_0x393b3e=>_0x41054a[_0x33a0a2(0xe0)][_0x33a0a2(0xf0)](_0x12cac3=>_0x12cac3[_0x33a0a2(0xe2)]===_0x393b3e[_0x33a0a2(0xe2)])):undefined,_0x5838f1=buildMetadata(_0x4787b7,_0x587206[_0x33a0a2(0xe5)]??_0x33a0a2(0xd9),_0x5f37dd,contentHash(_0x4787b7['content']??''),_0x587206[_0x33a0a2(0xef)],_0x3f360a);writeJsonAtomic(resolve(_0x44d114,METADATA_FILE),_0x5838f1);}export function deriveSkillCodeFromDirectory(_0x253733,_0x5a2c81){const _0x31db47=a117_0x533a,_0x495699=basename(resolve(_0x253733)),_0x6b8213=_0x5a2c81+'--';return _0x495699[_0x31db47(0xe6)](_0x6b8213)?_0x495699[_0x31db47(0xea)](_0x6b8213[_0x31db47(0xca)]):_0x495699;}function resolvePushSkillCode(_0xb267bd,_0x402f19,_0x3360ac,_0x30e2fb){const _0x1dd069=a117_0x533a,_0x590ab9=deriveSkillCodeFromSkillFile(_0xb267bd)||deriveSkillCodeFromDirectory(_0xb267bd,_0x402f19);if(_0x30e2fb['ignoreMetadataSkillCode'])return _0x590ab9;return _0x3360ac?.[_0x1dd069(0xdb)]?.[_0x1dd069(0xda)]()||_0x590ab9;}function deriveSkillCodeFromSkillFile(_0x4ef3e4){const _0x3deb5f=a117_0x533a,_0xc71fa9=resolve(_0x4ef3e4,SKILL_FILE);if(!existsSync(_0xc71fa9)||!lstatSync(_0xc71fa9)['isFile']())return undefined;const _0x10609c=readFileSync(_0xc71fa9,'utf8'),_0x44cfaa=_0x10609c['match'](/^---\r?\n([\s\S]*?)\r?\n---(?:\r?\n|$)/);if(!_0x44cfaa)return undefined;const _0x817904=parseFrontmatterObject(_0x44cfaa[0x1]??''),_0x39b2eb=scalarToString(_0x817904?.[_0x3deb5f(0xd6)]);return _0x39b2eb?slugifySkillName(_0x39b2eb):undefined;}function readSkillDisplayName(_0x2ad41f){const _0xc809ba=a117_0x533a,_0xb5c863=_0x2ad41f[_0xc809ba(0xfb)](/^---\r?\n([\s\S]*?)\r?\n---(?:\r?\n|$)/);if(!_0xb5c863)return undefined;const _0x22be75=parseFrontmatterObject(_0xb5c863[0x1]??'');return scalarToString(_0x22be75?.[_0xc809ba(0xf2)]);}function a117_0x533a(_0x146443,_0x249edb){_0x146443=_0x146443-0xbd;const _0x17916f=a117_0x1791();let _0x533ac1=_0x17916f[_0x146443];return _0x533ac1;}function slugifySkillName(_0x486982){const _0x2e24ec=a117_0x533a,_0x17769d=_0x486982[_0x2e24ec(0xda)]()[_0x2e24ec(0xd5)]()[_0x2e24ec(0xbd)](/[^\p{L}\p{N}\p{So}]+/gu,'-')[_0x2e24ec(0xbd)](/^-+/,'')[_0x2e24ec(0xbd)](/-+$/,'')[_0x2e24ec(0xbd)](/-{2,}/g,'-');if(!_0x17769d)throw CliErrors[_0x2e24ec(0xcb)]('Invalid\x20'+SKILL_FILE+'\x20name\x20for\x20SkillHub\x20slug\x20generation.');return _0x17769d;}function parseFrontmatterObject(_0x1e2519){const _0x3f564a=a117_0x533a;try{const _0x23e18a=a117_0xbc08f1(_0x1e2519);return _0x23e18a&&typeof _0x23e18a===_0x3f564a(0xcf)&&!Array[_0x3f564a(0xf6)](_0x23e18a)?_0x23e18a:undefined;}catch{return undefined;}}function scalarToString(_0x51037a){const _0x5a4f43=a117_0x533a;if(typeof _0x51037a===_0x5a4f43(0xce))return _0x51037a[_0x5a4f43(0xda)]();if(typeof _0x51037a===_0x5a4f43(0xf4)||typeof _0x51037a===_0x5a4f43(0xf1))return String(_0x51037a);return undefined;}function resolvePushDirectoryRoot(_0x42c969){const _0x35e39e=a117_0x533a,_0x2832ab=resolve(_0x42c969);if(!existsSync(_0x2832ab))throw CliErrors[_0x35e39e(0xcb)](_0x35e39e(0xec)+_0x42c969);const _0x1cf246=lstatSync(_0x2832ab);if(_0x1cf246[_0x35e39e(0xbe)]())return _0x2832ab;if(_0x1cf246[_0x35e39e(0xd0)]()){const _0x22f71a=realpathSync(_0x2832ab);if(lstatSync(_0x22f71a)[_0x35e39e(0xbe)]())return _0x22f71a;}throw CliErrors['validation'](_0x35e39e(0xec)+_0x42c969);}function requireRemoteScope(_0x5881a7){const _0x48976b=a117_0x533a;if(_0x5881a7[_0x48976b(0xe5)]===_0x48976b(0xd9)||_0x5881a7[_0x48976b(0xe5)]===_0x48976b(0xdd)||_0x5881a7[_0x48976b(0xe5)]===_0x48976b(0xc9))return _0x5881a7[_0x48976b(0xe5)];throw CliErrors[_0x48976b(0xcb)](_0x48976b(0xcc)+(_0x5881a7[_0x48976b(0xdb)]||_0x48976b(0xf9))+_0x48976b(0xe3)+(_0x5881a7[_0x48976b(0xe5)]??_0x48976b(0xd1))+'\x22.');}function readLocalSkillContent(_0x38c12d){const _0x55a238=a117_0x533a,_0x2a896f=resolve(_0x38c12d,SKILL_FILE);return existsSync(_0x2a896f)&&lstatSync(_0x2a896f)[_0x55a238(0xf5)]()?readFileSync(_0x2a896f,_0x55a238(0xfa)):'';}function readPushMetadataIfPresent(_0x1210b7,_0x310498={}){try{return readMetadataIfPresent(_0x1210b7);}catch(_0xae9ef6){if(_0x310498['ignoreInvalidMetadata'])return undefined;throw _0xae9ef6;}}
@@ -1 +1 @@
1
- function a118_0x5b8f(_0x4505eb,_0x1c9555){_0x4505eb=_0x4505eb-0x177;const _0x3678db=a118_0x3678();let _0x5b8f5b=_0x3678db[_0x4505eb];return _0x5b8f5b;}(function(_0x5db2e1,_0x770971){const _0x1ddf40=a118_0x5b8f,_0x283156=_0x5db2e1();while(!![]){try{const _0x1971af=parseInt(_0x1ddf40(0x180))/0x1+parseInt(_0x1ddf40(0x177))/0x2*(parseInt(_0x1ddf40(0x17f))/0x3)+-parseInt(_0x1ddf40(0x17b))/0x4+parseInt(_0x1ddf40(0x17d))/0x5+parseInt(_0x1ddf40(0x17a))/0x6+parseInt(_0x1ddf40(0x17e))/0x7+-parseInt(_0x1ddf40(0x179))/0x8;if(_0x1971af===_0x770971)break;else _0x283156['push'](_0x283156['shift']());}catch(_0x247ffa){_0x283156['push'](_0x283156['shift']());}}}(a118_0x3678,0x2a81f));import{CliErrors}from'../../errors.js';export function normalizeRuntimeSkillScopes(_0x402fa0){const _0x16949c=a118_0x5b8f,_0xa6658c=_0x402fa0&&_0x402fa0[_0x16949c(0x178)]>0x0?_0x402fa0:[_0x16949c(0x184),_0x16949c(0x185),_0x16949c(0x182)],_0x3df26e=[];for(const _0x4f8760 of _0xa6658c){if(!isRuntimeSkillScope(_0x4f8760))throw CliErrors[_0x16949c(0x181)](_0x16949c(0x17c)+_0x4f8760);!_0x3df26e[_0x16949c(0x183)](_0x4f8760)&&_0x3df26e['push'](_0x4f8760);}return _0x3df26e;}function a118_0x3678(){const _0x308f40=['personal','company','318aCVMKy','length','7260824mZqJKe','946242exfxMh','132184hChEJE','Unsupported\x20runtime\x20Skill\x20scope:\x20','1654375KcvMkZ','2265942jhypMd','5205PDoTMU','26607ByAgMw','validation','builtin','includes'];a118_0x3678=function(){return _0x308f40;};return a118_0x3678();}export function isRuntimeSkillScope(_0x553981){const _0x3782e6=a118_0x5b8f;return _0x553981===_0x3782e6(0x184)||_0x553981==='company'||_0x553981===_0x3782e6(0x182);}
1
+ (function(_0xaea109,_0x459faf){const _0x5c9b89=a118_0x157b,_0x5e30c2=_0xaea109();while(!![]){try{const _0x33ba94=parseInt(_0x5c9b89(0xd0))/0x1+parseInt(_0x5c9b89(0xcb))/0x2+parseInt(_0x5c9b89(0xcf))/0x3*(parseInt(_0x5c9b89(0xd8))/0x4)+-parseInt(_0x5c9b89(0xcd))/0x5+-parseInt(_0x5c9b89(0xd5))/0x6*(-parseInt(_0x5c9b89(0xcc))/0x7)+parseInt(_0x5c9b89(0xd6))/0x8*(parseInt(_0x5c9b89(0xd4))/0x9)+parseInt(_0x5c9b89(0xd7))/0xa*(-parseInt(_0x5c9b89(0xd3))/0xb);if(_0x33ba94===_0x459faf)break;else _0x5e30c2['push'](_0x5e30c2['shift']());}catch(_0x3c7a31){_0x5e30c2['push'](_0x5e30c2['shift']());}}}(a118_0x279d,0xbfc92));import{CliErrors}from'../../errors.js';function a118_0x157b(_0x470d48,_0x1e9e24){_0x470d48=_0x470d48-0xc8;const _0x279db5=a118_0x279d();let _0x157bb4=_0x279db5[_0x470d48];return _0x157bb4;}export function normalizeRuntimeSkillScopes(_0x4950a9){const _0x151cb2=a118_0x157b,_0x48f2b4=_0x4950a9&&_0x4950a9[_0x151cb2(0xd2)]>0x0?_0x4950a9:[_0x151cb2(0xca),_0x151cb2(0xc8),_0x151cb2(0xce)],_0x451719=[];for(const _0x350d32 of _0x48f2b4){if(!isRuntimeSkillScope(_0x350d32))throw CliErrors['validation'](_0x151cb2(0xc9)+_0x350d32);!_0x451719[_0x151cb2(0xd1)](_0x350d32)&&_0x451719['push'](_0x350d32);}return _0x451719;}export function isRuntimeSkillScope(_0xf5e47c){const _0x42c0a6=a118_0x157b;return _0xf5e47c===_0x42c0a6(0xca)||_0xf5e47c==='company'||_0xf5e47c===_0x42c0a6(0xce);}function a118_0x279d(){const _0x546f43=['1880606vXNLho','7516820foQsVz','builtin','1083765DlgfCw','190464LsPNaZ','includes','length','57189vQnKsX','18sjpRbS','24LocHCq','4031792zOWmOY','1720NSCLTk','4oMxjzK','company','Unsupported\x20runtime\x20Skill\x20scope:\x20','personal','1097694BJBnJm'];a118_0x279d=function(){return _0x546f43;};return a118_0x279d();}
@@ -1 +1 @@
1
- const a120_0xa69452=a120_0x167b;function a120_0x167b(_0x560393,_0x22d717){_0x560393=_0x560393-0x194;const _0x4e0b7d=a120_0x4e0b();let _0x167b23=_0x4e0b7d[_0x560393];return _0x167b23;}(function(_0x2dcf1d,_0x409175){const _0x390b46=a120_0x167b,_0x1c83bb=_0x2dcf1d();while(!![]){try{const _0x58a190=-parseInt(_0x390b46(0x1ab))/0x1*(parseInt(_0x390b46(0x19f))/0x2)+parseInt(_0x390b46(0x1a4))/0x3*(-parseInt(_0x390b46(0x195))/0x4)+-parseInt(_0x390b46(0x1aa))/0x5*(-parseInt(_0x390b46(0x1a3))/0x6)+parseInt(_0x390b46(0x1a9))/0x7+-parseInt(_0x390b46(0x19a))/0x8+parseInt(_0x390b46(0x1a2))/0x9*(-parseInt(_0x390b46(0x1ac))/0xa)+parseInt(_0x390b46(0x1a1))/0xb*(parseInt(_0x390b46(0x196))/0xc);if(_0x58a190===_0x409175)break;else _0x1c83bb['push'](_0x1c83bb['shift']());}catch(_0x21e11f){_0x1c83bb['push'](_0x1c83bb['shift']());}}}(a120_0x4e0b,0x8eaa1));import{unzipSync,zipSync}from'fflate';import{CliErrors}from'../../errors.js';import{compareSkillFiles,fileContent,normalizeLocalFiles,normalizeSkillRelativePath}from'./local-files.js';const ZIP_MTIME=new Date(a120_0xa69452(0x198));export function createDeterministicZipPackage(_0x2a11a3){const _0x3a1cea=a120_0xa69452,_0x5858d7={};for(const _0x1dc403 of normalizeLocalFiles(_0x2a11a3)){_0x5858d7[_0x1dc403[_0x3a1cea(0x1a6)]]=fileContent(_0x1dc403);}return Buffer[_0x3a1cea(0x194)](zipSync(_0x5858d7,{'level':0x0,'mtime':ZIP_MTIME}));}export function parseZipPackage(_0x1b46ed){const _0x1f531d=a120_0xa69452;if(_0x1b46ed[_0x1f531d(0x1a0)]<0x16)throw CliErrors[_0x1f531d(0x199)](_0x1f531d(0x197));let _0x15f31c;try{_0x15f31c=unzipSync(_0x1b46ed,{'filter'(_0x3b893a){const _0x322870=_0x1f531d,_0x1452e2=normalizeSkillRelativePath(_0x3b893a[_0x322870(0x19c)]);if(_0x1452e2['endsWith']('/'))throw CliErrors['validation'](_0x322870(0x19d)+_0x1452e2);return!![];}});}catch(_0xa04849){if(isRuntimeSkillValidationError(_0xa04849))throw _0xa04849;throw CliErrors[_0x1f531d(0x199)](_0x1f531d(0x197));}return Object[_0x1f531d(0x1a5)](_0x15f31c)['map'](([_0x489030,_0x3f74db])=>({'path':normalizeSkillRelativePath(_0x489030),'bytes':Buffer[_0x1f531d(0x194)](_0x3f74db)}))[_0x1f531d(0x1a8)](compareSkillFiles);}function isRuntimeSkillValidationError(_0x363d73){const _0x5b8084=a120_0xa69452;return typeof _0x363d73===_0x5b8084(0x1a7)&&_0x363d73!==null&&_0x5b8084(0x19e)in _0x363d73&&_0x363d73[_0x5b8084(0x19e)]===_0x5b8084(0x19b);}function a120_0x4e0b(){const _0x596e14=['Runtime\x20Skill\x20package\x20contains\x20directory\x20entry:\x20','code','2xjpDBR','length','22PmWzEs','9ITtcRz','312SozEWV','2174199rHoPMl','entries','path','object','sort','1501402qHGFQY','16855MggeXd','700735QODoWV','8584920Vhvixu','from','4yldZkI','18681876qYTBea','Runtime\x20Skill\x20package\x20is\x20not\x20a\x20valid\x20zip\x20file.','1980-01-01T00:00:00.000Z','validation','5080888ThUQPx','validation_error','name'];a120_0x4e0b=function(){return _0x596e14;};return a120_0x4e0b();}
1
+ (function(_0x5c3e37,_0x136ab2){const _0x2c07ec=a120_0x2b2d,_0x8dbf9c=_0x5c3e37();while(!![]){try{const _0x3961f4=parseInt(_0x2c07ec(0x129))/0x1*(-parseInt(_0x2c07ec(0x115))/0x2)+-parseInt(_0x2c07ec(0x117))/0x3+-parseInt(_0x2c07ec(0x127))/0x4*(parseInt(_0x2c07ec(0x128))/0x5)+-parseInt(_0x2c07ec(0x11f))/0x6*(-parseInt(_0x2c07ec(0x11e))/0x7)+-parseInt(_0x2c07ec(0x125))/0x8*(parseInt(_0x2c07ec(0x119))/0x9)+parseInt(_0x2c07ec(0x123))/0xa+parseInt(_0x2c07ec(0x11c))/0xb*(parseInt(_0x2c07ec(0x12a))/0xc);if(_0x3961f4===_0x136ab2)break;else _0x8dbf9c['push'](_0x8dbf9c['shift']());}catch(_0x423e7c){_0x8dbf9c['push'](_0x8dbf9c['shift']());}}}(a120_0x49da,0xba3c2));import{unzipSync,zipSync}from'fflate';function a120_0x49da(){const _0x52f171=['655140WEcmwz','entries','64ejEjMo','validation','676JQqLNH','38795UzEOqX','17NZbOVS','21816CuRbcz','name','Runtime\x20Skill\x20package\x20is\x20not\x20a\x20valid\x20zip\x20file.','51430eCBiIk','validation_error','21078RADFTA','length','105003tGCPay','from','code','13563yyrcSD','object','1065743TcvVLl','12Czgprt','endsWith','sort','Runtime\x20Skill\x20package\x20contains\x20directory\x20entry:\x20'];a120_0x49da=function(){return _0x52f171;};return a120_0x49da();}import{CliErrors}from'../../errors.js';function a120_0x2b2d(_0xed8d2e,_0x1be0ce){_0xed8d2e=_0xed8d2e-0x113;const _0x49da12=a120_0x49da();let _0x2b2d86=_0x49da12[_0xed8d2e];return _0x2b2d86;}import{compareSkillFiles,fileContent,normalizeLocalFiles,normalizeSkillRelativePath}from'./local-files.js';const ZIP_MTIME=new Date('1980-01-01T00:00:00.000Z');export function createDeterministicZipPackage(_0xa8cf79){const _0x4489e8={};for(const _0x37d028 of normalizeLocalFiles(_0xa8cf79)){_0x4489e8[_0x37d028['path']]=fileContent(_0x37d028);}return Buffer['from'](zipSync(_0x4489e8,{'level':0x0,'mtime':ZIP_MTIME}));}export function parseZipPackage(_0x525cf9){const _0x4b2fa4=a120_0x2b2d;if(_0x525cf9[_0x4b2fa4(0x118)]<0x16)throw CliErrors[_0x4b2fa4(0x126)](_0x4b2fa4(0x114));let _0x193dcc;try{_0x193dcc=unzipSync(_0x525cf9,{'filter'(_0x316c04){const _0x39063c=_0x4b2fa4,_0x57a533=normalizeSkillRelativePath(_0x316c04[_0x39063c(0x113)]);if(_0x57a533[_0x39063c(0x120)]('/'))throw CliErrors[_0x39063c(0x126)](_0x39063c(0x122)+_0x57a533);return!![];}});}catch(_0x30aef3){if(isRuntimeSkillValidationError(_0x30aef3))throw _0x30aef3;throw CliErrors['validation']('Runtime\x20Skill\x20package\x20is\x20not\x20a\x20valid\x20zip\x20file.');}return Object[_0x4b2fa4(0x124)](_0x193dcc)['map'](([_0x24b6c5,_0x25fe2e])=>({'path':normalizeSkillRelativePath(_0x24b6c5),'bytes':Buffer[_0x4b2fa4(0x11a)](_0x25fe2e)}))[_0x4b2fa4(0x121)](compareSkillFiles);}function isRuntimeSkillValidationError(_0x1a9c28){const _0x539adc=a120_0x2b2d;return typeof _0x1a9c28===_0x539adc(0x11d)&&_0x1a9c28!==null&&_0x539adc(0x11b)in _0x1a9c28&&_0x1a9c28[_0x539adc(0x11b)]===_0x539adc(0x116);}
@@ -1 +1 @@
1
- (function(_0x3073e8,_0x52fae5){const _0x3598d4=a121_0x1813,_0x2e92b9=_0x3073e8();while(!![]){try{const _0x25c5c6=parseInt(_0x3598d4(0x190))/0x1+parseInt(_0x3598d4(0x199))/0x2+-parseInt(_0x3598d4(0x183))/0x3*(parseInt(_0x3598d4(0x181))/0x4)+-parseInt(_0x3598d4(0x193))/0x5+parseInt(_0x3598d4(0x1a5))/0x6+parseInt(_0x3598d4(0x1a0))/0x7*(parseInt(_0x3598d4(0x194))/0x8)+-parseInt(_0x3598d4(0x1a3))/0x9;if(_0x25c5c6===_0x52fae5)break;else _0x2e92b9['push'](_0x2e92b9['shift']());}catch(_0x81fbef){_0x2e92b9['push'](_0x2e92b9['shift']());}}}(a121_0x5152,0x9478a));import{CliErrors}from'../../errors.js';function a121_0x1813(_0x4828cd,_0x42b02d){_0x4828cd=_0x4828cd-0x17a;const _0x5152ca=a121_0x5152();let _0x181374=_0x5152ca[_0x4828cd];return _0x181374;}import{SKILL_FILE}from'./constants.js';import{bufferSha256,fileHash,fileTreeHash}from'./hashing.js';import{fileContent,isSha256Hex,normalizeLocalFiles,normalizeManifestFiles}from'./local-files.js';import{createDeterministicZipPackage,parseZipPackage}from'./zip-codec.js';export function buildSkillPackage(_0x1a3183){const _0x4bcede=a121_0x1813,_0x318f2f=normalizeLocalFiles(_0x1a3183);if(!_0x318f2f['some'](_0x585aa3=>_0x585aa3[_0x4bcede(0x198)]===SKILL_FILE))throw CliErrors[_0x4bcede(0x17c)]('Missing\x20'+SKILL_FILE+_0x4bcede(0x185));const _0x5c9644=localFilesToManifestFiles(_0x318f2f),_0x2ede44=createDeterministicZipPackage(_0x318f2f);return{'manifest':{'schemaVersion':0x2,'treeSha256':fileTreeHash(_0x5c9644),'zipSha256':bufferSha256(_0x2ede44),'zipSize':_0x2ede44['length'],'files':_0x5c9644},'packageBytes':_0x2ede44,'packageBase64':_0x2ede44[_0x4bcede(0x180)]('base64')};}export function verifyRuntimeSkillPackage(_0x5cd635,_0x347805){const _0x19200d=a121_0x1813,_0x1b0df1=normalizePackageManifest(_0x5cd635,{'requireOssPath':![]});if(!_0x1b0df1)throw CliErrors[_0x19200d(0x17c)](_0x19200d(0x17b));return extractAndVerifyPackage(_0x1b0df1,_0x347805);}export function verifyRuntimeSkillBundle(_0x3e86c6,_0x4758ef){const _0x2f3245=a121_0x1813,_0x4f0249=normalizePackageManifest(_0x3e86c6,{'requireOssPath':![]});if(!_0x4f0249)throw CliErrors['validation'](_0x2f3245(0x17b));return extractAndVerifyPackageFiles(_0x4f0249,_0x4758ef);}export function tryNormalizePackageManifest(_0x28e766){return normalizePackageManifest(_0x28e766,{'requireOssPath':![]});}export function requirePackageBytes(_0x4688c4,_0x8fc30b){const _0x5af4a8=a121_0x1813;if(!_0x8fc30b||_0x8fc30b[_0x5af4a8(0x186)]===0x0)throw CliErrors[_0x5af4a8(0x17c)](_0x5af4a8(0x19d)+_0x4688c4);return _0x8fc30b;}export function extractDownloadedPackage(_0x3dc379){const _0x46d139=a121_0x1813,_0x2a3687=parseZipPackage(_0x3dc379)[_0x46d139(0x187)](_0x1692f6=>({'path':_0x1692f6[_0x46d139(0x198)],'bytes':_0x1692f6['bytes']}));if(!_0x2a3687['some'](_0x37a05d=>_0x37a05d['path']===SKILL_FILE))throw CliErrors[_0x46d139(0x17c)]('Runtime\x20Skill\x20package\x20is\x20missing\x20'+SKILL_FILE+'.');return normalizeLocalFiles(_0x2a3687);}export function localFilesToManifestFiles(_0x220ecf){const _0x542d0c=a121_0x1813;return normalizeLocalFiles(_0x220ecf)[_0x542d0c(0x187)](_0x55d165=>({'path':_0x55d165[_0x542d0c(0x198)],'sha256':fileHash(_0x55d165),'size':fileContent(_0x55d165)[_0x542d0c(0x186)]}));}function normalizePackageManifest(_0x27c17b,_0x54459e){const _0x134c9f=a121_0x1813;if(!_0x27c17b||typeof _0x27c17b!=='object'||Array[_0x134c9f(0x17e)](_0x27c17b))return undefined;const _0x1c25ef=_0x27c17b,_0x55f421=typeof _0x1c25ef[_0x134c9f(0x18a)]===_0x134c9f(0x19f)?_0x1c25ef[_0x134c9f(0x18a)][_0x134c9f(0x18d)]():undefined;if(_0x54459e['requireOssPath']&&!_0x55f421)return undefined;if(!Array[_0x134c9f(0x17e)](_0x1c25ef[_0x134c9f(0x19a)])||_0x1c25ef['files'][_0x134c9f(0x186)]===0x0)return undefined;if(!isSha256Hex(_0x1c25ef[_0x134c9f(0x1a1)]))throw CliErrors[_0x134c9f(0x17c)]('Runtime\x20Skill\x20file\x20tree\x20sha256\x20is\x20invalid.');if(!isSha256Hex(_0x1c25ef[_0x134c9f(0x192)]))throw CliErrors[_0x134c9f(0x17c)](_0x134c9f(0x184));if(!Number['isSafeInteger'](_0x1c25ef['zipSize'])||_0x1c25ef[_0x134c9f(0x189)]<0x0)throw CliErrors[_0x134c9f(0x17c)](_0x134c9f(0x191));const _0x286f12=normalizeManifestFiles(_0x1c25ef[_0x134c9f(0x19a)]);if(!_0x286f12[_0x134c9f(0x196)](_0x1631dc=>_0x1631dc[_0x134c9f(0x198)]===SKILL_FILE))throw CliErrors[_0x134c9f(0x17c)](_0x134c9f(0x1a2)+SKILL_FILE+'.');const _0x199b11=fileTreeHash(_0x286f12);if(_0x199b11!==_0x1c25ef['treeSha256'][_0x134c9f(0x195)]())throw CliErrors[_0x134c9f(0x17c)](_0x134c9f(0x18b));return{'schemaVersion':Number[_0x134c9f(0x17f)](_0x1c25ef[_0x134c9f(0x197)])?_0x1c25ef[_0x134c9f(0x197)]:0x2,'ossPath':_0x55f421,'treeSha256':_0x199b11,'zipSha256':_0x1c25ef[_0x134c9f(0x192)][_0x134c9f(0x195)](),'zipSize':_0x1c25ef['zipSize'],'files':_0x286f12};}function extractAndVerifyPackage(_0xd48608,_0x92787e){const _0xe9055a=a121_0x1813,_0x265cd0=normalizePackageManifest(_0xd48608,{'requireOssPath':![]});if(!_0x265cd0)throw CliErrors[_0xe9055a(0x17c)](_0xe9055a(0x17b));if(_0x92787e[_0xe9055a(0x186)]!==_0x265cd0[_0xe9055a(0x189)])throw CliErrors[_0xe9055a(0x17c)](_0xe9055a(0x17d));const _0x2e25d3=bufferSha256(_0x92787e);if(_0x2e25d3!==_0x265cd0['zipSha256'])throw CliErrors[_0xe9055a(0x17c)]('Runtime\x20Skill\x20package\x20sha256\x20mismatch.');return extractAndVerifyPackageFiles(_0x265cd0,_0x92787e);}function extractAndVerifyPackageFiles(_0x4cd9d6,_0x4a6a4b){const _0x4194d1=a121_0x1813,_0x57a876=parseZipPackage(_0x4a6a4b);if(_0x57a876[_0x4194d1(0x186)]!==_0x4cd9d6[_0x4194d1(0x19a)]['length'])throw CliErrors[_0x4194d1(0x17c)](_0x4194d1(0x1a4));const _0x5ad275=new Map();for(const _0x251c12 of _0x57a876){if(_0x5ad275[_0x4194d1(0x18c)](_0x251c12[_0x4194d1(0x198)]))throw CliErrors[_0x4194d1(0x17c)](_0x4194d1(0x188)+_0x251c12[_0x4194d1(0x198)]);_0x5ad275[_0x4194d1(0x182)](_0x251c12[_0x4194d1(0x198)],_0x251c12);}const _0x100865=[];for(const _0x4f0aeb of _0x4cd9d6['files']){const _0x43831=_0x5ad275[_0x4194d1(0x19c)](_0x4f0aeb[_0x4194d1(0x198)]);if(!_0x43831)throw CliErrors[_0x4194d1(0x17c)](_0x4194d1(0x19e)+_0x4f0aeb[_0x4194d1(0x198)]);if(_0x43831[_0x4194d1(0x19b)][_0x4194d1(0x186)]!==_0x4f0aeb[_0x4194d1(0x18f)])throw CliErrors['validation']('Runtime\x20Skill\x20package\x20file\x20size\x20mismatch:\x20'+_0x4f0aeb[_0x4194d1(0x198)]);const _0x50152b=bufferSha256(_0x43831[_0x4194d1(0x19b)]);if(_0x50152b!==_0x4f0aeb['sha256'])throw CliErrors[_0x4194d1(0x17c)](_0x4194d1(0x18e)+_0x4f0aeb[_0x4194d1(0x198)]);_0x100865[_0x4194d1(0x17a)]({'path':_0x4f0aeb[_0x4194d1(0x198)],'bytes':_0x43831[_0x4194d1(0x19b)]});}return normalizeLocalFiles(_0x100865);}function a121_0x5152(){const _0x36abbd=['path','85536FlcMff','files','bytes','get','Runtime\x20Skill\x20package\x20is\x20required\x20for\x20Skill\x20install:\x20','Runtime\x20Skill\x20package\x20is\x20missing\x20entry:\x20','string','49RouxIr','treeSha256','Runtime\x20Skill\x20manifest\x20is\x20missing\x20','4172499nyrDdf','Runtime\x20Skill\x20package\x20entry\x20list\x20mismatch.','4162386TAIKLm','push','Runtime\x20Skill\x20package\x20manifest\x20is\x20missing.','validation','Runtime\x20Skill\x20package\x20size\x20mismatch.','isArray','isSafeInteger','toString','16miNEQq','set','485913bwtxRf','Runtime\x20Skill\x20package\x20sha256\x20is\x20invalid.','\x20in\x20Skill\x20file\x20package.','length','map','Duplicate\x20Skill\x20package\x20entry:\x20','zipSize','ossPath','Runtime\x20Skill\x20file\x20tree\x20sha256\x20mismatch.','has','trim','Runtime\x20Skill\x20package\x20file\x20sha256\x20mismatch:\x20','size','839737OPjIXl','Runtime\x20Skill\x20package\x20size\x20is\x20invalid.','zipSha256','1994990ouqhbW','619880StiJOY','toLowerCase','some','schemaVersion'];a121_0x5152=function(){return _0x36abbd;};return a121_0x5152();}
1
+ (function(_0xcadfea,_0x4a1410){const _0x119049=a121_0x5c4b,_0x51c731=_0xcadfea();while(!![]){try{const _0x464da2=-parseInt(_0x119049(0xfc))/0x1*(-parseInt(_0x119049(0xe2))/0x2)+parseInt(_0x119049(0x108))/0x3*(-parseInt(_0x119049(0xf3))/0x4)+-parseInt(_0x119049(0xf4))/0x5*(-parseInt(_0x119049(0xec))/0x6)+-parseInt(_0x119049(0xf9))/0x7+parseInt(_0x119049(0xf5))/0x8+parseInt(_0x119049(0x115))/0x9*(parseInt(_0x119049(0x10f))/0xa)+parseInt(_0x119049(0x109))/0xb*(-parseInt(_0x119049(0xfb))/0xc);if(_0x464da2===_0x4a1410)break;else _0x51c731['push'](_0x51c731['shift']());}catch(_0x24266e){_0x51c731['push'](_0x51c731['shift']());}}}(a121_0x5c52,0x5e855));import{CliErrors}from'../../errors.js';import{SKILL_FILE}from'./constants.js';import{bufferSha256,fileHash,fileTreeHash}from'./hashing.js';import{fileContent,isSha256Hex,normalizeLocalFiles,normalizeManifestFiles}from'./local-files.js';function a121_0x5c4b(_0x37be8d,_0x5e4f3e){_0x37be8d=_0x37be8d-0xe2;const _0x5c5274=a121_0x5c52();let _0x5c4bf7=_0x5c5274[_0x37be8d];return _0x5c4bf7;}import{createDeterministicZipPackage,parseZipPackage}from'./zip-codec.js';export function buildSkillPackage(_0x1047f3){const _0x876ae3=a121_0x5c4b,_0x14cabe=normalizeLocalFiles(_0x1047f3);if(!_0x14cabe[_0x876ae3(0x10e)](_0x34cc85=>_0x34cc85[_0x876ae3(0x10a)]===SKILL_FILE))throw CliErrors[_0x876ae3(0x10c)](_0x876ae3(0x116)+SKILL_FILE+_0x876ae3(0x102));const _0x19d8d5=localFilesToManifestFiles(_0x14cabe),_0x5ddd74=createDeterministicZipPackage(_0x14cabe);return{'manifest':{'schemaVersion':0x2,'treeSha256':fileTreeHash(_0x19d8d5),'zipSha256':bufferSha256(_0x5ddd74),'zipSize':_0x5ddd74['length'],'files':_0x19d8d5},'packageBytes':_0x5ddd74,'packageBase64':_0x5ddd74[_0x876ae3(0xfd)](_0x876ae3(0x106))};}function a121_0x5c52(){const _0x59959c=['609323YfUZtD','path','Runtime\x20Skill\x20file\x20tree\x20sha256\x20mismatch.','validation','bytes','some','2203430nFPAUK','push','Runtime\x20Skill\x20package\x20sha256\x20is\x20invalid.','trim','Runtime\x20Skill\x20package\x20is\x20missing\x20','isSafeInteger','27bEaevb','Missing\x20','20SgUyAj','Runtime\x20Skill\x20package\x20size\x20mismatch.','size','toLowerCase','Runtime\x20Skill\x20file\x20tree\x20sha256\x20is\x20invalid.','Runtime\x20Skill\x20package\x20size\x20is\x20invalid.','ossPath','zipSize','Runtime\x20Skill\x20package\x20file\x20size\x20mismatch:\x20','sha256','17454YoBSeG','zipSha256','requireOssPath','isArray','treeSha256','Duplicate\x20Skill\x20package\x20entry:\x20','length','4HtKWkP','565cBTrBC','3572624jkBTIm','Runtime\x20Skill\x20package\x20file\x20sha256\x20mismatch:\x20','files','get','3776255ZKfirN','map','60kqueRU','15761mlMgsk','toString','schemaVersion','Runtime\x20Skill\x20package\x20sha256\x20mismatch.','Runtime\x20Skill\x20package\x20is\x20missing\x20entry:\x20','string','\x20in\x20Skill\x20file\x20package.','Runtime\x20Skill\x20package\x20is\x20required\x20for\x20Skill\x20install:\x20','has','Runtime\x20Skill\x20manifest\x20is\x20missing\x20','base64','Runtime\x20Skill\x20package\x20manifest\x20is\x20missing.','1171041MuViaD'];a121_0x5c52=function(){return _0x59959c;};return a121_0x5c52();}export function verifyRuntimeSkillPackage(_0x34ce34,_0x5ed6ac){const _0xad46b0=a121_0x5c4b,_0x2274a8=normalizePackageManifest(_0x34ce34,{'requireOssPath':![]});if(!_0x2274a8)throw CliErrors['validation'](_0xad46b0(0x107));return extractAndVerifyPackage(_0x2274a8,_0x5ed6ac);}export function verifyRuntimeSkillBundle(_0x16fb6e,_0x8ee642){const _0x5be13f=a121_0x5c4b,_0x2dccaa=normalizePackageManifest(_0x16fb6e,{'requireOssPath':![]});if(!_0x2dccaa)throw CliErrors[_0x5be13f(0x10c)](_0x5be13f(0x107));return extractAndVerifyPackageFiles(_0x2dccaa,_0x8ee642);}export function tryNormalizePackageManifest(_0x5c622e){return normalizePackageManifest(_0x5c622e,{'requireOssPath':![]});}export function requirePackageBytes(_0x583b46,_0x1a47c1){const _0x278119=a121_0x5c4b;if(!_0x1a47c1||_0x1a47c1[_0x278119(0xf2)]===0x0)throw CliErrors['validation'](_0x278119(0x103)+_0x583b46);return _0x1a47c1;}export function extractDownloadedPackage(_0x5b95c2){const _0x2a8e09=a121_0x5c4b,_0x46ba1b=parseZipPackage(_0x5b95c2)[_0x2a8e09(0xfa)](_0x24f9b1=>({'path':_0x24f9b1[_0x2a8e09(0x10a)],'bytes':_0x24f9b1['bytes']}));if(!_0x46ba1b[_0x2a8e09(0x10e)](_0x21fa6a=>_0x21fa6a['path']===SKILL_FILE))throw CliErrors[_0x2a8e09(0x10c)](_0x2a8e09(0x113)+SKILL_FILE+'.');return normalizeLocalFiles(_0x46ba1b);}export function localFilesToManifestFiles(_0x4efbf6){const _0x377d5c=a121_0x5c4b;return normalizeLocalFiles(_0x4efbf6)[_0x377d5c(0xfa)](_0x40968f=>({'path':_0x40968f[_0x377d5c(0x10a)],'sha256':fileHash(_0x40968f),'size':fileContent(_0x40968f)[_0x377d5c(0xf2)]}));}function normalizePackageManifest(_0x3542c9,_0x89828e){const _0xebce50=a121_0x5c4b;if(!_0x3542c9||typeof _0x3542c9!=='object'||Array[_0xebce50(0xef)](_0x3542c9))return undefined;const _0x52a10a=_0x3542c9,_0x1b008f=typeof _0x52a10a[_0xebce50(0xe8)]===_0xebce50(0x101)?_0x52a10a[_0xebce50(0xe8)][_0xebce50(0x112)]():undefined;if(_0x89828e[_0xebce50(0xee)]&&!_0x1b008f)return undefined;if(!Array[_0xebce50(0xef)](_0x52a10a[_0xebce50(0xf7)])||_0x52a10a[_0xebce50(0xf7)]['length']===0x0)return undefined;if(!isSha256Hex(_0x52a10a[_0xebce50(0xf0)]))throw CliErrors[_0xebce50(0x10c)](_0xebce50(0xe6));if(!isSha256Hex(_0x52a10a[_0xebce50(0xed)]))throw CliErrors['validation'](_0xebce50(0x111));if(!Number[_0xebce50(0x114)](_0x52a10a[_0xebce50(0xe9)])||_0x52a10a[_0xebce50(0xe9)]<0x0)throw CliErrors[_0xebce50(0x10c)](_0xebce50(0xe7));const _0x510af6=normalizeManifestFiles(_0x52a10a[_0xebce50(0xf7)]);if(!_0x510af6[_0xebce50(0x10e)](_0x341a30=>_0x341a30[_0xebce50(0x10a)]===SKILL_FILE))throw CliErrors[_0xebce50(0x10c)](_0xebce50(0x105)+SKILL_FILE+'.');const _0x49b96d=fileTreeHash(_0x510af6);if(_0x49b96d!==_0x52a10a[_0xebce50(0xf0)][_0xebce50(0xe5)]())throw CliErrors[_0xebce50(0x10c)](_0xebce50(0x10b));return{'schemaVersion':Number[_0xebce50(0x114)](_0x52a10a[_0xebce50(0xfe)])?_0x52a10a[_0xebce50(0xfe)]:0x2,'ossPath':_0x1b008f,'treeSha256':_0x49b96d,'zipSha256':_0x52a10a[_0xebce50(0xed)][_0xebce50(0xe5)](),'zipSize':_0x52a10a[_0xebce50(0xe9)],'files':_0x510af6};}function extractAndVerifyPackage(_0x3c067b,_0x207016){const _0x3ab224=a121_0x5c4b,_0x135d5c=normalizePackageManifest(_0x3c067b,{'requireOssPath':![]});if(!_0x135d5c)throw CliErrors[_0x3ab224(0x10c)](_0x3ab224(0x107));if(_0x207016[_0x3ab224(0xf2)]!==_0x135d5c['zipSize'])throw CliErrors['validation'](_0x3ab224(0xe3));const _0x5e3112=bufferSha256(_0x207016);if(_0x5e3112!==_0x135d5c[_0x3ab224(0xed)])throw CliErrors[_0x3ab224(0x10c)](_0x3ab224(0xff));return extractAndVerifyPackageFiles(_0x135d5c,_0x207016);}function extractAndVerifyPackageFiles(_0x1dc692,_0x3a4a30){const _0x4678f2=a121_0x5c4b,_0x397f2d=parseZipPackage(_0x3a4a30);if(_0x397f2d[_0x4678f2(0xf2)]!==_0x1dc692['files'][_0x4678f2(0xf2)])throw CliErrors[_0x4678f2(0x10c)]('Runtime\x20Skill\x20package\x20entry\x20list\x20mismatch.');const _0x132454=new Map();for(const _0x56cdc5 of _0x397f2d){if(_0x132454[_0x4678f2(0x104)](_0x56cdc5[_0x4678f2(0x10a)]))throw CliErrors[_0x4678f2(0x10c)](_0x4678f2(0xf1)+_0x56cdc5[_0x4678f2(0x10a)]);_0x132454['set'](_0x56cdc5[_0x4678f2(0x10a)],_0x56cdc5);}const _0x449369=[];for(const _0x4ca046 of _0x1dc692[_0x4678f2(0xf7)]){const _0x17b981=_0x132454[_0x4678f2(0xf8)](_0x4ca046[_0x4678f2(0x10a)]);if(!_0x17b981)throw CliErrors[_0x4678f2(0x10c)](_0x4678f2(0x100)+_0x4ca046[_0x4678f2(0x10a)]);if(_0x17b981[_0x4678f2(0x10d)]['length']!==_0x4ca046[_0x4678f2(0xe4)])throw CliErrors[_0x4678f2(0x10c)](_0x4678f2(0xea)+_0x4ca046[_0x4678f2(0x10a)]);const _0x2113b9=bufferSha256(_0x17b981[_0x4678f2(0x10d)]);if(_0x2113b9!==_0x4ca046[_0x4678f2(0xeb)])throw CliErrors['validation'](_0x4678f2(0xf6)+_0x4ca046['path']);_0x449369[_0x4678f2(0x110)]({'path':_0x4ca046[_0x4678f2(0x10a)],'bytes':_0x17b981[_0x4678f2(0x10d)]});}return normalizeLocalFiles(_0x449369);}
@@ -1 +1 @@
1
- function a122_0x3f30(){var _0x506d83=['80289RxaqLf','1670tFVNEx','9344464uBLQVr','6167FxsLJp','3346500BbBtJM','4386EVPhNW','3908937uAtUaw','5334800zATkvi','166bQQhXu','16297bAhImE'];a122_0x3f30=function(){return _0x506d83;};return a122_0x3f30();}(function(_0x502f6c,_0x9b461f){var _0x19068c=a122_0x1bb1,_0x578fc9=_0x502f6c();while(!![]){try{var _0x5923ab=-parseInt(_0x19068c(0x129))/0x1*(parseInt(_0x19068c(0x128))/0x2)+parseInt(_0x19068c(0x126))/0x3+parseInt(_0x19068c(0x124))/0x4+-parseInt(_0x19068c(0x127))/0x5+-parseInt(_0x19068c(0x125))/0x6*(-parseInt(_0x19068c(0x123))/0x7)+-parseInt(_0x19068c(0x122))/0x8+-parseInt(_0x19068c(0x120))/0x9*(-parseInt(_0x19068c(0x121))/0xa);if(_0x5923ab===_0x9b461f)break;else _0x578fc9['push'](_0x578fc9['shift']());}catch(_0x1b1848){_0x578fc9['push'](_0x578fc9['shift']());}}}(a122_0x3f30,0xa76b9));export{contentHash,fileTreeHash}from'./runtime-skill-sync/hashing.js';export{linkEffectiveRuntimeSkills,linkGlobalRuntimeSkills,pruneStaleRuntimeSkillCache,pruneStaleRuntimeSkillLinks}from'./runtime-skill-sync/links.js';function a122_0x1bb1(_0xaa05e9,_0x9c14c){_0xaa05e9=_0xaa05e9-0x120;var _0x3f30e7=a122_0x3f30();var _0x1bb18a=_0x3f30e7[_0xaa05e9];return _0x1bb18a;}export{resolveRuntimeSkillInstallTarget}from'./runtime-skill-sync/install-target.js';export{listLocalRuntimeSkills}from'./runtime-skill-sync/list-local.js';export{materializeRuntimeSkill}from'./runtime-skill-sync/materialize.js';export{readMetadataIfPresent}from'./runtime-skill-sync/metadata.js';export{getRuntimeSkillCacheRoot,getRuntimeSkillDir,resolveSkillSyncPaths,runtimeAgentSkillRoots}from'./runtime-skill-sync/paths.js';export{deriveSkillCodeFromDirectory,readPushDirectory,refreshPushDirectoryMetadataFromRemote,recordPushedRuntimeSkill,resolvePushDirectoryIdentity}from'./runtime-skill-sync/push.js';export{buildSkillPackage,verifyRuntimeSkillBundle,verifyRuntimeSkillPackage}from'./runtime-skill-sync/zip-package.js';
1
+ (function(_0x2519b2,_0x2f44f5){var _0x2e6aeb=a122_0x6e45,_0x35f7bd=_0x2519b2();while(!![]){try{var _0x239600=parseInt(_0x2e6aeb(0x14b))/0x1+parseInt(_0x2e6aeb(0x14a))/0x2+-parseInt(_0x2e6aeb(0x14d))/0x3+-parseInt(_0x2e6aeb(0x14c))/0x4+parseInt(_0x2e6aeb(0x14e))/0x5+parseInt(_0x2e6aeb(0x14f))/0x6+parseInt(_0x2e6aeb(0x150))/0x7;if(_0x239600===_0x2f44f5)break;else _0x35f7bd['push'](_0x35f7bd['shift']());}catch(_0x4d011c){_0x35f7bd['push'](_0x35f7bd['shift']());}}}(a122_0x4e65,0xeacbd));export{contentHash,fileTreeHash}from'./runtime-skill-sync/hashing.js';export{linkEffectiveRuntimeSkills,linkGlobalRuntimeSkills,pruneStaleRuntimeSkillCache,pruneStaleRuntimeSkillLinks}from'./runtime-skill-sync/links.js';export{resolveRuntimeSkillInstallTarget}from'./runtime-skill-sync/install-target.js';export{listLocalRuntimeSkills}from'./runtime-skill-sync/list-local.js';export{materializeRuntimeSkill}from'./runtime-skill-sync/materialize.js';function a122_0x6e45(_0x35efc0,_0x7fa9b){_0x35efc0=_0x35efc0-0x14a;var _0x4e6527=a122_0x4e65();var _0x6e4582=_0x4e6527[_0x35efc0];return _0x6e4582;}export{readMetadataIfPresent}from'./runtime-skill-sync/metadata.js';export{getRuntimeSkillCacheRoot,getRuntimeSkillDir,resolveSkillSyncPaths,runtimeAgentSkillRoots}from'./runtime-skill-sync/paths.js';export{deriveSkillCodeFromDirectory,readPushDirectory,refreshPushDirectoryMetadataFromRemote,recordPushedRuntimeSkill,resolvePushDirectoryIdentity}from'./runtime-skill-sync/push.js';function a122_0x4e65(){var _0x91b2d0=['3890376FApyPl','5661500ptUGZX','7324458oOHuCn','1694889iXIyzD','1413776BZzfoq','127813oFzCqN','4685416anzLjp'];a122_0x4e65=function(){return _0x91b2d0;};return a122_0x4e65();}export{buildSkillPackage,verifyRuntimeSkillBundle,verifyRuntimeSkillPackage}from'./runtime-skill-sync/zip-package.js';
@@ -1 +1 @@
1
- function a123_0x3fed(){const _0x159db5=['.skill-lock.json','present','2030196NnpzlD','403230gdhZFo','\x20uses\x20unsupported\x20version\x20','globalSkillsDirs','join','11812KHzgqe','parse','3129335xHuGgf','unverifiable','SKILL.md','find','kind','554Ejiqnr','skills','includes','reason','1236IwxluW','.agents','unusable','\x20records\x20\x22','496HLSQaA','117082CnvSKH','.claude','message','home','\x22\x20but\x20no\x20SKILL.md\x20was\x20found\x20in\x20known\x20layouts\x20','recorded','25277391OdHyIB','object','absent','\x20is\x20unreadable:\x20','version','map'];a123_0x3fed=function(){return _0x159db5;};return a123_0x3fed();}const a123_0xf18cdb=a123_0x1e2a;(function(_0xdb6045,_0x45742c){const _0x29c9d5=a123_0x1e2a,_0x13cb4d=_0xdb6045();while(!![]){try{const _0xd73868=parseInt(_0x29c9d5(0x103))/0x1+parseInt(_0x29c9d5(0x10a))/0x2*(-parseInt(_0x29c9d5(0x10e))/0x3)+-parseInt(_0x29c9d5(0xfe))/0x4+-parseInt(_0x29c9d5(0x105))/0x5+parseInt(_0x29c9d5(0xff))/0x6+-parseInt(_0x29c9d5(0x113))/0x7*(parseInt(_0x29c9d5(0x112))/0x8)+parseInt(_0x29c9d5(0xf6))/0x9;if(_0xd73868===_0x45742c)break;else _0x13cb4d['push'](_0x13cb4d['shift']());}catch(_0x206ca8){_0x13cb4d['push'](_0x13cb4d['shift']());}}}(a123_0x3fed,0x933b8));import{existsSync,readFileSync}from'node:fs';import{homedir}from'node:os';import{join}from'node:path';function a123_0x1e2a(_0x248b5f,_0x574278){_0x248b5f=_0x248b5f-0xf6;const _0x3fed27=a123_0x3fed();let _0x1e2a77=_0x3fed27[_0x248b5f];return _0x1e2a77;}export const SKILL_LOCK_RELATIVE_PATH=join('.agents',a123_0xf18cdb(0xfc));export const GLOBAL_SKILLS_DIR_RELATIVE_PATHS=[join(a123_0xf18cdb(0x10f),a123_0xf18cdb(0x10b)),join(a123_0xf18cdb(0x114),a123_0xf18cdb(0x10b))];const SUPPORTED_LOCK_VERSIONS=[0x3];function readLockLookup(_0x8541c6,_0x1cfd00){const _0x257bbc=a123_0xf18cdb;if(!existsSync(_0x8541c6))return{'kind':'not-recorded'};let _0x2970c2;try{_0x2970c2=JSON[_0x257bbc(0x104)](readFileSync(_0x8541c6,'utf8'));}catch(_0x1a447a){return{'kind':_0x257bbc(0x110),'reason':_0x8541c6+_0x257bbc(0xf9)+_0x1a447a[_0x257bbc(0x115)]};}const _0x1d7cdc=_0x2970c2;if(typeof _0x1d7cdc?.[_0x257bbc(0xfa)]!=='number'||!SUPPORTED_LOCK_VERSIONS[_0x257bbc(0x10c)](_0x1d7cdc[_0x257bbc(0xfa)]))return{'kind':'unusable','reason':_0x8541c6+_0x257bbc(0x100)+String(_0x1d7cdc?.[_0x257bbc(0xfa)])};if(!_0x1d7cdc['skills']||typeof _0x1d7cdc[_0x257bbc(0x10b)]!==_0x257bbc(0xf7))return{'kind':_0x257bbc(0x110),'reason':_0x8541c6+'\x20has\x20no\x20skills\x20map'};return _0x1d7cdc[_0x257bbc(0x10b)][_0x1cfd00]?{'kind':_0x257bbc(0x118)}:{'kind':'not-recorded'};}export function resolveInstalledSkill(_0x34ef69,_0x1d2db8){const _0x5d5842=a123_0xf18cdb,_0x20fe20=_0x1d2db8?.[_0x5d5842(0x116)]??homedir(),_0x3e4952=_0x1d2db8?.[_0x5d5842(0x101)]??GLOBAL_SKILLS_DIR_RELATIVE_PATHS[_0x5d5842(0xfb)](_0xb6d82d=>join(_0x20fe20,_0xb6d82d)),_0x353f3c=_0x1d2db8?.['lockFile']??join(_0x20fe20,SKILL_LOCK_RELATIVE_PATH),_0x456789=_0x3e4952[_0x5d5842(0xfb)](_0x4454f6=>join(_0x4454f6,_0x34ef69,_0x5d5842(0x107))),_0x1d93f2=_0x456789[_0x5d5842(0x108)](_0x571d46=>existsSync(_0x571d46));if(_0x1d93f2)return{'state':_0x5d5842(0xfd),'path':_0x1d93f2};const _0x4e0ea3=readLockLookup(_0x353f3c,_0x34ef69);if(_0x4e0ea3[_0x5d5842(0x109)]===_0x5d5842(0x110))return{'state':_0x5d5842(0x106),'reason':_0x4e0ea3[_0x5d5842(0x10d)]};if(_0x4e0ea3['kind']==='recorded')return{'state':_0x5d5842(0x106),'reason':_0x353f3c+_0x5d5842(0x111)+_0x34ef69+_0x5d5842(0x117)+('('+_0x456789[_0x5d5842(0x102)](',\x20')+')')};return{'state':_0x5d5842(0xf8),'checked':_0x456789};}
1
+ const a123_0x429e5a=a123_0x4562;(function(_0x2d4d83,_0x3bd202){const _0x39a36d=a123_0x4562,_0x42c522=_0x2d4d83();while(!![]){try{const _0x256794=parseInt(_0x39a36d(0x190))/0x1*(-parseInt(_0x39a36d(0x17e))/0x2)+-parseInt(_0x39a36d(0x18d))/0x3*(-parseInt(_0x39a36d(0x193))/0x4)+-parseInt(_0x39a36d(0x18a))/0x5+parseInt(_0x39a36d(0x17b))/0x6+parseInt(_0x39a36d(0x196))/0x7+-parseInt(_0x39a36d(0x182))/0x8+parseInt(_0x39a36d(0x18f))/0x9*(parseInt(_0x39a36d(0x180))/0xa);if(_0x256794===_0x3bd202)break;else _0x42c522['push'](_0x42c522['shift']());}catch(_0x52ecb5){_0x42c522['push'](_0x42c522['shift']());}}}(a123_0x4536,0x3b706));function a123_0x4562(_0x592b69,_0x3884ab){_0x592b69=_0x592b69-0x178;const _0x4536a3=a123_0x4536();let _0x4562f8=_0x4536a3[_0x592b69];return _0x4562f8;}import{existsSync,readFileSync}from'node:fs';import{homedir}from'node:os';function a123_0x4536(){const _0x140e8b=['find','present','220370qJgEhr','globalSkillsDirs','11650njaJwg','recorded','2865856sGOPIk','\x20is\x20unreadable:\x20','object','.agents','\x20uses\x20unsupported\x20version\x20','.claude','home','\x20records\x20\x22','73430ZQtcdy','lockFile','unverifiable','336759OGFzLf','version','3177KHCXxW','3myVlNR','reason','map','4grDLKa','message','not-recorded','566657AWEJmv','unusable','join','SKILL.md','\x20has\x20no\x20skills\x20map','skills','kind','utf8','2054916mjkXSW'];a123_0x4536=function(){return _0x140e8b;};return a123_0x4536();}import{join}from'node:path';export const SKILL_LOCK_RELATIVE_PATH=join(a123_0x429e5a(0x185),'.skill-lock.json');export const GLOBAL_SKILLS_DIR_RELATIVE_PATHS=[join(a123_0x429e5a(0x185),'skills'),join(a123_0x429e5a(0x187),a123_0x429e5a(0x178))];const SUPPORTED_LOCK_VERSIONS=[0x3];function readLockLookup(_0x590285,_0x21b489){const _0x3c26d2=a123_0x429e5a;if(!existsSync(_0x590285))return{'kind':_0x3c26d2(0x195)};let _0x2b1b6e;try{_0x2b1b6e=JSON['parse'](readFileSync(_0x590285,_0x3c26d2(0x17a)));}catch(_0x11de94){return{'kind':_0x3c26d2(0x197),'reason':_0x590285+_0x3c26d2(0x183)+_0x11de94[_0x3c26d2(0x194)]};}const _0x416d89=_0x2b1b6e;if(typeof _0x416d89?.['version']!=='number'||!SUPPORTED_LOCK_VERSIONS['includes'](_0x416d89[_0x3c26d2(0x18e)]))return{'kind':_0x3c26d2(0x197),'reason':_0x590285+_0x3c26d2(0x186)+String(_0x416d89?.[_0x3c26d2(0x18e)])};if(!_0x416d89[_0x3c26d2(0x178)]||typeof _0x416d89[_0x3c26d2(0x178)]!==_0x3c26d2(0x184))return{'kind':_0x3c26d2(0x197),'reason':_0x590285+_0x3c26d2(0x19a)};return _0x416d89[_0x3c26d2(0x178)][_0x21b489]?{'kind':_0x3c26d2(0x181)}:{'kind':'not-recorded'};}export function resolveInstalledSkill(_0x9d66a5,_0x26875f){const _0x36ce6f=a123_0x429e5a,_0x19bdef=_0x26875f?.[_0x36ce6f(0x188)]??homedir(),_0x3cc3a9=_0x26875f?.[_0x36ce6f(0x17f)]??GLOBAL_SKILLS_DIR_RELATIVE_PATHS[_0x36ce6f(0x192)](_0x29b3b1=>join(_0x19bdef,_0x29b3b1)),_0x29f795=_0x26875f?.[_0x36ce6f(0x18b)]??join(_0x19bdef,SKILL_LOCK_RELATIVE_PATH),_0x3856ba=_0x3cc3a9[_0x36ce6f(0x192)](_0xb5d3eb=>join(_0xb5d3eb,_0x9d66a5,_0x36ce6f(0x199))),_0x5bab9a=_0x3856ba[_0x36ce6f(0x17c)](_0x47a31f=>existsSync(_0x47a31f));if(_0x5bab9a)return{'state':_0x36ce6f(0x17d),'path':_0x5bab9a};const _0x5aeb4d=readLockLookup(_0x29f795,_0x9d66a5);if(_0x5aeb4d['kind']===_0x36ce6f(0x197))return{'state':_0x36ce6f(0x18c),'reason':_0x5aeb4d[_0x36ce6f(0x191)]};if(_0x5aeb4d[_0x36ce6f(0x179)]===_0x36ce6f(0x181))return{'state':_0x36ce6f(0x18c),'reason':_0x29f795+_0x36ce6f(0x189)+_0x9d66a5+'\x22\x20but\x20no\x20SKILL.md\x20was\x20found\x20in\x20known\x20layouts\x20'+('('+_0x3856ba[_0x36ce6f(0x198)](',\x20')+')')};return{'state':'absent','checked':_0x3856ba};}
@@ -1 +1 @@
1
- (function(_0x1c9cb3,_0x1b3315){const _0x256efe=a124_0xf910,_0x40ed33=_0x1c9cb3();while(!![]){try{const _0x4921b7=-parseInt(_0x256efe(0xf8))/0x1+parseInt(_0x256efe(0xed))/0x2*(-parseInt(_0x256efe(0xf3))/0x3)+parseInt(_0x256efe(0xf0))/0x4*(parseInt(_0x256efe(0xf4))/0x5)+-parseInt(_0x256efe(0xf2))/0x6*(parseInt(_0x256efe(0xef))/0x7)+parseInt(_0x256efe(0xf7))/0x8*(-parseInt(_0x256efe(0xf6))/0x9)+parseInt(_0x256efe(0xf1))/0xa*(-parseInt(_0x256efe(0xf5))/0xb)+parseInt(_0x256efe(0xee))/0xc;if(_0x4921b7===_0x1b3315)break;else _0x40ed33['push'](_0x40ed33['shift']());}catch(_0x524304){_0x40ed33['push'](_0x40ed33['shift']());}}}(a124_0x42fd,0xafcc9));import{createJqFilter,resolveBundledJqPaths}from'@lovrabet/cli-framework';import{CliErrors}from'../errors.js';function a124_0x42fd(){const _0x1f27ff=['277708rqUeoJ','73334BNuJEK','44048832NbikVK','3525445UgAOAG','28eZfUMP','130nDLKtc','6oOYsCM','60ucKAEt','197710oHYZMF','1192708iGfnuP','1215TSNHtl','17968XfKadt'];a124_0x42fd=function(){return _0x1f27ff;};return a124_0x42fd();}function a124_0xf910(_0x260737,_0x21df77){_0x260737=_0x260737-0xed;const _0x42fdaa=a124_0x42fd();let _0xf9103c=_0x42fdaa[_0x260737];return _0xf9103c;}export const applyJqFilter=createJqFilter(CliErrors,{'bundledJqPaths':resolveBundledJqPaths()});
1
+ (function(_0x3dcd06,_0x5e4619){const _0x4b1d8d=a124_0x256f,_0x13a262=_0x3dcd06();while(!![]){try{const _0x3458f4=-parseInt(_0x4b1d8d(0x112))/0x1+-parseInt(_0x4b1d8d(0x10f))/0x2*(-parseInt(_0x4b1d8d(0x114))/0x3)+parseInt(_0x4b1d8d(0x115))/0x4+parseInt(_0x4b1d8d(0x113))/0x5+parseInt(_0x4b1d8d(0x111))/0x6*(parseInt(_0x4b1d8d(0x10d))/0x7)+parseInt(_0x4b1d8d(0x110))/0x8+-parseInt(_0x4b1d8d(0x10e))/0x9;if(_0x3458f4===_0x5e4619)break;else _0x13a262['push'](_0x13a262['shift']());}catch(_0x3e70d6){_0x13a262['push'](_0x13a262['shift']());}}}(a124_0x2bc8,0x61b4b));import{createJqFilter,resolveBundledJqPaths}from'@lovrabet/cli-framework';import{CliErrors}from'../errors.js';function a124_0x256f(_0x5f3ad2,_0x3c426e){_0x5f3ad2=_0x5f3ad2-0x10d;const _0x2bc8b5=a124_0x2bc8();let _0x256f9c=_0x2bc8b5[_0x5f3ad2];return _0x256f9c;}export const applyJqFilter=createJqFilter(CliErrors,{'bundledJqPaths':resolveBundledJqPaths()});function a124_0x2bc8(){const _0x54c6de=['321909OGzdcH','319616ldDVNS','252203WUdBpS','4131639zlGVme','2xwxotO','4887984ZvySFn','42OxAeEu','675065czwZWz','2419655lyMYGR'];a124_0x2bc8=function(){return _0x54c6de;};return a124_0x2bc8();}
@@ -1 +1 @@
1
- const a125_0xf62f4d=a125_0x2b5f;(function(_0x5635bf,_0x538a27){const _0x273ad9=a125_0x2b5f,_0x470b54=_0x5635bf();while(!![]){try{const _0x41b7eb=parseInt(_0x273ad9(0x131))/0x1+parseInt(_0x273ad9(0x149))/0x2*(-parseInt(_0x273ad9(0x135))/0x3)+parseInt(_0x273ad9(0x138))/0x4*(parseInt(_0x273ad9(0x161))/0x5)+-parseInt(_0x273ad9(0x15d))/0x6*(-parseInt(_0x273ad9(0x13c))/0x7)+-parseInt(_0x273ad9(0x141))/0x8+-parseInt(_0x273ad9(0x159))/0x9+-parseInt(_0x273ad9(0x154))/0xa*(-parseInt(_0x273ad9(0x15e))/0xb);if(_0x41b7eb===_0x538a27)break;else _0x470b54['push'](_0x470b54['shift']());}catch(_0x27577f){_0x470b54['push'](_0x470b54['shift']());}}}(a125_0x13cc,0x727fe));import a125_0xae542a from'winston';import a125_0x33a17d from'node:fs';function a125_0x2b5f(_0x40bb07,_0x2153d1){_0x40bb07=_0x40bb07-0x130;const _0x13cc85=a125_0x13cc();let _0x2b5fde=_0x13cc85[_0x40bb07];return _0x2b5fde;}import a125_0x3d4931 from'node:path';import{PRODUCT_CONFIG}from'../constant/product.js';class Logger{[a125_0xf62f4d(0x13e)];['logFilePath']='';[a125_0xf62f4d(0x143)]='';constructor(){}[a125_0xf62f4d(0x134)](_0x59f17c){const _0xb88629=a125_0xf62f4d;this[_0xb88629(0x143)]=_0x59f17c;}[a125_0xf62f4d(0x13a)](_0x47a31c){const _0x4fac7d=a125_0xf62f4d;this[_0x4fac7d(0x15b)]=a125_0x3d4931[_0x4fac7d(0x150)](_0x47a31c,PRODUCT_CONFIG[_0x4fac7d(0x145)]),this['winstonLogger']&&this[_0x4fac7d(0x13e)][_0x4fac7d(0x162)](),this[_0x4fac7d(0x14d)]();}['initWinstonLogger'](){const _0x353482=a125_0xf62f4d,_0x43b3b1=a125_0x3d4931[_0x353482(0x153)](this[_0x353482(0x15b)]);!a125_0x33a17d[_0x353482(0x160)](_0x43b3b1)&&a125_0x33a17d[_0x353482(0x155)](_0x43b3b1,{'recursive':!![]});const _0x16e934=a125_0xae542a[_0x353482(0x152)]['combine'](a125_0xae542a[_0x353482(0x152)]['timestamp'](),a125_0xae542a[_0x353482(0x152)][_0x353482(0x157)]({'stack':!![]}),a125_0xae542a[_0x353482(0x152)]['printf'](_0x3f639b=>{const _0x4480a7=_0x353482,_0x5611b2={'timestamp':_0x3f639b[_0x4480a7(0x14e)]||new Date()['toISOString'](),'level':_0x3f639b[_0x4480a7(0x15a)]||_0x4480a7(0x142),'command':_0x3f639b[_0x4480a7(0x163)]||'unknown','rawCommand':_0x3f639b[_0x4480a7(0x148)]||this[_0x4480a7(0x143)]||undefined,'message':_0x3f639b[_0x4480a7(0x139)]||'','duration':_0x3f639b[_0x4480a7(0x167)]||undefined,'details':_0x3f639b[_0x4480a7(0x14b)]||undefined};return JSON[_0x4480a7(0x132)](_0x5611b2);}));this[_0x353482(0x13e)]=a125_0xae542a[_0x353482(0x14a)]({'level':'info','format':_0x16e934,'transports':[new a125_0xae542a[(_0x353482(0x15f))]['File']({'filename':this[_0x353482(0x15b)],'level':'info'})],'silent':![]}),a125_0xae542a[_0x353482(0x14f)]({'success':_0x353482(0x130),'error':_0x353482(0x133),'warn':'yellow','info':'blue'});}[a125_0xf62f4d(0x142)](_0x15ca9c,_0x3c12db,_0x303a64){const _0x281acf=a125_0xf62f4d;if(!this['logFilePath']||!this[_0x281acf(0x13e)])return;this[_0x281acf(0x13e)]['info'](_0x3c12db,{'command':_0x15ca9c,'details':_0x303a64});}[a125_0xf62f4d(0x146)](_0x42848a,_0x2915a8,_0x1de914,_0x26eb49){const _0x39468d=a125_0xf62f4d;if(!this['logFilePath']||!this[_0x39468d(0x13e)])return;this[_0x39468d(0x13e)][_0x39468d(0x15c)](_0x39468d(0x142),_0x2915a8,{'level':_0x39468d(0x146),'command':_0x42848a,'duration':_0x1de914,'details':_0x26eb49});}[a125_0xf62f4d(0x168)](_0x323b46,_0x747dee,_0x49c870){const _0x372dfc=a125_0xf62f4d;if(!this['logFilePath']||!this['winstonLogger'])return;this[_0x372dfc(0x13e)][_0x372dfc(0x168)](_0x747dee,{'command':_0x323b46,'details':_0x49c870});}['warn'](_0x56b731,_0x2ac254,_0x21df04){const _0x190a9a=a125_0xf62f4d;if(!this['logFilePath']||!this[_0x190a9a(0x13e)])return;this[_0x190a9a(0x13e)]['warn'](_0x2ac254,{'command':_0x56b731,'details':_0x21df04});}async[a125_0xf62f4d(0x13d)](_0x15608e,_0x2ceeb7,_0xa0b65c){const _0x20029c=a125_0xf62f4d,_0x4ebcc7=Date[_0x20029c(0x158)]();this[_0x20029c(0x142)](_0x15608e,_0x20029c(0x137)+_0x2ceeb7);try{const _0x5b4816=await _0xa0b65c(),_0x237788=Date[_0x20029c(0x158)]()-_0x4ebcc7;return this[_0x20029c(0x146)](_0x15608e,_0x20029c(0x166)+_0x2ceeb7,_0x237788),_0x5b4816;}catch(_0x410271){const _0x54ef69=Date[_0x20029c(0x158)]()-_0x4ebcc7;this['error'](_0x15608e,_0x20029c(0x169)+_0x2ceeb7,{'error':_0x410271 instanceof Error?_0x410271[_0x20029c(0x139)]:String(_0x410271),'duration':_0x54ef69});throw _0x410271;}}[a125_0xf62f4d(0x164)](){const _0x204a20=a125_0xf62f4d;try{if(!a125_0x33a17d[_0x204a20(0x160)](this[_0x204a20(0x15b)]))return[];const _0x283381=a125_0x33a17d[_0x204a20(0x14c)](this[_0x204a20(0x15b)],_0x204a20(0x165));return _0x283381[_0x204a20(0x140)](/\r?\n/)[_0x204a20(0x136)](_0x3812b2=>_0x3812b2[_0x204a20(0x156)]())[_0x204a20(0x13f)](_0x109b72=>JSON['parse'](_0x109b72));}catch(_0x4d6abb){return console[_0x204a20(0x13b)]('Failed\x20to\x20read\x20logs:',_0x4d6abb),[];}}[a125_0xf62f4d(0x144)](){const _0x3f4bf9=a125_0xf62f4d;try{a125_0x33a17d[_0x3f4bf9(0x160)](this[_0x3f4bf9(0x15b)])&&a125_0x33a17d[_0x3f4bf9(0x151)](this[_0x3f4bf9(0x15b)],'',_0x3f4bf9(0x165));}catch(_0x32c5f2){console['warn']('Failed\x20to\x20clear\x20logs:',_0x32c5f2);}}[a125_0xf62f4d(0x147)](){return this['winstonLogger'];}}export const logger=new Logger();function a125_0x13cc(){const _0x39bf9a=['level','logFilePath','log','3288uYLPcV','649CfOXZk','transports','existsSync','10RMNESa','clear','command','readLogs','utf8','Completed:\x20','duration','error','Failed:\x20','green','625450CXHGTu','stringify','red','setRawCommand','437163geYxAT','filter','Starting:\x20','65276NnhYPk','message','setLogPath','warn','2835UFxyCn','logTask','winstonLogger','map','split','375352nklfhb','info','currentRawCommand','clearLogs','logFileName','success','getWinstonInstance','rawCommand','12VBeskl','createLogger','details','readFileSync','initWinstonLogger','timestamp','addColors','join','writeFileSync','format','dirname','209190NnGYRk','mkdirSync','trim','errors','now','6516126ppIFJM'];a125_0x13cc=function(){return _0x39bf9a;};return a125_0x13cc();}
1
+ const a125_0x5b31d7=a125_0x1073;function a125_0x1073(_0x44bd76,_0x51f7a1){_0x44bd76=_0x44bd76-0x1d7;const _0x40f127=a125_0x40f1();let _0x10731a=_0x40f127[_0x44bd76];return _0x10731a;}(function(_0x1d17a1,_0x2f722e){const _0x3c4e9a=a125_0x1073,_0x19b1a6=_0x1d17a1();while(!![]){try{const _0x154485=parseInt(_0x3c4e9a(0x1e4))/0x1+parseInt(_0x3c4e9a(0x20f))/0x2*(parseInt(_0x3c4e9a(0x1e5))/0x3)+-parseInt(_0x3c4e9a(0x211))/0x4+-parseInt(_0x3c4e9a(0x203))/0x5+-parseInt(_0x3c4e9a(0x1f1))/0x6*(parseInt(_0x3c4e9a(0x1dd))/0x7)+parseInt(_0x3c4e9a(0x210))/0x8*(-parseInt(_0x3c4e9a(0x208))/0x9)+-parseInt(_0x3c4e9a(0x1e6))/0xa*(-parseInt(_0x3c4e9a(0x20b))/0xb);if(_0x154485===_0x2f722e)break;else _0x19b1a6['push'](_0x19b1a6['shift']());}catch(_0x18ac6f){_0x19b1a6['push'](_0x19b1a6['shift']());}}}(a125_0x40f1,0x437d9));import a125_0x1885c9 from'winston';import a125_0x5d9be9 from'node:fs';import a125_0x37d73d from'node:path';function a125_0x40f1(){const _0x12ea68=['error','utf8','timestamp','writeFileSync','blue','initWinstonLogger','71646hTcbgL','combine','logFilePath','errors','join','warn','trim','map','existsSync','Completed:\x20','rawCommand','getWinstonInstance','readLogs','success','info','createLogger','filter','now','214920XZiBMU','split','command','readFileSync','log','522EuHLVN','clearLogs','red','156552sKbqsN','parse','transports','setRawCommand','160qpxzmr','49944wjZEEb','1830748qxewTd','mkdirSync','format','toISOString','level','logFileName','yellow','238CUWSuo','Failed\x20to\x20clear\x20logs:','message','currentRawCommand','Starting:\x20','details','Failed\x20to\x20read\x20logs:','542928IzopDE','2361PwyLkb','660NjwgHS','logTask','Failed:\x20','winstonLogger','duration'];a125_0x40f1=function(){return _0x12ea68;};return a125_0x40f1();}import{PRODUCT_CONFIG}from'../constant/product.js';class Logger{[a125_0x5b31d7(0x1e9)];[a125_0x5b31d7(0x1f3)]='';[a125_0x5b31d7(0x1e0)]='';constructor(){}[a125_0x5b31d7(0x20e)](_0x40130c){const _0x297a7c=a125_0x5b31d7;this[_0x297a7c(0x1e0)]=_0x40130c;}['setLogPath'](_0x2170d6){const _0x5996ec=a125_0x5b31d7;this[_0x5996ec(0x1f3)]=a125_0x37d73d[_0x5996ec(0x1f5)](_0x2170d6,PRODUCT_CONFIG[_0x5996ec(0x1db)]),this[_0x5996ec(0x1e9)]&&this[_0x5996ec(0x1e9)]['clear'](),this[_0x5996ec(0x1f0)]();}[a125_0x5b31d7(0x1f0)](){const _0x103413=a125_0x5b31d7,_0x5a3ca7=a125_0x37d73d['dirname'](this[_0x103413(0x1f3)]);!a125_0x5d9be9[_0x103413(0x1f9)](_0x5a3ca7)&&a125_0x5d9be9[_0x103413(0x1d7)](_0x5a3ca7,{'recursive':!![]});const _0x3e4de6=a125_0x1885c9[_0x103413(0x1d8)][_0x103413(0x1f2)](a125_0x1885c9[_0x103413(0x1d8)]['timestamp'](),a125_0x1885c9['format'][_0x103413(0x1f4)]({'stack':!![]}),a125_0x1885c9[_0x103413(0x1d8)]['printf'](_0x462401=>{const _0x4e5253=_0x103413,_0x436e5e={'timestamp':_0x462401[_0x4e5253(0x1ed)]||new Date()[_0x4e5253(0x1d9)](),'level':_0x462401[_0x4e5253(0x1da)]||_0x4e5253(0x1ff),'command':_0x462401[_0x4e5253(0x205)]||'unknown','rawCommand':_0x462401[_0x4e5253(0x1fb)]||this[_0x4e5253(0x1e0)]||undefined,'message':_0x462401['message']||'','duration':_0x462401[_0x4e5253(0x1ea)]||undefined,'details':_0x462401[_0x4e5253(0x1e2)]||undefined};return JSON['stringify'](_0x436e5e);}));this[_0x103413(0x1e9)]=a125_0x1885c9[_0x103413(0x200)]({'level':'info','format':_0x3e4de6,'transports':[new a125_0x1885c9[(_0x103413(0x20d))]['File']({'filename':this['logFilePath'],'level':_0x103413(0x1ff)})],'silent':![]}),a125_0x1885c9['addColors']({'success':'green','error':_0x103413(0x20a),'warn':_0x103413(0x1dc),'info':_0x103413(0x1ef)});}[a125_0x5b31d7(0x1ff)](_0x2fcd12,_0x2013ea,_0x52b55d){const _0x4e742f=a125_0x5b31d7;if(!this['logFilePath']||!this[_0x4e742f(0x1e9)])return;this[_0x4e742f(0x1e9)][_0x4e742f(0x1ff)](_0x2013ea,{'command':_0x2fcd12,'details':_0x52b55d});}['success'](_0x119ec7,_0x17dbbe,_0x4cccb3,_0x2b6062){const _0x24d346=a125_0x5b31d7;if(!this[_0x24d346(0x1f3)]||!this['winstonLogger'])return;this['winstonLogger'][_0x24d346(0x207)](_0x24d346(0x1ff),_0x17dbbe,{'level':_0x24d346(0x1fe),'command':_0x119ec7,'duration':_0x4cccb3,'details':_0x2b6062});}[a125_0x5b31d7(0x1eb)](_0x443f33,_0x20c84f,_0x7abe1e){const _0x596a84=a125_0x5b31d7;if(!this[_0x596a84(0x1f3)]||!this[_0x596a84(0x1e9)])return;this[_0x596a84(0x1e9)]['error'](_0x20c84f,{'command':_0x443f33,'details':_0x7abe1e});}[a125_0x5b31d7(0x1f6)](_0x41de40,_0x109027,_0x2c0ce0){const _0x545895=a125_0x5b31d7;if(!this['logFilePath']||!this['winstonLogger'])return;this['winstonLogger'][_0x545895(0x1f6)](_0x109027,{'command':_0x41de40,'details':_0x2c0ce0});}async[a125_0x5b31d7(0x1e7)](_0x4c4e4a,_0x13ae43,_0x1e05ad){const _0x5024d3=a125_0x5b31d7,_0x302cad=Date[_0x5024d3(0x202)]();this[_0x5024d3(0x1ff)](_0x4c4e4a,_0x5024d3(0x1e1)+_0x13ae43);try{const _0x1223fc=await _0x1e05ad(),_0x16a97b=Date[_0x5024d3(0x202)]()-_0x302cad;return this[_0x5024d3(0x1fe)](_0x4c4e4a,_0x5024d3(0x1fa)+_0x13ae43,_0x16a97b),_0x1223fc;}catch(_0x2ec860){const _0x1de2fc=Date['now']()-_0x302cad;this[_0x5024d3(0x1eb)](_0x4c4e4a,_0x5024d3(0x1e8)+_0x13ae43,{'error':_0x2ec860 instanceof Error?_0x2ec860[_0x5024d3(0x1df)]:String(_0x2ec860),'duration':_0x1de2fc});throw _0x2ec860;}}[a125_0x5b31d7(0x1fd)](){const _0x36c054=a125_0x5b31d7;try{if(!a125_0x5d9be9[_0x36c054(0x1f9)](this[_0x36c054(0x1f3)]))return[];const _0x4f9b4e=a125_0x5d9be9[_0x36c054(0x206)](this[_0x36c054(0x1f3)],_0x36c054(0x1ec));return _0x4f9b4e[_0x36c054(0x204)](/\r?\n/)[_0x36c054(0x201)](_0x19aa87=>_0x19aa87[_0x36c054(0x1f7)]())[_0x36c054(0x1f8)](_0x4ed166=>JSON[_0x36c054(0x20c)](_0x4ed166));}catch(_0x4c1648){return console[_0x36c054(0x1f6)](_0x36c054(0x1e3),_0x4c1648),[];}}[a125_0x5b31d7(0x209)](){const _0x53299a=a125_0x5b31d7;try{a125_0x5d9be9['existsSync'](this['logFilePath'])&&a125_0x5d9be9[_0x53299a(0x1ee)](this[_0x53299a(0x1f3)],'',_0x53299a(0x1ec));}catch(_0x1c461d){console[_0x53299a(0x1f6)](_0x53299a(0x1de),_0x1c461d);}}[a125_0x5b31d7(0x1fc)](){const _0x315fae=a125_0x5b31d7;return this[_0x315fae(0x1e9)];}}export const logger=new Logger();
@@ -1 +1 @@
1
- const a126_0x5d9e90=a126_0x2410;(function(_0x22222c,_0x42d3f7){const _0x1b16f5=a126_0x2410,_0x252a80=_0x22222c();while(!![]){try{const _0x6d8eba=-parseInt(_0x1b16f5(0xdd))/0x1+parseInt(_0x1b16f5(0xd5))/0x2+-parseInt(_0x1b16f5(0xdc))/0x3*(-parseInt(_0x1b16f5(0xe5))/0x4)+parseInt(_0x1b16f5(0xe2))/0x5*(-parseInt(_0x1b16f5(0xd8))/0x6)+parseInt(_0x1b16f5(0xe4))/0x7*(parseInt(_0x1b16f5(0xe7))/0x8)+-parseInt(_0x1b16f5(0xdf))/0x9*(-parseInt(_0x1b16f5(0xe3))/0xa)+-parseInt(_0x1b16f5(0xd6))/0xb;if(_0x6d8eba===_0x42d3f7)break;else _0x252a80['push'](_0x252a80['shift']());}catch(_0x5d5621){_0x252a80['push'](_0x252a80['shift']());}}}(a126_0x2431,0x9535b));function a126_0x2410(_0x2fce35,_0x46fa22){_0x2fce35=_0x2fce35-0xd3;const _0x243160=a126_0x2431();let _0x241018=_0x243160[_0x2fce35];return _0x241018;}const JSON_NUMBER_PATTERN=/^-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][+-]?\d+)?/,MAX_SAFE_INTEGER=BigInt(Number[a126_0x5d9e90(0xda)]),MIN_SAFE_INTEGER=BigInt(Number[a126_0x5d9e90(0xde)]);let restoreResponseJsonParser,responseJsonPrototype,originalResponseJsonDescriptor;function isUnsafeIntegerLiteral(_0x1854ac){const _0x1b495c=a126_0x5d9e90;if(_0x1854ac[_0x1b495c(0xd4)]('.')||_0x1854ac[_0x1b495c(0xd4)]('e')||_0x1854ac[_0x1b495c(0xd4)]('E'))return![];const _0x5310d0=BigInt(_0x1854ac);return _0x5310d0>MAX_SAFE_INTEGER||_0x5310d0<MIN_SAFE_INTEGER;}function quoteUnsafeIntegerLiterals(_0x53ee24){const _0x211ae2=a126_0x5d9e90;let _0xa8ac6a='',_0x5eadd3=![],_0x4d24e5=![];for(let _0x506e18=0x0;_0x506e18<_0x53ee24['length'];){const _0x16ad48=_0x53ee24[_0x506e18];if(_0x5eadd3){_0xa8ac6a+=_0x16ad48,_0x506e18+=0x1;if(_0x4d24e5)_0x4d24e5=![];else{if(_0x16ad48==='\x5c')_0x4d24e5=!![];else _0x16ad48==='\x22'&&(_0x5eadd3=![]);}continue;}if(_0x16ad48==='\x22'){_0x5eadd3=!![],_0xa8ac6a+=_0x16ad48,_0x506e18+=0x1;continue;}if(_0x16ad48==='-'||_0x16ad48>='0'&&_0x16ad48<='9'){const _0x51dfa0=JSON_NUMBER_PATTERN[_0x211ae2(0xd3)](_0x53ee24[_0x211ae2(0xd7)](_0x506e18))?.[0x0];if(_0x51dfa0){_0xa8ac6a+=isUnsafeIntegerLiteral(_0x51dfa0)?'\x22'+_0x51dfa0+'\x22':_0x51dfa0,_0x506e18+=_0x51dfa0[_0x211ae2(0xd9)];continue;}}_0xa8ac6a+=_0x16ad48,_0x506e18+=0x1;}return _0xa8ac6a;}function a126_0x2431(){const _0x1fda43=['6APPIfE','146390InAutV','MIN_SAFE_INTEGER','3600LOFXji','json','defineProperty','1560735LhKQZY','3150VEaIws','2051133rgtKeZ','767100HXiHOr','undefined','16aNktLi','exec','includes','1524224CCDJIx','1800766voHUhq','slice','18GWmwkG','length','MAX_SAFE_INTEGER','getOwnPropertyDescriptor'];a126_0x2431=function(){return _0x1fda43;};return a126_0x2431();}export function parseLosslessJson(_0x54334c){return JSON['parse'](quoteUnsafeIntegerLiterals(_0x54334c));}export function installLosslessJsonResponseParser(){const _0x296c4b=a126_0x5d9e90;if(typeof Response===_0x296c4b(0xe6))return()=>{};if(restoreResponseJsonParser)return restoreResponseJsonParser;return responseJsonPrototype=Response['prototype'],originalResponseJsonDescriptor=Object[_0x296c4b(0xdb)](responseJsonPrototype,_0x296c4b(0xe0)),Object[_0x296c4b(0xe1)](responseJsonPrototype,_0x296c4b(0xe0),{...originalResponseJsonDescriptor??{'configurable':!![],'enumerable':![],'writable':!![]},'value':async function _0x4ad6c8(){return parseLosslessJson(await this['text']());}}),restoreResponseJsonParser=()=>{const _0x247991=_0x296c4b;if(!responseJsonPrototype)return;originalResponseJsonDescriptor?Object[_0x247991(0xe1)](responseJsonPrototype,_0x247991(0xe0),originalResponseJsonDescriptor):delete responseJsonPrototype['json'],responseJsonPrototype=undefined,originalResponseJsonDescriptor=undefined,restoreResponseJsonParser=undefined;},restoreResponseJsonParser;}export function restoreLosslessJsonResponseParser(){restoreResponseJsonParser?.();}
1
+ const a126_0x2b9abb=a126_0xefba;function a126_0x2dcf(){const _0x2d5401=['1290646rdnFhe','prototype','exec','6264140IprQzj','text','slice','2607745mRAGjk','792066jfWdjU','json','undefined','11PvWXmy','parse','39011oQfiYo','defineProperty','length','includes','MIN_SAFE_INTEGER','MAX_SAFE_INTEGER','168CEiAGi','7740GfXUWc','1711508PqvOty','4952tOwdyu','3qOtQdm','getOwnPropertyDescriptor'];a126_0x2dcf=function(){return _0x2d5401;};return a126_0x2dcf();}function a126_0xefba(_0x4bf264,_0x5e9bd8){_0x4bf264=_0x4bf264-0x102;const _0x2dcf7b=a126_0x2dcf();let _0xefba6f=_0x2dcf7b[_0x4bf264];return _0xefba6f;}(function(_0x1d4082,_0x4e5164){const _0x1959dc=a126_0xefba,_0xc0acde=_0x1d4082();while(!![]){try{const _0xf043e5=parseInt(_0x1959dc(0x103))/0x1+parseInt(_0x1959dc(0x114))/0x2+-parseInt(_0x1959dc(0x112))/0x3*(parseInt(_0x1959dc(0x110))/0x4)+-parseInt(_0x1959dc(0x102))/0x5+parseInt(_0x1959dc(0x10e))/0x6*(-parseInt(_0x1959dc(0x108))/0x7)+parseInt(_0x1959dc(0x111))/0x8*(-parseInt(_0x1959dc(0x10f))/0x9)+-parseInt(_0x1959dc(0x117))/0xa*(-parseInt(_0x1959dc(0x106))/0xb);if(_0xf043e5===_0x4e5164)break;else _0xc0acde['push'](_0xc0acde['shift']());}catch(_0x3d7348){_0xc0acde['push'](_0xc0acde['shift']());}}}(a126_0x2dcf,0x68009));const JSON_NUMBER_PATTERN=/^-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][+-]?\d+)?/,MAX_SAFE_INTEGER=BigInt(Number[a126_0x2b9abb(0x10d)]),MIN_SAFE_INTEGER=BigInt(Number[a126_0x2b9abb(0x10c)]);let restoreResponseJsonParser,responseJsonPrototype,originalResponseJsonDescriptor;function isUnsafeIntegerLiteral(_0xc3a1cf){const _0x25311b=a126_0x2b9abb;if(_0xc3a1cf[_0x25311b(0x10b)]('.')||_0xc3a1cf[_0x25311b(0x10b)]('e')||_0xc3a1cf['includes']('E'))return![];const _0x3e069b=BigInt(_0xc3a1cf);return _0x3e069b>MAX_SAFE_INTEGER||_0x3e069b<MIN_SAFE_INTEGER;}function quoteUnsafeIntegerLiterals(_0xfcb947){const _0x40f6dc=a126_0x2b9abb;let _0x3bd1a1='',_0x323087=![],_0x2b9d9a=![];for(let _0x404575=0x0;_0x404575<_0xfcb947[_0x40f6dc(0x10a)];){const _0x38059d=_0xfcb947[_0x404575];if(_0x323087){_0x3bd1a1+=_0x38059d,_0x404575+=0x1;if(_0x2b9d9a)_0x2b9d9a=![];else{if(_0x38059d==='\x5c')_0x2b9d9a=!![];else _0x38059d==='\x22'&&(_0x323087=![]);}continue;}if(_0x38059d==='\x22'){_0x323087=!![],_0x3bd1a1+=_0x38059d,_0x404575+=0x1;continue;}if(_0x38059d==='-'||_0x38059d>='0'&&_0x38059d<='9'){const _0x3300a8=JSON_NUMBER_PATTERN[_0x40f6dc(0x116)](_0xfcb947[_0x40f6dc(0x119)](_0x404575))?.[0x0];if(_0x3300a8){_0x3bd1a1+=isUnsafeIntegerLiteral(_0x3300a8)?'\x22'+_0x3300a8+'\x22':_0x3300a8,_0x404575+=_0x3300a8[_0x40f6dc(0x10a)];continue;}}_0x3bd1a1+=_0x38059d,_0x404575+=0x1;}return _0x3bd1a1;}export function parseLosslessJson(_0x25394e){const _0x4b54f6=a126_0x2b9abb;return JSON[_0x4b54f6(0x107)](quoteUnsafeIntegerLiterals(_0x25394e));}export function installLosslessJsonResponseParser(){const _0x3cd2fa=a126_0x2b9abb;if(typeof Response===_0x3cd2fa(0x105))return()=>{};if(restoreResponseJsonParser)return restoreResponseJsonParser;return responseJsonPrototype=Response[_0x3cd2fa(0x115)],originalResponseJsonDescriptor=Object[_0x3cd2fa(0x113)](responseJsonPrototype,_0x3cd2fa(0x104)),Object[_0x3cd2fa(0x109)](responseJsonPrototype,_0x3cd2fa(0x104),{...originalResponseJsonDescriptor??{'configurable':!![],'enumerable':![],'writable':!![]},'value':async function _0x4f4bbf(){const _0x577a20=_0x3cd2fa;return parseLosslessJson(await this[_0x577a20(0x118)]());}}),restoreResponseJsonParser=()=>{const _0x36ef4c=_0x3cd2fa;if(!responseJsonPrototype)return;originalResponseJsonDescriptor?Object[_0x36ef4c(0x109)](responseJsonPrototype,_0x36ef4c(0x104),originalResponseJsonDescriptor):delete responseJsonPrototype[_0x36ef4c(0x104)],responseJsonPrototype=undefined,originalResponseJsonDescriptor=undefined,restoreResponseJsonParser=undefined;},restoreResponseJsonParser;}export function restoreLosslessJsonResponseParser(){restoreResponseJsonParser?.();}
@@ -1 +1 @@
1
- (function(_0x4acfb9,_0x5ba9a3){const _0x481c7c=a127_0x5090,_0x5e9cd7=_0x4acfb9();while(!![]){try{const _0x10c573=parseInt(_0x481c7c(0x1e5))/0x1*(-parseInt(_0x481c7c(0x1ec))/0x2)+-parseInt(_0x481c7c(0x1f6))/0x3+-parseInt(_0x481c7c(0x1f2))/0x4*(-parseInt(_0x481c7c(0x1e9))/0x5)+-parseInt(_0x481c7c(0x1e4))/0x6*(parseInt(_0x481c7c(0x1e2))/0x7)+-parseInt(_0x481c7c(0x1f1))/0x8+-parseInt(_0x481c7c(0x1ed))/0x9*(-parseInt(_0x481c7c(0x1f0))/0xa)+parseInt(_0x481c7c(0x1e8))/0xb;if(_0x10c573===_0x5ba9a3)break;else _0x5e9cd7['push'](_0x5e9cd7['shift']());}catch(_0x1aaab0){_0x5e9cd7['push'](_0x5e9cd7['shift']());}}}(a127_0xa549,0x259a8));import{CliErrors}from'../errors.js';import{parseLosslessJson}from'../utils/lossless-json.js';export const MAX_DATA_UPDATE_IDS=0x3e8;function a127_0xa549(){const _0x52daac=['6YvOCqX','167226kFJyeC','Invalid\x20JSON\x20for\x20--params:\x20','isArray','9748255GmbxPj','5qooKEM','isSafeInteger','Example:\x20--params\x20\x27{\x22id\x22:[1,2,3],\x22status\x22:\x22done\x22}\x27','2ztWZXE','41301fxXEsi','map','data\x20update\x20requires\x20\x22id\x22\x20in\x20--params.','220ZsgoRx','1107136WKoYzI','251716IVZLML','data\x20update\x20can\x20update\x20at\x20most\x20','length','validation','918711IDSqdB','test','object','1989491qlJIIA','\x20must\x20be\x20a\x20positive\x20integer\x20or\x20numeric\x20string.'];a127_0xa549=function(){return _0x52daac;};return a127_0xa549();}export function parseJsonParams(_0xe1f55d){const _0x565595=a127_0x5090;if(!_0xe1f55d)return undefined;try{return parseLosslessJson(_0xe1f55d);}catch{throw CliErrors[_0x565595(0x1f5)](_0x565595(0x1e6)+_0xe1f55d);}}export function parseJsonParamsValue(_0x27ddc8){const _0x2aa2b5=a127_0x5090;if(!_0x27ddc8)return undefined;try{return parseLosslessJson(_0x27ddc8);}catch{throw CliErrors[_0x2aa2b5(0x1f5)](_0x2aa2b5(0x1e6)+_0x27ddc8);}}function a127_0x5090(_0x530096,_0x3cda75){_0x530096=_0x530096-0x1e1;const _0xa54975=a127_0xa549();let _0x50900a=_0xa54975[_0x530096];return _0x50900a;}export function parseBatchCreateItemsFromParams(_0x14bf86){const _0x3f4d53=a127_0x5090;if(Array[_0x3f4d53(0x1e7)](_0x14bf86))return _0x14bf86;if(_0x14bf86!==null&&_0x14bf86!==undefined&&typeof _0x14bf86===_0x3f4d53(0x1e1)&&Array[_0x3f4d53(0x1e7)](_0x14bf86['items']))return _0x14bf86['items'];throw CliErrors[_0x3f4d53(0x1f5)]('batchCreate\x20--params\x20must\x20be\x20a\x20JSON\x20array\x20or\x20{\x22items\x22:[...]}','Example:\x20--params\x20\x27[{\x22name\x22:\x22a\x22},{\x22name\x22:\x22b\x22}]\x27');}function parseDataUpdateId(_0x3d074a,_0x13bb6d){const _0x1afb89=a127_0x5090;if(typeof _0x3d074a==='number'&&Number[_0x1afb89(0x1ea)](_0x3d074a)&&_0x3d074a>0x0)return _0x3d074a;if(typeof _0x3d074a==='string'){if(/^[1-9]\d*$/[_0x1afb89(0x1f7)](_0x3d074a))return _0x3d074a;}throw CliErrors[_0x1afb89(0x1f5)]('data\x20update\x20--params.'+_0x13bb6d+_0x1afb89(0x1e3));}export function parseUpdateIdsFromParams(_0x495fa7){const _0x414714=a127_0x5090;if(_0x495fa7===null||_0x495fa7===undefined||typeof _0x495fa7!=='object'||Array[_0x414714(0x1e7)](_0x495fa7))throw CliErrors[_0x414714(0x1f5)]('data\x20update\x20--params\x20must\x20be\x20a\x20JSON\x20object\x20with\x20id.','Example:\x20--params\x20\x27{\x22id\x22:[1,2,3],\x22status\x22:\x22done\x22}\x27');const _0x53b520=_0x495fa7['id'];if(_0x53b520===undefined||_0x53b520===null)throw CliErrors[_0x414714(0x1f5)](_0x414714(0x1ef),_0x414714(0x1eb));const _0x4511f3=Array[_0x414714(0x1e7)](_0x53b520)?_0x53b520:[_0x53b520];if(_0x4511f3['length']===0x0)throw CliErrors['validation']('data\x20update\x20id\x20array\x20cannot\x20be\x20empty.');if(_0x4511f3['length']>MAX_DATA_UPDATE_IDS)throw CliErrors[_0x414714(0x1f5)](_0x414714(0x1f3)+MAX_DATA_UPDATE_IDS+'\x20records\x20per\x20call;\x20received\x20'+_0x4511f3[_0x414714(0x1f4)]+'.');return _0x4511f3[_0x414714(0x1ee)]((_0x24b7c9,_0x4b6c6a)=>parseDataUpdateId(_0x24b7c9,Array[_0x414714(0x1e7)](_0x53b520)?'id['+_0x4b6c6a+']':'id'));}export function normalizeUpdateParamsForRuntime(_0x3bfddd,_0x43ab7a){const _0x281515=a127_0x5090;if(Array[_0x281515(0x1e7)](_0x3bfddd['id'])&&_0x43ab7a[_0x281515(0x1f4)]>0x1)return{..._0x3bfddd,'id':_0x43ab7a['join'](',')};return _0x3bfddd;}
1
+ (function(_0x37473d,_0x486b98){const _0x34df4c=a127_0x5d6b,_0x415950=_0x37473d();while(!![]){try{const _0x5676dc=-parseInt(_0x34df4c(0x9a))/0x1+-parseInt(_0x34df4c(0x82))/0x2*(parseInt(_0x34df4c(0x86))/0x3)+-parseInt(_0x34df4c(0x8c))/0x4+-parseInt(_0x34df4c(0x8d))/0x5+parseInt(_0x34df4c(0x96))/0x6+parseInt(_0x34df4c(0x88))/0x7*(parseInt(_0x34df4c(0x98))/0x8)+parseInt(_0x34df4c(0x93))/0x9;if(_0x5676dc===_0x486b98)break;else _0x415950['push'](_0x415950['shift']());}catch(_0x334d0c){_0x415950['push'](_0x415950['shift']());}}}(a127_0x2df5,0x33aa8));import{CliErrors}from'../errors.js';import{parseLosslessJson}from'../utils/lossless-json.js';export const MAX_DATA_UPDATE_IDS=0x3e8;function a127_0x2df5(){const _0x13b710=['number','6vmHSeR','map','2889173XvAErb','\x20must\x20be\x20a\x20positive\x20integer\x20or\x20numeric\x20string.','data\x20update\x20--params\x20must\x20be\x20a\x20JSON\x20object\x20with\x20id.','data\x20update\x20requires\x20\x22id\x22\x20in\x20--params.','44056IReuib','1308415QaornG','length','data\x20update\x20can\x20update\x20at\x20most\x20','\x20records\x20per\x20call;\x20received\x20','Example:\x20--params\x20\x27{\x22id\x22:[1,2,3],\x22status\x22:\x22done\x22}\x27','object','4750362bUnZzV','join','Example:\x20--params\x20\x27[{\x22name\x22:\x22a\x22},{\x22name\x22:\x22b\x22}]\x27','1343418ZzZBnF','string','8ClBcKV','data\x20update\x20id\x20array\x20cannot\x20be\x20empty.','296527euTjTX','isSafeInteger','Invalid\x20JSON\x20for\x20--params:\x20','isArray','batchCreate\x20--params\x20must\x20be\x20a\x20JSON\x20array\x20or\x20{\x22items\x22:[...]}','383612ibRVgl','id[','validation'];a127_0x2df5=function(){return _0x13b710;};return a127_0x2df5();}export function parseJsonParams(_0x46939c){const _0x21f929=a127_0x5d6b;if(!_0x46939c)return undefined;try{return parseLosslessJson(_0x46939c);}catch{throw CliErrors[_0x21f929(0x84)](_0x21f929(0x9c)+_0x46939c);}}export function parseJsonParamsValue(_0x4118ba){const _0x3e4ff8=a127_0x5d6b;if(!_0x4118ba)return undefined;try{return parseLosslessJson(_0x4118ba);}catch{throw CliErrors['validation'](_0x3e4ff8(0x9c)+_0x4118ba);}}export function parseBatchCreateItemsFromParams(_0x5c0751){const _0x1ba7de=a127_0x5d6b;if(Array[_0x1ba7de(0x80)](_0x5c0751))return _0x5c0751;if(_0x5c0751!==null&&_0x5c0751!==undefined&&typeof _0x5c0751===_0x1ba7de(0x92)&&Array[_0x1ba7de(0x80)](_0x5c0751['items']))return _0x5c0751['items'];throw CliErrors[_0x1ba7de(0x84)](_0x1ba7de(0x81),_0x1ba7de(0x95));}function parseDataUpdateId(_0x3f01b1,_0x253d20){const _0xe18fac=a127_0x5d6b;if(typeof _0x3f01b1===_0xe18fac(0x85)&&Number[_0xe18fac(0x9b)](_0x3f01b1)&&_0x3f01b1>0x0)return _0x3f01b1;if(typeof _0x3f01b1===_0xe18fac(0x97)){if(/^[1-9]\d*$/['test'](_0x3f01b1))return _0x3f01b1;}throw CliErrors['validation']('data\x20update\x20--params.'+_0x253d20+_0xe18fac(0x89));}function a127_0x5d6b(_0x5efc22,_0x566a50){_0x5efc22=_0x5efc22-0x80;const _0x2df57e=a127_0x2df5();let _0x5d6bf5=_0x2df57e[_0x5efc22];return _0x5d6bf5;}export function parseUpdateIdsFromParams(_0x5af62b){const _0x46372d=a127_0x5d6b;if(_0x5af62b===null||_0x5af62b===undefined||typeof _0x5af62b!==_0x46372d(0x92)||Array[_0x46372d(0x80)](_0x5af62b))throw CliErrors[_0x46372d(0x84)](_0x46372d(0x8a),_0x46372d(0x91));const _0x2a484b=_0x5af62b['id'];if(_0x2a484b===undefined||_0x2a484b===null)throw CliErrors['validation'](_0x46372d(0x8b),'Example:\x20--params\x20\x27{\x22id\x22:[1,2,3],\x22status\x22:\x22done\x22}\x27');const _0x28ff72=Array[_0x46372d(0x80)](_0x2a484b)?_0x2a484b:[_0x2a484b];if(_0x28ff72[_0x46372d(0x8e)]===0x0)throw CliErrors['validation'](_0x46372d(0x99));if(_0x28ff72['length']>MAX_DATA_UPDATE_IDS)throw CliErrors[_0x46372d(0x84)](_0x46372d(0x8f)+MAX_DATA_UPDATE_IDS+_0x46372d(0x90)+_0x28ff72[_0x46372d(0x8e)]+'.');return _0x28ff72[_0x46372d(0x87)]((_0x100443,_0x368402)=>parseDataUpdateId(_0x100443,Array[_0x46372d(0x80)](_0x2a484b)?_0x46372d(0x83)+_0x368402+']':'id'));}export function normalizeUpdateParamsForRuntime(_0x36eea4,_0x32fefe){const _0x259a7a=a127_0x5d6b;if(Array[_0x259a7a(0x80)](_0x36eea4['id'])&&_0x32fefe[_0x259a7a(0x8e)]>0x1)return{..._0x36eea4,'id':_0x32fefe[_0x259a7a(0x94)](',')};return _0x36eea4;}
@@ -1 +1 @@
1
- function a128_0xcaed(){const _0x29b22d=['2211306Ktpjbn','win32','6RsMKCi','531314oTlEpC','199490vkRrwO','504ViHnUZ','platform','8Jeiaos','672164nOeeqj','6908tKsbJk','47844xRatCy','2SXCUPZ','637973RSbPDk','2604955Uivrha'];a128_0xcaed=function(){return _0x29b22d;};return a128_0xcaed();}const a128_0x4838fe=a128_0x68a1;(function(_0x2757db,_0xa134aa){const _0x23045e=a128_0x68a1,_0x101996=_0x2757db();while(!![]){try{const _0x28f2e2=parseInt(_0x23045e(0x174))/0x1*(parseInt(_0x23045e(0x16e))/0x2)+-parseInt(_0x23045e(0x171))/0x3+parseInt(_0x23045e(0x16b))/0x4+-parseInt(_0x23045e(0x170))/0x5*(parseInt(_0x23045e(0x173))/0x6)+parseInt(_0x23045e(0x16f))/0x7*(parseInt(_0x23045e(0x16a))/0x8)+parseInt(_0x23045e(0x168))/0x9*(-parseInt(_0x23045e(0x167))/0xa)+parseInt(_0x23045e(0x16c))/0xb*(parseInt(_0x23045e(0x16d))/0xc);if(_0x28f2e2===_0xa134aa)break;else _0x101996['push'](_0x101996['shift']());}catch(_0x5870ea){_0x101996['push'](_0x101996['shift']());}}}(a128_0xcaed,0xe0635));export const isWindows=process[a128_0x4838fe(0x169)]===a128_0x4838fe(0x172);function a128_0x68a1(_0x1d72dd,_0x18fc09){_0x1d72dd=_0x1d72dd-0x167;const _0xcaeda0=a128_0xcaed();let _0x68a1fa=_0xcaeda0[_0x1d72dd];return _0x68a1fa;}export function resolveNpmBin(_0x2e20aa){return isWindows?_0x2e20aa+'.cmd':_0x2e20aa;}
1
+ const a128_0x251f8f=a128_0x1e0c;(function(_0x22001c,_0x43dfe5){const _0x2b2c18=a128_0x1e0c,_0x2b26af=_0x22001c();while(!![]){try{const _0x19df1b=-parseInt(_0x2b2c18(0x1c4))/0x1+parseInt(_0x2b2c18(0x1cc))/0x2*(parseInt(_0x2b2c18(0x1cf))/0x3)+-parseInt(_0x2b2c18(0x1c8))/0x4*(-parseInt(_0x2b2c18(0x1cb))/0x5)+-parseInt(_0x2b2c18(0x1c9))/0x6*(parseInt(_0x2b2c18(0x1c3))/0x7)+-parseInt(_0x2b2c18(0x1c6))/0x8*(-parseInt(_0x2b2c18(0x1c7))/0x9)+parseInt(_0x2b2c18(0x1c5))/0xa+-parseInt(_0x2b2c18(0x1ca))/0xb;if(_0x19df1b===_0x43dfe5)break;else _0x2b26af['push'](_0x2b26af['shift']());}catch(_0x2b96af){_0x2b26af['push'](_0x2b26af['shift']());}}}(a128_0x432b,0xa66e0));function a128_0x432b(){const _0x5b1bd1=['88LpPqTq','.cmd','win32','74427rEbnFI','platform','7lodPYG','844169dgMCPr','9863490WBnmZY','440GKapbF','32013OxxNWi','2741368QUMtjA','5626914KtYbvw','5447618uglMAd','5bmhKom'];a128_0x432b=function(){return _0x5b1bd1;};return a128_0x432b();}export const isWindows=process[a128_0x251f8f(0x1d0)]===a128_0x251f8f(0x1ce);function a128_0x1e0c(_0x276e84,_0x2a4317){_0x276e84=_0x276e84-0x1c3;const _0x432bf9=a128_0x432b();let _0x1e0cbe=_0x432bf9[_0x276e84];return _0x1e0cbe;}export function resolveNpmBin(_0x187edc){const _0x26285c=a128_0x251f8f;return isWindows?_0x187edc+_0x26285c(0x1cd):_0x187edc;}