@lovrabet/rabetbase-cli 2.3.10-beta.1 → 2.3.10

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 (259) hide show
  1. package/lib/api/api-doc.js +1 -1
  2. package/lib/api/fetch-model-list.js +1 -1
  3. package/lib/api/generate-api-file.js +1 -1
  4. package/lib/auth/auth-server-ui.js +1 -1
  5. package/lib/auth/auth-server.js +1 -1
  6. package/lib/auth/constant.js +1 -1
  7. package/lib/auth/get-cookie.js +1 -1
  8. package/lib/auth/get-session-user.js +1 -1
  9. package/lib/auth/is-session-valid.js +1 -1
  10. package/lib/auth/login-success-html.js +1 -1
  11. package/lib/auth/logout.js +1 -1
  12. package/lib/cli-flags.js +1 -1
  13. package/lib/cli.js +1 -1
  14. package/lib/commands/api/generate.js +1 -1
  15. package/lib/commands/api/index.js +1 -1
  16. package/lib/commands/api/list.js +1 -1
  17. package/lib/commands/api/pull.js +1 -1
  18. package/lib/commands/api/shared.js +1 -1
  19. package/lib/commands/app/add.js +1 -1
  20. package/lib/commands/app/index.js +1 -1
  21. package/lib/commands/app/list.js +1 -1
  22. package/lib/commands/app/remote-directory.js +1 -1
  23. package/lib/commands/app/remove.js +1 -1
  24. package/lib/commands/app/shared.js +1 -1
  25. package/lib/commands/app-config/delete.js +1 -1
  26. package/lib/commands/app-config/get.js +1 -1
  27. package/lib/commands/app-config/index.js +1 -1
  28. package/lib/commands/app-config/list.js +1 -1
  29. package/lib/commands/app-config/set.js +1 -1
  30. package/lib/commands/app-config/shared.js +1 -1
  31. package/lib/commands/auth/index.js +1 -1
  32. package/lib/commands/bff/create.js +1 -1
  33. package/lib/commands/bff/delete.js +1 -1
  34. package/lib/commands/bff/detail.js +1 -1
  35. package/lib/commands/bff/index.js +1 -1
  36. package/lib/commands/bff/list.js +1 -1
  37. package/lib/commands/bff/pull.js +1 -1
  38. package/lib/commands/bff/push.js +1 -1
  39. package/lib/commands/bff/status.js +1 -1
  40. package/lib/commands/cli-skill/index.js +1 -1
  41. package/lib/commands/cli-update.js +1 -1
  42. package/lib/commands/codegen/index.js +1 -1
  43. package/lib/commands/codegen/sdk.js +1 -1
  44. package/lib/commands/codegen/sql.js +1 -1
  45. package/lib/commands/common/app-registry.js +1 -1
  46. package/lib/commands/common/app-selector.js +1 -1
  47. package/lib/commands/common/async-task.js +1 -1
  48. package/lib/commands/common/dry-run.js +1 -1
  49. package/lib/commands/common/flags.js +1 -1
  50. package/lib/commands/common/local-file.js +1 -1
  51. package/lib/commands/common/validate.js +1 -1
  52. package/lib/commands/config/get.js +1 -1
  53. package/lib/commands/config/index.js +1 -1
  54. package/lib/commands/config/list.js +1 -1
  55. package/lib/commands/config/set.js +1 -1
  56. package/lib/commands/config/shared.js +1 -1
  57. package/lib/commands/data/filter.js +1 -1
  58. package/lib/commands/data/getOne.js +1 -1
  59. package/lib/commands/data/index.js +1 -1
  60. package/lib/commands/data/shared.js +1 -1
  61. package/lib/commands/dataset/business-group-update.js +1 -1
  62. package/lib/commands/dataset/capability.js +1 -1
  63. package/lib/commands/dataset/delete.js +1 -1
  64. package/lib/commands/dataset/detail.js +1 -1
  65. package/lib/commands/dataset/extend-update.js +1 -1
  66. package/lib/commands/dataset/field-update.js +1 -1
  67. package/lib/commands/dataset/generate.js +1 -1
  68. package/lib/commands/dataset/index.js +1 -1
  69. package/lib/commands/dataset/list.js +1 -1
  70. package/lib/commands/dataset/operations.js +1 -1
  71. package/lib/commands/dataset/relation-audit.js +1 -1
  72. package/lib/commands/dataset/relation-create.js +1 -1
  73. package/lib/commands/dataset/relation-delete.js +1 -1
  74. package/lib/commands/dataset/relation-shared.js +1 -1
  75. package/lib/commands/dataset/relation-update.js +1 -1
  76. package/lib/commands/dataset/relations.js +1 -1
  77. package/lib/commands/dataset/rename.js +1 -1
  78. package/lib/commands/dataset/restore.js +1 -1
  79. package/lib/commands/db/analysis-batching.js +1 -1
  80. package/lib/commands/db/analyze-batch-plan.js +1 -1
  81. package/lib/commands/db/analyze-cancel.js +1 -1
  82. package/lib/commands/db/analyze-start.js +1 -1
  83. package/lib/commands/db/analyze-status.js +1 -1
  84. package/lib/commands/db/create.js +1 -1
  85. package/lib/commands/db/delete.js +1 -1
  86. package/lib/commands/db/detail.js +1 -1
  87. package/lib/commands/db/diff.js +1 -1
  88. package/lib/commands/db/index.js +1 -1
  89. package/lib/commands/db/list.js +1 -1
  90. package/lib/commands/db/shared.js +1 -1
  91. package/lib/commands/db/tables.js +1 -1
  92. package/lib/commands/db/test.js +1 -1
  93. package/lib/commands/db/update.js +1 -1
  94. package/lib/commands/doctor.js +1 -1
  95. package/lib/commands/file/index.js +1 -1
  96. package/lib/commands/init/index.js +1 -1
  97. package/lib/commands/issue/index.js +1 -1
  98. package/lib/commands/issue/nudge.js +1 -1
  99. package/lib/commands/issue/report.js +1 -1
  100. package/lib/commands/issue/shared.js +1 -1
  101. package/lib/commands/logs/index.js +1 -1
  102. package/lib/commands/menu/delete.js +1 -1
  103. package/lib/commands/menu/external-link-create.js +1 -0
  104. package/lib/commands/menu/group-create.js +1 -1
  105. package/lib/commands/menu/group-update.js +1 -1
  106. package/lib/commands/menu/index.js +1 -1
  107. package/lib/commands/menu/list.js +1 -1
  108. package/lib/commands/menu/regroup-start.js +1 -1
  109. package/lib/commands/menu/shared/compare-table.js +1 -1
  110. package/lib/commands/menu/shared/delete-plan.js +1 -1
  111. package/lib/commands/menu/shared/facts.js +1 -1
  112. package/lib/commands/menu/shared/index.js +1 -1
  113. package/lib/commands/menu/shared/inquirer.js +1 -1
  114. package/lib/commands/menu/shared/local-pages.js +1 -1
  115. package/lib/commands/menu/shared/logic.js +1 -1
  116. package/lib/commands/menu/shared/mutations.js +1 -1
  117. package/lib/commands/menu/shared/service.js +1 -1
  118. package/lib/commands/menu/shared/sync-core.js +1 -1
  119. package/lib/commands/menu/shared/update-core.js +1 -1
  120. package/lib/commands/menu/shared/valid-url.js +1 -1
  121. package/lib/commands/menu/sync.js +1 -1
  122. package/lib/commands/menu/update.js +1 -1
  123. package/lib/commands/notification/config-list.js +1 -1
  124. package/lib/commands/notification/index.js +1 -1
  125. package/lib/commands/page/generate-start.js +1 -1
  126. package/lib/commands/page/generate-status.js +1 -1
  127. package/lib/commands/page/index.js +1 -1
  128. package/lib/commands/page/pull.js +1 -1
  129. package/lib/commands/page/push.js +1 -1
  130. package/lib/commands/page/relation-audit.js +1 -1
  131. package/lib/commands/page/shared.js +1 -1
  132. package/lib/commands/page/standard-page-status.js +1 -1
  133. package/lib/commands/page/sync.js +1 -1
  134. package/lib/commands/permit/index.js +1 -1
  135. package/lib/commands/permit/page-get.js +1 -1
  136. package/lib/commands/permit/page-set.js +1 -1
  137. package/lib/commands/permit/role-apis-set.js +1 -1
  138. package/lib/commands/permit/role-menus-set.js +1 -1
  139. package/lib/commands/permit/role-menus.js +1 -1
  140. package/lib/commands/permit/shared.js +1 -1
  141. package/lib/commands/project/create/enhanced-guided-create.js +1 -1
  142. package/lib/commands/project/create/format-elapsed.js +1 -1
  143. package/lib/commands/project/create/main.js +1 -1
  144. package/lib/commands/project/create/non-interactive.js +1 -1
  145. package/lib/commands/project/create/project-template-path.js +1 -1
  146. package/lib/commands/project/create/use-copy-project-template.js +1 -1
  147. package/lib/commands/project/create/use-format-code.js +1 -1
  148. package/lib/commands/project/create/use-install-dependencies.js +1 -1
  149. package/lib/commands/project/index.js +1 -1
  150. package/lib/commands/project/init.js +1 -1
  151. package/lib/commands/project/upgrade.js +1 -1
  152. package/lib/commands/registry.js +1 -1
  153. package/lib/commands/role/create.js +1 -1
  154. package/lib/commands/role/delete.js +1 -1
  155. package/lib/commands/role/detail.js +1 -1
  156. package/lib/commands/role/index.js +1 -1
  157. package/lib/commands/role/list.js +1 -1
  158. package/lib/commands/role/shared.js +1 -1
  159. package/lib/commands/role/update.js +1 -1
  160. package/lib/commands/role/user-add.js +1 -1
  161. package/lib/commands/role/user-remove.js +1 -1
  162. package/lib/commands/role/user-resolve.js +1 -1
  163. package/lib/commands/run/index.js +1 -1
  164. package/lib/commands/schema.js +1 -1
  165. package/lib/commands/sql/create.js +1 -1
  166. package/lib/commands/sql/delete.js +1 -1
  167. package/lib/commands/sql/detail.js +1 -1
  168. package/lib/commands/sql/exec.js +1 -1
  169. package/lib/commands/sql/index.js +1 -1
  170. package/lib/commands/sql/list.js +1 -1
  171. package/lib/commands/sql/pull.js +1 -1
  172. package/lib/commands/sql/push.js +1 -1
  173. package/lib/commands/sql/save.js +1 -1
  174. package/lib/commands/sql/shared.js +1 -1
  175. package/lib/commands/sql/status.js +1 -1
  176. package/lib/commands/sql/validate.js +1 -1
  177. package/lib/commands/task/index.js +1 -1
  178. package/lib/commands/task/status.js +1 -1
  179. package/lib/commands/workspace/add.js +1 -1
  180. package/lib/commands/workspace/index.js +1 -1
  181. package/lib/commands/workspace/remove.js +1 -1
  182. package/lib/config/schema.js +1 -1
  183. package/lib/constant/cdn.js +1 -1
  184. package/lib/constant/cli.js +1 -1
  185. package/lib/constant/defaults.js +1 -1
  186. package/lib/constant/domain.js +1 -1
  187. package/lib/constant/env.js +1 -1
  188. package/lib/constant/output.js +1 -1
  189. package/lib/constant/paths.js +1 -1
  190. package/lib/constant/risk.js +1 -1
  191. package/lib/context/app-resolver.js +1 -1
  192. package/lib/context/auth-resolver.js +1 -1
  193. package/lib/context/config-loader.js +1 -1
  194. package/lib/context.js +1 -1
  195. package/lib/core/alias-resolver.js +1 -1
  196. package/lib/core/api-client.js +1 -1
  197. package/lib/core/bff/config.js +1 -1
  198. package/lib/core/bff/file-system.js +1 -1
  199. package/lib/core/bff/hash.js +1 -1
  200. package/lib/core/bff/lock.js +1 -1
  201. package/lib/core/bff/utils.js +1 -1
  202. package/lib/core/db-resolver.js +1 -1
  203. package/lib/core/page/file-system.js +1 -1
  204. package/lib/core/page/hash.js +1 -1
  205. package/lib/core/page/lock.js +1 -1
  206. package/lib/core/sql-index-auditor.js +1 -1
  207. package/lib/core/sql-sync/config.js +1 -1
  208. package/lib/core/sql-sync/file-system.js +1 -1
  209. package/lib/core/sql-sync/hash.js +1 -1
  210. package/lib/core/sql-sync/lock.js +1 -1
  211. package/lib/core/sql-sync/utils.js +1 -1
  212. package/lib/core/sql-validator.js +1 -1
  213. package/lib/errors.js +1 -1
  214. package/lib/framework/build-all-flags.js +1 -1
  215. package/lib/framework/error-output.js +1 -1
  216. package/lib/framework/explicit-yes.js +1 -1
  217. package/lib/framework/flags.js +1 -1
  218. package/lib/framework/help.js +1 -1
  219. package/lib/framework/index.js +1 -1
  220. package/lib/framework/output.js +1 -1
  221. package/lib/framework/response.js +1 -1
  222. package/lib/framework/runner-alias.js +1 -1
  223. package/lib/framework/runner.js +1 -1
  224. package/lib/framework/schema-export.js +1 -1
  225. package/lib/framework/types.js +1 -1
  226. package/lib/generated/build-info.js +1 -1
  227. package/lib/help.js +1 -1
  228. package/lib/skills/main.js +1 -1
  229. package/lib/skills/npx-skills-add.js +1 -1
  230. package/lib/telemetry/cli-command-trace.js +1 -1
  231. package/lib/telemetry/cli-help-trace.js +1 -1
  232. package/lib/telemetry/ensure-cli-otel-config.js +1 -1
  233. package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
  234. package/lib/telemetry/send-cli-trace-log.js +1 -1
  235. package/lib/telemetry/send-platform-issue-collect-log.js +1 -1
  236. package/lib/utils/ai_config.js +1 -1
  237. package/lib/utils/apply-jq-filter.js +1 -1
  238. package/lib/utils/cdn-config.js +1 -1
  239. package/lib/utils/check-sdk-version.js +1 -1
  240. package/lib/utils/cli-version-check.js +1 -1
  241. package/lib/utils/cli-version-policy.js +1 -1
  242. package/lib/utils/config.js +1 -1
  243. package/lib/utils/copy-directory.js +1 -1
  244. package/lib/utils/entity-with-id.js +1 -1
  245. package/lib/utils/file-utils.js +1 -1
  246. package/lib/utils/guides-cdn.js +1 -1
  247. package/lib/utils/http-client.js +1 -1
  248. package/lib/utils/is-non-interactive.js +1 -1
  249. package/lib/utils/logger.js +1 -1
  250. package/lib/utils/params.js +1 -1
  251. package/lib/utils/platform.js +1 -1
  252. package/lib/utils/rules-cdn.js +1 -1
  253. package/lib/utils/sleep.js +1 -1
  254. package/lib/utils/template-replacer.js +1 -1
  255. package/lib/utils/update-notice.js +1 -1
  256. package/lib/utils/version.js +1 -1
  257. package/lib/utils/with-active-cookie.js +1 -1
  258. package/lib/utils/write-cli-side-channel.js +1 -1
  259. package/package.json +1 -1
