@lovrabet/lovrabet-cli 2.3.1-beta.3 → 2.3.1-beta.4

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 (175) 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/init.js +1 -1
  25. package/lib/commands/config/shared.js +1 -1
  26. package/lib/commands/data/index.js +1 -1
  27. package/lib/commands/dataset/detail.js +1 -1
  28. package/lib/commands/dataset/index.js +1 -1
  29. package/lib/commands/dataset/list.js +1 -1
  30. package/lib/commands/dataset/sdk-doc.js +1 -1
  31. package/lib/commands/doctor.js +1 -1
  32. package/lib/commands/file/index.js +1 -1
  33. package/lib/commands/init.js +1 -1
  34. package/lib/commands/kb/index.js +1 -1
  35. package/lib/commands/logs/index.js +1 -1
  36. package/lib/commands/notification/config-list.js +1 -1
  37. package/lib/commands/notification/index.js +1 -1
  38. package/lib/commands/notification/shared.js +1 -1
  39. package/lib/commands/ocr/index.js +1 -1
  40. package/lib/commands/permit/dataset-get.js +1 -1
  41. package/lib/commands/permit/dataset-set.js +1 -1
  42. package/lib/commands/permit/index.js +1 -1
  43. package/lib/commands/permit/page-get.js +1 -1
  44. package/lib/commands/permit/page-set.js +1 -1
  45. package/lib/commands/permit/role-menus-set.js +1 -1
  46. package/lib/commands/permit/role-menus.js +1 -1
  47. package/lib/commands/permit/shared.js +1 -1
  48. package/lib/commands/personal-bff/index.js +1 -1
  49. package/lib/commands/registry.js +1 -1
  50. package/lib/commands/role/create.js +1 -1
  51. package/lib/commands/role/delete.js +1 -1
  52. package/lib/commands/role/detail.js +1 -1
  53. package/lib/commands/role/index.js +1 -1
  54. package/lib/commands/role/list.js +1 -1
  55. package/lib/commands/role/shared.js +1 -1
  56. package/lib/commands/role/update.js +1 -1
  57. package/lib/commands/role/user-add.js +1 -1
  58. package/lib/commands/role/user-remove.js +1 -1
  59. package/lib/commands/schedule/index.js +1 -1
  60. package/lib/commands/schema.js +1 -1
  61. package/lib/commands/service/dynamic.js +1 -1
  62. package/lib/commands/service/function-name-adapter.js +1 -1
  63. package/lib/commands/service/index.js +1 -1
  64. package/lib/commands/service/registry.js +1 -1
  65. package/lib/commands/skill/commands/create.js +1 -1
  66. package/lib/commands/skill/commands/diagram.js +1 -1
  67. package/lib/commands/skill/commands/install.js +1 -1
  68. package/lib/commands/skill/commands/list.js +1 -1
  69. package/lib/commands/skill/commands/push.js +1 -1
  70. package/lib/commands/skill/commands/validate.js +1 -1
  71. package/lib/commands/skill/diagram.js +1 -1
  72. package/lib/commands/skill/flags.js +1 -1
  73. package/lib/commands/skill/index.js +1 -1
  74. package/lib/commands/skill/manifest-helpers.js +1 -1
  75. package/lib/commands/skill/push-execute.js +1 -1
  76. package/lib/commands/skill/push-flow-helpers.js +1 -1
  77. package/lib/commands/skill/push-retarget.js +1 -1
  78. package/lib/commands/skill/scopes.js +1 -1
  79. package/lib/commands/skill/summary.js +1 -1
  80. package/lib/commands/skill/templates.js +1 -1
  81. package/lib/commands/skill/validate.js +1 -1
  82. package/lib/commands/sql/detail.js +1 -1
  83. package/lib/commands/sql/exec.js +1 -1
  84. package/lib/commands/sql/index.js +1 -1
  85. package/lib/commands/update.js +1 -1
  86. package/lib/commands/user-account/bind.js +1 -1
  87. package/lib/commands/user-account/index.js +1 -1
  88. package/lib/commands/workspace/index.js +1 -1
  89. package/lib/config/domain-config.js +1 -1
  90. package/lib/config/schema.js +1 -1
  91. package/lib/constant/app.js +1 -1
  92. package/lib/constant/auth-mode.js +1 -1
  93. package/lib/constant/cli.js +1 -1
  94. package/lib/constant/defaults.js +1 -1
  95. package/lib/constant/distribution.js +1 -1
  96. package/lib/constant/domain.d.ts +3 -3
  97. package/lib/constant/domain.js +1 -1
  98. package/lib/constant/env.js +1 -1
  99. package/lib/constant/output.js +1 -1
  100. package/lib/constant/product.js +1 -1
  101. package/lib/constant/region.js +1 -1
  102. package/lib/constant/risk.js +1 -1
  103. package/lib/constant/url.js +1 -1
  104. package/lib/context.js +1 -1
  105. package/lib/core/api-client.d.ts +0 -16
  106. package/lib/core/api-client.js +1 -1
  107. package/lib/core/db-resolver.js +1 -1
  108. package/lib/core/kb-search-client.d.ts +30 -0
  109. package/lib/core/kb-search-client.js +1 -0
  110. package/lib/core/sdk-client.js +1 -1
  111. package/lib/errors.js +1 -1
  112. package/lib/framework/build-all-flags.js +1 -1
  113. package/lib/framework/dryrun.js +1 -1
  114. package/lib/framework/flags.js +1 -1
  115. package/lib/framework/help.js +1 -1
  116. package/lib/framework/index.js +1 -1
  117. package/lib/framework/output.js +1 -1
  118. package/lib/framework/preparse.js +1 -1
  119. package/lib/framework/rate-limit.js +1 -1
  120. package/lib/framework/raw-flags.js +1 -1
  121. package/lib/framework/response.js +1 -1
  122. package/lib/framework/runner-confirmation.js +1 -1
  123. package/lib/framework/runner-error.js +1 -1
  124. package/lib/framework/runner.js +1 -1
  125. package/lib/framework/schema-export.js +1 -1
  126. package/lib/framework/service-order.js +1 -1
  127. package/lib/framework/types.d.ts +2 -0
  128. package/lib/framework/types.js +1 -1
  129. package/lib/generated/build-info.d.ts +4 -4
  130. package/lib/generated/build-info.js +1 -1
  131. package/lib/generated/official-routing.js +1 -1
  132. package/lib/generated/routing-contract.js +1 -1
  133. package/lib/help.js +1 -1
  134. package/lib/postinstall.js +1 -1
  135. package/lib/runtime/confirmation.js +1 -1
  136. package/lib/runtime/event.js +1 -1
  137. package/lib/runtime/index.js +1 -1
  138. package/lib/runtime/queue.js +1 -1
  139. package/lib/runtime/resolve.js +1 -1
  140. package/lib/skills/builtin-skill.js +1 -1
  141. package/lib/skills/npx-skills-add.js +1 -1
  142. package/lib/skills/runtime-skill-sync/constants.js +1 -1
  143. package/lib/skills/runtime-skill-sync/fs-utils.js +1 -1
  144. package/lib/skills/runtime-skill-sync/hashing.js +1 -1
  145. package/lib/skills/runtime-skill-sync/install-target.js +1 -1
  146. package/lib/skills/runtime-skill-sync/links.js +1 -1
  147. package/lib/skills/runtime-skill-sync/list-local.js +1 -1
  148. package/lib/skills/runtime-skill-sync/local-files.js +1 -1
  149. package/lib/skills/runtime-skill-sync/materialize.js +1 -1
  150. package/lib/skills/runtime-skill-sync/metadata.js +1 -1
  151. package/lib/skills/runtime-skill-sync/paths.js +1 -1
  152. package/lib/skills/runtime-skill-sync/push.js +1 -1
  153. package/lib/skills/runtime-skill-sync/scopes.js +1 -1
  154. package/lib/skills/runtime-skill-sync/zip-codec.js +1 -1
  155. package/lib/skills/runtime-skill-sync/zip-package.js +1 -1
  156. package/lib/skills/runtime-skill-sync.js +1 -1
  157. package/lib/skills/skill-presence.js +1 -1
  158. package/lib/utils/access-key-redaction.js +1 -1
  159. package/lib/utils/apply-jq-filter.js +1 -1
  160. package/lib/utils/cli-version-check.js +1 -1
  161. package/lib/utils/cli-version-policy.js +1 -1
  162. package/lib/utils/logger.js +1 -1
  163. package/lib/utils/lossless-json.js +1 -1
  164. package/lib/utils/params.js +1 -1
  165. package/lib/utils/platform.js +1 -1
  166. package/lib/utils/update-notice.js +1 -1
  167. package/lib/utils/version.js +1 -1
  168. package/lib/utils/write-cli-side-channel.js +1 -1
  169. package/package.json +1 -1
  170. package/skills/lovrabet/SKILL.md +2 -2
  171. package/skills/lovrabet/references/lovrabet-config-commands.md +3 -1
  172. package/skills/lovrabet/references/lovrabet-config.md +2 -2
  173. package/skills/lovrabet/references/lovrabet-doctor.md +2 -0
  174. package/skills/lovrabet/references/lovrabet-kb-workflow.md +3 -1
  175. package/skills/lovrabet.manifest.json +3 -3