@@ -1 +1 @@
1
- function a36_0x29d7(_0x3df891,_0x4e3e12){_0x3df891=_0x3df891-0x18a;const _0x57190f=a36_0x5719();let _0x29d761=_0x57190f[_0x3df891];return _0x29d761;}const a36_0x39fde2=a36_0x29d7;(function(_0x4e8bd8,_0xf5ca66){const _0x12188f=a36_0x29d7,_0x375890=_0x4e8bd8();while(!![]){try{const _0x237e1f=-parseInt(_0x12188f(0x18e))/0x1*(-parseInt(_0x12188f(0x1be))/0x2)+-parseInt(_0x12188f(0x1b3))/0x3*(parseInt(_0x12188f(0x194))/0x4)+parseInt(_0x12188f(0x1b4))/0x5*(-parseInt(_0x12188f(0x1c2))/0x6)+parseInt(_0x12188f(0x18c))/0x7+parseInt(_0x12188f(0x1c7))/0x8*(parseInt(_0x12188f(0x1aa))/0x9)+parseInt(_0x12188f(0x1a8))/0xa*(parseInt(_0x12188f(0x19a))/0xb)+-parseInt(_0x12188f(0x1ab))/0xc*(-parseInt(_0x12188f(0x191))/0xd);if(_0x237e1f===_0xf5ca66)break;else _0x375890['push'](_0x375890['shift']());}catch(_0x3793b8){_0x375890['push'](_0x375890['shift']());}}}(a36_0x5719,0x7fb71));import{createInterface}from'node:readline';import{writeFile}from'node:fs/promises';import{listBffScripts,getBffScriptStatistics}from'../../core/api-client.js';import{loadAliasMap}from'../../core/alias-resolver.js';import{resolveApiFilePath}from'../../context.js';import{loadBffProjectConfig}from'../../core/bff/config.js';import{createHookLocationMap,ensureParentDirectory,fileExists,normalizeBffType,resolveRemoteScriptTarget}from'../../core/bff/file-system.js';import{computeContentHash,computeFileHash}from'../../core/bff/hash.js';import{createEmptyBffLock,ensureLockScope,readBffLockFile,writeBffLockFile}from'../../core/bff/lock.js';import{CliErrors}from'../../errors.js';export const bffPull={'service':'bff','command':'pull','description':'Pull\x20remote\x20BFF\x20scripts\x20to\x20local','risk':a36_0x39fde2(0x18b),'flags':[{'name':a36_0x39fde2(0x19e),'type':'string','description':a36_0x39fde2(0x1ca),'enum':[a36_0x39fde2(0x1c9),'ENDPOINT','HOOK']},{'name':'force','type':a36_0x39fde2(0x199),'description':a36_0x39fde2(0x1bc)}],async 'dryRun'(_0xf6ec96){const _0x5c348a=a36_0x39fde2,_0x3c5ebe=loadBffProjectConfig(_0xf6ec96[_0x5c348a(0x1ac)]),_0x46da83=await readBffLockFile(_0x3c5ebe[_0x5c348a(0x1cd)]),{appLock:_0x544399}=ensureLockScope(_0x46da83??createEmptyBffLock(),_0xf6ec96[_0x5c348a(0x1ac)],_0x3c5ebe[_0x5c348a(0x1c1)],_0x5c348a(0x192)),_0x147edf=normalizeBffType(_0xf6ec96[_0x5c348a(0x1a1)](_0x5c348a(0x19e)))??undefined,_0xbe9ab4=buildDatasetCodeToAliasMap(_0xf6ec96[_0x5c348a(0x1b2)],_0xf6ec96['appCode']),[_0x1b93a2,_0x58c922]=await Promise[_0x5c348a(0x197)]([listBffScripts(_0xf6ec96['appCode'],_0x147edf),getBffScriptStatistics(_0xf6ec96[_0x5c348a(0x1ac)])]),_0xae0963=createHookLocationMap(_0x58c922),_0x1c19ee=[];for(const _0x40d786 of _0x1b93a2){const _0x1b2cc8=resolveRemoteScriptTarget(_0x3c5ebe,_0x40d786,_0xae0963,_0x544399[_0x5c348a(0x196)],_0xbe9ab4);if(!_0x1b2cc8){_0x1c19ee[_0x5c348a(0x1ce)]({'scriptType':_0x40d786['scriptType'],'functionName':_0x40d786['functionName']??'','status':_0x5c348a(0x1b6),'reason':'unresolvable\x20target\x20path'});continue;}const _0x368b8e=_0x544399[_0x5c348a(0x196)][_0x1b2cc8[_0x5c348a(0x1b0)]],_0x5366af=_0x40d786[_0x5c348a(0x1a6)]!=null?computeContentHash(_0x40d786[_0x5c348a(0x1a6)]):undefined,_0xc36009=await hasUnsyncedLocalChanges(_0x1b2cc8[_0x5c348a(0x1b8)],_0x368b8e,_0x5366af);_0x1c19ee[_0x5c348a(0x1ce)]({'lockKey':_0x1b2cc8['lockKey'],'filePath':_0x1b2cc8[_0x5c348a(0x1b8)],'remoteId':_0x40d786['id']??null,'status':_0xc36009?_0x5c348a(0x19f):_0x5c348a(0x1ba)});}return{'method':'GET','url':_0x5c348a(0x1a7)+_0xf6ec96['appCode']+(_0x147edf?'&type='+_0x147edf:''),'body':{'appCode':_0xf6ec96[_0x5c348a(0x1ac)],'filterType':_0x147edf??null,'files':_0x1c19ee},'description':_0x5c348a(0x190)+_0x1c19ee[_0x5c348a(0x1a9)]+_0x5c348a(0x195)};},async 'execute'(_0xf3b15d){const _0x35e2e0=a36_0x39fde2,_0x71cb6f=loadBffProjectConfig(_0xf3b15d[_0x35e2e0(0x1ac)]),_0x1a2836=await readBffLockFile(_0x71cb6f['lockFilePath']),{lockData:_0x5e7e1d,appLock:_0x47d33f}=ensureLockScope(_0x1a2836??createEmptyBffLock(),_0xf3b15d[_0x35e2e0(0x1ac)],_0x71cb6f['scriptsRoot'],_0x35e2e0(0x192)),_0x54b8f8=normalizeBffType(_0xf3b15d[_0x35e2e0(0x1a1)](_0x35e2e0(0x19e)))??undefined;if(_0xf3b15d[_0x35e2e0(0x1a1)]('type')&&!_0x54b8f8)throw CliErrors[_0x35e2e0(0x1b1)](_0x35e2e0(0x1a2));const [_0x46e598,_0x983a2]=await Promise[_0x35e2e0(0x197)]([listBffScripts(_0xf3b15d[_0x35e2e0(0x1ac)],_0x54b8f8),getBffScriptStatistics(_0xf3b15d['appCode'])]);if(_0x46e598[_0x35e2e0(0x1a9)]===0x0)return{'ok':!![],'data':{'pulled':[],'skipped':[],'failed':[]},'message':'No\x20remote\x20BFF\x20scripts\x20found.'};const _0xc3550c=_0xf3b15d['bool']('force');if(_0xc3550c&&!_0xf3b15d[_0x35e2e0(0x1bf)]){const _0x26a157=await confirmForce();if(!_0x26a157)throw CliErrors[_0x35e2e0(0x1c0)](_0x35e2e0(0x1cc));}if(_0xc3550c&&_0xf3b15d['nonInteractive']){}const _0x4f95fe=buildDatasetCodeToAliasMap(_0xf3b15d[_0x35e2e0(0x1b2)],_0xf3b15d['appCode']),_0x59cc92=createHookLocationMap(_0x983a2),_0xdf2ba7=JSON[_0x35e2e0(0x1a3)](JSON['stringify'](_0x5e7e1d)),_0x12b75a=_0xf3b15d[_0x35e2e0(0x1ac)],_0x41f0fe=_0xdf2ba7[_0x35e2e0(0x1a4)][_0x12b75a];if(!_0x41f0fe)throw new Error(_0x35e2e0(0x1b5)+_0x12b75a+_0x35e2e0(0x1af));const _0x8f7d27=[],_0x5b93ad=[],_0xc08fb=[];for(const _0x468c71 of _0x46e598){const _0x4c9210=resolveRemoteScriptTarget(_0x71cb6f,_0x468c71,_0x59cc92,_0x47d33f[_0x35e2e0(0x196)],_0x4f95fe);if(!_0x4c9210){_0x5b93ad[_0x35e2e0(0x1ce)]({'lockKey':_0x468c71[_0x35e2e0(0x1bd)]+'/'+_0x468c71[_0x35e2e0(0x198)],'reason':'unresolvable\x20target\x20path'});continue;}const _0x2f4f08=_0x47d33f[_0x35e2e0(0x196)][_0x4c9210[_0x35e2e0(0x1b0)]];try{if(!_0x468c71['id'])throw new Error('Remote\x20script\x20missing\x20id.');if(_0x468c71[_0x35e2e0(0x1a6)]==null)throw new Error('Remote\x20script\x20missing\x20content.');const _0x1d8496=_0x468c71[_0x35e2e0(0x1a6)],_0x3f3132=computeContentHash(_0x1d8496);if(!_0xc3550c){const _0x5544d0=await hasUnsyncedLocalChanges(_0x4c9210[_0x35e2e0(0x1b8)],_0x2f4f08,_0x3f3132);if(_0x5544d0){_0x5b93ad[_0x35e2e0(0x1ce)]({'lockKey':_0x4c9210[_0x35e2e0(0x1b0)],'reason':_0x35e2e0(0x1cf)});continue;}}await ensureParentDirectory(_0x4c9210['filePath']),await writeFile(_0x4c9210[_0x35e2e0(0x1b8)],_0x1d8496,_0x35e2e0(0x1cb));const _0x40c7d1={'hash':_0x3f3132,'remoteId':_0x468c71['id'],'version':_0x468c71[_0x35e2e0(0x1c3)]};_0x4c9210['type']===_0x35e2e0(0x18d)&&_0x4c9210[_0x35e2e0(0x19b)]&&(_0x40c7d1[_0x35e2e0(0x1c4)]=_0x4c9210['hookLocation'][_0x35e2e0(0x1c4)],_0x40c7d1[_0x35e2e0(0x193)]=_0x4c9210[_0x35e2e0(0x19b)][_0x35e2e0(0x193)],_0x40c7d1[_0x35e2e0(0x1ae)]=_0x4c9210['hookLocation'][_0x35e2e0(0x1ae)],_0x40c7d1['functionNode']=_0x4c9210[_0x35e2e0(0x19b)]['functionNode']),_0x41f0fe[_0x35e2e0(0x196)][_0x4c9210[_0x35e2e0(0x1b0)]]=_0x40c7d1,_0x8f7d27[_0x35e2e0(0x1ce)]({'lockKey':_0x4c9210[_0x35e2e0(0x1b0)],'remoteId':_0x468c71['id']});}catch(_0x3f6710){_0xc08fb[_0x35e2e0(0x1ce)]({'lockKey':_0x4c9210['lockKey'],'error':_0x3f6710 instanceof Error?_0x3f6710[_0x35e2e0(0x1ad)]:String(_0x3f6710)});}}return _0x41f0fe[_0x35e2e0(0x1c5)]=new Date()[_0x35e2e0(0x18f)](),await writeBffLockFile(_0x71cb6f[_0x35e2e0(0x1cd)],_0xdf2ba7),{'ok':_0xc08fb['length']===0x0,'data':{'pulled':_0x8f7d27,'skipped':_0x5b93ad,'failed':_0xc08fb},'message':_0x35e2e0(0x1a5)+_0x8f7d27['length']+'\x20pulled,\x20'+_0x5b93ad[_0x35e2e0(0x1a9)]+_0x35e2e0(0x1c6)+_0xc08fb[_0x35e2e0(0x1a9)]+_0x35e2e0(0x1c8)};}};async function hasUnsyncedLocalChanges(_0x4b2c6d,_0x4914e1,_0x2dc270){if(!await fileExists(_0x4b2c6d))return![];const _0x492c82=await computeFileHash(_0x4b2c6d);if(!_0x4914e1)return _0x2dc270?_0x492c82!==_0x2dc270:!![];return _0x492c82!==_0x4914e1['hash'];}function buildDatasetCodeToAliasMap(_0x188d76,_0x374459){const _0x34cd20=a36_0x39fde2,_0x18dec6=loadAliasMap(_0x188d76,undefined,resolveApiFilePath(_0x188d76,_0x374459));return new Map(_0x18dec6[_0x34cd20(0x1b7)](_0x48644b=>[_0x48644b[_0x34cd20(0x193)],_0x48644b[_0x34cd20(0x1c4)]]));}async function confirmForce(){const _0x252e8f=a36_0x39fde2,_0x591795=createInterface({'input':process['stdin'],'output':process['stderr']}),_0x31b430=await new Promise(_0x4a9166=>{const _0x1b73af=a36_0x29d7;_0x591795['question'](_0x1b73af(0x1b9),_0x4a9166);});return _0x591795[_0x252e8f(0x1bb)](),['y',_0x252e8f(0x1a0)][_0x252e8f(0x18a)](_0x31b430[_0x252e8f(0x19d)]()[_0x252e8f(0x19c)]());}function a36_0x5719(){const _0x5a72a0=['\x20skipped,\x20','16veJWXh','\x20failed','COMMON','Pull\x20only\x20this\x20script\x20type','utf8','Force\x20pull\x20cancelled.','lockFilePath','push','local\x20unsynced\x20changes','includes','write','2354590NXjQYg','HOOK','4037KsgZIv','toISOString','Would\x20inspect\x20','26HcblqT','pull','datasetCode','8048SRuOzS','\x20remote\x20BFF\x20script(s)\x20for\x20pull','functions','all','functionName','boolean','66phmqfU','hookLocation','toLowerCase','trim','type','conflict','yes','str','--type\x20must\x20be\x20COMMON,\x20ENDPOINT,\x20or\x20HOOK.','parse','apps','Pull\x20complete:\x20','scriptContent','/api/management/library/scripts/list?appCode=','1593370msxAVa','length','692532xzypAx','638160ZrZHdr','appCode','message','operationType','\x22\x20not\x20found\x20after\x20ensureLockScope.','lockKey','validation','apiDir','1503AsVHOx','3035tTwYAa','Lock\x20scope\x20for\x20app\x20\x22','skipped','map','filePath','Force\x20pull\x20will\x20overwrite\x20local\x20unsynced\x20changes.\x20Continue?\x20[y/N]\x20','would_pull','close','Force\x20overwrite\x20local\x20unsynced\x20changes','scriptType','14AeLRcV','nonInteractive','cancelled','scriptsRoot','492ETmQZg','version','alias','lastSync'];a36_0x5719=function(){return _0x5a72a0;};return a36_0x5719();}
1
+ const a36_0x6c3fd8=a36_0x5236;(function(_0x355bdc,_0x3f9572){const _0x46c173=a36_0x5236,_0xe70172=_0x355bdc();while(!![]){try{const _0x52bd26=-parseInt(_0x46c173(0x1db))/0x1*(parseInt(_0x46c173(0x1b1))/0x2)+-parseInt(_0x46c173(0x1b4))/0x3+parseInt(_0x46c173(0x1cc))/0x4*(parseInt(_0x46c173(0x1da))/0x5)+-parseInt(_0x46c173(0x1bc))/0x6*(parseInt(_0x46c173(0x1c9))/0x7)+-parseInt(_0x46c173(0x1d6))/0x8+-parseInt(_0x46c173(0x1d9))/0x9+parseInt(_0x46c173(0x1b5))/0xa;if(_0x52bd26===_0x3f9572)break;else _0xe70172['push'](_0xe70172['shift']());}catch(_0x26a510){_0xe70172['push'](_0xe70172['shift']());}}}(a36_0x59b9,0x3ba0d));import{createInterface}from'node:readline';import{writeFile}from'node:fs/promises';import{listBffScripts,getBffScriptStatistics}from'../../core/api-client.js';function a36_0x5236(_0x28e97a,_0x4b323c){_0x28e97a=_0x28e97a-0x1a9;const _0x59b907=a36_0x59b9();let _0x52360c=_0x59b907[_0x28e97a];return _0x52360c;}import{loadAliasMap}from'../../core/alias-resolver.js';import{resolveApiFilePath}from'../../context.js';import{loadBffProjectConfig}from'../../core/bff/config.js';import{createHookLocationMap,ensureParentDirectory,fileExists,normalizeBffType,resolveRemoteScriptTarget}from'../../core/bff/file-system.js';import{computeContentHash,computeFileHash}from'../../core/bff/hash.js';import{createEmptyBffLock,ensureLockScope,readBffLockFile,writeBffLockFile}from'../../core/bff/lock.js';import{CliErrors}from'../../errors.js';export const bffPull={'service':a36_0x6c3fd8(0x1e9),'command':a36_0x6c3fd8(0x1c2),'description':a36_0x6c3fd8(0x1ab),'risk':a36_0x6c3fd8(0x1cd),'flags':[{'name':a36_0x6c3fd8(0x1d8),'type':a36_0x6c3fd8(0x1ad),'description':a36_0x6c3fd8(0x1c3),'enum':[a36_0x6c3fd8(0x1c7),'ENDPOINT',a36_0x6c3fd8(0x1b7)]},{'name':a36_0x6c3fd8(0x1c8),'type':'boolean','description':a36_0x6c3fd8(0x1b8)}],async 'dryRun'(_0x117cf3){const _0x4d16cd=a36_0x6c3fd8,_0x11e3b4=loadBffProjectConfig(_0x117cf3[_0x4d16cd(0x1be)]),_0x90490d=await readBffLockFile(_0x11e3b4[_0x4d16cd(0x1e7)]),{appLock:_0x48d6a5}=ensureLockScope(_0x90490d??createEmptyBffLock(),_0x117cf3[_0x4d16cd(0x1be)],_0x11e3b4[_0x4d16cd(0x1b2)],_0x4d16cd(0x1c2)),_0x2a71c1=normalizeBffType(_0x117cf3[_0x4d16cd(0x1eb)](_0x4d16cd(0x1d8)))??undefined,_0x54ca3e=buildDatasetCodeToAliasMap(_0x117cf3[_0x4d16cd(0x1de)],_0x117cf3['appCode']),[_0x12b607,_0x29c88d]=await Promise[_0x4d16cd(0x1c4)]([listBffScripts(_0x117cf3['appCode'],_0x2a71c1),getBffScriptStatistics(_0x117cf3[_0x4d16cd(0x1be)])]),_0x1b45d4=createHookLocationMap(_0x29c88d),_0x5ff984=[];for(const _0x28e361 of _0x12b607){const _0x33796f=resolveRemoteScriptTarget(_0x11e3b4,_0x28e361,_0x1b45d4,_0x48d6a5['functions'],_0x54ca3e);if(!_0x33796f){_0x5ff984[_0x4d16cd(0x1e5)]({'scriptType':_0x28e361[_0x4d16cd(0x1d2)],'functionName':_0x28e361[_0x4d16cd(0x1b0)]??'','status':_0x4d16cd(0x1d0),'reason':'unresolvable\x20target\x20path'});continue;}const _0x1b3712=_0x48d6a5[_0x4d16cd(0x1b6)][_0x33796f[_0x4d16cd(0x1df)]],_0x5a20b1=_0x28e361[_0x4d16cd(0x1d4)]!=null?computeContentHash(_0x28e361['scriptContent']):undefined,_0x368dad=await hasUnsyncedLocalChanges(_0x33796f['filePath'],_0x1b3712,_0x5a20b1);_0x5ff984[_0x4d16cd(0x1e5)]({'lockKey':_0x33796f['lockKey'],'filePath':_0x33796f[_0x4d16cd(0x1ca)],'remoteId':_0x28e361['id']??null,'status':_0x368dad?'conflict':_0x4d16cd(0x1e2)});}return{'method':'GET','url':_0x4d16cd(0x1e4)+_0x117cf3['appCode']+(_0x2a71c1?_0x4d16cd(0x1cb)+_0x2a71c1:''),'body':{'appCode':_0x117cf3[_0x4d16cd(0x1be)],'filterType':_0x2a71c1??null,'files':_0x5ff984},'description':_0x4d16cd(0x1aa)+_0x5ff984[_0x4d16cd(0x1d3)]+_0x4d16cd(0x1e3)};},async 'execute'(_0x329ae1){const _0x563b18=a36_0x6c3fd8,_0x36bf89=loadBffProjectConfig(_0x329ae1['appCode']),_0x4629f3=await readBffLockFile(_0x36bf89['lockFilePath']),{lockData:_0x4022a8,appLock:_0x237be6}=ensureLockScope(_0x4629f3??createEmptyBffLock(),_0x329ae1['appCode'],_0x36bf89[_0x563b18(0x1b2)],'pull'),_0x477190=normalizeBffType(_0x329ae1[_0x563b18(0x1eb)](_0x563b18(0x1d8)))??undefined;if(_0x329ae1[_0x563b18(0x1eb)](_0x563b18(0x1d8))&&!_0x477190)throw CliErrors[_0x563b18(0x1ce)](_0x563b18(0x1c1));const [_0x3ec2c9,_0x32301d]=await Promise['all']([listBffScripts(_0x329ae1['appCode'],_0x477190),getBffScriptStatistics(_0x329ae1['appCode'])]);if(_0x3ec2c9['length']===0x0)return{'ok':!![],'data':{'pulled':[],'skipped':[],'failed':[]},'message':_0x563b18(0x1ba)};const _0x5c1cb3=_0x329ae1['bool'](_0x563b18(0x1c8));if(_0x5c1cb3&&!_0x329ae1[_0x563b18(0x1d7)]){const _0x4a133f=await confirmForce();if(!_0x4a133f)throw CliErrors['cancelled'](_0x563b18(0x1ec));}if(_0x5c1cb3&&_0x329ae1[_0x563b18(0x1d7)]){}const _0x26b408=buildDatasetCodeToAliasMap(_0x329ae1[_0x563b18(0x1de)],_0x329ae1['appCode']),_0x4a3e8f=createHookLocationMap(_0x32301d),_0x32de9d=JSON[_0x563b18(0x1ed)](JSON['stringify'](_0x4022a8)),_0x5c828c=_0x329ae1[_0x563b18(0x1be)],_0x16ad90=_0x32de9d['apps'][_0x5c828c];if(!_0x16ad90)throw new Error('Lock\x20scope\x20for\x20app\x20\x22'+_0x5c828c+'\x22\x20not\x20found\x20after\x20ensureLockScope.');const _0x595e70=[],_0x215e12=[],_0x541ce4=[];for(const _0x3411d6 of _0x3ec2c9){const _0xcb33e6=resolveRemoteScriptTarget(_0x36bf89,_0x3411d6,_0x4a3e8f,_0x237be6[_0x563b18(0x1b6)],_0x26b408);if(!_0xcb33e6){_0x215e12[_0x563b18(0x1e5)]({'lockKey':_0x3411d6[_0x563b18(0x1d2)]+'/'+_0x3411d6[_0x563b18(0x1b0)],'reason':'unresolvable\x20target\x20path'});continue;}const _0xc53293=_0x237be6[_0x563b18(0x1b6)][_0xcb33e6[_0x563b18(0x1df)]];try{if(!_0x3411d6['id'])throw new Error(_0x563b18(0x1c0));if(_0x3411d6[_0x563b18(0x1d4)]==null)throw new Error(_0x563b18(0x1af));const _0x3e2cc0=_0x3411d6[_0x563b18(0x1d4)],_0x55e058=computeContentHash(_0x3e2cc0);if(!_0x5c1cb3){const _0x3f50d1=await hasUnsyncedLocalChanges(_0xcb33e6[_0x563b18(0x1ca)],_0xc53293,_0x55e058);if(_0x3f50d1){_0x215e12[_0x563b18(0x1e5)]({'lockKey':_0xcb33e6['lockKey'],'reason':_0x563b18(0x1dd)});continue;}}await ensureParentDirectory(_0xcb33e6[_0x563b18(0x1ca)]),await writeFile(_0xcb33e6[_0x563b18(0x1ca)],_0x3e2cc0,_0x563b18(0x1ea));const _0x601473={'hash':_0x55e058,'remoteId':_0x3411d6['id'],'version':_0x3411d6[_0x563b18(0x1e8)]};_0xcb33e6[_0x563b18(0x1d8)]==='HOOK'&&_0xcb33e6[_0x563b18(0x1d5)]&&(_0x601473[_0x563b18(0x1bf)]=_0xcb33e6['hookLocation'][_0x563b18(0x1bf)],_0x601473[_0x563b18(0x1cf)]=_0xcb33e6[_0x563b18(0x1d5)][_0x563b18(0x1cf)],_0x601473[_0x563b18(0x1a9)]=_0xcb33e6[_0x563b18(0x1d5)]['operationType'],_0x601473[_0x563b18(0x1e0)]=_0xcb33e6['hookLocation']['functionNode']),_0x16ad90[_0x563b18(0x1b6)][_0xcb33e6[_0x563b18(0x1df)]]=_0x601473,_0x595e70[_0x563b18(0x1e5)]({'lockKey':_0xcb33e6[_0x563b18(0x1df)],'remoteId':_0x3411d6['id']});}catch(_0x548313){_0x541ce4[_0x563b18(0x1e5)]({'lockKey':_0xcb33e6[_0x563b18(0x1df)],'error':_0x548313 instanceof Error?_0x548313[_0x563b18(0x1b3)]:String(_0x548313)});}}return _0x16ad90['lastSync']=new Date()[_0x563b18(0x1bd)](),await writeBffLockFile(_0x36bf89['lockFilePath'],_0x32de9d),{'ok':_0x541ce4['length']===0x0,'data':{'pulled':_0x595e70,'skipped':_0x215e12,'failed':_0x541ce4},'message':'Pull\x20complete:\x20'+_0x595e70[_0x563b18(0x1d3)]+_0x563b18(0x1d1)+_0x215e12['length']+_0x563b18(0x1ae)+_0x541ce4[_0x563b18(0x1d3)]+'\x20failed'};}};function a36_0x59b9(){const _0x24cd7c=['HOOK','Force\x20overwrite\x20local\x20unsynced\x20changes','hash','No\x20remote\x20BFF\x20scripts\x20found.','toLowerCase','1308tNsoyw','toISOString','appCode','alias','Remote\x20script\x20missing\x20id.','--type\x20must\x20be\x20COMMON,\x20ENDPOINT,\x20or\x20HOOK.','pull','Pull\x20only\x20this\x20script\x20type','all','map','yes','COMMON','force','553nWIgpX','filePath','&type=','327156NdHcYA','write','validation','datasetCode','skipped','\x20pulled,\x20','scriptType','length','scriptContent','hookLocation','2504648aNjuTs','nonInteractive','type','951255BYawwK','15qUDXqr','4xFIMIQ','includes','local\x20unsynced\x20changes','apiDir','lockKey','functionNode','stderr','would_pull','\x20remote\x20BFF\x20script(s)\x20for\x20pull','/api/management/library/scripts/list?appCode=','push','question','lockFilePath','version','bff','utf8','str','Force\x20pull\x20cancelled.','parse','operationType','Would\x20inspect\x20','Pull\x20remote\x20BFF\x20scripts\x20to\x20local','Force\x20pull\x20will\x20overwrite\x20local\x20unsynced\x20changes.\x20Continue?\x20[y/N]\x20','string','\x20skipped,\x20','Remote\x20script\x20missing\x20content.','functionName','102862ygbJTi','scriptsRoot','message','670482FkuwUz','8640860qrSUDh','functions'];a36_0x59b9=function(){return _0x24cd7c;};return a36_0x59b9();}async function hasUnsyncedLocalChanges(_0x1f421a,_0x205aed,_0x5a0ebc){const _0x3f407a=a36_0x6c3fd8;if(!await fileExists(_0x1f421a))return![];const _0x41b11b=await computeFileHash(_0x1f421a);if(!_0x205aed)return _0x5a0ebc?_0x41b11b!==_0x5a0ebc:!![];return _0x41b11b!==_0x205aed[_0x3f407a(0x1b9)];}function buildDatasetCodeToAliasMap(_0x24124d,_0x47cef8){const _0x2f8efd=a36_0x6c3fd8,_0x1af0c0=loadAliasMap(_0x24124d,undefined,resolveApiFilePath(_0x24124d,_0x47cef8));return new Map(_0x1af0c0[_0x2f8efd(0x1c5)](_0x34ad5c=>[_0x34ad5c[_0x2f8efd(0x1cf)],_0x34ad5c[_0x2f8efd(0x1bf)]]));}async function confirmForce(){const _0x137697=a36_0x6c3fd8,_0x393fa4=createInterface({'input':process['stdin'],'output':process[_0x137697(0x1e1)]}),_0x1ec08d=await new Promise(_0x90d189=>{const _0x3057ce=_0x137697;_0x393fa4[_0x3057ce(0x1e6)](_0x3057ce(0x1ac),_0x90d189);});return _0x393fa4['close'](),['y',_0x137697(0x1c6)][_0x137697(0x1dc)](_0x1ec08d['trim']()[_0x137697(0x1bb)]());}
@@ -1 +1 @@
1
- const a37_0x5a71af=a37_0x1584;(function(_0x4b8eef,_0x46e949){const _0x54e554=a37_0x1584,_0x1bfd56=_0x4b8eef();while(!![]){try{const _0xad450c=parseInt(_0x54e554(0x1b8))/0x1+-parseInt(_0x54e554(0x1f2))/0x2*(parseInt(_0x54e554(0x1cd))/0x3)+parseInt(_0x54e554(0x1db))/0x4*(parseInt(_0x54e554(0x1b5))/0x5)+-parseInt(_0x54e554(0x1b1))/0x6+-parseInt(_0x54e554(0x1be))/0x7+parseInt(_0x54e554(0x19d))/0x8+-parseInt(_0x54e554(0x1de))/0x9;if(_0xad450c===_0x46e949)break;else _0x1bfd56['push'](_0x1bfd56['shift']());}catch(_0x282a4c){_0x1bfd56['push'](_0x1bfd56['shift']());}}}(a37_0x2172,0x60303));import{readFile}from'node:fs/promises';import{saveBffScript,getBffScriptInfo,listDatasets,clearBffScriptCache}from'../../core/api-client.js';import{loadAliasMap}from'../../core/alias-resolver.js';function a37_0x2172(){const _0x361630=['582102XHhNXp','apiDir','runtime\x20cache\x20clear\x20failed','create','POST','Push\x20complete:\x20','1638336PvJjCm','filter','validation','Push\x20only\x20the\x20named\x20function\x20(requires\x20--type)','status','aliasToDatasetCode','lockKey','map','HOOK','Force\x20push\x20ignoring\x20hash\x20protection','set','lockFilePath','bff','/api/management/library/scripts/save','get','147lVlCTi','Runtime\x20script\x20cache\x20cleared.','string','\x20local\x20BFF\x20script(s)\x20for\x20push\x20and\x20clear\x20runtime\x20cache\x20if\x20files\x20are\x20uploaded','runtime\x20cache\x20not\x20needed','code','high-risk-write','has','length','COMMON','\x22\x20not\x20found\x20after\x20ensureLockScope.','boolean','\x20api\x20pull`\x20to\x20refresh\x20api.ts,\x20or\x20verify\x20the\x20dataset\x20exists.','hash','16KcrwJC','attempted','push','288999JAhLwg','str','operationType','Would\x20inspect\x20','join','\x20skipped,\x20','cleared','unchanged','remoteId','stringify','update','some','Incomplete\x20HOOK\x20path:\x20','type','--name\x20requires\x20--type\x20to\x20identify\x20the\x20function.','every','apps','message','Local\x20function\x20not\x20found:\x20','utf8','27986ZFLDXl','name','1989128OufLGT','functionNode','datasetCode','force','ENDPOINT','filePath','datasetCodeToDataset','Run\x20`','scriptsRoot','version','alias','\x20uploaded,\x20','description',':\x20missing\x20remote\x20version.\x20Run\x20`push`\x20after\x20`pull`\x20to\x20sync\x20version\x20info.','bool','functions','values','would_push','No\x20local\x20BFF\x20functions\x20found.','Push\x20local\x20BFF\x20scripts\x20to\x20remote','1157088idIfLj','\x20failed,\x20','datasetId','\x22.\x20','884885LzzjIO','runtime\x20cache\x20cleared','appCode'];a37_0x2172=function(){return _0x361630;};return a37_0x2172();}import{resolveApiFilePath}from'../../context.js';import{loadBffProjectConfig}from'../../core/bff/config.js';import{normalizeBffType,scanLocalBffFunctions}from'../../core/bff/file-system.js';import{computeFileHash}from'../../core/bff/hash.js';function a37_0x1584(_0x259b21,_0x109b6c){_0x259b21=_0x259b21-0x19c;const _0x217292=a37_0x2172();let _0x15842f=_0x217292[_0x259b21];return _0x15842f;}import{createEmptyBffLock,ensureLockScope,readBffLockFile,writeBffLockFile}from'../../core/bff/lock.js';import{extractScriptDescription}from'../../core/bff/utils.js';import{sleep}from'../../utils/sleep.js';import{CliErrors}from'../../errors.js';import{CLI_BIN_NAME}from'../../constant/cli.js';const CACHE_CLEAR_ATTEMPTS=0x2,CACHE_CLEAR_INTERVAL_MS=0x12c;export const bffPush={'service':a37_0x5a71af(0x1ca),'command':a37_0x5a71af(0x1dd),'description':a37_0x5a71af(0x1b0),'risk':a37_0x5a71af(0x1d3),'flags':[{'name':'type','type':a37_0x5a71af(0x1cf),'description':'Push\x20only\x20this\x20script\x20type','enum':[a37_0x5a71af(0x1d6),a37_0x5a71af(0x1a1),a37_0x5a71af(0x1c6)]},{'name':'name','type':a37_0x5a71af(0x1cf),'description':a37_0x5a71af(0x1c1)},{'name':'force','type':a37_0x5a71af(0x1d8),'description':a37_0x5a71af(0x1c7)}],async 'dryRun'(_0x5aef65){const _0x3eb5ce=a37_0x5a71af,_0x2c7a73=loadBffProjectConfig(_0x5aef65[_0x3eb5ce(0x1b7)]),_0x2d0ed9=await readBffLockFile(_0x2c7a73[_0x3eb5ce(0x1c9)]),{appLock:_0x2090e2}=ensureLockScope(_0x2d0ed9??createEmptyBffLock(),_0x5aef65[_0x3eb5ce(0x1b7)],_0x2c7a73[_0x3eb5ce(0x1a5)],_0x3eb5ce(0x1dd)),_0x2cab87=await getTargetFunctions(_0x2c7a73,_0x5aef65),_0x1eca2e=_0x5aef65[_0x3eb5ce(0x1ab)]('force'),_0x24482e=[];for(const _0x59a340 of _0x2cab87){const _0x3a7a95=await computeFileHash(_0x59a340[_0x3eb5ce(0x1a2)]),_0x33cb66=_0x2090e2[_0x3eb5ce(0x1ac)][_0x59a340['lockKey']],_0x76b636=!!_0x33cb66&&_0x33cb66[_0x3eb5ce(0x1da)]===_0x3a7a95;_0x24482e['push']({'lockKey':_0x59a340[_0x3eb5ce(0x1c4)],'filePath':_0x59a340[_0x3eb5ce(0x1a2)],'remoteId':_0x33cb66?.[_0x3eb5ce(0x1e6)]??null,'mode':_0x33cb66?.[_0x3eb5ce(0x1e6)]?_0x3eb5ce(0x1e8):_0x3eb5ce(0x1bb),'status':!_0x1eca2e&&_0x76b636?_0x3eb5ce(0x1e5):_0x3eb5ce(0x1ae)});}return{'method':_0x3eb5ce(0x1bc),'url':_0x3eb5ce(0x1cb),'body':{'appCode':_0x5aef65[_0x3eb5ce(0x1b7)],'force':_0x1eca2e,'files':_0x24482e,'cacheClearAtRuntime':_0x24482e[_0x3eb5ce(0x1e9)](_0x1b4418=>_0x1b4418[_0x3eb5ce(0x1c2)]==='would_push'),'cacheClearAtRuntimeTimes':_0x24482e[_0x3eb5ce(0x1e9)](_0x1d3a54=>_0x1d3a54['status']===_0x3eb5ce(0x1ae))?CACHE_CLEAR_ATTEMPTS:0x0},'description':_0x3eb5ce(0x1e1)+_0x24482e[_0x3eb5ce(0x1d5)]+_0x3eb5ce(0x1d0)};},async 'execute'(_0x2ac521){const _0x4b0149=a37_0x5a71af,_0x3edb02=loadBffProjectConfig(_0x2ac521[_0x4b0149(0x1b7)]),_0x102bbe=await readBffLockFile(_0x3edb02[_0x4b0149(0x1c9)]),{lockData:_0x590d89,appLock:_0x40a949}=ensureLockScope(_0x102bbe??createEmptyBffLock(),_0x2ac521['appCode'],_0x3edb02[_0x4b0149(0x1a5)],_0x4b0149(0x1dd)),_0x26234d=await getTargetFunctions(_0x3edb02,_0x2ac521);if(_0x26234d['length']===0x0)return{'ok':!![],'data':{'uploaded':[],'skipped':[],'failed':[]},'message':_0x4b0149(0x1af)};const _0xfadad2=_0x2ac521[_0x4b0149(0x1ab)](_0x4b0149(0x1a0)),_0x501b36=JSON['parse'](JSON[_0x4b0149(0x1e7)](_0x590d89)),_0x4443d7=_0x501b36[_0x4b0149(0x1ee)][_0x2ac521[_0x4b0149(0x1b7)]];if(!_0x4443d7)throw new Error('Lock\x20scope\x20for\x20app\x20\x22'+_0x2ac521[_0x4b0149(0x1b7)]+_0x4b0149(0x1d7));const _0x4b65fe=await buildHookMaps(_0x2ac521[_0x4b0149(0x1b7)],_0x2ac521[_0x4b0149(0x1b9)],_0x26234d,_0x4443d7),_0x3e00db=[],_0x8533ec=[],_0x49bc89=[];for(const _0x12a9ce of _0x26234d){const _0x5ea8ea=await computeFileHash(_0x12a9ce['filePath']),_0x523df=_0x4443d7[_0x4b0149(0x1ac)][_0x12a9ce[_0x4b0149(0x1c4)]];if(!_0xfadad2&&_0x523df&&_0x523df[_0x4b0149(0x1da)]===_0x5ea8ea){_0x8533ec[_0x4b0149(0x1dd)]({'lockKey':_0x12a9ce[_0x4b0149(0x1c4)],'reason':'unchanged'});continue;}try{await uploadSingleFunction(_0x2ac521[_0x4b0149(0x1b7)],_0x12a9ce,_0x4443d7,_0x4b65fe);const _0x30561a=_0x4443d7[_0x4b0149(0x1ac)][_0x12a9ce[_0x4b0149(0x1c4)]];_0x3e00db[_0x4b0149(0x1dd)]({'lockKey':_0x12a9ce[_0x4b0149(0x1c4)],'remoteId':_0x30561a?.[_0x4b0149(0x1e6)]??0x0});}catch(_0xea13fa){_0x49bc89['push']({'lockKey':_0x12a9ce['lockKey'],'error':_0xea13fa instanceof Error?_0xea13fa[_0x4b0149(0x1ef)]:String(_0xea13fa)});}}_0x4443d7['lastSync']=new Date()['toISOString'](),await writeBffLockFile(_0x3edb02['lockFilePath'],_0x501b36),await waitForUploadedLockEntries(_0x3edb02[_0x4b0149(0x1c9)],_0x2ac521[_0x4b0149(0x1b7)],_0x3e00db[_0x4b0149(0x1c5)](_0x380a1c=>_0x380a1c[_0x4b0149(0x1c4)]));let _0x4310a3={'attempted':![],'cleared':![]};if(_0x3e00db['length']>0x0)try{let _0x588490='';for(let _0x2189e7=0x0;_0x2189e7<CACHE_CLEAR_ATTEMPTS;_0x2189e7+=0x1){_0x588490=await clearBffScriptCache(),_0x2189e7<CACHE_CLEAR_ATTEMPTS-0x1&&await sleep(CACHE_CLEAR_INTERVAL_MS);}_0x4310a3={'attempted':!![],'cleared':!![],'message':_0x588490||_0x4b0149(0x1ce)};}catch(_0x189124){_0x4310a3={'attempted':!![],'cleared':![],'error':_0x189124 instanceof Error?_0x189124[_0x4b0149(0x1ef)]:String(_0x189124)};}const _0x3f28c1=_0x49bc89[_0x4b0149(0x1d5)]===0x0&&(_0x4310a3[_0x4b0149(0x1dc)]?_0x4310a3[_0x4b0149(0x1e4)]:!![]),_0xf36a9d=_0x4310a3[_0x4b0149(0x1dc)]?_0x4310a3[_0x4b0149(0x1e4)]?_0x4b0149(0x1b6):_0x4b0149(0x1ba):_0x4b0149(0x1d1);return{'ok':_0x3f28c1,'data':{'uploaded':_0x3e00db,'skipped':_0x8533ec,'failed':_0x49bc89,'cacheClear':_0x4310a3},'message':_0x4b0149(0x1bd)+_0x3e00db[_0x4b0149(0x1d5)]+_0x4b0149(0x1a8)+_0x8533ec[_0x4b0149(0x1d5)]+_0x4b0149(0x1e3)+_0x49bc89['length']+_0x4b0149(0x1b2)+_0xf36a9d};}};async function getTargetFunctions(_0x59ecad,_0x489b31){const _0x1fbb02=a37_0x5a71af,_0x344b1f=_0x489b31[_0x1fbb02(0x1df)](_0x1fbb02(0x1eb)),_0x353ab3=_0x489b31[_0x1fbb02(0x1df)](_0x1fbb02(0x19c)),_0x33d769=normalizeBffType(_0x344b1f)??undefined;if(_0x353ab3&&!_0x33d769)throw CliErrors[_0x1fbb02(0x1c0)](_0x1fbb02(0x1ec));const _0x1fffbe=await scanLocalBffFunctions(_0x59ecad,_0x33d769);if(_0x353ab3){const _0x40b36b=_0x1fffbe[_0x1fbb02(0x1bf)](_0x28ce1b=>_0x28ce1b['name']===_0x353ab3);if(_0x40b36b[_0x1fbb02(0x1d5)]===0x0)throw CliErrors[_0x1fbb02(0x1c0)](_0x1fbb02(0x1f0)+_0x33d769+'/'+_0x353ab3);return _0x40b36b;}return _0x1fffbe;}async function buildHookMaps(_0x58d552,_0x4c6f0e,_0x18ef72,_0x4401ae){const _0x10b753=a37_0x5a71af,_0x2d914a=_0x18ef72['some'](_0x5a1e6b=>_0x5a1e6b['type']===_0x10b753(0x1c6));if(!_0x2d914a)return{'aliasToDatasetCode':new Map(),'datasetCodeToDataset':new Map()};const _0x3392e0=loadAliasMap(_0x4c6f0e,undefined,resolveApiFilePath(_0x4c6f0e,_0x58d552)),_0x349dbc=new Map(_0x3392e0[_0x10b753(0x1c5)](_0x1751f9=>[_0x1751f9['alias'],_0x1751f9[_0x10b753(0x19f)]]));for(const _0x9f59a3 of Object[_0x10b753(0x1ad)](_0x4401ae[_0x10b753(0x1ac)])){_0x9f59a3[_0x10b753(0x1a7)]&&_0x9f59a3['datasetCode']&&!_0x349dbc[_0x10b753(0x1d4)](_0x9f59a3[_0x10b753(0x1a7)])&&_0x349dbc[_0x10b753(0x1c8)](_0x9f59a3[_0x10b753(0x1a7)],_0x9f59a3[_0x10b753(0x19f)]);}const _0x2c3d54=await listDatasets(_0x58d552),_0x2a4f5f=new Map(_0x2c3d54[_0x10b753(0x1c5)](_0x41da8e=>[_0x41da8e[_0x10b753(0x1d2)],_0x41da8e]));return{'aliasToDatasetCode':_0x349dbc,'datasetCodeToDataset':_0x2a4f5f};}async function uploadSingleFunction(_0x2e9edc,_0x164c2c,_0x4d46cb,_0x333d34){const _0x4dcd82=a37_0x5a71af,_0xa4533c=await readFile(_0x164c2c[_0x4dcd82(0x1a2)],_0x4dcd82(0x1f1)),_0x4e2926=await computeFileHash(_0x164c2c['filePath']),_0x50c7eb=_0x4d46cb[_0x4dcd82(0x1ac)][_0x164c2c[_0x4dcd82(0x1c4)]];if(_0x50c7eb?.[_0x4dcd82(0x1e6)]&&_0x50c7eb[_0x4dcd82(0x1a6)]==null)throw CliErrors[_0x4dcd82(0x1c0)](_0x164c2c[_0x4dcd82(0x1c4)]+_0x4dcd82(0x1aa));let _0x38bec0=extractScriptDescription(_0xa4533c);if(!_0x38bec0&&_0x50c7eb?.[_0x4dcd82(0x1e6)]){const _0x505aa5=await getBffScriptInfo(_0x50c7eb[_0x4dcd82(0x1e6)]);_0x38bec0=_0x505aa5['description']||undefined;}const _0x5378ee={'appCode':_0x2e9edc,'functionName':_0x164c2c['name'],'scriptType':_0x164c2c['type'],'scriptContent':_0xa4533c};if(_0x50c7eb?.[_0x4dcd82(0x1e6)])_0x5378ee['id']=_0x50c7eb[_0x4dcd82(0x1e6)];if(_0x50c7eb?.[_0x4dcd82(0x1a6)]!=null)_0x5378ee[_0x4dcd82(0x1a6)]=_0x50c7eb[_0x4dcd82(0x1a6)];if(_0x38bec0)_0x5378ee[_0x4dcd82(0x1a9)]=_0x38bec0;if(_0x164c2c['type']===_0x4dcd82(0x1c6)){const _0x53dcd7=_0x164c2c['alias'];if(!_0x53dcd7||!_0x164c2c['operationType']||!_0x164c2c['functionNode'])throw CliErrors[_0x4dcd82(0x1c0)](_0x4dcd82(0x1ea)+_0x164c2c[_0x4dcd82(0x1c4)]);const _0x37b004=_0x333d34[_0x4dcd82(0x1c3)][_0x4dcd82(0x1cc)](_0x53dcd7)??_0x50c7eb?.[_0x4dcd82(0x19f)]??_0x53dcd7,_0x2b8ac7=_0x333d34[_0x4dcd82(0x1a3)]['get'](_0x37b004);if(!_0x2b8ac7)throw CliErrors['validation']('Cannot\x20resolve\x20dataset\x20for\x20\x22'+_0x53dcd7+_0x4dcd82(0x1b4)+(_0x4dcd82(0x1a4)+CLI_BIN_NAME+_0x4dcd82(0x1d9)));_0x5378ee[_0x4dcd82(0x1b3)]=_0x2b8ac7['id'],_0x5378ee[_0x4dcd82(0x1e0)]=_0x164c2c[_0x4dcd82(0x1e0)],_0x5378ee['functionNode']=_0x164c2c[_0x4dcd82(0x19e)];}const _0x125bce=await saveBffScript(_0x5378ee),_0x5b0040=_0x125bce['id'],_0x2472ee=_0x125bce['script']??await getBffScriptInfo(_0x5b0040),_0x246656={'hash':_0x4e2926,'remoteId':_0x5b0040,'version':_0x2472ee[_0x4dcd82(0x1a6)]};if(_0x164c2c[_0x4dcd82(0x1eb)]==='HOOK'){const _0x1de761=_0x164c2c['alias'],_0x5c14fa=_0x333d34[_0x4dcd82(0x1c3)]['get'](_0x1de761)??_0x50c7eb?.[_0x4dcd82(0x19f)]??_0x1de761;_0x333d34[_0x4dcd82(0x1c3)][_0x4dcd82(0x1d4)](_0x1de761)?_0x246656['alias']=_0x1de761:_0x246656[_0x4dcd82(0x1a7)]=_0x50c7eb?.[_0x4dcd82(0x1a7)],_0x246656[_0x4dcd82(0x19f)]=_0x5c14fa,_0x246656[_0x4dcd82(0x1e0)]=_0x164c2c[_0x4dcd82(0x1e0)],_0x246656['functionNode']=_0x164c2c[_0x4dcd82(0x19e)];}_0x4d46cb['functions'][_0x164c2c[_0x4dcd82(0x1c4)]]=_0x246656;}const LOCK_SETTLE_RETRY_COUNT=0x14,LOCK_SETTLE_DELAY_MS=0x64;async function waitForUploadedLockEntries(_0x4701a4,_0x4e3d39,_0xcf6733){const _0x19e920=a37_0x5a71af;if(_0xcf6733[_0x19e920(0x1d5)]===0x0)return;for(let _0x405e1d=0x0;_0x405e1d<LOCK_SETTLE_RETRY_COUNT;_0x405e1d+=0x1){const _0xe7b276=await readBffLockFile(_0x4701a4),_0x101036=_0xe7b276?.['apps']?.[_0x4e3d39]?.[_0x19e920(0x1ac)]??{},_0x53ecbc=_0xcf6733[_0x19e920(0x1ed)](_0x2a59f2=>!!_0x101036[_0x2a59f2]?.['remoteId']);if(_0x53ecbc)return;await sleep(LOCK_SETTLE_DELAY_MS);}throw new Error('Lock\x20file\x20not\x20settled\x20after\x20push\x20for\x20'+_0xcf6733[_0x19e920(0x1e2)](',\x20')+'.');}
1
+ const a37_0x4b3084=a37_0x5414;(function(_0x4ee80b,_0x12f66c){const _0x5ae58a=a37_0x5414,_0x5d2956=_0x4ee80b();while(!![]){try{const _0x54eff8=parseInt(_0x5ae58a(0x1b8))/0x1*(parseInt(_0x5ae58a(0x196))/0x2)+parseInt(_0x5ae58a(0x167))/0x3*(parseInt(_0x5ae58a(0x18e))/0x4)+parseInt(_0x5ae58a(0x17b))/0x5+parseInt(_0x5ae58a(0x1a4))/0x6*(-parseInt(_0x5ae58a(0x175))/0x7)+parseInt(_0x5ae58a(0x1a2))/0x8*(parseInt(_0x5ae58a(0x169))/0x9)+-parseInt(_0x5ae58a(0x16c))/0xa+-parseInt(_0x5ae58a(0x180))/0xb*(parseInt(_0x5ae58a(0x192))/0xc);if(_0x54eff8===_0x12f66c)break;else _0x5d2956['push'](_0x5d2956['shift']());}catch(_0x3d335d){_0x5d2956['push'](_0x5d2956['shift']());}}}(a37_0x1218,0xe8b7d));import{readFile}from'node:fs/promises';import{saveBffScript,getBffScriptInfo,listDatasets,clearBffScriptCache}from'../../core/api-client.js';import{loadAliasMap}from'../../core/alias-resolver.js';function a37_0x5414(_0x5189b5,_0x240539){_0x5189b5=_0x5189b5-0x167;const _0x12185e=a37_0x1218();let _0x54144d=_0x12185e[_0x5189b5];return _0x54144d;}import{resolveApiFilePath}from'../../context.js';import{loadBffProjectConfig}from'../../core/bff/config.js';import{normalizeBffType,scanLocalBffFunctions}from'../../core/bff/file-system.js';import{computeFileHash}from'../../core/bff/hash.js';import{createEmptyBffLock,ensureLockScope,readBffLockFile,writeBffLockFile}from'../../core/bff/lock.js';import{extractScriptDescription}from'../../core/bff/utils.js';import{sleep}from'../../utils/sleep.js';import{CliErrors}from'../../errors.js';function a37_0x1218(){const _0x26a498=['Push\x20complete:\x20','13488750OHyNzZ','/api/management/library/scripts/save','Local\x20function\x20not\x20found:\x20','bool','status','stringify','create','filePath','type','7kKQAVS','scriptsRoot','Runtime\x20script\x20cache\x20cleared.','toISOString','Push\x20only\x20this\x20script\x20type','appCode','7230060JWjQaS','aliasToDatasetCode','runtime\x20cache\x20clear\x20failed','remoteId','version','55MBoqLZ','map','every','has','hash','set','attempted','parse','code','name','apiDir','unchanged','functions','\x20uploaded,\x20','4bJCTrM','values','string','some','1963956ZRhDNv','lastSync',':\x20missing\x20remote\x20version.\x20Run\x20`push`\x20after\x20`pull`\x20to\x20sync\x20version\x20info.','Force\x20push\x20ignoring\x20hash\x20protection','42232vwSNEw','functionNode','datasetId','length','datasetCodeToDataset','would_push','\x20failed,\x20','HOOK','datasetCode','utf8','Would\x20inspect\x20','force','1180056KefBcH','ENDPOINT','889944MyPQeR','\x20skipped,\x20','Lock\x20scope\x20for\x20app\x20\x22','description','\x22\x20not\x20found\x20after\x20ensureLockScope.','Push\x20local\x20BFF\x20scripts\x20to\x20remote','\x20local\x20BFF\x20script(s)\x20for\x20push\x20and\x20clear\x20runtime\x20cache\x20if\x20files\x20are\x20uploaded','cleared','Run\x20`','apps','operationType','--name\x20requires\x20--type\x20to\x20identify\x20the\x20function.','lockFilePath','filter','push','get','alias','No\x20local\x20BFF\x20functions\x20found.','str','lockKey','63VCTOVO','runtime\x20cache\x20not\x20needed','149658JzmXNT','POST','27XSIpJW','validation'];a37_0x1218=function(){return _0x26a498;};return a37_0x1218();}import{CLI_BIN_NAME}from'../../constant/cli.js';const CACHE_CLEAR_ATTEMPTS=0x2,CACHE_CLEAR_INTERVAL_MS=0x12c;export const bffPush={'service':'bff','command':a37_0x4b3084(0x1b2),'description':a37_0x4b3084(0x1a9),'risk':'high-risk-write','flags':[{'name':a37_0x4b3084(0x174),'type':a37_0x4b3084(0x190),'description':a37_0x4b3084(0x179),'enum':['COMMON',a37_0x4b3084(0x1a3),a37_0x4b3084(0x19d)]},{'name':'name','type':a37_0x4b3084(0x190),'description':'Push\x20only\x20the\x20named\x20function\x20(requires\x20--type)'},{'name':a37_0x4b3084(0x1a1),'type':'boolean','description':a37_0x4b3084(0x195)}],async 'dryRun'(_0x16bd47){const _0xe8d6b0=a37_0x4b3084,_0x4daaa0=loadBffProjectConfig(_0x16bd47[_0xe8d6b0(0x17a)]),_0x2cef5f=await readBffLockFile(_0x4daaa0[_0xe8d6b0(0x1b0)]),{appLock:_0x4d932b}=ensureLockScope(_0x2cef5f??createEmptyBffLock(),_0x16bd47['appCode'],_0x4daaa0['scriptsRoot'],_0xe8d6b0(0x1b2)),_0x3b9176=await getTargetFunctions(_0x4daaa0,_0x16bd47),_0x476251=_0x16bd47[_0xe8d6b0(0x16f)](_0xe8d6b0(0x1a1)),_0x32ad01=[];for(const _0x499127 of _0x3b9176){const _0x2b3a3e=await computeFileHash(_0x499127[_0xe8d6b0(0x173)]),_0x2733cc=_0x4d932b[_0xe8d6b0(0x18c)][_0x499127['lockKey']],_0x724c5c=!!_0x2733cc&&_0x2733cc['hash']===_0x2b3a3e;_0x32ad01[_0xe8d6b0(0x1b2)]({'lockKey':_0x499127[_0xe8d6b0(0x1b7)],'filePath':_0x499127[_0xe8d6b0(0x173)],'remoteId':_0x2733cc?.[_0xe8d6b0(0x17e)]??null,'mode':_0x2733cc?.['remoteId']?'update':_0xe8d6b0(0x172),'status':!_0x476251&&_0x724c5c?'unchanged':_0xe8d6b0(0x19b)});}return{'method':_0xe8d6b0(0x168),'url':_0xe8d6b0(0x16d),'body':{'appCode':_0x16bd47[_0xe8d6b0(0x17a)],'force':_0x476251,'files':_0x32ad01,'cacheClearAtRuntime':_0x32ad01[_0xe8d6b0(0x191)](_0x48cf16=>_0x48cf16['status']===_0xe8d6b0(0x19b)),'cacheClearAtRuntimeTimes':_0x32ad01[_0xe8d6b0(0x191)](_0x18e2cf=>_0x18e2cf[_0xe8d6b0(0x170)]===_0xe8d6b0(0x19b))?CACHE_CLEAR_ATTEMPTS:0x0},'description':_0xe8d6b0(0x1a0)+_0x32ad01[_0xe8d6b0(0x199)]+_0xe8d6b0(0x1aa)};},async 'execute'(_0x2370d6){const _0x57f5ef=a37_0x4b3084,_0x50d869=loadBffProjectConfig(_0x2370d6[_0x57f5ef(0x17a)]),_0x39b34b=await readBffLockFile(_0x50d869['lockFilePath']),{lockData:_0x8211a7,appLock:_0x40db8f}=ensureLockScope(_0x39b34b??createEmptyBffLock(),_0x2370d6[_0x57f5ef(0x17a)],_0x50d869[_0x57f5ef(0x176)],_0x57f5ef(0x1b2)),_0x3001f1=await getTargetFunctions(_0x50d869,_0x2370d6);if(_0x3001f1[_0x57f5ef(0x199)]===0x0)return{'ok':!![],'data':{'uploaded':[],'skipped':[],'failed':[]},'message':_0x57f5ef(0x1b5)};const _0x1eaf81=_0x2370d6['bool']('force'),_0x5b691e=JSON[_0x57f5ef(0x187)](JSON[_0x57f5ef(0x171)](_0x8211a7)),_0x4db187=_0x5b691e[_0x57f5ef(0x1ad)][_0x2370d6[_0x57f5ef(0x17a)]];if(!_0x4db187)throw new Error(_0x57f5ef(0x1a6)+_0x2370d6[_0x57f5ef(0x17a)]+_0x57f5ef(0x1a8));const _0x47cc05=await buildHookMaps(_0x2370d6[_0x57f5ef(0x17a)],_0x2370d6[_0x57f5ef(0x18a)],_0x3001f1,_0x4db187),_0x558de8=[],_0x2bd2a5=[],_0x534d9f=[];for(const _0x5b1c3c of _0x3001f1){const _0x1fbdef=await computeFileHash(_0x5b1c3c[_0x57f5ef(0x173)]),_0x49022f=_0x4db187[_0x57f5ef(0x18c)][_0x5b1c3c[_0x57f5ef(0x1b7)]];if(!_0x1eaf81&&_0x49022f&&_0x49022f[_0x57f5ef(0x184)]===_0x1fbdef){_0x2bd2a5[_0x57f5ef(0x1b2)]({'lockKey':_0x5b1c3c['lockKey'],'reason':_0x57f5ef(0x18b)});continue;}try{await uploadSingleFunction(_0x2370d6[_0x57f5ef(0x17a)],_0x5b1c3c,_0x4db187,_0x47cc05);const _0x14e7a3=_0x4db187['functions'][_0x5b1c3c[_0x57f5ef(0x1b7)]];_0x558de8['push']({'lockKey':_0x5b1c3c['lockKey'],'remoteId':_0x14e7a3?.[_0x57f5ef(0x17e)]??0x0});}catch(_0x3e21ad){_0x534d9f['push']({'lockKey':_0x5b1c3c[_0x57f5ef(0x1b7)],'error':_0x3e21ad instanceof Error?_0x3e21ad['message']:String(_0x3e21ad)});}}_0x4db187[_0x57f5ef(0x193)]=new Date()[_0x57f5ef(0x178)](),await writeBffLockFile(_0x50d869[_0x57f5ef(0x1b0)],_0x5b691e),await waitForUploadedLockEntries(_0x50d869['lockFilePath'],_0x2370d6['appCode'],_0x558de8['map'](_0x249402=>_0x249402[_0x57f5ef(0x1b7)]));let _0x574edc={'attempted':![],'cleared':![]};if(_0x558de8['length']>0x0)try{let _0xa721b0='';for(let _0x3173b9=0x0;_0x3173b9<CACHE_CLEAR_ATTEMPTS;_0x3173b9+=0x1){_0xa721b0=await clearBffScriptCache(),_0x3173b9<CACHE_CLEAR_ATTEMPTS-0x1&&await sleep(CACHE_CLEAR_INTERVAL_MS);}_0x574edc={'attempted':!![],'cleared':!![],'message':_0xa721b0||_0x57f5ef(0x177)};}catch(_0x19e076){_0x574edc={'attempted':!![],'cleared':![],'error':_0x19e076 instanceof Error?_0x19e076['message']:String(_0x19e076)};}const _0x18d9cb=_0x534d9f[_0x57f5ef(0x199)]===0x0&&(_0x574edc[_0x57f5ef(0x186)]?_0x574edc['cleared']:!![]),_0x20fa10=_0x574edc['attempted']?_0x574edc[_0x57f5ef(0x1ab)]?'runtime\x20cache\x20cleared':_0x57f5ef(0x17d):_0x57f5ef(0x1b9);return{'ok':_0x18d9cb,'data':{'uploaded':_0x558de8,'skipped':_0x2bd2a5,'failed':_0x534d9f,'cacheClear':_0x574edc},'message':_0x57f5ef(0x16b)+_0x558de8[_0x57f5ef(0x199)]+_0x57f5ef(0x18d)+_0x2bd2a5[_0x57f5ef(0x199)]+_0x57f5ef(0x1a5)+_0x534d9f[_0x57f5ef(0x199)]+_0x57f5ef(0x19c)+_0x20fa10};}};async function getTargetFunctions(_0x1e6f72,_0x3f151e){const _0x398fdf=a37_0x4b3084,_0x279fb4=_0x3f151e['str'](_0x398fdf(0x174)),_0x163201=_0x3f151e[_0x398fdf(0x1b6)]('name'),_0x6b6373=normalizeBffType(_0x279fb4)??undefined;if(_0x163201&&!_0x6b6373)throw CliErrors['validation'](_0x398fdf(0x1af));const _0x22ea22=await scanLocalBffFunctions(_0x1e6f72,_0x6b6373);if(_0x163201){const _0x282998=_0x22ea22[_0x398fdf(0x1b1)](_0xe55b2a=>_0xe55b2a[_0x398fdf(0x189)]===_0x163201);if(_0x282998['length']===0x0)throw CliErrors[_0x398fdf(0x16a)](_0x398fdf(0x16e)+_0x6b6373+'/'+_0x163201);return _0x282998;}return _0x22ea22;}async function buildHookMaps(_0x22db46,_0x49e74b,_0x24d046,_0x322eb8){const _0x3f8560=a37_0x4b3084,_0x44a138=_0x24d046[_0x3f8560(0x191)](_0x125617=>_0x125617[_0x3f8560(0x174)]==='HOOK');if(!_0x44a138)return{'aliasToDatasetCode':new Map(),'datasetCodeToDataset':new Map()};const _0x1cf4d6=loadAliasMap(_0x49e74b,undefined,resolveApiFilePath(_0x49e74b,_0x22db46)),_0x24e5ac=new Map(_0x1cf4d6[_0x3f8560(0x181)](_0x4d5883=>[_0x4d5883['alias'],_0x4d5883[_0x3f8560(0x19e)]]));for(const _0x2653de of Object[_0x3f8560(0x18f)](_0x322eb8[_0x3f8560(0x18c)])){_0x2653de[_0x3f8560(0x1b4)]&&_0x2653de[_0x3f8560(0x19e)]&&!_0x24e5ac[_0x3f8560(0x183)](_0x2653de[_0x3f8560(0x1b4)])&&_0x24e5ac[_0x3f8560(0x185)](_0x2653de['alias'],_0x2653de[_0x3f8560(0x19e)]);}const _0x1f7580=await listDatasets(_0x22db46),_0x14fa49=new Map(_0x1f7580[_0x3f8560(0x181)](_0x12ea8a=>[_0x12ea8a[_0x3f8560(0x188)],_0x12ea8a]));return{'aliasToDatasetCode':_0x24e5ac,'datasetCodeToDataset':_0x14fa49};}async function uploadSingleFunction(_0x2b8864,_0x3aedd4,_0x2ad655,_0x52459c){const _0x58b20e=a37_0x4b3084,_0x48bd39=await readFile(_0x3aedd4[_0x58b20e(0x173)],_0x58b20e(0x19f)),_0x33517e=await computeFileHash(_0x3aedd4[_0x58b20e(0x173)]),_0x34892d=_0x2ad655['functions'][_0x3aedd4[_0x58b20e(0x1b7)]];if(_0x34892d?.[_0x58b20e(0x17e)]&&_0x34892d[_0x58b20e(0x17f)]==null)throw CliErrors[_0x58b20e(0x16a)](_0x3aedd4[_0x58b20e(0x1b7)]+_0x58b20e(0x194));let _0x514029=extractScriptDescription(_0x48bd39);if(!_0x514029&&_0x34892d?.[_0x58b20e(0x17e)]){const _0xd1cfae=await getBffScriptInfo(_0x34892d['remoteId']);_0x514029=_0xd1cfae['description']||undefined;}const _0x20e14a={'appCode':_0x2b8864,'functionName':_0x3aedd4[_0x58b20e(0x189)],'scriptType':_0x3aedd4[_0x58b20e(0x174)],'scriptContent':_0x48bd39};if(_0x34892d?.[_0x58b20e(0x17e)])_0x20e14a['id']=_0x34892d[_0x58b20e(0x17e)];if(_0x34892d?.['version']!=null)_0x20e14a['version']=_0x34892d[_0x58b20e(0x17f)];if(_0x514029)_0x20e14a[_0x58b20e(0x1a7)]=_0x514029;if(_0x3aedd4[_0x58b20e(0x174)]==='HOOK'){const _0x1d07e8=_0x3aedd4['alias'];if(!_0x1d07e8||!_0x3aedd4['operationType']||!_0x3aedd4['functionNode'])throw CliErrors[_0x58b20e(0x16a)]('Incomplete\x20HOOK\x20path:\x20'+_0x3aedd4[_0x58b20e(0x1b7)]);const _0x1f5cf8=_0x52459c[_0x58b20e(0x17c)][_0x58b20e(0x1b3)](_0x1d07e8)??_0x34892d?.[_0x58b20e(0x19e)]??_0x1d07e8,_0x1d185d=_0x52459c[_0x58b20e(0x19a)][_0x58b20e(0x1b3)](_0x1f5cf8);if(!_0x1d185d)throw CliErrors[_0x58b20e(0x16a)]('Cannot\x20resolve\x20dataset\x20for\x20\x22'+_0x1d07e8+'\x22.\x20'+(_0x58b20e(0x1ac)+CLI_BIN_NAME+'\x20api\x20pull`\x20to\x20refresh\x20api.ts,\x20or\x20verify\x20the\x20dataset\x20exists.'));_0x20e14a[_0x58b20e(0x198)]=_0x1d185d['id'],_0x20e14a['operationType']=_0x3aedd4[_0x58b20e(0x1ae)],_0x20e14a[_0x58b20e(0x197)]=_0x3aedd4[_0x58b20e(0x197)];}const _0x3b0bc8=await saveBffScript(_0x20e14a),_0x364390=_0x3b0bc8['id'],_0x326b6c=_0x3b0bc8['script']??await getBffScriptInfo(_0x364390),_0x405868={'hash':_0x33517e,'remoteId':_0x364390,'version':_0x326b6c[_0x58b20e(0x17f)]};if(_0x3aedd4['type']===_0x58b20e(0x19d)){const _0x5db12f=_0x3aedd4[_0x58b20e(0x1b4)],_0x1372d7=_0x52459c[_0x58b20e(0x17c)][_0x58b20e(0x1b3)](_0x5db12f)??_0x34892d?.['datasetCode']??_0x5db12f;_0x52459c[_0x58b20e(0x17c)][_0x58b20e(0x183)](_0x5db12f)?_0x405868[_0x58b20e(0x1b4)]=_0x5db12f:_0x405868[_0x58b20e(0x1b4)]=_0x34892d?.[_0x58b20e(0x1b4)],_0x405868[_0x58b20e(0x19e)]=_0x1372d7,_0x405868[_0x58b20e(0x1ae)]=_0x3aedd4[_0x58b20e(0x1ae)],_0x405868[_0x58b20e(0x197)]=_0x3aedd4[_0x58b20e(0x197)];}_0x2ad655[_0x58b20e(0x18c)][_0x3aedd4[_0x58b20e(0x1b7)]]=_0x405868;}const LOCK_SETTLE_RETRY_COUNT=0x14,LOCK_SETTLE_DELAY_MS=0x64;async function waitForUploadedLockEntries(_0x2a4766,_0x3247af,_0x181099){const _0x483a94=a37_0x4b3084;if(_0x181099[_0x483a94(0x199)]===0x0)return;for(let _0x1d6b42=0x0;_0x1d6b42<LOCK_SETTLE_RETRY_COUNT;_0x1d6b42+=0x1){const _0x5d04a4=await readBffLockFile(_0x2a4766),_0xe2004b=_0x5d04a4?.['apps']?.[_0x3247af]?.[_0x483a94(0x18c)]??{},_0x5d1337=_0x181099[_0x483a94(0x182)](_0x17f874=>!!_0xe2004b[_0x17f874]?.[_0x483a94(0x17e)]);if(_0x5d1337)return;await sleep(LOCK_SETTLE_DELAY_MS);}throw new Error('Lock\x20file\x20not\x20settled\x20after\x20push\x20for\x20'+_0x181099['join'](',\x20')+'.');}
@@ -1 +1 @@
1
- const a38_0x31ae76=a38_0x3604;(function(_0x8e03a3,_0x23efb1){const _0x5be3dd=a38_0x3604,_0x47af5c=_0x8e03a3();while(!![]){try{const _0x348468=parseInt(_0x5be3dd(0x1b5))/0x1+parseInt(_0x5be3dd(0x1ab))/0x2+parseInt(_0x5be3dd(0x1ad))/0x3+-parseInt(_0x5be3dd(0x1b4))/0x4+parseInt(_0x5be3dd(0x1af))/0x5*(-parseInt(_0x5be3dd(0x1b0))/0x6)+-parseInt(_0x5be3dd(0x1a5))/0x7+-parseInt(_0x5be3dd(0x1a8))/0x8*(parseInt(_0x5be3dd(0x1a1))/0x9);if(_0x348468===_0x23efb1)break;else _0x47af5c['push'](_0x47af5c['shift']());}catch(_0x40d80f){_0x47af5c['push'](_0x47af5c['shift']());}}}(a38_0x3f1e,0x80b7c));import{listBffScripts,getBffScriptStatistics}from'../../core/api-client.js';import{loadAliasMap}from'../../core/alias-resolver.js';import{resolveApiFilePath}from'../../context.js';import{loadBffProjectConfig}from'../../core/bff/config.js';function a38_0x3604(_0x4b7059,_0x5e9ce9){_0x4b7059=_0x4b7059-0x1a0;const _0x3f1e8a=a38_0x3f1e();let _0x36041a=_0x3f1e8a[_0x4b7059];return _0x36041a;}import{createHookLocationMap,resolveRemoteScriptTarget,scanLocalBffFunctions}from'../../core/bff/file-system.js';function a38_0x3f1e(){const _0x17971d=['1585QLjwNL','8754qXiUtw','functions','apiDir','status','349632tcFImB','915502AWwujN','map','boolean','Also\x20check\x20for\x20remote-only\x20scripts\x20not\x20present\x20locally','all','datasetCode','bff','push','alias','27BIAJPq','read','appCode','lockKey','950817IBxXrq','scriptsRoot','remote','3246736BcUhJF','bool','hash','1729356HoKhVd','\x20added,\x20','1950948Kxmzzz','length'];a38_0x3f1e=function(){return _0x17971d;};return a38_0x3f1e();}import{computeFileHash}from'../../core/bff/hash.js';import{createEmptyBffLock,ensureLockScope,readBffLockFile}from'../../core/bff/lock.js';export const bffStatus={'service':a38_0x31ae76(0x1bb),'command':a38_0x31ae76(0x1b3),'description':'Check\x20local\x20BFF\x20sync\x20status\x20against\x20lock\x20file','risk':a38_0x31ae76(0x1a2),'flags':[{'name':a38_0x31ae76(0x1a7),'type':a38_0x31ae76(0x1b7),'description':a38_0x31ae76(0x1b8)}],async 'execute'(_0x19d88a){const _0x24e62e=a38_0x31ae76,_0x147d73=loadBffProjectConfig(_0x19d88a['appCode']),_0x479041=await readBffLockFile(_0x147d73['lockFilePath']),{appLock:_0x41bf90}=ensureLockScope(_0x479041??createEmptyBffLock(),_0x19d88a['appCode'],_0x147d73[_0x24e62e(0x1a6)],'status'),_0x239f05=await scanLocalBffFunctions(_0x147d73),_0x50bf2b=[],_0x1c1c29=[],_0x4ef047=[];for(const _0x486fb3 of _0x239f05){const _0x67a155=await computeFileHash(_0x486fb3['filePath']),_0x5a1ab4=_0x41bf90[_0x24e62e(0x1b1)][_0x486fb3[_0x24e62e(0x1a4)]];if(!_0x5a1ab4)_0x50bf2b[_0x24e62e(0x1bc)](_0x486fb3[_0x24e62e(0x1a4)]);else _0x5a1ab4[_0x24e62e(0x1aa)]!==_0x67a155?_0x1c1c29[_0x24e62e(0x1bc)](_0x486fb3[_0x24e62e(0x1a4)]):_0x4ef047[_0x24e62e(0x1bc)](_0x486fb3[_0x24e62e(0x1a4)]);}const _0x436c48=[];if(_0x19d88a[_0x24e62e(0x1a9)](_0x24e62e(0x1a7))){const _0x9151de=loadAliasMap(_0x19d88a[_0x24e62e(0x1b2)],undefined,resolveApiFilePath(_0x19d88a[_0x24e62e(0x1b2)],_0x19d88a[_0x24e62e(0x1a3)])),_0x2897d7=new Map(_0x9151de[_0x24e62e(0x1b6)](_0x19a68e=>[_0x19a68e[_0x24e62e(0x1ba)],_0x19a68e[_0x24e62e(0x1a0)]])),[_0x4ded84,_0x1f89e8]=await Promise[_0x24e62e(0x1b9)]([listBffScripts(_0x19d88a[_0x24e62e(0x1a3)]),getBffScriptStatistics(_0x19d88a[_0x24e62e(0x1a3)])]),_0x58faef=createHookLocationMap(_0x1f89e8),_0x15064d=new Set(_0x239f05[_0x24e62e(0x1b6)](_0x3b7894=>_0x3b7894['lockKey']));for(const _0x266120 of _0x4ded84){const _0x167e8f=resolveRemoteScriptTarget(_0x147d73,_0x266120,_0x58faef,_0x41bf90[_0x24e62e(0x1b1)],_0x2897d7);_0x167e8f&&!_0x15064d['has'](_0x167e8f[_0x24e62e(0x1a4)])&&_0x436c48[_0x24e62e(0x1bc)](_0x167e8f[_0x24e62e(0x1a4)]);}}const _0x3b7c7a=_0x50bf2b[_0x24e62e(0x1ae)]===0x0&&_0x1c1c29[_0x24e62e(0x1ae)]===0x0&&_0x436c48[_0x24e62e(0x1ae)]===0x0;return{'ok':!![],'data':{'added':_0x50bf2b,'modified':_0x1c1c29,'unchanged':_0x4ef047,'remoteOnly':_0x436c48},'message':_0x3b7c7a?'All\x20BFF\x20scripts\x20are\x20in\x20sync.':_0x50bf2b[_0x24e62e(0x1ae)]+_0x24e62e(0x1ac)+_0x1c1c29[_0x24e62e(0x1ae)]+'\x20modified,\x20'+_0x4ef047[_0x24e62e(0x1ae)]+'\x20unchanged'+(_0x436c48['length']>0x0?',\x20'+_0x436c48['length']+'\x20remote-only':'')};}};
1
+ const a38_0x5e7d04=a38_0x4270;(function(_0xbb850d,_0xbe5bc2){const _0x13cc29=a38_0x4270,_0x4ee664=_0xbb850d();while(!![]){try{const _0x501e6b=-parseInt(_0x13cc29(0x1af))/0x1+-parseInt(_0x13cc29(0x1c8))/0x2*(parseInt(_0x13cc29(0x1c6))/0x3)+parseInt(_0x13cc29(0x1cc))/0x4*(-parseInt(_0x13cc29(0x1b5))/0x5)+parseInt(_0x13cc29(0x1b7))/0x6+-parseInt(_0x13cc29(0x1c5))/0x7+parseInt(_0x13cc29(0x1b9))/0x8*(-parseInt(_0x13cc29(0x1b0))/0x9)+parseInt(_0x13cc29(0x1cf))/0xa;if(_0x501e6b===_0xbe5bc2)break;else _0x4ee664['push'](_0x4ee664['shift']());}catch(_0x27b868){_0x4ee664['push'](_0x4ee664['shift']());}}}(a38_0x2920,0x5d477));import{listBffScripts,getBffScriptStatistics}from'../../core/api-client.js';function a38_0x4270(_0x5b8eb5,_0xf6258){_0x5b8eb5=_0x5b8eb5-0x1af;const _0x2920b2=a38_0x2920();let _0x427021=_0x2920b2[_0x5b8eb5];return _0x427021;}function a38_0x2920(){const _0x34f1ec=['boolean','190352grVlLE','all','\x20remote-only','28359080XTCEwh','200593gwRfLE','1071792FzhEDP','status','hash','lockKey','has','70kNVUzS','appCode','1574028PyEmgA','push','48hOCrvG','\x20added,\x20','length','map','alias','read','remote','datasetCode','scriptsRoot','All\x20BFF\x20scripts\x20are\x20in\x20sync.','Also\x20check\x20for\x20remote-only\x20scripts\x20not\x20present\x20locally','\x20modified,\x20','4747701Qmxmal','2619wqXRqk','functions','1046DJeTmz','apiDir','bool'];a38_0x2920=function(){return _0x34f1ec;};return a38_0x2920();}import{loadAliasMap}from'../../core/alias-resolver.js';import{resolveApiFilePath}from'../../context.js';import{loadBffProjectConfig}from'../../core/bff/config.js';import{createHookLocationMap,resolveRemoteScriptTarget,scanLocalBffFunctions}from'../../core/bff/file-system.js';import{computeFileHash}from'../../core/bff/hash.js';import{createEmptyBffLock,ensureLockScope,readBffLockFile}from'../../core/bff/lock.js';export const bffStatus={'service':'bff','command':'status','description':'Check\x20local\x20BFF\x20sync\x20status\x20against\x20lock\x20file','risk':a38_0x5e7d04(0x1be),'flags':[{'name':a38_0x5e7d04(0x1bf),'type':a38_0x5e7d04(0x1cb),'description':a38_0x5e7d04(0x1c3)}],async 'execute'(_0x590fba){const _0x2381b4=a38_0x5e7d04,_0x5ace64=loadBffProjectConfig(_0x590fba[_0x2381b4(0x1b6)]),_0x135bd2=await readBffLockFile(_0x5ace64['lockFilePath']),{appLock:_0x1ca432}=ensureLockScope(_0x135bd2??createEmptyBffLock(),_0x590fba[_0x2381b4(0x1b6)],_0x5ace64[_0x2381b4(0x1c1)],_0x2381b4(0x1b1)),_0x23b94b=await scanLocalBffFunctions(_0x5ace64),_0x3bcda2=[],_0x4be725=[],_0x4b50cf=[];for(const _0x11f80e of _0x23b94b){const _0x260b67=await computeFileHash(_0x11f80e['filePath']),_0x33c2a1=_0x1ca432[_0x2381b4(0x1c7)][_0x11f80e[_0x2381b4(0x1b3)]];if(!_0x33c2a1)_0x3bcda2[_0x2381b4(0x1b8)](_0x11f80e[_0x2381b4(0x1b3)]);else _0x33c2a1[_0x2381b4(0x1b2)]!==_0x260b67?_0x4be725[_0x2381b4(0x1b8)](_0x11f80e[_0x2381b4(0x1b3)]):_0x4b50cf[_0x2381b4(0x1b8)](_0x11f80e[_0x2381b4(0x1b3)]);}const _0x3151e1=[];if(_0x590fba[_0x2381b4(0x1ca)](_0x2381b4(0x1bf))){const _0x2a5e80=loadAliasMap(_0x590fba['apiDir'],undefined,resolveApiFilePath(_0x590fba[_0x2381b4(0x1c9)],_0x590fba['appCode'])),_0x4d7e3c=new Map(_0x2a5e80['map'](_0x4518a6=>[_0x4518a6[_0x2381b4(0x1c0)],_0x4518a6[_0x2381b4(0x1bd)]])),[_0x3ee492,_0xe7a36f]=await Promise[_0x2381b4(0x1cd)]([listBffScripts(_0x590fba['appCode']),getBffScriptStatistics(_0x590fba[_0x2381b4(0x1b6)])]),_0x1bd3b0=createHookLocationMap(_0xe7a36f),_0x50a988=new Set(_0x23b94b[_0x2381b4(0x1bc)](_0x574604=>_0x574604[_0x2381b4(0x1b3)]));for(const _0x3fc832 of _0x3ee492){const _0x491cce=resolveRemoteScriptTarget(_0x5ace64,_0x3fc832,_0x1bd3b0,_0x1ca432[_0x2381b4(0x1c7)],_0x4d7e3c);_0x491cce&&!_0x50a988[_0x2381b4(0x1b4)](_0x491cce['lockKey'])&&_0x3151e1['push'](_0x491cce[_0x2381b4(0x1b3)]);}}const _0x9b42ac=_0x3bcda2['length']===0x0&&_0x4be725[_0x2381b4(0x1bb)]===0x0&&_0x3151e1[_0x2381b4(0x1bb)]===0x0;return{'ok':!![],'data':{'added':_0x3bcda2,'modified':_0x4be725,'unchanged':_0x4b50cf,'remoteOnly':_0x3151e1},'message':_0x9b42ac?_0x2381b4(0x1c2):_0x3bcda2[_0x2381b4(0x1bb)]+_0x2381b4(0x1ba)+_0x4be725[_0x2381b4(0x1bb)]+_0x2381b4(0x1c4)+_0x4b50cf[_0x2381b4(0x1bb)]+'\x20unchanged'+(_0x3151e1[_0x2381b4(0x1bb)]>0x0?',\x20'+_0x3151e1[_0x2381b4(0x1bb)]+_0x2381b4(0x1ce):'')};}};
@@ -1 +1 @@
1
- function a39_0x2348(_0x4249b2,_0x2d8868){_0x4249b2=_0x4249b2-0x88;const _0x46e704=a39_0x46e7();let _0x234870=_0x46e704[_0x4249b2];return _0x234870;}const a39_0x38c2c3=a39_0x2348;function a39_0x46e7(){const _0x5c9f73=['inherit','CLI\x20Built-in\x20Skill\x20installed','skipped','4991335EHpEdX','4JTocse','info','apiError','10455584VbovyD','npx\x20skills\x20add\x20failed:\x20','Installing\x20CLI\x20Built-in\x20Skill\x20via\x20npx\x20(','write','7311003zISSBL','pipe','log','2VWnQnt','unknown','1468426fAAKzU','cli-skill-install','Installing\x20CLI\x20Built-in\x20Skill\x20via\x20npx.','cli-skill','error','cwd','nonInteractive','Check\x20network\x20connectivity\x20and\x20try\x20again,\x20or\x20run:\x20','829557rjxczW','19235556nLgJiX','Skipped\x20npx\x20(RABETBASE_SKIP_NPX_SKILLS=1);\x20assuming\x20CLI\x20Built-in\x20Skill\x20is\x20already\x20present.','install','Install\x20or\x20refresh\x20the\x20Rabetbase\x20CLI\x20Built-in\x20Skill','5865270ROGCWq'];a39_0x46e7=function(){return _0x5c9f73;};return a39_0x46e7();}(function(_0x27b50a,_0x5245e0){const _0x253387=a39_0x2348,_0x4e6e73=_0x27b50a();while(!![]){try{const _0x1429aa=parseInt(_0x253387(0xa2))/0x1+-parseInt(_0x253387(0xa0))/0x2*(parseInt(_0x253387(0x8c))/0x3)+parseInt(_0x253387(0x96))/0x4*(parseInt(_0x253387(0x95))/0x5)+-parseInt(_0x253387(0x91))/0x6+-parseInt(_0x253387(0x9d))/0x7+-parseInt(_0x253387(0x99))/0x8+parseInt(_0x253387(0x8d))/0x9;if(_0x1429aa===_0x5245e0)break;else _0x4e6e73['push'](_0x4e6e73['shift']());}catch(_0x82350b){_0x4e6e73['push'](_0x4e6e73['shift']());}}}(a39_0x46e7,0xf3c88));import{CliErrors}from'../../errors.js';import{logger}from'../../utils/logger.js';export const cliSkillDefinitions=[{'service':a39_0x38c2c3(0xa5),'command':a39_0x38c2c3(0x8f),'description':a39_0x38c2c3(0x90),'risk':a39_0x38c2c3(0x9c),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x552ed0){const _0x2ccad0=a39_0x38c2c3;logger['setLogPath'](process[_0x2ccad0(0x89)]()),logger[_0x2ccad0(0x97)](_0x2ccad0(0xa3),_0x2ccad0(0xa4));const {NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE:_0x8ab364,RABETBASE_SKILL_SOURCE:_0x227698,runNpxSkillsAddGlobal:_0x2adc25}=await import('../../skills/npx-skills-add.js'),_0x33fd25=_0x552ed0[_0x2ccad0(0x8a)]?_0x2ccad0(0x9e):_0x2ccad0(0x92);console['log'](_0x2ccad0(0x9b)+_0x8ab364+')...');const _0x3403f8=_0x2adc25(process[_0x2ccad0(0x89)](),_0x227698,{'stdio':_0x33fd25});if(_0x3403f8[_0x2ccad0(0x94)])console[_0x2ccad0(0x9f)](_0x2ccad0(0x8e));else{if(_0x3403f8['ok'])console[_0x2ccad0(0x9f)](_0x2ccad0(0x93));else throw CliErrors[_0x2ccad0(0x98)](_0x2ccad0(0x9a)+(_0x3403f8[_0x2ccad0(0x88)]||_0x2ccad0(0xa1)),_0x2ccad0(0x8b)+_0x8ab364);}return{'ok':!![]};}}];
1
+ const a39_0x167dca=a39_0x6fd9;(function(_0x529764,_0xf86c16){const _0x52a5ac=a39_0x6fd9,_0x8835dc=_0x529764();while(!![]){try{const _0x1e75bf=parseInt(_0x52a5ac(0x117))/0x1*(-parseInt(_0x52a5ac(0x10a))/0x2)+-parseInt(_0x52a5ac(0xff))/0x3+parseInt(_0x52a5ac(0x100))/0x4*(parseInt(_0x52a5ac(0xfb))/0x5)+-parseInt(_0x52a5ac(0x112))/0x6*(parseInt(_0x52a5ac(0x10c))/0x7)+parseInt(_0x52a5ac(0x101))/0x8+parseInt(_0x52a5ac(0x10d))/0x9*(-parseInt(_0x52a5ac(0x105))/0xa)+parseInt(_0x52a5ac(0x10b))/0xb;if(_0x1e75bf===_0xf86c16)break;else _0x8835dc['push'](_0x8835dc['shift']());}catch(_0x25bf8a){_0x8835dc['push'](_0x8835dc['shift']());}}}(a39_0x1c59,0x705a1));function a39_0x6fd9(_0x4fa15f,_0x4d837c){_0x4fa15f=_0x4fa15f-0xfb;const _0x1c5917=a39_0x1c59();let _0x6fd9c4=_0x1c5917[_0x4fa15f];return _0x6fd9c4;}import{CliErrors}from'../../errors.js';function a39_0x1c59(){const _0x1052e8=['1886289aBXrvW','518008vJlDGu','2603640bcessv','cwd','Installing\x20CLI\x20Built-in\x20Skill\x20via\x20npx\x20(','write','31330ChYaQj','../../skills/npx-skills-add.js','Check\x20network\x20connectivity\x20and\x20try\x20again,\x20or\x20run:\x20','unknown','cli-skill-install','160AAJTUZ','22229779IDWwCp','35QPiZIi','2430HVOGoV','npx\x20skills\x20add\x20failed:\x20','log','CLI\x20Built-in\x20Skill\x20installed','install','528684xMTCBA','pipe',')...','setLogPath','cli-skill','9349UsKNfa','30BoxWHx','apiError','inherit','Skipped\x20npx\x20(RABETBASE_SKIP_NPX_SKILLS=1);\x20assuming\x20CLI\x20Built-in\x20Skill\x20is\x20already\x20present.'];a39_0x1c59=function(){return _0x1052e8;};return a39_0x1c59();}import{logger}from'../../utils/logger.js';export const cliSkillDefinitions=[{'service':a39_0x167dca(0x116),'command':a39_0x167dca(0x111),'description':'Install\x20or\x20refresh\x20the\x20Rabetbase\x20CLI\x20Built-in\x20Skill','risk':a39_0x167dca(0x104),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x3a9585){const _0x232cb1=a39_0x167dca;logger[_0x232cb1(0x115)](process[_0x232cb1(0x102)]()),logger['info'](_0x232cb1(0x109),'Installing\x20CLI\x20Built-in\x20Skill\x20via\x20npx.');const {NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE:_0x1b9d76,RABETBASE_SKILL_SOURCE:_0x557a20,runNpxSkillsAddGlobal:_0x37ff64}=await import(_0x232cb1(0x106)),_0xf866c5=_0x3a9585['nonInteractive']?_0x232cb1(0x113):_0x232cb1(0xfd);console[_0x232cb1(0x10f)](_0x232cb1(0x103)+_0x1b9d76+_0x232cb1(0x114));const _0xf56f9f=_0x37ff64(process[_0x232cb1(0x102)](),_0x557a20,{'stdio':_0xf866c5});if(_0xf56f9f['skipped'])console[_0x232cb1(0x10f)](_0x232cb1(0xfe));else{if(_0xf56f9f['ok'])console[_0x232cb1(0x10f)](_0x232cb1(0x110));else throw CliErrors[_0x232cb1(0xfc)](_0x232cb1(0x10e)+(_0xf56f9f['error']||_0x232cb1(0x108)),_0x232cb1(0x107)+_0x1b9d76);}return{'ok':!![]};}}];
@@ -1 +1 @@
1
- const a40_0xae5f75=a40_0xf5cd;(function(_0x4b1eeb,_0x45fe63){const _0x7591a4=a40_0xf5cd,_0x392dec=_0x4b1eeb();while(!![]){try{const _0xbab34=parseInt(_0x7591a4(0xa3))/0x1+-parseInt(_0x7591a4(0xb6))/0x2+parseInt(_0x7591a4(0x90))/0x3*(parseInt(_0x7591a4(0xa5))/0x4)+parseInt(_0x7591a4(0xaa))/0x5*(parseInt(_0x7591a4(0xdd))/0x6)+-parseInt(_0x7591a4(0x99))/0x7+parseInt(_0x7591a4(0xa9))/0x8+-parseInt(_0x7591a4(0xd4))/0x9*(parseInt(_0x7591a4(0xb7))/0xa);if(_0xbab34===_0x45fe63)break;else _0x392dec['push'](_0x392dec['shift']());}catch(_0x3a07a9){_0x392dec['push'](_0x392dec['shift']());}}}(a40_0x2896,0x6b193));import a40_0x47d7c6 from'chalk';import a40_0x3ef4b3 from'ora';import a40_0x439034 from'semver';import{execa}from'execa';function a40_0xf5cd(_0x1b6338,_0xbc9e54){_0x1b6338=_0x1b6338-0x8d;const _0x28960c=a40_0x2896();let _0xf5cd57=_0x28960c[_0x1b6338];return _0xf5cd57;}import{CLI_BIN_NAME,NPM_PACKAGE_NAME}from'../constant/cli.js';import{VERSION,GIT_COMMIT,BUILD_TIME}from'../generated/build-info.js';import{CliErrors}from'../errors.js';import{RABETBASE_SKILL_SOURCE,runNpxSkillsAddGlobal}from'../skills/npx-skills-add.js';import{resolveNpmBin}from'../utils/platform.js';function getCurrentVersion(){const _0x45a878=a40_0xf5cd;return GIT_COMMIT!==_0x45a878(0xb0)?VERSION+'\x20('+GIT_COMMIT+',\x20'+BUILD_TIME[_0x45a878(0xd5)](0x0,0xa)+')':VERSION;}function detectPackageManager(){const _0x4abca0=a40_0xf5cd,_0x7e9ba1=process[_0x4abca0(0xa7)][_0x4abca0(0xb8)]();if(_0x7e9ba1[_0x4abca0(0xc6)](_0x4abca0(0xcf)))return'bun';return'npm';}const updateFlags=[{'name':a40_0xae5f75(0xac),'type':a40_0xae5f75(0xa0),'description':a40_0xae5f75(0x94),'default':![]},{'name':a40_0xae5f75(0x97),'type':'string','description':a40_0xae5f75(0xb1)},{'name':a40_0xae5f75(0xcb),'type':'boolean','description':'Skip\x20CLI\x20Built-in\x20Skill\x20refresh\x20after\x20updating','default':![]},{'name':a40_0xae5f75(0x98),'type':a40_0xae5f75(0xa0),'description':a40_0xae5f75(0x8f),'default':!![],'hidden':!![]}];function getRequestedVersion(_0x5ef7e9){const _0x363908=a40_0xae5f75;return _0x5ef7e9[_0x363908(0x8d)](_0x363908(0x97))[_0x363908(0xb3)]();}function shouldSkipCliSkill(_0x45d333){const _0x3aea77=a40_0xae5f75;return _0x45d333[_0x3aea77(0xcc)](_0x3aea77(0xcb))||_0x45d333[_0x3aea77(0xd0)](_0x3aea77(0x98))===![];}async function validateUpdateFlags(_0x7660a0){const _0x10a384=a40_0xae5f75,_0x4799fe=_0x7660a0[_0x10a384(0xcc)]('beta'),_0x3429a0=getRequestedVersion(_0x7660a0);if(_0x4799fe&&_0x3429a0)throw CliErrors[_0x10a384(0xbc)](_0x10a384(0xd1),'Choose\x20either\x20npm\x20beta\x20dist-tag\x20or\x20an\x20exact\x20version.');if(_0x3429a0&&!a40_0x439034[_0x10a384(0xb2)](_0x3429a0))throw CliErrors[_0x10a384(0xbc)](_0x10a384(0x9d)+_0x3429a0,'Use\x20a\x20full\x20semver\x20such\x20as\x202.1.6\x20or\x202.1.6-beta.1.');}async function fetchNpmDistTags(){const _0x5712a9=a40_0xae5f75;try{const _0x3fbf40=await fetch(_0x5712a9(0xd7)+encodeURIComponent(NPM_PACKAGE_NAME)+_0x5712a9(0x9e),{'signal':AbortSignal[_0x5712a9(0xd8)](0x2710)});if(!_0x3fbf40['ok'])return null;const _0x4b4e95=await _0x3fbf40[_0x5712a9(0x96)]();if(!_0x4b4e95||typeof _0x4b4e95!==_0x5712a9(0xa6))return null;return Object[_0x5712a9(0xd2)](Object[_0x5712a9(0xa2)](_0x4b4e95)[_0x5712a9(0xda)](([,_0x3cb246])=>typeof _0x3cb246==='string'&&_0x3cb246[_0x5712a9(0xb3)]()['length']>0x0)[_0x5712a9(0xc1)](([_0x5cc26b,_0x361709])=>[_0x5cc26b,String(_0x361709)['trim']()]));}catch{return null;}}async function fetchNpmDistTagVersion(_0x34b10f){const _0x847f25=await fetchNpmDistTags();return _0x847f25?.[_0x34b10f]??null;}async function fetchLatestVersion(){const _0x43585d=a40_0xae5f75;return fetchNpmDistTagVersion(_0x43585d(0xce));}async function resolveTargetVersion(_0x1aad7e){const _0x27a9fb=a40_0xae5f75,_0x43ee70=getRequestedVersion(_0x1aad7e);if(_0x43ee70)return{'version':_0x43ee70,'source':_0x27a9fb(0x97)};if(_0x1aad7e[_0x27a9fb(0xcc)](_0x27a9fb(0xac))){const _0x257ee3=await fetchNpmDistTagVersion(_0x27a9fb(0xac));if(!_0x257ee3)return null;return{'version':_0x257ee3,'source':_0x27a9fb(0xac)};}const _0x5e21cb=await fetchLatestVersion();if(!_0x5e21cb)return null;return{'version':_0x5e21cb,'source':_0x27a9fb(0xce)};}function shouldInstallTarget(_0x9d0b11,_0xfedf3d){const _0x22d531=a40_0xae5f75;if(_0xfedf3d[_0x22d531(0xb9)]==='version'||_0xfedf3d[_0x22d531(0xb9)]===_0x22d531(0xac))return!a40_0x439034['eq'](_0x9d0b11,_0xfedf3d[_0x22d531(0x97)]);return a40_0x439034['lt'](_0x9d0b11,_0xfedf3d[_0x22d531(0x97)]);}function getInstallPlanLabel(_0x5f1b9d,_0x4f0392){const _0x373f78=a40_0xae5f75;switch(_0x4f0392['source']){case'beta':return _0x373f78(0xd9)+a40_0x47d7c6[_0x373f78(0xa1)](_0x5f1b9d)+'\x20→\x20'+a40_0x47d7c6[_0x373f78(0x92)](_0x4f0392['version']);case _0x373f78(0x97):return _0x373f78(0xdc)+a40_0x47d7c6['yellow'](_0x5f1b9d)+_0x373f78(0x8e)+a40_0x47d7c6[_0x373f78(0x92)](_0x4f0392[_0x373f78(0x97)]);case'latest':default:return _0x373f78(0x9f)+a40_0x47d7c6[_0x373f78(0xa1)](_0x5f1b9d)+_0x373f78(0x8e)+a40_0x47d7c6['green'](_0x4f0392[_0x373f78(0x97)]);}}async function installCliSkill(_0xbd1005){const _0x1193ac=a40_0xae5f75;console['log'](a40_0x47d7c6['gray'](_0x1193ac(0x9b)));const _0x1fd2ae=runNpxSkillsAddGlobal(process[_0x1193ac(0xdb)](),RABETBASE_SKILL_SOURCE,{'stdio':_0xbd1005?_0x1193ac(0xb4):_0x1193ac(0xcd)});if(_0x1fd2ae['skipped']){console[_0x1193ac(0xc7)](a40_0x47d7c6[_0x1193ac(0xb5)](_0x1193ac(0xd3)));return;}if(_0x1fd2ae['ok']){console[_0x1193ac(0xc7)](a40_0x47d7c6[_0x1193ac(0xb5)](_0x1193ac(0xaf)));return;}console[_0x1193ac(0xa8)](a40_0x47d7c6[_0x1193ac(0xa1)](_0x1193ac(0xad)+(_0x1fd2ae[_0x1193ac(0xdf)]||_0x1193ac(0xb0)))),console[_0x1193ac(0xc7)](a40_0x47d7c6[_0x1193ac(0xb5)](_0x1193ac(0xa4)+CLI_BIN_NAME+_0x1193ac(0xba)));}async function execute(_0x3d3a79){const _0x353e2c=a40_0xae5f75;await validateUpdateFlags(_0x3d3a79);const _0xe642ab=getCurrentVersion();console[_0x353e2c(0xc7)](_0x353e2c(0x9a)+_0xe642ab);const _0xc6bfd6=a40_0x3ef4b3(_0x353e2c(0x9c))['start'](),_0x18dfe8=await resolveTargetVersion(_0x3d3a79);if(!_0x18dfe8){const _0x3df1a5=_0x3d3a79['bool'](_0x353e2c(0xac))?_0x353e2c(0xbb):_0x353e2c(0xc3);return _0xc6bfd6[_0x353e2c(0xbd)](_0x3df1a5),console[_0x353e2c(0xc7)](a40_0x47d7c6[_0x353e2c(0xb5)](_0x353e2c(0xc5)+NPM_PACKAGE_NAME+_0x353e2c(0x91))),{'ok':![],'message':_0x3df1a5};}const _0x3d0518=a40_0x439034['valid'](VERSION),_0x48ba99=a40_0x439034[_0x353e2c(0xb2)](_0x18dfe8['version']);if(!_0x3d0518||!_0x48ba99)return _0xc6bfd6[_0x353e2c(0xbd)](_0x353e2c(0xae)),{'ok':![],'message':'Version\x20comparison\x20failed'};if(!shouldInstallTarget(_0x3d0518,_0x18dfe8)){const _0x5732f3=_0x18dfe8[_0x353e2c(0xb9)]==='version'?_0x353e2c(0xc9)+_0x18dfe8[_0x353e2c(0x97)]+')':_0x353e2c(0x95)+_0x18dfe8[_0x353e2c(0x97)]+')';return _0xc6bfd6['succeed'](_0x5732f3),shouldSkipCliSkill(_0x3d3a79)?console['log'](a40_0x47d7c6[_0x353e2c(0xb5)](_0x353e2c(0xe0))):await installCliSkill(_0x3d3a79['nonInteractive']),{'ok':!![]};}_0xc6bfd6[_0x353e2c(0xab)](getInstallPlanLabel(_0xe642ab,_0x18dfe8));const _0x2c2fd5=detectPackageManager(),_0x183346=_0x2c2fd5===_0x353e2c(0x93)?resolveNpmBin(_0x353e2c(0x93)):_0x2c2fd5,_0x3cb696=a40_0x3ef4b3(_0x353e2c(0xbf)+_0x2c2fd5+'...')['start']();try{return await execa(_0x183346,[_0x353e2c(0xca),'-g',NPM_PACKAGE_NAME+'@'+_0x18dfe8[_0x353e2c(0x97)]],{'stdio':_0x353e2c(0xb4)}),_0x3cb696[_0x353e2c(0xc4)]('Updated\x20to\x20v'+_0x18dfe8[_0x353e2c(0x97)]),console[_0x353e2c(0xc7)](a40_0x47d7c6['gray'](_0x353e2c(0xd6))),shouldSkipCliSkill(_0x3d3a79)?console[_0x353e2c(0xc7)](a40_0x47d7c6[_0x353e2c(0xb5)](_0x353e2c(0xe0))):await installCliSkill(_0x3d3a79['nonInteractive']),{'ok':!![]};}catch(_0x2e084b){return _0x3cb696[_0x353e2c(0xbd)](_0x353e2c(0xbe)),console[_0x353e2c(0xdf)](a40_0x47d7c6['red']('\x20\x20'+_0x2e084b[_0x353e2c(0xc8)])),console[_0x353e2c(0xc7)](a40_0x47d7c6[_0x353e2c(0xb5)](_0x353e2c(0xc2)+_0x2c2fd5+_0x353e2c(0xc0)+NPM_PACKAGE_NAME+'@'+_0x18dfe8[_0x353e2c(0x97)])),{'ok':![],'message':_0x2e084b[_0x353e2c(0xc8)]};}}function a40_0x2896(){const _0x336da1=['Requested\x20version:\x20','732bDsjMf','run','error','Skipping\x20CLI\x20Built-in\x20Skill\x20refresh\x20(--no-skills).','Update\x20rabetbase\x20CLI\x20to\x20the\x20latest\x20version','str','\x20→\x20','Refresh\x20CLI\x20Built-in\x20Skill\x20after\x20updating','302502IdWCau','@latest','green','npm','Install\x20the\x20version\x20from\x20npm\x20beta\x20dist-tag','Already\x20up\x20to\x20date\x20(v','json','version','skills','3506776PHkHaR','Current\x20version:\x20','Checking\x20CLI\x20Built-in\x20Skill...','Checking\x20for\x20updates...','Invalid\x20version:\x20','/dist-tags','Update\x20available:\x20','boolean','yellow','entries','361899gukvQK','\x20\x20Run\x20manually:\x20','8gMczsg','object','execPath','warn','4143880CNvsHl','19310PbGCEl','info','beta','\x20\x20CLI\x20Built-in\x20Skill\x20update\x20failed:\x20','Version\x20comparison\x20failed','\x20\x20CLI\x20Built-in\x20Skill\x20is\x20up\x20to\x20date.','unknown','Install\x20a\x20specific\x20CLI\x20version','valid','trim','pipe','gray','438288obyweZ','10smjNHB','toLowerCase','source','\x20cli-skill\x20install','Unable\x20to\x20resolve\x20beta\x20version\x20from\x20npm','validation','fail','Update\x20failed','Updating\x20via\x20','\x20install\x20-g\x20','map','\x20\x20Try\x20manually:\x20','Unable\x20to\x20check\x20for\x20updates\x20(network\x20error)','succeed','\x20\x20Run\x20manually:\x20npm\x20install\x20-g\x20','includes','log','message','Already\x20on\x20requested\x20version\x20(v','install','no-skills','bool','inherit','latest','bun','flag','--beta\x20and\x20--version\x20cannot\x20be\x20used\x20together.','fromEntries','\x20\x20Skipped\x20CLI\x20Built-in\x20Skill\x20install\x20(RABETBASE_SKIP_NPX_SKILLS=1).','3545361FpDVfP','slice','\x20\x20Restart\x20your\x20terminal\x20to\x20use\x20the\x20new\x20version.','https://registry.npmjs.org/-/package/','timeout','Beta\x20version:\x20','filter','cwd'];a40_0x2896=function(){return _0x336da1;};return a40_0x2896();}export const updateDefinition={'service':'update','command':a40_0xae5f75(0xde),'description':a40_0xae5f75(0xe1),'risk':'write','requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':updateFlags,'validate':validateUpdateFlags,'execute':execute};
1
+ const a40_0x3af2e3=a40_0xfed1;(function(_0x2e9840,_0x14b1f4){const _0x376c03=a40_0xfed1,_0x5a2a66=_0x2e9840();while(!![]){try{const _0x47af8e=-parseInt(_0x376c03(0x1ec))/0x1*(-parseInt(_0x376c03(0x207))/0x2)+parseInt(_0x376c03(0x1df))/0x3*(-parseInt(_0x376c03(0x1e1))/0x4)+parseInt(_0x376c03(0x221))/0x5*(parseInt(_0x376c03(0x21e))/0x6)+parseInt(_0x376c03(0x210))/0x7+parseInt(_0x376c03(0x228))/0x8*(-parseInt(_0x376c03(0x1fe))/0x9)+parseInt(_0x376c03(0x1e3))/0xa+-parseInt(_0x376c03(0x1de))/0xb;if(_0x47af8e===_0x14b1f4)break;else _0x5a2a66['push'](_0x5a2a66['shift']());}catch(_0x34d3b3){_0x5a2a66['push'](_0x5a2a66['shift']());}}}(a40_0x3e64,0x3d899));import a40_0x113ec4 from'chalk';import a40_0x1487b1 from'ora';import a40_0x3627cb from'semver';import{execa}from'execa';import{CLI_BIN_NAME,NPM_PACKAGE_NAME}from'../constant/cli.js';import{VERSION,GIT_COMMIT,BUILD_TIME}from'../generated/build-info.js';import{CliErrors}from'../errors.js';import{RABETBASE_SKILL_SOURCE,runNpxSkillsAddGlobal}from'../skills/npx-skills-add.js';import{resolveNpmBin}from'../utils/platform.js';function getCurrentVersion(){return GIT_COMMIT!=='unknown'?VERSION+'\x20('+GIT_COMMIT+',\x20'+BUILD_TIME['slice'](0x0,0xa)+')':VERSION;}function detectPackageManager(){const _0xa19f66=a40_0xfed1,_0x5b60e1=process[_0xa19f66(0x1e5)][_0xa19f66(0x20e)]();if(_0x5b60e1[_0xa19f66(0x1f4)](_0xa19f66(0x22d)))return _0xa19f66(0x22d);return _0xa19f66(0x22e);}const updateFlags=[{'name':a40_0x3af2e3(0x229),'type':'boolean','description':a40_0x3af2e3(0x1fc),'default':![]},{'name':a40_0x3af2e3(0x1ff),'type':a40_0x3af2e3(0x217),'description':a40_0x3af2e3(0x208)},{'name':a40_0x3af2e3(0x1fa),'type':a40_0x3af2e3(0x1f1),'description':a40_0x3af2e3(0x20f),'default':![]},{'name':a40_0x3af2e3(0x1f3),'type':a40_0x3af2e3(0x1f1),'description':a40_0x3af2e3(0x215),'default':!![],'hidden':!![]}];function a40_0x3e64(){const _0x26e38b=['\x20→\x20','31004lCxMvk','Install\x20a\x20specific\x20CLI\x20version','green','\x20\x20CLI\x20Built-in\x20Skill\x20is\x20up\x20to\x20date.','object','Update\x20rabetbase\x20CLI\x20to\x20the\x20latest\x20version','@latest','toLowerCase','Skip\x20CLI\x20Built-in\x20Skill\x20refresh\x20after\x20updating','1801359KQQHWg','Already\x20on\x20requested\x20version\x20(v','cwd','inherit','\x20\x20Run\x20manually:\x20npm\x20install\x20-g\x20','Refresh\x20CLI\x20Built-in\x20Skill\x20after\x20updating','Use\x20a\x20full\x20semver\x20such\x20as\x202.1.6\x20or\x202.1.6-beta.1.','string','run','--beta\x20and\x20--version\x20cannot\x20be\x20used\x20together.','Beta\x20version:\x20','update','https://registry.npmjs.org/-/package/','Checking\x20CLI\x20Built-in\x20Skill...','900YPgxsp','Choose\x20either\x20npm\x20beta\x20dist-tag\x20or\x20an\x20exact\x20version.','Updated\x20to\x20v','3710PwPFoN','fail','gray','...','info','Already\x20up\x20to\x20date\x20(v','unknown','46032HpMbLS','beta','trim','length','bool','bun','npm','Invalid\x20version:\x20','\x20\x20Skipped\x20CLI\x20Built-in\x20Skill\x20install\x20(RABETBASE_SKIP_NPX_SKILLS=1).','\x20\x20Run\x20manually:\x20','warn','Checking\x20for\x20updates...','pipe','succeed','3023911XooopW','159oIZgdX','\x20\x20Try\x20manually:\x20','1336UKcIYm','Version\x20comparison\x20failed','3550730dxsFBx','timeout','execPath','log','Unable\x20to\x20check\x20for\x20updates\x20(network\x20error)','Requested\x20version:\x20','flag','\x20cli-skill\x20install','nonInteractive','20HnljFu','valid','source','Unable\x20to\x20resolve\x20beta\x20version\x20from\x20npm','json','boolean','message','skills','includes','yellow','/dist-tags','write','Skipping\x20CLI\x20Built-in\x20Skill\x20refresh\x20(--no-skills).','start','no-skills','skipped','Install\x20the\x20version\x20from\x20npm\x20beta\x20dist-tag','str','765DeUYHd','version','entries','validation','error','latest','\x20\x20CLI\x20Built-in\x20Skill\x20update\x20failed:\x20','\x20\x20Restart\x20your\x20terminal\x20to\x20use\x20the\x20new\x20version.'];a40_0x3e64=function(){return _0x26e38b;};return a40_0x3e64();}function getRequestedVersion(_0x4122bc){const _0x56034c=a40_0x3af2e3;return _0x4122bc[_0x56034c(0x1fd)](_0x56034c(0x1ff))[_0x56034c(0x22a)]();}function shouldSkipCliSkill(_0x507a98){const _0x5f8e8f=a40_0x3af2e3;return _0x507a98['bool']('no-skills')||_0x507a98[_0x5f8e8f(0x1e9)]('skills')===![];}async function validateUpdateFlags(_0x23142a){const _0x2ba15a=a40_0x3af2e3,_0x13a1d0=_0x23142a['bool'](_0x2ba15a(0x229)),_0x11d335=getRequestedVersion(_0x23142a);if(_0x13a1d0&&_0x11d335)throw CliErrors[_0x2ba15a(0x201)](_0x2ba15a(0x219),_0x2ba15a(0x21f));if(_0x11d335&&!a40_0x3627cb['valid'](_0x11d335))throw CliErrors[_0x2ba15a(0x201)](_0x2ba15a(0x22f)+_0x11d335,_0x2ba15a(0x216));}function a40_0xfed1(_0x3e95c6,_0xadda0){_0x3e95c6=_0x3e95c6-0x1dd;const _0x3e64be=a40_0x3e64();let _0xfed1f3=_0x3e64be[_0x3e95c6];return _0xfed1f3;}async function fetchNpmDistTags(){const _0xa0718c=a40_0x3af2e3;try{const _0x53a660=await fetch(_0xa0718c(0x21c)+encodeURIComponent(NPM_PACKAGE_NAME)+_0xa0718c(0x1f6),{'signal':AbortSignal[_0xa0718c(0x1e4)](0x2710)});if(!_0x53a660['ok'])return null;const _0x2b3a05=await _0x53a660[_0xa0718c(0x1f0)]();if(!_0x2b3a05||typeof _0x2b3a05!==_0xa0718c(0x20b))return null;return Object['fromEntries'](Object[_0xa0718c(0x200)](_0x2b3a05)['filter'](([,_0x48ee55])=>typeof _0x48ee55===_0xa0718c(0x217)&&_0x48ee55['trim']()[_0xa0718c(0x22b)]>0x0)['map'](([_0xfa8990,_0x23f6e6])=>[_0xfa8990,String(_0x23f6e6)[_0xa0718c(0x22a)]()]));}catch{return null;}}async function fetchNpmDistTagVersion(_0x2adc6f){const _0x19a376=await fetchNpmDistTags();return _0x19a376?.[_0x2adc6f]??null;}async function fetchLatestVersion(){const _0x2c2d30=a40_0x3af2e3;return fetchNpmDistTagVersion(_0x2c2d30(0x203));}async function resolveTargetVersion(_0x1c6b47){const _0x15fc5d=a40_0x3af2e3,_0x2b9036=getRequestedVersion(_0x1c6b47);if(_0x2b9036)return{'version':_0x2b9036,'source':_0x15fc5d(0x1ff)};if(_0x1c6b47[_0x15fc5d(0x22c)](_0x15fc5d(0x229))){const _0x37bab0=await fetchNpmDistTagVersion('beta');if(!_0x37bab0)return null;return{'version':_0x37bab0,'source':_0x15fc5d(0x229)};}const _0x34d576=await fetchLatestVersion();if(!_0x34d576)return null;return{'version':_0x34d576,'source':'latest'};}function shouldInstallTarget(_0x1ea265,_0x5db7d3){const _0x4197df=a40_0x3af2e3;if(_0x5db7d3[_0x4197df(0x1ee)]===_0x4197df(0x1ff)||_0x5db7d3['source']===_0x4197df(0x229))return!a40_0x3627cb['eq'](_0x1ea265,_0x5db7d3[_0x4197df(0x1ff)]);return a40_0x3627cb['lt'](_0x1ea265,_0x5db7d3[_0x4197df(0x1ff)]);}function getInstallPlanLabel(_0x553189,_0x558566){const _0x254a0f=a40_0x3af2e3;switch(_0x558566['source']){case _0x254a0f(0x229):return _0x254a0f(0x21a)+a40_0x113ec4[_0x254a0f(0x1f5)](_0x553189)+_0x254a0f(0x206)+a40_0x113ec4[_0x254a0f(0x209)](_0x558566['version']);case _0x254a0f(0x1ff):return _0x254a0f(0x1e8)+a40_0x113ec4[_0x254a0f(0x1f5)](_0x553189)+_0x254a0f(0x206)+a40_0x113ec4['green'](_0x558566['version']);case _0x254a0f(0x203):default:return'Update\x20available:\x20'+a40_0x113ec4[_0x254a0f(0x1f5)](_0x553189)+_0x254a0f(0x206)+a40_0x113ec4[_0x254a0f(0x209)](_0x558566['version']);}}async function installCliSkill(_0x5df284){const _0x1029d8=a40_0x3af2e3;console[_0x1029d8(0x1e6)](a40_0x113ec4['gray'](_0x1029d8(0x21d)));const _0x207699=runNpxSkillsAddGlobal(process[_0x1029d8(0x212)](),RABETBASE_SKILL_SOURCE,{'stdio':_0x5df284?_0x1029d8(0x234):_0x1029d8(0x213)});if(_0x207699[_0x1029d8(0x1fb)]){console[_0x1029d8(0x1e6)](a40_0x113ec4[_0x1029d8(0x223)](_0x1029d8(0x230)));return;}if(_0x207699['ok']){console['log'](a40_0x113ec4[_0x1029d8(0x223)](_0x1029d8(0x20a)));return;}console[_0x1029d8(0x232)](a40_0x113ec4['yellow'](_0x1029d8(0x204)+(_0x207699[_0x1029d8(0x202)]||_0x1029d8(0x227)))),console[_0x1029d8(0x1e6)](a40_0x113ec4[_0x1029d8(0x223)](_0x1029d8(0x231)+CLI_BIN_NAME+_0x1029d8(0x1ea)));}async function execute(_0x176114){const _0x226572=a40_0x3af2e3;await validateUpdateFlags(_0x176114);const _0x2ec978=getCurrentVersion();console['log']('Current\x20version:\x20'+_0x2ec978);const _0x11908c=a40_0x1487b1(_0x226572(0x233))[_0x226572(0x1f9)](),_0x3c6fb3=await resolveTargetVersion(_0x176114);if(!_0x3c6fb3){const _0x998174=_0x176114['bool'](_0x226572(0x229))?_0x226572(0x1ef):_0x226572(0x1e7);return _0x11908c['fail'](_0x998174),console[_0x226572(0x1e6)](a40_0x113ec4[_0x226572(0x223)](_0x226572(0x214)+NPM_PACKAGE_NAME+_0x226572(0x20d))),{'ok':![],'message':_0x998174};}const _0x16805f=a40_0x3627cb[_0x226572(0x1ed)](VERSION),_0x28b2d7=a40_0x3627cb[_0x226572(0x1ed)](_0x3c6fb3[_0x226572(0x1ff)]);if(!_0x16805f||!_0x28b2d7)return _0x11908c[_0x226572(0x222)](_0x226572(0x1e2)),{'ok':![],'message':'Version\x20comparison\x20failed'};if(!shouldInstallTarget(_0x16805f,_0x3c6fb3)){const _0x3ab38b=_0x3c6fb3['source']==='version'?_0x226572(0x211)+_0x3c6fb3[_0x226572(0x1ff)]+')':_0x226572(0x226)+_0x3c6fb3[_0x226572(0x1ff)]+')';return _0x11908c[_0x226572(0x1dd)](_0x3ab38b),shouldSkipCliSkill(_0x176114)?console[_0x226572(0x1e6)](a40_0x113ec4['gray']('Skipping\x20CLI\x20Built-in\x20Skill\x20refresh\x20(--no-skills).')):await installCliSkill(_0x176114['nonInteractive']),{'ok':!![]};}_0x11908c[_0x226572(0x225)](getInstallPlanLabel(_0x2ec978,_0x3c6fb3));const _0x319e7b=detectPackageManager(),_0x4f25dd=_0x319e7b==='npm'?resolveNpmBin('npm'):_0x319e7b,_0x56c966=a40_0x1487b1('Updating\x20via\x20'+_0x319e7b+_0x226572(0x224))[_0x226572(0x1f9)]();try{return await execa(_0x4f25dd,['install','-g',NPM_PACKAGE_NAME+'@'+_0x3c6fb3[_0x226572(0x1ff)]],{'stdio':_0x226572(0x234)}),_0x56c966['succeed'](_0x226572(0x220)+_0x3c6fb3[_0x226572(0x1ff)]),console[_0x226572(0x1e6)](a40_0x113ec4[_0x226572(0x223)](_0x226572(0x205))),shouldSkipCliSkill(_0x176114)?console['log'](a40_0x113ec4[_0x226572(0x223)](_0x226572(0x1f8))):await installCliSkill(_0x176114[_0x226572(0x1eb)]),{'ok':!![]};}catch(_0x4e8adb){return _0x56c966[_0x226572(0x222)]('Update\x20failed'),console['error'](a40_0x113ec4['red']('\x20\x20'+_0x4e8adb['message'])),console['log'](a40_0x113ec4[_0x226572(0x223)](_0x226572(0x1e0)+_0x319e7b+'\x20install\x20-g\x20'+NPM_PACKAGE_NAME+'@'+_0x3c6fb3['version'])),{'ok':![],'message':_0x4e8adb[_0x226572(0x1f2)]};}}export const updateDefinition={'service':a40_0x3af2e3(0x21b),'command':a40_0x3af2e3(0x218),'description':a40_0x3af2e3(0x20c),'risk':a40_0x3af2e3(0x1f7),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':updateFlags,'validate':validateUpdateFlags,'execute':execute};
@@ -1 +1 @@
1
- (function(_0x2877e5,_0x5d3323){const _0x16d548=a41_0x49cd,_0x228362=_0x2877e5();while(!![]){try{const _0xe5692b=parseInt(_0x16d548(0x1ef))/0x1+-parseInt(_0x16d548(0x1f5))/0x2+-parseInt(_0x16d548(0x1f4))/0x3+-parseInt(_0x16d548(0x1f6))/0x4+parseInt(_0x16d548(0x1f2))/0x5*(parseInt(_0x16d548(0x1f1))/0x6)+parseInt(_0x16d548(0x1f0))/0x7*(parseInt(_0x16d548(0x1f3))/0x8)+parseInt(_0x16d548(0x1ee))/0x9;if(_0xe5692b===_0x5d3323)break;else _0x228362['push'](_0x228362['shift']());}catch(_0x10ee74){_0x228362['push'](_0x228362['shift']());}}}(a41_0xcaf4,0x4a14c));function a41_0x49cd(_0x586602,_0x2ba941){_0x586602=_0x586602-0x1ee;const _0xcaf424=a41_0xcaf4();let _0x49cda8=_0xcaf424[_0x586602];return _0x49cda8;}import{codegenSdk}from'../../commands/codegen/sdk.js';import{codegenSql}from'../../commands/codegen/sql.js';export const codegenDefinitions=[codegenSdk,codegenSql];function a41_0xcaf4(){const _0x38b0ab=['80969KrwvdC','12RsRISo','1026005JuzWXr','152ALlqUP','1509192oaQeHH','1146360uJUxta','531948pHDQdp','4057659RfVMtC','431641gtSsTO'];a41_0xcaf4=function(){return _0x38b0ab;};return a41_0xcaf4();}
1
+ function a41_0x4de1(){const _0xe07f1d=['3833284tfBMkC','880404XtHObr','8DlKZdU','1208DyzSLq','2796605IepbbK','4605370mBAgKX','30657609birWRS','4374RWSmpi','707349Zdszno'];a41_0x4de1=function(){return _0xe07f1d;};return a41_0x4de1();}(function(_0x3656b0,_0x26cce9){const _0x1746ed=a41_0x1d8b,_0x2d8975=_0x3656b0();while(!![]){try{const _0x4d55ae=parseInt(_0x1746ed(0xc8))/0x1+-parseInt(_0x1746ed(0xc3))/0x2*(-parseInt(_0x1746ed(0xc7))/0x3)+parseInt(_0x1746ed(0xc0))/0x4+parseInt(_0x1746ed(0xc4))/0x5+parseInt(_0x1746ed(0xc1))/0x6+-parseInt(_0x1746ed(0xc5))/0x7*(-parseInt(_0x1746ed(0xc2))/0x8)+-parseInt(_0x1746ed(0xc6))/0x9;if(_0x4d55ae===_0x26cce9)break;else _0x2d8975['push'](_0x2d8975['shift']());}catch(_0x304ab3){_0x2d8975['push'](_0x2d8975['shift']());}}}(a41_0x4de1,0x7b03a));import{codegenSdk}from'../../commands/codegen/sdk.js';import{codegenSql}from'../../commands/codegen/sql.js';function a41_0x1d8b(_0x2a733f,_0x134965){_0x2a733f=_0x2a733f-0xc0;const _0x4de1e9=a41_0x4de1();let _0x1d8b09=_0x4de1e9[_0x2a733f];return _0x1d8b09;}export const codegenDefinitions=[codegenSdk,codegenSql];
@@ -1 +1 @@
1
- const a42_0x45c7a6=a42_0x5949;(function(_0x478d31,_0x17fd8e){const _0x4b7ebf=a42_0x5949,_0x315626=_0x478d31();while(!![]){try{const _0x3ebfd2=parseInt(_0x4b7ebf(0xa5))/0x1+parseInt(_0x4b7ebf(0xa9))/0x2*(-parseInt(_0x4b7ebf(0xb1))/0x3)+-parseInt(_0x4b7ebf(0xae))/0x4+-parseInt(_0x4b7ebf(0xa2))/0x5*(-parseInt(_0x4b7ebf(0xab))/0x6)+-parseInt(_0x4b7ebf(0xa7))/0x7+-parseInt(_0x4b7ebf(0xb3))/0x8*(parseInt(_0x4b7ebf(0xb4))/0x9)+parseInt(_0x4b7ebf(0xb2))/0xa*(parseInt(_0x4b7ebf(0xb0))/0xb);if(_0x3ebfd2===_0x17fd8e)break;else _0x315626['push'](_0x315626['shift']());}catch(_0x49b357){_0x315626['push'](_0x315626['shift']());}}}(a42_0x2610,0xb703d));import{getOperationDetail,generateSdkCode}from'../../core/api-client.js';import{CODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';export const codegenSdk={'service':'codegen','command':a42_0x45c7a6(0xaf),'description':a42_0x45c7a6(0xa6),'risk':'read','flags':[CODE_FLAG_OPTIONAL,{'name':a42_0x45c7a6(0xa8),'type':'string','description':a42_0x45c7a6(0xb7)},{'name':a42_0x45c7a6(0xba),'type':a42_0x45c7a6(0xb6),'required':!![],'description':a42_0x45c7a6(0xac)},{'name':a42_0x45c7a6(0xa1),'type':a42_0x45c7a6(0xa4),'description':a42_0x45c7a6(0xb8)}],async 'execute'(_0xaa0d0c){const _0x5f27e1=a42_0x45c7a6,{dataset:_0x34bdce,operation:_0x4b006f}=await getOperationDetail(_0xaa0d0c['appCode'],_0xaa0d0c[_0x5f27e1(0xb9)](_0x5f27e1(0xb5)),_0xaa0d0c['str'](_0x5f27e1(0xba))),_0x2cb4a6=generateSdkCode(_0x34bdce,_0x4b006f,{'includeImports':!_0xaa0d0c[_0x5f27e1(0xa3)](_0x5f27e1(0xa1))});return{'ok':!![],'data':{'dataset':{'name':_0x34bdce[_0x5f27e1(0xad)],'code':_0x34bdce['code'],'tableName':_0x34bdce[_0x5f27e1(0xaa)]},'operation':_0xaa0d0c[_0x5f27e1(0xb9)](_0x5f27e1(0xba)),'code':_0x2cb4a6}};}};function a42_0x5949(_0x4af6af,_0x76b59d){_0x4af6af=_0x4af6af-0xa1;const _0x26108a=a42_0x2610();let _0x5949c9=_0x26108a[_0x4af6af];return _0x5949c9;}function a42_0x2610(){const _0x278fc0=['181310XZdbiK','2056oIhPHA','11943QKXGZP','code','string','Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon)','Omit\x20import\x20statements\x20from\x20generated\x20code','str','operation','skip-imports','2801870DUFyhC','bool','boolean','596173uZCTEZ','Generate\x20TypeScript\x20SDK\x20code\x20for\x20a\x20dataset\x20operation','8606080YxAaDp','alias','6YVHpcY','tableName','6dwUvAd','Operation\x20name\x20(e.g.\x20filter,\x20getOne,\x20create,\x20update)','name','5691708gguUHr','sdk','1727vQUZIv','260079LSJOJs'];a42_0x2610=function(){return _0x278fc0;};return a42_0x2610();}
1
+ const a42_0x25e9a4=a42_0x4716;function a42_0x4716(_0xe3f2f9,_0x34bfae){_0xe3f2f9=_0xe3f2f9-0x1f3;const _0x4b55c6=a42_0x4b55();let _0x47163b=_0x4b55c6[_0xe3f2f9];return _0x47163b;}function a42_0x4b55(){const _0x4b778b=['2416498QuDAvw','Operation\x20name\x20(e.g.\x20filter,\x20getOne,\x20create,\x20update)','name','6eveyZN','12776nSKDtD','373823HBoFfV','operation','3aqVBem','string','codegen','Omit\x20import\x20statements\x20from\x20generated\x20code','929856popDdQ','Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon)','str','55562rmlNlh','code','read','skip-imports','515OJhxDR','4971960oIdClT','Generate\x20TypeScript\x20SDK\x20code\x20for\x20a\x20dataset\x20operation','sdk','2154591nkLFtF','appCode'];a42_0x4b55=function(){return _0x4b778b;};return a42_0x4b55();}(function(_0x92fd5c,_0x4ca137){const _0x38fa2f=a42_0x4716,_0x1ce83a=_0x92fd5c();while(!![]){try{const _0x345353=-parseInt(_0x38fa2f(0x203))/0x1+-parseInt(_0x38fa2f(0x1f4))/0x2*(parseInt(_0x38fa2f(0x205))/0x3)+-parseInt(_0x38fa2f(0x202))/0x4*(-parseInt(_0x38fa2f(0x1f8))/0x5)+-parseInt(_0x38fa2f(0x201))/0x6*(parseInt(_0x38fa2f(0x1fe))/0x7)+-parseInt(_0x38fa2f(0x209))/0x8+parseInt(_0x38fa2f(0x1fc))/0x9+parseInt(_0x38fa2f(0x1f9))/0xa;if(_0x345353===_0x4ca137)break;else _0x1ce83a['push'](_0x1ce83a['shift']());}catch(_0x17d099){_0x1ce83a['push'](_0x1ce83a['shift']());}}}(a42_0x4b55,0x3171f));import{getOperationDetail,generateSdkCode}from'../../core/api-client.js';import{CODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';export const codegenSdk={'service':a42_0x25e9a4(0x207),'command':a42_0x25e9a4(0x1fb),'description':a42_0x25e9a4(0x1fa),'risk':a42_0x25e9a4(0x1f6),'flags':[CODE_FLAG_OPTIONAL,{'name':'alias','type':a42_0x25e9a4(0x206),'description':a42_0x25e9a4(0x20a)},{'name':a42_0x25e9a4(0x204),'type':a42_0x25e9a4(0x206),'required':!![],'description':a42_0x25e9a4(0x1ff)},{'name':a42_0x25e9a4(0x1f7),'type':'boolean','description':a42_0x25e9a4(0x208)}],async 'execute'(_0x32bddc){const _0x48c041=a42_0x25e9a4,{dataset:_0x25e48a,operation:_0x271f2b}=await getOperationDetail(_0x32bddc[_0x48c041(0x1fd)],_0x32bddc['str']('code'),_0x32bddc[_0x48c041(0x1f3)](_0x48c041(0x204))),_0x557941=generateSdkCode(_0x25e48a,_0x271f2b,{'includeImports':!_0x32bddc['bool'](_0x48c041(0x1f7))});return{'ok':!![],'data':{'dataset':{'name':_0x25e48a[_0x48c041(0x200)],'code':_0x25e48a[_0x48c041(0x1f5)],'tableName':_0x25e48a['tableName']},'operation':_0x32bddc[_0x48c041(0x1f3)](_0x48c041(0x204)),'code':_0x557941}};}};
@@ -1 +1 @@
1
- const a43_0xa697a0=a43_0x3fbe;(function(_0x4e3e1e,_0xeec18){const _0x2c7baa=a43_0x3fbe,_0x4bd013=_0x4e3e1e();while(!![]){try{const _0x35d10a=-parseInt(_0x2c7baa(0x19c))/0x1*(-parseInt(_0x2c7baa(0x1ac))/0x2)+-parseInt(_0x2c7baa(0x1a1))/0x3+-parseInt(_0x2c7baa(0x1aa))/0x4+-parseInt(_0x2c7baa(0x1ab))/0x5*(-parseInt(_0x2c7baa(0x1a2))/0x6)+parseInt(_0x2c7baa(0x1a9))/0x7+-parseInt(_0x2c7baa(0x1a8))/0x8+parseInt(_0x2c7baa(0x19b))/0x9;if(_0x35d10a===_0xeec18)break;else _0x4bd013['push'](_0x4bd013['shift']());}catch(_0x1b15e1){_0x4bd013['push'](_0x4bd013['shift']());}}}(a43_0x12c8,0xe91c4));function a43_0x12c8(){const _0x276452=['Omit\x20import\x20statements\x20from\x20generated\x20code','sdk','appCode','no-imports','sqlcode','8860592GPWugE','8894347xkHdED','3722488zmHbMF','5zFtozb','3168178pmBRac','bff','Code\x20target:\x20sdk\x20(default)\x20or\x20bff','read','Generate\x20TypeScript\x20code\x20for\x20a\x20custom\x20SQL\x20query','171171VhEsHI','1jmMNDs','str','boolean','target','codegen','2555448ewwXVJ','5826618ynCLoY'];a43_0x12c8=function(){return _0x276452;};return a43_0x12c8();}function a43_0x3fbe(_0x2158e0,_0x52398d){_0x2158e0=_0x2158e0-0x19b;const _0x12c83=a43_0x12c8();let _0x3fbe46=_0x12c83[_0x2158e0];return _0x3fbe46;}import{getSqlQueryInfo,generateSqlCodeTemplate}from'../../core/api-client.js';import{SQLCODE_FLAG}from'../../commands/common/flags.js';export const codegenSql={'service':a43_0xa697a0(0x1a0),'command':'sql','description':a43_0xa697a0(0x1b0),'risk':a43_0xa697a0(0x1af),'flags':[SQLCODE_FLAG,{'name':a43_0xa697a0(0x19f),'type':'string','description':a43_0xa697a0(0x1ae),'default':'sdk','enum':[a43_0xa697a0(0x1a4),a43_0xa697a0(0x1ad)]},{'name':a43_0xa697a0(0x1a6),'type':a43_0xa697a0(0x19e),'description':a43_0xa697a0(0x1a3)}],async 'execute'(_0x370d58){const _0x3bff70=a43_0xa697a0,_0x542dcf=await getSqlQueryInfo(_0x370d58[_0x3bff70(0x1a5)],_0x370d58[_0x3bff70(0x19d)](_0x3bff70(0x1a7))),_0x4232aa=_0x370d58[_0x3bff70(0x19d)](_0x3bff70(0x19f))||'sdk',_0xe71238=generateSqlCodeTemplate(_0x542dcf,{'target':_0x4232aa,'includeImports':!_0x370d58['bool'](_0x3bff70(0x1a6))});return{'ok':!![],'data':{'sqlCode':_0x542dcf['sqlCode'],'sqlName':_0x542dcf['sqlName'],'target':_0x4232aa,'code':_0xe71238}};}};
1
+ const a43_0x1c3867=a43_0x13cd;(function(_0x315b93,_0x101bed){const _0x3c40e0=a43_0x13cd,_0x3d2288=_0x315b93();while(!![]){try{const _0x38cb56=parseInt(_0x3c40e0(0x99))/0x1+parseInt(_0x3c40e0(0x9c))/0x2+parseInt(_0x3c40e0(0x9d))/0x3+-parseInt(_0x3c40e0(0x98))/0x4*(-parseInt(_0x3c40e0(0x9a))/0x5)+parseInt(_0x3c40e0(0x8e))/0x6+parseInt(_0x3c40e0(0x8a))/0x7*(parseInt(_0x3c40e0(0x90))/0x8)+parseInt(_0x3c40e0(0x93))/0x9*(-parseInt(_0x3c40e0(0x92))/0xa);if(_0x38cb56===_0x101bed)break;else _0x3d2288['push'](_0x3d2288['shift']());}catch(_0x26ec95){_0x3d2288['push'](_0x3d2288['shift']());}}}(a43_0x19d4,0x5e259));import{getSqlQueryInfo,generateSqlCodeTemplate}from'../../core/api-client.js';import{SQLCODE_FLAG}from'../../commands/common/flags.js';function a43_0x13cd(_0x1dd1f0,_0x2f473d){_0x1dd1f0=_0x1dd1f0-0x8a;const _0x19d461=a43_0x19d4();let _0x13cdc7=_0x19d461[_0x1dd1f0];return _0x13cdc7;}export const codegenSql={'service':a43_0x1c3867(0x9e),'command':a43_0x1c3867(0x91),'description':'Generate\x20TypeScript\x20code\x20for\x20a\x20custom\x20SQL\x20query','risk':a43_0x1c3867(0x94),'flags':[SQLCODE_FLAG,{'name':a43_0x1c3867(0x8b),'type':a43_0x1c3867(0x96),'description':a43_0x1c3867(0x97),'default':a43_0x1c3867(0x95),'enum':[a43_0x1c3867(0x95),'bff']},{'name':a43_0x1c3867(0x9b),'type':a43_0x1c3867(0x8f),'description':a43_0x1c3867(0xa0)}],async 'execute'(_0x14bdb9){const _0x4864a2=a43_0x1c3867,_0x57ff80=await getSqlQueryInfo(_0x14bdb9['appCode'],_0x14bdb9[_0x4864a2(0x8d)](_0x4864a2(0x9f))),_0x3e85d6=_0x14bdb9[_0x4864a2(0x8d)](_0x4864a2(0x8b))||_0x4864a2(0x95),_0x1bd143=generateSqlCodeTemplate(_0x57ff80,{'target':_0x3e85d6,'includeImports':!_0x14bdb9[_0x4864a2(0x8c)](_0x4864a2(0x9b))});return{'ok':!![],'data':{'sqlCode':_0x57ff80['sqlCode'],'sqlName':_0x57ff80['sqlName'],'target':_0x3e85d6,'code':_0x1bd143}};}};function a43_0x19d4(){const _0x48b7a2=['read','sdk','string','Code\x20target:\x20sdk\x20(default)\x20or\x20bff','434140odcSEj','464913EsvSFS','5Emynmx','no-imports','36896mmLVlC','2268723qxxLbg','codegen','sqlcode','Omit\x20import\x20statements\x20from\x20generated\x20code','245scXMnj','target','bool','str','6858dmkUWW','boolean','135544wTPEbk','sql','444760VGvfpQ','315TzXgnJ'];a43_0x19d4=function(){return _0x48b7a2;};return a43_0x19d4();}
@@ -1 +1 @@
1
- (function(_0x4aba39,_0xb2661e){const _0x14ebba=a44_0x158a,_0x1adfbd=_0x4aba39();while(!![]){try{const _0x1abeb0=parseInt(_0x14ebba(0x1c4))/0x1*(parseInt(_0x14ebba(0x1ea))/0x2)+-parseInt(_0x14ebba(0x1d3))/0x3*(parseInt(_0x14ebba(0x1bb))/0x4)+-parseInt(_0x14ebba(0x1de))/0x5*(parseInt(_0x14ebba(0x1cb))/0x6)+-parseInt(_0x14ebba(0x1e7))/0x7+parseInt(_0x14ebba(0x1e1))/0x8+parseInt(_0x14ebba(0x1d8))/0x9*(-parseInt(_0x14ebba(0x1c8))/0xa)+-parseInt(_0x14ebba(0x1c9))/0xb*(-parseInt(_0x14ebba(0x1c0))/0xc);if(_0x1abeb0===_0xb2661e)break;else _0x1adfbd['push'](_0x1adfbd['shift']());}catch(_0x1201d2){_0x1adfbd['push'](_0x1adfbd['shift']());}}}(a44_0x4a7c,0x9e189));function a44_0x4a7c(){const _0x47e5b4=['1250990zqcwzJ','both','\x20Set\x20as\x20default\x20app.','7138584CUnClm','object','length','globalConfig','appcode','Use\x20global\x20config\x20scope','139216GzQOrM','\x20Note:\x20app\x20\x22','keys','6728wFgcde','4wJHoyM','\x22\x20not\x20found.','Missing\x20app\x20name.','App\x20\x22','Usage:\x20','56976jeOPoh','boolean','App\x20code','project','193JrkLnN','validation','\x20Default\x20app\x20changed\x20to\x20\x22','\x20app\x20\x22','2208410gfUEeB','3784WAwZCU','args','24Yknxtk','\x20<name>\x20--appcode\x20<code>','string','global','\x20<name>\x20[--global]','projectConfig','\x22\x20(appcode:\x20','str','3194892DhjKLN','Added','trim','bool','\x20config.','18hBROPa','flagMissing','inherit','\x20<name>','apps','defaultApp'];a44_0x4a7c=function(){return _0x47e5b4;};return a44_0x4a7c();}function a44_0x158a(_0xd6a173,_0x3a6991){_0xd6a173=_0xd6a173-0x1bb;const _0x4a7c93=a44_0x4a7c();let _0x158ac3=_0x4a7c93[_0xd6a173];return _0x158ac3;}import{CliErrors}from'../../errors.js';import{CLI_BIN_NAME}from'../../constant/cli.js';import{collectAppProfileOverrides,getAppProfileFlagDefs}from'../../config/schema.js';import{readRawConfigWithLayers}from'../../context.js';import{readConfig,writeConfig,scopeLabel,resolveAppScopeForWrite,appDefinedIn}from'../../commands/app/shared.js';export function buildAppAddFlags(){const _0x4cde48=a44_0x158a;return[{'name':_0x4cde48(0x1e5),'type':_0x4cde48(0x1cd),'description':_0x4cde48(0x1c2),'required':!![]},{'name':_0x4cde48(0x1ce),'type':'boolean','description':_0x4cde48(0x1e6),'default':![]},...getAppProfileFlagDefs()];}export function buildAppRemoveFlags(){const _0x1197b7=a44_0x158a;return[{'name':'global','type':_0x1197b7(0x1c1),'description':_0x1197b7(0x1e6),'default':![]}];}export async function validateAppName(_0x281329,_0x2dd934){const _0x50d0b4=a44_0x158a,_0x665d91=_0x281329[_0x50d0b4(0x1ca)][0x0]?.[_0x50d0b4(0x1d5)]();if(!_0x665d91)throw CliErrors['validation'](_0x50d0b4(0x1bd),'Usage:\x20'+CLI_BIN_NAME+'\x20'+_0x2dd934+_0x50d0b4(0x1db));}export async function runAppAdd(_0x196d0a,_0x42d77d){const _0x2f6d5b=a44_0x158a,_0xb56eba=_0x196d0a[_0x2f6d5b(0x1ca)][0x0]?.[_0x2f6d5b(0x1d5)]();if(!_0xb56eba)throw CliErrors[_0x2f6d5b(0x1c5)](_0x2f6d5b(0x1bd),_0x2f6d5b(0x1bf)+CLI_BIN_NAME+'\x20'+_0x42d77d+_0x2f6d5b(0x1cc));const _0x4dc683=_0x196d0a[_0x2f6d5b(0x1d2)](_0x2f6d5b(0x1e5));if(!_0x4dc683)throw CliErrors[_0x2f6d5b(0x1d9)](_0x2f6d5b(0x1e5),_0x2f6d5b(0x1bf)+CLI_BIN_NAME+'\x20'+_0x42d77d+_0x2f6d5b(0x1cc));const _0x18515c={'global':_0x196d0a[_0x2f6d5b(0x1d6)]('global')},_0x24d9fa=readConfig(_0x18515c);if(!_0x24d9fa[_0x2f6d5b(0x1dc)])_0x24d9fa[_0x2f6d5b(0x1dc)]={};const _0x1e681e={'appcode':_0x4dc683,...collectAppProfileOverrides(_0x57b97f=>_0x196d0a[_0x2f6d5b(0x1d2)](_0x57b97f))},_0x477ad9=_0x24d9fa[_0x2f6d5b(0x1dc)],_0x12be03=!!_0x477ad9[_0xb56eba];_0x477ad9[_0xb56eba]=_0x1e681e;if(!_0x24d9fa[_0x2f6d5b(0x1dd)])_0x24d9fa['defaultApp']=_0xb56eba;writeConfig(_0x24d9fa,_0x18515c);const _0x1b21c3=!_0x12be03&&_0x24d9fa['defaultApp']===_0xb56eba?_0x2f6d5b(0x1e0):'',_0x2a1ce4=(_0x12be03?'Updated':_0x2f6d5b(0x1d4))+_0x2f6d5b(0x1c7)+_0xb56eba+_0x2f6d5b(0x1d1)+_0x4dc683+')'+scopeLabel(_0x18515c)+'.'+_0x1b21c3;return{'ok':!![],'message':_0x2a1ce4};}export async function runAppRemove(_0x2cce12,_0x3a2853){const _0x3fd715=a44_0x158a,_0x44b75b=_0x2cce12[_0x3fd715(0x1ca)][0x0]?.[_0x3fd715(0x1d5)]();if(!_0x44b75b)throw CliErrors[_0x3fd715(0x1c5)](_0x3fd715(0x1bd),'Usage:\x20'+CLI_BIN_NAME+'\x20'+_0x3a2853+_0x3fd715(0x1cf));const _0x1efc0f=_0x2cce12['bool']('global'),{config:_0x25986d,layers:_0x23ca88}=readRawConfigWithLayers(),_0x585081=_0x25986d[_0x3fd715(0x1dc)]??{};if(!_0x585081[_0x44b75b])throw CliErrors['validation']('App\x20\x22'+_0x44b75b+_0x3fd715(0x1bc));const _0x2fb1ee=_0x23ca88[_0x3fd715(0x1e4)][_0x3fd715(0x1dc)]&&typeof _0x23ca88[_0x3fd715(0x1e4)][_0x3fd715(0x1dc)]==='object'?_0x23ca88[_0x3fd715(0x1e4)]['apps']:{},_0x2022b0=_0x23ca88[_0x3fd715(0x1d0)][_0x3fd715(0x1dc)]&&typeof _0x23ca88[_0x3fd715(0x1d0)][_0x3fd715(0x1dc)]===_0x3fd715(0x1e2)?_0x23ca88[_0x3fd715(0x1d0)]['apps']:{},_0x57a48a=appDefinedIn(_0x44b75b,_0x2fb1ee,_0x2022b0,_0x23ca88[_0x3fd715(0x1d0)][_0x3fd715(0x1da)]===![]),_0x1232d0=resolveAppScopeForWrite(_0x44b75b,_0x1efc0f,_0x23ca88),_0x33c421={'global':_0x1232d0===_0x3fd715(0x1ce)},_0x993a4a=readConfig(_0x33c421),_0x1f8881=_0x993a4a['apps'];if(!_0x1f8881||!_0x1f8881[_0x44b75b])throw CliErrors['validation'](_0x3fd715(0x1be)+_0x44b75b+_0x3fd715(0x1bc));delete _0x1f8881[_0x44b75b];let _0xbd3e4f='';if(_0x993a4a[_0x3fd715(0x1dd)]===_0x44b75b){const _0x19e507=Object[_0x3fd715(0x1e9)](_0x1f8881);_0x993a4a['defaultApp']=_0x19e507[_0x3fd715(0x1e3)]>0x0?_0x19e507[0x0]:undefined,_0x993a4a[_0x3fd715(0x1dd)]?_0xbd3e4f=_0x3fd715(0x1c6)+_0x993a4a[_0x3fd715(0x1dd)]+'\x22.':delete _0x993a4a[_0x3fd715(0x1dd)];}Object[_0x3fd715(0x1e9)](_0x1f8881)[_0x3fd715(0x1e3)]===0x0&&(delete _0x993a4a[_0x3fd715(0x1dc)],delete _0x993a4a[_0x3fd715(0x1dd)]);writeConfig(_0x993a4a,_0x33c421);const _0x39a64f=_0x57a48a===_0x3fd715(0x1df)?_0x3fd715(0x1e8)+_0x44b75b+'\x22\x20still\x20defined\x20in\x20'+(_0x1232d0==='project'?_0x3fd715(0x1ce):_0x3fd715(0x1c3))+_0x3fd715(0x1d7):'';return{'ok':!![],'message':'Removed\x20app\x20\x22'+_0x44b75b+'\x22'+scopeLabel(_0x33c421)+'.'+_0xbd3e4f+_0x39a64f};}
1
+ (function(_0x848ef,_0xa3edde){const _0xe85411=a44_0x174b,_0x476a5c=_0x848ef();while(!![]){try{const _0x4be955=parseInt(_0xe85411(0x16c))/0x1+-parseInt(_0xe85411(0x150))/0x2+parseInt(_0xe85411(0x15b))/0x3*(-parseInt(_0xe85411(0x168))/0x4)+parseInt(_0xe85411(0x16a))/0x5+-parseInt(_0xe85411(0x149))/0x6*(parseInt(_0xe85411(0x15e))/0x7)+-parseInt(_0xe85411(0x15a))/0x8*(-parseInt(_0xe85411(0x164))/0x9)+parseInt(_0xe85411(0x148))/0xa;if(_0x4be955===_0xa3edde)break;else _0x476a5c['push'](_0x476a5c['shift']());}catch(_0x5397ca){_0x476a5c['push'](_0x476a5c['shift']());}}}(a44_0x1ae9,0x6bba7));function a44_0x1ae9(){const _0x31b11b=['validation','args','length','Added','global','\x22\x20still\x20defined\x20in\x20','24eWgIie','1488825EfykTt','bool','Usage:\x20','105XgjkJZ','project','Use\x20global\x20config\x20scope','apps','object','keys','1729440XFRQUl','both','Updated','\x20Set\x20as\x20default\x20app.','4vZBxjz','globalConfig','2508490haqZnO','boolean','146128prMXYh','defaultApp','str','\x20app\x20\x22','\x20Default\x20app\x20changed\x20to\x20\x22','appcode','App\x20\x22','\x20Note:\x20app\x20\x22','\x20<name>','string','trim','7532400ofTReV','317118AWMJBY','projectConfig','\x22\x20(appcode:\x20','Missing\x20app\x20name.','\x20<name>\x20--appcode\x20<code>','\x22\x20not\x20found.','\x20<name>\x20[--global]','494442KVazoY','App\x20code','Removed\x20app\x20\x22','inherit'];a44_0x1ae9=function(){return _0x31b11b;};return a44_0x1ae9();}import{CliErrors}from'../../errors.js';import{CLI_BIN_NAME}from'../../constant/cli.js';import{collectAppProfileOverrides,getAppProfileFlagDefs}from'../../config/schema.js';import{readRawConfigWithLayers}from'../../context.js';import{readConfig,writeConfig,scopeLabel,resolveAppScopeForWrite,appDefinedIn}from'../../commands/app/shared.js';function a44_0x174b(_0x5db2f4,_0x3e773a){_0x5db2f4=_0x5db2f4-0x141;const _0x1ae9c1=a44_0x1ae9();let _0x174b73=_0x1ae9c1[_0x5db2f4];return _0x174b73;}export function buildAppAddFlags(){const _0x3f5c58=a44_0x174b;return[{'name':'appcode','type':_0x3f5c58(0x146),'description':_0x3f5c58(0x151),'required':!![]},{'name':_0x3f5c58(0x158),'type':_0x3f5c58(0x16b),'description':_0x3f5c58(0x160),'default':![]},...getAppProfileFlagDefs()];}export function buildAppRemoveFlags(){const _0x386d32=a44_0x174b;return[{'name':_0x386d32(0x158),'type':_0x386d32(0x16b),'description':_0x386d32(0x160),'default':![]}];}export async function validateAppName(_0x519da6,_0x32a825){const _0x192ad5=a44_0x174b,_0x53ed78=_0x519da6[_0x192ad5(0x155)][0x0]?.[_0x192ad5(0x147)]();if(!_0x53ed78)throw CliErrors[_0x192ad5(0x154)](_0x192ad5(0x14c),_0x192ad5(0x15d)+CLI_BIN_NAME+'\x20'+_0x32a825+_0x192ad5(0x145));}export async function runAppAdd(_0x3c17b9,_0x407a9c){const _0x40a05e=a44_0x174b,_0x170d69=_0x3c17b9[_0x40a05e(0x155)][0x0]?.['trim']();if(!_0x170d69)throw CliErrors[_0x40a05e(0x154)]('Missing\x20app\x20name.',_0x40a05e(0x15d)+CLI_BIN_NAME+'\x20'+_0x407a9c+_0x40a05e(0x14d));const _0xbfdf0c=_0x3c17b9[_0x40a05e(0x16e)](_0x40a05e(0x142));if(!_0xbfdf0c)throw CliErrors['flagMissing'](_0x40a05e(0x142),'Usage:\x20'+CLI_BIN_NAME+'\x20'+_0x407a9c+'\x20<name>\x20--appcode\x20<code>');const _0x104cc1={'global':_0x3c17b9[_0x40a05e(0x15c)](_0x40a05e(0x158))},_0x621ed8=readConfig(_0x104cc1);if(!_0x621ed8[_0x40a05e(0x161)])_0x621ed8[_0x40a05e(0x161)]={};const _0x41efba={'appcode':_0xbfdf0c,...collectAppProfileOverrides(_0x4794f0=>_0x3c17b9[_0x40a05e(0x16e)](_0x4794f0))},_0x203a34=_0x621ed8[_0x40a05e(0x161)],_0x1903be=!!_0x203a34[_0x170d69];_0x203a34[_0x170d69]=_0x41efba;if(!_0x621ed8[_0x40a05e(0x16d)])_0x621ed8[_0x40a05e(0x16d)]=_0x170d69;writeConfig(_0x621ed8,_0x104cc1);const _0x203fb3=!_0x1903be&&_0x621ed8['defaultApp']===_0x170d69?_0x40a05e(0x167):'',_0xbffadd=(_0x1903be?_0x40a05e(0x166):_0x40a05e(0x157))+_0x40a05e(0x16f)+_0x170d69+_0x40a05e(0x14b)+_0xbfdf0c+')'+scopeLabel(_0x104cc1)+'.'+_0x203fb3;return{'ok':!![],'message':_0xbffadd};}export async function runAppRemove(_0x423064,_0x3e3072){const _0x2cd1ee=a44_0x174b,_0x2ab916=_0x423064[_0x2cd1ee(0x155)][0x0]?.[_0x2cd1ee(0x147)]();if(!_0x2ab916)throw CliErrors[_0x2cd1ee(0x154)](_0x2cd1ee(0x14c),_0x2cd1ee(0x15d)+CLI_BIN_NAME+'\x20'+_0x3e3072+_0x2cd1ee(0x14f));const _0xe92092=_0x423064[_0x2cd1ee(0x15c)](_0x2cd1ee(0x158)),{config:_0x310ab8,layers:_0x12e340}=readRawConfigWithLayers(),_0x2da345=_0x310ab8[_0x2cd1ee(0x161)]??{};if(!_0x2da345[_0x2ab916])throw CliErrors[_0x2cd1ee(0x154)]('App\x20\x22'+_0x2ab916+'\x22\x20not\x20found.');const _0x57285f=_0x12e340['globalConfig'][_0x2cd1ee(0x161)]&&typeof _0x12e340[_0x2cd1ee(0x169)][_0x2cd1ee(0x161)]===_0x2cd1ee(0x162)?_0x12e340['globalConfig'][_0x2cd1ee(0x161)]:{},_0x12d9b7=_0x12e340['projectConfig']['apps']&&typeof _0x12e340['projectConfig'][_0x2cd1ee(0x161)]==='object'?_0x12e340['projectConfig']['apps']:{},_0x3f7cd7=appDefinedIn(_0x2ab916,_0x57285f,_0x12d9b7,_0x12e340[_0x2cd1ee(0x14a)][_0x2cd1ee(0x153)]===![]),_0x39b71c=resolveAppScopeForWrite(_0x2ab916,_0xe92092,_0x12e340),_0x50fc4b={'global':_0x39b71c==='global'},_0x25f089=readConfig(_0x50fc4b),_0x421e31=_0x25f089[_0x2cd1ee(0x161)];if(!_0x421e31||!_0x421e31[_0x2ab916])throw CliErrors[_0x2cd1ee(0x154)](_0x2cd1ee(0x143)+_0x2ab916+_0x2cd1ee(0x14e));delete _0x421e31[_0x2ab916];let _0x156ecd='';if(_0x25f089[_0x2cd1ee(0x16d)]===_0x2ab916){const _0x225ba8=Object[_0x2cd1ee(0x163)](_0x421e31);_0x25f089[_0x2cd1ee(0x16d)]=_0x225ba8[_0x2cd1ee(0x156)]>0x0?_0x225ba8[0x0]:undefined,_0x25f089[_0x2cd1ee(0x16d)]?_0x156ecd=_0x2cd1ee(0x141)+_0x25f089[_0x2cd1ee(0x16d)]+'\x22.':delete _0x25f089[_0x2cd1ee(0x16d)];}Object[_0x2cd1ee(0x163)](_0x421e31)[_0x2cd1ee(0x156)]===0x0&&(delete _0x25f089[_0x2cd1ee(0x161)],delete _0x25f089['defaultApp']);writeConfig(_0x25f089,_0x50fc4b);const _0x30c0cd=_0x3f7cd7===_0x2cd1ee(0x165)?_0x2cd1ee(0x144)+_0x2ab916+_0x2cd1ee(0x159)+(_0x39b71c===_0x2cd1ee(0x15f)?_0x2cd1ee(0x158):_0x2cd1ee(0x15f))+'\x20config.':'';return{'ok':!![],'message':_0x2cd1ee(0x152)+_0x2ab916+'\x22'+scopeLabel(_0x50fc4b)+'.'+_0x156ecd+_0x30c0cd};}
@@ -1 +1 @@
1
- function a45_0x2d06(){const _0xb87a6a=['2157288PMeeOV','\x20个应用,请选择\x20(空格勾选,\x20a=全选,\x20i=反选):','includes','Invalid\x20App\x20Code','157494EEfvgq','✎\x20自定义输入\x20appcode','gray','skip','337340kFkicx','(跳过,稍后通过\x20config\x20set\x20appcode\x20配置)','正在获取可用应用列表...','(未检测到登录态,请手动输入\x20App\x20Code\x20或直接跳过)','6rGSjIz','map','请选择要绑定的应用:','cyan','trim','appCode','appName','yellow','\x0a未找到可用应用。','10wOJHFR','167169yqZCIQ','length','2250693yIaBXv','valid','1048565UbTdAR','(跳过,稍后配置)','find','message','319402zLixmc','App\x20Code:','\x20\x20(','custom'];a45_0x2d06=function(){return _0xb87a6a;};return a45_0x2d06();}function a45_0x47cb(_0x321624,_0x2dcb66){_0x321624=_0x321624-0x1ed;const _0x2d06e9=a45_0x2d06();let _0x47cbdb=_0x2d06e9[_0x321624];return _0x47cbdb;}(function(_0x1c9fc8,_0x4ccded){const _0x22822e=a45_0x47cb,_0x25d6e1=_0x1c9fc8();while(!![]){try{const _0x1bf3bc=parseInt(_0x22822e(0x209))/0x1+-parseInt(_0x22822e(0x201))/0x2+-parseInt(_0x22822e(0x1f9))/0x3+parseInt(_0x22822e(0x20d))/0x4*(-parseInt(_0x22822e(0x1f8))/0x5)+-parseInt(_0x22822e(0x1ef))/0x6*(parseInt(_0x22822e(0x1fd))/0x7)+parseInt(_0x22822e(0x205))/0x8+parseInt(_0x22822e(0x1fb))/0x9;if(_0x1bf3bc===_0x4ccded)break;else _0x25d6e1['push'](_0x25d6e1['shift']());}catch(_0xbb476){_0x25d6e1['push'](_0x25d6e1['shift']());}}}(a45_0x2d06,0x22fef));import{input,checkbox,select}from'@inquirer/prompts';import a45_0x4067af from'chalk';import{validateAppcode}from'../../commands/common/validate.js';import{listRemoteApps}from'../../core/api-client.js';import{withActiveCookie}from'../../utils/with-active-cookie.js';import{writeCliSideChannelLine}from'../../utils/write-cli-side-channel.js';export async function promptCustomAppcode(){const _0x3a4d33=a45_0x47cb,_0x5c8a60=await input({'message':'请输入\x20App\x20Code:','validate':_0x262b2d=>{const _0x20ce33=a45_0x47cb,_0x161bac=validateAppcode(_0x262b2d[_0x20ce33(0x1f3)]());return _0x161bac[_0x20ce33(0x1fc)]||_0x161bac['message']||_0x20ce33(0x208);}});return _0x5c8a60[_0x3a4d33(0x1f3)]();}export async function promptAppSelection(_0x5aaf5a){const _0xd12b11=a45_0x47cb,_0x1a7910=[{'name':a45_0x4067af[_0xd12b11(0x1f6)](_0xd12b11(0x20a)),'value':-0x1},..._0x5aaf5a['map']((_0x45a776,_0x2fa56e)=>({'name':_0x45a776[_0xd12b11(0x1f5)]+'\x20\x20'+a45_0x4067af[_0xd12b11(0x20b)]('('+_0x45a776[_0xd12b11(0x1f4)]+')'),'value':_0x2fa56e}))],_0x3a0a01=await checkbox({'message':'获取到\x20'+a45_0x4067af[_0xd12b11(0x1f2)](_0x5aaf5a['length'])+_0xd12b11(0x206),'choices':_0x1a7910,'loop':![]});if(_0x3a0a01[_0xd12b11(0x207)](-0x1))return'custom';if(_0x3a0a01[_0xd12b11(0x1fa)]===0x0)return _0xd12b11(0x204);return _0x3a0a01[_0xd12b11(0x1f0)](_0x52fcce=>_0x5aaf5a[_0x52fcce]);}export async function promptSingleAppSelection(_0x1f7202){const _0x50e236=a45_0x47cb,_0x5d22e4=[{'name':a45_0x4067af['gray'](_0x50e236(0x20e)),'value':_0x50e236(0x20c)},{'name':a45_0x4067af[_0x50e236(0x1f6)]('✎\x20自定义输入\x20appcode'),'value':_0x50e236(0x204)},..._0x1f7202[_0x50e236(0x1f0)](_0x1e507e=>({'name':_0x1e507e[_0x50e236(0x1f5)]+'\x20\x20'+a45_0x4067af['gray']('('+_0x1e507e[_0x50e236(0x1f4)]+')'),'value':_0x1e507e[_0x50e236(0x1f4)]}))],_0x52664a=await select({'message':_0x50e236(0x1f1),'choices':_0x5d22e4});if(_0x52664a===_0x50e236(0x20c))return _0x50e236(0x20c);if(_0x52664a===_0x50e236(0x204))return _0x50e236(0x204);return _0x1f7202[_0x50e236(0x1ff)](_0x4c68b4=>_0x4c68b4[_0x50e236(0x1f4)]===_0x52664a);}export async function selectSingleAppcode(_0x2e3f55){const _0xc19c49=a45_0x47cb;if(!_0x2e3f55)return writeCliSideChannelLine(a45_0x4067af[_0xc19c49(0x20b)](_0xc19c49(0x1ee))),_fallbackOrSkip();writeCliSideChannelLine(_0xc19c49(0x1ed));let _0x4133fc;try{_0x4133fc=await withActiveCookie(_0x2e3f55,()=>listRemoteApps());}catch(_0x35a696){writeCliSideChannelLine(a45_0x4067af['yellow']('无法获取远程应用列表,请手动输入。'));if(_0x35a696 instanceof Error)writeCliSideChannelLine(a45_0x4067af[_0xc19c49(0x20b)](_0xc19c49(0x203)+_0x35a696[_0xc19c49(0x200)]+')'));return _fallbackOrSkip();}if(_0x4133fc['length']===0x0)return writeCliSideChannelLine(a45_0x4067af['yellow']('未找到可用应用。')),_fallbackOrSkip();const _0xc255ac=await promptSingleAppSelection(_0x4133fc);if(_0xc255ac===_0xc19c49(0x20c))return'';if(_0xc255ac==='custom')return promptCustomAppcode();return _0xc255ac['appCode'];}export async function selectMultipleApps(_0x42ce42){const _0x28df3a=a45_0x47cb;writeCliSideChannelLine('正在获取可用应用列表...');let _0x5095b3;try{_0x5095b3=await withActiveCookie(_0x42ce42,()=>listRemoteApps());}catch(_0x291182){writeCliSideChannelLine('\x0a无法获取远程应用列表,请手动输入。');if(_0x291182 instanceof Error)writeCliSideChannelLine('\x20\x20('+_0x291182['message']+')');return _0x28df3a(0x204);}if(_0x5095b3[_0x28df3a(0x1fa)]===0x0)return writeCliSideChannelLine(_0x28df3a(0x1f7)),'custom';return promptAppSelection(_0x5095b3);}async function _fallbackOrSkip(){const _0x2c127d=a45_0x47cb,_0x27ac81=await select({'message':_0x2c127d(0x202),'choices':[{'name':a45_0x4067af[_0x2c127d(0x20b)](_0x2c127d(0x1fe)),'value':'skip'},{'name':a45_0x4067af[_0x2c127d(0x1f6)]('✎\x20手动输入'),'value':'manual'}]});if(_0x27ac81===_0x2c127d(0x20c))return'';return promptCustomAppcode();}
1
+ function a45_0x565b(){const _0xbb05e3=['1VzhasA','✎\x20自定义输入\x20appcode','includes','\x0a无法获取远程应用列表,请手动输入。','请输入\x20App\x20Code:','length','✎\x20手动输入','map','3694563wUathG','find','\x20\x20(','yellow','414692XIbidY','180Alggoi','Invalid\x20App\x20Code','8ZESVIg','valid','请选择要绑定的应用:','trim','skip','无法获取远程应用列表,请手动输入。','正在获取可用应用列表...','2800800ZKbTNw','5MTypkv','4782519cLuNel','255981dLYJka','10OeHBFY','未找到可用应用。','11770713hXrzEz','1656916ivVTmk','custom','appCode','(跳过,稍后通过\x20config\x20set\x20appcode\x20配置)','message','gray'];a45_0x565b=function(){return _0xbb05e3;};return a45_0x565b();}(function(_0x1631a1,_0x57af93){const _0xe249e0=a45_0x1096,_0x34e78f=_0x1631a1();while(!![]){try{const _0x5b62ea=parseInt(_0xe249e0(0x111))/0x1*(parseInt(_0xe249e0(0x12e))/0x2)+-parseInt(_0xe249e0(0x119))/0x3+-parseInt(_0xe249e0(0x11d))/0x4*(parseInt(_0xe249e0(0x128))/0x5)+-parseInt(_0xe249e0(0x127))/0x6+-parseInt(_0xe249e0(0x129))/0x7*(-parseInt(_0xe249e0(0x120))/0x8)+parseInt(_0xe249e0(0x12d))/0x9*(parseInt(_0xe249e0(0x12b))/0xa)+parseInt(_0xe249e0(0x12a))/0xb*(-parseInt(_0xe249e0(0x11e))/0xc);if(_0x5b62ea===_0x57af93)break;else _0x34e78f['push'](_0x34e78f['shift']());}catch(_0x3e1ee8){_0x34e78f['push'](_0x34e78f['shift']());}}}(a45_0x565b,0xa3339));import{input,checkbox,select}from'@inquirer/prompts';import a45_0x274b07 from'chalk';import{validateAppcode}from'../../commands/common/validate.js';import{listRemoteApps}from'../../core/api-client.js';import{withActiveCookie}from'../../utils/with-active-cookie.js';import{writeCliSideChannelLine}from'../../utils/write-cli-side-channel.js';export async function promptCustomAppcode(){const _0x40b2a9=a45_0x1096,_0x566dab=await input({'message':_0x40b2a9(0x115),'validate':_0x3392e5=>{const _0x218b6b=_0x40b2a9,_0x3fff2a=validateAppcode(_0x3392e5[_0x218b6b(0x123)]());return _0x3fff2a[_0x218b6b(0x121)]||_0x3fff2a[_0x218b6b(0x10f)]||_0x218b6b(0x11f);}});return _0x566dab['trim']();}export async function promptAppSelection(_0x384f7d){const _0x53f5e2=a45_0x1096,_0xa67029=[{'name':a45_0x274b07[_0x53f5e2(0x11c)]('✎\x20自定义输入\x20appcode'),'value':-0x1},..._0x384f7d[_0x53f5e2(0x118)]((_0x31634b,_0x412bd7)=>({'name':_0x31634b['appName']+'\x20\x20'+a45_0x274b07[_0x53f5e2(0x110)]('('+_0x31634b[_0x53f5e2(0x10d)]+')'),'value':_0x412bd7}))],_0x44463b=await checkbox({'message':'获取到\x20'+a45_0x274b07['cyan'](_0x384f7d['length'])+'\x20个应用,请选择\x20(空格勾选,\x20a=全选,\x20i=反选):','choices':_0xa67029,'loop':![]});if(_0x44463b[_0x53f5e2(0x113)](-0x1))return _0x53f5e2(0x12f);if(_0x44463b['length']===0x0)return _0x53f5e2(0x12f);return _0x44463b[_0x53f5e2(0x118)](_0x4076cc=>_0x384f7d[_0x4076cc]);}export async function promptSingleAppSelection(_0x201a14){const _0x366f41=a45_0x1096,_0x1697c8=[{'name':a45_0x274b07['gray'](_0x366f41(0x10e)),'value':_0x366f41(0x124)},{'name':a45_0x274b07[_0x366f41(0x11c)](_0x366f41(0x112)),'value':_0x366f41(0x12f)},..._0x201a14['map'](_0x47ddbd=>({'name':_0x47ddbd['appName']+'\x20\x20'+a45_0x274b07[_0x366f41(0x110)]('('+_0x47ddbd[_0x366f41(0x10d)]+')'),'value':_0x47ddbd[_0x366f41(0x10d)]}))],_0x3dd551=await select({'message':_0x366f41(0x122),'choices':_0x1697c8});if(_0x3dd551===_0x366f41(0x124))return _0x366f41(0x124);if(_0x3dd551===_0x366f41(0x12f))return _0x366f41(0x12f);return _0x201a14[_0x366f41(0x11a)](_0x2bed58=>_0x2bed58[_0x366f41(0x10d)]===_0x3dd551);}function a45_0x1096(_0x174970,_0x30875e){_0x174970=_0x174970-0x10d;const _0x565bac=a45_0x565b();let _0x10963d=_0x565bac[_0x174970];return _0x10963d;}export async function selectSingleAppcode(_0x190dbd){const _0x36abe2=a45_0x1096;if(!_0x190dbd)return writeCliSideChannelLine(a45_0x274b07[_0x36abe2(0x110)]('(未检测到登录态,请手动输入\x20App\x20Code\x20或直接跳过)')),_fallbackOrSkip();writeCliSideChannelLine(_0x36abe2(0x126));let _0x2253da;try{_0x2253da=await withActiveCookie(_0x190dbd,()=>listRemoteApps());}catch(_0x571840){writeCliSideChannelLine(a45_0x274b07[_0x36abe2(0x11c)](_0x36abe2(0x125)));if(_0x571840 instanceof Error)writeCliSideChannelLine(a45_0x274b07['gray'](_0x36abe2(0x11b)+_0x571840[_0x36abe2(0x10f)]+')'));return _fallbackOrSkip();}if(_0x2253da['length']===0x0)return writeCliSideChannelLine(a45_0x274b07['yellow'](_0x36abe2(0x12c))),_fallbackOrSkip();const _0x171b75=await promptSingleAppSelection(_0x2253da);if(_0x171b75===_0x36abe2(0x124))return'';if(_0x171b75==='custom')return promptCustomAppcode();return _0x171b75['appCode'];}export async function selectMultipleApps(_0x542b20){const _0x557ebd=a45_0x1096;writeCliSideChannelLine(_0x557ebd(0x126));let _0x3421d3;try{_0x3421d3=await withActiveCookie(_0x542b20,()=>listRemoteApps());}catch(_0x53d3a5){writeCliSideChannelLine(_0x557ebd(0x114));if(_0x53d3a5 instanceof Error)writeCliSideChannelLine(_0x557ebd(0x11b)+_0x53d3a5[_0x557ebd(0x10f)]+')');return _0x557ebd(0x12f);}if(_0x3421d3[_0x557ebd(0x116)]===0x0)return writeCliSideChannelLine('\x0a未找到可用应用。'),_0x557ebd(0x12f);return promptAppSelection(_0x3421d3);}async function _fallbackOrSkip(){const _0x7ab50d=a45_0x1096,_0x3e8790=await select({'message':'App\x20Code:','choices':[{'name':a45_0x274b07['gray']('(跳过,稍后配置)'),'value':'skip'},{'name':a45_0x274b07[_0x7ab50d(0x11c)](_0x7ab50d(0x117)),'value':'manual'}]});if(_0x3e8790===_0x7ab50d(0x124))return'';return promptCustomAppcode();}
@@ -1 +1 @@
1
- const a46_0x3769d9=a46_0x5ba7;(function(_0x354920,_0xceec4){const _0x23135f=a46_0x5ba7,_0x23357a=_0x354920();while(!![]){try{const _0x1b8f93=-parseInt(_0x23135f(0x97))/0x1+-parseInt(_0x23135f(0x9f))/0x2*(parseInt(_0x23135f(0xa3))/0x3)+-parseInt(_0x23135f(0xa4))/0x4*(-parseInt(_0x23135f(0x93))/0x5)+-parseInt(_0x23135f(0xa1))/0x6*(-parseInt(_0x23135f(0xac))/0x7)+parseInt(_0x23135f(0x9a))/0x8+-parseInt(_0x23135f(0xb4))/0x9+parseInt(_0x23135f(0xab))/0xa*(-parseInt(_0x23135f(0xb3))/0xb);if(_0x1b8f93===_0xceec4)break;else _0x23357a['push'](_0x23357a['shift']());}catch(_0x397ed8){_0x23357a['push'](_0x23357a['shift']());}}}(a46_0x5b88,0xcb044));function a46_0x5ba7(_0x2433de,_0x30363c){_0x2433de=_0x2433de-0x92;const _0x5b88ba=a46_0x5b88();let _0x5ba7aa=_0x5b88ba[_0x2433de];return _0x5ba7aa;}import{CLI_BIN_NAME}from'../../constant/cli.js';import{CliErrors}from'../../errors.js';const TERMINAL_STATUSES=new Set([a46_0x3769d9(0xaa),a46_0x3769d9(0x9e)]),NON_TERMINAL_STATUSES=new Set([a46_0x3769d9(0x9d),'PROCESSING']);export function normalizeAsyncTask(_0x2ca6fe){const _0x7db644=a46_0x3769d9,_0x1109e4=typeof _0x2ca6fe?.[_0x7db644(0xb1)]===_0x7db644(0x95)?_0x2ca6fe['taskId'][_0x7db644(0xa0)]():'';if(!_0x1109e4)throw CliErrors[_0x7db644(0x99)](_0x7db644(0xae));const _0x31cffa=typeof _0x2ca6fe['status']===_0x7db644(0x95)?_0x2ca6fe[_0x7db644(0x92)][_0x7db644(0xa0)]()[_0x7db644(0x9c)]():'';if(!_0x31cffa)throw CliErrors[_0x7db644(0x99)](_0x7db644(0xb2)+_0x1109e4+_0x7db644(0xa9));return{'taskId':_0x1109e4,'status':_0x31cffa,'errorMessage':typeof _0x2ca6fe['errorMessage']===_0x7db644(0x95)&&_0x2ca6fe['errorMessage']['trim']()?_0x2ca6fe['errorMessage'][_0x7db644(0xa0)]():null,'isTerminal':TERMINAL_STATUSES[_0x7db644(0x94)](_0x31cffa),'knownStatus':TERMINAL_STATUSES[_0x7db644(0x94)](_0x31cffa)||NON_TERMINAL_STATUSES[_0x7db644(0x94)](_0x31cffa)};}export function buildAsyncTaskStatusCommand(_0x3e412b,_0x316b0e){const _0x2bdb04=a46_0x3769d9;return CLI_BIN_NAME+_0x2bdb04(0xaf)+quoteShellArg(_0x3e412b)+_0x2bdb04(0xa5)+quoteShellArg(_0x316b0e)+_0x2bdb04(0x96);}export function asyncTaskMessage(_0x2bf610){const _0x317474=a46_0x3769d9;switch(_0x2bf610[_0x317474(0x92)]){case _0x317474(0x9d):return _0x317474(0xa6)+_0x2bf610[_0x317474(0xb1)]+_0x317474(0xa2);case _0x317474(0xb0):return _0x317474(0xa6)+_0x2bf610[_0x317474(0xb1)]+_0x317474(0xad);case'SUCCESS':return _0x317474(0xa6)+_0x2bf610[_0x317474(0xb1)]+_0x317474(0xa8);case'FAILED':return _0x2bf610[_0x317474(0x9b)]?_0x317474(0xa6)+_0x2bf610[_0x317474(0xb1)]+'\x20failed:\x20'+_0x2bf610['errorMessage']:_0x317474(0xa6)+_0x2bf610[_0x317474(0xb1)]+'\x20failed.';default:return _0x317474(0xa6)+_0x2bf610[_0x317474(0xb1)]+'\x20returned\x20unknown\x20status\x20'+_0x2bf610['status']+'.';}}function quoteShellArg(_0x576a50){const _0x2a5a76=a46_0x3769d9;return'\x27'+_0x576a50[_0x2a5a76(0x98)](/'/g,_0x2a5a76(0xa7))+'\x27';}function a46_0x5b88(){const _0x52e469=['has','string','\x20--format\x20compress','664946PKaaaM','replace','apiError','9996560GxLaIq','errorMessage','toUpperCase','PENDING','FAILED','2869110OQpotp','trim','24IDaQIm','\x20is\x20pending.','3frdetb','452PeQiRu','\x20--appcode\x20','Task\x20','\x27\x5c\x27\x27','\x20completed\x20successfully.','\x20response\x20did\x20not\x20contain\x20a\x20status.','SUCCESS','310DoRwZi','1551025mcfbrb','\x20is\x20processing.','Async\x20task\x20response\x20did\x20not\x20contain\x20a\x20taskId.','\x20task\x20status\x20--task-id\x20','PROCESSING','taskId','Async\x20task\x20','45001jMWmOI','4257810bUhKIx','status','61730kvjsEa'];a46_0x5b88=function(){return _0x52e469;};return a46_0x5b88();}
1
+ const a46_0x7976cf=a46_0x2c53;(function(_0x302c08,_0x58fd5b){const _0x590b9a=a46_0x2c53,_0x38db1d=_0x302c08();while(!![]){try{const _0x49894c=parseInt(_0x590b9a(0x137))/0x1+parseInt(_0x590b9a(0x138))/0x2*(-parseInt(_0x590b9a(0x124))/0x3)+parseInt(_0x590b9a(0x121))/0x4*(parseInt(_0x590b9a(0x134))/0x5)+-parseInt(_0x590b9a(0x133))/0x6+parseInt(_0x590b9a(0x12a))/0x7*(-parseInt(_0x590b9a(0x136))/0x8)+-parseInt(_0x590b9a(0x12c))/0x9*(-parseInt(_0x590b9a(0x11d))/0xa)+-parseInt(_0x590b9a(0x139))/0xb;if(_0x49894c===_0x58fd5b)break;else _0x38db1d['push'](_0x38db1d['shift']());}catch(_0x109eac){_0x38db1d['push'](_0x38db1d['shift']());}}}(a46_0x3421,0x73035));import{CLI_BIN_NAME}from'../../constant/cli.js';import{CliErrors}from'../../errors.js';const TERMINAL_STATUSES=new Set([a46_0x7976cf(0x122),a46_0x7976cf(0x130)]),NON_TERMINAL_STATUSES=new Set([a46_0x7976cf(0x129),a46_0x7976cf(0x11b)]);export function normalizeAsyncTask(_0x2a3d99){const _0x162df5=a46_0x7976cf,_0x4bc362=typeof _0x2a3d99?.['taskId']===_0x162df5(0x13a)?_0x2a3d99[_0x162df5(0x135)][_0x162df5(0x132)]():'';if(!_0x4bc362)throw CliErrors[_0x162df5(0x13d)](_0x162df5(0x12b));const _0x10f90e=typeof _0x2a3d99[_0x162df5(0x12f)]===_0x162df5(0x13a)?_0x2a3d99[_0x162df5(0x12f)][_0x162df5(0x132)]()[_0x162df5(0x13e)]():'';if(!_0x10f90e)throw CliErrors['apiError'](_0x162df5(0x11c)+_0x4bc362+'\x20response\x20did\x20not\x20contain\x20a\x20status.');return{'taskId':_0x4bc362,'status':_0x10f90e,'errorMessage':typeof _0x2a3d99[_0x162df5(0x13b)]==='string'&&_0x2a3d99[_0x162df5(0x13b)][_0x162df5(0x132)]()?_0x2a3d99[_0x162df5(0x13b)]['trim']():null,'isTerminal':TERMINAL_STATUSES[_0x162df5(0x13c)](_0x10f90e),'knownStatus':TERMINAL_STATUSES['has'](_0x10f90e)||NON_TERMINAL_STATUSES['has'](_0x10f90e)};}function a46_0x3421(){const _0x13a749=['7RXaBeR','Async\x20task\x20response\x20did\x20not\x20contain\x20a\x20taskId.','140499yTTGOp','\x20is\x20pending.','\x20task\x20status\x20--task-id\x20','status','FAILED','\x20failed:\x20','trim','4040190CkgVxm','2357965fJeOME','taskId','5119624ueqapR','903847bmOGIi','295436ADlCSi','2290750OrsneM','string','errorMessage','has','apiError','toUpperCase','PROCESSING','Async\x20task\x20','490jrMuKr','\x20is\x20processing.','\x20completed\x20successfully.','\x20failed.','4hfViLr','SUCCESS','Task\x20','3PKFlRj','\x27\x5c\x27\x27','replace','\x20--appcode\x20','\x20returned\x20unknown\x20status\x20','PENDING'];a46_0x3421=function(){return _0x13a749;};return a46_0x3421();}function a46_0x2c53(_0x211668,_0x5232f1){_0x211668=_0x211668-0x11b;const _0x3421ae=a46_0x3421();let _0x2c53d0=_0x3421ae[_0x211668];return _0x2c53d0;}export function buildAsyncTaskStatusCommand(_0x348764,_0x2f6d0b){const _0xb92041=a46_0x7976cf;return CLI_BIN_NAME+_0xb92041(0x12e)+quoteShellArg(_0x348764)+_0xb92041(0x127)+quoteShellArg(_0x2f6d0b)+'\x20--format\x20compress';}export function asyncTaskMessage(_0x4d1b7c){const _0x5a6a66=a46_0x7976cf;switch(_0x4d1b7c[_0x5a6a66(0x12f)]){case _0x5a6a66(0x129):return _0x5a6a66(0x123)+_0x4d1b7c[_0x5a6a66(0x135)]+_0x5a6a66(0x12d);case'PROCESSING':return'Task\x20'+_0x4d1b7c['taskId']+_0x5a6a66(0x11e);case'SUCCESS':return'Task\x20'+_0x4d1b7c[_0x5a6a66(0x135)]+_0x5a6a66(0x11f);case _0x5a6a66(0x130):return _0x4d1b7c[_0x5a6a66(0x13b)]?_0x5a6a66(0x123)+_0x4d1b7c[_0x5a6a66(0x135)]+_0x5a6a66(0x131)+_0x4d1b7c['errorMessage']:_0x5a6a66(0x123)+_0x4d1b7c[_0x5a6a66(0x135)]+_0x5a6a66(0x120);default:return _0x5a6a66(0x123)+_0x4d1b7c['taskId']+_0x5a6a66(0x128)+_0x4d1b7c[_0x5a6a66(0x12f)]+'.';}}function quoteShellArg(_0x53df7b){const _0x32423e=a46_0x7976cf;return'\x27'+_0x53df7b[_0x32423e(0x126)](/'/g,_0x32423e(0x125))+'\x27';}
@@ -1 +1 @@
1
- function a47_0x4c14(_0x362e7e,_0x1f35a5){_0x362e7e=_0x362e7e-0x1a8;var _0x12836f=a47_0x1283();var _0x4c14ad=_0x12836f[_0x362e7e];return _0x4c14ad;}function a47_0x1283(){var _0x15f590=['45GMJEkW','505752yaKyrd','defineProperties','1824180gQkSDQ','19732HWMfxl','3948736MPHraT','2149760QkPNNy','4ozoazs','description','102hwPLlt','440778NmfQvR','method','3723642WzAbZT','28MGUTWn'];a47_0x1283=function(){return _0x15f590;};return a47_0x1283();}(function(_0x4cbf2f,_0xc75917){var _0x2c44fd=a47_0x4c14,_0x24ceae=_0x4cbf2f();while(!![]){try{var _0x2c87b8=-parseInt(_0x2c44fd(0x1ad))/0x1*(-parseInt(_0x2c44fd(0x1a8))/0x2)+-parseInt(_0x2c44fd(0x1ae))/0x3*(-parseInt(_0x2c44fd(0x1ab))/0x4)+-parseInt(_0x2c44fd(0x1aa))/0x5+parseInt(_0x2c44fd(0x1b0))/0x6+parseInt(_0x2c44fd(0x1b1))/0x7*(-parseInt(_0x2c44fd(0x1b3))/0x8)+parseInt(_0x2c44fd(0x1b2))/0x9*(-parseInt(_0x2c44fd(0x1b5))/0xa)+parseInt(_0x2c44fd(0x1a9))/0xb;if(_0x2c87b8===_0xc75917)break;else _0x24ceae['push'](_0x24ceae['shift']());}catch(_0x55cfc5){_0x24ceae['push'](_0x24ceae['shift']());}}}(a47_0x1283,0x83543));export function asDryRunResult(_0x29d787,_0x5305ff){var _0x482198=a47_0x4c14;return Object[_0x482198(0x1b4)](_0x29d787,{'method':{'value':_0x5305ff[_0x482198(0x1af)],'enumerable':![]},'url':{'value':_0x5305ff['url'],'enumerable':![]},..._0x5305ff['description']?{'description':{'value':_0x5305ff[_0x482198(0x1ac)],'enumerable':![]}}:{}});}
1
+ function a47_0x47c5(_0x2bb31b,_0x578c1f){_0x2bb31b=_0x2bb31b-0x1a6;var _0x540772=a47_0x5407();var _0x47c541=_0x540772[_0x2bb31b];return _0x47c541;}function a47_0x5407(){var _0x2612f9=['830869OBKxSP','24yitxeh','6838200elxybZ','defineProperties','5aTSHvv','3039524BHseqt','3144432flwmrQ','url','37081800WNVMHJ','method','1957529nSoICi','903304XFZqdV','description'];a47_0x5407=function(){return _0x2612f9;};return a47_0x5407();}(function(_0x526ecf,_0x3f31ad){var _0x37a642=a47_0x47c5,_0x57e23c=_0x526ecf();while(!![]){try{var _0x49fe51=parseInt(_0x37a642(0x1af))/0x1+-parseInt(_0x37a642(0x1ad))/0x2+-parseInt(_0x37a642(0x1a8))/0x3+-parseInt(_0x37a642(0x1a7))/0x4*(parseInt(_0x37a642(0x1a6))/0x5)+-parseInt(_0x37a642(0x1b0))/0x6*(parseInt(_0x37a642(0x1ac))/0x7)+-parseInt(_0x37a642(0x1b1))/0x8+parseInt(_0x37a642(0x1aa))/0x9;if(_0x49fe51===_0x3f31ad)break;else _0x57e23c['push'](_0x57e23c['shift']());}catch(_0x33d3ba){_0x57e23c['push'](_0x57e23c['shift']());}}}(a47_0x5407,0xaf4cd));export function asDryRunResult(_0xe284fd,_0x53780f){var _0x489037=a47_0x47c5;return Object[_0x489037(0x1b2)](_0xe284fd,{'method':{'value':_0x53780f[_0x489037(0x1ab)],'enumerable':![]},'url':{'value':_0x53780f[_0x489037(0x1a9)],'enumerable':![]},..._0x53780f[_0x489037(0x1ae)]?{'description':{'value':_0x53780f[_0x489037(0x1ae)],'enumerable':![]}}:{}});}
@@ -1 +1 @@
1
- const a48_0x21f6fc=a48_0x5168;function a48_0x5168(_0x3dccaf,_0x479553){_0x3dccaf=_0x3dccaf-0x76;const _0x24a94b=a48_0x24a9();let _0x516878=_0x24a94b[_0x3dccaf];return _0x516878;}(function(_0x5cee45,_0x54ce79){const _0x464622=a48_0x5168,_0x4eba1c=_0x5cee45();while(!![]){try{const _0x2b4f29=-parseInt(_0x464622(0x7b))/0x1*(parseInt(_0x464622(0x8a))/0x2)+parseInt(_0x464622(0x82))/0x3*(parseInt(_0x464622(0x84))/0x4)+parseInt(_0x464622(0x81))/0x5*(parseInt(_0x464622(0x8f))/0x6)+-parseInt(_0x464622(0x8d))/0x7+-parseInt(_0x464622(0x7a))/0x8*(parseInt(_0x464622(0x79))/0x9)+-parseInt(_0x464622(0x89))/0xa*(-parseInt(_0x464622(0x7f))/0xb)+-parseInt(_0x464622(0x7c))/0xc;if(_0x2b4f29===_0x54ce79)break;else _0x4eba1c['push'](_0x4eba1c['shift']());}catch(_0x3541ab){_0x4eba1c['push'](_0x4eba1c['shift']());}}}(a48_0x24a9,0x3a48e));export const DATASET_CODE_PATTERN={'regex':/^[a-f0-9]{32}$/i,'description':a48_0x21f6fc(0x7e)};export const CODE_FLAG={'name':a48_0x21f6fc(0x86),'type':'string','required':!![],'description':a48_0x21f6fc(0x78),'pattern':DATASET_CODE_PATTERN};export const CODE_FLAG_OPTIONAL={...CODE_FLAG,'required':![]};export const DATASETCODE_FLAG_OPTIONAL={...CODE_FLAG_OPTIONAL,'name':'datasetcode','description':a48_0x21f6fc(0x78)};export const SQLCODE_FLAG={'name':a48_0x21f6fc(0x8c),'type':a48_0x21f6fc(0x77),'required':!![],'description':a48_0x21f6fc(0x88),'pattern':{'regex':/^[a-f0-9]{8}-[a-f0-9]{8}$/i,'description':a48_0x21f6fc(0x87)}};export const APPCODE_FLAG_OPTIONAL={'name':a48_0x21f6fc(0x83),'type':'string','required':![],'description':a48_0x21f6fc(0x85)};export const APPCODE_FLAG={...APPCODE_FLAG_OPTIONAL,'required':!![],'description':a48_0x21f6fc(0x8e)};function a48_0x24a9(){const _0x497557=['200511JUaFJs','56elCwCz','79102miWuhO','2358648lCBhZD','Database\x20connection\x20ID\x20(dblink\x20id\x20from\x20db\x20list)','a\x2032-character\x20hex\x20string\x20(e.g.\x2099a909313f1fa7153186431e1c551588)','2483679EnkeuC','dbtype','211865XOMbAX','15eeqYml','appcode','347264qPPBbX','App\x20code\x20(overrides\x20config\x20file,\x20e.g.\x20app-xxxxx)','code','SQL\x20code\x20in\x20format\x20xxxxxxxx-xxxxxxxx\x20(e.g.\x202305f915-dd48cd4c)','SQL\x20code\x20identifier\x20(format:\x20xxxxxxxx-xxxxxxxx,\x20e.g.\x202305f915-dd48cd4c)','20ISGcUE','8AJxyna','POSTGRESQL','sqlcode','1329118iQchTc','App\x20code\x20(e.g.\x20app-xxxxx)','30BqxzKZ','number','string','Dataset\x20code\x20(32-char\x20hex\x20UUID)'];a48_0x24a9=function(){return _0x497557;};return a48_0x24a9();}export const SQLCODE_FLAG_OPTIONAL={...SQLCODE_FLAG,'required':![]};export const DBLINK_ID_FLAG={'name':'id','type':a48_0x21f6fc(0x76),'required':!![],'description':a48_0x21f6fc(0x7d)};export const DB_TYPE_FLAG={'name':a48_0x21f6fc(0x80),'type':a48_0x21f6fc(0x77),'required':!![],'description':'Database\x20product\x20type','enum':['MYSQL',a48_0x21f6fc(0x8b)]};
1
+ const a48_0x1006be=a48_0x366b;(function(_0x378112,_0x46ea73){const _0x45850e=a48_0x366b,_0x526e54=_0x378112();while(!![]){try{const _0x5c8dee=parseInt(_0x45850e(0xcf))/0x1*(-parseInt(_0x45850e(0xcd))/0x2)+-parseInt(_0x45850e(0xe1))/0x3+parseInt(_0x45850e(0xc9))/0x4*(-parseInt(_0x45850e(0xcc))/0x5)+parseInt(_0x45850e(0xd3))/0x6+-parseInt(_0x45850e(0xd5))/0x7+parseInt(_0x45850e(0xd7))/0x8*(-parseInt(_0x45850e(0xd1))/0x9)+-parseInt(_0x45850e(0xde))/0xa*(-parseInt(_0x45850e(0xd6))/0xb);if(_0x5c8dee===_0x46ea73)break;else _0x526e54['push'](_0x526e54['shift']());}catch(_0x273503){_0x526e54['push'](_0x526e54['shift']());}}}(a48_0x4467,0x52220));export const DATASET_CODE_PATTERN={'regex':/^[a-f0-9]{32}$/i,'description':a48_0x1006be(0xda)};export const CODE_FLAG={'name':a48_0x1006be(0xd8),'type':a48_0x1006be(0xd9),'required':!![],'description':a48_0x1006be(0xd4),'pattern':DATASET_CODE_PATTERN};export const CODE_FLAG_OPTIONAL={...CODE_FLAG,'required':![]};function a48_0x366b(_0xf01217,_0x3545e4){_0xf01217=_0xf01217-0xc8;const _0x446788=a48_0x4467();let _0x366bfe=_0x446788[_0xf01217];return _0x366bfe;}export const DATASETCODE_FLAG_OPTIONAL={...CODE_FLAG_OPTIONAL,'name':a48_0x1006be(0xdc),'description':a48_0x1006be(0xd4)};export const SQLCODE_FLAG={'name':a48_0x1006be(0xdf),'type':a48_0x1006be(0xd9),'required':!![],'description':a48_0x1006be(0xdb),'pattern':{'regex':/^[a-f0-9]{8}-[a-f0-9]{8}$/i,'description':a48_0x1006be(0xce)}};export const APPCODE_FLAG_OPTIONAL={'name':a48_0x1006be(0xca),'type':a48_0x1006be(0xd9),'required':![],'description':a48_0x1006be(0xdd)};export const APPCODE_FLAG={...APPCODE_FLAG_OPTIONAL,'required':!![],'description':'App\x20code\x20(e.g.\x20app-xxxxx)'};function a48_0x4467(){const _0x4b79ba=['6289veUOal','Database\x20connection\x20ID\x20(dblink\x20id\x20from\x20db\x20list)','9nmJEaS','Database\x20product\x20type','2350092yXwZkN','Dataset\x20code\x20(32-char\x20hex\x20UUID)','1116787woBulk','11XRbbqw','1861128BlbNNA','code','string','a\x2032-character\x20hex\x20string\x20(e.g.\x2099a909313f1fa7153186431e1c551588)','SQL\x20code\x20identifier\x20(format:\x20xxxxxxxx-xxxxxxxx,\x20e.g.\x202305f915-dd48cd4c)','datasetcode','App\x20code\x20(overrides\x20config\x20file,\x20e.g.\x20app-xxxxx)','12310500DTtzXH','sqlcode','dbtype','1332036gkbsUd','POSTGRESQL','12cSQlQk','appcode','number','446235puqopj','58NtmfIY','SQL\x20code\x20in\x20format\x20xxxxxxxx-xxxxxxxx\x20(e.g.\x202305f915-dd48cd4c)'];a48_0x4467=function(){return _0x4b79ba;};return a48_0x4467();}export const SQLCODE_FLAG_OPTIONAL={...SQLCODE_FLAG,'required':![]};export const DBLINK_ID_FLAG={'name':'id','type':a48_0x1006be(0xcb),'required':!![],'description':a48_0x1006be(0xd0)};export const DB_TYPE_FLAG={'name':a48_0x1006be(0xe0),'type':a48_0x1006be(0xd9),'required':!![],'description':a48_0x1006be(0xd2),'enum':['MYSQL',a48_0x1006be(0xc8)]};
@@ -1 +1 @@
1
- (function(_0x5cb0be,_0x10444e){const _0x942bb4=a49_0xab9b,_0x1cb694=_0x5cb0be();while(!![]){try{const _0x2f44a5=-parseInt(_0x942bb4(0x1e7))/0x1*(parseInt(_0x942bb4(0x1d9))/0x2)+-parseInt(_0x942bb4(0x1e1))/0x3+-parseInt(_0x942bb4(0x1e3))/0x4*(-parseInt(_0x942bb4(0x1dc))/0x5)+parseInt(_0x942bb4(0x1e8))/0x6+parseInt(_0x942bb4(0x1db))/0x7*(-parseInt(_0x942bb4(0x1da))/0x8)+parseInt(_0x942bb4(0x1d8))/0x9*(-parseInt(_0x942bb4(0x1e2))/0xa)+parseInt(_0x942bb4(0x1df))/0xb*(parseInt(_0x942bb4(0x1e6))/0xc);if(_0x2f44a5===_0x10444e)break;else _0x1cb694['push'](_0x1cb694['shift']());}catch(_0x486c15){_0x1cb694['push'](_0x1cb694['shift']());}}}(a49_0x5edd,0xd66fd));import{existsSync,statSync}from'node:fs';import{CliErrors}from'../../errors.js';const BYTES_PER_MB=0x400*0x400;function a49_0xab9b(_0x1ecc89,_0x3c4451){_0x1ecc89=_0x1ecc89-0x1d6;const _0x5eddf6=a49_0x5edd();let _0xab9b62=_0x5eddf6[_0x1ecc89];return _0xab9b62;}export const DEVELOPMENT_UPLOAD_MAX_BYTES=0x32*BYTES_PER_MB;function a49_0x5edd(){const _0x2b00f2=['58XgwYhF','8MZKKjA','573251dZLnRL','5045eruqMu','File\x20is\x20not\x20a\x20regular\x20file:\x20','File\x20exceeds\x20the\x20development\x20upload\x20limit\x20of\x2050\x20MB:\x20','16788695cMemDJ','isFile','4039776hHalHG','45010mIzZXz','6884BAffMo','File\x20not\x20found:\x20','toFixed','12IiCrXo','17083PXfrzP','2773176VyBHnQ','validation','trim','size','1845SxxWsk'];a49_0x5edd=function(){return _0x2b00f2;};return a49_0x5edd();}function formatBytes(_0x402d34){const _0x52201f=a49_0xab9b;if(_0x402d34>=BYTES_PER_MB){const _0x5d207a=Math['ceil'](_0x402d34/BYTES_PER_MB*0x64)/0x64;return _0x5d207a[_0x52201f(0x1e5)](0x2)+'\x20MB';}return _0x402d34+'\x20B';}export function requireDevelopmentUploadFile(_0x440c8b,_0x45762d){const _0x56e3cc=a49_0xab9b,_0x139b6f=_0x440c8b[_0x56e3cc(0x1d6)]();if(!_0x139b6f)throw CliErrors[_0x56e3cc(0x1e9)](_0x45762d+'\x20path\x20is\x20required.');if(!existsSync(_0x139b6f))throw CliErrors[_0x56e3cc(0x1e9)](_0x56e3cc(0x1e4)+_0x139b6f);const _0x1dcb8c=statSync(_0x139b6f);if(!_0x1dcb8c[_0x56e3cc(0x1e0)]())throw CliErrors[_0x56e3cc(0x1e9)](_0x56e3cc(0x1dd)+_0x139b6f);if(_0x1dcb8c[_0x56e3cc(0x1d7)]>DEVELOPMENT_UPLOAD_MAX_BYTES)throw CliErrors[_0x56e3cc(0x1e9)](_0x56e3cc(0x1de)+_0x139b6f+'\x20('+formatBytes(_0x1dcb8c[_0x56e3cc(0x1d7)])+')');return{'path':_0x139b6f,'size':_0x1dcb8c[_0x56e3cc(0x1d7)]};}
1
+ (function(_0x344ee3,_0x1c7d7c){const _0x2ebc88=a49_0x2cb9,_0x337d62=_0x344ee3();while(!![]){try{const _0x57f2d5=-parseInt(_0x2ebc88(0x1b9))/0x1*(-parseInt(_0x2ebc88(0x1b2))/0x2)+parseInt(_0x2ebc88(0x1bd))/0x3+parseInt(_0x2ebc88(0x1b8))/0x4*(parseInt(_0x2ebc88(0x1b4))/0x5)+-parseInt(_0x2ebc88(0x1bc))/0x6+parseInt(_0x2ebc88(0x1b5))/0x7*(-parseInt(_0x2ebc88(0x1b6))/0x8)+-parseInt(_0x2ebc88(0x1b1))/0x9+-parseInt(_0x2ebc88(0x1be))/0xa*(-parseInt(_0x2ebc88(0x1bf))/0xb);if(_0x57f2d5===_0x1c7d7c)break;else _0x337d62['push'](_0x337d62['shift']());}catch(_0x5ea912){_0x337d62['push'](_0x337d62['shift']());}}}(a49_0x268c,0xc19fe));import{existsSync,statSync}from'node:fs';function a49_0x2cb9(_0x418c48,_0x777d45){_0x418c48=_0x418c48-0x1ac;const _0x268c41=a49_0x268c();let _0x2cb955=_0x268c41[_0x418c48];return _0x2cb955;}import{CliErrors}from'../../errors.js';function a49_0x268c(){const _0x52abfe=['\x20path\x20is\x20required.','size','File\x20is\x20not\x20a\x20regular\x20file:\x20','trim','11843451HoYqzO','1749714zFQwVa','File\x20exceeds\x20the\x20development\x20upload\x20limit\x20of\x2050\x20MB:\x20','590405BRpGhL','14pTeaUt','5999416gRBqFn','ceil','40PWWICK','1bxBYNK','validation','toFixed','7762962vqZVkN','4355253urXgnD','90kpqqhY','1705352mwSNsm','\x20MB','isFile'];a49_0x268c=function(){return _0x52abfe;};return a49_0x268c();}const BYTES_PER_MB=0x400*0x400;export const DEVELOPMENT_UPLOAD_MAX_BYTES=0x32*BYTES_PER_MB;function formatBytes(_0x404709){const _0x49258b=a49_0x2cb9;if(_0x404709>=BYTES_PER_MB){const _0x25eb65=Math[_0x49258b(0x1b7)](_0x404709/BYTES_PER_MB*0x64)/0x64;return _0x25eb65[_0x49258b(0x1bb)](0x2)+_0x49258b(0x1c0);}return _0x404709+'\x20B';}export function requireDevelopmentUploadFile(_0x5dc02c,_0x4124eb){const _0x257bdf=a49_0x2cb9,_0x102feb=_0x5dc02c[_0x257bdf(0x1b0)]();if(!_0x102feb)throw CliErrors[_0x257bdf(0x1ba)](_0x4124eb+_0x257bdf(0x1ad));if(!existsSync(_0x102feb))throw CliErrors['validation']('File\x20not\x20found:\x20'+_0x102feb);const _0xa2e3aa=statSync(_0x102feb);if(!_0xa2e3aa[_0x257bdf(0x1ac)]())throw CliErrors[_0x257bdf(0x1ba)](_0x257bdf(0x1af)+_0x102feb);if(_0xa2e3aa[_0x257bdf(0x1ae)]>DEVELOPMENT_UPLOAD_MAX_BYTES)throw CliErrors[_0x257bdf(0x1ba)](_0x257bdf(0x1b3)+_0x102feb+'\x20('+formatBytes(_0xa2e3aa[_0x257bdf(0x1ae)])+')');return{'path':_0x102feb,'size':_0xa2e3aa[_0x257bdf(0x1ae)]};}
@@ -1 +1 @@
1
- function a50_0x2575(_0x2c7e49,_0x34fbdf){_0x2c7e49=_0x2c7e49-0x1b5;const _0x192695=a50_0x1926();let _0x2575df=_0x192695[_0x2c7e49];return _0x2575df;}(function(_0x16d444,_0x41e184){const _0x374e09=a50_0x2575,_0x37a7ce=_0x16d444();while(!![]){try{const _0x2163fc=-parseInt(_0x374e09(0x1b6))/0x1+-parseInt(_0x374e09(0x1be))/0x2*(-parseInt(_0x374e09(0x1c1))/0x3)+parseInt(_0x374e09(0x1b5))/0x4*(parseInt(_0x374e09(0x1ba))/0x5)+-parseInt(_0x374e09(0x1c2))/0x6*(parseInt(_0x374e09(0x1bd))/0x7)+-parseInt(_0x374e09(0x1bc))/0x8+-parseInt(_0x374e09(0x1bf))/0x9*(-parseInt(_0x374e09(0x1bb))/0xa)+-parseInt(_0x374e09(0x1b8))/0xb*(-parseInt(_0x374e09(0x1c3))/0xc);if(_0x2163fc===_0x41e184)break;else _0x37a7ce['push'](_0x37a7ce['shift']());}catch(_0x239db0){_0x37a7ce['push'](_0x37a7ce['shift']());}}}(a50_0x1926,0xee2a2));export function validateAppcode(_0x2b0341){const _0x3a5c4f=a50_0x2575,_0x239487=_0x2b0341['trim']();if(!_0x239487)return{'valid':![],'message':_0x3a5c4f(0x1b7)};if(_0x239487['length']>0x64)return{'valid':![],'message':_0x3a5c4f(0x1c0)};if(!/^[A-Za-z0-9_-]+$/[_0x3a5c4f(0x1b9)](_0x239487))return{'valid':![],'message':_0x3a5c4f(0x1c4)};return{'valid':!![]};}function a50_0x1926(){const _0x98f95f=['Only\x20letters,\x20numbers,\x20-\x20and\x20_\x20are\x20allowed','188VtZdES','106157mOCBRQ','App\x20Code\x20cannot\x20be\x20empty','11KVGSuB','test','28540AlsUkt','90wkcROm','13110024PoCZAg','518gEkRSY','1254sJzIjX','1070469qfcxhL','App\x20Code\x20cannot\x20exceed\x20100\x20characters','1014VnkwQg','57144nTkyYA','22494444XEkDQr'];a50_0x1926=function(){return _0x98f95f;};return a50_0x1926();}
1
+ function a50_0x17c7(_0x9b0ae0,_0x2cf85c){_0x9b0ae0=_0x9b0ae0-0xf3;const _0x499a6b=a50_0x499a();let _0x17c763=_0x499a6b[_0x9b0ae0];return _0x17c763;}(function(_0x12e507,_0x11569d){const _0x313b6d=a50_0x17c7,_0x107e86=_0x12e507();while(!![]){try{const _0x331a07=parseInt(_0x313b6d(0xfd))/0x1+parseInt(_0x313b6d(0x100))/0x2*(-parseInt(_0x313b6d(0xf6))/0x3)+-parseInt(_0x313b6d(0xfb))/0x4*(parseInt(_0x313b6d(0xf4))/0x5)+-parseInt(_0x313b6d(0xf9))/0x6*(-parseInt(_0x313b6d(0x101))/0x7)+parseInt(_0x313b6d(0xff))/0x8+parseInt(_0x313b6d(0xf5))/0x9+parseInt(_0x313b6d(0xfc))/0xa*(-parseInt(_0x313b6d(0xfa))/0xb);if(_0x331a07===_0x11569d)break;else _0x107e86['push'](_0x107e86['shift']());}catch(_0xd16b0b){_0x107e86['push'](_0x107e86['shift']());}}}(a50_0x499a,0xa7119));export function validateAppcode(_0x388c60){const _0x2945d3=a50_0x17c7,_0x288dab=_0x388c60[_0x2945d3(0xfe)]();if(!_0x288dab)return{'valid':![],'message':_0x2945d3(0xf3)};if(_0x288dab[_0x2945d3(0xf8)]>0x64)return{'valid':![],'message':_0x2945d3(0xf7)};if(!/^[A-Za-z0-9_-]+$/[_0x2945d3(0x102)](_0x288dab))return{'valid':![],'message':_0x2945d3(0x103)};return{'valid':!![]};}function a50_0x499a(){const _0x3dc8df=['797905jSVkXE','trim','4455232tzUSul','26222daimZr','426069mBPfqA','test','Only\x20letters,\x20numbers,\x20-\x20and\x20_\x20are\x20allowed','App\x20Code\x20cannot\x20be\x20empty','15GrUSPE','6964227FJaxla','183iANsGN','App\x20Code\x20cannot\x20exceed\x20100\x20characters','length','60GusKbE','649dpmdGI','1582116QsZbdu','11290JnuGYx'];a50_0x499a=function(){return _0x3dc8df;};return a50_0x499a();}
@@ -1 +1 @@
1
- const a51_0x594c75=a51_0x126c;(function(_0x1dfd24,_0x4a83ca){const _0x52ebb9=a51_0x126c,_0x5df66b=_0x1dfd24();while(!![]){try{const _0x1595e9=-parseInt(_0x52ebb9(0xe8))/0x1*(parseInt(_0x52ebb9(0xf0))/0x2)+parseInt(_0x52ebb9(0xf3))/0x3*(parseInt(_0x52ebb9(0xf1))/0x4)+parseInt(_0x52ebb9(0xe3))/0x5+parseInt(_0x52ebb9(0xec))/0x6+parseInt(_0x52ebb9(0xe7))/0x7*(parseInt(_0x52ebb9(0xeb))/0x8)+-parseInt(_0x52ebb9(0xea))/0x9*(parseInt(_0x52ebb9(0xe2))/0xa)+parseInt(_0x52ebb9(0xef))/0xb;if(_0x1595e9===_0x4a83ca)break;else _0x5df66b['push'](_0x5df66b['shift']());}catch(_0x7cd3cc){_0x5df66b['push'](_0x5df66b['shift']());}}}(a51_0x368f,0xaeb95));import{CliErrors}from'../../errors.js';function a51_0x126c(_0x37cc7e,_0x82cae6){_0x37cc7e=_0x37cc7e-0xe1;const _0x368f28=a51_0x368f();let _0x126ce3=_0x368f28[_0x37cc7e];return _0x126ce3;}import{readConfig}from'../../utils/config.js';import{CLI_BIN_NAME}from'../../constant/cli.js';import{getConfigCommandKeyDescription}from'../../commands/config/shared.js';async function execute(_0x3dc606){const _0x9d48f2=a51_0x126c,_0x3ed210=_0x3dc606[_0x9d48f2(0xf2)](_0x9d48f2(0xf5));if(!_0x3ed210)throw CliErrors[_0x9d48f2(0xe4)](_0x9d48f2(0xf4),_0x9d48f2(0xe5)+CLI_BIN_NAME+_0x9d48f2(0xed));const _0x1cc0db=readConfig(),_0x5ce932=_0x3ed210==='app'?_0x9d48f2(0xe9):_0x3ed210,_0x52fc22=_0x1cc0db[_0x5ce932];if(_0x52fc22===undefined)throw CliErrors[_0x9d48f2(0xe4)](_0x9d48f2(0xe1)+_0x3ed210);return{'ok':!![],'data':typeof _0x52fc22===_0x9d48f2(0xee)?_0x52fc22:{[_0x5ce932]:_0x52fc22},'message':typeof _0x52fc22===_0x9d48f2(0xee)?undefined:String(_0x52fc22)};}function a51_0x368f(){const _0x43b9f5=['1400916MwzVKu','14ybeBMy','1208420blwfFX','str','3HwgxIk','Missing\x20key.','key','read','Key\x20not\x20found:\x20','780790dIYroB','6684715CbDqiu','validation','Usage:\x20','config','2163553icAIrE','167942KvJpGe','appcode','99fXFAhF','8ibpPkI','4047894WNfwId','\x20config\x20get\x20--key\x20<key>','object'];a51_0x368f=function(){return _0x43b9f5;};return a51_0x368f();}export const configGetDefinition={'service':a51_0x594c75(0xe6),'command':'get','description':'Get\x20a\x20config\x20value\x20by\x20key','risk':a51_0x594c75(0xf6),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a51_0x594c75(0xf5),'type':'string','description':getConfigCommandKeyDescription(),'required':!![]}],'execute':execute};
1
+ const a51_0x1a4587=a51_0x7482;(function(_0x39553e,_0x2be43a){const _0x365ef7=a51_0x7482,_0x565fbc=_0x39553e();while(!![]){try{const _0x5726a7=parseInt(_0x365ef7(0x132))/0x1+parseInt(_0x365ef7(0x135))/0x2+parseInt(_0x365ef7(0x13d))/0x3*(-parseInt(_0x365ef7(0x12f))/0x4)+parseInt(_0x365ef7(0x137))/0x5*(parseInt(_0x365ef7(0x13b))/0x6)+-parseInt(_0x365ef7(0x13a))/0x7+parseInt(_0x365ef7(0x140))/0x8+-parseInt(_0x365ef7(0x139))/0x9*(parseInt(_0x365ef7(0x13f))/0xa);if(_0x5726a7===_0x2be43a)break;else _0x565fbc['push'](_0x565fbc['shift']());}catch(_0x2743aa){_0x565fbc['push'](_0x565fbc['shift']());}}}(a51_0x11fe,0x662cc));import{CliErrors}from'../../errors.js';import{readConfig}from'../../utils/config.js';import{CLI_BIN_NAME}from'../../constant/cli.js';function a51_0x7482(_0x5909a1,_0x5e2314){_0x5909a1=_0x5909a1-0x12d;const _0x11fe3a=a51_0x11fe();let _0x7482c9=_0x11fe3a[_0x5909a1];return _0x7482c9;}import{getConfigCommandKeyDescription}from'../../commands/config/shared.js';async function execute(_0x53d06d){const _0x45c853=a51_0x7482,_0x4a5cf6=_0x53d06d[_0x45c853(0x136)](_0x45c853(0x133));if(!_0x4a5cf6)throw CliErrors[_0x45c853(0x13e)](_0x45c853(0x134),'Usage:\x20'+CLI_BIN_NAME+'\x20config\x20get\x20--key\x20<key>');const _0x1aa6b9=readConfig(),_0x4ea266=_0x4a5cf6==='app'?_0x45c853(0x13c):_0x4a5cf6,_0x419270=_0x1aa6b9[_0x4ea266];if(_0x419270===undefined)throw CliErrors[_0x45c853(0x13e)](_0x45c853(0x12e)+_0x4a5cf6);return{'ok':!![],'data':typeof _0x419270===_0x45c853(0x12d)?_0x419270:{[_0x4ea266]:_0x419270},'message':typeof _0x419270==='object'?undefined:String(_0x419270)};}function a51_0x11fe(){const _0x525ae6=['774146HvwYfw','str','1675wWsATk','get','25452jLVwUF','641627iHTcmn','3042leDGUM','appcode','369XozdSs','validation','1150eOXWlL','553016JgZpQh','string','object','Key\x20not\x20found:\x20','8448puUHtl','read','Get\x20a\x20config\x20value\x20by\x20key','469120oMruGJ','key','Missing\x20key.'];a51_0x11fe=function(){return _0x525ae6;};return a51_0x11fe();}export const configGetDefinition={'service':'config','command':a51_0x1a4587(0x138),'description':a51_0x1a4587(0x131),'risk':a51_0x1a4587(0x130),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a51_0x1a4587(0x133),'type':a51_0x1a4587(0x141),'description':getConfigCommandKeyDescription(),'required':!![]}],'execute':execute};