@@ -1 +1 @@
1
- const a125_0x5d1bf4=a125_0x2480;(function(_0x356dbc,_0x4a96a7){const _0x4b4a05=a125_0x2480,_0x27fd2d=_0x356dbc();while(!![]){try{const _0x21f9b3=parseInt(_0x4b4a05(0xfb))/0x1+parseInt(_0x4b4a05(0xef))/0x2+-parseInt(_0x4b4a05(0xf9))/0x3+-parseInt(_0x4b4a05(0x100))/0x4+-parseInt(_0x4b4a05(0xfc))/0x5*(parseInt(_0x4b4a05(0x102))/0x6)+-parseInt(_0x4b4a05(0x104))/0x7*(-parseInt(_0x4b4a05(0xf2))/0x8)+-parseInt(_0x4b4a05(0xf6))/0x9*(parseInt(_0x4b4a05(0xed))/0xa);if(_0x21f9b3===_0x4a96a7)break;else _0x27fd2d['push'](_0x27fd2d['shift']());}catch(_0xe33694){_0x27fd2d['push'](_0x27fd2d['shift']());}}}(a125_0x16e9,0xc5f53));function a125_0x2480(_0x26b6ba,_0xb00802){_0x26b6ba=_0x26b6ba-0xed;const _0x16e91b=a125_0x16e9();let _0x248047=_0x16e91b[_0x26b6ba];return _0x248047;}export const ENTERPRISE_ROUTING_SCHEMA_DIGEST='0bc465ada0b5c1621a0dfd5441b91b5d7c69d95ef7417f07cc7afd3548593d8a';export const ENTERPRISE_ROUTING_PROTOCOL=a125_0x5d1bf4(0x103);export const ENTERPRISE_ROUTING_KIND=a125_0x5d1bf4(0xf7);export const ENTERPRISE_ROUTING_TOP_LEVEL_FIELDS=[a125_0x5d1bf4(0xf1),a125_0x5d1bf4(0x106),a125_0x5d1bf4(0xee),a125_0x5d1bf4(0xf5)];export const ENTERPRISE_ROUTING_CONSUMERS=[a125_0x5d1bf4(0xff),a125_0x5d1bf4(0xf0),a125_0x5d1bf4(0x107)];export const ENTERPRISE_ROUTING_DOMAIN_FIELDS=[a125_0x5d1bf4(0xfe),a125_0x5d1bf4(0xf8),'runtimeDomain',a125_0x5d1bf4(0xf4),a125_0x5d1bf4(0xfa),a125_0x5d1bf4(0xf3),a125_0x5d1bf4(0xfd),'certificateDomain'];export const REQUIRED_ENTERPRISE_ROUTING_DOMAIN_FIELDS=[a125_0x5d1bf4(0xfe),a125_0x5d1bf4(0xf8),'runtimeDomain',a125_0x5d1bf4(0xf4),a125_0x5d1bf4(0xfa),a125_0x5d1bf4(0xf3)];export const ENTERPRISE_ROUTING_CDN_FIELDS=[a125_0x5d1bf4(0x101),a125_0x5d1bf4(0x105)];export const REQUIRED_ENTERPRISE_ROUTING_CDN_FIELDS=[a125_0x5d1bf4(0x101),'lovrabet'];function a125_0x16e9(){const _0x2a3ee6=['lovrabet-routing/v1','227759BwuUXg','lovrabet','kind','lovrabet-node-sdk','9200XKuNkR','domains','299568TiTHeS','lovrabet-cli','protocol','288YkJIvF','appDomain','skillDomain','cdn','9342OnqwzU','enterprise','apiDomain','47001rBoZaq','kbDomain','1147192YaCzOG','249670fjZyZF','localDomain','userDomain','rabetbase-cli','2547648rMHXZT','libraries','6JTKKRQ'];a125_0x16e9=function(){return _0x2a3ee6;};return a125_0x16e9();}
1
+ const a126_0x380286=a126_0x266e;(function(_0x4ee1bb,_0x575845){const _0x12f727=a126_0x266e,_0x3698a5=_0x4ee1bb();while(!![]){try{const _0x4757a6=-parseInt(_0x12f727(0x170))/0x1*(parseInt(_0x12f727(0x171))/0x2)+parseInt(_0x12f727(0x175))/0x3+parseInt(_0x12f727(0x163))/0x4*(parseInt(_0x12f727(0x166))/0x5)+parseInt(_0x12f727(0x17b))/0x6*(parseInt(_0x12f727(0x172))/0x7)+parseInt(_0x12f727(0x161))/0x8*(-parseInt(_0x12f727(0x16b))/0x9)+parseInt(_0x12f727(0x17a))/0xa+-parseInt(_0x12f727(0x16c))/0xb*(-parseInt(_0x12f727(0x178))/0xc);if(_0x4757a6===_0x575845)break;else _0x3698a5['push'](_0x3698a5['shift']());}catch(_0x4636c5){_0x3698a5['push'](_0x3698a5['shift']());}}}(a126_0x9454,0xf3c28));export const ENTERPRISE_ROUTING_SCHEMA_DIGEST=a126_0x380286(0x168);export const ENTERPRISE_ROUTING_PROTOCOL=a126_0x380286(0x167);export const ENTERPRISE_ROUTING_KIND=a126_0x380286(0x16a);export const ENTERPRISE_ROUTING_TOP_LEVEL_FIELDS=[a126_0x380286(0x162),'kind',a126_0x380286(0x160),'cdn'];function a126_0x266e(_0x50d9bc,_0x421858){_0x50d9bc=_0x50d9bc-0x160;const _0x94542e=a126_0x9454();let _0x266e7b=_0x94542e[_0x50d9bc];return _0x266e7b;}function a126_0x9454(){const _0x53eb9d=['enterprise','18UzJMst','33HcxWGO','apiDomain','appDomain','kbDomain','1478VwauDa','772TEAyTb','368662vhYRZG','libraries','lovrabet-cli','371928KUAhfO','rabetbase-cli','lovrabet-node-sdk','3964956mxAldp','runtimeDomain','7240680ShnFXR','84ztYLNl','domains','7029184MfdfSr','protocol','18396mNpVrP','certificateDomain','lovrabet','815QgNplG','lovrabet-routing/v1','0bc465ada0b5c1621a0dfd5441b91b5d7c69d95ef7417f07cc7afd3548593d8a','localDomain'];a126_0x9454=function(){return _0x53eb9d;};return a126_0x9454();}export const ENTERPRISE_ROUTING_CONSUMERS=[a126_0x380286(0x176),a126_0x380286(0x174),a126_0x380286(0x177)];export const ENTERPRISE_ROUTING_DOMAIN_FIELDS=['userDomain',a126_0x380286(0x16d),a126_0x380286(0x179),'skillDomain',a126_0x380286(0x16f),a126_0x380286(0x16e),a126_0x380286(0x169),a126_0x380286(0x164)];export const REQUIRED_ENTERPRISE_ROUTING_DOMAIN_FIELDS=['userDomain',a126_0x380286(0x16d),'runtimeDomain','skillDomain',a126_0x380286(0x16f),a126_0x380286(0x16e)];export const ENTERPRISE_ROUTING_CDN_FIELDS=[a126_0x380286(0x173),'lovrabet'];export const REQUIRED_ENTERPRISE_ROUTING_CDN_FIELDS=[a126_0x380286(0x173),a126_0x380286(0x165)];
package/lib/help.js CHANGED
@@ -1 +1 @@
1
- (function(_0x7dca32,_0x5b0af3){const _0x316169=a126_0x44ec,_0x26358e=_0x7dca32();while(!![]){try{const _0x467a42=parseInt(_0x316169(0x1b6))/0x1+parseInt(_0x316169(0x1a8))/0x2*(parseInt(_0x316169(0x1a9))/0x3)+parseInt(_0x316169(0x1b0))/0x4*(-parseInt(_0x316169(0x1b1))/0x5)+-parseInt(_0x316169(0x1b3))/0x6+-parseInt(_0x316169(0x1ac))/0x7+-parseInt(_0x316169(0x1b4))/0x8*(parseInt(_0x316169(0x1aa))/0x9)+parseInt(_0x316169(0x1af))/0xa*(parseInt(_0x316169(0x1ae))/0xb);if(_0x467a42===_0x5b0af3)break;else _0x26358e['push'](_0x26358e['shift']());}catch(_0x26f9c4){_0x26358e['push'](_0x26358e['shift']());}}}(a126_0x2a5c,0x2ba27));function a126_0x44ec(_0x5af3f0,_0x80d911){_0x5af3f0=_0x5af3f0-0x1a8;const _0x2a5ce2=a126_0x2a5c();let _0x44ec05=_0x2a5ce2[_0x5af3f0];return _0x44ec05;}import{jsx as a126_0x50a58c,jsxs as a126_0x4a529a}from'react/jsx-runtime';import{useEffect}from'react';import{Box,Text,useApp}from'ink';function a126_0x2a5c(){const _0x534269=['26020sDqxnT','628kLuSri','8585IdgwfY','\x20--help','1079892EToreW','448832MsqNoY','green','56474gadoUd','column','316URLAwD','81sBqVSJ','54FLBxNH','\x20\x20Use\x20','155050NIZCEW','\x20to\x20view\x20available\x20commands.','3916dzqIVz'];a126_0x2a5c=function(){return _0x534269;};return a126_0x2a5c();}import{CLI_BIN_NAME,CLI_DISPLAY_NAME}from'./constant/cli.js';export function Help(){const _0x2cf4f8=a126_0x44ec,{exit:_0x1fe080}=useApp();return useEffect(()=>{_0x1fe080();},[_0x1fe080]),a126_0x4a529a(Box,{'flexDirection':_0x2cf4f8(0x1b7),'marginTop':0x1,'marginBottom':0x1,'children':[a126_0x50a58c(Box,{'children':a126_0x50a58c(Text,{'bold':!![],'color':_0x2cf4f8(0x1b5),'children':'\x20\x20'+CLI_DISPLAY_NAME})}),a126_0x4a529a(Box,{'marginTop':0x1,'children':[a126_0x50a58c(Text,{'dimColor':!![],'children':_0x2cf4f8(0x1ab)}),a126_0x50a58c(Text,{'bold':!![],'color':_0x2cf4f8(0x1b5),'children':CLI_BIN_NAME+_0x2cf4f8(0x1b2)}),a126_0x50a58c(Text,{'dimColor':!![],'children':_0x2cf4f8(0x1ad)})]})]});}
1
+ (function(_0x12f56d,_0x386a72){const _0x45d6c9=a127_0x2a0c,_0x1a452e=_0x12f56d();while(!![]){try{const _0x311502=parseInt(_0x45d6c9(0x15d))/0x1+parseInt(_0x45d6c9(0x15e))/0x2+parseInt(_0x45d6c9(0x160))/0x3*(parseInt(_0x45d6c9(0x15b))/0x4)+parseInt(_0x45d6c9(0x162))/0x5*(parseInt(_0x45d6c9(0x165))/0x6)+parseInt(_0x45d6c9(0x161))/0x7*(-parseInt(_0x45d6c9(0x15c))/0x8)+parseInt(_0x45d6c9(0x15f))/0x9+-parseInt(_0x45d6c9(0x163))/0xa;if(_0x311502===_0x386a72)break;else _0x1a452e['push'](_0x1a452e['shift']());}catch(_0x59ddc6){_0x1a452e['push'](_0x1a452e['shift']());}}}(a127_0x5f28,0xb6efd));import{jsx as a127_0x2a9438,jsxs as a127_0x15783d}from'react/jsx-runtime';import{useEffect}from'react';function a127_0x2a0c(_0x1c0760,_0x3d3a62){_0x1c0760=_0x1c0760-0x15a;const _0x5f284f=a127_0x5f28();let _0x2a0c1d=_0x5f284f[_0x1c0760];return _0x2a0c1d;}import{Box,Text,useApp}from'ink';import{CLI_BIN_NAME,CLI_DISPLAY_NAME}from'./constant/cli.js';function a127_0x5f28(){const _0x223de1=['green','2942046YQuyAU','\x20\x20Use\x20','13428NbolAC','203136ghTYdx','1046552WMrHkE','2360906cYfNch','4541751pXONct','678ReBmEL','14PreFjS','15CRiWqC','41612560lsSHRS'];a127_0x5f28=function(){return _0x223de1;};return a127_0x5f28();}export function Help(){const _0x1dc9c7=a127_0x2a0c,{exit:_0x2f84ec}=useApp();return useEffect(()=>{_0x2f84ec();},[_0x2f84ec]),a127_0x15783d(Box,{'flexDirection':'column','marginTop':0x1,'marginBottom':0x1,'children':[a127_0x2a9438(Box,{'children':a127_0x2a9438(Text,{'bold':!![],'color':_0x1dc9c7(0x164),'children':'\x20\x20'+CLI_DISPLAY_NAME})}),a127_0x15783d(Box,{'marginTop':0x1,'children':[a127_0x2a9438(Text,{'dimColor':!![],'children':_0x1dc9c7(0x15a)}),a127_0x2a9438(Text,{'bold':!![],'color':_0x1dc9c7(0x164),'children':CLI_BIN_NAME+'\x20--help'}),a127_0x2a9438(Text,{'dimColor':!![],'children':'\x20to\x20view\x20available\x20commands.'})]})]});}
@@ -1 +1 @@
1
- function a127_0x10a8(_0x16da2e,_0x4a6a5d){_0x16da2e=_0x16da2e-0x1ce;const _0x2a95a4=a127_0x2a95();let _0x10a8bf=_0x2a95a4[_0x16da2e];return _0x10a8bf;}(function(_0x15080e,_0x55d325){const _0x555245=a127_0x10a8,_0x416424=_0x15080e();while(!![]){try{const _0xab934d=-parseInt(_0x555245(0x1db))/0x1*(parseInt(_0x555245(0x1d3))/0x2)+-parseInt(_0x555245(0x1d9))/0x3+parseInt(_0x555245(0x1e4))/0x4*(-parseInt(_0x555245(0x1e3))/0x5)+parseInt(_0x555245(0x1d7))/0x6*(-parseInt(_0x555245(0x1e1))/0x7)+-parseInt(_0x555245(0x1da))/0x8*(parseInt(_0x555245(0x1dc))/0x9)+parseInt(_0x555245(0x1e5))/0xa+parseInt(_0x555245(0x1d2))/0xb*(parseInt(_0x555245(0x1d4))/0xc);if(_0xab934d===_0x55d325)break;else _0x416424['push'](_0x416424['shift']());}catch(_0x3b93da){_0x416424['push'](_0x416424['shift']());}}}(a127_0x2a95,0xa8ad3));import{installBuiltinSkill}from'./skills/builtin-skill.js';export async function runPostinstall(_0x530be2={}){const _0x1ca130=a127_0x10a8,_0x126536=installBuiltinSkill(_0x530be2);if(_0x126536['ok']){const _0x3e6f30=_0x126536[_0x1ca130(0x1de)]?_0x1ca130(0x1ce):_0x1ca130(0x1d5),_0x3ee8dd=_0x126536[_0x1ca130(0x1e7)]?'\x20at\x20'+_0x126536['installedPath']:_0x1ca130(0x1d1);return console[_0x1ca130(0x1df)](_0x1ca130(0x1e6)+_0x126536[_0x1ca130(0x1e2)]+'\x20'+_0x3e6f30+_0x3ee8dd),_0x126536;}const _0x13fe27=_0x1ca130(0x1dd)+(_0x126536['code']??_0x1ca130(0x1e8))+']\x20'+(_0x126536[_0x1ca130(0x1cf)]??_0x1ca130(0x1d8))+'.\x20'+(_0x1ca130(0x1e0)+_0x126536['repairCommand']);if(_0x126536['code']===_0x1ca130(0x1d0))throw new Error(_0x13fe27);return console[_0x1ca130(0x1d6)](_0x13fe27),_0x126536;}function a127_0x2a95(){const _0x20b4fc=['error','SOURCE_INVALID','\x20via\x20skills@latest','253FIPvoQ','2zeBMvy','1616016Unnlnj','already\x20current','warn','42BtllCE','Installation\x20failed','2614749dktErs','48eekJcH','986386eUevBf','1119906KGVQWE','[BUILTIN_SKILL_INSTALL_','changed','log','Repair\x20with:\x20','154077CILcpI','skillVersion','77635IWpRZV','20SZQnyB','4298200QBADbV','Lovrabet\x20Built-in\x20Skill\x20','installedPath','FAILED','installed'];a127_0x2a95=function(){return _0x20b4fc;};return a127_0x2a95();}
1
+ (function(_0x366b30,_0x4dc7c1){const _0x2f7743=a128_0x3ab2,_0x1584a9=_0x366b30();while(!![]){try{const _0xc12281=parseInt(_0x2f7743(0x18a))/0x1*(parseInt(_0x2f7743(0x199))/0x2)+parseInt(_0x2f7743(0x198))/0x3+-parseInt(_0x2f7743(0x195))/0x4+-parseInt(_0x2f7743(0x18d))/0x5*(parseInt(_0x2f7743(0x19b))/0x6)+-parseInt(_0x2f7743(0x19e))/0x7*(-parseInt(_0x2f7743(0x19f))/0x8)+-parseInt(_0x2f7743(0x19c))/0x9*(-parseInt(_0x2f7743(0x191))/0xa)+parseInt(_0x2f7743(0x196))/0xb*(-parseInt(_0x2f7743(0x189))/0xc);if(_0xc12281===_0x4dc7c1)break;else _0x1584a9['push'](_0x1584a9['shift']());}catch(_0x26b5de){_0x1584a9['push'](_0x1584a9['shift']());}}}(a128_0x8340,0xe37ec));import{installBuiltinSkill}from'./skills/builtin-skill.js';export async function runPostinstall(_0x1ddada={}){const _0x52ae45=a128_0x3ab2,_0x21625f=installBuiltinSkill(_0x1ddada);if(_0x21625f['ok']){const _0x3129a1=_0x21625f[_0x52ae45(0x18f)]?'installed':_0x52ae45(0x194),_0x511474=_0x21625f[_0x52ae45(0x188)]?_0x52ae45(0x187)+_0x21625f[_0x52ae45(0x188)]:_0x52ae45(0x18c);return console[_0x52ae45(0x190)](_0x52ae45(0x1a0)+_0x21625f[_0x52ae45(0x193)]+'\x20'+_0x3129a1+_0x511474),_0x21625f;}const _0x4df030=_0x52ae45(0x197)+(_0x21625f[_0x52ae45(0x19d)]??_0x52ae45(0x18e))+']\x20'+(_0x21625f[_0x52ae45(0x192)]??_0x52ae45(0x18b))+'.\x20'+(_0x52ae45(0x19a)+_0x21625f['repairCommand']);if(_0x21625f[_0x52ae45(0x19d)]==='SOURCE_INVALID')throw new Error(_0x4df030);return console['warn'](_0x4df030),_0x21625f;}function a128_0x3ab2(_0x8eb282,_0x583f40){_0x8eb282=_0x8eb282-0x187;const _0x83405f=a128_0x8340();let _0x3ab243=_0x83405f[_0x8eb282];return _0x3ab243;}function a128_0x8340(){const _0x4717ce=['1841QxRaCH','53744vKjlkd','Lovrabet\x20Built-in\x20Skill\x20','\x20at\x20','installedPath','12dMWbDr','244553wUHVMA','Installation\x20failed','\x20via\x20skills@latest','365EhvrMZ','FAILED','changed','log','9568810quuPJE','error','skillVersion','already\x20current','5536724eFQwpF','7630645TjZIgm','[BUILTIN_SKILL_INSTALL_','1290861KLuUNN','10DZwfYH','Repair\x20with:\x20','112362EAUaLa','9THghNw','code'];a128_0x8340=function(){return _0x4717ce;};return a128_0x8340();}
@@ -1 +1 @@
1
- function a128_0x2b9c(_0x3869aa,_0x43300b){_0x3869aa=_0x3869aa-0xb8;const _0x415352=a128_0x4153();let _0x2b9c19=_0x415352[_0x3869aa];return _0x2b9c19;}(function(_0x1fd99b,_0x23ee00){const _0x1e64d4=a128_0x2b9c,_0x8a5121=_0x1fd99b();while(!![]){try{const _0x339880=parseInt(_0x1e64d4(0xb8))/0x1*(parseInt(_0x1e64d4(0xc3))/0x2)+-parseInt(_0x1e64d4(0xba))/0x3+-parseInt(_0x1e64d4(0xc0))/0x4*(parseInt(_0x1e64d4(0xc7))/0x5)+-parseInt(_0x1e64d4(0xc6))/0x6*(parseInt(_0x1e64d4(0xc4))/0x7)+-parseInt(_0x1e64d4(0xbe))/0x8*(parseInt(_0x1e64d4(0xc9))/0x9)+parseInt(_0x1e64d4(0xc8))/0xa+-parseInt(_0x1e64d4(0xbc))/0xb*(-parseInt(_0x1e64d4(0xc2))/0xc);if(_0x339880===_0x23ee00)break;else _0x8a5121['push'](_0x8a5121['shift']());}catch(_0x12ae75){_0x8a5121['push'](_0x8a5121['shift']());}}}(a128_0x4153,0x286dd));const DESCRIPTION_MAX_LENGTH=0x1f4;export function buildLovrabetConfirmationRequest(_0xa306ae,_0xc89953,_0x12e592){const _0x342b5f=a128_0x2b9c,_0x19afef=normalizeText(_0xa306ae[_0x342b5f(0xbd)],DESCRIPTION_MAX_LENGTH),_0x4888fb=normalizeText(_0xa306ae['description'],DESCRIPTION_MAX_LENGTH);return{'operation':_0xc89953,'risk':requireWriteRisk(_0xa306ae),'description':_0x19afef||_0x4888fb||_0x342b5f(0xbf),..._0x12e592?{'signal':_0x12e592}:{}};}function requireWriteRisk(_0x46a936){const _0xb3f9fa=a128_0x2b9c;if(_0x46a936[_0xb3f9fa(0xbb)]===_0xb3f9fa(0xc1)||_0x46a936[_0xb3f9fa(0xbb)]==='high-risk-write')return _0x46a936[_0xb3f9fa(0xbb)];throw new Error('Lovrabet\x20confirmation\x20requires\x20a\x20write\x20command.');}function a128_0x4153(){const _0x50373f=['22685EbFRLP','3032810zKduQc','18018bdoqwc','4gRJkei','replace','694056eaLtDB','risk','13464FADdtD','confirmationDescription','8IpSiTJ','Run\x20this\x20write\x20operation','76KNWPAd','write','1968dSyAqW','59068SCmeBR','958993XfgOMU','trim','6YKpnEK'];a128_0x4153=function(){return _0x50373f;};return a128_0x4153();}function normalizeText(_0x3281a2,_0x2dfa3d){const _0x557282=a128_0x2b9c;if(typeof _0x3281a2!=='string')return'';return _0x3281a2['replace'](/[\u0000-\u001f\u007f]+/g,'\x20')[_0x557282(0xb9)](/\s+/g,'\x20')[_0x557282(0xc5)]()['slice'](0x0,_0x2dfa3d);}
1
+ function a129_0x3d0f(){const _0x30ba33=['write','high-risk-write','1397212wtTySZ','description','string','slice','risk','7275688pdxBvT','1477716gPslCz','117926GRfinN','24709333DhnmRw','3MdNdio','16DJZeMD','6344450GTZsKA','Lovrabet\x20confirmation\x20requires\x20a\x20write\x20command.','confirmationDescription','7QMRPko','10wBUQQa','trim','5213133ZeJcUQ'];a129_0x3d0f=function(){return _0x30ba33;};return a129_0x3d0f();}function a129_0x3537(_0x529ae6,_0x165f68){_0x529ae6=_0x529ae6-0x147;const _0x3d0f81=a129_0x3d0f();let _0x3537be=_0x3d0f81[_0x529ae6];return _0x3537be;}(function(_0x8d7470,_0x2caea8){const _0xeb4458=a129_0x3537,_0x1c1861=_0x8d7470();while(!![]){try{const _0x415025=-parseInt(_0xeb4458(0x14c))/0x1*(parseInt(_0xeb4458(0x14f))/0x2)+parseInt(_0xeb4458(0x14e))/0x3*(-parseInt(_0xeb4458(0x159))/0x4)+-parseInt(_0xeb4458(0x154))/0x5*(-parseInt(_0xeb4458(0x14b))/0x6)+parseInt(_0xeb4458(0x153))/0x7*(-parseInt(_0xeb4458(0x14a))/0x8)+parseInt(_0xeb4458(0x156))/0x9+-parseInt(_0xeb4458(0x150))/0xa+parseInt(_0xeb4458(0x14d))/0xb;if(_0x415025===_0x2caea8)break;else _0x1c1861['push'](_0x1c1861['shift']());}catch(_0xa3580e){_0x1c1861['push'](_0x1c1861['shift']());}}}(a129_0x3d0f,0x758d7));const DESCRIPTION_MAX_LENGTH=0x1f4;export function buildLovrabetConfirmationRequest(_0x5e4f10,_0x59897c,_0x4cc48e){const _0x36301b=a129_0x3537,_0x430473=normalizeText(_0x5e4f10[_0x36301b(0x152)],DESCRIPTION_MAX_LENGTH),_0x27a08d=normalizeText(_0x5e4f10[_0x36301b(0x15a)],DESCRIPTION_MAX_LENGTH);return{'operation':_0x59897c,'risk':requireWriteRisk(_0x5e4f10),'description':_0x430473||_0x27a08d||'Run\x20this\x20write\x20operation',..._0x4cc48e?{'signal':_0x4cc48e}:{}};}function requireWriteRisk(_0x61e975){const _0x56909f=a129_0x3537;if(_0x61e975[_0x56909f(0x149)]===_0x56909f(0x157)||_0x61e975[_0x56909f(0x149)]===_0x56909f(0x158))return _0x61e975[_0x56909f(0x149)];throw new Error(_0x56909f(0x151));}function normalizeText(_0x487a66,_0x3abc7c){const _0x33d9ad=a129_0x3537;if(typeof _0x487a66!==_0x33d9ad(0x147))return'';return _0x487a66['replace'](/[\u0000-\u001f\u007f]+/g,'\x20')['replace'](/\s+/g,'\x20')[_0x33d9ad(0x155)]()[_0x33d9ad(0x148)](0x0,_0x3abc7c);}
@@ -1 +1 @@
1
- (function(_0xf83c44,_0x15e327){const _0x4bedbd=a129_0x2b11,_0x4bf40b=_0xf83c44();while(!![]){try{const _0x3bcdde=-parseInt(_0x4bedbd(0x151))/0x1*(-parseInt(_0x4bedbd(0x154))/0x2)+parseInt(_0x4bedbd(0x15e))/0x3*(-parseInt(_0x4bedbd(0x15d))/0x4)+parseInt(_0x4bedbd(0x153))/0x5+parseInt(_0x4bedbd(0x155))/0x6+parseInt(_0x4bedbd(0x14e))/0x7+parseInt(_0x4bedbd(0x14c))/0x8+parseInt(_0x4bedbd(0x15c))/0x9*(-parseInt(_0x4bedbd(0x15a))/0xa);if(_0x3bcdde===_0x15e327)break;else _0x4bf40b['push'](_0x4bf40b['shift']());}catch(_0x39f9d6){_0x4bf40b['push'](_0x4bf40b['shift']());}}}(a129_0x2f8c,0x8c447));function a129_0x2b11(_0x1cd317,_0x2004fa){_0x1cd317=_0x1cd317-0x14c;const _0x2f8cf4=a129_0x2f8c();let _0x2b115e=_0x2f8cf4[_0x1cd317];return _0x2b115e;}export function canonicalLovrabetOperation(_0x3f9f24){const _0x404a81=a129_0x2b11;return[_0x3f9f24[_0x404a81(0x152)],..._0x3f9f24[_0x404a81(0x150)][_0x404a81(0x156)]()[_0x404a81(0x158)](/\s+/)][_0x404a81(0x157)](Boolean)['join']('.');}export function createLovrabetWriteMetadata(_0x24505a,_0xe4b349,_0x26482a,_0x5d3f30){const _0x485e0b=a129_0x2b11;if(_0x5d3f30||_0x26482a['ok']!==!![]||_0x24505a['risk']!==_0x485e0b(0x15b)&&_0x24505a[_0x485e0b(0x14f)]!=='high-risk-write')return undefined;const _0x9ac24d=_0x24505a[_0x485e0b(0x14d)]?.(_0x26482a),_0x223c6d={'type':_0x485e0b(0x159),'operation':_0xe4b349,'risk':_0x24505a[_0x485e0b(0x14f)],..._0x9ac24d?{'subject':_0x9ac24d}:{}};return{'lovrabet':{'schemaVersion':0x1,'event':_0x223c6d}};}function a129_0x2f8c(){const _0x1fcb25=['1388970nHpPyM','728830KghVJt','5936490nIalyI','trim','filter','split','lovrabet.write.completed','190ShxFke','write','1036053lYYnda','472IvrGzs','4878uaOYcE','3892128cIlvpQ','writeEventSubject','5848402XGQxMu','risk','command','1ixoSij','service'];a129_0x2f8c=function(){return _0x1fcb25;};return a129_0x2f8c();}
1
+ (function(_0x517aa4,_0x21400a){const _0x30431d=a130_0x30db,_0xaa1c4d=_0x517aa4();while(!![]){try{const _0x1de19a=parseInt(_0x30431d(0x7b))/0x1*(parseInt(_0x30431d(0x71))/0x2)+parseInt(_0x30431d(0x6d))/0x3*(-parseInt(_0x30431d(0x77))/0x4)+-parseInt(_0x30431d(0x78))/0x5+parseInt(_0x30431d(0x73))/0x6+-parseInt(_0x30431d(0x79))/0x7*(parseInt(_0x30431d(0x7c))/0x8)+-parseInt(_0x30431d(0x74))/0x9+-parseInt(_0x30431d(0x6e))/0xa*(-parseInt(_0x30431d(0x7a))/0xb);if(_0x1de19a===_0x21400a)break;else _0xaa1c4d['push'](_0xaa1c4d['shift']());}catch(_0x213669){_0xaa1c4d['push'](_0xaa1c4d['shift']());}}}(a130_0x1d3d,0x978de));export function canonicalLovrabetOperation(_0x11f6b2){const _0x450c4b=a130_0x30db;return[_0x11f6b2['service'],..._0x11f6b2[_0x450c4b(0x7d)]['trim']()['split'](/\s+/)]['filter'](Boolean)[_0x450c4b(0x76)]('.');}function a130_0x30db(_0x51a483,_0x2d09e3){_0x51a483=_0x51a483-0x6d;const _0x1d3da8=a130_0x1d3d();let _0x30db3d=_0x1d3da8[_0x51a483];return _0x30db3d;}function a130_0x1d3d(){const _0x2066bc=['lovrabet.write.completed','2sllylH','high-risk-write','2409300nQpAmH','9982071WiPdve','risk','join','743740OAqRCu','5511235QJYXWL','8619842vkglsN','2981gDJDTG','258073AzqATD','8LimPWK','command','12ZcgNPN','153050HMgDnt','writeEventSubject'];a130_0x1d3d=function(){return _0x2066bc;};return a130_0x1d3d();}export function createLovrabetWriteMetadata(_0x4c1862,_0x4a1e95,_0x4f08b3,_0x37bb42){const _0x2a00b0=a130_0x30db;if(_0x37bb42||_0x4f08b3['ok']!==!![]||_0x4c1862[_0x2a00b0(0x75)]!=='write'&&_0x4c1862[_0x2a00b0(0x75)]!==_0x2a00b0(0x72))return undefined;const _0x2bcab3=_0x4c1862[_0x2a00b0(0x6f)]?.(_0x4f08b3),_0x1ef75c={'type':_0x2a00b0(0x70),'operation':_0x4a1e95,'risk':_0x4c1862[_0x2a00b0(0x75)],..._0x2bcab3?{'subject':_0x2bcab3}:{}};return{'lovrabet':{'schemaVersion':0x1,'event':_0x1ef75c}};}
@@ -1 +1 @@
1
- (function(_0xb52a7b,_0x1ebe18){const _0x1ffee7=a130_0x306d,_0xa8a7aa=_0xb52a7b();while(!![]){try{const _0x46506b=parseInt(_0x1ffee7(0x1c7))/0x1*(parseInt(_0x1ffee7(0x1b1))/0x2)+-parseInt(_0x1ffee7(0x1ae))/0x3*(parseInt(_0x1ffee7(0x1c2))/0x4)+parseInt(_0x1ffee7(0x1b0))/0x5*(-parseInt(_0x1ffee7(0x1ad))/0x6)+-parseInt(_0x1ffee7(0x1ac))/0x7*(-parseInt(_0x1ffee7(0x1b5))/0x8)+parseInt(_0x1ffee7(0x1a8))/0x9*(parseInt(_0x1ffee7(0x1a5))/0xa)+-parseInt(_0x1ffee7(0x1b2))/0xb*(-parseInt(_0x1ffee7(0x1b9))/0xc)+parseInt(_0x1ffee7(0x1b7))/0xd*(parseInt(_0x1ffee7(0x1c5))/0xe);if(_0x46506b===_0x1ebe18)break;else _0xa8a7aa['push'](_0xa8a7aa['shift']());}catch(_0x2faa83){_0xa8a7aa['push'](_0xa8a7aa['shift']());}}}(a130_0xb424,0x1c0ad));import{buildConfigFromFlags,initGlobalEnvironment}from'../context.js';import{createLovrabetRunnerAdapter,createPipelineEnv,finalizeLovrabetRuntimeState,runCommand}from'../framework/runner.js';import{canonicalLovrabetOperation,createLovrabetWriteMetadata}from'../runtime/event.js';function a130_0xb424(){const _0x4ed777=['present','5ZQlqUy','2opsnGY','11FawSNM','dryRun','data','16rKZUpw','presentation','3679JIFcMd','dry-run','330972ycyyqM','result','confirmation','high-risk-write','format','AbortError','rawFlags','signal','Lovrabet\x20invocation\x20aborted.','296dnMxfn','risk','riskLevel','3906EVBKwJ','confirm','199195LwPKZI','yes','10ecxcyv','args','stringify','571203CGEBzX','definition','isNonInteractive','command','99071MARxTc','1211466kOxSMk','3273bOumRr'];a130_0xb424=function(){return _0x4ed777;};return a130_0xb424();}import{buildLovrabetConfirmationRequest}from'../runtime/confirmation.js';function a130_0x306d(_0x14beb2,_0x62421f){_0x14beb2=_0x14beb2-0x1a5;const _0xb424aa=a130_0xb424();let _0x306df8=_0xb424aa[_0x14beb2];return _0x306df8;}import{resolveLovrabetInvocation}from'../runtime/resolve.js';import{runSerialized}from'../runtime/queue.js';const defaultPresentation={'present'({result:_0x55a7a7,command:_0x4da225,risk:_0x5e367e,dryRun:_0x553f9c}){const _0x10d085=a130_0x306d;return JSON[_0x10d085(0x1a7)]({'ok':_0x55a7a7['ok'],'command':_0x4da225,'risk':_0x5e367e,..._0x553f9c?{'dryRun':!![]}:{},..._0x55a7a7[_0x10d085(0x1b4)]!==undefined?{'data':_0x55a7a7[_0x10d085(0x1b4)]}:{},..._0x55a7a7['message']?{'message':_0x55a7a7['message']}:{}});}};export async function invokeLovrabet(_0x51ff87,_0x354f51){const _0x593cd9=a130_0x306d;throwIfAborted(_0x354f51[_0x593cd9(0x1c0)]);const _0x122b06=await resolveLovrabetInvocation(_0x51ff87),_0x1796f8=canonicalLovrabetOperation(_0x122b06[_0x593cd9(0x1a9)]);return await confirmWriteBeforeQueue(_0x122b06['definition'],_0x122b06['rawFlags'],_0x1796f8,_0x354f51),runSerialized(async()=>{const _0x26e805=_0x593cd9;throwIfAborted(_0x354f51[_0x26e805(0x1c0)]);const _0x20bbe8={},_0x114117=buildConfigFromFlags(_0x122b06[_0x26e805(0x1bf)]);await initGlobalEnvironment(_0x114117);const _0xd115a=createPipelineEnv(_0x114117,{..._0x122b06['rawFlags'],'yes':_0x122b06[_0x26e805(0x1a9)][_0x26e805(0x1c3)]===_0x26e805(0x1bc)?!![]:_0x122b06[_0x26e805(0x1bf)][_0x26e805(0x1c8)],'nonInteractive':!![]});_0xd115a[_0x26e805(0x1a6)]=_0x122b06['args'],_0xd115a[_0x26e805(0x1aa)]=!![],_0xd115a[_0x26e805(0x1c4)]=_0x26e805(0x1bc);const _0x59a467=withAbortSignal(_0x122b06[_0x26e805(0x1a9)],_0x354f51[_0x26e805(0x1c0)]),_0x2a1a33=createLovrabetRunnerAdapter({'formatOutput'(_0x1994ec,_0x59c12d){const _0x18d837=_0x26e805;_0x20bbe8['result']=_0x1994ec,_0x20bbe8[_0x18d837(0x1ab)]=_0x59c12d[_0x18d837(0x1ab)],_0x20bbe8['risk']=_0x59c12d['risk'],_0x20bbe8['format']=_0x59c12d[_0x18d837(0x1bd)],_0x20bbe8['dryRun']=_0x59c12d[_0x18d837(0x1b3)]===!![];},async 'confirmHighRisk'(){throw new Error('Embedded\x20Lovrabet\x20confirmation\x20must\x20run\x20inside\x20execute.');}});try{await runCommand(_0x59a467,_0xd115a,_0x2a1a33);if(!_0x20bbe8['result']||!_0x20bbe8['command']||!_0x20bbe8[_0x26e805(0x1c3)]||!_0x20bbe8[_0x26e805(0x1bd)])throw new Error('Lovrabet\x20invocation\x20completed\x20without\x20a\x20captured\x20command\x20result.');const _0x21cd60=_0x354f51[_0x26e805(0x1b6)]??defaultPresentation,_0x56e460=_0x20bbe8[_0x26e805(0x1b3)]===!![],_0x20c40f={'result':_0x20bbe8['result'],'command':_0x20bbe8[_0x26e805(0x1ab)],'operation':_0x1796f8,'risk':_0x20bbe8[_0x26e805(0x1c3)],'format':_0x20bbe8[_0x26e805(0x1bd)],'dryRun':_0x56e460},_0x64f550=createLovrabetWriteMetadata(_0x122b06[_0x26e805(0x1a9)],_0x1796f8,_0x20bbe8['result'],_0x56e460);let _0x45b12a;try{_0x45b12a=await _0x21cd60[_0x26e805(0x1af)](_0x20c40f);}catch(_0x340155){if(!_0x64f550||_0x21cd60===defaultPresentation)throw _0x340155;_0x45b12a=await defaultPresentation[_0x26e805(0x1af)](_0x20c40f);}return{'operation':_0x1796f8,'risk':_0x20bbe8[_0x26e805(0x1c3)],'mode':_0x56e460?_0x26e805(0x1b8):'execute','result':_0x20bbe8[_0x26e805(0x1ba)],'output':_0x45b12a,..._0x64f550?{'metadata':_0x64f550}:{}};}finally{await finalizeLovrabetRuntimeState();}});}async function confirmWriteBeforeQueue(_0xe3aab6,_0x221c85,_0x42aa98,_0x832124){const _0x42d5e5=a130_0x306d;if(_0x221c85[_0x42d5e5(0x1b3)]===!![]||_0xe3aab6['risk']!=='write'&&_0xe3aab6[_0x42d5e5(0x1c3)]!==_0x42d5e5(0x1bc))return;await _0x832124[_0x42d5e5(0x1bb)][_0x42d5e5(0x1c6)](buildLovrabetConfirmationRequest(_0xe3aab6,_0x42aa98,_0x832124[_0x42d5e5(0x1c0)]));}function withAbortSignal(_0x5d9668,_0x45638c){return{..._0x5d9668,async 'execute'(_0x4a94de){return throwIfAborted(_0x45638c),_0x5d9668['execute'](_0x4a94de);}};}function throwIfAborted(_0xd15d67){const _0x494a22=a130_0x306d;if(_0xd15d67?.['aborted'])throw _0xd15d67['reason']instanceof Error?_0xd15d67['reason']:new DOMException(_0x494a22(0x1c1),_0x494a22(0x1be));}
1
+ (function(_0x1a074f,_0x457702){const _0x2c47e2=a131_0x1145,_0x472fc4=_0x1a074f();while(!![]){try{const _0x2e9a6a=parseInt(_0x2c47e2(0x81))/0x1+-parseInt(_0x2c47e2(0x88))/0x2+-parseInt(_0x2c47e2(0x8a))/0x3*(-parseInt(_0x2c47e2(0x87))/0x4)+parseInt(_0x2c47e2(0x7a))/0x5*(-parseInt(_0x2c47e2(0x90))/0x6)+parseInt(_0x2c47e2(0x93))/0x7*(parseInt(_0x2c47e2(0x77))/0x8)+parseInt(_0x2c47e2(0x85))/0x9+-parseInt(_0x2c47e2(0x82))/0xa*(parseInt(_0x2c47e2(0x7e))/0xb);if(_0x2e9a6a===_0x457702)break;else _0x472fc4['push'](_0x472fc4['shift']());}catch(_0xf0090a){_0x472fc4['push'](_0x472fc4['shift']());}}}(a131_0x5bb1,0x3f169));import{buildConfigFromFlags,initGlobalEnvironment}from'../context.js';import{createLovrabetRunnerAdapter,createPipelineEnv,finalizeLovrabetRuntimeState,runCommand}from'../framework/runner.js';import{canonicalLovrabetOperation,createLovrabetWriteMetadata}from'../runtime/event.js';import{buildLovrabetConfirmationRequest}from'../runtime/confirmation.js';import{resolveLovrabetInvocation}from'../runtime/resolve.js';function a131_0x1145(_0x293273,_0xb13d3){_0x293273=_0x293273-0x73;const _0x5bb120=a131_0x5bb1();let _0x11451e=_0x5bb120[_0x293273];return _0x11451e;}import{runSerialized}from'../runtime/queue.js';const defaultPresentation={'present'({result:_0x16c934,command:_0x259583,risk:_0x1b884a,dryRun:_0x13be3b}){const _0x321d23=a131_0x1145;return JSON[_0x321d23(0x75)]({'ok':_0x16c934['ok'],'command':_0x259583,'risk':_0x1b884a,..._0x13be3b?{'dryRun':!![]}:{},..._0x16c934[_0x321d23(0x8f)]!==undefined?{'data':_0x16c934[_0x321d23(0x8f)]}:{},..._0x16c934[_0x321d23(0x7f)]?{'message':_0x16c934['message']}:{}});}};export async function invokeLovrabet(_0x2f82eb,_0x3e44e1){const _0x23fbef=a131_0x1145;throwIfAborted(_0x3e44e1['signal']);const _0x4d98ed=await resolveLovrabetInvocation(_0x2f82eb),_0x544a98=canonicalLovrabetOperation(_0x4d98ed[_0x23fbef(0x7c)]);return await confirmWriteBeforeQueue(_0x4d98ed[_0x23fbef(0x7c)],_0x4d98ed[_0x23fbef(0x80)],_0x544a98,_0x3e44e1),runSerialized(async()=>{const _0x3f920a=_0x23fbef;throwIfAborted(_0x3e44e1[_0x3f920a(0x95)]);const _0x50ead3={},_0x24fc8b=buildConfigFromFlags(_0x4d98ed[_0x3f920a(0x80)]);await initGlobalEnvironment(_0x24fc8b);const _0x4574a7=createPipelineEnv(_0x24fc8b,{..._0x4d98ed[_0x3f920a(0x80)],'yes':_0x4d98ed[_0x3f920a(0x7c)][_0x3f920a(0x89)]==='high-risk-write'?!![]:_0x4d98ed[_0x3f920a(0x80)][_0x3f920a(0x92)],'nonInteractive':!![]});_0x4574a7[_0x3f920a(0x91)]=_0x4d98ed[_0x3f920a(0x91)],_0x4574a7['isNonInteractive']=!![],_0x4574a7[_0x3f920a(0x83)]=_0x3f920a(0x7d);const _0x2ee68c=withAbortSignal(_0x4d98ed['definition'],_0x3e44e1[_0x3f920a(0x95)]),_0xd8919=createLovrabetRunnerAdapter({'formatOutput'(_0x30d7c1,_0xd9fb8b){const _0x4ffdd7=_0x3f920a;_0x50ead3[_0x4ffdd7(0x84)]=_0x30d7c1,_0x50ead3[_0x4ffdd7(0x78)]=_0xd9fb8b[_0x4ffdd7(0x78)],_0x50ead3['risk']=_0xd9fb8b[_0x4ffdd7(0x89)],_0x50ead3[_0x4ffdd7(0x8e)]=_0xd9fb8b[_0x4ffdd7(0x8e)],_0x50ead3[_0x4ffdd7(0x8b)]=_0xd9fb8b[_0x4ffdd7(0x8b)]===!![];},async 'confirmHighRisk'(){throw new Error('Embedded\x20Lovrabet\x20confirmation\x20must\x20run\x20inside\x20execute.');}});try{await runCommand(_0x2ee68c,_0x4574a7,_0xd8919);if(!_0x50ead3[_0x3f920a(0x84)]||!_0x50ead3['command']||!_0x50ead3[_0x3f920a(0x89)]||!_0x50ead3['format'])throw new Error(_0x3f920a(0x79));const _0x580efc=_0x3e44e1['presentation']??defaultPresentation,_0x513b58=_0x50ead3[_0x3f920a(0x8b)]===!![],_0x1838cf={'result':_0x50ead3[_0x3f920a(0x84)],'command':_0x50ead3[_0x3f920a(0x78)],'operation':_0x544a98,'risk':_0x50ead3[_0x3f920a(0x89)],'format':_0x50ead3[_0x3f920a(0x8e)],'dryRun':_0x513b58},_0x165f0c=createLovrabetWriteMetadata(_0x4d98ed[_0x3f920a(0x7c)],_0x544a98,_0x50ead3[_0x3f920a(0x84)],_0x513b58);let _0x45612c;try{_0x45612c=await _0x580efc['present'](_0x1838cf);}catch(_0x540df1){if(!_0x165f0c||_0x580efc===defaultPresentation)throw _0x540df1;_0x45612c=await defaultPresentation[_0x3f920a(0x76)](_0x1838cf);}return{'operation':_0x544a98,'risk':_0x50ead3[_0x3f920a(0x89)],'mode':_0x513b58?'dry-run':_0x3f920a(0x74),'result':_0x50ead3['result'],'output':_0x45612c,..._0x165f0c?{'metadata':_0x165f0c}:{}};}finally{await finalizeLovrabetRuntimeState();}});}async function confirmWriteBeforeQueue(_0x51f493,_0x49ac9a,_0x553cbe,_0x18b876){const _0x5c4049=a131_0x1145;if(_0x49ac9a[_0x5c4049(0x8b)]===!![]||_0x51f493['risk']!==_0x5c4049(0x86)&&_0x51f493[_0x5c4049(0x89)]!=='high-risk-write')return;await _0x18b876[_0x5c4049(0x7b)][_0x5c4049(0x73)](buildLovrabetConfirmationRequest(_0x51f493,_0x553cbe,_0x18b876['signal']));}function a131_0x5bb1(){const _0x3efc6e=['14050ZJtyAJ','confirmation','definition','high-risk-write','100309CBVxuO','message','rawFlags','180331kcVOUL','310uJBScN','riskLevel','result','1917477ivTmwj','write','4CXlNwt','719528umnkKw','risk','1039032EuvshC','dryRun','reason','aborted','format','data','174aKmYWT','args','yes','1698368MfMPXk','Lovrabet\x20invocation\x20aborted.','signal','AbortError','confirm','execute','stringify','present','8rwOwiq','command','Lovrabet\x20invocation\x20completed\x20without\x20a\x20captured\x20command\x20result.'];a131_0x5bb1=function(){return _0x3efc6e;};return a131_0x5bb1();}function withAbortSignal(_0x141963,_0x4ef6b6){return{..._0x141963,async 'execute'(_0x36078f){return throwIfAborted(_0x4ef6b6),_0x141963['execute']({..._0x36078f,'signal':_0x4ef6b6});}};}function throwIfAborted(_0x3bdf7f){const _0x5ce460=a131_0x1145;if(_0x3bdf7f?.[_0x5ce460(0x8d)])throw _0x3bdf7f[_0x5ce460(0x8c)]instanceof Error?_0x3bdf7f[_0x5ce460(0x8c)]:new DOMException(_0x5ce460(0x94),_0x5ce460(0x96));}
@@ -1 +1 @@
1
- function a131_0x2478(_0x2fffa0,_0x399aec){_0x2fffa0=_0x2fffa0-0x1b5;const _0x58e39d=a131_0x58e3();let _0x24784c=_0x58e39d[_0x2fffa0];return _0x24784c;}const a131_0x196373=a131_0x2478;function a131_0x58e3(){const _0x534094=['8HwVZSp','726iMhZwe','3132640czXwvN','8185kvcQEn','665130aysWgk','483930tXnorh','3706830wgnzYV','394hPsIwT','417FzSsBs','22fzQnXo','resolve','catch','3062672FIEGPE'];a131_0x58e3=function(){return _0x534094;};return a131_0x58e3();}(function(_0x54ea1f,_0xba2fb5){const _0x50d408=a131_0x2478,_0x4de066=_0x54ea1f();while(!![]){try{const _0xc270ab=-parseInt(_0x50d408(0x1b9))/0x1*(-parseInt(_0x50d408(0x1b8))/0x2)+parseInt(_0x50d408(0x1b5))/0x3+parseInt(_0x50d408(0x1bd))/0x4+-parseInt(_0x50d408(0x1c1))/0x5*(-parseInt(_0x50d408(0x1bf))/0x6)+-parseInt(_0x50d408(0x1c0))/0x7+parseInt(_0x50d408(0x1be))/0x8*(-parseInt(_0x50d408(0x1b7))/0x9)+-parseInt(_0x50d408(0x1b6))/0xa*(-parseInt(_0x50d408(0x1ba))/0xb);if(_0xc270ab===_0xba2fb5)break;else _0x4de066['push'](_0x4de066['shift']());}catch(_0x411b68){_0x4de066['push'](_0x4de066['shift']());}}}(a131_0x58e3,0x7b4a8));let tail=Promise[a131_0x196373(0x1bb)]();export async function runSerialized(_0x45da70){const _0x3cb410=a131_0x196373,_0x53f1ad=tail;let _0x74c6e;tail=new Promise(_0x484052=>{_0x74c6e=_0x484052;}),await _0x53f1ad[_0x3cb410(0x1bc)](()=>undefined);try{return await _0x45da70();}finally{_0x74c6e();}}
1
+ function a132_0x4285(_0x261feb,_0x4ab7d0){_0x261feb=_0x261feb-0x16c;const _0x5b40e0=a132_0x5b40();let _0x4285c7=_0x5b40e0[_0x261feb];return _0x4285c7;}(function(_0x319459,_0x168c2b){const _0x57baa7=a132_0x4285,_0x480e15=_0x319459();while(!![]){try{const _0x2770c2=parseInt(_0x57baa7(0x175))/0x1*(-parseInt(_0x57baa7(0x177))/0x2)+parseInt(_0x57baa7(0x172))/0x3+parseInt(_0x57baa7(0x170))/0x4*(-parseInt(_0x57baa7(0x16e))/0x5)+parseInt(_0x57baa7(0x173))/0x6*(-parseInt(_0x57baa7(0x171))/0x7)+parseInt(_0x57baa7(0x16d))/0x8+-parseInt(_0x57baa7(0x176))/0x9*(-parseInt(_0x57baa7(0x16f))/0xa)+parseInt(_0x57baa7(0x174))/0xb;if(_0x2770c2===_0x168c2b)break;else _0x480e15['push'](_0x480e15['shift']());}catch(_0x870f66){_0x480e15['push'](_0x480e15['shift']());}}}(a132_0x5b40,0xc55df));let tail=Promise['resolve']();export async function runSerialized(_0x5282db){const _0x38f85b=a132_0x4285,_0x1d9d1f=tail;let _0x281e74;tail=new Promise(_0x1e95b4=>{_0x281e74=_0x1e95b4;}),await _0x1d9d1f[_0x38f85b(0x16c)](()=>undefined);try{return await _0x5282db();}finally{_0x281e74();}}function a132_0x5b40(){const _0x1858b7=['9878528ayjfnk','10Meaytd','454550bQoeFO','1482848GgtyBi','7339626KcwQKr','423348kTxPho','6bGKkgt','11718223VRNyPW','161053lyrUkE','63QAUCgU','2OZfsmg','catch'];a132_0x5b40=function(){return _0x1858b7;};return a132_0x5b40();}
@@ -1 +1 @@
1
- (function(_0x307bb2,_0x4b69af){const _0x647c76=a132_0x1702,_0x5c002a=_0x307bb2();while(!![]){try{const _0x48091b=-parseInt(_0x647c76(0xa1))/0x1+parseInt(_0x647c76(0x94))/0x2+-parseInt(_0x647c76(0xa4))/0x3*(-parseInt(_0x647c76(0x9d))/0x4)+-parseInt(_0x647c76(0x95))/0x5+parseInt(_0x647c76(0x9f))/0x6+-parseInt(_0x647c76(0x9c))/0x7*(-parseInt(_0x647c76(0x91))/0x8)+parseInt(_0x647c76(0xa9))/0x9*(parseInt(_0x647c76(0x97))/0xa);if(_0x48091b===_0x4b69af)break;else _0x5c002a['push'](_0x5c002a['shift']());}catch(_0x579921){_0x5c002a['push'](_0x5c002a['shift']());}}}(a132_0x1405,0xa9855));import a132_0x35c7ef from'meow';import{findDefinition,getServiceEntry,isKnownService,resolveRemovedCommand}from'../commands/registry.js';import{resolveDynamicServiceCommand}from'../commands/service/dynamic.js';import{buildMeowFlags}from'../constant/cli.js';import{CliErrors}from'../errors.js';export async function resolveLovrabetInvocation(_0x22be86){const _0x1d89f0=a132_0x1702,_0x2b67a3=a132_0x35c7ef('',{'importMeta':import.meta,'argv':_0x22be86,'flags':buildMeowFlags(),'autoHelp':![],'autoVersion':![]}),_0x1986d1=[..._0x2b67a3[_0x1d89f0(0x99)]],_0x5a63c8=_0x2b67a3[_0x1d89f0(0x96)];await correctFlags(_0x5a63c8);const _0x3f8889=_0x1986d1[0x0];if(!_0x3f8889)throw CliErrors[_0x1d89f0(0xa8)](_0x1d89f0(0x9e));const _0x1bea07=resolveRemovedCommand(_0x3f8889,_0x1986d1[0x1]);if(_0x1bea07)throw CliErrors[_0x1d89f0(0xa8)](_0x1bea07['message'],_0x1bea07[_0x1d89f0(0xa0)]);if(!isKnownService(_0x3f8889)){const _0x2d7b20=resolveDynamicServiceCommand(_0x1986d1,_0x5a63c8);if(!_0x2d7b20)throw CliErrors[_0x1d89f0(0x9b)](_0x1986d1[_0x1d89f0(0x98)]('\x20'));return Object[_0x1d89f0(0xa3)](_0x5a63c8,_0x2d7b20['flags']),{'definition':_0x2d7b20[_0x1d89f0(0xa5)],'rawFlags':_0x5a63c8,'args':_0x2d7b20[_0x1d89f0(0x9a)]};}const _0x1045d0=getServiceEntry(_0x3f8889),_0x162a46=_0x1986d1[0x1]||_0x1045d0[_0x1d89f0(0xa2)];if(!_0x162a46)throw CliErrors[_0x1d89f0(0xa8)](_0x1d89f0(0x93)+_0x3f8889+'\x22.');const _0x1f8684=findDefinition(_0x3f8889,_0x162a46);if(!_0x1f8684)throw CliErrors[_0x1d89f0(0x9b)](_0x3f8889+'\x20'+_0x162a46);return{'definition':_0x1f8684,'rawFlags':_0x5a63c8,'args':_0x1986d1[_0x1d89f0(0x92)](0x2)};}function a132_0x1405(){const _0xf76a60=['input','args','unknownCommand','7ZamQae','4296232hfBTEq','Lovrabet\x20argv\x20must\x20include\x20a\x20service\x20and\x20command.','677034nCRMjS','hint','534392VhddJj','defaultCommand','assign','3ZDMEqY','definition','../commands/registry.js','flatMap','validation','294381SVGSPK','232184fmrDBZ','slice','Lovrabet\x20argv\x20must\x20include\x20a\x20command\x20for\x20service\x20\x22','2120402WPFWlK','5400405ZrIcbE','flags','10awuFXP','join'];a132_0x1405=function(){return _0xf76a60;};return a132_0x1405();}function a132_0x1702(_0x1f33a4,_0x5430df){_0x1f33a4=_0x1f33a4-0x91;const _0x140572=a132_0x1405();let _0x17023b=_0x140572[_0x1f33a4];return _0x17023b;}async function correctFlags(_0x5cf569){const _0x134bed=a132_0x1702;try{const {correctFlags:_0x3b9750}=await import('../framework/preparse.js'),{getAllDefinitions:_0x2edb27}=await import(_0x134bed(0xa6)),_0x3a3364=_0x2edb27()[_0x134bed(0xa7)](_0x2cf159=>_0x2cf159['flags']??[]),_0x55ac0c=_0x3b9750(_0x5cf569,_0x3a3364);Object[_0x134bed(0xa3)](_0x5cf569,_0x55ac0c[_0x134bed(0x96)]);}catch{}}
1
+ function a133_0x1370(){const _0x191b05=['flags','820jMZuMH','1710866whVfoB','hint','116tTwafv','slice','Lovrabet\x20argv\x20must\x20include\x20a\x20service\x20and\x20command.','../framework/preparse.js','5784210JYVUfl','160443YbQvUs','join','assign','flatMap','7384016dWIsTX','3rKjiqG','validation','1398xswyLX','unknownCommand','../commands/registry.js','1454338SmyjBa','input','22463HAiPOT','definition','message','defaultCommand'];a133_0x1370=function(){return _0x191b05;};return a133_0x1370();}(function(_0x2b9699,_0x14f05e){const _0xbeab4e=a133_0x50b4,_0x40a469=_0x2b9699();while(!![]){try{const _0x40cfda=parseInt(_0xbeab4e(0x132))/0x1+-parseInt(_0xbeab4e(0x13a))/0x2+parseInt(_0xbeab4e(0x12d))/0x3*(parseInt(_0xbeab4e(0x13c))/0x4)+-parseInt(_0xbeab4e(0x127))/0x5+parseInt(_0xbeab4e(0x12f))/0x6*(parseInt(_0xbeab4e(0x134))/0x7)+-parseInt(_0xbeab4e(0x12c))/0x8+-parseInt(_0xbeab4e(0x128))/0x9*(-parseInt(_0xbeab4e(0x139))/0xa);if(_0x40cfda===_0x14f05e)break;else _0x40a469['push'](_0x40a469['shift']());}catch(_0x571bfe){_0x40a469['push'](_0x40a469['shift']());}}}(a133_0x1370,0xb1e19));import a133_0x19a469 from'meow';function a133_0x50b4(_0x358188,_0x53d2ad){_0x358188=_0x358188-0x125;const _0x1370e2=a133_0x1370();let _0x50b48e=_0x1370e2[_0x358188];return _0x50b48e;}import{findDefinition,getServiceEntry,isKnownService,resolveRemovedCommand}from'../commands/registry.js';import{resolveDynamicServiceCommand}from'../commands/service/dynamic.js';import{buildMeowFlags}from'../constant/cli.js';import{CliErrors}from'../errors.js';export async function resolveLovrabetInvocation(_0x18bcfa){const _0x2e98d3=a133_0x50b4,_0x4b30f2=a133_0x19a469('',{'importMeta':import.meta,'argv':_0x18bcfa,'flags':buildMeowFlags(),'autoHelp':![],'autoVersion':![]}),_0x220431=[..._0x4b30f2[_0x2e98d3(0x133)]],_0x8f347e=_0x4b30f2[_0x2e98d3(0x138)];await correctFlags(_0x8f347e);const _0x3f2d37=_0x220431[0x0];if(!_0x3f2d37)throw CliErrors[_0x2e98d3(0x12e)](_0x2e98d3(0x125));const _0x2273fd=resolveRemovedCommand(_0x3f2d37,_0x220431[0x1]);if(_0x2273fd)throw CliErrors[_0x2e98d3(0x12e)](_0x2273fd[_0x2e98d3(0x136)],_0x2273fd[_0x2e98d3(0x13b)]);if(!isKnownService(_0x3f2d37)){const _0x2427b9=resolveDynamicServiceCommand(_0x220431,_0x8f347e);if(!_0x2427b9)throw CliErrors[_0x2e98d3(0x130)](_0x220431[_0x2e98d3(0x129)]('\x20'));return Object[_0x2e98d3(0x12a)](_0x8f347e,_0x2427b9[_0x2e98d3(0x138)]),{'definition':_0x2427b9[_0x2e98d3(0x135)],'rawFlags':_0x8f347e,'args':_0x2427b9['args']};}const _0x4b376c=getServiceEntry(_0x3f2d37),_0x2ecb6e=_0x220431[0x1]||_0x4b376c[_0x2e98d3(0x137)];if(!_0x2ecb6e)throw CliErrors[_0x2e98d3(0x12e)]('Lovrabet\x20argv\x20must\x20include\x20a\x20command\x20for\x20service\x20\x22'+_0x3f2d37+'\x22.');const _0x2a0217=findDefinition(_0x3f2d37,_0x2ecb6e);if(!_0x2a0217)throw CliErrors[_0x2e98d3(0x130)](_0x3f2d37+'\x20'+_0x2ecb6e);return{'definition':_0x2a0217,'rawFlags':_0x8f347e,'args':_0x220431[_0x2e98d3(0x13d)](0x2)};}async function correctFlags(_0x3e7b13){const _0x5cf3e1=a133_0x50b4;try{const {correctFlags:_0x3c5f97}=await import(_0x5cf3e1(0x126)),{getAllDefinitions:_0x5019f6}=await import(_0x5cf3e1(0x131)),_0xde7a04=_0x5019f6()[_0x5cf3e1(0x12b)](_0x476af4=>_0x476af4['flags']??[]),_0x1d6971=_0x3c5f97(_0x3e7b13,_0xde7a04);Object[_0x5cf3e1(0x12a)](_0x3e7b13,_0x1d6971[_0x5cf3e1(0x138)]);}catch{}}
@@ -1 +1 @@
1
- const a134_0x53c79c=a134_0x2365;function a134_0xcd30(){const _0x1fb94f=['45YhfPOd','isDirectory','unknown','361506jDwqIW','content_mismatch','Symbolic\x20link\x20is\x20not\x20allowed:\x20',':\x5cs*(.+)$','skills@latest\x20exited\x20','930300UkKfhh','837011NgOPim','3AJVDtW','skills','trim','packageRoot','package.json','absent','update','every','digest','isFile','Built-in\x20Skill\x20source\x20does\x20not\x20match\x20its\x20package\x20manifest','name','lovrabet','SOURCE_INVALID','48SArBEo','1235812etfhOs','sort','installedPath','11788271hvmbVd','split','message','skipped','2SNnYle','627765IBTetE','length','Installed\x20Skill\x20state\x20is\x20','isSymbolicLink','reason','manifest','sha256','includes','home','parse','version_mismatch','pipe','root','path','missing','lovrabet\x20cli-skill\x20install','Unsafe\x20manifest\x20path:\x20','packageVersion','INSTALL_FAILED','630398eBNAhS','version','skillVersion','match','present','hex','current','utf8','state','SKILL.md','flatMap','unverifiable','files'];a134_0xcd30=function(){return _0x1fb94f;};return a134_0xcd30();}(function(_0x1624d5,_0xc09c76){const _0xfd7336=a134_0x2365,_0x57952c=_0x1624d5();while(!![]){try{const _0x5276c2=-parseInt(_0xfd7336(0x220))/0x1*(-parseInt(_0xfd7336(0x20c))/0x2)+parseInt(_0xfd7336(0x1f6))/0x3*(-parseInt(_0xfd7336(0x205))/0x4)+parseInt(_0xfd7336(0x20d))/0x5+-parseInt(_0xfd7336(0x1ef))/0x6+-parseInt(_0xfd7336(0x1f5))/0x7*(-parseInt(_0xfd7336(0x204))/0x8)+-parseInt(_0xfd7336(0x1ec))/0x9*(-parseInt(_0xfd7336(0x1f4))/0xa)+-parseInt(_0xfd7336(0x208))/0xb;if(_0x5276c2===_0xc09c76)break;else _0x57952c['push'](_0x57952c['shift']());}catch(_0x10e624){_0x57952c['push'](_0x57952c['shift']());}}}(a134_0xcd30,0x7980a));function a134_0x2365(_0x1e9cd1,_0x121732){_0x1e9cd1=_0x1e9cd1-0x1ea;const _0xcd30c1=a134_0xcd30();let _0x236518=_0xcd30c1[_0x1e9cd1];return _0x236518;}import{createHash}from'node:crypto';import{lstatSync,readFileSync,readdirSync}from'node:fs';import{homedir}from'node:os';import{dirname,join,relative,resolve,sep}from'node:path';import{fileURLToPath}from'node:url';import{runNpxSkillsAddGlobal}from'../skills/npx-skills-add.js';import{resolveInstalledSkill}from'../skills/skill-presence.js';const DEFAULT_PACKAGE_ROOT=resolve(dirname(fileURLToPath(import.meta.url)),'..','..'),REPAIR_COMMAND=a134_0x53c79c(0x21c),SKILL_NAME=a134_0x53c79c(0x202);function frontmatterValue(_0x377fea,_0x1bd7b3){const _0x1fb399=a134_0x53c79c;return _0x377fea[_0x1fb399(0x223)](new RegExp('^'+_0x1bd7b3+_0x1fb399(0x1f2),'m'))?.[0x1]?.[_0x1fb399(0x1f8)]()??'';}function listFiles(_0xfb519d,_0x2a512b=_0xfb519d){const _0x2bea6e=a134_0x53c79c;return readdirSync(_0x2a512b,{'withFileTypes':!![]})[_0x2bea6e(0x22a)](_0x14497a=>{const _0x3a4036=_0x2bea6e,_0x16f7e0=join(_0x2a512b,_0x14497a[_0x3a4036(0x201)]),_0x455a33=lstatSync(_0x16f7e0);if(_0x455a33[_0x3a4036(0x210)]())throw new Error(_0x3a4036(0x1f1)+_0x16f7e0);if(_0x455a33[_0x3a4036(0x1ed)]())return listFiles(_0xfb519d,_0x16f7e0);if(!_0x455a33[_0x3a4036(0x1ff)]())throw new Error('Unsupported\x20Skill\x20entry:\x20'+_0x16f7e0);return[relative(_0xfb519d,_0x16f7e0)[_0x3a4036(0x209)](sep)['join']('/')];})[_0x2bea6e(0x206)]((_0x52e4d1,_0x3da14e)=>_0x52e4d1<_0x3da14e?-0x1:_0x52e4d1>_0x3da14e?0x1:0x0);}function digestFiles(_0x21d021,_0x6e2c3c){const _0x20a115=a134_0x53c79c,_0x2fbcb5=createHash(_0x20a115(0x213));for(const _0x1aad5e of _0x6e2c3c){if(_0x1aad5e['startsWith']('/')||_0x1aad5e[_0x20a115(0x209)]('/')[_0x20a115(0x214)]('..')||_0x1aad5e[_0x20a115(0x214)]('\x5c'))throw new Error(_0x20a115(0x21d)+_0x1aad5e);_0x2fbcb5[_0x20a115(0x1fc)](_0x1aad5e),_0x2fbcb5['update']('\x00'),_0x2fbcb5[_0x20a115(0x1fc)](readFileSync(join(_0x21d021,..._0x1aad5e[_0x20a115(0x209)]('/')))),_0x2fbcb5['update']('\x00');}return _0x2fbcb5[_0x20a115(0x1fe)](_0x20a115(0x225));}function sameFiles(_0x4cf472,_0x3e9058){const _0x41fa4c=a134_0x53c79c;return _0x4cf472[_0x41fa4c(0x20e)]===_0x3e9058[_0x41fa4c(0x20e)]&&_0x4cf472[_0x41fa4c(0x1fd)]((_0x2af487,_0x5b81cd)=>_0x2af487===_0x3e9058[_0x5b81cd]);}function readSource(_0x4b6e01){const _0x5f0de0=a134_0x53c79c,_0x31ec8c=JSON[_0x5f0de0(0x216)](readFileSync(join(_0x4b6e01,_0x5f0de0(0x1fa)),_0x5f0de0(0x227))),_0x4a92c0=JSON[_0x5f0de0(0x216)](readFileSync(join(_0x4b6e01,_0x5f0de0(0x1f7),'lovrabet.manifest.json'),_0x5f0de0(0x227))),_0x2a88f4=join(_0x4b6e01,_0x5f0de0(0x1f7),SKILL_NAME),_0x29b1bf=frontmatterValue(readFileSync(join(_0x2a88f4,'SKILL.md'),_0x5f0de0(0x227)),_0x5f0de0(0x221)),_0x3db62a=listFiles(_0x2a88f4);if(_0x4a92c0['schemaVersion']!==0x1||_0x4a92c0['name']!==SKILL_NAME||!_0x31ec8c['version']||_0x4a92c0[_0x5f0de0(0x21e)]!==_0x31ec8c['version']||_0x4a92c0['skillVersion']!==_0x31ec8c[_0x5f0de0(0x221)]||_0x29b1bf!==_0x31ec8c[_0x5f0de0(0x221)]||!sameFiles(_0x3db62a,_0x4a92c0[_0x5f0de0(0x1eb)])||digestFiles(_0x2a88f4,_0x3db62a)!==_0x4a92c0[_0x5f0de0(0x1fe)])throw new Error(_0x5f0de0(0x200));return{'packageVersion':_0x31ec8c[_0x5f0de0(0x221)],'skillVersion':_0x29b1bf,'root':_0x2a88f4,'manifest':_0x4a92c0};}function installedSkillPath(_0x56c7c7){const _0x564399=a134_0x53c79c,_0x4f76b3=resolveInstalledSkill(SKILL_NAME,{'home':_0x56c7c7});if(_0x4f76b3[_0x564399(0x228)]===_0x564399(0x224))return{'state':'present','path':dirname(_0x4f76b3[_0x564399(0x21a)])};if(_0x4f76b3[_0x564399(0x228)]===_0x564399(0x1fb))return{'state':_0x564399(0x21b)};return{'state':_0x564399(0x1ea),'reason':_0x4f76b3[_0x564399(0x211)]};}export function inspectInstalledBuiltinSkillVersion(_0x338db4,_0x44a934={}){const _0x2d7b0d=a134_0x53c79c,_0x4330ef=installedSkillPath(_0x44a934[_0x2d7b0d(0x215)]??homedir());if(_0x4330ef['state']===_0x2d7b0d(0x21b))return{'state':_0x2d7b0d(0x21b),'expectedVersion':_0x338db4,'repairCommand':REPAIR_COMMAND};if(_0x4330ef[_0x2d7b0d(0x228)]===_0x2d7b0d(0x1ea))return{'state':_0x2d7b0d(0x1ea),'expectedVersion':_0x338db4,'reason':_0x4330ef[_0x2d7b0d(0x211)],'repairCommand':REPAIR_COMMAND};try{const _0x503090=frontmatterValue(readFileSync(join(_0x4330ef['path'],_0x2d7b0d(0x229)),'utf8'),_0x2d7b0d(0x221));return{'state':_0x503090===_0x338db4?_0x2d7b0d(0x226):_0x2d7b0d(0x217),'expectedVersion':_0x338db4,'skillVersion':_0x503090,'installedPath':_0x4330ef['path'],'repairCommand':REPAIR_COMMAND};}catch(_0x4269f1){return{'state':_0x2d7b0d(0x1ea),'expectedVersion':_0x338db4,'installedPath':_0x4330ef[_0x2d7b0d(0x21a)],'reason':_0x4269f1 instanceof Error?_0x4269f1[_0x2d7b0d(0x20a)]:String(_0x4269f1),'repairCommand':REPAIR_COMMAND};}}export function inspectBuiltinSkill(_0x2e43bb={}){const _0x5c08a6=a134_0x53c79c,_0xb012ef=_0x2e43bb[_0x5c08a6(0x1f9)]??DEFAULT_PACKAGE_ROOT;let _0x1030e0;try{_0x1030e0=readSource(_0xb012ef);}catch(_0x45bfe9){return{'state':'unverifiable','packageVersion':_0x5c08a6(0x1ee),'reason':_0x45bfe9 instanceof Error?_0x45bfe9[_0x5c08a6(0x20a)]:String(_0x45bfe9),'repairCommand':REPAIR_COMMAND};}const _0x31cc5e=installedSkillPath(_0x2e43bb['home']??homedir());if(_0x31cc5e[_0x5c08a6(0x228)]===_0x5c08a6(0x21b))return{'state':_0x5c08a6(0x21b),'packageVersion':_0x1030e0[_0x5c08a6(0x21e)],'repairCommand':REPAIR_COMMAND};if(_0x31cc5e[_0x5c08a6(0x228)]===_0x5c08a6(0x1ea))return{'state':_0x5c08a6(0x1ea),'packageVersion':_0x1030e0[_0x5c08a6(0x21e)],'reason':_0x31cc5e[_0x5c08a6(0x211)],'repairCommand':REPAIR_COMMAND};try{const _0x25e017=frontmatterValue(readFileSync(join(_0x31cc5e[_0x5c08a6(0x21a)],'SKILL.md'),_0x5c08a6(0x227)),_0x5c08a6(0x221));if(_0x25e017!==_0x1030e0[_0x5c08a6(0x222)])return{'state':'version_mismatch','packageVersion':_0x1030e0[_0x5c08a6(0x21e)],'skillVersion':_0x25e017,'installedPath':_0x31cc5e[_0x5c08a6(0x21a)],'repairCommand':REPAIR_COMMAND};const _0x55f549=listFiles(_0x31cc5e[_0x5c08a6(0x21a)]),_0x40869e=digestFiles(_0x31cc5e['path'],_0x55f549);return{'state':sameFiles(_0x55f549,_0x1030e0[_0x5c08a6(0x212)][_0x5c08a6(0x1eb)])&&_0x40869e===_0x1030e0['manifest'][_0x5c08a6(0x1fe)]?'current':_0x5c08a6(0x1f0),'packageVersion':_0x1030e0[_0x5c08a6(0x21e)],'skillVersion':_0x25e017,'installedPath':_0x31cc5e[_0x5c08a6(0x21a)],'digest':_0x40869e,'repairCommand':REPAIR_COMMAND};}catch(_0x50df58){return{'state':_0x5c08a6(0x1ea),'packageVersion':_0x1030e0[_0x5c08a6(0x21e)],'installedPath':_0x31cc5e['path'],'reason':_0x50df58 instanceof Error?_0x50df58[_0x5c08a6(0x20a)]:String(_0x50df58),'repairCommand':REPAIR_COMMAND};}}function failure(_0x1c50c4,_0x21d1d4,_0x3a2a27,_0x559867){const _0x3b3463=a134_0x53c79c;return{'ok':![],'code':_0x1c50c4,'packageVersion':_0x21d1d4[_0x3b3463(0x21e)],'skillVersion':_0x21d1d4[_0x3b3463(0x222)],'installedPath':_0x559867,'changed':![],'repairCommand':REPAIR_COMMAND,'error':_0x3a2a27 instanceof Error?_0x3a2a27[_0x3b3463(0x20a)]:String(_0x3a2a27)};}export function installBuiltinSkill(_0x296ae7={}){const _0x5c2740=a134_0x53c79c,_0x470b56=_0x296ae7[_0x5c2740(0x1f9)]??DEFAULT_PACKAGE_ROOT,_0xf7292b=_0x296ae7[_0x5c2740(0x215)]??homedir();let _0x22af0d;try{_0x22af0d=readSource(_0x470b56);}catch(_0x584d47){return failure(_0x5c2740(0x203),{'packageVersion':_0x5c2740(0x1ee),'skillVersion':'unknown'},_0x584d47);}const _0x2d9a15=inspectBuiltinSkill({'packageRoot':_0x470b56,'home':_0xf7292b}),_0x188815=runNpxSkillsAddGlobal(_0x470b56,_0x22af0d[_0x5c2740(0x219)],{'stdio':_0x296ae7['stdio']??_0x5c2740(0x218),'expectedSkillName':SKILL_NAME,'presence':{'home':_0xf7292b}});if(_0x188815[_0x5c2740(0x20b)])return{'ok':!![],'packageVersion':_0x22af0d[_0x5c2740(0x21e)],'skillVersion':_0x22af0d[_0x5c2740(0x222)],'installedPath':_0x2d9a15[_0x5c2740(0x207)],'changed':![],'repairCommand':REPAIR_COMMAND};if(!_0x188815['ok'])return failure(_0x5c2740(0x21f),_0x22af0d,_0x188815['error']??_0x5c2740(0x1f3)+_0x188815['status']);const _0x5ce5e4=inspectBuiltinSkill({'packageRoot':_0x470b56,'home':_0xf7292b});if(_0x5ce5e4[_0x5c2740(0x228)]!==_0x5c2740(0x226))return failure('VERIFY_FAILED',_0x22af0d,_0x5ce5e4[_0x5c2740(0x211)]??_0x5c2740(0x20f)+_0x5ce5e4[_0x5c2740(0x228)],_0x5ce5e4['installedPath']);return{'ok':!![],'packageVersion':_0x22af0d[_0x5c2740(0x21e)],'skillVersion':_0x22af0d[_0x5c2740(0x222)],'installedPath':_0x5ce5e4[_0x5c2740(0x207)],'changed':_0x2d9a15[_0x5c2740(0x228)]!==_0x5c2740(0x226),'repairCommand':REPAIR_COMMAND};}
1
+ const a135_0x2cdcbf=a135_0x5bf5;(function(_0x16723f,_0x50b0ec){const _0x267c5a=a135_0x5bf5,_0x5e6d78=_0x16723f();while(!![]){try{const _0x4bbc92=parseInt(_0x267c5a(0x1a4))/0x1+parseInt(_0x267c5a(0x1a2))/0x2+-parseInt(_0x267c5a(0x1b0))/0x3*(parseInt(_0x267c5a(0x1ad))/0x4)+parseInt(_0x267c5a(0x18e))/0x5*(-parseInt(_0x267c5a(0x185))/0x6)+-parseInt(_0x267c5a(0x18c))/0x7+-parseInt(_0x267c5a(0x17d))/0x8*(-parseInt(_0x267c5a(0x171))/0x9)+-parseInt(_0x267c5a(0x183))/0xa*(-parseInt(_0x267c5a(0x17b))/0xb);if(_0x4bbc92===_0x50b0ec)break;else _0x5e6d78['push'](_0x5e6d78['shift']());}catch(_0x467a1f){_0x5e6d78['push'](_0x5e6d78['shift']());}}}(a135_0x5033,0x89131));import{createHash}from'node:crypto';import{lstatSync,readFileSync,readdirSync}from'node:fs';function a135_0x5bf5(_0x3a33e7,_0x1891f2){_0x3a33e7=_0x3a33e7-0x171;const _0x50333f=a135_0x5033();let _0x5bf529=_0x50333f[_0x3a33e7];return _0x5bf529;}import{homedir}from'node:os';import{dirname,join,relative,resolve,sep}from'node:path';import{fileURLToPath}from'node:url';import{runNpxSkillsAddGlobal}from'../skills/npx-skills-add.js';import{resolveInstalledSkill}from'../skills/skill-presence.js';const DEFAULT_PACKAGE_ROOT=resolve(dirname(fileURLToPath(import.meta.url)),'..','..'),REPAIR_COMMAND=a135_0x2cdcbf(0x188),SKILL_NAME='lovrabet';function frontmatterValue(_0x4c2856,_0x1a88ae){const _0x3b2612=a135_0x2cdcbf;return _0x4c2856[_0x3b2612(0x19d)](new RegExp('^'+_0x1a88ae+_0x3b2612(0x1ae),'m'))?.[0x1]?.[_0x3b2612(0x194)]()??'';}function a135_0x5033(){const _0x219b0e=['path','unverifiable','packageRoot','root','Built-in\x20Skill\x20source\x20does\x20not\x20match\x20its\x20package\x20manifest','version_mismatch','absent','464YIjrqX',':\x5cs*(.+)$','package.json','15843DWbYXs','skills@latest\x20exited\x20','isDirectory','59544NnaCHr','hex','schemaVersion','files','message','utf8','Unsupported\x20Skill\x20entry:\x20','update','unknown','home','5796593RaPzaV','Symbolic\x20link\x20is\x20not\x20allowed:\x20','328ithnCf','content_mismatch','name','skipped','SOURCE_INVALID','current','10mICDYT','present','12fttzEO','installedPath','error','lovrabet\x20cli-skill\x20install','status','lovrabet.manifest.json','every','580748wOEElr','manifest','1212235iecKRF','version','parse','includes','startsWith','skillVersion','trim','SKILL.md','split','skills','Installed\x20Skill\x20state\x20is\x20','reason','digest','sha256','length','match','missing','packageVersion','state','sort','1629938znuxaC','VERIFY_FAILED','128723EzZyrg','Unsafe\x20manifest\x20path:\x20'];a135_0x5033=function(){return _0x219b0e;};return a135_0x5033();}function listFiles(_0x525f21,_0xfc42f7=_0x525f21){const _0x2125db=a135_0x2cdcbf;return readdirSync(_0xfc42f7,{'withFileTypes':!![]})['flatMap'](_0x39a9c2=>{const _0x595a2e=a135_0x5bf5,_0x39bfe4=join(_0xfc42f7,_0x39a9c2[_0x595a2e(0x17f)]),_0x4521ab=lstatSync(_0x39bfe4);if(_0x4521ab['isSymbolicLink']())throw new Error(_0x595a2e(0x17c)+_0x39bfe4);if(_0x4521ab[_0x595a2e(0x1b2)]())return listFiles(_0x525f21,_0x39bfe4);if(!_0x4521ab['isFile']())throw new Error(_0x595a2e(0x177)+_0x39bfe4);return[relative(_0x525f21,_0x39bfe4)[_0x595a2e(0x196)](sep)['join']('/')];})[_0x2125db(0x1a1)]((_0x1030b5,_0x1fe808)=>_0x1030b5<_0x1fe808?-0x1:_0x1030b5>_0x1fe808?0x1:0x0);}function digestFiles(_0x41a34d,_0x6d88f5){const _0x4a47ca=a135_0x2cdcbf,_0x53003e=createHash(_0x4a47ca(0x19b));for(const _0x6f86f4 of _0x6d88f5){if(_0x6f86f4[_0x4a47ca(0x192)]('/')||_0x6f86f4[_0x4a47ca(0x196)]('/')[_0x4a47ca(0x191)]('..')||_0x6f86f4[_0x4a47ca(0x191)]('\x5c'))throw new Error(_0x4a47ca(0x1a5)+_0x6f86f4);_0x53003e[_0x4a47ca(0x178)](_0x6f86f4),_0x53003e[_0x4a47ca(0x178)]('\x00'),_0x53003e['update'](readFileSync(join(_0x41a34d,..._0x6f86f4[_0x4a47ca(0x196)]('/')))),_0x53003e[_0x4a47ca(0x178)]('\x00');}return _0x53003e['digest'](_0x4a47ca(0x172));}function sameFiles(_0x3b92fd,_0x1fad20){const _0x496163=a135_0x2cdcbf;return _0x3b92fd[_0x496163(0x19c)]===_0x1fad20['length']&&_0x3b92fd[_0x496163(0x18b)]((_0x20d864,_0x3bf8ad)=>_0x20d864===_0x1fad20[_0x3bf8ad]);}function readSource(_0x10220e){const _0x5231fb=a135_0x2cdcbf,_0x3dc8c0=JSON[_0x5231fb(0x190)](readFileSync(join(_0x10220e,_0x5231fb(0x1af)),_0x5231fb(0x176))),_0x16c53d=JSON[_0x5231fb(0x190)](readFileSync(join(_0x10220e,_0x5231fb(0x197),_0x5231fb(0x18a)),_0x5231fb(0x176))),_0x127062=join(_0x10220e,'skills',SKILL_NAME),_0x285484=frontmatterValue(readFileSync(join(_0x127062,'SKILL.md'),'utf8'),'version'),_0x1d7857=listFiles(_0x127062);if(_0x16c53d[_0x5231fb(0x173)]!==0x1||_0x16c53d[_0x5231fb(0x17f)]!==SKILL_NAME||!_0x3dc8c0['version']||_0x16c53d[_0x5231fb(0x19f)]!==_0x3dc8c0[_0x5231fb(0x18f)]||_0x16c53d[_0x5231fb(0x193)]!==_0x3dc8c0[_0x5231fb(0x18f)]||_0x285484!==_0x3dc8c0[_0x5231fb(0x18f)]||!sameFiles(_0x1d7857,_0x16c53d[_0x5231fb(0x174)])||digestFiles(_0x127062,_0x1d7857)!==_0x16c53d[_0x5231fb(0x19a)])throw new Error(_0x5231fb(0x1aa));return{'packageVersion':_0x3dc8c0['version'],'skillVersion':_0x285484,'root':_0x127062,'manifest':_0x16c53d};}function installedSkillPath(_0xf6c31){const _0x4baaf=a135_0x2cdcbf,_0xa9c1=resolveInstalledSkill(SKILL_NAME,{'home':_0xf6c31});if(_0xa9c1[_0x4baaf(0x1a0)]===_0x4baaf(0x184))return{'state':_0x4baaf(0x184),'path':dirname(_0xa9c1[_0x4baaf(0x1a6)])};if(_0xa9c1['state']===_0x4baaf(0x1ac))return{'state':_0x4baaf(0x19e)};return{'state':'unverifiable','reason':_0xa9c1[_0x4baaf(0x199)]};}export function inspectInstalledBuiltinSkillVersion(_0x3793c6,_0x3ef1e8={}){const _0x1dffdf=a135_0x2cdcbf,_0x57ba6f=installedSkillPath(_0x3ef1e8[_0x1dffdf(0x17a)]??homedir());if(_0x57ba6f['state']===_0x1dffdf(0x19e))return{'state':_0x1dffdf(0x19e),'expectedVersion':_0x3793c6,'repairCommand':REPAIR_COMMAND};if(_0x57ba6f[_0x1dffdf(0x1a0)]===_0x1dffdf(0x1a7))return{'state':_0x1dffdf(0x1a7),'expectedVersion':_0x3793c6,'reason':_0x57ba6f[_0x1dffdf(0x199)],'repairCommand':REPAIR_COMMAND};try{const _0x2bd9be=frontmatterValue(readFileSync(join(_0x57ba6f[_0x1dffdf(0x1a6)],_0x1dffdf(0x195)),_0x1dffdf(0x176)),_0x1dffdf(0x18f));return{'state':_0x2bd9be===_0x3793c6?'current':_0x1dffdf(0x1ab),'expectedVersion':_0x3793c6,'skillVersion':_0x2bd9be,'installedPath':_0x57ba6f[_0x1dffdf(0x1a6)],'repairCommand':REPAIR_COMMAND};}catch(_0x38fb9d){return{'state':_0x1dffdf(0x1a7),'expectedVersion':_0x3793c6,'installedPath':_0x57ba6f[_0x1dffdf(0x1a6)],'reason':_0x38fb9d instanceof Error?_0x38fb9d['message']:String(_0x38fb9d),'repairCommand':REPAIR_COMMAND};}}export function inspectBuiltinSkill(_0x16cb06={}){const _0x402849=a135_0x2cdcbf,_0x5e6305=_0x16cb06[_0x402849(0x1a8)]??DEFAULT_PACKAGE_ROOT;let _0x10a448;try{_0x10a448=readSource(_0x5e6305);}catch(_0x403a75){return{'state':'unverifiable','packageVersion':'unknown','reason':_0x403a75 instanceof Error?_0x403a75['message']:String(_0x403a75),'repairCommand':REPAIR_COMMAND};}const _0x5a95c5=installedSkillPath(_0x16cb06['home']??homedir());if(_0x5a95c5[_0x402849(0x1a0)]===_0x402849(0x19e))return{'state':_0x402849(0x19e),'packageVersion':_0x10a448[_0x402849(0x19f)],'repairCommand':REPAIR_COMMAND};if(_0x5a95c5[_0x402849(0x1a0)]===_0x402849(0x1a7))return{'state':_0x402849(0x1a7),'packageVersion':_0x10a448['packageVersion'],'reason':_0x5a95c5[_0x402849(0x199)],'repairCommand':REPAIR_COMMAND};try{const _0x1458f2=frontmatterValue(readFileSync(join(_0x5a95c5[_0x402849(0x1a6)],_0x402849(0x195)),'utf8'),_0x402849(0x18f));if(_0x1458f2!==_0x10a448[_0x402849(0x193)])return{'state':'version_mismatch','packageVersion':_0x10a448[_0x402849(0x19f)],'skillVersion':_0x1458f2,'installedPath':_0x5a95c5[_0x402849(0x1a6)],'repairCommand':REPAIR_COMMAND};const _0x2a7cb2=listFiles(_0x5a95c5[_0x402849(0x1a6)]),_0x4d25bb=digestFiles(_0x5a95c5['path'],_0x2a7cb2);return{'state':sameFiles(_0x2a7cb2,_0x10a448[_0x402849(0x18d)][_0x402849(0x174)])&&_0x4d25bb===_0x10a448[_0x402849(0x18d)][_0x402849(0x19a)]?_0x402849(0x182):_0x402849(0x17e),'packageVersion':_0x10a448[_0x402849(0x19f)],'skillVersion':_0x1458f2,'installedPath':_0x5a95c5['path'],'digest':_0x4d25bb,'repairCommand':REPAIR_COMMAND};}catch(_0xb83287){return{'state':_0x402849(0x1a7),'packageVersion':_0x10a448[_0x402849(0x19f)],'installedPath':_0x5a95c5['path'],'reason':_0xb83287 instanceof Error?_0xb83287[_0x402849(0x175)]:String(_0xb83287),'repairCommand':REPAIR_COMMAND};}}function failure(_0x382e06,_0x2a05dd,_0x5b4415,_0xfa3c78){const _0x776f5a=a135_0x2cdcbf;return{'ok':![],'code':_0x382e06,'packageVersion':_0x2a05dd[_0x776f5a(0x19f)],'skillVersion':_0x2a05dd[_0x776f5a(0x193)],'installedPath':_0xfa3c78,'changed':![],'repairCommand':REPAIR_COMMAND,'error':_0x5b4415 instanceof Error?_0x5b4415[_0x776f5a(0x175)]:String(_0x5b4415)};}export function installBuiltinSkill(_0x1cc91a={}){const _0x23acff=a135_0x2cdcbf,_0x5f4529=_0x1cc91a['packageRoot']??DEFAULT_PACKAGE_ROOT,_0x2092eb=_0x1cc91a[_0x23acff(0x17a)]??homedir();let _0x54c60b;try{_0x54c60b=readSource(_0x5f4529);}catch(_0x2ddf3f){return failure(_0x23acff(0x181),{'packageVersion':_0x23acff(0x179),'skillVersion':_0x23acff(0x179)},_0x2ddf3f);}const _0x47a50e=inspectBuiltinSkill({'packageRoot':_0x5f4529,'home':_0x2092eb}),_0x638e70=runNpxSkillsAddGlobal(_0x5f4529,_0x54c60b[_0x23acff(0x1a9)],{'stdio':_0x1cc91a['stdio']??'pipe','expectedSkillName':SKILL_NAME,'presence':{'home':_0x2092eb}});if(_0x638e70[_0x23acff(0x180)])return{'ok':!![],'packageVersion':_0x54c60b[_0x23acff(0x19f)],'skillVersion':_0x54c60b[_0x23acff(0x193)],'installedPath':_0x47a50e[_0x23acff(0x186)],'changed':![],'repairCommand':REPAIR_COMMAND};if(!_0x638e70['ok'])return failure('INSTALL_FAILED',_0x54c60b,_0x638e70[_0x23acff(0x187)]??_0x23acff(0x1b1)+_0x638e70[_0x23acff(0x189)]);const _0x37f60d=inspectBuiltinSkill({'packageRoot':_0x5f4529,'home':_0x2092eb});if(_0x37f60d[_0x23acff(0x1a0)]!==_0x23acff(0x182))return failure(_0x23acff(0x1a3),_0x54c60b,_0x37f60d[_0x23acff(0x199)]??_0x23acff(0x198)+_0x37f60d[_0x23acff(0x1a0)],_0x37f60d[_0x23acff(0x186)]);return{'ok':!![],'packageVersion':_0x54c60b[_0x23acff(0x19f)],'skillVersion':_0x54c60b[_0x23acff(0x193)],'installedPath':_0x37f60d[_0x23acff(0x186)],'changed':_0x47a50e[_0x23acff(0x1a0)]!==_0x23acff(0x182),'repairCommand':REPAIR_COMMAND};}
@@ -1 +1 @@
1
- const a135_0x3b9126=a135_0x542c;(function(_0x51cc6d,_0x563e74){const _0x37958b=a135_0x542c,_0x5dc66c=_0x51cc6d();while(!![]){try{const _0x2ed8be=parseInt(_0x37958b(0x200))/0x1+parseInt(_0x37958b(0x203))/0x2+parseInt(_0x37958b(0x1fa))/0x3+-parseInt(_0x37958b(0x1fd))/0x4*(-parseInt(_0x37958b(0x210))/0x5)+-parseInt(_0x37958b(0x207))/0x6+parseInt(_0x37958b(0x1ef))/0x7+-parseInt(_0x37958b(0x1fb))/0x8*(parseInt(_0x37958b(0x20f))/0x9);if(_0x2ed8be===_0x563e74)break;else _0x5dc66c['push'](_0x5dc66c['shift']());}catch(_0x5b7fde){_0x5dc66c['push'](_0x5dc66c['shift']());}}}(a135_0x19a3,0x453b1));import{spawnSync}from'node:child_process';import{resolveNpmBin}from'../utils/platform.js';import{LOVRABET_SKILL_SOURCE as a135_0x24f6b7}from'../constant/distribution.js';import{PRODUCT_CONFIG,productEnvName}from'../constant/product.js';import{resolveInstalledSkill}from'../skills/skill-presence.js';export const LOVRABET_SKILL_SOURCE=a135_0x24f6b7;export const LOVRABET_SKILL_GIT_SOURCE=PRODUCT_CONFIG[a135_0x3b9126(0x1e2)];function a135_0x542c(_0x4b7d10,_0x23c101){_0x4b7d10=_0x4b7d10-0x1e2;const _0x19a324=a135_0x19a3();let _0x542c32=_0x19a324[_0x4b7d10];return _0x542c32;}export const LOVRABET_GLOBAL_SKILL_NAME=PRODUCT_CONFIG[a135_0x3b9126(0x1ec)];export function resolveGlobalSkillName(_0xf5fc09){const _0x33eec1=a135_0x3b9126;switch(_0xf5fc09[_0x33eec1(0x204)]()){case LOVRABET_SKILL_SOURCE:case LOVRABET_SKILL_GIT_SOURCE:return LOVRABET_GLOBAL_SKILL_NAME;default:return undefined;}}export const LOVRABET_SKIP_NPX_SKILLS_ENV=productEnvName(PRODUCT_CONFIG[a135_0x3b9126(0x1f9)]);function a135_0x19a3(){const _0xe90c4=['220102YWVreA','trim','expectedSkillName','npx','806334fatKGr','\x22\x20install\x20state:\x20','code','unverifiable','npx\x20terminated\x20by\x20signal\x20','status','SKILL_NOT_INSTALLED','state','9qnfNDS','34305FxBMOs','presence','error','present','CHILD_TERMINATED','internalSkillSource','\x20failed\x20target(s)','stdout','ENOENT','INSTALL_PARTIAL','log','message','EACCES','filter','join','globalSkillName','signal','EPERM','1624518qFIoFe','stderr','!\x20Could\x20not\x20verify\x20\x22','add','SPAWN_FAILED','toString','match','npm_config_global','Skill\x20\x22','skills@latest','skipNpxSkillsEnvSuffix','1364631JvpDJh','8835576NQaCGi','CHILD_EXIT_NONZERO','216NpXkej','checked','PERMISSION_DENIED','354909jspQgB','warn','pipe'];a135_0x19a3=function(){return _0xe90c4;};return a135_0x19a3();}const CHILD_OUTPUT_MAX_BUFFER=0x10*0x400*0x400;function failure(_0x1988b2,_0x4e13c2,_0x1316fc){return{'ok':![],'status':_0x4e13c2,'code':_0x1988b2,'error':'['+_0x1988b2+']\x20'+_0x1316fc};}export function shouldSkipNpxSkillsAdd(){return process.env[LOVRABET_SKIP_NPX_SKILLS_ENV]==='1';}export function runNpxSkillsAddGlobal(_0x2ecfca,_0x2b65f3=LOVRABET_SKILL_SOURCE,_0xed417d){const _0x691e25=a135_0x3b9126;if(shouldSkipNpxSkillsAdd())return{'ok':!![],'status':0x0,'skipped':!![]};const _0x589aec=resolveNpmBin(_0x691e25(0x206)),_0x555ad9=['-y',_0x691e25(0x1f8),_0x691e25(0x1f2),_0x2b65f3,'-g','-y'],_0x25aead=[_0x589aec,..._0x555ad9][_0x691e25(0x1eb)]('\x20');console[_0x691e25(0x1e7)]('*\x20'+_0x25aead);const _0x3fb64f={...process.env};delete _0x3fb64f[_0x691e25(0x1f6)],delete _0x3fb64f['NPM_CONFIG_GLOBAL'];const _0x5bce11=spawnSync(_0x589aec,_0x555ad9,{'cwd':_0x2ecfca,'stdio':'pipe','env':_0x3fb64f,'shell':![],'maxBuffer':CHILD_OUTPUT_MAX_BUFFER}),_0xe5cdc8=[_0x5bce11[_0x691e25(0x1e4)]?_0x5bce11['stdout'][_0x691e25(0x1f4)]():'',_0x5bce11[_0x691e25(0x1f0)]?_0x5bce11['stderr']['toString']():''][_0x691e25(0x1ea)](Boolean)['join']('\x0a')[_0x691e25(0x204)]();_0xed417d?.['stdio']!==_0x691e25(0x202)&&_0xe5cdc8&&console[_0x691e25(0x1e7)](_0xe5cdc8);if(_0x5bce11[_0x691e25(0x212)]){const _0x6c0623=_0x5bce11[_0x691e25(0x212)],_0x4015b1=_0x6c0623[_0x691e25(0x209)]===_0x691e25(0x1e5)?'NPX_NOT_FOUND':_0x6c0623[_0x691e25(0x209)]===_0x691e25(0x1ee)||_0x6c0623[_0x691e25(0x209)]===_0x691e25(0x1e9)?_0x691e25(0x1ff):_0x691e25(0x1f3);return failure(_0x4015b1,_0x5bce11[_0x691e25(0x20c)],_0x6c0623[_0x691e25(0x1e8)]);}if(_0x5bce11[_0x691e25(0x1ed)])return failure(_0x691e25(0x214),_0x5bce11[_0x691e25(0x20c)],_0x691e25(0x20b)+_0x5bce11[_0x691e25(0x1ed)]);if(_0x5bce11[_0x691e25(0x20c)]!==0x0)return failure(_0x691e25(0x1fc),_0x5bce11[_0x691e25(0x20c)],_0xe5cdc8||'exit\x20'+(_0x5bce11[_0x691e25(0x20c)]??'unknown'));const _0x11f23a=_0xed417d?.[_0x691e25(0x205)]??resolveGlobalSkillName(_0x2b65f3),_0x4bb0ac=_0x11f23a?resolveInstalledSkill(_0x11f23a,_0xed417d?.[_0x691e25(0x211)]):undefined,_0x9c3890=_0xe5cdc8[_0x691e25(0x1f5)](/Failed to install\s+(\d+)/i);if(_0x9c3890&&Number(_0x9c3890[0x1])>0x0){const _0x4c1ea9='Installer\x20reported\x20'+_0x9c3890[0x1]+_0x691e25(0x1e3)+(_0xe5cdc8?':\x0a'+_0xe5cdc8:'');if(_0x4bb0ac?.[_0x691e25(0x20e)]===_0x691e25(0x213))return console['warn']('!\x20'+_0x4c1ea9),{'ok':!![],'status':0x0};return failure(_0x691e25(0x1e6),0x0,_0x4c1ea9);}if(_0x11f23a&&_0x4bb0ac){if(_0x4bb0ac[_0x691e25(0x20e)]==='absent')return failure(_0x691e25(0x20d),0x0,_0x691e25(0x1f7)+_0x11f23a+'\x22\x20not\x20found\x20after\x20install\x20(checked\x20'+_0x4bb0ac[_0x691e25(0x1fe)][_0x691e25(0x1eb)](',\x20')+')');_0x4bb0ac['state']===_0x691e25(0x20a)&&console[_0x691e25(0x201)](_0x691e25(0x1f1)+_0x11f23a+_0x691e25(0x208)+_0x4bb0ac['reason']);}return{'ok':!![],'status':0x0};}
1
+ const a136_0x373a5d=a136_0x5e6c;(function(_0x425f42,_0x2613a5){const _0x4931fe=a136_0x5e6c,_0xa958e5=_0x425f42();while(!![]){try{const _0x31f4e2=-parseInt(_0x4931fe(0x11b))/0x1*(-parseInt(_0x4931fe(0x112))/0x2)+parseInt(_0x4931fe(0x123))/0x3+-parseInt(_0x4931fe(0xfe))/0x4*(-parseInt(_0x4931fe(0x108))/0x5)+parseInt(_0x4931fe(0x118))/0x6+-parseInt(_0x4931fe(0xfa))/0x7*(parseInt(_0x4931fe(0xf8))/0x8)+parseInt(_0x4931fe(0x105))/0x9+-parseInt(_0x4931fe(0x100))/0xa*(parseInt(_0x4931fe(0xff))/0xb);if(_0x31f4e2===_0x2613a5)break;else _0xa958e5['push'](_0xa958e5['shift']());}catch(_0x355200){_0xa958e5['push'](_0xa958e5['shift']());}}}(a136_0x2561,0x21b3e));import{spawnSync}from'node:child_process';import{resolveNpmBin}from'../utils/platform.js';import{LOVRABET_SKILL_SOURCE as a136_0x274c79}from'../constant/distribution.js';function a136_0x2561(){const _0x27a4c2=['ENOENT','\x20failed\x20target(s)','internalSkillSource','toString','!\x20Could\x20not\x20verify\x20\x22','12024tWjuWF','INSTALL_PARTIAL','735HqyqWE','code','npm_config_global','present','4cUwesO','143VqxeNf','243510CkVjpl','status','reason','pipe','log','843876SALzSn','SKILL_NOT_INSTALLED','presence','790805wwbgHS','npx','error','trim','expectedSkillName','CHILD_TERMINATED','\x22\x20install\x20state:\x20','join','EPERM','stdout','2ZpMLLp','checked','EACCES','match','\x22\x20not\x20found\x20after\x20install\x20(checked\x20','warn','698640gNoxOm','stderr','stdio','175734GWBTYm','add','globalSkillName','absent','state','CHILD_EXIT_NONZERO','signal','NPX_NOT_FOUND','204975HBnCau','unverifiable','SPAWN_FAILED'];a136_0x2561=function(){return _0x27a4c2;};return a136_0x2561();}import{PRODUCT_CONFIG,productEnvName}from'../constant/product.js';import{resolveInstalledSkill}from'../skills/skill-presence.js';export const LOVRABET_SKILL_SOURCE=a136_0x274c79;export const LOVRABET_SKILL_GIT_SOURCE=PRODUCT_CONFIG[a136_0x373a5d(0xf5)];export const LOVRABET_GLOBAL_SKILL_NAME=PRODUCT_CONFIG[a136_0x373a5d(0x11d)];function a136_0x5e6c(_0x3a5076,_0x395314){_0x3a5076=_0x3a5076-0xf2;const _0x256168=a136_0x2561();let _0x5e6cd6=_0x256168[_0x3a5076];return _0x5e6cd6;}export function resolveGlobalSkillName(_0xfa0fd7){const _0x52de10=a136_0x373a5d;switch(_0xfa0fd7[_0x52de10(0x10b)]()){case LOVRABET_SKILL_SOURCE:case LOVRABET_SKILL_GIT_SOURCE:return LOVRABET_GLOBAL_SKILL_NAME;default:return undefined;}}export const LOVRABET_SKIP_NPX_SKILLS_ENV=productEnvName(PRODUCT_CONFIG['skipNpxSkillsEnvSuffix']);const CHILD_OUTPUT_MAX_BUFFER=0x10*0x400*0x400;function failure(_0x1eb5cf,_0x4ea9ec,_0x228bae){return{'ok':![],'status':_0x4ea9ec,'code':_0x1eb5cf,'error':'['+_0x1eb5cf+']\x20'+_0x228bae};}export function shouldSkipNpxSkillsAdd(){return process.env[LOVRABET_SKIP_NPX_SKILLS_ENV]==='1';}export function runNpxSkillsAddGlobal(_0x2e00f2,_0x387950=LOVRABET_SKILL_SOURCE,_0x103e5a){const _0x1cc733=a136_0x373a5d;if(shouldSkipNpxSkillsAdd())return{'ok':!![],'status':0x0,'skipped':!![]};const _0x2a5a35=resolveNpmBin(_0x1cc733(0x109)),_0x19e805=['-y','skills@latest',_0x1cc733(0x11c),_0x387950,'-g','-y'],_0x233d82=[_0x2a5a35,..._0x19e805][_0x1cc733(0x10f)]('\x20');console[_0x1cc733(0x104)]('*\x20'+_0x233d82);const _0x1fc482={...process.env};delete _0x1fc482[_0x1cc733(0xfc)],delete _0x1fc482['NPM_CONFIG_GLOBAL'];const _0x128947=spawnSync(_0x2a5a35,_0x19e805,{'cwd':_0x2e00f2,'stdio':_0x1cc733(0x103),'env':_0x1fc482,'shell':![],'maxBuffer':CHILD_OUTPUT_MAX_BUFFER}),_0xdcea8a=[_0x128947[_0x1cc733(0x111)]?_0x128947[_0x1cc733(0x111)][_0x1cc733(0xf6)]():'',_0x128947['stderr']?_0x128947[_0x1cc733(0x119)]['toString']():'']['filter'](Boolean)['join']('\x0a')['trim']();_0x103e5a?.[_0x1cc733(0x11a)]!==_0x1cc733(0x103)&&_0xdcea8a&&console[_0x1cc733(0x104)](_0xdcea8a);if(_0x128947[_0x1cc733(0x10a)]){const _0x32b68d=_0x128947[_0x1cc733(0x10a)],_0x5ded1f=_0x32b68d[_0x1cc733(0xfb)]===_0x1cc733(0xf3)?_0x1cc733(0x122):_0x32b68d[_0x1cc733(0xfb)]===_0x1cc733(0x110)||_0x32b68d[_0x1cc733(0xfb)]===_0x1cc733(0x114)?'PERMISSION_DENIED':_0x1cc733(0xf2);return failure(_0x5ded1f,_0x128947[_0x1cc733(0x101)],_0x32b68d['message']);}if(_0x128947[_0x1cc733(0x121)])return failure(_0x1cc733(0x10d),_0x128947['status'],'npx\x20terminated\x20by\x20signal\x20'+_0x128947['signal']);if(_0x128947['status']!==0x0)return failure(_0x1cc733(0x120),_0x128947[_0x1cc733(0x101)],_0xdcea8a||'exit\x20'+(_0x128947[_0x1cc733(0x101)]??'unknown'));const _0x1f0da8=_0x103e5a?.[_0x1cc733(0x10c)]??resolveGlobalSkillName(_0x387950),_0x44c474=_0x1f0da8?resolveInstalledSkill(_0x1f0da8,_0x103e5a?.[_0x1cc733(0x107)]):undefined,_0x194f73=_0xdcea8a[_0x1cc733(0x115)](/Failed to install\s+(\d+)/i);if(_0x194f73&&Number(_0x194f73[0x1])>0x0){const _0x5a2dec='Installer\x20reported\x20'+_0x194f73[0x1]+_0x1cc733(0xf4)+(_0xdcea8a?':\x0a'+_0xdcea8a:'');if(_0x44c474?.['state']===_0x1cc733(0xfd))return console[_0x1cc733(0x117)]('!\x20'+_0x5a2dec),{'ok':!![],'status':0x0};return failure(_0x1cc733(0xf9),0x0,_0x5a2dec);}if(_0x1f0da8&&_0x44c474){if(_0x44c474['state']===_0x1cc733(0x11e))return failure(_0x1cc733(0x106),0x0,'Skill\x20\x22'+_0x1f0da8+_0x1cc733(0x116)+_0x44c474[_0x1cc733(0x113)][_0x1cc733(0x10f)](',\x20')+')');_0x44c474[_0x1cc733(0x11f)]===_0x1cc733(0x124)&&console[_0x1cc733(0x117)](_0x1cc733(0xf7)+_0x1f0da8+_0x1cc733(0x10e)+_0x44c474[_0x1cc733(0x102)]);}return{'ok':!![],'status':0x0};}
@@ -1 +1 @@
1
- const a136_0x2159d4=a136_0x5325;(function(_0x54cd0d,_0x17090a){const _0x1b9bfe=a136_0x5325,_0x9ec9bd=_0x54cd0d();while(!![]){try{const _0x449853=-parseInt(_0x1b9bfe(0x1de))/0x1*(-parseInt(_0x1b9bfe(0x1dd))/0x2)+parseInt(_0x1b9bfe(0x1df))/0x3+parseInt(_0x1b9bfe(0x1ea))/0x4*(-parseInt(_0x1b9bfe(0x1ee))/0x5)+-parseInt(_0x1b9bfe(0x1e7))/0x6+-parseInt(_0x1b9bfe(0x1e5))/0x7+-parseInt(_0x1b9bfe(0x1ec))/0x8+-parseInt(_0x1b9bfe(0x1e3))/0x9*(-parseInt(_0x1b9bfe(0x1e0))/0xa);if(_0x449853===_0x17090a)break;else _0x9ec9bd['push'](_0x9ec9bd['shift']());}catch(_0x25d510){_0x9ec9bd['push'](_0x9ec9bd['shift']());}}}(a136_0x5bf6,0x35114));export const METADATA_FILE=a136_0x2159d4(0x1e2);export const SKILL_FILE=a136_0x2159d4(0x1e6);export const IGNORED_FILE_NAMES=new Set([METADATA_FILE,a136_0x2159d4(0x1eb)]);function a136_0x5bf6(){const _0x3d054f=['443256CDwoYA','.git','5FMOxkK','build','node_modules','4jAVScV','129007YRnbvK','751455HQfCty','3110djAcZf','.hg','lovrabet.skill.json','1494xWKPQg','.turbo','949886zRgAeX','SKILL.md','507834WvzMRd','dist','.svn','268068ANWNNY','.DS_Store'];a136_0x5bf6=function(){return _0x3d054f;};return a136_0x5bf6();}function a136_0x5325(_0x287631,_0x28ebd1){_0x287631=_0x287631-0x1dd;const _0x5bf62d=a136_0x5bf6();let _0x5325d0=_0x5bf62d[_0x287631];return _0x5325d0;}export const IGNORED_DIR_NAMES=new Set([a136_0x2159d4(0x1ed),a136_0x2159d4(0x1e1),a136_0x2159d4(0x1e9),a136_0x2159d4(0x1f0),'.next',a136_0x2159d4(0x1e8),a136_0x2159d4(0x1ef),'coverage',a136_0x2159d4(0x1e4),'.cache']);
1
+ const a137_0x4a939f=a137_0x4d4c;function a137_0x4d4c(_0x85bad3,_0x233d28){_0x85bad3=_0x85bad3-0x7d;const _0x1fd313=a137_0x1fd3();let _0x4d4c4b=_0x1fd313[_0x85bad3];return _0x4d4c4b;}(function(_0x1b533e,_0x6f74e1){const _0x1d6a85=a137_0x4d4c,_0x301b49=_0x1b533e();while(!![]){try{const _0x362fef=-parseInt(_0x1d6a85(0x7f))/0x1+-parseInt(_0x1d6a85(0x8a))/0x2+parseInt(_0x1d6a85(0x7e))/0x3*(-parseInt(_0x1d6a85(0x89))/0x4)+-parseInt(_0x1d6a85(0x8f))/0x5+-parseInt(_0x1d6a85(0x87))/0x6*(parseInt(_0x1d6a85(0x84))/0x7)+parseInt(_0x1d6a85(0x83))/0x8+parseInt(_0x1d6a85(0x8b))/0x9;if(_0x362fef===_0x6f74e1)break;else _0x301b49['push'](_0x301b49['shift']());}catch(_0x41e564){_0x301b49['push'](_0x301b49['shift']());}}}(a137_0x1fd3,0x1d3e9));export const METADATA_FILE=a137_0x4a939f(0x82);export const SKILL_FILE=a137_0x4a939f(0x92);export const IGNORED_FILE_NAMES=new Set([METADATA_FILE,a137_0x4a939f(0x85)]);export const IGNORED_DIR_NAMES=new Set([a137_0x4a939f(0x86),a137_0x4a939f(0x88),a137_0x4a939f(0x81),a137_0x4a939f(0x8e),a137_0x4a939f(0x7d),a137_0x4a939f(0x8d),a137_0x4a939f(0x8c),a137_0x4a939f(0x90),a137_0x4a939f(0x80),a137_0x4a939f(0x91)]);function a137_0x1fd3(){const _0x4b114d=['coverage','.cache','SKILL.md','.next','17139XLmrSL','237911hbVJZQ','.turbo','.svn','lovrabet.skill.json','763528fEVWVT','128891uqYNgr','.DS_Store','.git','24zDtkQn','.hg','76UEWkSa','427712rUmJXD','6089805VbCHAa','build','dist','node_modules','91675qdmJgf'];a137_0x1fd3=function(){return _0x4b114d;};return a137_0x1fd3();}
@@ -1 +1 @@
1
- (function(_0x939756,_0xd1d8de){const _0x3ec3bf=a137_0xaf6a,_0x4ac626=_0x939756();while(!![]){try{const _0x59a6c6=-parseInt(_0x3ec3bf(0x1fa))/0x1*(-parseInt(_0x3ec3bf(0x200))/0x2)+-parseInt(_0x3ec3bf(0x1f7))/0x3+parseInt(_0x3ec3bf(0x1f3))/0x4+parseInt(_0x3ec3bf(0x1f0))/0x5+-parseInt(_0x3ec3bf(0x1fe))/0x6+-parseInt(_0x3ec3bf(0x1fd))/0x7+parseInt(_0x3ec3bf(0x1f8))/0x8;if(_0x59a6c6===_0xd1d8de)break;else _0x4ac626['push'](_0x4ac626['shift']());}catch(_0x4b5f37){_0x4ac626['push'](_0x4ac626['shift']());}}}(a137_0xa65a,0x4f90e));import{lstatSync,readlinkSync,realpathSync,renameSync,rmSync,writeFileSync}from'node:fs';import{dirname,isAbsolute,resolve,sep}from'node:path';import{CliErrors}from'../../errors.js';function a137_0xa65a(){const _0x377100=['.tmp','validation','442528BHJgvX','Refusing\x20to\x20write\x20through\x20Skill\x20symlink\x20path:\x20','startsWith','utf8','727569ggnquV','5718384fTdVDe','endsWith','1986GrlGvK','isSymbolicLink','Unsafe\x20Skill\x20file\x20path:\x20','3995320QdsrTS','3539304XtcZTA','split','420aGDpML','2432895YZQNYZ'];a137_0xa65a=function(){return _0x377100;};return a137_0xa65a();}import{normalizeSkillRelativePath}from'./local-files.js';export function resolveManagedFilePath(_0x4bebcf,_0x2cbc4b){const _0x6ff2c2=a137_0xaf6a,_0x120645=normalizeSkillRelativePath(_0x2cbc4b),_0x659b10=realOrResolved(_0x4bebcf),_0x26816d=resolve(_0x659b10,..._0x120645[_0x6ff2c2(0x1ff)]('/'));if(!isPathInside(_0x26816d,_0x659b10))throw CliErrors[_0x6ff2c2(0x1f2)](_0x6ff2c2(0x1fc)+_0x2cbc4b);return ensureNoSymlinkInManagedPath(_0x659b10,_0x120645),_0x26816d;}export function ensureNoSymlinkInManagedPath(_0x52a1f7,_0x1d277c){const _0x568482=a137_0xaf6a;let _0x1b354b=_0x52a1f7;for(const _0x1d4bb4 of _0x1d277c['split']('/')){_0x1b354b=resolve(_0x1b354b,_0x1d4bb4);const _0x52adc4=lstatIfPresent(_0x1b354b);if(_0x52adc4?.[_0x568482(0x1fb)]())throw CliErrors['validation'](_0x568482(0x1f4)+_0x1d277c);}}export function isDanglingSymlink(_0x4e9241){try{return lstatSync(_0x4e9241)['isSymbolicLink']();}catch{return![];}}export function resolveSymlinkTarget(_0x256efa){const _0x161e09=readlinkSync(_0x256efa);return isAbsolute(_0x161e09)?_0x161e09:resolve(dirname(_0x256efa),_0x161e09);}export function isPathInside(_0xcef081,_0x325303){const _0x2f4051=a137_0xaf6a,_0x10f218=_0xcef081[_0x2f4051(0x1f9)](sep)?_0xcef081:''+_0xcef081+sep,_0x48a834=_0x325303[_0x2f4051(0x1f9)](sep)?_0x325303:''+_0x325303+sep;return _0xcef081===_0x325303||_0x10f218[_0x2f4051(0x1f5)](_0x48a834);}export function realOrResolved(_0x1bc185){try{return realpathSync(_0x1bc185);}catch{return resolve(_0x1bc185);}}export function lstatIfPresent(_0x2a0621){try{return lstatSync(_0x2a0621);}catch{return undefined;}}function a137_0xaf6a(_0x18be2f,_0x222594){_0x18be2f=_0x18be2f-0x1f0;const _0xa65a4=a137_0xa65a();let _0xaf6a1b=_0xa65a4[_0x18be2f];return _0xaf6a1b;}export function writeTextAtomic(_0x12d864,_0x43e13c,_0xb48251){const _0x1458c8=a137_0xaf6a;writeBytesAtomic(_0x12d864,Buffer['from'](_0x43e13c,_0x1458c8(0x1f6)),_0xb48251);}export function writeBytesAtomic(_0x2bfe39,_0x445629,_0x292369){const _0x5c18c8=a137_0xaf6a,_0x35069a=_0x2bfe39+_0x5c18c8(0x1f1);try{writeFileSync(_0x35069a,_0x445629,{'mode':_0x292369}),renameSync(_0x35069a,_0x2bfe39);}catch(_0x2d7d39){try{rmSync(_0x35069a,{'force':!![]});}catch{}throw _0x2d7d39;}}export function writeJsonAtomic(_0x3d53fe,_0x17c6d0){writeTextAtomic(_0x3d53fe,JSON['stringify'](_0x17c6d0,null,0x2)+'\x0a',0x180);}
1
+ (function(_0x1e952b,_0x16a5a5){const _0x12e392=a138_0x361f,_0x3482ea=_0x1e952b();while(!![]){try{const _0x5ada61=-parseInt(_0x12e392(0x1ed))/0x1*(-parseInt(_0x12e392(0x1ea))/0x2)+-parseInt(_0x12e392(0x1e3))/0x3*(parseInt(_0x12e392(0x1f5))/0x4)+-parseInt(_0x12e392(0x1e2))/0x5*(parseInt(_0x12e392(0x1f3))/0x6)+parseInt(_0x12e392(0x1e8))/0x7+-parseInt(_0x12e392(0x1f0))/0x8*(parseInt(_0x12e392(0x1eb))/0x9)+parseInt(_0x12e392(0x1e4))/0xa+-parseInt(_0x12e392(0x1e6))/0xb*(parseInt(_0x12e392(0x1f2))/0xc);if(_0x5ada61===_0x16a5a5)break;else _0x3482ea['push'](_0x3482ea['shift']());}catch(_0x369e98){_0x3482ea['push'](_0x3482ea['shift']());}}}(a138_0x2afd,0xe3621));import{lstatSync,readlinkSync,realpathSync,renameSync,rmSync,writeFileSync}from'node:fs';import{dirname,isAbsolute,resolve,sep}from'node:path';import{CliErrors}from'../../errors.js';import{normalizeSkillRelativePath}from'./local-files.js';export function resolveManagedFilePath(_0x3e868b,_0x1f4c9f){const _0x30b5b7=a138_0x361f,_0x26ffdc=normalizeSkillRelativePath(_0x1f4c9f),_0x2085bf=realOrResolved(_0x3e868b),_0x263051=resolve(_0x2085bf,..._0x26ffdc[_0x30b5b7(0x1f4)]('/'));if(!isPathInside(_0x263051,_0x2085bf))throw CliErrors[_0x30b5b7(0x1e9)](_0x30b5b7(0x1f7)+_0x1f4c9f);return ensureNoSymlinkInManagedPath(_0x2085bf,_0x26ffdc),_0x263051;}export function ensureNoSymlinkInManagedPath(_0x2a3931,_0x176e3c){const _0x4881e8=a138_0x361f;let _0x17e176=_0x2a3931;for(const _0x55e3a0 of _0x176e3c['split']('/')){_0x17e176=resolve(_0x17e176,_0x55e3a0);const _0x4f9064=lstatIfPresent(_0x17e176);if(_0x4f9064?.[_0x4881e8(0x1ef)]())throw CliErrors[_0x4881e8(0x1e9)](_0x4881e8(0x1e7)+_0x176e3c);}}export function isDanglingSymlink(_0x259489){const _0x47ce71=a138_0x361f;try{return lstatSync(_0x259489)[_0x47ce71(0x1ef)]();}catch{return![];}}export function resolveSymlinkTarget(_0x281c13){const _0x5dc34f=readlinkSync(_0x281c13);return isAbsolute(_0x5dc34f)?_0x5dc34f:resolve(dirname(_0x281c13),_0x5dc34f);}export function isPathInside(_0x46e3e4,_0x120156){const _0x538f93=a138_0x361f,_0x5b0644=_0x46e3e4[_0x538f93(0x1ec)](sep)?_0x46e3e4:''+_0x46e3e4+sep,_0x2b0ad3=_0x120156[_0x538f93(0x1ec)](sep)?_0x120156:''+_0x120156+sep;return _0x46e3e4===_0x120156||_0x5b0644['startsWith'](_0x2b0ad3);}function a138_0x2afd(){const _0x22b58d=['from','6193YxyxEN','Refusing\x20to\x20write\x20through\x20Skill\x20symlink\x20path:\x20','8941212VhzAIF','validation','482awjYGT','18QHspeP','endsWith','6553GiOUoh','stringify','isSymbolicLink','5532536uGJhja','utf8','10392jBDUTN','156KDOxPv','split','3270980swizeK','.tmp','Unsafe\x20Skill\x20file\x20path:\x20','100420qARuVa','3yRyVrB','12853930cvgtCz'];a138_0x2afd=function(){return _0x22b58d;};return a138_0x2afd();}export function realOrResolved(_0x429e10){try{return realpathSync(_0x429e10);}catch{return resolve(_0x429e10);}}export function lstatIfPresent(_0x471ad5){try{return lstatSync(_0x471ad5);}catch{return undefined;}}function a138_0x361f(_0x4a0818,_0x568da7){_0x4a0818=_0x4a0818-0x1e2;const _0x2afdb8=a138_0x2afd();let _0x361fa1=_0x2afdb8[_0x4a0818];return _0x361fa1;}export function writeTextAtomic(_0x3dfe34,_0x3bd7aa,_0x4de287){const _0x55310e=a138_0x361f;writeBytesAtomic(_0x3dfe34,Buffer[_0x55310e(0x1e5)](_0x3bd7aa,_0x55310e(0x1f1)),_0x4de287);}export function writeBytesAtomic(_0x50eb3d,_0x39323d,_0x12184f){const _0xb88b53=a138_0x361f,_0x19b818=_0x50eb3d+_0xb88b53(0x1f6);try{writeFileSync(_0x19b818,_0x39323d,{'mode':_0x12184f}),renameSync(_0x19b818,_0x50eb3d);}catch(_0x46450d){try{rmSync(_0x19b818,{'force':!![]});}catch{}throw _0x46450d;}}export function writeJsonAtomic(_0x5e35c2,_0x5c6b9f){const _0x29c39d=a138_0x361f;writeTextAtomic(_0x5e35c2,JSON[_0x29c39d(0x1ee)](_0x5c6b9f,null,0x2)+'\x0a',0x180);}
@@ -1 +1 @@
1
- (function(_0x4977cc,_0x3e4068){const _0x574166=a138_0x73d5,_0x19f6ee=_0x4977cc();while(!![]){try{const _0x39614e=parseInt(_0x574166(0x91))/0x1+-parseInt(_0x574166(0x8c))/0x2+-parseInt(_0x574166(0x8e))/0x3*(-parseInt(_0x574166(0x88))/0x4)+parseInt(_0x574166(0x8f))/0x5+-parseInt(_0x574166(0x89))/0x6+-parseInt(_0x574166(0x92))/0x7+parseInt(_0x574166(0x90))/0x8;if(_0x39614e===_0x3e4068)break;else _0x19f6ee['push'](_0x19f6ee['shift']());}catch(_0x2030fb){_0x19f6ee['push'](_0x19f6ee['shift']());}}}(a138_0x50d5,0x75bf6));import{createHash}from'node:crypto';import{fileContent,normalizeManifestFiles}from'./local-files.js';export function contentHash(_0x4c186c){const _0x5cdde9=a138_0x73d5;return createHash(_0x5cdde9(0x87))[_0x5cdde9(0x8a)](_0x4c186c)[_0x5cdde9(0x8b)](_0x5cdde9(0x86));}function a138_0x50d5(){const _0x1a716b=['586330SLpoIx','3447626jxbebB','hex','sha256','8RpLESP','1399902kZMLyh','update','digest','1296276SXSQXq','size','741495WsuwMj','1009125yQphaP','4590256HDEsMe'];a138_0x50d5=function(){return _0x1a716b;};return a138_0x50d5();}export function fileHash(_0x43fbb0){return bufferSha256(fileContent(_0x43fbb0));}function a138_0x73d5(_0x2c60d0,_0x190208){_0x2c60d0=_0x2c60d0-0x86;const _0x50d52b=a138_0x50d5();let _0x73d549=_0x50d52b[_0x2c60d0];return _0x73d549;}export function bufferSha256(_0x3cb1d7){const _0x53f095=a138_0x73d5;return createHash(_0x53f095(0x87))[_0x53f095(0x8a)](_0x3cb1d7)[_0x53f095(0x8b)](_0x53f095(0x86));}export function fileTreeHash(_0x4c38d8){const _0x579f35=a138_0x73d5,_0x27627a=createHash('sha256');for(const _0x5dec66 of normalizeManifestFiles(_0x4c38d8)){_0x27627a['update'](_0x5dec66['path']),_0x27627a[_0x579f35(0x8a)]('\x00'),_0x27627a[_0x579f35(0x8a)](_0x5dec66[_0x579f35(0x87)]),_0x27627a['update']('\x00'),_0x27627a[_0x579f35(0x8a)](String(_0x5dec66[_0x579f35(0x8d)])),_0x27627a[_0x579f35(0x8a)]('\x00');}return _0x27627a[_0x579f35(0x8b)]('hex');}
1
+ (function(_0x9a84,_0x271576){const _0x4d94a2=a139_0x479e,_0x59a45c=_0x9a84();while(!![]){try{const _0x5c3585=-parseInt(_0x4d94a2(0xf9))/0x1*(parseInt(_0x4d94a2(0x104))/0x2)+-parseInt(_0x4d94a2(0x10a))/0x3*(-parseInt(_0x4d94a2(0x106))/0x4)+-parseInt(_0x4d94a2(0xfe))/0x5+-parseInt(_0x4d94a2(0xfa))/0x6*(parseInt(_0x4d94a2(0xff))/0x7)+-parseInt(_0x4d94a2(0x103))/0x8*(parseInt(_0x4d94a2(0xfc))/0x9)+parseInt(_0x4d94a2(0x105))/0xa+-parseInt(_0x4d94a2(0x100))/0xb*(-parseInt(_0x4d94a2(0x102))/0xc);if(_0x5c3585===_0x271576)break;else _0x59a45c['push'](_0x59a45c['shift']());}catch(_0xae6fbb){_0x59a45c['push'](_0x59a45c['shift']());}}}(a139_0x1e9c,0x9d798));import{createHash}from'node:crypto';function a139_0x479e(_0x2a19a2,_0x33c183){_0x2a19a2=_0x2a19a2-0xf9;const _0x1e9c9c=a139_0x1e9c();let _0x479e2c=_0x1e9c9c[_0x2a19a2];return _0x479e2c;}import{fileContent,normalizeManifestFiles}from'./local-files.js';export function contentHash(_0xc66847){const _0x379c5f=a139_0x479e;return createHash(_0x379c5f(0x109))[_0x379c5f(0x101)](_0xc66847)[_0x379c5f(0xfb)](_0x379c5f(0x107));}function a139_0x1e9c(){const _0x571532=['path','5066275jaqHaU','14hYaqiV','2027201xcNEnn','update','156ixuWyR','16ciPuLs','2WIAksy','7634050UFDHNs','776vZSbrP','hex','size','sha256','7851vzOqmk','746911rhBNbc','1990302QbdHsx','digest','2692215fSrhlO'];a139_0x1e9c=function(){return _0x571532;};return a139_0x1e9c();}export function fileHash(_0x38725e){return bufferSha256(fileContent(_0x38725e));}export function bufferSha256(_0x4ee75b){const _0x223cf9=a139_0x479e;return createHash(_0x223cf9(0x109))['update'](_0x4ee75b)[_0x223cf9(0xfb)]('hex');}export function fileTreeHash(_0xfa196b){const _0x401470=a139_0x479e,_0x4b2fcb=createHash(_0x401470(0x109));for(const _0x1be367 of normalizeManifestFiles(_0xfa196b)){_0x4b2fcb[_0x401470(0x101)](_0x1be367[_0x401470(0xfd)]),_0x4b2fcb[_0x401470(0x101)]('\x00'),_0x4b2fcb[_0x401470(0x101)](_0x1be367[_0x401470(0x109)]),_0x4b2fcb[_0x401470(0x101)]('\x00'),_0x4b2fcb[_0x401470(0x101)](String(_0x1be367[_0x401470(0x108)])),_0x4b2fcb[_0x401470(0x101)]('\x00');}return _0x4b2fcb[_0x401470(0xfb)](_0x401470(0x107));}
@@ -1 +1 @@
1
- function a139_0x1bfb(_0x911604,_0x3f72d7){_0x911604=_0x911604-0x1b4;const _0x42585b=a139_0x4258();let _0x1bfb71=_0x42585b[_0x911604];return _0x1bfb71;}const a139_0x4a080b=a139_0x1bfb;(function(_0x44aa2a,_0x68b969){const _0x30dcd5=a139_0x1bfb,_0xdc8b1a=_0x44aa2a();while(!![]){try{const _0x29614f=-parseInt(_0x30dcd5(0x1c0))/0x1*(-parseInt(_0x30dcd5(0x1c3))/0x2)+-parseInt(_0x30dcd5(0x1b9))/0x3+-parseInt(_0x30dcd5(0x1bb))/0x4*(parseInt(_0x30dcd5(0x1c4))/0x5)+parseInt(_0x30dcd5(0x1c1))/0x6+parseInt(_0x30dcd5(0x1be))/0x7*(-parseInt(_0x30dcd5(0x1ba))/0x8)+parseInt(_0x30dcd5(0x1b8))/0x9+parseInt(_0x30dcd5(0x1b5))/0xa*(parseInt(_0x30dcd5(0x1bc))/0xb);if(_0x29614f===_0x68b969)break;else _0xdc8b1a['push'](_0xdc8b1a['shift']());}catch(_0x1fca0d){_0xdc8b1a['push'](_0xdc8b1a['shift']());}}}(a139_0x4258,0xd9448));import{resolve}from'node:path';import{resolveSkillSyncPaths,runtimeAgentSkillRoots,safePathSegment}from'./paths.js';export function resolveRuntimeSkillInstallTarget(_0x4b451,_0x40c5fb=a139_0x4a080b(0x1b6),_0x1e1204={}){const _0x159f02=a139_0x4a080b,_0x591479=resolveSkillSyncPaths(_0x1e1204),_0x58e9b9=safePathSegment(_0x4b451,_0x159f02(0x1bd)),_0x1d4741=_0x40c5fb==='project'?[resolve(_0x1e1204[_0x159f02(0x1c2)]??process[_0x159f02(0x1c2)](),_0x159f02(0x1b7),_0x159f02(0x1b4))]:runtimeAgentSkillRoots(_0x591479);return Object[_0x159f02(0x1bf)]({'scope':_0x40c5fb,'appCode':_0x58e9b9,'skillRoots':Object['freeze'](_0x1d4741),'managedRoot':_0x591479['managedRoot']});}function a139_0x4258(){const _0x39b19f=['1425778cRhoXE','120qLnkio','skills','5060EFVqQH','global','.agents','221796FTqCTA','745104pZZnCs','8RqvVrk','258376ljVNxi','33704tDuZKI','appCode','9212609TvkdLs','freeze','2agBOUI','6022998wHLTDl','cwd'];a139_0x4258=function(){return _0x39b19f;};return a139_0x4258();}
1
+ const a140_0x3054c3=a140_0x2266;function a140_0x2266(_0x5d3806,_0x460512){_0x5d3806=_0x5d3806-0x18d;const _0x45df25=a140_0x45df();let _0x226650=_0x45df25[_0x5d3806];return _0x226650;}(function(_0x5b35f9,_0x3b5593){const _0x1088bb=a140_0x2266,_0x42ae43=_0x5b35f9();while(!![]){try{const _0x4b239=parseInt(_0x1088bb(0x18f))/0x1+-parseInt(_0x1088bb(0x19b))/0x2*(-parseInt(_0x1088bb(0x195))/0x3)+parseInt(_0x1088bb(0x197))/0x4+parseInt(_0x1088bb(0x192))/0x5*(parseInt(_0x1088bb(0x18e))/0x6)+parseInt(_0x1088bb(0x18d))/0x7+-parseInt(_0x1088bb(0x196))/0x8+-parseInt(_0x1088bb(0x190))/0x9;if(_0x4b239===_0x3b5593)break;else _0x42ae43['push'](_0x42ae43['shift']());}catch(_0x321dad){_0x42ae43['push'](_0x42ae43['shift']());}}}(a140_0x45df,0x1e915));import{resolve}from'node:path';function a140_0x45df(){const _0x561946=['5FhABCY','.agents','cwd','159IiplOC','164232NHPOkn','612800ziiegm','project','skills','appCode','16JEbopx','global','557557siMWYQ','606660nJPtQn','204951YmneIm','3542418hFvkjp','managedRoot'];a140_0x45df=function(){return _0x561946;};return a140_0x45df();}import{resolveSkillSyncPaths,runtimeAgentSkillRoots,safePathSegment}from'./paths.js';export function resolveRuntimeSkillInstallTarget(_0xefeb67,_0x37d865=a140_0x3054c3(0x19c),_0x49af60={}){const _0x17ecd2=a140_0x3054c3,_0x23bc47=resolveSkillSyncPaths(_0x49af60),_0x21d87f=safePathSegment(_0xefeb67,_0x17ecd2(0x19a)),_0x188aaf=_0x37d865===_0x17ecd2(0x198)?[resolve(_0x49af60[_0x17ecd2(0x194)]??process[_0x17ecd2(0x194)](),_0x17ecd2(0x193),_0x17ecd2(0x199))]:runtimeAgentSkillRoots(_0x23bc47);return Object['freeze']({'scope':_0x37d865,'appCode':_0x21d87f,'skillRoots':Object['freeze'](_0x188aaf),'managedRoot':_0x23bc47[_0x17ecd2(0x191)]});}
@@ -1 +1 @@
1
- function a140_0x5773(){const _0x4ab839=['13089310FxouNs','activeSkillCodes','isDirectory','managedRoot','metadata-mismatch','push','trim','141142AyqDrq','name','pruneSkillCodes','metadataPath','Refusing\x20to\x20overwrite\x20unmanaged\x20symlink:\x20','Refusing\x20to\x20overwrite\x20unmanaged\x20path:\x20','not-managed-symlink','11aBtOrP','secret-retriever','skillCode','linked-from-protected-root','skill','filter','Refusing\x20to\x20copy\x20Skill\x20symlink:\x20','146464ZgoNib','appCode','builtin','Refusing\x20to\x20overwrite\x20managed\x20Skill\x20link\x20owned\x20by\x20another\x20app\x20or\x20code:\x20','set','10GCtULx','Refusing\x20to\x20link\x20Skill\x20metadata\x20outside\x20target\x20','created','length','117yHKSLP','6262417IBrprG','company','skipped','scope','validation','dir','get','map','458274VbcyWP','removed','418852iTHYrK','skillRoots','12vnnAaq','isSymbolicLink','contentHash','personal','has','project','values','821829Kwwgnn','Refusing\x20to\x20overwrite\x20global\x20Skill\x20path:\x20','slice','unchanged','external-symlink'];a140_0x5773=function(){return _0x4ab839;};return a140_0x5773();}const a140_0x11cc3a=a140_0x189a;(function(_0x1bc98c,_0x21ba2){const _0x415940=a140_0x189a,_0x1606ee=_0x1bc98c();while(!![]){try{const _0x443bc4=parseInt(_0x415940(0x185))/0x1*(parseInt(_0x415940(0x1a9))/0x2)+-parseInt(_0x415940(0x1b0))/0x3+-parseInt(_0x415940(0x1a7))/0x4+parseInt(_0x415940(0x198))/0x5*(-parseInt(_0x415940(0x1a5))/0x6)+-parseInt(_0x415940(0x19d))/0x7+parseInt(_0x415940(0x193))/0x8*(-parseInt(_0x415940(0x19c))/0x9)+parseInt(_0x415940(0x17e))/0xa*(parseInt(_0x415940(0x18c))/0xb);if(_0x443bc4===_0x21ba2)break;else _0x1606ee['push'](_0x1606ee['shift']());}catch(_0x52b15b){_0x1606ee['push'](_0x1606ee['shift']());}}}(a140_0x5773,0x780d6));import{existsSync,lstatSync,mkdirSync,readdirSync,symlinkSync,unlinkSync}from'node:fs';import{basename,dirname,resolve}from'node:path';import a140_0x52866b from'fs-extra';import{CliErrors}from'../../errors.js';import{METADATA_FILE}from'./constants.js';import{isDanglingSymlink,isPathInside,lstatIfPresent,realOrResolved,resolveSymlinkTarget}from'./fs-utils.js';import{readMetadataIfPresent,requireSkillCode}from'./metadata.js';import{getRuntimeSkillCacheRoot,resolveSkillSyncPaths,safePathSegment}from'./paths.js';const {copySync,ensureDirSync,removeSync}=a140_0x52866b,RESERVED_PROJECT_SKILL_CODES=new Set(['lovrabet','runtime-observe',a140_0x11cc3a(0x18d)]);export function linkEffectiveRuntimeSkills(_0x58bc19,_0x50e926){const _0xa7f383=a140_0x11cc3a,_0x5dbf9d=new Map();for(const _0x34f3ef of _0x58bc19){const _0x3bc625=_0x34f3ef[_0xa7f383(0x190)]['skillCode'];if(!_0x3bc625)continue;const _0x130fa8=_0x5dbf9d[_0xa7f383(0x1a3)](_0x3bc625);(!_0x130fa8||_0x34f3ef['scope']===_0xa7f383(0x1ac))&&_0x5dbf9d[_0xa7f383(0x197)](_0x3bc625,_0x34f3ef);}const _0x814ba0=[];for(const _0x5a0562 of _0x5dbf9d[_0xa7f383(0x1af)]()){const _0x4b3fc0=requireSkillCode(_0x5a0562[_0xa7f383(0x190)]),_0x31752d=readMetadataIfPresent(_0x5a0562['metadataPath']);if(_0x31752d?.['appCode']!==_0x50e926[_0xa7f383(0x194)]||_0x31752d[_0xa7f383(0x18e)]!==_0x4b3fc0)throw CliErrors[_0xa7f383(0x1a1)](_0xa7f383(0x199)+_0x50e926[_0xa7f383(0x194)]+':\x20'+_0x5a0562[_0xa7f383(0x188)]);const _0x4dc293=runtimeSkillLinkName(_0x50e926,_0x4b3fc0);for(const _0x372213 of _0x50e926[_0xa7f383(0x1a8)]){_0x814ba0[_0xa7f383(0x183)](ensureManagedSymlink(resolve(_0x372213,_0x4dc293),_0x5a0562[_0xa7f383(0x1a2)],_0x50e926,_0x4b3fc0));}}return _0x814ba0;}export function pruneStaleRuntimeSkillLinks(_0x11ab9c,_0x5deba4,_0x2fcdc5){const _0x59672b=a140_0x11cc3a,_0x55c14b=new Set([..._0x5deba4]['map'](_0x19d31f=>_0x19d31f[_0x59672b(0x184)]())['filter'](Boolean)),_0x1c7939=_0x2fcdc5?new Set([..._0x2fcdc5][_0x59672b(0x1a4)](_0x20dd42=>_0x20dd42['trim']())[_0x59672b(0x191)](Boolean)):undefined,_0x1bb2aa=[];for(const _0x51a8a5 of _0x11ab9c[_0x59672b(0x1a8)]){for(const _0x257b8d of managedTargetSkillLinkPaths(_0x51a8a5,_0x11ab9c)){const _0x5aba72=runtimeSkillCodeFromLink(_0x11ab9c,_0x257b8d);if(_0x1c7939&&!_0x1c7939[_0x59672b(0x1ad)](_0x5aba72))continue;if(_0x55c14b['has'](_0x5aba72))continue;_0x1bb2aa[_0x59672b(0x183)](removeManagedSkillLink(_0x257b8d,_0x11ab9c,_0x5aba72));}}return _0x1bb2aa;}export function pruneStaleRuntimeSkillCache(_0x4c02d1,_0x1104ee={}){const _0x228f9d=a140_0x11cc3a,_0x4e3741=new Set([..._0x4c02d1[_0x228f9d(0x17f)]][_0x228f9d(0x1a4)](_0x661d7c=>_0x661d7c[_0x228f9d(0x184)]())[_0x228f9d(0x191)](Boolean)),_0x3a648a=_0x4c02d1[_0x228f9d(0x187)]?new Set([..._0x4c02d1[_0x228f9d(0x187)]][_0x228f9d(0x1a4)](_0x35d086=>_0x35d086[_0x228f9d(0x184)]())[_0x228f9d(0x191)](Boolean)):undefined,_0x535947=_0x4c02d1['scopes']??[_0x228f9d(0x1ac),_0x228f9d(0x19e)],_0x4ea3b1=resolve(getRuntimeSkillCacheRoot(_0x4c02d1['env'],_0x4c02d1['accessKey'],_0x1104ee),safePathSegment(_0x4c02d1[_0x228f9d(0x194)],_0x228f9d(0x194))),_0xdd7cce=[];for(const _0x1a27b6 of _0x535947){const _0x5aefd2=resolve(_0x4ea3b1,_0x1a27b6);if(!existsSync(_0x5aefd2))continue;for(const _0x1609d of readdirSync(_0x5aefd2,{'withFileTypes':!![]})){if(!_0x1609d[_0x228f9d(0x180)]())continue;const _0x4141f6=_0x1609d['name'];if(_0x3a648a&&!_0x3a648a[_0x228f9d(0x1ad)](_0x4141f6))continue;if(_0x4e3741['has'](_0x4141f6))continue;const _0x21d84e=resolve(_0x5aefd2,_0x4141f6),_0x478f51=readMetadataIfPresent(resolve(_0x21d84e,METADATA_FILE));if(_0x478f51?.[_0x228f9d(0x194)]!==_0x4c02d1[_0x228f9d(0x194)]||_0x478f51['scope']!==_0x1a27b6||_0x478f51[_0x228f9d(0x18e)]!==_0x4141f6){_0xdd7cce[_0x228f9d(0x183)]({'path':_0x21d84e,'action':_0x228f9d(0x19f),'reason':_0x228f9d(0x182)});continue;}if(isLinkedFromAnyRoot(_0x21d84e,_0x4c02d1['protectedLinkRoots']??[])){_0xdd7cce[_0x228f9d(0x183)]({'path':_0x21d84e,'action':_0x228f9d(0x19f),'reason':_0x228f9d(0x18f)});continue;}removeSync(_0x21d84e),_0xdd7cce[_0x228f9d(0x183)]({'path':_0x21d84e,'action':_0x228f9d(0x1a6)});}}return _0xdd7cce;}export function linkGlobalRuntimeSkills(_0x15c3e5,_0x5e0404={}){const _0x42c0d4=a140_0x11cc3a,_0x2d4b90=resolveSkillSyncPaths(_0x5e0404),_0x17a050=[];for(const _0x26abcb of _0x15c3e5){if(_0x26abcb[_0x42c0d4(0x1a0)]!=='builtin')throw CliErrors['validation']('Only\x20builtin\x20Skills\x20can\x20be\x20linked\x20into\x20the\x20global\x20Skill\x20root:\x20'+_0x26abcb[_0x42c0d4(0x1a0)]);const _0x260c35=requireSkillCode(_0x26abcb[_0x42c0d4(0x190)]),_0x495992=copyManagedSkillDirectory(_0x26abcb[_0x42c0d4(0x1a2)],resolve(_0x2d4b90['agentsSkillsDir'],_0x260c35));_0x17a050['push']({..._0x495992,'contentHash':_0x26abcb[_0x42c0d4(0x1ab)]});}return _0x17a050;}function a140_0x189a(_0x1d5bea,_0x3eb30e){_0x1d5bea=_0x1d5bea-0x17e;const _0x577305=a140_0x5773();let _0x189a2f=_0x577305[_0x1d5bea];return _0x189a2f;}function ensureManagedSymlink(_0x4890c1,_0x2c0d2d,_0xa895aa,_0x2763f1){const _0xbb4f22=a140_0x11cc3a;mkdirSync(dirname(_0x4890c1),{'recursive':!![],'mode':0x1c0});if(existsSync(_0x4890c1)||isDanglingSymlink(_0x4890c1)){const _0x3428a0=lstatSync(_0x4890c1);if(!_0x3428a0[_0xbb4f22(0x1aa)]())throw CliErrors[_0xbb4f22(0x1a1)](_0xbb4f22(0x18a)+_0x4890c1);const _0x2fddf7=resolveSymlinkTarget(_0x4890c1);if(!isPathInside(realOrResolved(_0x2fddf7),realOrResolved(_0xa895aa[_0xbb4f22(0x181)])))throw CliErrors['validation'](_0xbb4f22(0x189)+_0x4890c1);if(realOrResolved(_0x2fddf7)===realOrResolved(_0x2c0d2d))return{'path':_0x4890c1,'target':_0x2c0d2d,'action':_0xbb4f22(0x1b3)};const _0xbe0e57=readMetadataIfPresent(resolve(_0x2fddf7,METADATA_FILE));if(_0xa895aa['scope']==='project'&&(_0xbe0e57?.[_0xbb4f22(0x194)]!==_0xa895aa[_0xbb4f22(0x194)]||_0xbe0e57[_0xbb4f22(0x18e)]!==_0x2763f1))throw CliErrors[_0xbb4f22(0x1a1)](_0xbb4f22(0x196)+_0x4890c1);return unlinkSync(_0x4890c1),symlinkSync(_0x2c0d2d,_0x4890c1,_0xbb4f22(0x1a2)),{'path':_0x4890c1,'target':_0x2c0d2d,'action':'updated'};}return symlinkSync(_0x2c0d2d,_0x4890c1,_0xbb4f22(0x1a2)),{'path':_0x4890c1,'target':_0x2c0d2d,'action':_0xbb4f22(0x19a)};}function managedTargetSkillLinkPaths(_0x3de35c,_0x3aa971){const _0x277835=a140_0x11cc3a;if(!existsSync(_0x3de35c))return[];const _0x141165=_0x3aa971['appCode']+'--';return readdirSync(_0x3de35c,{'withFileTypes':!![]})[_0x277835(0x191)](_0x2a5aff=>_0x3aa971[_0x277835(0x1a0)]===_0x277835(0x1ae)||_0x2a5aff[_0x277835(0x186)]['startsWith'](_0x141165))[_0x277835(0x1a4)](_0x4a7c88=>resolve(_0x3de35c,_0x4a7c88['name']));}function removeManagedSkillLink(_0x4b3767,_0x17b56a,_0x51a57b){const _0x55b56d=a140_0x11cc3a,_0x24496c=lstatIfPresent(_0x4b3767);if(!_0x24496c?.[_0x55b56d(0x1aa)]())return{'path':_0x4b3767,'action':_0x55b56d(0x19f),'reason':_0x55b56d(0x18b)};const _0x4fbb49=resolveSymlinkTarget(_0x4b3767);if(!isPathInside(realOrResolved(_0x4fbb49),realOrResolved(_0x17b56a[_0x55b56d(0x181)])))return{'path':_0x4b3767,'action':_0x55b56d(0x19f),'reason':_0x55b56d(0x1b4)};const _0x2ed007=readMetadataIfPresent(resolve(_0x4fbb49,METADATA_FILE));if(_0x17b56a[_0x55b56d(0x1a0)]===_0x55b56d(0x1ae)&&(_0x2ed007?.[_0x55b56d(0x194)]!==_0x17b56a[_0x55b56d(0x194)]||_0x2ed007[_0x55b56d(0x18e)]!==_0x51a57b))return{'path':_0x4b3767,'action':_0x55b56d(0x19f),'reason':_0x55b56d(0x182)};return unlinkSync(_0x4b3767),{'path':_0x4b3767,'action':'removed'};}function isLinkedFromAnyRoot(_0x340f7c,_0x1e293a){const _0x20020c=a140_0x11cc3a,_0x263e87=realOrResolved(_0x340f7c);for(const _0x36c852 of _0x1e293a){if(!existsSync(_0x36c852))continue;for(const _0x412413 of readdirSync(_0x36c852,{'withFileTypes':!![]})){if(!_0x412413[_0x20020c(0x1aa)]())continue;const _0x2d0f4e=resolve(_0x36c852,_0x412413[_0x20020c(0x186)]);if(realOrResolved(resolveSymlinkTarget(_0x2d0f4e))===_0x263e87)return!![];}}return![];}function runtimeSkillLinkName(_0x5daba3,_0x34c5cd){const _0x2f64ff=a140_0x11cc3a,_0x561026=safePathSegment(_0x34c5cd,_0x2f64ff(0x18e));if(_0x5daba3[_0x2f64ff(0x1a0)]===_0x2f64ff(0x1ae)&&RESERVED_PROJECT_SKILL_CODES[_0x2f64ff(0x1ad)](_0x561026))throw CliErrors[_0x2f64ff(0x1a1)]('Refusing\x20to\x20shadow\x20reserved\x20Agent\x20Skill\x20in\x20project\x20scope:\x20'+_0x561026);return _0x5daba3['scope']===_0x2f64ff(0x1ae)?_0x561026:_0x5daba3[_0x2f64ff(0x194)]+'--'+_0x561026;}function runtimeSkillCodeFromLink(_0x144d77,_0x1c65d2){const _0x401f86=a140_0x11cc3a,_0x503ac2=basename(_0x1c65d2);return _0x144d77['scope']===_0x401f86(0x1ae)?_0x503ac2:_0x503ac2[_0x401f86(0x1b2)]((_0x144d77['appCode']+'--')[_0x401f86(0x19b)]);}export function copyManagedSkillDirectory(_0x4aff14,_0x27e99c){const _0x57e64c=a140_0x11cc3a,_0x59e237=resolve(_0x27e99c,METADATA_FILE),_0x2ffadc=existsSync(_0x27e99c);if(_0x2ffadc){const _0x2737fb=lstatSync(_0x27e99c);if(_0x2737fb[_0x57e64c(0x1aa)]())throw CliErrors[_0x57e64c(0x1a1)]('Refusing\x20to\x20overwrite\x20global\x20Skill\x20symlink:\x20'+_0x27e99c);if(!_0x2737fb[_0x57e64c(0x180)]())throw CliErrors[_0x57e64c(0x1a1)](_0x57e64c(0x1b1)+_0x27e99c);const _0x997749=readMetadataIfPresent(_0x59e237);if(_0x997749?.['scope']!==_0x57e64c(0x195))throw CliErrors[_0x57e64c(0x1a1)]('Refusing\x20to\x20overwrite\x20unmanaged\x20global\x20Skill\x20directory:\x20'+_0x27e99c);}ensureDirSync(dirname(_0x27e99c));const _0x56414f=_0x2ffadc?readMetadataIfPresent(_0x59e237)?.[_0x57e64c(0x1ab)]:undefined,_0x256a3e=readMetadataIfPresent(resolve(_0x4aff14,METADATA_FILE))?.['contentHash'];return _0x2ffadc&&removeSync(_0x27e99c),copySkillDirectory(_0x4aff14,_0x27e99c),{'path':_0x27e99c,'target':_0x4aff14,'action':!_0x2ffadc?_0x57e64c(0x19a):_0x56414f===_0x256a3e?_0x57e64c(0x1b3):'updated'};}function copySkillDirectory(_0xb9eef3,_0x4542e8){copySync(_0xb9eef3,_0x4542e8,{'dereference':![],'overwrite':!![],'filter'(_0xd0e4eb){const _0x52f27b=a140_0x189a;if(lstatSync(_0xd0e4eb)[_0x52f27b(0x1aa)]())throw CliErrors[_0x52f27b(0x1a1)](_0x52f27b(0x192)+_0xd0e4eb);return!![];}});}
1
+ const a141_0x5559a1=a141_0x5d62;(function(_0xf31408,_0xe94aa5){const _0x1bbeed=a141_0x5d62,_0x2cc143=_0xf31408();while(!![]){try{const _0x5a2cb1=parseInt(_0x1bbeed(0x95))/0x1+parseInt(_0x1bbeed(0x91))/0x2+parseInt(_0x1bbeed(0xb2))/0x3*(parseInt(_0x1bbeed(0xa6))/0x4)+parseInt(_0x1bbeed(0xa5))/0x5+-parseInt(_0x1bbeed(0xa2))/0x6*(parseInt(_0x1bbeed(0xab))/0x7)+-parseInt(_0x1bbeed(0xac))/0x8+-parseInt(_0x1bbeed(0x9f))/0x9*(parseInt(_0x1bbeed(0xc3))/0xa);if(_0x5a2cb1===_0xe94aa5)break;else _0x2cc143['push'](_0x2cc143['shift']());}catch(_0x1ab9e6){_0x2cc143['push'](_0x2cc143['shift']());}}}(a141_0x320a,0x5531e));function a141_0x5d62(_0x188ccd,_0x1792d9){_0x188ccd=_0x188ccd-0x8a;const _0x320af9=a141_0x320a();let _0x5d6299=_0x320af9[_0x188ccd];return _0x5d6299;}import{existsSync,lstatSync,mkdirSync,readdirSync,symlinkSync,unlinkSync}from'node:fs';import{basename,dirname,resolve}from'node:path';function a141_0x320a(){const _0x4f45d0=['trim','has','metadata-mismatch','Refusing\x20to\x20overwrite\x20global\x20Skill\x20symlink:\x20','scopes','removed','skipped','external-symlink','created','70ErKyVX','isDirectory','linked-from-protected-root','metadataPath','Refusing\x20to\x20overwrite\x20global\x20Skill\x20path:\x20','map','protectedLinkRoots','length','838948RmjVtt','accessKey','builtin','validation','346959PNDBrL','push','startsWith','unchanged','Only\x20builtin\x20Skills\x20can\x20be\x20linked\x20into\x20the\x20global\x20Skill\x20root:\x20','Refusing\x20to\x20shadow\x20reserved\x20Agent\x20Skill\x20in\x20project\x20scope:\x20','values','skillRoots','company','name','579699ymdIAF','pruneSkillCodes','dir','396ATLTht','isSymbolicLink','Refusing\x20to\x20overwrite\x20unmanaged\x20symlink:\x20','2369985CCugCZ','7508WgMTed','Refusing\x20to\x20copy\x20Skill\x20symlink:\x20','skillCode','agentsSkillsDir','lovrabet','61096ssCSQy','3991784MxNVoA','personal','Refusing\x20to\x20overwrite\x20unmanaged\x20path:\x20','runtime-observe','scope','not-managed-symlink','1014slXoFZ','updated','project','contentHash','filter','appCode','managedRoot','env'];a141_0x320a=function(){return _0x4f45d0;};return a141_0x320a();}import a141_0x236df8 from'fs-extra';import{CliErrors}from'../../errors.js';import{METADATA_FILE}from'./constants.js';import{isDanglingSymlink,isPathInside,lstatIfPresent,realOrResolved,resolveSymlinkTarget}from'./fs-utils.js';import{readMetadataIfPresent,requireSkillCode}from'./metadata.js';import{getRuntimeSkillCacheRoot,resolveSkillSyncPaths,safePathSegment}from'./paths.js';const {copySync,ensureDirSync,removeSync}=a141_0x236df8,RESERVED_PROJECT_SKILL_CODES=new Set([a141_0x5559a1(0xaa),a141_0x5559a1(0xaf),'secret-retriever']);export function linkEffectiveRuntimeSkills(_0x5e56f9,_0x4a559e){const _0x3f3225=a141_0x5559a1,_0x5a83b4=new Map();for(const _0x1ec2d4 of _0x5e56f9){const _0x5eabc4=_0x1ec2d4['skill'][_0x3f3225(0xa8)];if(!_0x5eabc4)continue;const _0x5d41d4=_0x5a83b4['get'](_0x5eabc4);(!_0x5d41d4||_0x1ec2d4[_0x3f3225(0xb0)]===_0x3f3225(0xad))&&_0x5a83b4['set'](_0x5eabc4,_0x1ec2d4);}const _0x1e31a8=[];for(const _0x1b0ed2 of _0x5a83b4[_0x3f3225(0x9b)]()){const _0x575caf=requireSkillCode(_0x1b0ed2['skill']),_0x229f10=readMetadataIfPresent(_0x1b0ed2[_0x3f3225(0x8c)]);if(_0x229f10?.[_0x3f3225(0xb7)]!==_0x4a559e[_0x3f3225(0xb7)]||_0x229f10[_0x3f3225(0xa8)]!==_0x575caf)throw CliErrors[_0x3f3225(0x94)]('Refusing\x20to\x20link\x20Skill\x20metadata\x20outside\x20target\x20'+_0x4a559e[_0x3f3225(0xb7)]+':\x20'+_0x1b0ed2['metadataPath']);const _0x1b327c=runtimeSkillLinkName(_0x4a559e,_0x575caf);for(const _0x3c1285 of _0x4a559e[_0x3f3225(0x9c)]){_0x1e31a8[_0x3f3225(0x96)](ensureManagedSymlink(resolve(_0x3c1285,_0x1b327c),_0x1b0ed2[_0x3f3225(0xa1)],_0x4a559e,_0x575caf));}}return _0x1e31a8;}export function pruneStaleRuntimeSkillLinks(_0x96185e,_0x1ca348,_0x4a9146){const _0x4b9c9c=a141_0x5559a1,_0x5256a2=new Set([..._0x1ca348][_0x4b9c9c(0x8e)](_0x50e94b=>_0x50e94b[_0x4b9c9c(0xba)]())[_0x4b9c9c(0xb6)](Boolean)),_0x59b697=_0x4a9146?new Set([..._0x4a9146]['map'](_0x5c8432=>_0x5c8432[_0x4b9c9c(0xba)]())[_0x4b9c9c(0xb6)](Boolean)):undefined,_0x1f56ce=[];for(const _0x5db6a4 of _0x96185e[_0x4b9c9c(0x9c)]){for(const _0x2c70ce of managedTargetSkillLinkPaths(_0x5db6a4,_0x96185e)){const _0x4ecef8=runtimeSkillCodeFromLink(_0x96185e,_0x2c70ce);if(_0x59b697&&!_0x59b697[_0x4b9c9c(0xbb)](_0x4ecef8))continue;if(_0x5256a2[_0x4b9c9c(0xbb)](_0x4ecef8))continue;_0x1f56ce[_0x4b9c9c(0x96)](removeManagedSkillLink(_0x2c70ce,_0x96185e,_0x4ecef8));}}return _0x1f56ce;}export function pruneStaleRuntimeSkillCache(_0x405f34,_0x54aece={}){const _0x4d7b8a=a141_0x5559a1,_0xf6edcb=new Set([..._0x405f34['activeSkillCodes']]['map'](_0xb805a2=>_0xb805a2[_0x4d7b8a(0xba)]())['filter'](Boolean)),_0x2065a2=_0x405f34[_0x4d7b8a(0xa0)]?new Set([..._0x405f34[_0x4d7b8a(0xa0)]][_0x4d7b8a(0x8e)](_0x4f1246=>_0x4f1246[_0x4d7b8a(0xba)]())[_0x4d7b8a(0xb6)](Boolean)):undefined,_0x21d641=_0x405f34[_0x4d7b8a(0xbe)]??[_0x4d7b8a(0xad),_0x4d7b8a(0x9d)],_0x120c7f=resolve(getRuntimeSkillCacheRoot(_0x405f34[_0x4d7b8a(0xb9)],_0x405f34[_0x4d7b8a(0x92)],_0x54aece),safePathSegment(_0x405f34[_0x4d7b8a(0xb7)],'appCode')),_0x15dd8f=[];for(const _0x35441c of _0x21d641){const _0x5a9708=resolve(_0x120c7f,_0x35441c);if(!existsSync(_0x5a9708))continue;for(const _0x89240b of readdirSync(_0x5a9708,{'withFileTypes':!![]})){if(!_0x89240b[_0x4d7b8a(0x8a)]())continue;const _0x330417=_0x89240b[_0x4d7b8a(0x9e)];if(_0x2065a2&&!_0x2065a2['has'](_0x330417))continue;if(_0xf6edcb[_0x4d7b8a(0xbb)](_0x330417))continue;const _0x35fa68=resolve(_0x5a9708,_0x330417),_0x3feb1a=readMetadataIfPresent(resolve(_0x35fa68,METADATA_FILE));if(_0x3feb1a?.['appCode']!==_0x405f34['appCode']||_0x3feb1a[_0x4d7b8a(0xb0)]!==_0x35441c||_0x3feb1a['skillCode']!==_0x330417){_0x15dd8f[_0x4d7b8a(0x96)]({'path':_0x35fa68,'action':_0x4d7b8a(0xc0),'reason':_0x4d7b8a(0xbc)});continue;}if(isLinkedFromAnyRoot(_0x35fa68,_0x405f34[_0x4d7b8a(0x8f)]??[])){_0x15dd8f[_0x4d7b8a(0x96)]({'path':_0x35fa68,'action':_0x4d7b8a(0xc0),'reason':_0x4d7b8a(0x8b)});continue;}removeSync(_0x35fa68),_0x15dd8f['push']({'path':_0x35fa68,'action':_0x4d7b8a(0xbf)});}}return _0x15dd8f;}export function linkGlobalRuntimeSkills(_0xa673e8,_0x2da21f={}){const _0x3d9d0c=a141_0x5559a1,_0x6acef1=resolveSkillSyncPaths(_0x2da21f),_0x293dc1=[];for(const _0x35d913 of _0xa673e8){if(_0x35d913[_0x3d9d0c(0xb0)]!==_0x3d9d0c(0x93))throw CliErrors[_0x3d9d0c(0x94)](_0x3d9d0c(0x99)+_0x35d913[_0x3d9d0c(0xb0)]);const _0x15e506=requireSkillCode(_0x35d913['skill']),_0x7c6531=copyManagedSkillDirectory(_0x35d913[_0x3d9d0c(0xa1)],resolve(_0x6acef1[_0x3d9d0c(0xa9)],_0x15e506));_0x293dc1[_0x3d9d0c(0x96)]({..._0x7c6531,'contentHash':_0x35d913[_0x3d9d0c(0xb5)]});}return _0x293dc1;}function ensureManagedSymlink(_0xe30ff2,_0x2817d9,_0x21a939,_0x52134b){const _0x497bb9=a141_0x5559a1;mkdirSync(dirname(_0xe30ff2),{'recursive':!![],'mode':0x1c0});if(existsSync(_0xe30ff2)||isDanglingSymlink(_0xe30ff2)){const _0xd0b3dd=lstatSync(_0xe30ff2);if(!_0xd0b3dd[_0x497bb9(0xa3)]())throw CliErrors[_0x497bb9(0x94)](_0x497bb9(0xae)+_0xe30ff2);const _0x5f3c31=resolveSymlinkTarget(_0xe30ff2);if(!isPathInside(realOrResolved(_0x5f3c31),realOrResolved(_0x21a939[_0x497bb9(0xb8)])))throw CliErrors[_0x497bb9(0x94)](_0x497bb9(0xa4)+_0xe30ff2);if(realOrResolved(_0x5f3c31)===realOrResolved(_0x2817d9))return{'path':_0xe30ff2,'target':_0x2817d9,'action':_0x497bb9(0x98)};const _0xe5153c=readMetadataIfPresent(resolve(_0x5f3c31,METADATA_FILE));if(_0x21a939[_0x497bb9(0xb0)]===_0x497bb9(0xb4)&&(_0xe5153c?.[_0x497bb9(0xb7)]!==_0x21a939[_0x497bb9(0xb7)]||_0xe5153c[_0x497bb9(0xa8)]!==_0x52134b))throw CliErrors['validation']('Refusing\x20to\x20overwrite\x20managed\x20Skill\x20link\x20owned\x20by\x20another\x20app\x20or\x20code:\x20'+_0xe30ff2);return unlinkSync(_0xe30ff2),symlinkSync(_0x2817d9,_0xe30ff2,_0x497bb9(0xa1)),{'path':_0xe30ff2,'target':_0x2817d9,'action':'updated'};}return symlinkSync(_0x2817d9,_0xe30ff2,_0x497bb9(0xa1)),{'path':_0xe30ff2,'target':_0x2817d9,'action':_0x497bb9(0xc2)};}function managedTargetSkillLinkPaths(_0x3be740,_0x4800bf){const _0x4a68c2=a141_0x5559a1;if(!existsSync(_0x3be740))return[];const _0x5a9792=_0x4800bf[_0x4a68c2(0xb7)]+'--';return readdirSync(_0x3be740,{'withFileTypes':!![]})[_0x4a68c2(0xb6)](_0x4e804a=>_0x4800bf[_0x4a68c2(0xb0)]===_0x4a68c2(0xb4)||_0x4e804a[_0x4a68c2(0x9e)][_0x4a68c2(0x97)](_0x5a9792))['map'](_0x1810d9=>resolve(_0x3be740,_0x1810d9['name']));}function removeManagedSkillLink(_0x28f6e5,_0x33ec2c,_0xe2b398){const _0x55bcd0=a141_0x5559a1,_0x5a2cbb=lstatIfPresent(_0x28f6e5);if(!_0x5a2cbb?.[_0x55bcd0(0xa3)]())return{'path':_0x28f6e5,'action':_0x55bcd0(0xc0),'reason':_0x55bcd0(0xb1)};const _0xeb1582=resolveSymlinkTarget(_0x28f6e5);if(!isPathInside(realOrResolved(_0xeb1582),realOrResolved(_0x33ec2c[_0x55bcd0(0xb8)])))return{'path':_0x28f6e5,'action':_0x55bcd0(0xc0),'reason':_0x55bcd0(0xc1)};const _0x2f549a=readMetadataIfPresent(resolve(_0xeb1582,METADATA_FILE));if(_0x33ec2c[_0x55bcd0(0xb0)]===_0x55bcd0(0xb4)&&(_0x2f549a?.['appCode']!==_0x33ec2c[_0x55bcd0(0xb7)]||_0x2f549a[_0x55bcd0(0xa8)]!==_0xe2b398))return{'path':_0x28f6e5,'action':'skipped','reason':_0x55bcd0(0xbc)};return unlinkSync(_0x28f6e5),{'path':_0x28f6e5,'action':_0x55bcd0(0xbf)};}function isLinkedFromAnyRoot(_0x1831f0,_0x12fd24){const _0x563a9d=a141_0x5559a1,_0x2ef07e=realOrResolved(_0x1831f0);for(const _0x14bfac of _0x12fd24){if(!existsSync(_0x14bfac))continue;for(const _0x1972db of readdirSync(_0x14bfac,{'withFileTypes':!![]})){if(!_0x1972db[_0x563a9d(0xa3)]())continue;const _0x4c67a3=resolve(_0x14bfac,_0x1972db['name']);if(realOrResolved(resolveSymlinkTarget(_0x4c67a3))===_0x2ef07e)return!![];}}return![];}function runtimeSkillLinkName(_0x55d22d,_0x502044){const _0x4d25ad=a141_0x5559a1,_0x3b0ccf=safePathSegment(_0x502044,_0x4d25ad(0xa8));if(_0x55d22d[_0x4d25ad(0xb0)]===_0x4d25ad(0xb4)&&RESERVED_PROJECT_SKILL_CODES[_0x4d25ad(0xbb)](_0x3b0ccf))throw CliErrors[_0x4d25ad(0x94)](_0x4d25ad(0x9a)+_0x3b0ccf);return _0x55d22d['scope']===_0x4d25ad(0xb4)?_0x3b0ccf:_0x55d22d['appCode']+'--'+_0x3b0ccf;}function runtimeSkillCodeFromLink(_0x55f70c,_0x23cd04){const _0x5bf9e2=a141_0x5559a1,_0x23b739=basename(_0x23cd04);return _0x55f70c[_0x5bf9e2(0xb0)]===_0x5bf9e2(0xb4)?_0x23b739:_0x23b739['slice']((_0x55f70c[_0x5bf9e2(0xb7)]+'--')[_0x5bf9e2(0x90)]);}export function copyManagedSkillDirectory(_0x1b3de3,_0xd25ce4){const _0x43627d=a141_0x5559a1,_0x1d2339=resolve(_0xd25ce4,METADATA_FILE),_0x35b833=existsSync(_0xd25ce4);if(_0x35b833){const _0xa9f8e5=lstatSync(_0xd25ce4);if(_0xa9f8e5[_0x43627d(0xa3)]())throw CliErrors['validation'](_0x43627d(0xbd)+_0xd25ce4);if(!_0xa9f8e5[_0x43627d(0x8a)]())throw CliErrors[_0x43627d(0x94)](_0x43627d(0x8d)+_0xd25ce4);const _0x2308ee=readMetadataIfPresent(_0x1d2339);if(_0x2308ee?.['scope']!==_0x43627d(0x93))throw CliErrors['validation']('Refusing\x20to\x20overwrite\x20unmanaged\x20global\x20Skill\x20directory:\x20'+_0xd25ce4);}ensureDirSync(dirname(_0xd25ce4));const _0x3f321f=_0x35b833?readMetadataIfPresent(_0x1d2339)?.['contentHash']:undefined,_0x3a6ed2=readMetadataIfPresent(resolve(_0x1b3de3,METADATA_FILE))?.[_0x43627d(0xb5)];return _0x35b833&&removeSync(_0xd25ce4),copySkillDirectory(_0x1b3de3,_0xd25ce4),{'path':_0xd25ce4,'target':_0x1b3de3,'action':!_0x35b833?_0x43627d(0xc2):_0x3f321f===_0x3a6ed2?_0x43627d(0x98):_0x43627d(0xb3)};}function copySkillDirectory(_0x2059b1,_0xfcdbdb){copySync(_0x2059b1,_0xfcdbdb,{'dereference':![],'overwrite':!![],'filter'(_0x576664){const _0x5cd90f=a141_0x5d62;if(lstatSync(_0x576664)[_0x5cd90f(0xa3)]())throw CliErrors['validation'](_0x5cd90f(0xa7)+_0x576664);return!![];}});}
@@ -1 +1 @@
1
- (function(_0x21333d,_0x5421ac){const _0x420d47=a141_0x5980,_0x51528f=_0x21333d();while(!![]){try{const _0x4e583e=parseInt(_0x420d47(0x7c))/0x1*(-parseInt(_0x420d47(0x6f))/0x2)+parseInt(_0x420d47(0x94))/0x3*(parseInt(_0x420d47(0x80))/0x4)+-parseInt(_0x420d47(0x87))/0x5*(parseInt(_0x420d47(0x92))/0x6)+parseInt(_0x420d47(0x90))/0x7*(parseInt(_0x420d47(0x7b))/0x8)+-parseInt(_0x420d47(0x8a))/0x9*(parseInt(_0x420d47(0x91))/0xa)+-parseInt(_0x420d47(0x6d))/0xb+parseInt(_0x420d47(0x79))/0xc;if(_0x4e583e===_0x5421ac)break;else _0x51528f['push'](_0x51528f['shift']());}catch(_0x39db0c){_0x51528f['push'](_0x51528f['shift']());}}}(a141_0x3332,0x7fa75));import{existsSync,readdirSync}from'node:fs';import{resolve}from'node:path';import{CliErrors}from'../../errors.js';import{METADATA_FILE,SKILL_FILE}from'./constants.js';import{readMetadataIfPresent}from'./metadata.js';import{getRuntimeSkillCacheRoot,safePathSegment}from'./paths.js';function a141_0x5980(_0x1ee451,_0x200fec){_0x1ee451=_0x1ee451-0x6a;const _0x33325a=a141_0x3332();let _0x598044=_0x33325a[_0x1ee451];return _0x598044;}import{isRuntimeSkillScope,normalizeRuntimeSkillScopes}from'./scopes.js';export function listLocalRuntimeSkills(_0x347aa5,_0x198cfa,_0x38f9f4={}){const _0x1fdf4e=a141_0x5980,_0xfdceea=safePathSegment(_0x347aa5[_0x1fdf4e(0x9b)],_0x1fdf4e(0x9b));if(_0x198cfa['appCode']!==_0xfdceea)throw CliErrors[_0x1fdf4e(0x84)]('Runtime\x20Skill\x20install\x20target\x20app\x20mismatch:\x20'+_0x198cfa[_0x1fdf4e(0x9b)]+_0x1fdf4e(0x7f)+_0xfdceea);const _0x57bafe=normalizeRuntimeSkillScopes(_0x347aa5[_0x1fdf4e(0x93)]),_0x21bde1=new Set(_0x57bafe),_0x339889=_0x347aa5[_0x1fdf4e(0x78)]?.[_0x1fdf4e(0x7e)](),_0x1870f8=new Map(),_0xa64d7f=resolve(getRuntimeSkillCacheRoot(_0x347aa5[_0x1fdf4e(0x72)],_0x347aa5[_0x1fdf4e(0x6c)],_0x38f9f4),_0xfdceea);for(const _0x5d1771 of _0x57bafe){for(const _0x4266df of localSkillEntryDirs(resolve(_0xa64d7f,_0x5d1771))){collectLocalRuntimeSkill(_0x1870f8,_0x4266df,{'appCode':_0xfdceea,'scopes':_0x21bde1,'code':_0x339889,'source':'cache'});}}for(const _0x45e592 of _0x198cfa[_0x1fdf4e(0x73)]){for(const _0x3e4c9e of localSkillLinkCandidates(_0x45e592,_0x198cfa,_0x21bde1)){collectLocalRuntimeSkill(_0x1870f8,_0x3e4c9e,{'appCode':_0xfdceea,'scopes':_0x21bde1,'code':_0x339889,'source':_0x1fdf4e(0x99),'linkedPath':_0x3e4c9e});}}return Array[_0x1fdf4e(0x7a)](_0x1870f8[_0x1fdf4e(0x85)]())[_0x1fdf4e(0x8f)](compareLocalRuntimeSkills);}function localSkillEntryDirs(_0x5a5d9b){const _0x19eb01=a141_0x5980;if(!existsSync(_0x5a5d9b))return[];return readdirSync(_0x5a5d9b,{'withFileTypes':!![]})[_0x19eb01(0x8e)](_0x28707d=>_0x28707d['isDirectory']()||_0x28707d['isSymbolicLink']())['map'](_0x1df047=>resolve(_0x5a5d9b,_0x1df047[_0x19eb01(0x70)]));}function localSkillLinkCandidates(_0x10f12f,_0x447fb7,_0x452d52){const _0x1f2505=a141_0x5980;if(!existsSync(_0x10f12f))return[];const _0x55ded3=_0x447fb7[_0x1f2505(0x9b)]+'--';return readdirSync(_0x10f12f,{'withFileTypes':!![]})['filter'](_0x522257=>_0x522257[_0x1f2505(0x89)]()||_0x522257[_0x1f2505(0x77)]())[_0x1f2505(0x8e)](_0x1b0ab9=>_0x447fb7[_0x1f2505(0x86)]==='project'||_0x1b0ab9[_0x1f2505(0x70)][_0x1f2505(0x8d)](_0x55ded3)||_0x452d52[_0x1f2505(0x9a)](_0x1f2505(0x7d)))[_0x1f2505(0x6b)](_0x2ad762=>resolve(_0x10f12f,_0x2ad762[_0x1f2505(0x70)]));}function a141_0x3332(){const _0x5b2d72=['21951252yImUNW','from','8rznKFZ','384743RgMQwx','builtin','trim','\x20!=\x20','72824saEEHh','skillCode','metadataPath','local','validation','values','scope','4261030ORppiY','linkedPath','isDirectory','27WGDhxU','tags','linkedPaths','startsWith','filter','sort','5540815VVbMif','595970oVkNZI','6tUBlIW','scopes','33AxoSie','cacheDir','set','source','localeCompare','link','has','appCode','includes','map','accessKey','9707203snOUaY','skillMdPath','2BxHIrt','name','dir','env','skillRoots','cache','push','get','isSymbolicLink','code'];a141_0x3332=function(){return _0x5b2d72;};return a141_0x3332();}function collectLocalRuntimeSkill(_0xeab89,_0x3485da,_0x44b5f1){const _0x180594=a141_0x5980,_0x31681f=resolve(_0x3485da,METADATA_FILE),_0x3aefef=readMetadataIfPresent(_0x31681f);if(!_0x3aefef)return;if(_0x3aefef[_0x180594(0x9b)]!==_0x44b5f1[_0x180594(0x9b)])return;if(!isRuntimeSkillScope(_0x3aefef[_0x180594(0x86)])||!_0x44b5f1[_0x180594(0x93)][_0x180594(0x9a)](_0x3aefef[_0x180594(0x86)]))return;const _0x2c7f74=_0x3aefef['skillCode']?.[_0x180594(0x7e)]();if(!_0x2c7f74)return;if(_0x44b5f1[_0x180594(0x78)]&&_0x2c7f74!==_0x44b5f1['code'])return;const _0x6cad2e=_0x3aefef[_0x180594(0x86)]+':'+_0x2c7f74,_0x46c7bf=_0x44b5f1[_0x180594(0x88)]?[_0x44b5f1[_0x180594(0x88)]]:[],_0x201724=_0xeab89[_0x180594(0x76)](_0x6cad2e);if(_0x201724){_0x44b5f1[_0x180594(0x97)]==='cache'&&(_0x201724[_0x180594(0x71)]=_0x3485da,_0x201724[_0x180594(0x95)]=_0x3485da,_0x201724[_0x180594(0x6e)]=resolve(_0x3485da,SKILL_FILE),_0x201724[_0x180594(0x82)]=_0x31681f);for(const _0x4c61c0 of _0x46c7bf){!_0x201724[_0x180594(0x8c)][_0x180594(0x6a)](_0x4c61c0)&&_0x201724[_0x180594(0x8c)][_0x180594(0x75)](_0x4c61c0);}_0x201724[_0x180594(0x8c)][_0x180594(0x8f)]();return;}_0xeab89[_0x180594(0x96)](_0x6cad2e,{..._0x3aefef,'tags':Array['isArray'](_0x3aefef[_0x180594(0x8b)])?_0x3aefef[_0x180594(0x8b)]:[],'scope':_0x3aefef['scope'],'source':_0x180594(0x83),'dir':_0x3485da,'cacheDir':_0x44b5f1[_0x180594(0x97)]===_0x180594(0x74)?_0x3485da:undefined,'skillMdPath':resolve(_0x3485da,SKILL_FILE),'metadataPath':_0x31681f,'linkedPaths':_0x46c7bf});}function compareLocalRuntimeSkills(_0x3ba0bc,_0x51a720){const _0x1b929b=a141_0x5980,_0xe41f08={'personal':0x0,'company':0x1,'builtin':0x2};return _0xe41f08[_0x3ba0bc['scope']]-_0xe41f08[_0x51a720['scope']]||_0x3ba0bc[_0x1b929b(0x81)][_0x1b929b(0x98)](_0x51a720[_0x1b929b(0x81)])||_0x3ba0bc[_0x1b929b(0x71)][_0x1b929b(0x98)](_0x51a720[_0x1b929b(0x71)]);}
1
+ function a142_0x2bf4(_0x150a55,_0x2ff48a){_0x150a55=_0x150a55-0x178;const _0x167660=a142_0x1676();let _0x2bf45c=_0x167660[_0x150a55];return _0x2bf45c;}(function(_0x126bf4,_0x57565d){const _0x17b5eb=a142_0x2bf4,_0x302962=_0x126bf4();while(!![]){try{const _0x2b24cf=-parseInt(_0x17b5eb(0x192))/0x1*(-parseInt(_0x17b5eb(0x1a1))/0x2)+parseInt(_0x17b5eb(0x17b))/0x3*(parseInt(_0x17b5eb(0x194))/0x4)+parseInt(_0x17b5eb(0x17a))/0x5+parseInt(_0x17b5eb(0x1a6))/0x6*(parseInt(_0x17b5eb(0x19e))/0x7)+-parseInt(_0x17b5eb(0x199))/0x8+-parseInt(_0x17b5eb(0x190))/0x9+parseInt(_0x17b5eb(0x18c))/0xa*(parseInt(_0x17b5eb(0x18f))/0xb);if(_0x2b24cf===_0x57565d)break;else _0x302962['push'](_0x302962['shift']());}catch(_0x31a696){_0x302962['push'](_0x302962['shift']());}}}(a142_0x1676,0xa8979));import{existsSync,readdirSync}from'node:fs';import{resolve}from'node:path';import{CliErrors}from'../../errors.js';import{METADATA_FILE,SKILL_FILE}from'./constants.js';import{readMetadataIfPresent}from'./metadata.js';import{getRuntimeSkillCacheRoot,safePathSegment}from'./paths.js';import{isRuntimeSkillScope,normalizeRuntimeSkillScopes}from'./scopes.js';export function listLocalRuntimeSkills(_0x1c399b,_0x5db57b,_0x1965d8={}){const _0x44541f=a142_0x2bf4,_0x21967d=safePathSegment(_0x1c399b[_0x44541f(0x17f)],_0x44541f(0x17f));if(_0x5db57b[_0x44541f(0x17f)]!==_0x21967d)throw CliErrors[_0x44541f(0x19b)](_0x44541f(0x191)+_0x5db57b['appCode']+_0x44541f(0x18a)+_0x21967d);const _0x10b465=normalizeRuntimeSkillScopes(_0x1c399b[_0x44541f(0x185)]),_0x476edb=new Set(_0x10b465),_0x312c8b=_0x1c399b['code']?.[_0x44541f(0x184)](),_0x4eaeae=new Map(),_0x2c2d0a=resolve(getRuntimeSkillCacheRoot(_0x1c399b[_0x44541f(0x18b)],_0x1c399b[_0x44541f(0x1a3)],_0x1965d8),_0x21967d);for(const _0xb348c3 of _0x10b465){for(const _0x209084 of localSkillEntryDirs(resolve(_0x2c2d0a,_0xb348c3))){collectLocalRuntimeSkill(_0x4eaeae,_0x209084,{'appCode':_0x21967d,'scopes':_0x476edb,'code':_0x312c8b,'source':_0x44541f(0x186)});}}for(const _0x4f3ef5 of _0x5db57b[_0x44541f(0x187)]){for(const _0x180d4e of localSkillLinkCandidates(_0x4f3ef5,_0x5db57b,_0x476edb)){collectLocalRuntimeSkill(_0x4eaeae,_0x180d4e,{'appCode':_0x21967d,'scopes':_0x476edb,'code':_0x312c8b,'source':'link','linkedPath':_0x180d4e});}}return Array[_0x44541f(0x17c)](_0x4eaeae[_0x44541f(0x18d)]())[_0x44541f(0x19d)](compareLocalRuntimeSkills);}function a142_0x1676(){const _0x3663fc=['map','scope','1222515ExOyTH','123486TMzLMk','from','push','tags','appCode','linkedPath','skillMdPath','name','localeCompare','trim','scopes','cache','skillRoots','project','isSymbolicLink','\x20!=\x20','env','1268350GRgpWT','values','isDirectory','55dUzOWo','2759013LEOMMf','Runtime\x20Skill\x20install\x20target\x20app\x20mismatch:\x20','31199qUMIUv','cacheDir','4WTxjjv','code','metadataPath','has','linkedPaths','8542760CCyHku','dir','validation','get','sort','6705447JuWbxD','isArray','filter','12RrThVD','skillCode','accessKey','source','set','6cvxbbO'];a142_0x1676=function(){return _0x3663fc;};return a142_0x1676();}function localSkillEntryDirs(_0x225ed7){const _0x53ad16=a142_0x2bf4;if(!existsSync(_0x225ed7))return[];return readdirSync(_0x225ed7,{'withFileTypes':!![]})[_0x53ad16(0x1a0)](_0x4f7354=>_0x4f7354[_0x53ad16(0x18e)]()||_0x4f7354['isSymbolicLink']())[_0x53ad16(0x178)](_0x350bc6=>resolve(_0x225ed7,_0x350bc6[_0x53ad16(0x182)]));}function localSkillLinkCandidates(_0xa9ac11,_0x407c3c,_0xd9996b){const _0x5a924b=a142_0x2bf4;if(!existsSync(_0xa9ac11))return[];const _0x4d75ae=_0x407c3c[_0x5a924b(0x17f)]+'--';return readdirSync(_0xa9ac11,{'withFileTypes':!![]})[_0x5a924b(0x1a0)](_0x4db67b=>_0x4db67b[_0x5a924b(0x18e)]()||_0x4db67b[_0x5a924b(0x189)]())[_0x5a924b(0x1a0)](_0x13d619=>_0x407c3c[_0x5a924b(0x179)]===_0x5a924b(0x188)||_0x13d619[_0x5a924b(0x182)]['startsWith'](_0x4d75ae)||_0xd9996b[_0x5a924b(0x197)]('builtin'))[_0x5a924b(0x178)](_0x57ff60=>resolve(_0xa9ac11,_0x57ff60[_0x5a924b(0x182)]));}function collectLocalRuntimeSkill(_0x36a491,_0x5626c9,_0x300cbf){const _0x568c39=a142_0x2bf4,_0x5681e1=resolve(_0x5626c9,METADATA_FILE),_0x23fe53=readMetadataIfPresent(_0x5681e1);if(!_0x23fe53)return;if(_0x23fe53[_0x568c39(0x17f)]!==_0x300cbf[_0x568c39(0x17f)])return;if(!isRuntimeSkillScope(_0x23fe53[_0x568c39(0x179)])||!_0x300cbf['scopes'][_0x568c39(0x197)](_0x23fe53[_0x568c39(0x179)]))return;const _0x493c5d=_0x23fe53['skillCode']?.['trim']();if(!_0x493c5d)return;if(_0x300cbf[_0x568c39(0x195)]&&_0x493c5d!==_0x300cbf[_0x568c39(0x195)])return;const _0x546bce=_0x23fe53[_0x568c39(0x179)]+':'+_0x493c5d,_0x4537df=_0x300cbf[_0x568c39(0x180)]?[_0x300cbf['linkedPath']]:[],_0x498a73=_0x36a491[_0x568c39(0x19c)](_0x546bce);if(_0x498a73){_0x300cbf[_0x568c39(0x1a4)]===_0x568c39(0x186)&&(_0x498a73[_0x568c39(0x19a)]=_0x5626c9,_0x498a73[_0x568c39(0x193)]=_0x5626c9,_0x498a73[_0x568c39(0x181)]=resolve(_0x5626c9,SKILL_FILE),_0x498a73[_0x568c39(0x196)]=_0x5681e1);for(const _0x25221c of _0x4537df){!_0x498a73[_0x568c39(0x198)]['includes'](_0x25221c)&&_0x498a73['linkedPaths'][_0x568c39(0x17d)](_0x25221c);}_0x498a73['linkedPaths']['sort']();return;}_0x36a491[_0x568c39(0x1a5)](_0x546bce,{..._0x23fe53,'tags':Array[_0x568c39(0x19f)](_0x23fe53[_0x568c39(0x17e)])?_0x23fe53[_0x568c39(0x17e)]:[],'scope':_0x23fe53[_0x568c39(0x179)],'source':'local','dir':_0x5626c9,'cacheDir':_0x300cbf['source']==='cache'?_0x5626c9:undefined,'skillMdPath':resolve(_0x5626c9,SKILL_FILE),'metadataPath':_0x5681e1,'linkedPaths':_0x4537df});}function compareLocalRuntimeSkills(_0x426edc,_0x249b2c){const _0x3e556d=a142_0x2bf4,_0x844905={'personal':0x0,'company':0x1,'builtin':0x2};return _0x844905[_0x426edc[_0x3e556d(0x179)]]-_0x844905[_0x249b2c[_0x3e556d(0x179)]]||_0x426edc[_0x3e556d(0x1a2)][_0x3e556d(0x183)](_0x249b2c[_0x3e556d(0x1a2)])||_0x426edc[_0x3e556d(0x19a)][_0x3e556d(0x183)](_0x249b2c[_0x3e556d(0x19a)]);}
@@ -1 +1 @@
1
- (function(_0x5c3268,_0x2d251f){const _0x4c655b=a142_0x4f27,_0x3f9e7d=_0x5c3268();while(!![]){try{const _0x2de99d=parseInt(_0x4c655b(0xe7))/0x1+-parseInt(_0x4c655b(0x106))/0x2+parseInt(_0x4c655b(0xeb))/0x3+-parseInt(_0x4c655b(0x103))/0x4*(parseInt(_0x4c655b(0x101))/0x5)+parseInt(_0x4c655b(0xde))/0x6+parseInt(_0x4c655b(0xdd))/0x7*(parseInt(_0x4c655b(0xdf))/0x8)+parseInt(_0x4c655b(0xf8))/0x9;if(_0x2de99d===_0x2d251f)break;else _0x3f9e7d['push'](_0x3f9e7d['shift']());}catch(_0x3a0388){_0x3f9e7d['push'](_0x3f9e7d['shift']());}}}(a142_0x3f4f,0x5894b));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(_0x1530b3){const _0x595276=a142_0x4f27;return _0x1530b3['bytes']??Buffer['from'](_0x1530b3[_0x595276(0xed)]??'','utf8');}export function fileText(_0x1321c0){const _0x303019=a142_0x4f27;return fileContent(_0x1321c0)['toString'](_0x303019(0x10c));}export function normalizeLocalFiles(_0x41f5c5){const _0x25f9e6=a142_0x4f27;if(!Array[_0x25f9e6(0xec)](_0x41f5c5)||_0x41f5c5[_0x25f9e6(0x107)]===0x0)return[];const _0x442b26=new Map();for(const _0x299dba of _0x41f5c5){if(!_0x299dba||typeof _0x299dba!=='object'||typeof _0x299dba['path']!=='string')throw CliErrors[_0x25f9e6(0x104)]('Skill\x20file\x20path\x20must\x20be\x20text.');const _0xe5f872=normalizeSkillRelativePath(_0x299dba[_0x25f9e6(0xe0)]);if(_0x442b26[_0x25f9e6(0x102)](_0xe5f872))throw CliErrors[_0x25f9e6(0x104)]('Duplicate\x20Skill\x20file\x20path:\x20'+_0xe5f872);if(_0x299dba[_0x25f9e6(0xfa)]!==undefined&&!Buffer[_0x25f9e6(0x10b)](_0x299dba['bytes']))throw CliErrors[_0x25f9e6(0x104)](_0x25f9e6(0xe4)+_0xe5f872);if(_0x299dba[_0x25f9e6(0xfa)]===undefined&&typeof _0x299dba['content']!==_0x25f9e6(0xf6))throw CliErrors[_0x25f9e6(0x104)](_0x25f9e6(0xe9)+_0xe5f872);const _0x1f6c9e=fileContent(_0x299dba);_0x442b26[_0x25f9e6(0xe3)](_0xe5f872,{'path':_0xe5f872,'bytes':_0x1f6c9e});}return Array[_0x25f9e6(0xf9)](_0x442b26[_0x25f9e6(0xf4)]())[_0x25f9e6(0xfc)](compareSkillFiles);}export function normalizeManifestFiles(_0x532ca7){const _0x43b259=a142_0x4f27;if(!Array['isArray'](_0x532ca7)||_0x532ca7[_0x43b259(0x107)]===0x0)return[];const _0x173fe0=new Map();for(const _0x19272a of _0x532ca7){if(!_0x19272a||typeof _0x19272a!=='object'||typeof _0x19272a['path']!==_0x43b259(0xf6))throw CliErrors[_0x43b259(0x104)](_0x43b259(0xff));const _0x353a3d=normalizeSkillRelativePath(_0x19272a['path']);if(_0x173fe0[_0x43b259(0x102)](_0x353a3d))throw CliErrors[_0x43b259(0x104)](_0x43b259(0xe6)+_0x353a3d);if(!isSha256Hex(_0x19272a[_0x43b259(0x105)]))throw CliErrors[_0x43b259(0x104)](_0x43b259(0xea)+_0x353a3d);if(!Number['isSafeInteger'](_0x19272a[_0x43b259(0xe2)])||_0x19272a[_0x43b259(0xe2)]<0x0)throw CliErrors['validation']('Skill\x20file\x20size\x20is\x20invalid:\x20'+_0x353a3d);_0x173fe0[_0x43b259(0xe3)](_0x353a3d,{'path':_0x353a3d,'sha256':_0x19272a['sha256'][_0x43b259(0x108)](),'size':_0x19272a[_0x43b259(0xe2)]});}return Array[_0x43b259(0xf9)](_0x173fe0['values']())[_0x43b259(0xfc)](compareSkillFiles);}function a142_0x3f4f(){const _0x32481d=['1833222fyLnnZ','16QOvEGY','path','push','size','set','Skill\x20file\x20bytes\x20must\x20be\x20a\x20Buffer:\x20','replace','Duplicate\x20Skill\x20file\x20path:\x20','318299bqJjEt','split','Skill\x20file\x20content\x20must\x20be\x20text\x20or\x20bytes:\x20','Skill\x20file\x20sha256\x20is\x20invalid:\x20','846468VDQkcr','isArray','content','isFile','excludedFilePaths','Unsafe\x20Skill\x20file\x20path:\x20','isDirectory','Skill\x20directory\x20contains\x20unsupported\x20symlink:\x20','isSymbolicLink','values','localeCompare','string','compare','3486231YhBtnC','from','bytes','add','sort','startsWith','trim','Skill\x20file\x20path\x20must\x20be\x20text.','includes','5khuVjT','has','1720000DLpBlx','validation','sha256','1397760DLnSdt','length','toLowerCase','name','test','isBuffer','utf8','694246ChwtLA'];a142_0x3f4f=function(){return _0x32481d;};return a142_0x3f4f();}export function scanSkillDirectory(_0x206236,_0x472812={}){const _0x5a6c84=a142_0x4f27,_0x319789=realpathSync(_0x206236),_0x3bbdeb=canonicalExcludedFilePaths(_0x472812[_0x5a6c84(0xef)]),_0x2d081=[];function _0x523304(_0x5f5118){const _0x3db192=_0x5a6c84,_0x1fd44a=readdirSync(_0x5f5118,{'withFileTypes':!![]})[_0x3db192(0xfc)]((_0x18a059,_0x2b0b20)=>_0x18a059[_0x3db192(0x109)][_0x3db192(0xf5)](_0x2b0b20[_0x3db192(0x109)]));for(const _0x399806 of _0x1fd44a){if(_0x399806[_0x3db192(0xf1)]()&&IGNORED_DIR_NAMES[_0x3db192(0x102)](_0x399806[_0x3db192(0x109)]))continue;if(IGNORED_FILE_NAMES[_0x3db192(0x102)](_0x399806[_0x3db192(0x109)]))continue;const _0x48424b=resolve(_0x5f5118,_0x399806[_0x3db192(0x109)]);if(isExcludedFilePath(_0x48424b,_0x3bbdeb))continue;if(_0x399806[_0x3db192(0xf3)]())throw CliErrors[_0x3db192(0x104)](_0x3db192(0xf2)+_0x48424b);const _0x1d8792=toPosixPath(relative(_0x319789,_0x48424b));if(_0x399806['isDirectory']()){_0x523304(_0x48424b);continue;}if(!_0x399806[_0x3db192(0xee)]())continue;validateSkillRelativePath(_0x1d8792);const _0x381add=readFileSync(_0x48424b);_0x2d081[_0x3db192(0xe1)]({'path':_0x1d8792,'bytes':_0x381add});}}return _0x523304(_0x319789),normalizeLocalFiles(_0x2d081);}function a142_0x4f27(_0x443a6b,_0x1553b0){_0x443a6b=_0x443a6b-0xdd;const _0x3f4ff2=a142_0x3f4f();let _0x4f27b9=_0x3f4ff2[_0x443a6b];return _0x4f27b9;}function canonicalExcludedFilePaths(_0x1b6e82){const _0x46ee27=a142_0x4f27,_0x46a1ec=new Set();for(const _0x22301f of _0x1b6e82??[]){const _0x50ac16=resolve(_0x22301f);_0x46a1ec[_0x46ee27(0xfb)](_0x50ac16);try{_0x46a1ec['add'](realpathSync(_0x50ac16));}catch{}}return _0x46a1ec;}function isExcludedFilePath(_0x7d6669,_0x1c3493){const _0x35508f=a142_0x4f27;if(_0x1c3493[_0x35508f(0x102)](_0x7d6669))return!![];if(_0x1c3493[_0x35508f(0xe2)]===0x0)return![];try{return _0x1c3493[_0x35508f(0x102)](realpathSync(_0x7d6669));}catch{return![];}}export function compareSkillFiles(_0x11b9fb,_0x501ed1){const _0x458208=a142_0x4f27;if(_0x11b9fb[_0x458208(0xe0)]===SKILL_FILE)return _0x501ed1[_0x458208(0xe0)]===SKILL_FILE?0x0:-0x1;if(_0x501ed1[_0x458208(0xe0)]===SKILL_FILE)return 0x1;return Buffer[_0x458208(0xf7)](Buffer['from'](_0x11b9fb['path'],_0x458208(0x10c)),Buffer[_0x458208(0xf9)](_0x501ed1[_0x458208(0xe0)],_0x458208(0x10c)));}export function normalizeSkillRelativePath(_0x44d55a){const _0x4260ff=a142_0x4f27,_0x46b156=toPosixPath(_0x44d55a[_0x4260ff(0xfe)]());return validateSkillRelativePath(_0x46b156),_0x46b156;}export function validateSkillRelativePath(_0x3f265a){const _0x73eea9=a142_0x4f27;if(!_0x3f265a||_0x3f265a[_0x73eea9(0xfd)]('/')||_0x3f265a[_0x73eea9(0x100)]('//'))throw CliErrors[_0x73eea9(0x104)](_0x73eea9(0xf0)+_0x3f265a);for(const _0x1d2e4b of _0x3f265a[_0x73eea9(0xe8)]('/')){if(!_0x1d2e4b||_0x1d2e4b==='.'||_0x1d2e4b==='..')throw CliErrors['validation'](_0x73eea9(0xf0)+_0x3f265a);}}export function toPosixPath(_0xdcd6ff){const _0x2a0ea2=a142_0x4f27;return _0xdcd6ff[_0x2a0ea2(0xe5)](/\\/g,'/');}export function isSha256Hex(_0x42c1f1){const _0x2d88b2=a142_0x4f27;return typeof _0x42c1f1===_0x2d88b2(0xf6)&&/^[a-fA-F0-9]{64}$/[_0x2d88b2(0x10a)](_0x42c1f1);}
1
+ (function(_0x4db48b,_0x3d0d4d){const _0x2a0224=a143_0x17af,_0x588e1b=_0x4db48b();while(!![]){try{const _0x80656a=-parseInt(_0x2a0224(0x138))/0x1*(parseInt(_0x2a0224(0x13d))/0x2)+parseInt(_0x2a0224(0x153))/0x3+parseInt(_0x2a0224(0x140))/0x4+-parseInt(_0x2a0224(0x12a))/0x5*(parseInt(_0x2a0224(0x14b))/0x6)+parseInt(_0x2a0224(0x133))/0x7*(-parseInt(_0x2a0224(0x129))/0x8)+-parseInt(_0x2a0224(0x150))/0x9*(parseInt(_0x2a0224(0x148))/0xa)+parseInt(_0x2a0224(0x126))/0xb*(parseInt(_0x2a0224(0x13e))/0xc);if(_0x80656a===_0x3d0d4d)break;else _0x588e1b['push'](_0x588e1b['shift']());}catch(_0xe6c37e){_0x588e1b['push'](_0x588e1b['shift']());}}}(a143_0x5128,0x41ff9));import{readFileSync,readdirSync,realpathSync}from'node:fs';import{relative,resolve}from'node:path';import{CliErrors}from'../../errors.js';function a143_0x17af(_0xe4558f,_0x4e749d){_0xe4558f=_0xe4558f-0x125;const _0x51282f=a143_0x5128();let _0x17afdf=_0x51282f[_0xe4558f];return _0x17afdf;}import{IGNORED_DIR_NAMES,IGNORED_FILE_NAMES,SKILL_FILE}from'./constants.js';export function fileContent(_0x1b0b5b){const _0x23c106=a143_0x17af;return _0x1b0b5b[_0x23c106(0x134)]??Buffer[_0x23c106(0x132)](_0x1b0b5b[_0x23c106(0x139)]??'',_0x23c106(0x147));}export function fileText(_0x3f719c){const _0x649b42=a143_0x17af;return fileContent(_0x3f719c)[_0x649b42(0x144)]('utf8');}export function normalizeLocalFiles(_0x24d5d2){const _0x2f9fe4=a143_0x17af;if(!Array[_0x2f9fe4(0x14a)](_0x24d5d2)||_0x24d5d2[_0x2f9fe4(0x14e)]===0x0)return[];const _0x5f7c71=new Map();for(const _0x82d5e7 of _0x24d5d2){if(!_0x82d5e7||typeof _0x82d5e7!==_0x2f9fe4(0x13b)||typeof _0x82d5e7[_0x2f9fe4(0x13a)]!=='string')throw CliErrors[_0x2f9fe4(0x152)](_0x2f9fe4(0x127));const _0x5e4164=normalizeSkillRelativePath(_0x82d5e7[_0x2f9fe4(0x13a)]);if(_0x5f7c71[_0x2f9fe4(0x12e)](_0x5e4164))throw CliErrors[_0x2f9fe4(0x152)](_0x2f9fe4(0x14d)+_0x5e4164);if(_0x82d5e7[_0x2f9fe4(0x134)]!==undefined&&!Buffer['isBuffer'](_0x82d5e7['bytes']))throw CliErrors['validation'](_0x2f9fe4(0x12d)+_0x5e4164);if(_0x82d5e7[_0x2f9fe4(0x134)]===undefined&&typeof _0x82d5e7[_0x2f9fe4(0x139)]!==_0x2f9fe4(0x143))throw CliErrors[_0x2f9fe4(0x152)](_0x2f9fe4(0x12f)+_0x5e4164);const _0x2d7e90=fileContent(_0x82d5e7);_0x5f7c71[_0x2f9fe4(0x125)](_0x5e4164,{'path':_0x5e4164,'bytes':_0x2d7e90});}return Array[_0x2f9fe4(0x132)](_0x5f7c71[_0x2f9fe4(0x136)]())['sort'](compareSkillFiles);}export function normalizeManifestFiles(_0x492673){const _0x16ada9=a143_0x17af;if(!Array[_0x16ada9(0x14a)](_0x492673)||_0x492673['length']===0x0)return[];const _0x380619=new Map();for(const _0x5a8029 of _0x492673){if(!_0x5a8029||typeof _0x5a8029!==_0x16ada9(0x13b)||typeof _0x5a8029[_0x16ada9(0x13a)]!==_0x16ada9(0x143))throw CliErrors[_0x16ada9(0x152)](_0x16ada9(0x127));const _0x38a9de=normalizeSkillRelativePath(_0x5a8029[_0x16ada9(0x13a)]);if(_0x380619['has'](_0x38a9de))throw CliErrors[_0x16ada9(0x152)]('Duplicate\x20Skill\x20file\x20path:\x20'+_0x38a9de);if(!isSha256Hex(_0x5a8029[_0x16ada9(0x14f)]))throw CliErrors['validation'](_0x16ada9(0x130)+_0x38a9de);if(!Number[_0x16ada9(0x12c)](_0x5a8029[_0x16ada9(0x13c)])||_0x5a8029['size']<0x0)throw CliErrors[_0x16ada9(0x152)](_0x16ada9(0x142)+_0x38a9de);_0x380619[_0x16ada9(0x125)](_0x38a9de,{'path':_0x38a9de,'sha256':_0x5a8029['sha256']['toLowerCase'](),'size':_0x5a8029[_0x16ada9(0x13c)]});}return Array['from'](_0x380619[_0x16ada9(0x136)]())[_0x16ada9(0x146)](compareSkillFiles);}export function scanSkillDirectory(_0x3d92df,_0x4bf191={}){const _0x2d8741=realpathSync(_0x3d92df),_0x249476=canonicalExcludedFilePaths(_0x4bf191['excludedFilePaths']),_0x569c6c=[];function _0x37b45b(_0x3fcd7e){const _0x3e1500=a143_0x17af,_0x1db6e2=readdirSync(_0x3fcd7e,{'withFileTypes':!![]})['sort']((_0x2fb41d,_0x17e983)=>_0x2fb41d['name'][_0x3e1500(0x128)](_0x17e983[_0x3e1500(0x13f)]));for(const _0x13b6b0 of _0x1db6e2){if(_0x13b6b0['isDirectory']()&&IGNORED_DIR_NAMES[_0x3e1500(0x12e)](_0x13b6b0['name']))continue;if(IGNORED_FILE_NAMES[_0x3e1500(0x12e)](_0x13b6b0[_0x3e1500(0x13f)]))continue;const _0x544eb2=resolve(_0x3fcd7e,_0x13b6b0['name']);if(isExcludedFilePath(_0x544eb2,_0x249476))continue;if(_0x13b6b0['isSymbolicLink']())throw CliErrors[_0x3e1500(0x152)](_0x3e1500(0x149)+_0x544eb2);const _0x2b7ccc=toPosixPath(relative(_0x2d8741,_0x544eb2));if(_0x13b6b0['isDirectory']()){_0x37b45b(_0x544eb2);continue;}if(!_0x13b6b0[_0x3e1500(0x14c)]())continue;validateSkillRelativePath(_0x2b7ccc);const _0x40102a=readFileSync(_0x544eb2);_0x569c6c[_0x3e1500(0x141)]({'path':_0x2b7ccc,'bytes':_0x40102a});}}return _0x37b45b(_0x2d8741),normalizeLocalFiles(_0x569c6c);}function canonicalExcludedFilePaths(_0x4469bf){const _0x1bd769=a143_0x17af,_0x36b215=new Set();for(const _0x5e96f4 of _0x4469bf??[]){const _0x43b33b=resolve(_0x5e96f4);_0x36b215[_0x1bd769(0x12b)](_0x43b33b);try{_0x36b215[_0x1bd769(0x12b)](realpathSync(_0x43b33b));}catch{}}return _0x36b215;}function isExcludedFilePath(_0x430f2e,_0x2e4e31){const _0x2677c2=a143_0x17af;if(_0x2e4e31[_0x2677c2(0x12e)](_0x430f2e))return!![];if(_0x2e4e31[_0x2677c2(0x13c)]===0x0)return![];try{return _0x2e4e31[_0x2677c2(0x12e)](realpathSync(_0x430f2e));}catch{return![];}}export function compareSkillFiles(_0xf1ff76,_0x2f8963){const _0x112fb8=a143_0x17af;if(_0xf1ff76[_0x112fb8(0x13a)]===SKILL_FILE)return _0x2f8963[_0x112fb8(0x13a)]===SKILL_FILE?0x0:-0x1;if(_0x2f8963[_0x112fb8(0x13a)]===SKILL_FILE)return 0x1;return Buffer[_0x112fb8(0x135)](Buffer[_0x112fb8(0x132)](_0xf1ff76[_0x112fb8(0x13a)],_0x112fb8(0x147)),Buffer['from'](_0x2f8963[_0x112fb8(0x13a)],_0x112fb8(0x147)));}function a143_0x5128(){const _0x452353=['name','104472OOgRhn','push','Skill\x20file\x20size\x20is\x20invalid:\x20','string','toString','includes','sort','utf8','7070dPaGGt','Skill\x20directory\x20contains\x20unsupported\x20symlink:\x20','isArray','6qTditH','isFile','Duplicate\x20Skill\x20file\x20path:\x20','length','sha256','3987TSSTDs','test','validation','1302867cUPgoD','set','53141muKjrp','Skill\x20file\x20path\x20must\x20be\x20text.','localeCompare','8QgAlTV','812740FjacXm','add','isSafeInteger','Skill\x20file\x20bytes\x20must\x20be\x20a\x20Buffer:\x20','has','Skill\x20file\x20content\x20must\x20be\x20text\x20or\x20bytes:\x20','Skill\x20file\x20sha256\x20is\x20invalid:\x20','split','from','900165qwWBhr','bytes','compare','values','Unsafe\x20Skill\x20file\x20path:\x20','293OAcNXt','content','path','object','size','272ueNLQu','1128NnCwWe'];a143_0x5128=function(){return _0x452353;};return a143_0x5128();}export function normalizeSkillRelativePath(_0x454401){const _0x1caa0=toPosixPath(_0x454401['trim']());return validateSkillRelativePath(_0x1caa0),_0x1caa0;}export function validateSkillRelativePath(_0x50d673){const _0x4477a9=a143_0x17af;if(!_0x50d673||_0x50d673['startsWith']('/')||_0x50d673[_0x4477a9(0x145)]('//'))throw CliErrors[_0x4477a9(0x152)](_0x4477a9(0x137)+_0x50d673);for(const _0x313d62 of _0x50d673[_0x4477a9(0x131)]('/')){if(!_0x313d62||_0x313d62==='.'||_0x313d62==='..')throw CliErrors[_0x4477a9(0x152)](_0x4477a9(0x137)+_0x50d673);}}export function toPosixPath(_0x13b2e0){return _0x13b2e0['replace'](/\\/g,'/');}export function isSha256Hex(_0x2816ef){const _0x3a16f7=a143_0x17af;return typeof _0x2816ef===_0x3a16f7(0x143)&&/^[a-fA-F0-9]{64}$/[_0x3a16f7(0x151)](_0x2816ef);}