@lovrabet/rabetbase-cli 2.2.4-beta.5 → 2.2.4-beta.6

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 (209) 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/discover.js +1 -1
  21. package/lib/commands/app/index.js +1 -1
  22. package/lib/commands/app/list.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/use.js +1 -1
  26. package/lib/commands/auth/index.js +1 -1
  27. package/lib/commands/bff/create.js +1 -1
  28. package/lib/commands/bff/delete.js +1 -1
  29. package/lib/commands/bff/detail.js +1 -1
  30. package/lib/commands/bff/index.js +1 -1
  31. package/lib/commands/bff/list.js +1 -1
  32. package/lib/commands/bff/pull.js +1 -1
  33. package/lib/commands/bff/push.js +1 -1
  34. package/lib/commands/bff/status.js +1 -1
  35. package/lib/commands/cli-update.js +1 -1
  36. package/lib/commands/codegen/index.js +1 -1
  37. package/lib/commands/codegen/sdk.js +1 -1
  38. package/lib/commands/codegen/sql.js +1 -1
  39. package/lib/commands/common/app-selector.js +1 -1
  40. package/lib/commands/common/flags.js +1 -1
  41. package/lib/commands/common/validate.js +1 -1
  42. package/lib/commands/config/get.js +1 -1
  43. package/lib/commands/config/index.js +1 -1
  44. package/lib/commands/config/list.js +1 -1
  45. package/lib/commands/config/set.js +1 -1
  46. package/lib/commands/config/shared.js +1 -1
  47. package/lib/commands/data/filter.js +1 -1
  48. package/lib/commands/data/getOne.js +1 -1
  49. package/lib/commands/data/index.js +1 -1
  50. package/lib/commands/data/shared.js +1 -1
  51. package/lib/commands/dataset/capability.js +1 -1
  52. package/lib/commands/dataset/delete.js +1 -1
  53. package/lib/commands/dataset/detail.js +1 -1
  54. package/lib/commands/dataset/extend-update.js +1 -1
  55. package/lib/commands/dataset/field-update.js +1 -1
  56. package/lib/commands/dataset/index.js +1 -1
  57. package/lib/commands/dataset/list.js +1 -1
  58. package/lib/commands/dataset/operations.js +1 -1
  59. package/lib/commands/dataset/relation-create.js +1 -1
  60. package/lib/commands/dataset/relation-delete.js +1 -1
  61. package/lib/commands/dataset/relation-shared.js +1 -1
  62. package/lib/commands/dataset/relation-update.js +1 -1
  63. package/lib/commands/dataset/relations.js +1 -1
  64. package/lib/commands/dataset/rename.js +1 -1
  65. package/lib/commands/db/analyze-cancel.js +1 -1
  66. package/lib/commands/db/analyze-start.js +1 -1
  67. package/lib/commands/db/analyze-status.js +1 -1
  68. package/lib/commands/db/create.js +1 -1
  69. package/lib/commands/db/delete.js +1 -1
  70. package/lib/commands/db/detail.js +1 -1
  71. package/lib/commands/db/diff.js +1 -1
  72. package/lib/commands/db/index.js +1 -1
  73. package/lib/commands/db/list.js +1 -1
  74. package/lib/commands/db/shared.js +1 -1
  75. package/lib/commands/db/tables.js +1 -1
  76. package/lib/commands/db/test.js +1 -1
  77. package/lib/commands/db/update.js +1 -1
  78. package/lib/commands/doctor.js +1 -1
  79. package/lib/commands/init/index.js +1 -1
  80. package/lib/commands/issue/index.js +1 -1
  81. package/lib/commands/issue/nudge.js +1 -1
  82. package/lib/commands/issue/report.js +1 -1
  83. package/lib/commands/issue/shared.js +1 -1
  84. package/lib/commands/logs/index.js +1 -1
  85. package/lib/commands/menu/index.js +1 -1
  86. package/lib/commands/menu/list.js +1 -1
  87. package/lib/commands/menu/shared/compare-table.js +1 -1
  88. package/lib/commands/menu/shared/index.js +1 -1
  89. package/lib/commands/menu/shared/inquirer.js +1 -1
  90. package/lib/commands/menu/shared/local-pages.js +1 -1
  91. package/lib/commands/menu/shared/logic.js +1 -1
  92. package/lib/commands/menu/shared/service.js +1 -1
  93. package/lib/commands/menu/shared/sync-core.js +1 -1
  94. package/lib/commands/menu/shared/update-core.js +1 -1
  95. package/lib/commands/menu/shared/valid-url.js +1 -1
  96. package/lib/commands/menu/sync.js +1 -1
  97. package/lib/commands/menu/update.js +1 -1
  98. package/lib/commands/page/generate-start.js +1 -1
  99. package/lib/commands/page/generate-status.js +1 -1
  100. package/lib/commands/page/index.js +1 -1
  101. package/lib/commands/page/pull.js +1 -1
  102. package/lib/commands/page/push.js +1 -1
  103. package/lib/commands/page/relation-audit.js +1 -1
  104. package/lib/commands/page/shared.js +1 -1
  105. package/lib/commands/page/standard-page-status.js +1 -1
  106. package/lib/commands/page/sync.js +1 -1
  107. package/lib/commands/project/create/enhanced-guided-create.js +1 -1
  108. package/lib/commands/project/create/format-elapsed.js +1 -1
  109. package/lib/commands/project/create/main.js +1 -1
  110. package/lib/commands/project/create/non-interactive.js +1 -1
  111. package/lib/commands/project/create/project-template-path.js +1 -1
  112. package/lib/commands/project/create/use-copy-project-template.js +1 -1
  113. package/lib/commands/project/create/use-format-code.js +1 -1
  114. package/lib/commands/project/create/use-install-dependencies.js +1 -1
  115. package/lib/commands/project/index.js +1 -1
  116. package/lib/commands/project/init.js +1 -1
  117. package/lib/commands/project/upgrade.js +1 -1
  118. package/lib/commands/registry.js +1 -1
  119. package/lib/commands/run/index.js +1 -1
  120. package/lib/commands/schema.js +1 -1
  121. package/lib/commands/skill/index.js +1 -1
  122. package/lib/commands/sql/create.js +1 -1
  123. package/lib/commands/sql/delete.js +1 -1
  124. package/lib/commands/sql/detail.js +1 -1
  125. package/lib/commands/sql/exec.js +1 -1
  126. package/lib/commands/sql/index.js +1 -1
  127. package/lib/commands/sql/list.js +1 -1
  128. package/lib/commands/sql/pull.js +1 -1
  129. package/lib/commands/sql/push.js +1 -1
  130. package/lib/commands/sql/save.js +1 -1
  131. package/lib/commands/sql/shared.js +1 -1
  132. package/lib/commands/sql/status.js +1 -1
  133. package/lib/commands/sql/validate.js +1 -1
  134. package/lib/commands/workspace/index.js +1 -0
  135. package/lib/config/schema.js +1 -1
  136. package/lib/constant/cdn.js +1 -1
  137. package/lib/constant/cli.js +1 -1
  138. package/lib/constant/defaults.js +1 -1
  139. package/lib/constant/domain.js +1 -1
  140. package/lib/constant/env.js +1 -1
  141. package/lib/constant/output.js +1 -1
  142. package/lib/constant/paths.js +1 -1
  143. package/lib/constant/risk.js +1 -1
  144. package/lib/context/app-resolver.js +1 -1
  145. package/lib/context/auth-resolver.js +1 -1
  146. package/lib/context/config-loader.js +1 -1
  147. package/lib/context.js +1 -1
  148. package/lib/core/alias-resolver.js +1 -1
  149. package/lib/core/api-client.js +1 -1
  150. package/lib/core/bff/config.js +1 -1
  151. package/lib/core/bff/file-system.js +1 -1
  152. package/lib/core/bff/hash.js +1 -1
  153. package/lib/core/bff/lock.js +1 -1
  154. package/lib/core/bff/utils.js +1 -1
  155. package/lib/core/db-resolver.js +1 -1
  156. package/lib/core/page/file-system.js +1 -1
  157. package/lib/core/page/hash.js +1 -1
  158. package/lib/core/page/lock.js +1 -1
  159. package/lib/core/sql-sync/config.js +1 -1
  160. package/lib/core/sql-sync/file-system.js +1 -1
  161. package/lib/core/sql-sync/hash.js +1 -1
  162. package/lib/core/sql-sync/lock.js +1 -1
  163. package/lib/core/sql-sync/utils.js +1 -1
  164. package/lib/core/sql-validator.js +1 -1
  165. package/lib/errors.js +1 -1
  166. package/lib/framework/build-all-flags.js +1 -1
  167. package/lib/framework/flags.js +1 -1
  168. package/lib/framework/help.js +1 -1
  169. package/lib/framework/index.js +1 -1
  170. package/lib/framework/output.js +1 -1
  171. package/lib/framework/response.js +1 -1
  172. package/lib/framework/runner-alias.js +1 -1
  173. package/lib/framework/runner.js +1 -1
  174. package/lib/framework/schema-export.js +1 -1
  175. package/lib/framework/types.js +1 -1
  176. package/lib/generated/build-info.js +1 -1
  177. package/lib/help.js +1 -1
  178. package/lib/skills/main.js +1 -1
  179. package/lib/skills/npx-skills-add.js +1 -1
  180. package/lib/telemetry/cli-command-trace.js +1 -1
  181. package/lib/telemetry/cli-help-trace.js +1 -1
  182. package/lib/telemetry/ensure-cli-otel-config.js +1 -1
  183. package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
  184. package/lib/telemetry/send-cli-trace-log.js +1 -1
  185. package/lib/telemetry/send-platform-issue-collect-log.js +1 -1
  186. package/lib/utils/ai_config.js +1 -1
  187. package/lib/utils/apply-jq-filter.js +1 -1
  188. package/lib/utils/cdn-config.js +1 -1
  189. package/lib/utils/check-sdk-version.js +1 -1
  190. package/lib/utils/cli-version-check.js +1 -1
  191. package/lib/utils/cli-version-policy.js +1 -1
  192. package/lib/utils/config.js +1 -1
  193. package/lib/utils/copy-directory.js +1 -1
  194. package/lib/utils/entity-with-id.js +1 -1
  195. package/lib/utils/file-utils.js +1 -1
  196. package/lib/utils/guides-cdn.js +1 -1
  197. package/lib/utils/http-client.js +1 -1
  198. package/lib/utils/is-non-interactive.js +1 -1
  199. package/lib/utils/logger.js +1 -1
  200. package/lib/utils/params.js +1 -1
  201. package/lib/utils/platform.js +1 -1
  202. package/lib/utils/rules-cdn.js +1 -1
  203. package/lib/utils/sleep.js +1 -1
  204. package/lib/utils/template-replacer.js +1 -1
  205. package/lib/utils/update-notice.js +1 -1
  206. package/lib/utils/version.js +1 -1
  207. package/lib/utils/with-active-cookie.js +1 -1
  208. package/lib/utils/write-cli-side-channel.js +1 -1
  209. package/package.json +1 -1
@@ -1 +1 @@
1
- const a32_0x3ba512=a32_0x2999;(function(_0x130d72,_0x55d3a5){const _0x546cb7=a32_0x2999,_0x1de5b4=_0x130d72();while(!![]){try{const _0x3fe643=parseInt(_0x546cb7(0x1b3))/0x1*(-parseInt(_0x546cb7(0x1b4))/0x2)+parseInt(_0x546cb7(0x1a8))/0x3+parseInt(_0x546cb7(0x1c4))/0x4+parseInt(_0x546cb7(0x1c0))/0x5*(-parseInt(_0x546cb7(0x1c5))/0x6)+-parseInt(_0x546cb7(0x188))/0x7*(-parseInt(_0x546cb7(0x192))/0x8)+parseInt(_0x546cb7(0x1af))/0x9+-parseInt(_0x546cb7(0x1ae))/0xa*(-parseInt(_0x546cb7(0x197))/0xb);if(_0x3fe643===_0x55d3a5)break;else _0x1de5b4['push'](_0x1de5b4['shift']());}catch(_0x250b70){_0x1de5b4['push'](_0x1de5b4['shift']());}}}(a32_0x4681,0xa979e));import{readFile}from'node:fs/promises';import{saveBffScript,getBffScriptInfo,listDatasets,clearBffScriptCache}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{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';function a32_0x4681(){const _0x3e9e8d=['lockKey','map','script',':\x20missing\x20remote\x20version.\x20Run\x20`push`\x20after\x20`pull`\x20to\x20sync\x20version\x20info.','functionNode','filePath','create','Lock\x20scope\x20for\x20app\x20\x22','679AIBFbV','Incomplete\x20HOOK\x20path:\x20','runtime\x20cache\x20not\x20needed','string','scriptsRoot','unchanged','bool','name','aliasToDatasetCode','Lock\x20file\x20not\x20settled\x20after\x20push\x20for\x20','47704thErhk','utf8','apiDir','high-risk-write','apps','11VBgIOd','appCode','\x20failed,\x20','Run\x20`','push','alias','attempted','datasetCode','toISOString','operationType','--name\x20requires\x20--type\x20to\x20identify\x20the\x20function.','description','\x22.\x20','remoteId','/api/management/library/scripts/save','Push\x20only\x20this\x20script\x20type','validation','983253ROiJra','Push\x20only\x20the\x20named\x20function\x20(requires\x20--type)','lockFilePath','\x22\x20not\x20found\x20after\x20ensureLockScope.','type','update','7357490eDFZbb','1595151RxuJBY','length','parse','functions','1350345usWFqs','2sgeYeO','ENDPOINT','Push\x20local\x20BFF\x20scripts\x20to\x20remote','would_push','has','\x20local\x20BFF\x20script(s)\x20for\x20push\x20and\x20clear\x20runtime\x20cache\x20if\x20files\x20are\x20uploaded','\x20skipped,\x20','force','version','join','HOOK','cleared','7945iMoCST','message','COMMON','boolean','4289224BvTSYA','3198QGFuSK','Would\x20inspect\x20','Cannot\x20resolve\x20dataset\x20for\x20\x22','hash','get'];a32_0x4681=function(){return _0x3e9e8d;};return a32_0x4681();}import{sleep}from'../../utils/sleep.js';function a32_0x2999(_0x3a0271,_0x590f81){_0x3a0271=_0x3a0271-0x188;const _0x4681fd=a32_0x4681();let _0x299946=_0x4681fd[_0x3a0271];return _0x299946;}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':'bff','command':a32_0x3ba512(0x19b),'description':a32_0x3ba512(0x1b6),'risk':a32_0x3ba512(0x195),'flags':[{'name':a32_0x3ba512(0x1ac),'type':a32_0x3ba512(0x18b),'description':a32_0x3ba512(0x1a6),'enum':[a32_0x3ba512(0x1c2),a32_0x3ba512(0x1b5),a32_0x3ba512(0x1be)]},{'name':a32_0x3ba512(0x18f),'type':'string','description':a32_0x3ba512(0x1a9)},{'name':'force','type':a32_0x3ba512(0x1c3),'description':'Force\x20push\x20ignoring\x20hash\x20protection'}],async 'dryRun'(_0x7a77a4){const _0x20640d=a32_0x3ba512,_0x57041a=loadBffProjectConfig(_0x7a77a4['appCode']),_0x1ff4e5=await readBffLockFile(_0x57041a[_0x20640d(0x1aa)]),{appLock:_0x45d048}=ensureLockScope(_0x1ff4e5??createEmptyBffLock(),_0x7a77a4['appCode'],_0x57041a[_0x20640d(0x18c)],_0x20640d(0x19b)),_0x3621d4=await getTargetFunctions(_0x57041a,_0x7a77a4),_0x5c2a1f=_0x7a77a4['bool'](_0x20640d(0x1bb)),_0x3a5c67=[];for(const _0x12691c of _0x3621d4){const _0x2108de=await computeFileHash(_0x12691c[_0x20640d(0x1cf)]),_0xe300c3=_0x45d048['functions'][_0x12691c[_0x20640d(0x1ca)]],_0x308ddb=!!_0xe300c3&&_0xe300c3['hash']===_0x2108de;_0x3a5c67[_0x20640d(0x19b)]({'lockKey':_0x12691c[_0x20640d(0x1ca)],'filePath':_0x12691c[_0x20640d(0x1cf)],'remoteId':_0xe300c3?.[_0x20640d(0x1a4)]??null,'mode':_0xe300c3?.['remoteId']?_0x20640d(0x1ad):_0x20640d(0x1d0),'status':!_0x5c2a1f&&_0x308ddb?_0x20640d(0x18d):_0x20640d(0x1b7)});}return{'method':'POST','url':_0x20640d(0x1a5),'body':{'appCode':_0x7a77a4['appCode'],'force':_0x5c2a1f,'files':_0x3a5c67,'cacheClearAtRuntime':_0x3a5c67['some'](_0x4ff4e8=>_0x4ff4e8['status']===_0x20640d(0x1b7)),'cacheClearAtRuntimeTimes':_0x3a5c67['some'](_0x4e9640=>_0x4e9640['status']===_0x20640d(0x1b7))?CACHE_CLEAR_ATTEMPTS:0x0},'description':_0x20640d(0x1c6)+_0x3a5c67['length']+_0x20640d(0x1b9)};},async 'execute'(_0x29c4b2){const _0x32e218=a32_0x3ba512,_0x10e8c7=loadBffProjectConfig(_0x29c4b2[_0x32e218(0x198)]),_0x29594d=await readBffLockFile(_0x10e8c7[_0x32e218(0x1aa)]),{lockData:_0x14af01,appLock:_0x26bdcb}=ensureLockScope(_0x29594d??createEmptyBffLock(),_0x29c4b2['appCode'],_0x10e8c7[_0x32e218(0x18c)],'push'),_0x2e8411=await getTargetFunctions(_0x10e8c7,_0x29c4b2);if(_0x2e8411[_0x32e218(0x1b0)]===0x0)return{'ok':!![],'data':{'uploaded':[],'skipped':[],'failed':[]},'message':'No\x20local\x20BFF\x20functions\x20found.'};const _0x4d710e=_0x29c4b2[_0x32e218(0x18e)](_0x32e218(0x1bb)),_0x2d33e9=JSON[_0x32e218(0x1b1)](JSON['stringify'](_0x14af01)),_0xd7565e=_0x2d33e9[_0x32e218(0x196)][_0x29c4b2['appCode']];if(!_0xd7565e)throw new Error(_0x32e218(0x1d1)+_0x29c4b2[_0x32e218(0x198)]+_0x32e218(0x1ab));const _0x2dad0a=await buildHookMaps(_0x29c4b2[_0x32e218(0x198)],_0x29c4b2[_0x32e218(0x194)],_0x2e8411,_0xd7565e),_0x3decd5=[],_0x33e1d0=[],_0x223a44=[];for(const _0xf571ac of _0x2e8411){const _0x39db94=await computeFileHash(_0xf571ac[_0x32e218(0x1cf)]),_0x189186=_0xd7565e['functions'][_0xf571ac[_0x32e218(0x1ca)]];if(!_0x4d710e&&_0x189186&&_0x189186[_0x32e218(0x1c8)]===_0x39db94){_0x33e1d0[_0x32e218(0x19b)]({'lockKey':_0xf571ac[_0x32e218(0x1ca)],'reason':_0x32e218(0x18d)});continue;}try{await uploadSingleFunction(_0x29c4b2[_0x32e218(0x198)],_0xf571ac,_0xd7565e,_0x2dad0a);const _0x3ae227=_0xd7565e[_0x32e218(0x1b2)][_0xf571ac[_0x32e218(0x1ca)]];_0x3decd5[_0x32e218(0x19b)]({'lockKey':_0xf571ac[_0x32e218(0x1ca)],'remoteId':_0x3ae227?.['remoteId']??0x0});}catch(_0x413c38){_0x223a44['push']({'lockKey':_0xf571ac[_0x32e218(0x1ca)],'error':_0x413c38 instanceof Error?_0x413c38[_0x32e218(0x1c1)]:String(_0x413c38)});}}_0xd7565e['lastSync']=new Date()[_0x32e218(0x19f)](),await writeBffLockFile(_0x10e8c7[_0x32e218(0x1aa)],_0x2d33e9),await waitForUploadedLockEntries(_0x10e8c7['lockFilePath'],_0x29c4b2[_0x32e218(0x198)],_0x3decd5['map'](_0x76230=>_0x76230[_0x32e218(0x1ca)]));let _0x5901e0={'attempted':![],'cleared':![]};if(_0x3decd5[_0x32e218(0x1b0)]>0x0)try{let _0x612dc9='';for(let _0xb20680=0x0;_0xb20680<CACHE_CLEAR_ATTEMPTS;_0xb20680+=0x1){_0x612dc9=await clearBffScriptCache(),_0xb20680<CACHE_CLEAR_ATTEMPTS-0x1&&await sleep(CACHE_CLEAR_INTERVAL_MS);}_0x5901e0={'attempted':!![],'cleared':!![],'message':_0x612dc9||'Runtime\x20script\x20cache\x20cleared.'};}catch(_0x116356){_0x5901e0={'attempted':!![],'cleared':![],'error':_0x116356 instanceof Error?_0x116356[_0x32e218(0x1c1)]:String(_0x116356)};}const _0xe177cb=_0x223a44[_0x32e218(0x1b0)]===0x0&&(_0x5901e0['attempted']?_0x5901e0[_0x32e218(0x1bf)]:!![]),_0x42e819=_0x5901e0[_0x32e218(0x19d)]?_0x5901e0[_0x32e218(0x1bf)]?'runtime\x20cache\x20cleared':'runtime\x20cache\x20clear\x20failed':_0x32e218(0x18a);return{'ok':_0xe177cb,'data':{'uploaded':_0x3decd5,'skipped':_0x33e1d0,'failed':_0x223a44,'cacheClear':_0x5901e0},'message':'Push\x20complete:\x20'+_0x3decd5['length']+'\x20uploaded,\x20'+_0x33e1d0['length']+_0x32e218(0x1ba)+_0x223a44[_0x32e218(0x1b0)]+_0x32e218(0x199)+_0x42e819};}};async function getTargetFunctions(_0x28140f,_0x24fac4){const _0x1fc527=a32_0x3ba512,_0x5a58d2=_0x24fac4['str'](_0x1fc527(0x1ac)),_0x385662=_0x24fac4['str'](_0x1fc527(0x18f)),_0x4d834d=normalizeBffType(_0x5a58d2)??undefined;if(_0x385662&&!_0x4d834d)throw CliErrors[_0x1fc527(0x1a7)](_0x1fc527(0x1a1));const _0x5e82c0=await scanLocalBffFunctions(_0x28140f,_0x4d834d);if(_0x385662){const _0x39f9f2=_0x5e82c0['filter'](_0x552360=>_0x552360[_0x1fc527(0x18f)]===_0x385662);if(_0x39f9f2[_0x1fc527(0x1b0)]===0x0)throw CliErrors['validation']('Local\x20function\x20not\x20found:\x20'+_0x4d834d+'/'+_0x385662);return _0x39f9f2;}return _0x5e82c0;}async function buildHookMaps(_0xfdb8d5,_0x284603,_0x409be0,_0x3ad298){const _0x4918ab=a32_0x3ba512,_0x5030b0=_0x409be0['some'](_0x6a2dc2=>_0x6a2dc2['type']==='HOOK');if(!_0x5030b0)return{'aliasToDatasetCode':new Map(),'datasetCodeToDataset':new Map()};const _0x2543fa=loadAliasMap(_0x284603,undefined,resolveApiFilePath(_0x284603,_0xfdb8d5)),_0x19a7cf=new Map(_0x2543fa[_0x4918ab(0x1cb)](_0xdf7e49=>[_0xdf7e49[_0x4918ab(0x19c)],_0xdf7e49[_0x4918ab(0x19e)]]));for(const _0xfeae81 of Object['values'](_0x3ad298[_0x4918ab(0x1b2)])){_0xfeae81[_0x4918ab(0x19c)]&&_0xfeae81[_0x4918ab(0x19e)]&&!_0x19a7cf['has'](_0xfeae81['alias'])&&_0x19a7cf['set'](_0xfeae81[_0x4918ab(0x19c)],_0xfeae81['datasetCode']);}const _0x1f93f4=await listDatasets(_0xfdb8d5),_0x34c194=new Map(_0x1f93f4[_0x4918ab(0x1cb)](_0x5345f5=>[_0x5345f5['code'],_0x5345f5]));return{'aliasToDatasetCode':_0x19a7cf,'datasetCodeToDataset':_0x34c194};}async function uploadSingleFunction(_0xd1c74,_0x416f18,_0x12d8a6,_0x3ba537){const _0x28b8d0=a32_0x3ba512,_0x4af12f=await readFile(_0x416f18[_0x28b8d0(0x1cf)],_0x28b8d0(0x193)),_0x110976=await computeFileHash(_0x416f18['filePath']),_0x44684e=_0x12d8a6[_0x28b8d0(0x1b2)][_0x416f18[_0x28b8d0(0x1ca)]];if(_0x44684e?.[_0x28b8d0(0x1a4)]&&_0x44684e[_0x28b8d0(0x1bc)]==null)throw CliErrors[_0x28b8d0(0x1a7)](_0x416f18[_0x28b8d0(0x1ca)]+_0x28b8d0(0x1cd));let _0x26eda2=extractScriptDescription(_0x4af12f);if(!_0x26eda2&&_0x44684e?.['remoteId']){const _0x245c79=await getBffScriptInfo(_0x44684e['remoteId']);_0x26eda2=_0x245c79['description']||undefined;}const _0x43c679={'appCode':_0xd1c74,'functionName':_0x416f18[_0x28b8d0(0x18f)],'scriptType':_0x416f18[_0x28b8d0(0x1ac)],'scriptContent':_0x4af12f};if(_0x44684e?.[_0x28b8d0(0x1a4)])_0x43c679['id']=_0x44684e[_0x28b8d0(0x1a4)];if(_0x44684e?.[_0x28b8d0(0x1bc)]!=null)_0x43c679[_0x28b8d0(0x1bc)]=_0x44684e[_0x28b8d0(0x1bc)];if(_0x26eda2)_0x43c679[_0x28b8d0(0x1a2)]=_0x26eda2;if(_0x416f18['type']===_0x28b8d0(0x1be)){const _0x3d987c=_0x416f18[_0x28b8d0(0x19c)];if(!_0x3d987c||!_0x416f18[_0x28b8d0(0x1a0)]||!_0x416f18['functionNode'])throw CliErrors[_0x28b8d0(0x1a7)](_0x28b8d0(0x189)+_0x416f18[_0x28b8d0(0x1ca)]);const _0x26af14=_0x3ba537[_0x28b8d0(0x190)][_0x28b8d0(0x1c9)](_0x3d987c)??_0x44684e?.[_0x28b8d0(0x19e)]??_0x3d987c,_0xfc5f80=_0x3ba537['datasetCodeToDataset']['get'](_0x26af14);if(!_0xfc5f80)throw CliErrors[_0x28b8d0(0x1a7)](_0x28b8d0(0x1c7)+_0x3d987c+_0x28b8d0(0x1a3)+(_0x28b8d0(0x19a)+CLI_BIN_NAME+'\x20api\x20pull`\x20to\x20refresh\x20api.ts,\x20or\x20verify\x20the\x20dataset\x20exists.'));_0x43c679['datasetId']=_0xfc5f80['id'],_0x43c679['operationType']=_0x416f18[_0x28b8d0(0x1a0)],_0x43c679[_0x28b8d0(0x1ce)]=_0x416f18[_0x28b8d0(0x1ce)];}const _0x2629cf=await saveBffScript(_0x43c679),_0x148496=_0x2629cf['id'],_0x484180=_0x2629cf[_0x28b8d0(0x1cc)]??await getBffScriptInfo(_0x148496),_0x18b284={'hash':_0x110976,'remoteId':_0x148496,'version':_0x484180['version']};if(_0x416f18[_0x28b8d0(0x1ac)]===_0x28b8d0(0x1be)){const _0x565407=_0x416f18['alias'],_0x21c62f=_0x3ba537[_0x28b8d0(0x190)][_0x28b8d0(0x1c9)](_0x565407)??_0x44684e?.[_0x28b8d0(0x19e)]??_0x565407;_0x3ba537['aliasToDatasetCode'][_0x28b8d0(0x1b8)](_0x565407)?_0x18b284[_0x28b8d0(0x19c)]=_0x565407:_0x18b284['alias']=_0x44684e?.['alias'],_0x18b284[_0x28b8d0(0x19e)]=_0x21c62f,_0x18b284[_0x28b8d0(0x1a0)]=_0x416f18[_0x28b8d0(0x1a0)],_0x18b284[_0x28b8d0(0x1ce)]=_0x416f18[_0x28b8d0(0x1ce)];}_0x12d8a6[_0x28b8d0(0x1b2)][_0x416f18['lockKey']]=_0x18b284;}const LOCK_SETTLE_RETRY_COUNT=0x14,LOCK_SETTLE_DELAY_MS=0x64;async function waitForUploadedLockEntries(_0x33ac86,_0x5008e2,_0x562bfb){const _0x36d957=a32_0x3ba512;if(_0x562bfb[_0x36d957(0x1b0)]===0x0)return;for(let _0x43e4ca=0x0;_0x43e4ca<LOCK_SETTLE_RETRY_COUNT;_0x43e4ca+=0x1){const _0x3f4517=await readBffLockFile(_0x33ac86),_0x599170=_0x3f4517?.['apps']?.[_0x5008e2]?.[_0x36d957(0x1b2)]??{},_0x1d7472=_0x562bfb['every'](_0x4a9291=>!!_0x599170[_0x4a9291]?.['remoteId']);if(_0x1d7472)return;await sleep(LOCK_SETTLE_DELAY_MS);}throw new Error(_0x36d957(0x191)+_0x562bfb[_0x36d957(0x1bd)](',\x20')+'.');}
1
+ const a32_0xd8d93c=a32_0x32fa;(function(_0x1abe7c,_0x3a15fe){const _0x205f1e=a32_0x32fa,_0xe356a4=_0x1abe7c();while(!![]){try{const _0x3695ae=parseInt(_0x205f1e(0xcb))/0x1*(-parseInt(_0x205f1e(0xa6))/0x2)+-parseInt(_0x205f1e(0xc3))/0x3*(parseInt(_0x205f1e(0xba))/0x4)+parseInt(_0x205f1e(0xc5))/0x5+parseInt(_0x205f1e(0xce))/0x6*(parseInt(_0x205f1e(0xd8))/0x7)+parseInt(_0x205f1e(0xbb))/0x8*(parseInt(_0x205f1e(0xb7))/0x9)+-parseInt(_0x205f1e(0xcc))/0xa+parseInt(_0x205f1e(0xab))/0xb;if(_0x3695ae===_0x3a15fe)break;else _0xe356a4['push'](_0xe356a4['shift']());}catch(_0x4d0bd1){_0xe356a4['push'](_0xe356a4['shift']());}}}(a32_0x7386,0x694ef));import{readFile}from'node:fs/promises';import{saveBffScript,getBffScriptInfo,listDatasets,clearBffScriptCache}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{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';function a32_0x32fa(_0x5a1b1f,_0x4e0c9a){_0x5a1b1f=_0x5a1b1f-0x94;const _0x7386a4=a32_0x7386();let _0x32fa3f=_0x7386a4[_0x5a1b1f];return _0x32fa3f;}import{sleep}from'../../utils/sleep.js';import{CliErrors}from'../../errors.js';import{CLI_BIN_NAME}from'../../constant/cli.js';function a32_0x7386(){const _0xa7188f=['5jzDslR','1343220huLHPd','boolean','5028besjDN','\x22\x20not\x20found\x20after\x20ensureLockScope.','cleared','Push\x20local\x20BFF\x20scripts\x20to\x20remote','type','force','validation','/api/management/library/scripts/save','would_push','version','350iNCirS','parse','unchanged','length','map','appCode','\x20failed,\x20','\x20local\x20BFF\x20script(s)\x20for\x20push\x20and\x20clear\x20runtime\x20cache\x20if\x20files\x20are\x20uploaded','No\x20local\x20BFF\x20functions\x20found.','attempted','lockFilePath','scriptsRoot','runtime\x20cache\x20clear\x20failed','filter','apps','message','datasetId','bff','join','values','stringify','toISOString','create','functions','Run\x20`','Runtime\x20script\x20cache\x20cleared.','--name\x20requires\x20--type\x20to\x20identify\x20the\x20function.','bool','HOOK',':\x20missing\x20remote\x20version.\x20Run\x20`push`\x20after\x20`pull`\x20to\x20sync\x20version\x20info.','datasetCode','set','41750yXOLDz','Force\x20push\x20ignoring\x20hash\x20protection','Push\x20only\x20the\x20named\x20function\x20(requires\x20--type)','string','update','5926668ZkEhuI','runtime\x20cache\x20cleared','lockKey','description','aliasToDatasetCode','name','ENDPOINT','str','remoteId','push','high-risk-write','datasetCodeToDataset','2760309zodDnI','get','filePath','91652rJnPES','8PARQev','operationType','functionNode','\x22.\x20','some','Incomplete\x20HOOK\x20path:\x20','Push\x20complete:\x20','hash','81gcLClR','has','2006510lukXIz','Push\x20only\x20this\x20script\x20type','alias','Local\x20function\x20not\x20found:\x20','Would\x20inspect\x20','Lock\x20scope\x20for\x20app\x20\x22'];a32_0x7386=function(){return _0xa7188f;};return a32_0x7386();}const CACHE_CLEAR_ATTEMPTS=0x2,CACHE_CLEAR_INTERVAL_MS=0x12c;export const bffPush={'service':a32_0xd8d93c(0x97),'command':'push','description':a32_0xd8d93c(0xd1),'risk':a32_0xd8d93c(0xb5),'flags':[{'name':a32_0xd8d93c(0xd2),'type':a32_0xd8d93c(0xa9),'description':a32_0xd8d93c(0xc6),'enum':['COMMON',a32_0xd8d93c(0xb1),a32_0xd8d93c(0xa2)]},{'name':a32_0xd8d93c(0xb0),'type':a32_0xd8d93c(0xa9),'description':a32_0xd8d93c(0xa8)},{'name':'force','type':a32_0xd8d93c(0xcd),'description':a32_0xd8d93c(0xa7)}],async 'dryRun'(_0x1a110d){const _0xfb3e13=a32_0xd8d93c,_0x790282=loadBffProjectConfig(_0x1a110d['appCode']),_0x2d5038=await readBffLockFile(_0x790282[_0xfb3e13(0xe2)]),{appLock:_0x3c3739}=ensureLockScope(_0x2d5038??createEmptyBffLock(),_0x1a110d['appCode'],_0x790282[_0xfb3e13(0xe3)],_0xfb3e13(0xb4)),_0x25da18=await getTargetFunctions(_0x790282,_0x1a110d),_0x4ff2ec=_0x1a110d[_0xfb3e13(0xa1)](_0xfb3e13(0xd3)),_0x313424=[];for(const _0x3d56bb of _0x25da18){const _0x177548=await computeFileHash(_0x3d56bb[_0xfb3e13(0xb9)]),_0x2726c2=_0x3c3739[_0xfb3e13(0x9d)][_0x3d56bb[_0xfb3e13(0xad)]],_0xc8ef87=!!_0x2726c2&&_0x2726c2[_0xfb3e13(0xc2)]===_0x177548;_0x313424[_0xfb3e13(0xb4)]({'lockKey':_0x3d56bb[_0xfb3e13(0xad)],'filePath':_0x3d56bb['filePath'],'remoteId':_0x2726c2?.['remoteId']??null,'mode':_0x2726c2?.[_0xfb3e13(0xb3)]?_0xfb3e13(0xaa):_0xfb3e13(0x9c),'status':!_0x4ff2ec&&_0xc8ef87?'unchanged':_0xfb3e13(0xd6)});}return{'method':'POST','url':_0xfb3e13(0xd5),'body':{'appCode':_0x1a110d[_0xfb3e13(0xdd)],'force':_0x4ff2ec,'files':_0x313424,'cacheClearAtRuntime':_0x313424[_0xfb3e13(0xbf)](_0x2f7256=>_0x2f7256['status']===_0xfb3e13(0xd6)),'cacheClearAtRuntimeTimes':_0x313424[_0xfb3e13(0xbf)](_0x2caa83=>_0x2caa83['status']===_0xfb3e13(0xd6))?CACHE_CLEAR_ATTEMPTS:0x0},'description':_0xfb3e13(0xc9)+_0x313424['length']+_0xfb3e13(0xdf)};},async 'execute'(_0x2bb20e){const _0x2fb60b=a32_0xd8d93c,_0x91cbb5=loadBffProjectConfig(_0x2bb20e[_0x2fb60b(0xdd)]),_0x5bf4d8=await readBffLockFile(_0x91cbb5['lockFilePath']),{lockData:_0x519644,appLock:_0x62aa07}=ensureLockScope(_0x5bf4d8??createEmptyBffLock(),_0x2bb20e['appCode'],_0x91cbb5[_0x2fb60b(0xe3)],_0x2fb60b(0xb4)),_0x383afa=await getTargetFunctions(_0x91cbb5,_0x2bb20e);if(_0x383afa[_0x2fb60b(0xdb)]===0x0)return{'ok':!![],'data':{'uploaded':[],'skipped':[],'failed':[]},'message':_0x2fb60b(0xe0)};const _0xa2fa05=_0x2bb20e[_0x2fb60b(0xa1)](_0x2fb60b(0xd3)),_0x46c034=JSON[_0x2fb60b(0xd9)](JSON[_0x2fb60b(0x9a)](_0x519644)),_0x131ef2=_0x46c034[_0x2fb60b(0x94)][_0x2bb20e[_0x2fb60b(0xdd)]];if(!_0x131ef2)throw new Error(_0x2fb60b(0xca)+_0x2bb20e[_0x2fb60b(0xdd)]+_0x2fb60b(0xcf));const _0x107110=await buildHookMaps(_0x2bb20e[_0x2fb60b(0xdd)],_0x2bb20e['apiDir'],_0x383afa,_0x131ef2),_0x1eb70d=[],_0x329fd1=[],_0x571914=[];for(const _0x1cb24c of _0x383afa){const _0x1fb4de=await computeFileHash(_0x1cb24c[_0x2fb60b(0xb9)]),_0x1531c5=_0x131ef2[_0x2fb60b(0x9d)][_0x1cb24c[_0x2fb60b(0xad)]];if(!_0xa2fa05&&_0x1531c5&&_0x1531c5[_0x2fb60b(0xc2)]===_0x1fb4de){_0x329fd1[_0x2fb60b(0xb4)]({'lockKey':_0x1cb24c['lockKey'],'reason':_0x2fb60b(0xda)});continue;}try{await uploadSingleFunction(_0x2bb20e['appCode'],_0x1cb24c,_0x131ef2,_0x107110);const _0x1be9df=_0x131ef2[_0x2fb60b(0x9d)][_0x1cb24c[_0x2fb60b(0xad)]];_0x1eb70d['push']({'lockKey':_0x1cb24c[_0x2fb60b(0xad)],'remoteId':_0x1be9df?.[_0x2fb60b(0xb3)]??0x0});}catch(_0x48393b){_0x571914[_0x2fb60b(0xb4)]({'lockKey':_0x1cb24c[_0x2fb60b(0xad)],'error':_0x48393b instanceof Error?_0x48393b[_0x2fb60b(0x95)]:String(_0x48393b)});}}_0x131ef2['lastSync']=new Date()[_0x2fb60b(0x9b)](),await writeBffLockFile(_0x91cbb5['lockFilePath'],_0x46c034),await waitForUploadedLockEntries(_0x91cbb5['lockFilePath'],_0x2bb20e['appCode'],_0x1eb70d[_0x2fb60b(0xdc)](_0x19de60=>_0x19de60[_0x2fb60b(0xad)]));let _0x33b261={'attempted':![],'cleared':![]};if(_0x1eb70d[_0x2fb60b(0xdb)]>0x0)try{let _0x25441c='';for(let _0x593dc3=0x0;_0x593dc3<CACHE_CLEAR_ATTEMPTS;_0x593dc3+=0x1){_0x25441c=await clearBffScriptCache(),_0x593dc3<CACHE_CLEAR_ATTEMPTS-0x1&&await sleep(CACHE_CLEAR_INTERVAL_MS);}_0x33b261={'attempted':!![],'cleared':!![],'message':_0x25441c||_0x2fb60b(0x9f)};}catch(_0x547460){_0x33b261={'attempted':!![],'cleared':![],'error':_0x547460 instanceof Error?_0x547460[_0x2fb60b(0x95)]:String(_0x547460)};}const _0x196ef2=_0x571914[_0x2fb60b(0xdb)]===0x0&&(_0x33b261[_0x2fb60b(0xe1)]?_0x33b261['cleared']:!![]),_0x15dd00=_0x33b261[_0x2fb60b(0xe1)]?_0x33b261[_0x2fb60b(0xd0)]?_0x2fb60b(0xac):_0x2fb60b(0xe4):'runtime\x20cache\x20not\x20needed';return{'ok':_0x196ef2,'data':{'uploaded':_0x1eb70d,'skipped':_0x329fd1,'failed':_0x571914,'cacheClear':_0x33b261},'message':_0x2fb60b(0xc1)+_0x1eb70d[_0x2fb60b(0xdb)]+'\x20uploaded,\x20'+_0x329fd1[_0x2fb60b(0xdb)]+'\x20skipped,\x20'+_0x571914[_0x2fb60b(0xdb)]+_0x2fb60b(0xde)+_0x15dd00};}};async function getTargetFunctions(_0xec46e8,_0x3040f9){const _0x2dfb10=a32_0xd8d93c,_0x360c96=_0x3040f9[_0x2dfb10(0xb2)](_0x2dfb10(0xd2)),_0x5f4640=_0x3040f9[_0x2dfb10(0xb2)](_0x2dfb10(0xb0)),_0x1569fc=normalizeBffType(_0x360c96)??undefined;if(_0x5f4640&&!_0x1569fc)throw CliErrors[_0x2dfb10(0xd4)](_0x2dfb10(0xa0));const _0x58f785=await scanLocalBffFunctions(_0xec46e8,_0x1569fc);if(_0x5f4640){const _0x5e8963=_0x58f785[_0x2dfb10(0xe5)](_0x5db53f=>_0x5db53f[_0x2dfb10(0xb0)]===_0x5f4640);if(_0x5e8963[_0x2dfb10(0xdb)]===0x0)throw CliErrors[_0x2dfb10(0xd4)](_0x2dfb10(0xc8)+_0x1569fc+'/'+_0x5f4640);return _0x5e8963;}return _0x58f785;}async function buildHookMaps(_0x5a639f,_0x5c6497,_0x3fee01,_0x465f13){const _0x2a8002=a32_0xd8d93c,_0x3cceeb=_0x3fee01[_0x2a8002(0xbf)](_0x287c14=>_0x287c14[_0x2a8002(0xd2)]===_0x2a8002(0xa2));if(!_0x3cceeb)return{'aliasToDatasetCode':new Map(),'datasetCodeToDataset':new Map()};const _0x5c41c2=loadAliasMap(_0x5c6497,undefined,resolveApiFilePath(_0x5c6497,_0x5a639f)),_0x3b8300=new Map(_0x5c41c2[_0x2a8002(0xdc)](_0x3ee022=>[_0x3ee022[_0x2a8002(0xc7)],_0x3ee022['datasetCode']]));for(const _0x5d7833 of Object[_0x2a8002(0x99)](_0x465f13[_0x2a8002(0x9d)])){_0x5d7833[_0x2a8002(0xc7)]&&_0x5d7833['datasetCode']&&!_0x3b8300[_0x2a8002(0xc4)](_0x5d7833[_0x2a8002(0xc7)])&&_0x3b8300[_0x2a8002(0xa5)](_0x5d7833[_0x2a8002(0xc7)],_0x5d7833[_0x2a8002(0xa4)]);}const _0xd09225=await listDatasets(_0x5a639f),_0x41ba17=new Map(_0xd09225[_0x2a8002(0xdc)](_0x232ebf=>[_0x232ebf['code'],_0x232ebf]));return{'aliasToDatasetCode':_0x3b8300,'datasetCodeToDataset':_0x41ba17};}async function uploadSingleFunction(_0x555c8a,_0x4fe21d,_0x3a869a,_0x2737ad){const _0x775d69=a32_0xd8d93c,_0x4b3377=await readFile(_0x4fe21d[_0x775d69(0xb9)],'utf8'),_0x4c25ea=await computeFileHash(_0x4fe21d[_0x775d69(0xb9)]),_0x1c998a=_0x3a869a[_0x775d69(0x9d)][_0x4fe21d[_0x775d69(0xad)]];if(_0x1c998a?.[_0x775d69(0xb3)]&&_0x1c998a[_0x775d69(0xd7)]==null)throw CliErrors[_0x775d69(0xd4)](_0x4fe21d[_0x775d69(0xad)]+_0x775d69(0xa3));let _0xec4b0c=extractScriptDescription(_0x4b3377);if(!_0xec4b0c&&_0x1c998a?.[_0x775d69(0xb3)]){const _0x1e143a=await getBffScriptInfo(_0x1c998a[_0x775d69(0xb3)]);_0xec4b0c=_0x1e143a[_0x775d69(0xae)]||undefined;}const _0x4e3b0b={'appCode':_0x555c8a,'functionName':_0x4fe21d['name'],'scriptType':_0x4fe21d[_0x775d69(0xd2)],'scriptContent':_0x4b3377};if(_0x1c998a?.[_0x775d69(0xb3)])_0x4e3b0b['id']=_0x1c998a['remoteId'];if(_0x1c998a?.[_0x775d69(0xd7)]!=null)_0x4e3b0b[_0x775d69(0xd7)]=_0x1c998a['version'];if(_0xec4b0c)_0x4e3b0b[_0x775d69(0xae)]=_0xec4b0c;if(_0x4fe21d[_0x775d69(0xd2)]==='HOOK'){const _0x325c9c=_0x4fe21d[_0x775d69(0xc7)];if(!_0x325c9c||!_0x4fe21d[_0x775d69(0xbc)]||!_0x4fe21d[_0x775d69(0xbd)])throw CliErrors[_0x775d69(0xd4)](_0x775d69(0xc0)+_0x4fe21d[_0x775d69(0xad)]);const _0x147591=_0x2737ad[_0x775d69(0xaf)][_0x775d69(0xb8)](_0x325c9c)??_0x1c998a?.[_0x775d69(0xa4)]??_0x325c9c,_0x988d24=_0x2737ad[_0x775d69(0xb6)][_0x775d69(0xb8)](_0x147591);if(!_0x988d24)throw CliErrors[_0x775d69(0xd4)]('Cannot\x20resolve\x20dataset\x20for\x20\x22'+_0x325c9c+_0x775d69(0xbe)+(_0x775d69(0x9e)+CLI_BIN_NAME+'\x20api\x20pull`\x20to\x20refresh\x20api.ts,\x20or\x20verify\x20the\x20dataset\x20exists.'));_0x4e3b0b[_0x775d69(0x96)]=_0x988d24['id'],_0x4e3b0b['operationType']=_0x4fe21d[_0x775d69(0xbc)],_0x4e3b0b[_0x775d69(0xbd)]=_0x4fe21d['functionNode'];}const _0x35f7ed=await saveBffScript(_0x4e3b0b),_0x4b4a79=_0x35f7ed['id'],_0x3c3a3c=_0x35f7ed['script']??await getBffScriptInfo(_0x4b4a79),_0x41d3d5={'hash':_0x4c25ea,'remoteId':_0x4b4a79,'version':_0x3c3a3c[_0x775d69(0xd7)]};if(_0x4fe21d[_0x775d69(0xd2)]===_0x775d69(0xa2)){const _0x1c9bf4=_0x4fe21d[_0x775d69(0xc7)],_0x3dbf68=_0x2737ad[_0x775d69(0xaf)][_0x775d69(0xb8)](_0x1c9bf4)??_0x1c998a?.['datasetCode']??_0x1c9bf4;_0x2737ad[_0x775d69(0xaf)][_0x775d69(0xc4)](_0x1c9bf4)?_0x41d3d5[_0x775d69(0xc7)]=_0x1c9bf4:_0x41d3d5['alias']=_0x1c998a?.[_0x775d69(0xc7)],_0x41d3d5['datasetCode']=_0x3dbf68,_0x41d3d5[_0x775d69(0xbc)]=_0x4fe21d['operationType'],_0x41d3d5[_0x775d69(0xbd)]=_0x4fe21d[_0x775d69(0xbd)];}_0x3a869a[_0x775d69(0x9d)][_0x4fe21d[_0x775d69(0xad)]]=_0x41d3d5;}const LOCK_SETTLE_RETRY_COUNT=0x14,LOCK_SETTLE_DELAY_MS=0x64;async function waitForUploadedLockEntries(_0x537839,_0x38d839,_0x282427){const _0x51533e=a32_0xd8d93c;if(_0x282427[_0x51533e(0xdb)]===0x0)return;for(let _0x119c3e=0x0;_0x119c3e<LOCK_SETTLE_RETRY_COUNT;_0x119c3e+=0x1){const _0x16d493=await readBffLockFile(_0x537839),_0x5012aa=_0x16d493?.[_0x51533e(0x94)]?.[_0x38d839]?.[_0x51533e(0x9d)]??{},_0x174b4b=_0x282427['every'](_0x35c173=>!!_0x5012aa[_0x35c173]?.[_0x51533e(0xb3)]);if(_0x174b4b)return;await sleep(LOCK_SETTLE_DELAY_MS);}throw new Error('Lock\x20file\x20not\x20settled\x20after\x20push\x20for\x20'+_0x282427[_0x51533e(0x98)](',\x20')+'.');}
@@ -1 +1 @@
1
- const a33_0x2b8ed3=a33_0x4cff;(function(_0x1e0ddc,_0x44f838){const _0x5acaab=a33_0x4cff,_0x40db34=_0x1e0ddc();while(!![]){try{const _0x45c51e=parseInt(_0x5acaab(0x73))/0x1*(parseInt(_0x5acaab(0x7f))/0x2)+-parseInt(_0x5acaab(0x81))/0x3*(parseInt(_0x5acaab(0x90))/0x4)+parseInt(_0x5acaab(0x85))/0x5+-parseInt(_0x5acaab(0x7b))/0x6+parseInt(_0x5acaab(0x84))/0x7+parseInt(_0x5acaab(0x74))/0x8*(parseInt(_0x5acaab(0x77))/0x9)+-parseInt(_0x5acaab(0x87))/0xa;if(_0x45c51e===_0x44f838)break;else _0x40db34['push'](_0x40db34['shift']());}catch(_0x4c0a9e){_0x40db34['push'](_0x40db34['shift']());}}}(a33_0x4511,0xafe5f));import{listBffScripts,getBffScriptStatistics}from'../../core/api-client.js';function a33_0x4511(){const _0x53f38d=['23477FvkKlt','80lWHqIP','All\x20BFF\x20scripts\x20are\x20in\x20sync.','has','475533zgatrZ','\x20added,\x20','lockFilePath','datasetCode','5698050rNmFkZ','boolean','functions','length','90rBHGGB','status','3081003iAHpKe','map','scriptsRoot','127575ocNBfp','7038135XBXQdf','all','3135320ydViQp','Also\x20check\x20for\x20remote-only\x20scripts\x20not\x20present\x20locally','\x20remote-only','lockKey','hash','\x20unchanged','push','apiDir','filePath','4sKpEYq','remote','bff','appCode','Check\x20local\x20BFF\x20sync\x20status\x20against\x20lock\x20file'];a33_0x4511=function(){return _0x53f38d;};return a33_0x4511();}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';function a33_0x4cff(_0x629d5,_0x6cd511){_0x629d5=_0x629d5-0x73;const _0x45111d=a33_0x4511();let _0x4cfff7=_0x45111d[_0x629d5];return _0x4cfff7;}import{createEmptyBffLock,ensureLockScope,readBffLockFile}from'../../core/bff/lock.js';export const bffStatus={'service':a33_0x2b8ed3(0x92),'command':a33_0x2b8ed3(0x80),'description':a33_0x2b8ed3(0x94),'risk':'read','flags':[{'name':a33_0x2b8ed3(0x91),'type':a33_0x2b8ed3(0x7c),'description':a33_0x2b8ed3(0x88)}],async 'execute'(_0x4b0964){const _0x560ef9=a33_0x2b8ed3,_0x2d5ac3=loadBffProjectConfig(_0x4b0964[_0x560ef9(0x93)]),_0x41deb6=await readBffLockFile(_0x2d5ac3[_0x560ef9(0x79)]),{appLock:_0x3c1a01}=ensureLockScope(_0x41deb6??createEmptyBffLock(),_0x4b0964['appCode'],_0x2d5ac3[_0x560ef9(0x83)],_0x560ef9(0x80)),_0x58f133=await scanLocalBffFunctions(_0x2d5ac3),_0x101884=[],_0x32315f=[],_0xd9e458=[];for(const _0x55c5b2 of _0x58f133){const _0x2526dd=await computeFileHash(_0x55c5b2[_0x560ef9(0x8f)]),_0x502f6a=_0x3c1a01[_0x560ef9(0x7d)][_0x55c5b2[_0x560ef9(0x8a)]];if(!_0x502f6a)_0x101884[_0x560ef9(0x8d)](_0x55c5b2[_0x560ef9(0x8a)]);else _0x502f6a[_0x560ef9(0x8b)]!==_0x2526dd?_0x32315f[_0x560ef9(0x8d)](_0x55c5b2[_0x560ef9(0x8a)]):_0xd9e458[_0x560ef9(0x8d)](_0x55c5b2[_0x560ef9(0x8a)]);}const _0x48330d=[];if(_0x4b0964['bool']('remote')){const _0xb586cd=loadAliasMap(_0x4b0964[_0x560ef9(0x8e)],undefined,resolveApiFilePath(_0x4b0964[_0x560ef9(0x8e)],_0x4b0964[_0x560ef9(0x93)])),_0x2e3e54=new Map(_0xb586cd['map'](_0xd2f70=>[_0xd2f70[_0x560ef9(0x7a)],_0xd2f70['alias']])),[_0x505419,_0x175c55]=await Promise[_0x560ef9(0x86)]([listBffScripts(_0x4b0964[_0x560ef9(0x93)]),getBffScriptStatistics(_0x4b0964[_0x560ef9(0x93)])]),_0x2d8827=createHookLocationMap(_0x175c55),_0x14e532=new Set(_0x58f133[_0x560ef9(0x82)](_0x26ec88=>_0x26ec88['lockKey']));for(const _0x5ec088 of _0x505419){const _0x58fec2=resolveRemoteScriptTarget(_0x2d5ac3,_0x5ec088,_0x2d8827,_0x3c1a01[_0x560ef9(0x7d)],_0x2e3e54);_0x58fec2&&!_0x14e532[_0x560ef9(0x76)](_0x58fec2['lockKey'])&&_0x48330d[_0x560ef9(0x8d)](_0x58fec2[_0x560ef9(0x8a)]);}}const _0x285e09=_0x101884['length']===0x0&&_0x32315f[_0x560ef9(0x7e)]===0x0&&_0x48330d[_0x560ef9(0x7e)]===0x0;return{'ok':!![],'data':{'added':_0x101884,'modified':_0x32315f,'unchanged':_0xd9e458,'remoteOnly':_0x48330d},'message':_0x285e09?_0x560ef9(0x75):_0x101884[_0x560ef9(0x7e)]+_0x560ef9(0x78)+_0x32315f['length']+'\x20modified,\x20'+_0xd9e458[_0x560ef9(0x7e)]+_0x560ef9(0x8c)+(_0x48330d[_0x560ef9(0x7e)]>0x0?',\x20'+_0x48330d['length']+_0x560ef9(0x89):'')};}};
1
+ const a33_0x156dda=a33_0x270b;(function(_0x332460,_0x5af11e){const _0x2cb294=a33_0x270b,_0x1fae39=_0x332460();while(!![]){try{const _0x190bbb=-parseInt(_0x2cb294(0xba))/0x1+parseInt(_0x2cb294(0xb3))/0x2*(parseInt(_0x2cb294(0xbe))/0x3)+-parseInt(_0x2cb294(0xbf))/0x4+-parseInt(_0x2cb294(0xb4))/0x5*(parseInt(_0x2cb294(0xaf))/0x6)+parseInt(_0x2cb294(0xc4))/0x7+parseInt(_0x2cb294(0xc8))/0x8*(parseInt(_0x2cb294(0xb8))/0x9)+parseInt(_0x2cb294(0xcd))/0xa;if(_0x190bbb===_0x5af11e)break;else _0x1fae39['push'](_0x1fae39['shift']());}catch(_0x485437){_0x1fae39['push'](_0x1fae39['shift']());}}}(a33_0xa2d2,0xa042d));import{listBffScripts,getBffScriptStatistics}from'../../core/api-client.js';function a33_0xa2d2(){const _0x3111f3=['4240116qUflLj','apiDir','status','scriptsRoot','push','1717275SxvItt','appCode','bool','hash','304wlSJWr','\x20added,\x20','remote','has','Check\x20local\x20BFF\x20sync\x20status\x20against\x20lock\x20file','19802290XzdotB','48414NzSXDE','boolean','bff','\x20unchanged','1175532KcrKRG','710ujhOvZ','length','read','functions','48996jvDuhF','lockKey','157936GBgjJQ','all','Also\x20check\x20for\x20remote-only\x20scripts\x20not\x20present\x20locally','alias','3HoXsSE'];a33_0xa2d2=function(){return _0x3111f3;};return a33_0xa2d2();}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';function a33_0x270b(_0x3eba1d,_0x4ce0cc){_0x3eba1d=_0x3eba1d-0xaf;const _0xa2d27f=a33_0xa2d2();let _0x270b98=_0xa2d27f[_0x3eba1d];return _0x270b98;}import{createEmptyBffLock,ensureLockScope,readBffLockFile}from'../../core/bff/lock.js';export const bffStatus={'service':a33_0x156dda(0xb1),'command':'status','description':a33_0x156dda(0xcc),'risk':a33_0x156dda(0xb6),'flags':[{'name':a33_0x156dda(0xca),'type':a33_0x156dda(0xb0),'description':a33_0x156dda(0xbc)}],async 'execute'(_0x5c0432){const _0x36ba1c=a33_0x156dda,_0x17ccbe=loadBffProjectConfig(_0x5c0432[_0x36ba1c(0xc5)]),_0x2e4cea=await readBffLockFile(_0x17ccbe['lockFilePath']),{appLock:_0x359343}=ensureLockScope(_0x2e4cea??createEmptyBffLock(),_0x5c0432[_0x36ba1c(0xc5)],_0x17ccbe[_0x36ba1c(0xc2)],_0x36ba1c(0xc1)),_0x25bf11=await scanLocalBffFunctions(_0x17ccbe),_0x4b2422=[],_0x3fa102=[],_0x11b2ae=[];for(const _0x5cd09e of _0x25bf11){const _0x2b0765=await computeFileHash(_0x5cd09e['filePath']),_0x2a9b3e=_0x359343[_0x36ba1c(0xb7)][_0x5cd09e['lockKey']];if(!_0x2a9b3e)_0x4b2422[_0x36ba1c(0xc3)](_0x5cd09e[_0x36ba1c(0xb9)]);else _0x2a9b3e[_0x36ba1c(0xc7)]!==_0x2b0765?_0x3fa102['push'](_0x5cd09e[_0x36ba1c(0xb9)]):_0x11b2ae['push'](_0x5cd09e[_0x36ba1c(0xb9)]);}const _0x33c954=[];if(_0x5c0432[_0x36ba1c(0xc6)]('remote')){const _0x3f9122=loadAliasMap(_0x5c0432['apiDir'],undefined,resolveApiFilePath(_0x5c0432[_0x36ba1c(0xc0)],_0x5c0432['appCode'])),_0x33caff=new Map(_0x3f9122['map'](_0x374066=>[_0x374066['datasetCode'],_0x374066[_0x36ba1c(0xbd)]])),[_0xc8a416,_0x2bf6ce]=await Promise[_0x36ba1c(0xbb)]([listBffScripts(_0x5c0432[_0x36ba1c(0xc5)]),getBffScriptStatistics(_0x5c0432[_0x36ba1c(0xc5)])]),_0x13120f=createHookLocationMap(_0x2bf6ce),_0x11b19c=new Set(_0x25bf11['map'](_0x2db79c=>_0x2db79c[_0x36ba1c(0xb9)]));for(const _0x56b616 of _0xc8a416){const _0x2404ea=resolveRemoteScriptTarget(_0x17ccbe,_0x56b616,_0x13120f,_0x359343[_0x36ba1c(0xb7)],_0x33caff);_0x2404ea&&!_0x11b19c[_0x36ba1c(0xcb)](_0x2404ea['lockKey'])&&_0x33c954[_0x36ba1c(0xc3)](_0x2404ea[_0x36ba1c(0xb9)]);}}const _0x2f2b5e=_0x4b2422[_0x36ba1c(0xb5)]===0x0&&_0x3fa102[_0x36ba1c(0xb5)]===0x0&&_0x33c954[_0x36ba1c(0xb5)]===0x0;return{'ok':!![],'data':{'added':_0x4b2422,'modified':_0x3fa102,'unchanged':_0x11b2ae,'remoteOnly':_0x33c954},'message':_0x2f2b5e?'All\x20BFF\x20scripts\x20are\x20in\x20sync.':_0x4b2422[_0x36ba1c(0xb5)]+_0x36ba1c(0xc9)+_0x3fa102[_0x36ba1c(0xb5)]+'\x20modified,\x20'+_0x11b2ae[_0x36ba1c(0xb5)]+_0x36ba1c(0xb2)+(_0x33c954[_0x36ba1c(0xb5)]>0x0?',\x20'+_0x33c954[_0x36ba1c(0xb5)]+'\x20remote-only':'')};}};
@@ -1 +1 @@
1
- const a34_0x549c21=a34_0x4b08;(function(_0x54dc48,_0x4f29c9){const _0x10c90d=a34_0x4b08,_0x467032=_0x54dc48();while(!![]){try{const _0x351fcb=parseInt(_0x10c90d(0x1c1))/0x1+parseInt(_0x10c90d(0x1bb))/0x2+-parseInt(_0x10c90d(0x1ae))/0x3+parseInt(_0x10c90d(0x1be))/0x4*(parseInt(_0x10c90d(0x1a8))/0x5)+-parseInt(_0x10c90d(0x1b3))/0x6+-parseInt(_0x10c90d(0x1a5))/0x7*(parseInt(_0x10c90d(0x1a9))/0x8)+parseInt(_0x10c90d(0x1c8))/0x9*(-parseInt(_0x10c90d(0x1cf))/0xa);if(_0x351fcb===_0x4f29c9)break;else _0x467032['push'](_0x467032['shift']());}catch(_0x3f6a17){_0x467032['push'](_0x467032['shift']());}}}(a34_0x1062,0x7fe74));import a34_0x584130 from'chalk';import a34_0xedfc39 from'ora';import a34_0x157196 from'semver';import{execa}from'execa';import{NPM_PACKAGE_NAME}from'../constant/cli.js';import{VERSION,GIT_COMMIT,BUILD_TIME}from'../generated/build-info.js';import{CliErrors}from'../errors.js';import{NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE,RABETBASE_SKILL_SOURCE,runNpxSkillsAddGlobal}from'../skills/npx-skills-add.js';import{resolveNpmBin}from'../utils/platform.js';function a34_0x1062(){const _0x404c42=['no-skills','\x20→\x20','Update\x20failed','Install\x20a\x20specific\x20CLI\x20version','validation','725011QlIuhE','@latest','Update\x20available:\x20','90QeschG','16OJYFjl','Install\x20the\x20version\x20from\x20npm\x20beta\x20dist-tag','https://registry.npmjs.org/-/package/','execPath','boolean','98907vARTOg','...','pipe','fromEntries','json','3775692aqgvbi','filter','green','Updating\x20via\x20','error','npm','install','fail','1655596NGZQdc','bool','log','216316qLrXBj','message','update','360948OnCMxH','beta','gray','\x20\x20Official\x20skill\x20package\x20is\x20up\x20to\x20date.','trim','\x20\x20Skipped\x20skill\x20install\x20(RABETBASE_SKIP_NPX_SKILLS=1).','source','6919911FQUkzI','bun','length','\x20\x20Try\x20manually:\x20','Use\x20a\x20full\x20semver\x20such\x20as\x202.1.6\x20or\x202.1.6-beta.1.','Skip\x20official\x20skill\x20package\x20refresh\x20after\x20updating','yellow','10gYqjOs','Version\x20comparison\x20failed','version','\x20\x20Restart\x20your\x20terminal\x20to\x20use\x20the\x20new\x20version.','\x20install\x20-g\x20','valid','Updated\x20to\x20v','skills','Already\x20on\x20requested\x20version\x20(v','toLowerCase','skipped','info','Current\x20version:\x20','Update\x20rabetbase\x20CLI\x20to\x20the\x20latest\x20version','Skipping\x20official\x20skill\x20package\x20(--no-skills).','timeout','flag','unknown','string','start','Unable\x20to\x20check\x20for\x20updates\x20(network\x20error)','--beta\x20and\x20--version\x20cannot\x20be\x20used\x20together.','write','\x20\x20Run\x20manually:\x20npm\x20install\x20-g\x20','nonInteractive','Unable\x20to\x20resolve\x20beta\x20version\x20from\x20npm','Requested\x20version:\x20','succeed','red','warn','Invalid\x20version:\x20','latest','run','Checking\x20for\x20updates...','object'];a34_0x1062=function(){return _0x404c42;};return a34_0x1062();}function getCurrentVersion(){const _0x12966d=a34_0x4b08;return GIT_COMMIT!==_0x12966d(0x1e0)?VERSION+'\x20('+GIT_COMMIT+',\x20'+BUILD_TIME['slice'](0x0,0xa)+')':VERSION;}function detectPackageManager(){const _0xc2fefa=a34_0x4b08,_0x18ab23=process[_0xc2fefa(0x1ac)][_0xc2fefa(0x1d8)]();if(_0x18ab23['includes'](_0xc2fefa(0x1c9)))return _0xc2fefa(0x1c9);return'npm';}const updateFlags=[{'name':a34_0x549c21(0x1c2),'type':a34_0x549c21(0x1ad),'description':a34_0x549c21(0x1aa),'default':![]},{'name':a34_0x549c21(0x1d1),'type':a34_0x549c21(0x1e1),'description':a34_0x549c21(0x1a3)},{'name':a34_0x549c21(0x1a0),'type':a34_0x549c21(0x1ad),'description':a34_0x549c21(0x1cd),'default':![]},{'name':a34_0x549c21(0x1d6),'type':a34_0x549c21(0x1ad),'description':'Refresh\x20official\x20skill\x20package\x20after\x20updating','default':!![],'hidden':!![]}];function getRequestedVersion(_0x2e293e){const _0xc1cc6c=a34_0x549c21;return _0x2e293e['str'](_0xc1cc6c(0x1d1))[_0xc1cc6c(0x1c5)]();}function shouldSkipOfficialSkill(_0x58e743){const _0x3f5c77=a34_0x549c21;return _0x58e743[_0x3f5c77(0x1bc)]('no-skills')||_0x58e743[_0x3f5c77(0x1df)](_0x3f5c77(0x1d6))===![];}async function validateUpdateFlags(_0x14667c){const _0x3e91fa=a34_0x549c21,_0x439dd3=_0x14667c[_0x3e91fa(0x1bc)]('beta'),_0x5f481c=getRequestedVersion(_0x14667c);if(_0x439dd3&&_0x5f481c)throw CliErrors['validation'](_0x3e91fa(0x1e4),'Choose\x20either\x20npm\x20beta\x20dist-tag\x20or\x20an\x20exact\x20version.');if(_0x5f481c&&!a34_0x157196[_0x3e91fa(0x1d4)](_0x5f481c))throw CliErrors[_0x3e91fa(0x1a4)](_0x3e91fa(0x1ed)+_0x5f481c,_0x3e91fa(0x1cc));}function a34_0x4b08(_0x2fa8c0,_0x46ae10){_0x2fa8c0=_0x2fa8c0-0x19c;const _0x106276=a34_0x1062();let _0x4b08a0=_0x106276[_0x2fa8c0];return _0x4b08a0;}async function fetchNpmDistTags(){const _0x47dd83=a34_0x549c21;try{const _0x578f29=await fetch(_0x47dd83(0x1ab)+encodeURIComponent(NPM_PACKAGE_NAME)+'/dist-tags',{'signal':AbortSignal[_0x47dd83(0x1de)](0x2710)});if(!_0x578f29['ok'])return null;const _0x622df2=await _0x578f29[_0x47dd83(0x1b2)]();if(!_0x622df2||typeof _0x622df2!==_0x47dd83(0x19f))return null;return Object[_0x47dd83(0x1b1)](Object['entries'](_0x622df2)[_0x47dd83(0x1b4)](([,_0x3bf9f7])=>typeof _0x3bf9f7===_0x47dd83(0x1e1)&&_0x3bf9f7['trim']()[_0x47dd83(0x1ca)]>0x0)['map'](([_0x2c25c0,_0x439830])=>[_0x2c25c0,String(_0x439830)[_0x47dd83(0x1c5)]()]));}catch{return null;}}async function fetchNpmDistTagVersion(_0x486437){const _0x312989=await fetchNpmDistTags();return _0x312989?.[_0x486437]??null;}async function fetchLatestVersion(){return fetchNpmDistTagVersion('latest');}async function resolveTargetVersion(_0x1974c4){const _0x30b060=a34_0x549c21,_0x5da22d=getRequestedVersion(_0x1974c4);if(_0x5da22d)return{'version':_0x5da22d,'source':'version'};if(_0x1974c4['bool'](_0x30b060(0x1c2))){const _0x59664e=await fetchNpmDistTagVersion(_0x30b060(0x1c2));if(!_0x59664e)return null;return{'version':_0x59664e,'source':_0x30b060(0x1c2)};}const _0x12e007=await fetchLatestVersion();if(!_0x12e007)return null;return{'version':_0x12e007,'source':_0x30b060(0x19c)};}function shouldInstallTarget(_0x259ed8,_0x2faaa4){const _0x12de87=a34_0x549c21;if(_0x2faaa4[_0x12de87(0x1c7)]===_0x12de87(0x1d1)||_0x2faaa4['source']===_0x12de87(0x1c2))return!a34_0x157196['eq'](_0x259ed8,_0x2faaa4[_0x12de87(0x1d1)]);return a34_0x157196['lt'](_0x259ed8,_0x2faaa4[_0x12de87(0x1d1)]);}function getInstallPlanLabel(_0x546f7e,_0x71a557){const _0xa667f=a34_0x549c21;switch(_0x71a557[_0xa667f(0x1c7)]){case _0xa667f(0x1c2):return'Beta\x20version:\x20'+a34_0x584130[_0xa667f(0x1ce)](_0x546f7e)+_0xa667f(0x1a1)+a34_0x584130[_0xa667f(0x1b5)](_0x71a557[_0xa667f(0x1d1)]);case _0xa667f(0x1d1):return _0xa667f(0x1e9)+a34_0x584130[_0xa667f(0x1ce)](_0x546f7e)+'\x20→\x20'+a34_0x584130[_0xa667f(0x1b5)](_0x71a557[_0xa667f(0x1d1)]);case _0xa667f(0x19c):default:return _0xa667f(0x1a7)+a34_0x584130[_0xa667f(0x1ce)](_0x546f7e)+_0xa667f(0x1a1)+a34_0x584130[_0xa667f(0x1b5)](_0x71a557[_0xa667f(0x1d1)]);}}async function installOfficialSkill(_0x54ded5){const _0x275449=a34_0x549c21;console[_0x275449(0x1bd)](a34_0x584130['gray']('Checking\x20official\x20skill\x20package...'));const _0x48b06a=runNpxSkillsAddGlobal(process['cwd'](),RABETBASE_SKILL_SOURCE,{'stdio':_0x54ded5?_0x275449(0x1b0):'inherit'});if(_0x48b06a[_0x275449(0x1d9)]){console[_0x275449(0x1bd)](a34_0x584130[_0x275449(0x1c3)](_0x275449(0x1c6)));return;}if(_0x48b06a['ok']){console[_0x275449(0x1bd)](a34_0x584130[_0x275449(0x1c3)](_0x275449(0x1c4)));return;}console[_0x275449(0x1ec)](a34_0x584130[_0x275449(0x1ce)]('\x20\x20Official\x20skill\x20update\x20failed:\x20'+(_0x48b06a[_0x275449(0x1b7)]||_0x275449(0x1e0)))),console['log'](a34_0x584130[_0x275449(0x1c3)]('\x20\x20Run\x20manually:\x20'+NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE));}async function execute(_0x94787f){const _0x23e423=a34_0x549c21;await validateUpdateFlags(_0x94787f);const _0x2413b4=getCurrentVersion();console[_0x23e423(0x1bd)](_0x23e423(0x1db)+_0x2413b4);const _0xd7f8f2=a34_0xedfc39(_0x23e423(0x19e))[_0x23e423(0x1e2)](),_0x2623de=await resolveTargetVersion(_0x94787f);if(!_0x2623de){const _0x71e726=_0x94787f[_0x23e423(0x1bc)]('beta')?_0x23e423(0x1e8):_0x23e423(0x1e3);return _0xd7f8f2[_0x23e423(0x1ba)](_0x71e726),console[_0x23e423(0x1bd)](a34_0x584130['gray'](_0x23e423(0x1e6)+NPM_PACKAGE_NAME+_0x23e423(0x1a6))),{'ok':![],'message':_0x71e726};}const _0x2ae3b0=a34_0x157196['valid'](VERSION),_0x58c8a8=a34_0x157196[_0x23e423(0x1d4)](_0x2623de[_0x23e423(0x1d1)]);if(!_0x2ae3b0||!_0x58c8a8)return _0xd7f8f2['fail'](_0x23e423(0x1d0)),{'ok':![],'message':_0x23e423(0x1d0)};if(!shouldInstallTarget(_0x2ae3b0,_0x2623de)){const _0x280e81=_0x2623de['source']===_0x23e423(0x1d1)?_0x23e423(0x1d7)+_0x2623de[_0x23e423(0x1d1)]+')':'Already\x20up\x20to\x20date\x20(v'+_0x2623de[_0x23e423(0x1d1)]+')';return _0xd7f8f2[_0x23e423(0x1ea)](_0x280e81),shouldSkipOfficialSkill(_0x94787f)?console[_0x23e423(0x1bd)](a34_0x584130['gray'](_0x23e423(0x1dd))):await installOfficialSkill(_0x94787f[_0x23e423(0x1e7)]),{'ok':!![]};}_0xd7f8f2[_0x23e423(0x1da)](getInstallPlanLabel(_0x2413b4,_0x2623de));const _0x5511eb=detectPackageManager(),_0x38ff69=_0x5511eb===_0x23e423(0x1b8)?resolveNpmBin('npm'):_0x5511eb,_0xcb69ea=a34_0xedfc39(_0x23e423(0x1b6)+_0x5511eb+_0x23e423(0x1af))[_0x23e423(0x1e2)]();try{return await execa(_0x38ff69,[_0x23e423(0x1b9),'-g',NPM_PACKAGE_NAME+'@'+_0x2623de[_0x23e423(0x1d1)]],{'stdio':_0x23e423(0x1b0)}),_0xcb69ea['succeed'](_0x23e423(0x1d5)+_0x2623de[_0x23e423(0x1d1)]),console[_0x23e423(0x1bd)](a34_0x584130['gray'](_0x23e423(0x1d2))),shouldSkipOfficialSkill(_0x94787f)?console[_0x23e423(0x1bd)](a34_0x584130['gray'](_0x23e423(0x1dd))):await installOfficialSkill(_0x94787f[_0x23e423(0x1e7)]),{'ok':!![]};}catch(_0x4f4535){return _0xcb69ea['fail'](_0x23e423(0x1a2)),console['error'](a34_0x584130[_0x23e423(0x1eb)]('\x20\x20'+_0x4f4535[_0x23e423(0x1bf)])),console[_0x23e423(0x1bd)](a34_0x584130[_0x23e423(0x1c3)](_0x23e423(0x1cb)+_0x5511eb+_0x23e423(0x1d3)+NPM_PACKAGE_NAME+'@'+_0x2623de[_0x23e423(0x1d1)])),{'ok':![],'message':_0x4f4535['message']};}}export const updateDefinition={'service':a34_0x549c21(0x1c0),'command':a34_0x549c21(0x19d),'description':a34_0x549c21(0x1dc),'risk':a34_0x549c21(0x1e5),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':updateFlags,'validate':validateUpdateFlags,'execute':execute};
1
+ const a34_0x3b3325=a34_0x33ae;(function(_0x25b007,_0x501067){const _0x3fd783=a34_0x33ae,_0x9e35b4=_0x25b007();while(!![]){try{const _0x4c272e=parseInt(_0x3fd783(0x10b))/0x1*(-parseInt(_0x3fd783(0x15c))/0x2)+-parseInt(_0x3fd783(0x14c))/0x3*(parseInt(_0x3fd783(0x10d))/0x4)+-parseInt(_0x3fd783(0x159))/0x5*(-parseInt(_0x3fd783(0x132))/0x6)+-parseInt(_0x3fd783(0x11f))/0x7+-parseInt(_0x3fd783(0x129))/0x8+-parseInt(_0x3fd783(0x153))/0x9+parseInt(_0x3fd783(0x158))/0xa;if(_0x4c272e===_0x501067)break;else _0x9e35b4['push'](_0x9e35b4['shift']());}catch(_0x5db7cc){_0x9e35b4['push'](_0x9e35b4['shift']());}}}(a34_0x17a9,0x6fc38));import a34_0x53d106 from'chalk';import a34_0x1aa0b6 from'ora';import a34_0x9375f0 from'semver';import{execa}from'execa';import{NPM_PACKAGE_NAME}from'../constant/cli.js';import{VERSION,GIT_COMMIT,BUILD_TIME}from'../generated/build-info.js';import{CliErrors}from'../errors.js';import{NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE,RABETBASE_SKILL_SOURCE,runNpxSkillsAddGlobal}from'../skills/npx-skills-add.js';import{resolveNpmBin}from'../utils/platform.js';function getCurrentVersion(){const _0x2b32eb=a34_0x33ae;return GIT_COMMIT!==_0x2b32eb(0x12c)?VERSION+'\x20('+GIT_COMMIT+',\x20'+BUILD_TIME['slice'](0x0,0xa)+')':VERSION;}function detectPackageManager(){const _0xdf08d5=a34_0x33ae,_0x1d7ca6=process[_0xdf08d5(0x146)]['toLowerCase']();if(_0x1d7ca6['includes']('bun'))return _0xdf08d5(0x15b);return'npm';}function a34_0x17a9(){const _0x44e631=['Updating\x20via\x20','inherit','map','@latest','Install\x20a\x20specific\x20CLI\x20version','Install\x20the\x20version\x20from\x20npm\x20beta\x20dist-tag','succeed','Unable\x20to\x20resolve\x20beta\x20version\x20from\x20npm','\x20\x20Official\x20skill\x20package\x20is\x20up\x20to\x20date.','start','boolean','Requested\x20version:\x20','source','3883446FSSSxE','yellow','message','Checking\x20official\x20skill\x20package...','valid','npm','\x20\x20Restart\x20your\x20terminal\x20to\x20use\x20the\x20new\x20version.','fail','\x20→\x20','validation','1673944AqhzTC','/dist-tags','Skipping\x20official\x20skill\x20package\x20(--no-skills).','unknown','--beta\x20and\x20--version\x20cannot\x20be\x20used\x20together.','gray','Checking\x20for\x20updates...','error','flag','6ROGqXe','Update\x20failed','no-skills','\x20install\x20-g\x20','Update\x20available:\x20','\x20\x20Run\x20manually:\x20npm\x20install\x20-g\x20','Refresh\x20official\x20skill\x20package\x20after\x20updating','trim','timeout','https://registry.npmjs.org/-/package/','\x20\x20Official\x20skill\x20update\x20failed:\x20','skills','filter','\x20\x20Try\x20manually:\x20','beta','nonInteractive','skipped','pipe','entries','log','execPath','version','Skip\x20official\x20skill\x20package\x20refresh\x20after\x20updating','red','Unable\x20to\x20check\x20for\x20updates\x20(network\x20error)','install','2183697nheVyY','info','warn','latest','bool','Updated\x20to\x20v','fromEntries','1876725WosYSG','json','cwd','update','Use\x20a\x20full\x20semver\x20such\x20as\x202.1.6\x20or\x202.1.6-beta.1.','23913610xhuvFk','1469305MMOnta','\x20\x20Skipped\x20skill\x20install\x20(RABETBASE_SKIP_NPX_SKILLS=1).','bun','2tvqeLA','526993FpoNKR','write','4YsFRLc','Current\x20version:\x20','str','Choose\x20either\x20npm\x20beta\x20dist-tag\x20or\x20an\x20exact\x20version.','green'];a34_0x17a9=function(){return _0x44e631;};return a34_0x17a9();}const updateFlags=[{'name':a34_0x3b3325(0x140),'type':a34_0x3b3325(0x11c),'description':a34_0x3b3325(0x117),'default':![]},{'name':a34_0x3b3325(0x147),'type':'string','description':a34_0x3b3325(0x116)},{'name':a34_0x3b3325(0x134),'type':a34_0x3b3325(0x11c),'description':a34_0x3b3325(0x148),'default':![]},{'name':a34_0x3b3325(0x13d),'type':a34_0x3b3325(0x11c),'description':a34_0x3b3325(0x138),'default':!![],'hidden':!![]}];function getRequestedVersion(_0xb387d7){const _0x21efee=a34_0x3b3325;return _0xb387d7[_0x21efee(0x10f)]('version')[_0x21efee(0x139)]();}function shouldSkipOfficialSkill(_0x8a78f5){const _0x367d42=a34_0x3b3325;return _0x8a78f5[_0x367d42(0x150)](_0x367d42(0x134))||_0x8a78f5[_0x367d42(0x131)]('skills')===![];}function a34_0x33ae(_0x2bd1a8,_0x5f3b72){_0x2bd1a8=_0x2bd1a8-0x10b;const _0x17a96f=a34_0x17a9();let _0x33ae11=_0x17a96f[_0x2bd1a8];return _0x33ae11;}async function validateUpdateFlags(_0x18c12c){const _0xec68fa=a34_0x3b3325,_0x23d051=_0x18c12c['bool'](_0xec68fa(0x140)),_0x391695=getRequestedVersion(_0x18c12c);if(_0x23d051&&_0x391695)throw CliErrors['validation'](_0xec68fa(0x12d),_0xec68fa(0x110));if(_0x391695&&!a34_0x9375f0[_0xec68fa(0x123)](_0x391695))throw CliErrors[_0xec68fa(0x128)]('Invalid\x20version:\x20'+_0x391695,_0xec68fa(0x157));}async function fetchNpmDistTags(){const _0x414138=a34_0x3b3325;try{const _0x2073d1=await fetch(_0x414138(0x13b)+encodeURIComponent(NPM_PACKAGE_NAME)+_0x414138(0x12a),{'signal':AbortSignal[_0x414138(0x13a)](0x2710)});if(!_0x2073d1['ok'])return null;const _0x47718e=await _0x2073d1[_0x414138(0x154)]();if(!_0x47718e||typeof _0x47718e!=='object')return null;return Object[_0x414138(0x152)](Object[_0x414138(0x144)](_0x47718e)[_0x414138(0x13e)](([,_0x1742fb])=>typeof _0x1742fb==='string'&&_0x1742fb[_0x414138(0x139)]()['length']>0x0)[_0x414138(0x114)](([_0x268592,_0x9f8224])=>[_0x268592,String(_0x9f8224)[_0x414138(0x139)]()]));}catch{return null;}}async function fetchNpmDistTagVersion(_0x36981d){const _0x3565ba=await fetchNpmDistTags();return _0x3565ba?.[_0x36981d]??null;}async function fetchLatestVersion(){const _0x1f1418=a34_0x3b3325;return fetchNpmDistTagVersion(_0x1f1418(0x14f));}async function resolveTargetVersion(_0xa9ca73){const _0x3605af=a34_0x3b3325,_0x380266=getRequestedVersion(_0xa9ca73);if(_0x380266)return{'version':_0x380266,'source':_0x3605af(0x147)};if(_0xa9ca73[_0x3605af(0x150)](_0x3605af(0x140))){const _0x23088c=await fetchNpmDistTagVersion(_0x3605af(0x140));if(!_0x23088c)return null;return{'version':_0x23088c,'source':_0x3605af(0x140)};}const _0x2b702e=await fetchLatestVersion();if(!_0x2b702e)return null;return{'version':_0x2b702e,'source':'latest'};}function shouldInstallTarget(_0x9fdfad,_0x109dff){const _0xd1b54b=a34_0x3b3325;if(_0x109dff[_0xd1b54b(0x11e)]===_0xd1b54b(0x147)||_0x109dff[_0xd1b54b(0x11e)]===_0xd1b54b(0x140))return!a34_0x9375f0['eq'](_0x9fdfad,_0x109dff['version']);return a34_0x9375f0['lt'](_0x9fdfad,_0x109dff[_0xd1b54b(0x147)]);}function getInstallPlanLabel(_0x57b3d1,_0xbda7e2){const _0x52c4f1=a34_0x3b3325;switch(_0xbda7e2[_0x52c4f1(0x11e)]){case _0x52c4f1(0x140):return'Beta\x20version:\x20'+a34_0x53d106['yellow'](_0x57b3d1)+_0x52c4f1(0x127)+a34_0x53d106[_0x52c4f1(0x111)](_0xbda7e2[_0x52c4f1(0x147)]);case _0x52c4f1(0x147):return _0x52c4f1(0x11d)+a34_0x53d106[_0x52c4f1(0x120)](_0x57b3d1)+_0x52c4f1(0x127)+a34_0x53d106['green'](_0xbda7e2[_0x52c4f1(0x147)]);case'latest':default:return _0x52c4f1(0x136)+a34_0x53d106[_0x52c4f1(0x120)](_0x57b3d1)+_0x52c4f1(0x127)+a34_0x53d106[_0x52c4f1(0x111)](_0xbda7e2['version']);}}async function installOfficialSkill(_0x4290e5){const _0x58eb3d=a34_0x3b3325;console[_0x58eb3d(0x145)](a34_0x53d106[_0x58eb3d(0x12e)](_0x58eb3d(0x122)));const _0x559bc4=runNpxSkillsAddGlobal(process[_0x58eb3d(0x155)](),RABETBASE_SKILL_SOURCE,{'stdio':_0x4290e5?_0x58eb3d(0x143):_0x58eb3d(0x113)});if(_0x559bc4[_0x58eb3d(0x142)]){console[_0x58eb3d(0x145)](a34_0x53d106['gray'](_0x58eb3d(0x15a)));return;}if(_0x559bc4['ok']){console[_0x58eb3d(0x145)](a34_0x53d106[_0x58eb3d(0x12e)](_0x58eb3d(0x11a)));return;}console[_0x58eb3d(0x14e)](a34_0x53d106[_0x58eb3d(0x120)](_0x58eb3d(0x13c)+(_0x559bc4[_0x58eb3d(0x130)]||'unknown'))),console['log'](a34_0x53d106['gray']('\x20\x20Run\x20manually:\x20'+NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE));}async function execute(_0x2db835){const _0x1ea270=a34_0x3b3325;await validateUpdateFlags(_0x2db835);const _0x2fd3a2=getCurrentVersion();console[_0x1ea270(0x145)](_0x1ea270(0x10e)+_0x2fd3a2);const _0x1c7333=a34_0x1aa0b6(_0x1ea270(0x12f))['start'](),_0x48ec99=await resolveTargetVersion(_0x2db835);if(!_0x48ec99){const _0x2ea6b4=_0x2db835['bool'](_0x1ea270(0x140))?_0x1ea270(0x119):_0x1ea270(0x14a);return _0x1c7333['fail'](_0x2ea6b4),console[_0x1ea270(0x145)](a34_0x53d106[_0x1ea270(0x12e)](_0x1ea270(0x137)+NPM_PACKAGE_NAME+_0x1ea270(0x115))),{'ok':![],'message':_0x2ea6b4};}const _0x56e77f=a34_0x9375f0['valid'](VERSION),_0x4acf72=a34_0x9375f0[_0x1ea270(0x123)](_0x48ec99[_0x1ea270(0x147)]);if(!_0x56e77f||!_0x4acf72)return _0x1c7333[_0x1ea270(0x126)]('Version\x20comparison\x20failed'),{'ok':![],'message':'Version\x20comparison\x20failed'};if(!shouldInstallTarget(_0x56e77f,_0x48ec99)){const _0x4a899e=_0x48ec99['source']===_0x1ea270(0x147)?'Already\x20on\x20requested\x20version\x20(v'+_0x48ec99[_0x1ea270(0x147)]+')':'Already\x20up\x20to\x20date\x20(v'+_0x48ec99[_0x1ea270(0x147)]+')';return _0x1c7333[_0x1ea270(0x118)](_0x4a899e),shouldSkipOfficialSkill(_0x2db835)?console[_0x1ea270(0x145)](a34_0x53d106['gray']('Skipping\x20official\x20skill\x20package\x20(--no-skills).')):await installOfficialSkill(_0x2db835[_0x1ea270(0x141)]),{'ok':!![]};}_0x1c7333[_0x1ea270(0x14d)](getInstallPlanLabel(_0x2fd3a2,_0x48ec99));const _0x4732bc=detectPackageManager(),_0x1cf17c=_0x4732bc===_0x1ea270(0x124)?resolveNpmBin(_0x1ea270(0x124)):_0x4732bc,_0xa85c88=a34_0x1aa0b6(_0x1ea270(0x112)+_0x4732bc+'...')[_0x1ea270(0x11b)]();try{return await execa(_0x1cf17c,[_0x1ea270(0x14b),'-g',NPM_PACKAGE_NAME+'@'+_0x48ec99['version']],{'stdio':_0x1ea270(0x143)}),_0xa85c88['succeed'](_0x1ea270(0x151)+_0x48ec99[_0x1ea270(0x147)]),console[_0x1ea270(0x145)](a34_0x53d106[_0x1ea270(0x12e)](_0x1ea270(0x125))),shouldSkipOfficialSkill(_0x2db835)?console[_0x1ea270(0x145)](a34_0x53d106[_0x1ea270(0x12e)](_0x1ea270(0x12b))):await installOfficialSkill(_0x2db835['nonInteractive']),{'ok':!![]};}catch(_0x642ef8){return _0xa85c88[_0x1ea270(0x126)](_0x1ea270(0x133)),console[_0x1ea270(0x130)](a34_0x53d106[_0x1ea270(0x149)]('\x20\x20'+_0x642ef8[_0x1ea270(0x121)])),console[_0x1ea270(0x145)](a34_0x53d106[_0x1ea270(0x12e)](_0x1ea270(0x13f)+_0x4732bc+_0x1ea270(0x135)+NPM_PACKAGE_NAME+'@'+_0x48ec99[_0x1ea270(0x147)])),{'ok':![],'message':_0x642ef8[_0x1ea270(0x121)]};}}export const updateDefinition={'service':a34_0x3b3325(0x156),'command':'run','description':'Update\x20rabetbase\x20CLI\x20to\x20the\x20latest\x20version','risk':a34_0x3b3325(0x10c),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':updateFlags,'validate':validateUpdateFlags,'execute':execute};
@@ -1 +1 @@
1
- (function(_0x35c0de,_0x39819e){const _0x1f069c=a35_0x111e,_0x243025=_0x35c0de();while(!![]){try{const _0x29ffd7=parseInt(_0x1f069c(0x1aa))/0x1*(-parseInt(_0x1f069c(0x1a6))/0x2)+-parseInt(_0x1f069c(0x1ad))/0x3*(-parseInt(_0x1f069c(0x1a7))/0x4)+parseInt(_0x1f069c(0x1ae))/0x5+-parseInt(_0x1f069c(0x1a9))/0x6*(-parseInt(_0x1f069c(0x1b0))/0x7)+parseInt(_0x1f069c(0x1ab))/0x8+parseInt(_0x1f069c(0x1a8))/0x9+parseInt(_0x1f069c(0x1af))/0xa*(-parseInt(_0x1f069c(0x1ac))/0xb);if(_0x29ffd7===_0x39819e)break;else _0x243025['push'](_0x243025['shift']());}catch(_0x212d0b){_0x243025['push'](_0x243025['shift']());}}}(a35_0x4159,0x620b9));import{codegenSdk}from'../../commands/codegen/sdk.js';import{codegenSql}from'../../commands/codegen/sql.js';function a35_0x111e(_0x3d58bb,_0x3e534e){_0x3d58bb=_0x3d58bb-0x1a6;const _0x415997=a35_0x4159();let _0x111edd=_0x415997[_0x3d58bb];return _0x111edd;}export const codegenDefinitions=[codegenSdk,codegenSql];function a35_0x4159(){const _0x2eb2e4=['7hVTcog','10SUEkwU','9932EgqSoM','5207382jxnBHu','3232434CZDLqt','22742XOVBoA','2405112pIXpCL','144782VDfZyb','693FNuVzl','1963790digAor','1420PzvKTS'];a35_0x4159=function(){return _0x2eb2e4;};return a35_0x4159();}
1
+ function a35_0x57d3(_0x2677b8,_0xf58149){_0x2677b8=_0x2677b8-0xf5;const _0x29f3e1=a35_0x29f3();let _0x57d3f6=_0x29f3e1[_0x2677b8];return _0x57d3f6;}(function(_0x85ea34,_0x52820f){const _0x312578=a35_0x57d3,_0x161731=_0x85ea34();while(!![]){try{const _0x1e2f47=-parseInt(_0x312578(0xfa))/0x1+-parseInt(_0x312578(0xfc))/0x2*(-parseInt(_0x312578(0xf5))/0x3)+-parseInt(_0x312578(0xfe))/0x4+-parseInt(_0x312578(0xf6))/0x5*(-parseInt(_0x312578(0xfb))/0x6)+parseInt(_0x312578(0xf9))/0x7*(parseInt(_0x312578(0xfd))/0x8)+-parseInt(_0x312578(0xf7))/0x9+parseInt(_0x312578(0xf8))/0xa;if(_0x1e2f47===_0x52820f)break;else _0x161731['push'](_0x161731['shift']());}catch(_0x5ae095){_0x161731['push'](_0x161731['shift']());}}}(a35_0x29f3,0xa83ed));function a35_0x29f3(){const _0x1fb905=['2338aKyXqX','312965cKPaWK','6QmpFER','37894mPvUZr','19016cXXAbD','4030672IEQsWd','6ifrJLC','6167030jdtvtb','2253339xlZoLA','1949190LOaBMn'];a35_0x29f3=function(){return _0x1fb905;};return a35_0x29f3();}import{codegenSdk}from'../../commands/codegen/sdk.js';import{codegenSql}from'../../commands/codegen/sql.js';export const codegenDefinitions=[codegenSdk,codegenSql];
@@ -1 +1 @@
1
- const a36_0x473e7e=a36_0x4482;function a36_0x2285(){const _0x1806ff=['53471XyrAkU','4hsGVQQ','bool','1970kJAtIP','appCode','Omit\x20import\x20statements\x20from\x20generated\x20code','55yMIRxq','alias','639138HjpKBr','name','11211624uWGEUQ','skip-imports','Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon)','read','3046173AFqQzV','str','18176772tKmksm','codegen','45698PNvCpm','30WNfdPE','8bWIvwP','operation','8734355JAeHJu','tableName','Operation\x20name\x20(e.g.\x20filter,\x20getOne,\x20create,\x20update)','code','string','sdk'];a36_0x2285=function(){return _0x1806ff;};return a36_0x2285();}(function(_0x515be1,_0x313c5b){const _0x9c5a7f=a36_0x4482,_0xc6e550=_0x515be1();while(!![]){try{const _0x4fe21d=parseInt(_0x9c5a7f(0x1dd))/0x1*(parseInt(_0x9c5a7f(0x1dc))/0x2)+-parseInt(_0x9c5a7f(0x1d8))/0x3*(parseInt(_0x9c5a7f(0x1e7))/0x4)+-parseInt(_0x9c5a7f(0x1ec))/0x5*(-parseInt(_0x9c5a7f(0x1ee))/0x6)+-parseInt(_0x9c5a7f(0x1e0))/0x7*(parseInt(_0x9c5a7f(0x1de))/0x8)+-parseInt(_0x9c5a7f(0x1f0))/0x9+parseInt(_0x9c5a7f(0x1e9))/0xa*(parseInt(_0x9c5a7f(0x1e6))/0xb)+parseInt(_0x9c5a7f(0x1da))/0xc;if(_0x4fe21d===_0x313c5b)break;else _0xc6e550['push'](_0xc6e550['shift']());}catch(_0xf2b737){_0xc6e550['push'](_0xc6e550['shift']());}}}(a36_0x2285,0xc85c7));import{getOperationDetail,generateSdkCode}from'../../core/api-client.js';function a36_0x4482(_0x4c2b0e,_0x3fe5a1){_0x4c2b0e=_0x4c2b0e-0x1d8;const _0x2285b9=a36_0x2285();let _0x44828a=_0x2285b9[_0x4c2b0e];return _0x44828a;}import{CODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';export const codegenSdk={'service':a36_0x473e7e(0x1db),'command':a36_0x473e7e(0x1e5),'description':'Generate\x20TypeScript\x20SDK\x20code\x20for\x20a\x20dataset\x20operation','risk':a36_0x473e7e(0x1f3),'flags':[CODE_FLAG_OPTIONAL,{'name':a36_0x473e7e(0x1ed),'type':'string','description':a36_0x473e7e(0x1f2)},{'name':'operation','type':a36_0x473e7e(0x1e4),'required':!![],'description':a36_0x473e7e(0x1e2)},{'name':'skip-imports','type':'boolean','description':a36_0x473e7e(0x1eb)}],async 'execute'(_0x20cce1){const _0x3346cb=a36_0x473e7e,{dataset:_0x2b1555,operation:_0x30e202}=await getOperationDetail(_0x20cce1[_0x3346cb(0x1ea)],_0x20cce1[_0x3346cb(0x1d9)](_0x3346cb(0x1e3)),_0x20cce1[_0x3346cb(0x1d9)](_0x3346cb(0x1df))),_0x174763=generateSdkCode(_0x2b1555,_0x30e202,{'includeImports':!_0x20cce1[_0x3346cb(0x1e8)](_0x3346cb(0x1f1))});return{'ok':!![],'data':{'dataset':{'name':_0x2b1555[_0x3346cb(0x1ef)],'code':_0x2b1555[_0x3346cb(0x1e3)],'tableName':_0x2b1555[_0x3346cb(0x1e1)]},'operation':_0x20cce1[_0x3346cb(0x1d9)](_0x3346cb(0x1df)),'code':_0x174763}};}};
1
+ function a36_0x202b(_0x28efca,_0x68ba28){_0x28efca=_0x28efca-0x136;const _0x1006f8=a36_0x1006();let _0x202b08=_0x1006f8[_0x28efca];return _0x202b08;}function a36_0x1006(){const _0x2815be=['Generate\x20TypeScript\x20SDK\x20code\x20for\x20a\x20dataset\x20operation','tableName','948558SuRcOg','11dKgDPI','alias','sdk','23111PMtxoK','str','boolean','27GxGQiB','17084ZvRjfD','5sbSnUg','1009645wcsDVP','249BAIxnz','codegen','Operation\x20name\x20(e.g.\x20filter,\x20getOne,\x20create,\x20update)','code','name','68456LxXBQi','bool','Omit\x20import\x20statements\x20from\x20generated\x20code','string','732RKDPup','operation','skip-imports','read','90410uKhviM','57382xCQpGJ','Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon)'];a36_0x1006=function(){return _0x2815be;};return a36_0x1006();}const a36_0x226e62=a36_0x202b;(function(_0x40df79,_0xb33f10){const _0x4abc55=a36_0x202b,_0x504d13=_0x40df79();while(!![]){try{const _0x254796=-parseInt(_0x4abc55(0x14b))/0x1*(-parseInt(_0x4abc55(0x146))/0x2)+parseInt(_0x4abc55(0x138))/0x3*(parseInt(_0x4abc55(0x152))/0x4)+parseInt(_0x4abc55(0x136))/0x5*(-parseInt(_0x4abc55(0x14a))/0x6)+-parseInt(_0x4abc55(0x137))/0x7+-parseInt(_0x4abc55(0x13d))/0x8+parseInt(_0x4abc55(0x151))/0x9*(-parseInt(_0x4abc55(0x145))/0xa)+-parseInt(_0x4abc55(0x14e))/0xb*(parseInt(_0x4abc55(0x141))/0xc);if(_0x254796===_0xb33f10)break;else _0x504d13['push'](_0x504d13['shift']());}catch(_0x22d943){_0x504d13['push'](_0x504d13['shift']());}}}(a36_0x1006,0x31c95));import{getOperationDetail,generateSdkCode}from'../../core/api-client.js';import{CODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';export const codegenSdk={'service':a36_0x226e62(0x139),'command':a36_0x226e62(0x14d),'description':a36_0x226e62(0x148),'risk':a36_0x226e62(0x144),'flags':[CODE_FLAG_OPTIONAL,{'name':a36_0x226e62(0x14c),'type':a36_0x226e62(0x140),'description':a36_0x226e62(0x147)},{'name':'operation','type':a36_0x226e62(0x140),'required':!![],'description':a36_0x226e62(0x13a)},{'name':a36_0x226e62(0x143),'type':a36_0x226e62(0x150),'description':a36_0x226e62(0x13f)}],async 'execute'(_0x53bfc6){const _0x22e0b1=a36_0x226e62,{dataset:_0x56c59d,operation:_0x492b58}=await getOperationDetail(_0x53bfc6['appCode'],_0x53bfc6[_0x22e0b1(0x14f)](_0x22e0b1(0x13b)),_0x53bfc6[_0x22e0b1(0x14f)](_0x22e0b1(0x142))),_0x46a4ff=generateSdkCode(_0x56c59d,_0x492b58,{'includeImports':!_0x53bfc6[_0x22e0b1(0x13e)](_0x22e0b1(0x143))});return{'ok':!![],'data':{'dataset':{'name':_0x56c59d[_0x22e0b1(0x13c)],'code':_0x56c59d[_0x22e0b1(0x13b)],'tableName':_0x56c59d[_0x22e0b1(0x149)]},'operation':_0x53bfc6['str']('operation'),'code':_0x46a4ff}};}};
@@ -1 +1 @@
1
- function a37_0x45c9(_0x1bc35b,_0x37662b){_0x1bc35b=_0x1bc35b-0x172;const _0x2dcd78=a37_0x2dcd();let _0x45c9e3=_0x2dcd78[_0x1bc35b];return _0x45c9e3;}const a37_0x5cdb38=a37_0x45c9;(function(_0x3bb390,_0x34eeaf){const _0xe3d91b=a37_0x45c9,_0x476cfe=_0x3bb390();while(!![]){try{const _0x20847b=parseInt(_0xe3d91b(0x174))/0x1*(-parseInt(_0xe3d91b(0x178))/0x2)+-parseInt(_0xe3d91b(0x188))/0x3+parseInt(_0xe3d91b(0x17b))/0x4*(parseInt(_0xe3d91b(0x179))/0x5)+-parseInt(_0xe3d91b(0x17c))/0x6+-parseInt(_0xe3d91b(0x181))/0x7*(-parseInt(_0xe3d91b(0x17f))/0x8)+parseInt(_0xe3d91b(0x180))/0x9+parseInt(_0xe3d91b(0x175))/0xa;if(_0x20847b===_0x34eeaf)break;else _0x476cfe['push'](_0x476cfe['shift']());}catch(_0x4edb99){_0x476cfe['push'](_0x476cfe['shift']());}}}(a37_0x2dcd,0x80321));import{getSqlQueryInfo,generateSqlCodeTemplate}from'../../core/api-client.js';import{SQLCODE_FLAG}from'../../commands/common/flags.js';function a37_0x2dcd(){const _0x2584b4=['string','1404855xZOeoQ','sdk','sqlCode','bool','bff','7yMxZuR','13537600GqdmbQ','Code\x20target:\x20sdk\x20(default)\x20or\x20bff','sql','15044ErEbKo','90TOhqRa','sqlcode','28284adjKjP','5704398bBqlke','no-imports','codegen','13336uOJdsp','3186216NVcUIU','679rmiMNY','Omit\x20import\x20statements\x20from\x20generated\x20code','Generate\x20TypeScript\x20code\x20for\x20a\x20custom\x20SQL\x20query','target','str','appCode'];a37_0x2dcd=function(){return _0x2584b4;};return a37_0x2dcd();}export const codegenSql={'service':a37_0x5cdb38(0x17e),'command':a37_0x5cdb38(0x177),'description':a37_0x5cdb38(0x183),'risk':'read','flags':[SQLCODE_FLAG,{'name':a37_0x5cdb38(0x184),'type':a37_0x5cdb38(0x187),'description':a37_0x5cdb38(0x176),'default':a37_0x5cdb38(0x189),'enum':[a37_0x5cdb38(0x189),a37_0x5cdb38(0x173)]},{'name':a37_0x5cdb38(0x17d),'type':'boolean','description':a37_0x5cdb38(0x182)}],async 'execute'(_0x217180){const _0xa625dd=a37_0x5cdb38,_0x18258f=await getSqlQueryInfo(_0x217180[_0xa625dd(0x186)],_0x217180['str'](_0xa625dd(0x17a))),_0x45948a=_0x217180[_0xa625dd(0x185)](_0xa625dd(0x184))||_0xa625dd(0x189),_0x33dbf1=generateSqlCodeTemplate(_0x18258f,{'target':_0x45948a,'includeImports':!_0x217180[_0xa625dd(0x172)](_0xa625dd(0x17d))});return{'ok':!![],'data':{'sqlCode':_0x18258f[_0xa625dd(0x18a)],'sqlName':_0x18258f['sqlName'],'target':_0x45948a,'code':_0x33dbf1}};}};
1
+ const a37_0x137a0f=a37_0xf847;(function(_0x3947d9,_0x314cef){const _0x3d06c7=a37_0xf847,_0x69417d=_0x3947d9();while(!![]){try{const _0x4c5093=-parseInt(_0x3d06c7(0xfb))/0x1*(-parseInt(_0x3d06c7(0xf2))/0x2)+parseInt(_0x3d06c7(0xfa))/0x3+parseInt(_0x3d06c7(0xf8))/0x4*(parseInt(_0x3d06c7(0xf3))/0x5)+-parseInt(_0x3d06c7(0xff))/0x6*(-parseInt(_0x3d06c7(0xef))/0x7)+-parseInt(_0x3d06c7(0x102))/0x8+-parseInt(_0x3d06c7(0xf6))/0x9+-parseInt(_0x3d06c7(0xf7))/0xa;if(_0x4c5093===_0x314cef)break;else _0x69417d['push'](_0x69417d['shift']());}catch(_0xc3a495){_0x69417d['push'](_0x69417d['shift']());}}}(a37_0xad8f,0x96c0d));import{getSqlQueryInfo,generateSqlCodeTemplate}from'../../core/api-client.js';import{SQLCODE_FLAG}from'../../commands/common/flags.js';export const codegenSql={'service':a37_0x137a0f(0xfe),'command':a37_0x137a0f(0x106),'description':'Generate\x20TypeScript\x20code\x20for\x20a\x20custom\x20SQL\x20query','risk':a37_0x137a0f(0xf5),'flags':[SQLCODE_FLAG,{'name':a37_0x137a0f(0x105),'type':a37_0x137a0f(0xf1),'description':a37_0x137a0f(0x101),'default':a37_0x137a0f(0xee),'enum':[a37_0x137a0f(0xee),a37_0x137a0f(0xfc)]},{'name':'no-imports','type':'boolean','description':a37_0x137a0f(0xf4)}],async 'execute'(_0x963528){const _0x19fe2f=a37_0x137a0f,_0x474914=await getSqlQueryInfo(_0x963528['appCode'],_0x963528[_0x19fe2f(0xf0)](_0x19fe2f(0x104))),_0x5af43a=_0x963528[_0x19fe2f(0xf0)](_0x19fe2f(0x105))||'sdk',_0x91059a=generateSqlCodeTemplate(_0x474914,{'target':_0x5af43a,'includeImports':!_0x963528[_0x19fe2f(0xf9)](_0x19fe2f(0xfd))});return{'ok':!![],'data':{'sqlCode':_0x474914[_0x19fe2f(0x100)],'sqlName':_0x474914[_0x19fe2f(0x103)],'target':_0x5af43a,'code':_0x91059a}};}};function a37_0xf847(_0x20922c,_0x43a2e0){_0x20922c=_0x20922c-0xee;const _0xad8fba=a37_0xad8f();let _0xf847e2=_0xad8fba[_0x20922c];return _0xf847e2;}function a37_0xad8f(){const _0x4f50a7=['sqlcode','target','sql','sdk','6615qtCXMl','str','string','6iGvjRv','1382795tPLrRe','Omit\x20import\x20statements\x20from\x20generated\x20code','read','7218639UfBFVg','5729440LhYdVA','8FeeHqS','bool','642387blJNvM','134262lNBtWF','bff','no-imports','codegen','6102MzpMSf','sqlCode','Code\x20target:\x20sdk\x20(default)\x20or\x20bff','1108784lNlnRn','sqlName'];a37_0xad8f=function(){return _0x4f50a7;};return a37_0xad8f();}
@@ -1 +1 @@
1
- (function(_0x560767,_0x5a45e8){const _0x45f4ad=a38_0x1d02,_0x1df399=_0x560767();while(!![]){try{const _0x1eccde=parseInt(_0x45f4ad(0x141))/0x1*(-parseInt(_0x45f4ad(0x13d))/0x2)+parseInt(_0x45f4ad(0x155))/0x3*(-parseInt(_0x45f4ad(0x153))/0x4)+-parseInt(_0x45f4ad(0x14f))/0x5+parseInt(_0x45f4ad(0x150))/0x6+parseInt(_0x45f4ad(0x142))/0x7*(parseInt(_0x45f4ad(0x138))/0x8)+parseInt(_0x45f4ad(0x13f))/0x9*(parseInt(_0x45f4ad(0x15b))/0xa)+parseInt(_0x45f4ad(0x149))/0xb*(parseInt(_0x45f4ad(0x146))/0xc);if(_0x1eccde===_0x5a45e8)break;else _0x1df399['push'](_0x1df399['shift']());}catch(_0x9cd043){_0x1df399['push'](_0x1df399['shift']());}}}(a38_0x320c,0x31823));import{input,checkbox,select}from'@inquirer/prompts';import a38_0x43c0c6 from'chalk';import{validateAppcode}from'../../commands/common/validate.js';import{listRemoteApps}from'../../core/api-client.js';import{withActiveCookie}from'../../utils/with-active-cookie.js';function a38_0x1d02(_0x5e3d2a,_0x132699){_0x5e3d2a=_0x5e3d2a-0x137;const _0x320c2d=a38_0x320c();let _0x1d029b=_0x320c2d[_0x5e3d2a];return _0x1d029b;}import{writeCliSideChannelLine}from'../../utils/write-cli-side-channel.js';function a38_0x320c(){const _0x1cc413=['422042GUWDxh','valid','904005GVUqbq','Invalid\x20App\x20Code','1bBLlYx','18536BuQIsr','find','正在获取可用应用列表...','length','140784kRFdqz','\x0a无法获取远程应用列表,请手动输入。','yellow','286KqVXng','获取到\x20','\x20个应用,请选择\x20(空格勾选,\x20a=全选,\x20i=反选):','未找到可用应用。','trim','\x20\x20(','1008805LdOuAr','571320YjOaVI','(跳过,稍后配置)','无法获取远程应用列表,请手动输入。','25196mWVggi','skip','186BMmcez','(跳过,稍后通过\x20config\x20set\x20appcode\x20配置)','manual','map','✎\x20自定义输入\x20appcode','appName','30uQNPGM','gray','请输入\x20App\x20Code:','920McAduW','cyan','App\x20Code:','custom','appCode'];a38_0x320c=function(){return _0x1cc413;};return a38_0x320c();}export async function promptCustomAppcode(){const _0x1d0f62=a38_0x1d02,_0x3affa2=await input({'message':_0x1d0f62(0x137),'validate':_0x1a32cd=>{const _0x533aa2=_0x1d0f62,_0x4a30b1=validateAppcode(_0x1a32cd[_0x533aa2(0x14d)]());return _0x4a30b1[_0x533aa2(0x13e)]||_0x4a30b1['message']||_0x533aa2(0x140);}});return _0x3affa2['trim']();}export async function promptAppSelection(_0x91293){const _0x40ef44=a38_0x1d02,_0x304ad7=[{'name':a38_0x43c0c6[_0x40ef44(0x148)](_0x40ef44(0x159)),'value':-0x1},..._0x91293[_0x40ef44(0x158)]((_0x55fa70,_0x5af7a8)=>({'name':_0x55fa70[_0x40ef44(0x15a)]+'\x20\x20'+a38_0x43c0c6[_0x40ef44(0x15c)]('('+_0x55fa70[_0x40ef44(0x13c)]+')'),'value':_0x5af7a8}))],_0x5965d2=await checkbox({'message':_0x40ef44(0x14a)+a38_0x43c0c6[_0x40ef44(0x139)](_0x91293[_0x40ef44(0x145)])+_0x40ef44(0x14b),'choices':_0x304ad7,'loop':![]});if(_0x5965d2['includes'](-0x1))return _0x40ef44(0x13b);if(_0x5965d2[_0x40ef44(0x145)]===0x0)return _0x40ef44(0x13b);return _0x5965d2[_0x40ef44(0x158)](_0xe52f9e=>_0x91293[_0xe52f9e]);}export async function promptSingleAppSelection(_0x39687f){const _0x386877=a38_0x1d02,_0x3e884a=[{'name':a38_0x43c0c6['gray'](_0x386877(0x156)),'value':_0x386877(0x154)},{'name':a38_0x43c0c6['yellow']('✎\x20自定义输入\x20appcode'),'value':_0x386877(0x13b)},..._0x39687f['map'](_0x25516d=>({'name':_0x25516d['appName']+'\x20\x20'+a38_0x43c0c6[_0x386877(0x15c)]('('+_0x25516d['appCode']+')'),'value':_0x25516d[_0x386877(0x13c)]}))],_0x52cabc=await select({'message':'请选择要绑定的应用:','choices':_0x3e884a});if(_0x52cabc==='skip')return'skip';if(_0x52cabc===_0x386877(0x13b))return'custom';return _0x39687f[_0x386877(0x143)](_0x44d79e=>_0x44d79e[_0x386877(0x13c)]===_0x52cabc);}export async function selectSingleAppcode(_0x533fed){const _0x1f566d=a38_0x1d02;if(!_0x533fed)return writeCliSideChannelLine(a38_0x43c0c6[_0x1f566d(0x15c)]('(未检测到登录态,请手动输入\x20App\x20Code\x20或直接跳过)')),_fallbackOrSkip();writeCliSideChannelLine(_0x1f566d(0x144));let _0xc0f48b;try{_0xc0f48b=await withActiveCookie(_0x533fed,()=>listRemoteApps());}catch(_0x1ed112){writeCliSideChannelLine(a38_0x43c0c6[_0x1f566d(0x148)](_0x1f566d(0x152)));if(_0x1ed112 instanceof Error)writeCliSideChannelLine(a38_0x43c0c6[_0x1f566d(0x15c)]('\x20\x20('+_0x1ed112['message']+')'));return _fallbackOrSkip();}if(_0xc0f48b[_0x1f566d(0x145)]===0x0)return writeCliSideChannelLine(a38_0x43c0c6[_0x1f566d(0x148)](_0x1f566d(0x14c))),_fallbackOrSkip();const _0x3b0d84=await promptSingleAppSelection(_0xc0f48b);if(_0x3b0d84==='skip')return'';if(_0x3b0d84==='custom')return promptCustomAppcode();return _0x3b0d84[_0x1f566d(0x13c)];}export async function selectMultipleApps(_0x2fadf6){const _0x1436e=a38_0x1d02;writeCliSideChannelLine(_0x1436e(0x144));let _0x1fd750;try{_0x1fd750=await withActiveCookie(_0x2fadf6,()=>listRemoteApps());}catch(_0x28bc5e){writeCliSideChannelLine(_0x1436e(0x147));if(_0x28bc5e instanceof Error)writeCliSideChannelLine(_0x1436e(0x14e)+_0x28bc5e['message']+')');return _0x1436e(0x13b);}if(_0x1fd750[_0x1436e(0x145)]===0x0)return writeCliSideChannelLine('\x0a未找到可用应用。'),'custom';return promptAppSelection(_0x1fd750);}async function _fallbackOrSkip(){const _0x1de295=a38_0x1d02,_0x42c2b1=await select({'message':_0x1de295(0x13a),'choices':[{'name':a38_0x43c0c6[_0x1de295(0x15c)](_0x1de295(0x151)),'value':_0x1de295(0x154)},{'name':a38_0x43c0c6['yellow']('✎\x20手动输入'),'value':_0x1de295(0x157)}]});if(_0x42c2b1===_0x1de295(0x154))return'';return promptCustomAppcode();}
1
+ (function(_0x2a27d5,_0x59bd75){const _0x15ccd4=a38_0x50c6,_0x16736c=_0x2a27d5();while(!![]){try{const _0x52e474=parseInt(_0x15ccd4(0x12f))/0x1*(-parseInt(_0x15ccd4(0x10d))/0x2)+parseInt(_0x15ccd4(0x125))/0x3*(parseInt(_0x15ccd4(0x133))/0x4)+parseInt(_0x15ccd4(0x118))/0x5*(parseInt(_0x15ccd4(0x132))/0x6)+parseInt(_0x15ccd4(0x115))/0x7*(-parseInt(_0x15ccd4(0x119))/0x8)+-parseInt(_0x15ccd4(0x131))/0x9*(parseInt(_0x15ccd4(0x12c))/0xa)+-parseInt(_0x15ccd4(0x123))/0xb+-parseInt(_0x15ccd4(0x112))/0xc*(-parseInt(_0x15ccd4(0x117))/0xd);if(_0x52e474===_0x59bd75)break;else _0x16736c['push'](_0x16736c['shift']());}catch(_0x371e72){_0x16736c['push'](_0x16736c['shift']());}}}(a38_0x42d4,0x26544));import{input,checkbox,select}from'@inquirer/prompts';import a38_0x1ebc08 from'chalk';import{validateAppcode}from'../../commands/common/validate.js';function a38_0x42d4(){const _0x4e2418=['✎\x20手动输入','appName','(未检测到登录态,请手动输入\x20App\x20Code\x20或直接跳过)','2EYaSvj','获取到\x20','\x0a无法获取远程应用列表,请手动输入。','appCode','\x0a未找到可用应用。','7042764eVZBtg','includes','请选择要绑定的应用:','35SwMoDu','yellow','13AuMCPN','30665ZzGRgy','123608Dqzgvu','cyan','length','valid','gray','Invalid\x20App\x20Code','map','(跳过,稍后配置)','custom','✎\x20自定义输入\x20appcode','3425730QNTQVv','未找到可用应用。','6CmiWJG','\x20个应用,请选择\x20(空格勾选,\x20a=全选,\x20i=反选):','manual','正在获取可用应用列表...','skip','trim','(跳过,稍后通过\x20config\x20set\x20appcode\x20配置)','30GUAYds','find','\x20\x20(','121241FwMPYO','message','655794zuAQjJ','30owOkEw','535916OtqTjZ','无法获取远程应用列表,请手动输入。'];a38_0x42d4=function(){return _0x4e2418;};return a38_0x42d4();}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 _0x3132ea=a38_0x50c6,_0x4df239=await input({'message':'请输入\x20App\x20Code:','validate':_0x488fc9=>{const _0x5b7e99=a38_0x50c6,_0x5e34aa=validateAppcode(_0x488fc9[_0x5b7e99(0x12a)]());return _0x5e34aa[_0x5b7e99(0x11c)]||_0x5e34aa[_0x5b7e99(0x130)]||_0x5b7e99(0x11e);}});return _0x4df239[_0x3132ea(0x12a)]();}export async function promptAppSelection(_0x131f21){const _0x2de645=a38_0x50c6,_0x23cbb7=[{'name':a38_0x1ebc08[_0x2de645(0x116)](_0x2de645(0x122)),'value':-0x1},..._0x131f21[_0x2de645(0x11f)]((_0x166dd7,_0x522b03)=>({'name':_0x166dd7['appName']+'\x20\x20'+a38_0x1ebc08['gray']('('+_0x166dd7[_0x2de645(0x110)]+')'),'value':_0x522b03}))],_0x8bdbc0=await checkbox({'message':_0x2de645(0x10e)+a38_0x1ebc08[_0x2de645(0x11a)](_0x131f21[_0x2de645(0x11b)])+_0x2de645(0x126),'choices':_0x23cbb7,'loop':![]});if(_0x8bdbc0[_0x2de645(0x113)](-0x1))return'custom';if(_0x8bdbc0[_0x2de645(0x11b)]===0x0)return'custom';return _0x8bdbc0[_0x2de645(0x11f)](_0x4396dd=>_0x131f21[_0x4396dd]);}export async function promptSingleAppSelection(_0x9cd92b){const _0x3709b9=a38_0x50c6,_0x34ac88=[{'name':a38_0x1ebc08[_0x3709b9(0x11d)](_0x3709b9(0x12b)),'value':_0x3709b9(0x129)},{'name':a38_0x1ebc08[_0x3709b9(0x116)]('✎\x20自定义输入\x20appcode'),'value':_0x3709b9(0x121)},..._0x9cd92b['map'](_0x4a933d=>({'name':_0x4a933d[_0x3709b9(0x136)]+'\x20\x20'+a38_0x1ebc08['gray']('('+_0x4a933d['appCode']+')'),'value':_0x4a933d[_0x3709b9(0x110)]}))],_0xb1d855=await select({'message':_0x3709b9(0x114),'choices':_0x34ac88});if(_0xb1d855==='skip')return _0x3709b9(0x129);if(_0xb1d855===_0x3709b9(0x121))return'custom';return _0x9cd92b[_0x3709b9(0x12d)](_0x54c9ef=>_0x54c9ef[_0x3709b9(0x110)]===_0xb1d855);}function a38_0x50c6(_0x209f67,_0x56ff20){_0x209f67=_0x209f67-0x10d;const _0x42d44b=a38_0x42d4();let _0x50c6a0=_0x42d44b[_0x209f67];return _0x50c6a0;}export async function selectSingleAppcode(_0x5a92dc){const _0x10a86d=a38_0x50c6;if(!_0x5a92dc)return writeCliSideChannelLine(a38_0x1ebc08[_0x10a86d(0x11d)](_0x10a86d(0x137))),_fallbackOrSkip();writeCliSideChannelLine(_0x10a86d(0x128));let _0x44d433;try{_0x44d433=await withActiveCookie(_0x5a92dc,()=>listRemoteApps());}catch(_0x5da23d){writeCliSideChannelLine(a38_0x1ebc08[_0x10a86d(0x116)](_0x10a86d(0x134)));if(_0x5da23d instanceof Error)writeCliSideChannelLine(a38_0x1ebc08['gray'](_0x10a86d(0x12e)+_0x5da23d[_0x10a86d(0x130)]+')'));return _fallbackOrSkip();}if(_0x44d433['length']===0x0)return writeCliSideChannelLine(a38_0x1ebc08[_0x10a86d(0x116)](_0x10a86d(0x124))),_fallbackOrSkip();const _0x27e175=await promptSingleAppSelection(_0x44d433);if(_0x27e175==='skip')return'';if(_0x27e175===_0x10a86d(0x121))return promptCustomAppcode();return _0x27e175[_0x10a86d(0x110)];}export async function selectMultipleApps(_0xf80dba){const _0x516ac2=a38_0x50c6;writeCliSideChannelLine(_0x516ac2(0x128));let _0x2dd5ae;try{_0x2dd5ae=await withActiveCookie(_0xf80dba,()=>listRemoteApps());}catch(_0x3eb808){writeCliSideChannelLine(_0x516ac2(0x10f));if(_0x3eb808 instanceof Error)writeCliSideChannelLine(_0x516ac2(0x12e)+_0x3eb808[_0x516ac2(0x130)]+')');return _0x516ac2(0x121);}if(_0x2dd5ae[_0x516ac2(0x11b)]===0x0)return writeCliSideChannelLine(_0x516ac2(0x111)),'custom';return promptAppSelection(_0x2dd5ae);}async function _fallbackOrSkip(){const _0x22eddd=a38_0x50c6,_0xa63149=await select({'message':'App\x20Code:','choices':[{'name':a38_0x1ebc08['gray'](_0x22eddd(0x120)),'value':_0x22eddd(0x129)},{'name':a38_0x1ebc08[_0x22eddd(0x116)](_0x22eddd(0x135)),'value':_0x22eddd(0x127)}]});if(_0xa63149==='skip')return'';return promptCustomAppcode();}
@@ -1 +1 @@
1
- const a39_0xcafc55=a39_0x20aa;(function(_0x295dbb,_0x3b1767){const _0xc495f=a39_0x20aa,_0x194c76=_0x295dbb();while(!![]){try{const _0x455471=parseInt(_0xc495f(0xf4))/0x1*(parseInt(_0xc495f(0xf5))/0x2)+-parseInt(_0xc495f(0xeb))/0x3*(parseInt(_0xc495f(0xe9))/0x4)+parseInt(_0xc495f(0xf3))/0x5*(parseInt(_0xc495f(0xee))/0x6)+-parseInt(_0xc495f(0xe3))/0x7+parseInt(_0xc495f(0xec))/0x8*(parseInt(_0xc495f(0xf9))/0x9)+parseInt(_0xc495f(0xe2))/0xa*(-parseInt(_0xc495f(0xe4))/0xb)+parseInt(_0xc495f(0xf7))/0xc;if(_0x455471===_0x3b1767)break;else _0x194c76['push'](_0x194c76['shift']());}catch(_0x953273){_0x194c76['push'](_0x194c76['shift']());}}}(a39_0x31c0,0xa2b8b));export const DATASET_CODE_PATTERN={'regex':/^[a-f0-9]{32}$/i,'description':a39_0xcafc55(0xe0)};export const CODE_FLAG={'name':'code','type':'string','required':!![],'description':a39_0xcafc55(0xea),'pattern':DATASET_CODE_PATTERN};export const CODE_FLAG_OPTIONAL={...CODE_FLAG,'required':![]};function a39_0x31c0(){const _0x1a8b5e=['3576iCzqSj','appcode','SQL\x20code\x20identifier\x20(format:\x20xxxxxxxx-xxxxxxxx,\x20e.g.\x202305f915-dd48cd4c)','Database\x20connection\x20ID\x20(dblink\x20id\x20from\x20db\x20list)','App\x20code\x20(overrides\x20config\x20file,\x20e.g.\x20app-xxxxx)','1685omNkJJ','347278jNnbPf','2OVRjae','sqlcode','29624832nVnBvD','MYSQL','456507PdHAUo','a\x2032-character\x20hex\x20string\x20(e.g.\x2099a909313f1fa7153186431e1c551588)','dbtype','50zbdsaX','5553324iHNktB','2857261iOXWuN','Database\x20product\x20type','number','SQL\x20code\x20in\x20format\x20xxxxxxxx-xxxxxxxx\x20(e.g.\x202305f915-dd48cd4c)','POSTGRESQL','1438872ZzkAMg','Dataset\x20code\x20(32-char\x20hex\x20UUID)','3cmbInv','16WIUeJO','string'];a39_0x31c0=function(){return _0x1a8b5e;};return a39_0x31c0();}export const DATASETCODE_FLAG_OPTIONAL={...CODE_FLAG_OPTIONAL,'name':'datasetcode','description':a39_0xcafc55(0xea)};export const SQLCODE_FLAG={'name':a39_0xcafc55(0xf6),'type':a39_0xcafc55(0xed),'required':!![],'description':a39_0xcafc55(0xf0),'pattern':{'regex':/^[a-f0-9]{8}-[a-f0-9]{8}$/i,'description':a39_0xcafc55(0xe7)}};export const APPCODE_FLAG_OPTIONAL={'name':a39_0xcafc55(0xef),'type':a39_0xcafc55(0xed),'required':![],'description':a39_0xcafc55(0xf2)};export const SQLCODE_FLAG_OPTIONAL={...SQLCODE_FLAG,'required':![]};export const DBLINK_ID_FLAG={'name':'id','type':a39_0xcafc55(0xe6),'required':!![],'description':a39_0xcafc55(0xf1)};function a39_0x20aa(_0x30aae5,_0xd1e0d0){_0x30aae5=_0x30aae5-0xe0;const _0x31c080=a39_0x31c0();let _0x20aa7f=_0x31c080[_0x30aae5];return _0x20aa7f;}export const DB_TYPE_FLAG={'name':a39_0xcafc55(0xe1),'type':a39_0xcafc55(0xed),'required':!![],'description':a39_0xcafc55(0xe5),'enum':[a39_0xcafc55(0xf8),a39_0xcafc55(0xe8)]};
1
+ const a39_0x1ae5fa=a39_0x5497;(function(_0x2356fb,_0x1e1a14){const _0x53bfa1=a39_0x5497,_0x447350=_0x2356fb();while(!![]){try{const _0x5e3199=-parseInt(_0x53bfa1(0x1f8))/0x1+parseInt(_0x53bfa1(0x1fc))/0x2+-parseInt(_0x53bfa1(0x20a))/0x3*(-parseInt(_0x53bfa1(0x1f5))/0x4)+parseInt(_0x53bfa1(0x204))/0x5*(parseInt(_0x53bfa1(0x1fd))/0x6)+parseInt(_0x53bfa1(0x1fa))/0x7+parseInt(_0x53bfa1(0x208))/0x8+parseInt(_0x53bfa1(0x1fb))/0x9*(-parseInt(_0x53bfa1(0x1f7))/0xa);if(_0x5e3199===_0x1e1a14)break;else _0x447350['push'](_0x447350['shift']());}catch(_0x4db552){_0x447350['push'](_0x447350['shift']());}}}(a39_0x4224,0x4d35c));export const DATASET_CODE_PATTERN={'regex':/^[a-f0-9]{32}$/i,'description':a39_0x1ae5fa(0x200)};export const CODE_FLAG={'name':a39_0x1ae5fa(0x1f4),'type':a39_0x1ae5fa(0x1f9),'required':!![],'description':a39_0x1ae5fa(0x1f6),'pattern':DATASET_CODE_PATTERN};export const CODE_FLAG_OPTIONAL={...CODE_FLAG,'required':![]};function a39_0x4224(){const _0x555ba0=['3269896wzHGbt','POSTGRESQL','1737rADHvR','appcode','datasetcode','MYSQL','code','1856apYwRH','Dataset\x20code\x20(32-char\x20hex\x20UUID)','1110oHeiRY','547794CViegJ','string','3917697NagtUh','42723sESnTP','155096FFyVRR','3786SpXSxZ','Database\x20connection\x20ID\x20(dblink\x20id\x20from\x20db\x20list)','SQL\x20code\x20in\x20format\x20xxxxxxxx-xxxxxxxx\x20(e.g.\x202305f915-dd48cd4c)','a\x2032-character\x20hex\x20string\x20(e.g.\x2099a909313f1fa7153186431e1c551588)','sqlcode','dbtype','SQL\x20code\x20identifier\x20(format:\x20xxxxxxxx-xxxxxxxx,\x20e.g.\x202305f915-dd48cd4c)','605JnusQZ','number','App\x20code\x20(overrides\x20config\x20file,\x20e.g.\x20app-xxxxx)','Database\x20product\x20type'];a39_0x4224=function(){return _0x555ba0;};return a39_0x4224();}export const DATASETCODE_FLAG_OPTIONAL={...CODE_FLAG_OPTIONAL,'name':a39_0x1ae5fa(0x1f2),'description':a39_0x1ae5fa(0x1f6)};export const SQLCODE_FLAG={'name':a39_0x1ae5fa(0x201),'type':a39_0x1ae5fa(0x1f9),'required':!![],'description':a39_0x1ae5fa(0x203),'pattern':{'regex':/^[a-f0-9]{8}-[a-f0-9]{8}$/i,'description':a39_0x1ae5fa(0x1ff)}};export const APPCODE_FLAG_OPTIONAL={'name':a39_0x1ae5fa(0x1f1),'type':'string','required':![],'description':a39_0x1ae5fa(0x206)};export const SQLCODE_FLAG_OPTIONAL={...SQLCODE_FLAG,'required':![]};function a39_0x5497(_0x2f3cef,_0xd8d6ed){_0x2f3cef=_0x2f3cef-0x1f1;const _0x4224ab=a39_0x4224();let _0x549783=_0x4224ab[_0x2f3cef];return _0x549783;}export const DBLINK_ID_FLAG={'name':'id','type':a39_0x1ae5fa(0x205),'required':!![],'description':a39_0x1ae5fa(0x1fe)};export const DB_TYPE_FLAG={'name':a39_0x1ae5fa(0x202),'type':a39_0x1ae5fa(0x1f9),'required':!![],'description':a39_0x1ae5fa(0x207),'enum':[a39_0x1ae5fa(0x1f3),a39_0x1ae5fa(0x209)]};
@@ -1 +1 @@
1
- function a40_0x2d77(){const _0x10b2b3=['App\x20Code\x20cannot\x20exceed\x20100\x20characters','78RkwXuy','App\x20Code\x20cannot\x20be\x20empty','102188JCXjPF','1386045KGxJEx','1572580AQqZVY','678832upgykW','48NkRAhC','Only\x20letters,\x20numbers,\x20-\x20and\x20_\x20are\x20allowed','13326vpHQIs','7PMtaRB','24ItqZms','trim','2751199rAbskO','1287258CsdXJu','test','length','72JwpUAG'];a40_0x2d77=function(){return _0x10b2b3;};return a40_0x2d77();}(function(_0xff540b,_0x44cc27){const _0x4feff2=a40_0x2699,_0x530de7=_0xff540b();while(!![]){try{const _0x4e2813=parseInt(_0x4feff2(0x1b2))/0x1*(parseInt(_0x4feff2(0x1a8))/0x2)+-parseInt(_0x4feff2(0x1a6))/0x3*(-parseInt(_0x4feff2(0x1b4))/0x4)+-parseInt(_0x4feff2(0x1b5))/0x5+-parseInt(_0x4feff2(0x1ad))/0x6*(parseInt(_0x4feff2(0x1a9))/0x7)+-parseInt(_0x4feff2(0x1a5))/0x8*(-parseInt(_0x4feff2(0x1b0))/0x9)+-parseInt(_0x4feff2(0x1a4))/0xa+parseInt(_0x4feff2(0x1ac))/0xb*(-parseInt(_0x4feff2(0x1aa))/0xc);if(_0x4e2813===_0x44cc27)break;else _0x530de7['push'](_0x530de7['shift']());}catch(_0x1e2739){_0x530de7['push'](_0x530de7['shift']());}}}(a40_0x2d77,0x6fd56));function a40_0x2699(_0x5d08aa,_0x4fd472){_0x5d08aa=_0x5d08aa-0x1a4;const _0x2d7721=a40_0x2d77();let _0x26997e=_0x2d7721[_0x5d08aa];return _0x26997e;}export function validateAppcode(_0x5888c2){const _0x59f805=a40_0x2699,_0x48e4a9=_0x5888c2[_0x59f805(0x1ab)]();if(!_0x48e4a9)return{'valid':![],'message':_0x59f805(0x1b3)};if(_0x48e4a9[_0x59f805(0x1af)]>0x64)return{'valid':![],'message':_0x59f805(0x1b1)};if(!/^[A-Za-z0-9_-]+$/[_0x59f805(0x1ae)](_0x48e4a9))return{'valid':![],'message':_0x59f805(0x1a7)};return{'valid':!![]};}
1
+ (function(_0x2a6a84,_0x5752b5){const _0x23ed7c=a40_0x1e98,_0x546218=_0x2a6a84();while(!![]){try{const _0x1e8b2e=parseInt(_0x23ed7c(0x13c))/0x1*(-parseInt(_0x23ed7c(0x13d))/0x2)+parseInt(_0x23ed7c(0x134))/0x3*(parseInt(_0x23ed7c(0x140))/0x4)+parseInt(_0x23ed7c(0x135))/0x5+parseInt(_0x23ed7c(0x144))/0x6*(-parseInt(_0x23ed7c(0x136))/0x7)+parseInt(_0x23ed7c(0x139))/0x8+parseInt(_0x23ed7c(0x141))/0x9*(-parseInt(_0x23ed7c(0x142))/0xa)+parseInt(_0x23ed7c(0x13a))/0xb*(parseInt(_0x23ed7c(0x137))/0xc);if(_0x1e8b2e===_0x5752b5)break;else _0x546218['push'](_0x546218['shift']());}catch(_0x8a1220){_0x546218['push'](_0x546218['shift']());}}}(a40_0x14a1,0xf0232));function a40_0x1e98(_0x55fbd7,_0x179ca9){_0x55fbd7=_0x55fbd7-0x134;const _0x14a1e2=a40_0x14a1();let _0x1e9888=_0x14a1e2[_0x55fbd7];return _0x1e9888;}export function validateAppcode(_0x51631b){const _0x37776a=a40_0x1e98,_0x398649=_0x51631b['trim']();if(!_0x398649)return{'valid':![],'message':_0x37776a(0x13f)};if(_0x398649[_0x37776a(0x13e)]>0x64)return{'valid':![],'message':_0x37776a(0x143)};if(!/^[A-Za-z0-9_-]+$/[_0x37776a(0x138)](_0x398649))return{'valid':![],'message':_0x37776a(0x13b)};return{'valid':!![]};}function a40_0x14a1(){const _0x3c94be=['44sapnah','36YPxOwM','4273770zsIsDc','App\x20Code\x20cannot\x20exceed\x20100\x20characters','6uxOKQI','395808enONWN','4409970MHRGJI','12050255lZyqHe','24vTfFmG','test','14356784ZKbNyl','5992712mwNfZI','Only\x20letters,\x20numbers,\x20-\x20and\x20_\x20are\x20allowed','1nbivyS','1605794wJROpR','length','App\x20Code\x20cannot\x20be\x20empty'];a40_0x14a1=function(){return _0x3c94be;};return a40_0x14a1();}
@@ -1 +1 @@
1
- function a41_0x4fe9(){const _0x24b720=['appcode','Usage:\x20','\x20config\x20get\x20--key\x20<key>','3RHCKxD','61144RuCTIC','1341gawlxp','29416cERpvT','read','323367LeBcXg','validation','832480yYkHXr','app','Key\x20not\x20found:\x20','155kHSrHH','string','get','Get\x20a\x20config\x20value\x20by\x20key','1621634wMrUXS','33124XpyFmV','1678164KLhYli','key','Missing\x20key.'];a41_0x4fe9=function(){return _0x24b720;};return a41_0x4fe9();}const a41_0x1a6b2c=a41_0x5c2c;(function(_0xad99fb,_0x6a4dad){const _0x5de0af=a41_0x5c2c,_0x2d9e36=_0xad99fb();while(!![]){try{const _0x16c04d=-parseInt(_0x5de0af(0x1a6))/0x1*(-parseInt(_0x5de0af(0x1a7))/0x2)+parseInt(_0x5de0af(0x1ab))/0x3+parseInt(_0x5de0af(0x1b5))/0x4*(parseInt(_0x5de0af(0x1b0))/0x5)+parseInt(_0x5de0af(0x1b6))/0x6+parseInt(_0x5de0af(0x1b4))/0x7+-parseInt(_0x5de0af(0x1a9))/0x8*(parseInt(_0x5de0af(0x1a8))/0x9)+-parseInt(_0x5de0af(0x1ad))/0xa;if(_0x16c04d===_0x6a4dad)break;else _0x2d9e36['push'](_0x2d9e36['shift']());}catch(_0x486a83){_0x2d9e36['push'](_0x2d9e36['shift']());}}}(a41_0x4fe9,0x52243));import{CliErrors}from'../../errors.js';function a41_0x5c2c(_0x585822,_0xd6b685){_0x585822=_0x585822-0x1a4;const _0x4fe9df=a41_0x4fe9();let _0x5c2cd7=_0x4fe9df[_0x585822];return _0x5c2cd7;}import{readConfig}from'../../utils/config.js';import{CLI_BIN_NAME}from'../../constant/cli.js';import{getConfigCommandKeyDescription}from'../../commands/config/shared.js';async function execute(_0x4ded74){const _0x22d45b=a41_0x5c2c,_0x475ba5=_0x4ded74['str'](_0x22d45b(0x1b7));if(!_0x475ba5)throw CliErrors[_0x22d45b(0x1ac)](_0x22d45b(0x1b8),_0x22d45b(0x1a4)+CLI_BIN_NAME+_0x22d45b(0x1a5));const _0x36b8d8=readConfig(),_0x394c5e=_0x475ba5===_0x22d45b(0x1ae)?_0x22d45b(0x1b9):_0x475ba5,_0x55c39f=_0x36b8d8[_0x394c5e];if(_0x55c39f===undefined)throw CliErrors[_0x22d45b(0x1ac)](_0x22d45b(0x1af)+_0x475ba5);return{'ok':!![],'data':typeof _0x55c39f==='object'?_0x55c39f:{[_0x394c5e]:_0x55c39f},'message':typeof _0x55c39f==='object'?undefined:String(_0x55c39f)};}export const configGetDefinition={'service':'config','command':a41_0x1a6b2c(0x1b2),'description':a41_0x1a6b2c(0x1b3),'risk':a41_0x1a6b2c(0x1aa),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a41_0x1a6b2c(0x1b7),'type':a41_0x1a6b2c(0x1b1),'description':getConfigCommandKeyDescription(),'required':!![]}],'execute':execute};
1
+ const a41_0xf877c6=a41_0x4fa5;(function(_0x4f720c,_0x3fa033){const _0x170573=a41_0x4fa5,_0x2bb33b=_0x4f720c();while(!![]){try{const _0x18d1a9=-parseInt(_0x170573(0x9d))/0x1+-parseInt(_0x170573(0x97))/0x2+-parseInt(_0x170573(0x95))/0x3+-parseInt(_0x170573(0x99))/0x4+-parseInt(_0x170573(0x9b))/0x5+-parseInt(_0x170573(0x9f))/0x6*(parseInt(_0x170573(0x94))/0x7)+parseInt(_0x170573(0xa1))/0x8;if(_0x18d1a9===_0x3fa033)break;else _0x2bb33b['push'](_0x2bb33b['shift']());}catch(_0x1d457b){_0x2bb33b['push'](_0x2bb33b['shift']());}}}(a41_0x28ac,0xd77ca));import{CliErrors}from'../../errors.js';import{readConfig}from'../../utils/config.js';import{CLI_BIN_NAME}from'../../constant/cli.js';function a41_0x4fa5(_0x4d2087,_0x987913){_0x4d2087=_0x4d2087-0x90;const _0x28acd7=a41_0x28ac();let _0x4fa5e3=_0x28acd7[_0x4d2087];return _0x4fa5e3;}function a41_0x28ac(){const _0x253c5a=['Usage:\x20','app','Get\x20a\x20config\x20value\x20by\x20key','object','133QdhsnA','1289385UgYTFE','string','122584HYyDVS','key','1197500NVJrHa','config','8431645PQpyqZ','validation','584857LUfTrF','\x20config\x20get\x20--key\x20<key>','541092BCgkfD','Missing\x20key.','45261920FsveVo','Key\x20not\x20found:\x20'];a41_0x28ac=function(){return _0x253c5a;};return a41_0x28ac();}import{getConfigCommandKeyDescription}from'../../commands/config/shared.js';async function execute(_0x32076c){const _0xed16=a41_0x4fa5,_0x116b92=_0x32076c['str'](_0xed16(0x98));if(!_0x116b92)throw CliErrors[_0xed16(0x9c)](_0xed16(0xa0),_0xed16(0x90)+CLI_BIN_NAME+_0xed16(0x9e));const _0xf66e3d=readConfig(),_0x458f01=_0x116b92===_0xed16(0x91)?'appcode':_0x116b92,_0x26b029=_0xf66e3d[_0x458f01];if(_0x26b029===undefined)throw CliErrors[_0xed16(0x9c)](_0xed16(0xa2)+_0x116b92);return{'ok':!![],'data':typeof _0x26b029===_0xed16(0x93)?_0x26b029:{[_0x458f01]:_0x26b029},'message':typeof _0x26b029===_0xed16(0x93)?undefined:String(_0x26b029)};}export const configGetDefinition={'service':a41_0xf877c6(0x9a),'command':'get','description':a41_0xf877c6(0x92),'risk':'read','requiresAuth':![],'requiresAppCode':![],'flags':[{'name':'key','type':a41_0xf877c6(0x96),'description':getConfigCommandKeyDescription(),'required':!![]}],'execute':execute};
@@ -1 +1 @@
1
- (function(_0x201d82,_0x4ee890){const _0x2af110=a42_0x1190,_0x449d9e=_0x201d82();while(!![]){try{const _0x55a3e9=parseInt(_0x2af110(0x8d))/0x1+parseInt(_0x2af110(0x93))/0x2*(-parseInt(_0x2af110(0x8b))/0x3)+parseInt(_0x2af110(0x92))/0x4*(parseInt(_0x2af110(0x8e))/0x5)+-parseInt(_0x2af110(0x91))/0x6+parseInt(_0x2af110(0x90))/0x7*(parseInt(_0x2af110(0x8f))/0x8)+parseInt(_0x2af110(0x8a))/0x9+parseInt(_0x2af110(0x8c))/0xa*(-parseInt(_0x2af110(0x94))/0xb);if(_0x55a3e9===_0x4ee890)break;else _0x449d9e['push'](_0x449d9e['shift']());}catch(_0x283b9f){_0x449d9e['push'](_0x449d9e['shift']());}}}(a42_0x457f,0x2cc68));import{configListDefinition}from'../../commands/config/list.js';import{configGetDefinition}from'../../commands/config/get.js';function a42_0x1190(_0x151272,_0x64f596){_0x151272=_0x151272-0x8a;const _0x457f41=a42_0x457f();let _0x11900d=_0x457f41[_0x151272];return _0x11900d;}import{configSetDefinition}from'../../commands/config/set.js';function a42_0x457f(){const _0x287e18=['60697ynnCOX','223146MsHhcd','2792stkxnj','16770gdPrLD','715ThntSo','2346219xLFNjl','78AjwUTU','92890OwLVSE','346396NxdRQh','820NxzLWG','296nBWgkL'];a42_0x457f=function(){return _0x287e18;};return a42_0x457f();}export const configDefinitions=[configListDefinition,configGetDefinition,configSetDefinition];
1
+ (function(_0x3ab3f3,_0x19590f){const _0x3c2884=a42_0x15ac,_0x4d86af=_0x3ab3f3();while(!![]){try{const _0x594a5e=-parseInt(_0x3c2884(0x18c))/0x1*(parseInt(_0x3c2884(0x18f))/0x2)+parseInt(_0x3c2884(0x18a))/0x3*(parseInt(_0x3c2884(0x18b))/0x4)+-parseInt(_0x3c2884(0x18e))/0x5*(parseInt(_0x3c2884(0x18d))/0x6)+-parseInt(_0x3c2884(0x187))/0x7+-parseInt(_0x3c2884(0x190))/0x8+-parseInt(_0x3c2884(0x189))/0x9+parseInt(_0x3c2884(0x186))/0xa*(parseInt(_0x3c2884(0x188))/0xb);if(_0x594a5e===_0x19590f)break;else _0x4d86af['push'](_0x4d86af['shift']());}catch(_0x14412b){_0x4d86af['push'](_0x4d86af['shift']());}}}(a42_0x4533,0x53b93));import{configListDefinition}from'../../commands/config/list.js';function a42_0x15ac(_0x273acc,_0x2d2af3){_0x273acc=_0x273acc-0x186;const _0x45330d=a42_0x4533();let _0x15ac3=_0x45330d[_0x273acc];return _0x15ac3;}import{configGetDefinition}from'../../commands/config/get.js';function a42_0x4533(){const _0x4d470c=['40VqgSzj','11574aFkepL','1861608oALFxx','90JGguDU','4176389bbmKZy','2167506SSRqaw','1988739JdJghW','4281uOYmqu','52TgOODm','37pKyMar','138462fAjtvr'];a42_0x4533=function(){return _0x4d470c;};return a42_0x4533();}import{configSetDefinition}from'../../commands/config/set.js';export const configDefinitions=[configListDefinition,configGetDefinition,configSetDefinition];
@@ -1 +1 @@
1
- function a43_0x56d6(_0x22aeb0,_0x81c319){_0x22aeb0=_0x22aeb0-0x17c;const _0x1a402e=a43_0x1a40();let _0x56d628=_0x1a402e[_0x22aeb0];return _0x56d628;}function a43_0x1a40(){const _0x14f347=['3181876bFsJLC','global','309kxQypB','8cWXuVq','402437RJhEVc','225245bJQGAH','18HpVCKn','15509748RHbKXR','4210269DQqFOu','105615EwLHOQ','350vWJtHX','7366bPqYVi','List\x20all\x20config\x20values','11GVOFiK','read','bool','list'];a43_0x1a40=function(){return _0x14f347;};return a43_0x1a40();}const a43_0x27be80=a43_0x56d6;(function(_0x45de88,_0x38318a){const _0x5a9e22=a43_0x56d6,_0x527aed=_0x45de88();while(!![]){try{const _0x254f28=parseInt(_0x5a9e22(0x187))/0x1+-parseInt(_0x5a9e22(0x17d))/0x2*(-parseInt(_0x5a9e22(0x185))/0x3)+-parseInt(_0x5a9e22(0x183))/0x4+-parseInt(_0x5a9e22(0x188))/0x5*(-parseInt(_0x5a9e22(0x189))/0x6)+-parseInt(_0x5a9e22(0x18b))/0x7*(parseInt(_0x5a9e22(0x186))/0x8)+parseInt(_0x5a9e22(0x18c))/0x9*(-parseInt(_0x5a9e22(0x17c))/0xa)+-parseInt(_0x5a9e22(0x17f))/0xb*(-parseInt(_0x5a9e22(0x18a))/0xc);if(_0x254f28===_0x38318a)break;else _0x527aed['push'](_0x527aed['shift']());}catch(_0x57fb23){_0x527aed['push'](_0x527aed['shift']());}}}(a43_0x1a40,0x62157));import{readScopedConfig}from'../../commands/config/shared.js';import{readConfig}from'../../utils/config.js';async function execute(_0x455cf5){const _0x40edc5=a43_0x56d6,_0x4dcc43=_0x455cf5[_0x40edc5(0x181)](_0x40edc5(0x184))?readScopedConfig(_0x40edc5(0x184)):readConfig();return{'ok':!![],'data':_0x4dcc43};}export const configListDefinition={'service':'config','command':a43_0x27be80(0x182),'description':a43_0x27be80(0x17e),'risk':a43_0x27be80(0x180),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a43_0x27be80(0x184),'type':'boolean','description':'Show\x20global\x20config\x20only\x20(~/.rabetbase.json)','default':![]}],'execute':execute};
1
+ const a43_0x16e26a=a43_0x4fbd;(function(_0x54d9ba,_0x3cbfe3){const _0x2b691e=a43_0x4fbd,_0x6bfb15=_0x54d9ba();while(!![]){try{const _0x2c244b=-parseInt(_0x2b691e(0x17b))/0x1+parseInt(_0x2b691e(0x176))/0x2+parseInt(_0x2b691e(0x17d))/0x3*(parseInt(_0x2b691e(0x180))/0x4)+parseInt(_0x2b691e(0x182))/0x5+parseInt(_0x2b691e(0x17f))/0x6*(-parseInt(_0x2b691e(0x178))/0x7)+-parseInt(_0x2b691e(0x181))/0x8*(-parseInt(_0x2b691e(0x179))/0x9)+parseInt(_0x2b691e(0x17e))/0xa;if(_0x2c244b===_0x3cbfe3)break;else _0x6bfb15['push'](_0x6bfb15['shift']());}catch(_0x76d74){_0x6bfb15['push'](_0x6bfb15['shift']());}}}(a43_0x2c74,0x6f1ec));import{readScopedConfig}from'../../commands/config/shared.js';function a43_0x2c74(){const _0x3032ff=['3435948VCdlbN','532232Qjqocq','2527955IadXHW','List\x20all\x20config\x20values','global','106896RrpCIz','Show\x20global\x20config\x20only\x20(~/.rabetbase.json)','7BtKcTY','36mzPGBl','bool','430314TcHXUg','read','3LmuYMJ','1053360jFpHEK','5424096dyhxDE'];a43_0x2c74=function(){return _0x3032ff;};return a43_0x2c74();}import{readConfig}from'../../utils/config.js';function a43_0x4fbd(_0x103a70,_0x11fef4){_0x103a70=_0x103a70-0x175;const _0x2c74fa=a43_0x2c74();let _0x4fbda5=_0x2c74fa[_0x103a70];return _0x4fbda5;}async function execute(_0x1c5156){const _0x58ead7=a43_0x4fbd,_0x417306=_0x1c5156[_0x58ead7(0x17a)](_0x58ead7(0x175))?readScopedConfig('global'):readConfig();return{'ok':!![],'data':_0x417306};}export const configListDefinition={'service':'config','command':'list','description':a43_0x16e26a(0x183),'risk':a43_0x16e26a(0x17c),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a43_0x16e26a(0x175),'type':'boolean','description':a43_0x16e26a(0x177),'default':![]}],'execute':execute};
@@ -1 +1 @@
1
- function a44_0x8106(_0x4349c5,_0x1e0ff0){_0x4349c5=_0x4349c5-0x1b9;const _0x3128e7=a44_0x3128();let _0x810665=_0x3128e7[_0x4349c5];return _0x810665;}function a44_0x3128(){const _0xb1eade=['1209800sglRQq','3778SENmTH','Global','Use\x20`','boolean','\x22.\x20Allowed:\x20','value','3086376WeiUsW','bool','Supported:\x20zh,\x20en,\x20zh-CN,\x20en-US','appcode','\x22\x20is\x20not\x20settable.','join','app','keys','Config\x20value','Usage:\x20','\x20appcode\x20set\x20to:\x20','Invalid\x20value\x20for\x20\x22','object','string','309EZnvzx','3680061Gswfsg','2340365btXsaj','apps','locale','global','validation','Missing\x20value.','Legacy\x20alias\x20\x22online\x22\x20is\x20accepted\x20and\x20stored\x20as\x20production.','Invalid\x20value\x20for\x20env.\x20Allowed:\x20production,\x20daily.','2961933qkxMRo','Missing\x20key.','6IOesuC','includes','\x22riskLevel\x22\x20cannot\x20be\x20changed\x20via\x20the\x20CLI.','\x20app\x20use\x20<name>`,\x20or\x20pass\x20`--appcode`\x20on\x20the\x20command.','set','key','str','\x20(stored\x20as\x20apps\x20+\x20defaultApp)','write','`,\x20`','config','\x20app\x20add\x20<name>\x20--appcode\x20','\x20config\x20set\x20--key\x20<key>\x20--value\x20<value>','env','2627316YvAhYl','Project'];a44_0x3128=function(){return _0xb1eade;};return a44_0x3128();}const a44_0x569890=a44_0x8106;(function(_0x41de15,_0x753077){const _0x44ca99=a44_0x8106,_0x9f9e10=_0x41de15();while(!![]){try{const _0x68fc05=-parseInt(_0x44ca99(0x1c0))/0x1*(-parseInt(_0x44ca99(0x1dd))/0x2)+-parseInt(_0x44ca99(0x1ca))/0x3+parseInt(_0x44ca99(0x1dc))/0x4+parseInt(_0x44ca99(0x1c2))/0x5*(-parseInt(_0x44ca99(0x1cc))/0x6)+parseInt(_0x44ca99(0x1c1))/0x7+parseInt(_0x44ca99(0x1e3))/0x8+parseInt(_0x44ca99(0x1da))/0x9;if(_0x68fc05===_0x753077)break;else _0x9f9e10['push'](_0x9f9e10['shift']());}catch(_0x26a05d){_0x9f9e10['push'](_0x9f9e10['shift']());}}}(a44_0x3128,0x9ad63));import{CliErrors}from'../../errors.js';import{buildCanonicalProjectConfig}from'../../config/schema.js';import{CLI_BIN_NAME,CONFIG_ENUM_VALUES,getConfigCommandKeyDescription,getTopLevelConfigKeySummary,isTopLevelConfigKey,normalizeLocale,resolveWriteScope,readScopedConfig,writeScopedConfig}from'../../commands/config/shared.js';import{normalizeEnv,isProduction,isDaily}from'../../constant/env.js';async function execute(_0x46d3a3){const _0x387e63=a44_0x8106,_0x35fa17=_0x46d3a3[_0x387e63(0x1d2)]('key'),_0x220627=_0x46d3a3[_0x387e63(0x1d2)](_0x387e63(0x1e2));if(!_0x35fa17)throw CliErrors['validation'](_0x387e63(0x1cb),_0x387e63(0x1bb)+CLI_BIN_NAME+'\x20config\x20set\x20--key\x20<key>\x20--value\x20<value>');if(_0x220627===undefined||_0x220627==='')throw CliErrors[_0x387e63(0x1c6)](_0x387e63(0x1c7),_0x387e63(0x1bb)+CLI_BIN_NAME+_0x387e63(0x1d8));if(_0x220627['length']>0x1f4)throw CliErrors[_0x387e63(0x1c6)]('Config\x20value\x20is\x20invalid\x20or\x20too\x20long.');if(!isTopLevelConfigKey(_0x35fa17))throw CliErrors[_0x387e63(0x1c6)]('Top-level\x20key\x20\x22'+_0x35fa17+_0x387e63(0x1e7),'Settable\x20top-level\x20keys:\x20'+getTopLevelConfigKeySummary());if(_0x35fa17==='riskLevel')throw CliErrors[_0x387e63(0x1c6)](_0x387e63(0x1ce));if(CONFIG_ENUM_VALUES[_0x35fa17]&&!CONFIG_ENUM_VALUES[_0x35fa17][_0x387e63(0x1cd)](_0x220627))throw CliErrors[_0x387e63(0x1c6)](_0x387e63(0x1bd)+_0x35fa17+_0x387e63(0x1e1)+CONFIG_ENUM_VALUES[_0x35fa17][_0x387e63(0x1e8)](',\x20'));if(_0x35fa17===_0x387e63(0x1c4)&&!normalizeLocale(_0x220627))throw CliErrors[_0x387e63(0x1c6)]('Invalid\x20locale\x20value.',_0x387e63(0x1e5));const _0x32e436={'global':_0x46d3a3[_0x387e63(0x1e4)]('global')},_0x35ced9=resolveWriteScope(_0x32e436),_0x29c0fd=readScopedConfig(_0x35ced9);let _0x1ea943=_0x35fa17,_0x41bbd3=_0x220627;_0x35fa17==='app'&&(_0x1ea943=_0x387e63(0x1e6),delete _0x29c0fd[_0x387e63(0x1e9)]);_0x35fa17===_0x387e63(0x1c4)&&(_0x41bbd3=normalizeLocale(_0x220627));if(_0x35fa17===_0x387e63(0x1d9)){_0x41bbd3=normalizeEnv(_0x220627);if(!isProduction(_0x41bbd3)&&!isDaily(_0x41bbd3))throw CliErrors[_0x387e63(0x1c6)](_0x387e63(0x1c9),_0x387e63(0x1c8));}if(_0x35fa17===_0x387e63(0x1e6)){const _0x1fcb2c=_0x29c0fd['apps']&&typeof _0x29c0fd[_0x387e63(0x1c3)]===_0x387e63(0x1be)?Object[_0x387e63(0x1b9)](_0x29c0fd['apps']):[];if(_0x1fcb2c['length']>0x0)throw CliErrors[_0x387e63(0x1c6)]('Cannot\x20set\x20top-level\x20\x22appcode\x22\x20when\x20multi-app\x20config\x20already\x20exists.',_0x387e63(0x1df)+CLI_BIN_NAME+_0x387e63(0x1d7)+_0x41bbd3+_0x387e63(0x1d5)+CLI_BIN_NAME+_0x387e63(0x1cf));const _0x561fe9=buildCanonicalProjectConfig({..._0x29c0fd},{'appCodes':[_0x41bbd3],'env':typeof _0x29c0fd[_0x387e63(0x1d9)]==='string'?_0x29c0fd['env']:undefined});writeScopedConfig(_0x561fe9,_0x35ced9);const _0x43ed6f=_0x35ced9===_0x387e63(0x1c5)?_0x387e63(0x1de):_0x387e63(0x1db);return{'ok':!![],'message':'✓\x20'+_0x43ed6f+_0x387e63(0x1bc)+_0x41bbd3+_0x387e63(0x1d3)};}_0x29c0fd[_0x1ea943]=_0x41bbd3,writeScopedConfig(_0x29c0fd,_0x35ced9);const _0x4ce96a=_0x35ced9===_0x387e63(0x1c5)?_0x387e63(0x1de):_0x387e63(0x1db);return{'ok':!![],'message':'✓\x20'+_0x4ce96a+'\x20'+_0x1ea943+'\x20set\x20to:\x20'+_0x41bbd3};}export const configSetDefinition={'service':a44_0x569890(0x1d6),'command':a44_0x569890(0x1d0),'description':'Set\x20a\x20config\x20value','risk':a44_0x569890(0x1d4),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a44_0x569890(0x1d1),'type':a44_0x569890(0x1bf),'description':getConfigCommandKeyDescription(),'required':!![]},{'name':a44_0x569890(0x1e2),'type':a44_0x569890(0x1bf),'description':a44_0x569890(0x1ba),'required':!![]},{'name':a44_0x569890(0x1c5),'type':a44_0x569890(0x1e0),'description':'Write\x20to\x20global\x20config\x20(~/.rabetbase.json)','default':![]}],'execute':execute};
1
+ function a44_0x2d26(){const _0x180b4b=['global','Config\x20value','249968ZzxVLw','locale','apps','set','app','str','\x20(stored\x20as\x20apps\x20+\x20defaultApp)','env','Legacy\x20alias\x20\x22online\x22\x20is\x20accepted\x20and\x20stored\x20as\x20production.','Set\x20a\x20config\x20value','Global','validation','\x22riskLevel\x22\x20cannot\x20be\x20changed\x20via\x20the\x20CLI.','610160NZkrbC','Invalid\x20value\x20for\x20\x22','appcode','365841unBThh','5065pEAMPy','join','object','56Klxrke','\x20app\x20add\x20<name>\x20--appcode\x20','value','Missing\x20key.','bool','string','\x20config\x20set\x20--key\x20<key>\x20--value\x20<value>','\x22\x20is\x20not\x20settable.','19724tsasWZ','Missing\x20value.','length','51CShGFv','Supported:\x20zh,\x20en,\x20zh-CN,\x20en-US','22blQTCU','Invalid\x20value\x20for\x20env.\x20Allowed:\x20production,\x20daily.','riskLevel','Settable\x20top-level\x20keys:\x20','keys','48752phCmDq','Write\x20to\x20global\x20config\x20(~/.rabetbase.json)','Usage:\x20','Invalid\x20locale\x20value.','includes','write','`,\x20`','1336713jTQBkE','102jTokAY','Cannot\x20set\x20top-level\x20\x22appcode\x22\x20when\x20multi-app\x20config\x20already\x20exists.'];a44_0x2d26=function(){return _0x180b4b;};return a44_0x2d26();}function a44_0xb0c8(_0x258fe7,_0x59794a){_0x258fe7=_0x258fe7-0x162;const _0x2d26ef=a44_0x2d26();let _0xb0c8c5=_0x2d26ef[_0x258fe7];return _0xb0c8c5;}const a44_0x741b3b=a44_0xb0c8;(function(_0x716fab,_0x1df812){const _0x330850=a44_0xb0c8,_0x4f315c=_0x716fab();while(!![]){try{const _0x56449c=parseInt(_0x330850(0x186))/0x1+-parseInt(_0x330850(0x17c))/0x2*(parseInt(_0x330850(0x17f))/0x3)+-parseInt(_0x330850(0x192))/0x4+parseInt(_0x330850(0x171))/0x5*(-parseInt(_0x330850(0x18e))/0x6)+parseInt(_0x330850(0x18d))/0x7+parseInt(_0x330850(0x174))/0x8*(parseInt(_0x330850(0x170))/0x9)+parseInt(_0x330850(0x16d))/0xa*(-parseInt(_0x330850(0x181))/0xb);if(_0x56449c===_0x1df812)break;else _0x4f315c['push'](_0x4f315c['shift']());}catch(_0x4f1668){_0x4f315c['push'](_0x4f315c['shift']());}}}(a44_0x2d26,0x25ce7));import{CliErrors}from'../../errors.js';import{buildCanonicalProjectConfig}from'../../config/schema.js';import{CLI_BIN_NAME,CONFIG_ENUM_VALUES,getConfigCommandKeyDescription,getTopLevelConfigKeySummary,isTopLevelConfigKey,normalizeLocale,resolveWriteScope,readScopedConfig,writeScopedConfig}from'../../commands/config/shared.js';import{normalizeEnv,isProduction,isDaily}from'../../constant/env.js';async function execute(_0x4794a3){const _0x214d8c=a44_0xb0c8,_0x1ce19d=_0x4794a3[_0x214d8c(0x165)]('key'),_0x246500=_0x4794a3[_0x214d8c(0x165)]('value');if(!_0x1ce19d)throw CliErrors[_0x214d8c(0x16b)](_0x214d8c(0x177),_0x214d8c(0x188)+CLI_BIN_NAME+_0x214d8c(0x17a));if(_0x246500===undefined||_0x246500==='')throw CliErrors['validation'](_0x214d8c(0x17d),_0x214d8c(0x188)+CLI_BIN_NAME+'\x20config\x20set\x20--key\x20<key>\x20--value\x20<value>');if(_0x246500[_0x214d8c(0x17e)]>0x1f4)throw CliErrors['validation']('Config\x20value\x20is\x20invalid\x20or\x20too\x20long.');if(!isTopLevelConfigKey(_0x1ce19d))throw CliErrors['validation']('Top-level\x20key\x20\x22'+_0x1ce19d+_0x214d8c(0x17b),_0x214d8c(0x184)+getTopLevelConfigKeySummary());if(_0x1ce19d===_0x214d8c(0x183))throw CliErrors['validation'](_0x214d8c(0x16c));if(CONFIG_ENUM_VALUES[_0x1ce19d]&&!CONFIG_ENUM_VALUES[_0x1ce19d][_0x214d8c(0x18a)](_0x246500))throw CliErrors[_0x214d8c(0x16b)](_0x214d8c(0x16e)+_0x1ce19d+'\x22.\x20Allowed:\x20'+CONFIG_ENUM_VALUES[_0x1ce19d][_0x214d8c(0x172)](',\x20'));if(_0x1ce19d===_0x214d8c(0x193)&&!normalizeLocale(_0x246500))throw CliErrors['validation'](_0x214d8c(0x189),_0x214d8c(0x180));const _0x56be35={'global':_0x4794a3[_0x214d8c(0x178)](_0x214d8c(0x190))},_0x148397=resolveWriteScope(_0x56be35),_0x1cb081=readScopedConfig(_0x148397);let _0x388fbe=_0x1ce19d,_0x5965f5=_0x246500;_0x1ce19d===_0x214d8c(0x164)&&(_0x388fbe='appcode',delete _0x1cb081[_0x214d8c(0x164)]);_0x1ce19d==='locale'&&(_0x5965f5=normalizeLocale(_0x246500));if(_0x1ce19d===_0x214d8c(0x167)){_0x5965f5=normalizeEnv(_0x246500);if(!isProduction(_0x5965f5)&&!isDaily(_0x5965f5))throw CliErrors[_0x214d8c(0x16b)](_0x214d8c(0x182),_0x214d8c(0x168));}if(_0x1ce19d===_0x214d8c(0x16f)){const _0x64d9aa=_0x1cb081[_0x214d8c(0x162)]&&typeof _0x1cb081[_0x214d8c(0x162)]===_0x214d8c(0x173)?Object[_0x214d8c(0x185)](_0x1cb081[_0x214d8c(0x162)]):[];if(_0x64d9aa[_0x214d8c(0x17e)]>0x0)throw CliErrors[_0x214d8c(0x16b)](_0x214d8c(0x18f),'Use\x20`'+CLI_BIN_NAME+_0x214d8c(0x175)+_0x5965f5+_0x214d8c(0x18c)+CLI_BIN_NAME+'\x20app\x20use\x20<name>`,\x20or\x20pass\x20`--appcode`\x20on\x20the\x20command.');const _0x25b73d=buildCanonicalProjectConfig({..._0x1cb081},{'appCodes':[_0x5965f5],'env':typeof _0x1cb081[_0x214d8c(0x167)]===_0x214d8c(0x179)?_0x1cb081['env']:undefined});writeScopedConfig(_0x25b73d,_0x148397);const _0x44e26c=_0x148397==='global'?_0x214d8c(0x16a):'Project';return{'ok':!![],'message':'✓\x20'+_0x44e26c+'\x20appcode\x20set\x20to:\x20'+_0x5965f5+_0x214d8c(0x166)};}_0x1cb081[_0x388fbe]=_0x5965f5,writeScopedConfig(_0x1cb081,_0x148397);const _0x1f66dc=_0x148397==='global'?_0x214d8c(0x16a):'Project';return{'ok':!![],'message':'✓\x20'+_0x1f66dc+'\x20'+_0x388fbe+'\x20set\x20to:\x20'+_0x5965f5};}export const configSetDefinition={'service':'config','command':a44_0x741b3b(0x163),'description':a44_0x741b3b(0x169),'risk':a44_0x741b3b(0x18b),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':'key','type':a44_0x741b3b(0x179),'description':getConfigCommandKeyDescription(),'required':!![]},{'name':a44_0x741b3b(0x176),'type':a44_0x741b3b(0x179),'description':a44_0x741b3b(0x191),'required':!![]},{'name':'global','type':'boolean','description':a44_0x741b3b(0x187),'default':![]}],'execute':execute};
@@ -1 +1 @@
1
- (function(_0x94d142,_0x264bc3){var _0x48b17d=a45_0x4a97,_0x38287a=_0x94d142();while(!![]){try{var _0x35478e=-parseInt(_0x48b17d(0xb0))/0x1*(-parseInt(_0x48b17d(0xb7))/0x2)+-parseInt(_0x48b17d(0xae))/0x3*(parseInt(_0x48b17d(0xb1))/0x4)+-parseInt(_0x48b17d(0xb2))/0x5+-parseInt(_0x48b17d(0xaa))/0x6+-parseInt(_0x48b17d(0xab))/0x7*(parseInt(_0x48b17d(0xb3))/0x8)+parseInt(_0x48b17d(0xb4))/0x9+parseInt(_0x48b17d(0xb5))/0xa;if(_0x35478e===_0x264bc3)break;else _0x38287a['push'](_0x38287a['shift']());}catch(_0x2ae920){_0x38287a['push'](_0x38287a['shift']());}}}(a45_0x1dba,0xe16a0));function a45_0x1dba(){var _0x29e97b=['1050DSQCUM','\x20init`\x20first.','global','16734JzklSf','project','290zTphFd','484gRVGpK','840350NjzrTQ','32632NFzUwb','11511234NcPOBG','9389070LFDegK','validation','2246XSKOlz','Not\x20inside\x20a\x20project\x20(no\x20.rabetbase.json\x20found).','992694ZTVnJY'];a45_0x1dba=function(){return _0x29e97b;};return a45_0x1dba();}function a45_0x4a97(_0x9a15a,_0x35d619){_0x9a15a=_0x9a15a-0xa9;var _0x1dba09=a45_0x1dba();var _0x4a9798=_0x1dba09[_0x9a15a];return _0x4a9798;}import{CLI_BIN_NAME}from'../../constant/cli.js';import{isInProject,resolveWriteConfigPath,readConfigFile,writeConfigFile}from'../../context.js';import{CliErrors}from'../../errors.js';import{CONFIG_ENUM_VALUES,TOP_LEVEL_CONFIG_KEYS,getConfigCommandKeyDescription,getTopLevelConfigKeyList,getTopLevelConfigKeySummary,isTopLevelConfigKey,normalizeLocale}from'../../config/schema.js';export{CLI_BIN_NAME};export{normalizeLocale};export{CONFIG_ENUM_VALUES,TOP_LEVEL_CONFIG_KEYS,getConfigCommandKeyDescription,getTopLevelConfigKeyList,getTopLevelConfigKeySummary,isTopLevelConfigKey};export function resolveWriteScope(_0x592786){var _0xa3be3f=a45_0x4a97;if(_0x592786['global'])return _0xa3be3f(0xad);if(!isInProject())throw CliErrors[_0xa3be3f(0xb6)](_0xa3be3f(0xa9),'Add\x20--global\x20to\x20write\x20to\x20~/.rabetbase.json,\x20or\x20run\x20`'+CLI_BIN_NAME+_0xa3be3f(0xac));return _0xa3be3f(0xaf);}export function readScopedConfig(_0x36d036){return readConfigFile(resolveWriteConfigPath(_0x36d036));}export function writeScopedConfig(_0x52129d,_0xedebf5){writeConfigFile(resolveWriteConfigPath(_0xedebf5),_0x52129d);}
1
+ (function(_0x2985be,_0x81378a){var _0x3571e9=a45_0x1068,_0x1b45e1=_0x2985be();while(!![]){try{var _0x2bdae4=-parseInt(_0x3571e9(0x19d))/0x1+-parseInt(_0x3571e9(0x19f))/0x2*(parseInt(_0x3571e9(0x197))/0x3)+parseInt(_0x3571e9(0x19c))/0x4*(-parseInt(_0x3571e9(0x196))/0x5)+parseInt(_0x3571e9(0x198))/0x6*(-parseInt(_0x3571e9(0x1a4))/0x7)+-parseInt(_0x3571e9(0x19a))/0x8+parseInt(_0x3571e9(0x1a6))/0x9*(-parseInt(_0x3571e9(0x199))/0xa)+-parseInt(_0x3571e9(0x1a0))/0xb*(-parseInt(_0x3571e9(0x1a3))/0xc);if(_0x2bdae4===_0x81378a)break;else _0x1b45e1['push'](_0x1b45e1['shift']());}catch(_0x464c1b){_0x1b45e1['push'](_0x1b45e1['shift']());}}}(a45_0x58db,0x309cb));import{CLI_BIN_NAME}from'../../constant/cli.js';import{isInProject,resolveWriteConfigPath,readConfigFile,writeConfigFile}from'../../context.js';function a45_0x58db(){var _0x54621b=['2989056xTHVmJ','global','4hXvoOw','228891AsTmds','validation','177874dkaKMJ','165RUriiD','project','\x20init`\x20first.','1360104vdDvOJ','1126993vIEFXY','Add\x20--global\x20to\x20write\x20to\x20~/.rabetbase.json,\x20or\x20run\x20`','18PfizjZ','728600aDjUPy','9NSiMpO','6Htwvwu','1624810mDTwAq'];a45_0x58db=function(){return _0x54621b;};return a45_0x58db();}import{CliErrors}from'../../errors.js';function a45_0x1068(_0x16d3c1,_0x4aff50){_0x16d3c1=_0x16d3c1-0x196;var _0x58dba9=a45_0x58db();var _0x1068d5=_0x58dba9[_0x16d3c1];return _0x1068d5;}import{CONFIG_ENUM_VALUES,TOP_LEVEL_CONFIG_KEYS,getConfigCommandKeyDescription,getTopLevelConfigKeyList,getTopLevelConfigKeySummary,isTopLevelConfigKey,normalizeLocale}from'../../config/schema.js';export{CLI_BIN_NAME};export{normalizeLocale};export{CONFIG_ENUM_VALUES,TOP_LEVEL_CONFIG_KEYS,getConfigCommandKeyDescription,getTopLevelConfigKeyList,getTopLevelConfigKeySummary,isTopLevelConfigKey};export function resolveWriteScope(_0x50c270){var _0xf3ced6=a45_0x1068;if(_0x50c270[_0xf3ced6(0x19b)])return _0xf3ced6(0x19b);if(!isInProject())throw CliErrors[_0xf3ced6(0x19e)]('Not\x20inside\x20a\x20project\x20(no\x20.rabetbase.json\x20found).',_0xf3ced6(0x1a5)+CLI_BIN_NAME+_0xf3ced6(0x1a2));return _0xf3ced6(0x1a1);}export function readScopedConfig(_0x436ab6){return readConfigFile(resolveWriteConfigPath(_0x436ab6));}export function writeScopedConfig(_0x4e73e0,_0x3ceab3){writeConfigFile(resolveWriteConfigPath(_0x3ceab3),_0x4e73e0);}
@@ -1 +1 @@
1
- function a46_0x1579(_0x1f0aa3,_0x191ebc){_0x1f0aa3=_0x1f0aa3-0x83;const _0x17fc65=a46_0x17fc();let _0x1579a6=_0x17fc65[_0x1f0aa3];return _0x1579a6;}const a46_0x1efda9=a46_0x1579;(function(_0x300906,_0x39ad89){const _0x2c2fe7=a46_0x1579,_0x399dd7=_0x300906();while(!![]){try{const _0x2a6726=parseInt(_0x2c2fe7(0x8c))/0x1+parseInt(_0x2c2fe7(0x8e))/0x2+parseInt(_0x2c2fe7(0x87))/0x3*(-parseInt(_0x2c2fe7(0x89))/0x4)+parseInt(_0x2c2fe7(0x88))/0x5+parseInt(_0x2c2fe7(0x92))/0x6+-parseInt(_0x2c2fe7(0x91))/0x7*(-parseInt(_0x2c2fe7(0x85))/0x8)+-parseInt(_0x2c2fe7(0x8a))/0x9;if(_0x2a6726===_0x39ad89)break;else _0x399dd7['push'](_0x399dd7['shift']());}catch(_0x1651de){_0x399dd7['push'](_0x399dd7['shift']());}}}(a46_0x17fc,0x28867));function a46_0x17fc(){const _0x1ab944=['7499664fdXvHq','Filter\x20dataset\x20records\x20with\x20query\x20conditions','104533YfBipp','\x20\x20\x20\x20pageSize\x20\x20\x20\x20\x20\x20Number\x20\x20\x20Records\x20per\x20page','651310WwBqPM','\x20\x20\x20\x20orderBy\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Sort\x20order,\x20e.g.\x20[{\x22id\x22:\x22desc\x22},{\x22name\x22:\x22asc\x22}]','JSON\x20body\x20for\x20filter\x20API.\x20Fields:\x20where,\x20select,\x20orderBy,\x20currentPage,\x20pageSize.\x20Example:\x20\x27{\x22where\x22:{\x22status\x22:{\x22$eq\x22:\x22active\x22}},\x22currentPage\x22:1,\x22pageSize\x22:20}\x27','623HCsKcH','1675392yrZccz','filter','\x20\x20\x20\x20currentPage\x20\x20\x20Number\x20\x20\x20Page\x20number\x20(starts\x20from\x201)','25720hvZPUU','\x20\x20\x20\x20where\x20\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Query\x20conditions','317829WkhsvG','1078090YLZbVn','8itveyx'];a46_0x17fc=function(){return _0x1ab944;};return a46_0x17fc();}import{buildDataCommand}from'../../commands/data/shared.js';export const dataFilter=buildDataCommand({'command':'filter','operation':a46_0x1efda9(0x83),'description':a46_0x1efda9(0x8b),'paramsRequired':![],'paramsHint':a46_0x1efda9(0x90),'helpExtra':['\x20\x20JSON\x20BODY\x20FIELDS\x20(pass\x20inside\x20--params)',a46_0x1efda9(0x86),'\x20\x20\x20\x20select\x20\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Fields\x20to\x20return,\x20e.g.\x20[\x22id\x22,\x22name\x22,\x22status\x22]',a46_0x1efda9(0x8f),a46_0x1efda9(0x84),a46_0x1efda9(0x8d)]['join']('\x0a')});
1
+ function a46_0x45ec(){const _0x2fed09=['\x20\x20\x20\x20where\x20\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Query\x20conditions','3028210vIUzln','7841211RFIGuN','JSON\x20body\x20for\x20filter\x20API.\x20Fields:\x20where,\x20select,\x20orderBy,\x20currentPage,\x20pageSize.\x20Example:\x20\x27{\x22where\x22:{\x22status\x22:{\x22$eq\x22:\x22active\x22}},\x22currentPage\x22:1,\x22pageSize\x22:20}\x27','filter','\x20\x20\x20\x20currentPage\x20\x20\x20Number\x20\x20\x20Page\x20number\x20(starts\x20from\x201)','1889424DPZsvl','\x20\x20\x20\x20orderBy\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Sort\x20order,\x20e.g.\x20[{\x22id\x22:\x22desc\x22},{\x22name\x22:\x22asc\x22}]','\x20\x20\x20\x20select\x20\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Fields\x20to\x20return,\x20e.g.\x20[\x22id\x22,\x22name\x22,\x22status\x22]','328869Ltqnst','18vODDdk','220359VHCvjI','5122120VRtnIl','45272DsIlIU','Filter\x20dataset\x20records\x20with\x20query\x20conditions','9MDsSIe'];a46_0x45ec=function(){return _0x2fed09;};return a46_0x45ec();}const a46_0x5c91b1=a46_0x264d;(function(_0x56daba,_0x27336e){const _0x2e914d=a46_0x264d,_0x4ba667=_0x56daba();while(!![]){try{const _0xca616b=parseInt(_0x2e914d(0x1d5))/0x1+parseInt(_0x2e914d(0x1d4))/0x2*(parseInt(_0x2e914d(0x1d3))/0x3)+-parseInt(_0x2e914d(0x1d6))/0x4+-parseInt(_0x2e914d(0x1db))/0x5+parseInt(_0x2e914d(0x1e0))/0x6+parseInt(_0x2e914d(0x1dc))/0x7+-parseInt(_0x2e914d(0x1d7))/0x8*(parseInt(_0x2e914d(0x1d9))/0x9);if(_0xca616b===_0x27336e)break;else _0x4ba667['push'](_0x4ba667['shift']());}catch(_0x1d925a){_0x4ba667['push'](_0x4ba667['shift']());}}}(a46_0x45ec,0xb7284));import{buildDataCommand}from'../../commands/data/shared.js';function a46_0x264d(_0x3ec922,_0x52ae8e){_0x3ec922=_0x3ec922-0x1d3;const _0x45ec27=a46_0x45ec();let _0x264daa=_0x45ec27[_0x3ec922];return _0x264daa;}export const dataFilter=buildDataCommand({'command':'filter','operation':a46_0x5c91b1(0x1de),'description':a46_0x5c91b1(0x1d8),'paramsRequired':![],'paramsHint':a46_0x5c91b1(0x1dd),'helpExtra':['\x20\x20JSON\x20BODY\x20FIELDS\x20(pass\x20inside\x20--params)',a46_0x5c91b1(0x1da),a46_0x5c91b1(0x1e2),a46_0x5c91b1(0x1e1),a46_0x5c91b1(0x1df),'\x20\x20\x20\x20pageSize\x20\x20\x20\x20\x20\x20Number\x20\x20\x20Records\x20per\x20page']['join']('\x0a')});
@@ -1 +1 @@
1
- function a47_0x6267(_0x9fbce0,_0x56281d){_0x9fbce0=_0x9fbce0-0xd7;const _0x2fb227=a47_0x2fb2();let _0x62671b=_0x2fb227[_0x9fbce0];return _0x62671b;}function a47_0x2fb2(){const _0x16e335=['getOne','189838zsLbAp','7qRMxMB','1229100HiCUEK','9bmHMpr','680359gpAjMG','28264qbylwk','2896736UmxaFX','Get\x20a\x20single\x20record\x20by\x20ID','13438qQOxtR','320wQlWHS','5iCthla','1179abgRjy','2527932nIaDgk'];a47_0x2fb2=function(){return _0x16e335;};return a47_0x2fb2();}const a47_0x586592=a47_0x6267;(function(_0xf2ff40,_0x14a2ac){const _0x865faa=a47_0x6267,_0x58740d=_0xf2ff40();while(!![]){try{const _0x5d7930=parseInt(_0x865faa(0xe1))/0x1+parseInt(_0x865faa(0xd7))/0x2*(parseInt(_0x865faa(0xe0))/0x3)+-parseInt(_0x865faa(0xe3))/0x4*(parseInt(_0x865faa(0xd9))/0x5)+parseInt(_0x865faa(0xdb))/0x6*(parseInt(_0x865faa(0xde))/0x7)+-parseInt(_0x865faa(0xe2))/0x8*(parseInt(_0x865faa(0xda))/0x9)+-parseInt(_0x865faa(0xd8))/0xa*(-parseInt(_0x865faa(0xdd))/0xb)+parseInt(_0x865faa(0xdf))/0xc;if(_0x5d7930===_0x14a2ac)break;else _0x58740d['push'](_0x58740d['shift']());}catch(_0x34a4a1){_0x58740d['push'](_0x58740d['shift']());}}}(a47_0x2fb2,0x8fec8));import{buildDataCommand}from'../../commands/data/shared.js';export const dataGetOne=buildDataCommand({'command':a47_0x586592(0xdc),'operation':a47_0x586592(0xdc),'description':a47_0x586592(0xe4),'paramsRequired':!![],'paramsHint':'JSON\x20with\x20record\x20id.\x20Example:\x20\x27{\x22id\x22:123}\x27'});
1
+ const a47_0x4239f8=a47_0x2fee;(function(_0x65e634,_0xc38d29){const _0x4b5174=a47_0x2fee,_0x11b48a=_0x65e634();while(!![]){try{const _0x3567cc=-parseInt(_0x4b5174(0x1d5))/0x1+-parseInt(_0x4b5174(0x1dc))/0x2+-parseInt(_0x4b5174(0x1d9))/0x3+parseInt(_0x4b5174(0x1d7))/0x4*(parseInt(_0x4b5174(0x1d6))/0x5)+-parseInt(_0x4b5174(0x1dd))/0x6*(parseInt(_0x4b5174(0x1d3))/0x7)+-parseInt(_0x4b5174(0x1db))/0x8*(-parseInt(_0x4b5174(0x1d8))/0x9)+parseInt(_0x4b5174(0x1d2))/0xa*(parseInt(_0x4b5174(0x1da))/0xb);if(_0x3567cc===_0xc38d29)break;else _0x11b48a['push'](_0x11b48a['shift']());}catch(_0x13f041){_0x11b48a['push'](_0x11b48a['shift']());}}}(a47_0x19e1,0xc6677));function a47_0x2fee(_0x48fcc6,_0x145ec3){_0x48fcc6=_0x48fcc6-0x1d2;const _0x19e155=a47_0x19e1();let _0x2fee50=_0x19e155[_0x48fcc6];return _0x2fee50;}import{buildDataCommand}from'../../commands/data/shared.js';function a47_0x19e1(){const _0x1e8b3d=['3605cxKOkQ','getOne','601745xxtzZj','3940gcELVO','4700JBYlqu','6516LqKubH','360096QEPFkq','33aOiRog','4000nAEeoZ','308072eSgwFy','10374PcgvIy','Get\x20a\x20single\x20record\x20by\x20ID','4303370wdFtCD'];a47_0x19e1=function(){return _0x1e8b3d;};return a47_0x19e1();}export const dataGetOne=buildDataCommand({'command':a47_0x4239f8(0x1d4),'operation':'getOne','description':a47_0x4239f8(0x1de),'paramsRequired':!![],'paramsHint':'JSON\x20with\x20record\x20id.\x20Example:\x20\x27{\x22id\x22:123}\x27'});
@@ -1 +1 @@
1
- function a48_0x40c5(_0x5dd7d2,_0x43b950){_0x5dd7d2=_0x5dd7d2-0x197;const _0x2d09ed=a48_0x2d09();let _0x40c53d=_0x2d09ed[_0x5dd7d2];return _0x40c53d;}(function(_0x1ebb8e,_0x13e95e){const _0xeab2aa=a48_0x40c5,_0x4aa9e0=_0x1ebb8e();while(!![]){try{const _0x275972=-parseInt(_0xeab2aa(0x19c))/0x1*(-parseInt(_0xeab2aa(0x197))/0x2)+-parseInt(_0xeab2aa(0x19a))/0x3*(parseInt(_0xeab2aa(0x19d))/0x4)+-parseInt(_0xeab2aa(0x19f))/0x5+parseInt(_0xeab2aa(0x1a1))/0x6+parseInt(_0xeab2aa(0x199))/0x7*(-parseInt(_0xeab2aa(0x19e))/0x8)+-parseInt(_0xeab2aa(0x198))/0x9+-parseInt(_0xeab2aa(0x19b))/0xa*(-parseInt(_0xeab2aa(0x1a0))/0xb);if(_0x275972===_0x13e95e)break;else _0x4aa9e0['push'](_0x4aa9e0['shift']());}catch(_0x1708cf){_0x4aa9e0['push'](_0x4aa9e0['shift']());}}}(a48_0x2d09,0xb647a));import{dataFilter}from'../../commands/data/filter.js';import{dataGetOne}from'../../commands/data/getOne.js';function a48_0x2d09(){const _0x5cc7cd=['561VxSpza','14101060ugUloB','6376tzXwZp','13620LhScHX','8CWIBGk','6317545vhgcyc','11Eczvck','3919422YuUAbR','428EwBeLb','6189489BgfRnc','652568PQskgv'];a48_0x2d09=function(){return _0x5cc7cd;};return a48_0x2d09();}export const dataDefinitions=[dataFilter,dataGetOne];
1
+ function a48_0x2ea4(_0x1b7d12,_0x1360b8){_0x1b7d12=_0x1b7d12-0x176;const _0x40a041=a48_0x40a0();let _0x2ea407=_0x40a041[_0x1b7d12];return _0x2ea407;}(function(_0x432940,_0x3202b5){const _0x39786a=a48_0x2ea4,_0x2e3d90=_0x432940();while(!![]){try{const _0x4c1f1d=parseInt(_0x39786a(0x178))/0x1*(-parseInt(_0x39786a(0x17e))/0x2)+parseInt(_0x39786a(0x179))/0x3+-parseInt(_0x39786a(0x177))/0x4*(-parseInt(_0x39786a(0x17a))/0x5)+parseInt(_0x39786a(0x176))/0x6*(parseInt(_0x39786a(0x17d))/0x7)+-parseInt(_0x39786a(0x17b))/0x8*(parseInt(_0x39786a(0x17f))/0x9)+-parseInt(_0x39786a(0x180))/0xa*(-parseInt(_0x39786a(0x181))/0xb)+-parseInt(_0x39786a(0x17c))/0xc;if(_0x4c1f1d===_0x3202b5)break;else _0x2e3d90['push'](_0x2e3d90['shift']());}catch(_0x6503e4){_0x2e3d90['push'](_0x2e3d90['shift']());}}}(a48_0x40a0,0x77ed2));function a48_0x40a0(){const _0x39ca34=['10750320sQDCAx','6779262mtiWco','608294esTUdm','5661sKaSyC','10ozLJaR','10347612xFChQl','6YNNhWj','551420kvgaaT','1OUjZWu','223032MxHLYA','10dYwXnv','7224WktSnT'];a48_0x40a0=function(){return _0x39ca34;};return a48_0x40a0();}import{dataFilter}from'../../commands/data/filter.js';import{dataGetOne}from'../../commands/data/getOne.js';export const dataDefinitions=[dataFilter,dataGetOne];
@@ -1 +1 @@
1
- function a49_0x2b97(){const _0x1f15b3=['859180LPoaNn','13098zlEKPo','alias','flagMissing','string','988tavQaG','Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon).\x20Resolves\x20to\x20dataset\x20code\x20automatically','6uoWSFR','operation','code','compress','6220193Neigsk','appCode','read','233720TvxrYy','helpExtra','paramsRequired','171nyKjmf','6010770XYIinW','now','Provide\x20--params\x20\x27{\x22id\x22:123}\x27\x20for\x20data\x20getOne.','Example:\x20--params\x20\x27{\x22id\x22:123}\x27','data\x20','paramsHint','params','str','\x20completed\x20in\x20','4722085ojBBKc','command','data','826168UxeKYI'];a49_0x2b97=function(){return _0x1f15b3;};return a49_0x2b97();}function a49_0x4d0a(_0x165238,_0x1f6685){_0x165238=_0x165238-0xc1;const _0x2b9798=a49_0x2b97();let _0x4d0a84=_0x2b9798[_0x165238];return _0x4d0a84;}(function(_0x190f61,_0x2e2524){const _0x546de0=a49_0x4d0a,_0xeba03a=_0x190f61();while(!![]){try{const _0x3cee1c=parseInt(_0x546de0(0xdb))/0x1+-parseInt(_0x546de0(0xda))/0x2+-parseInt(_0x546de0(0xdc))/0x3*(parseInt(_0x546de0(0xc1))/0x4)+parseInt(_0x546de0(0xd7))/0x5*(parseInt(_0x546de0(0xc3))/0x6)+-parseInt(_0x546de0(0xc7))/0x7+-parseInt(_0x546de0(0xca))/0x8*(-parseInt(_0x546de0(0xcd))/0x9)+parseInt(_0x546de0(0xce))/0xa;if(_0x3cee1c===_0x2e2524)break;else _0xeba03a['push'](_0xeba03a['shift']());}catch(_0x3d525d){_0xeba03a['push'](_0xeba03a['shift']());}}}(a49_0x2b97,0x8d85a));import{executeDatasetDataOperation}from'../../core/api-client.js';import{CODE_FLAG,APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{CliErrors}from'../../errors.js';import{parseJsonParams}from'../../utils/params.js';function assertGetOneId(_0x215e2d){const _0x372ef8=a49_0x4d0a;if(!_0x215e2d)throw CliErrors[_0x372ef8(0xde)](_0x372ef8(0xd4),_0x372ef8(0xd0));const _0x324f46=_0x215e2d['id'];if(_0x324f46===undefined||_0x324f46===null||_0x324f46==='')throw CliErrors['validation']('data\x20getOne\x20requires\x20\x22id\x22\x20in\x20--params',_0x372ef8(0xd1));}function parseCommandParams(_0x1a5868){return parseJsonParams(_0x1a5868)??{};}export function buildDataCommand(_0x21e4ea){const _0x446992=a49_0x4d0a,_0x5a799d=_0x446992(0xc2);return{'service':_0x446992(0xd9),'command':_0x21e4ea[_0x446992(0xd8)],'description':_0x21e4ea['description'],'risk':_0x446992(0xc9),'defaultOutputFormat':_0x446992(0xc6),'helpExtra':_0x21e4ea[_0x446992(0xcb)],'flags':[CODE_FLAG,APPCODE_FLAG_OPTIONAL,{'name':_0x446992(0xdd),'type':_0x446992(0xdf),'description':_0x5a799d},{'name':_0x446992(0xd4),'type':_0x446992(0xdf),'description':_0x21e4ea[_0x446992(0xd3)]}],async 'validate'(_0x36b9d4){const _0x377e90=_0x446992,_0x581a21=_0x36b9d4[_0x377e90(0xd5)](_0x377e90(0xd4));if(_0x21e4ea[_0x377e90(0xcc)]&&!_0x581a21)throw CliErrors[_0x377e90(0xde)](_0x377e90(0xd4),_0x21e4ea['paramsHint']);const _0x1ed162=parseJsonParams(_0x581a21);_0x21e4ea[_0x377e90(0xc4)]==='getOne'&&assertGetOneId(_0x1ed162);},async 'execute'(_0x4a7a4a){const _0x2fe488=_0x446992,_0x4e778a=parseCommandParams(_0x4a7a4a[_0x2fe488(0xd5)]('params')),_0x4c62f8=Date[_0x2fe488(0xcf)](),_0x43257f=await executeDatasetDataOperation(_0x4a7a4a[_0x2fe488(0xc8)],_0x4a7a4a[_0x2fe488(0xd5)](_0x2fe488(0xc5)),_0x21e4ea[_0x2fe488(0xc4)],_0x4e778a),_0x3a1dcd=Date[_0x2fe488(0xcf)]()-_0x4c62f8;return{'ok':!![],'data':{'result':_0x43257f,'elapsed':_0x3a1dcd},'message':_0x2fe488(0xd2)+_0x21e4ea['command']+_0x2fe488(0xd6)+_0x3a1dcd+'ms'};}};}
1
+ (function(_0x1c89bf,_0x809464){const _0xf63999=a49_0x35c8,_0x3fece6=_0x1c89bf();while(!![]){try{const _0x5b23f9=-parseInt(_0xf63999(0x19d))/0x1+-parseInt(_0xf63999(0x195))/0x2*(-parseInt(_0xf63999(0x191))/0x3)+-parseInt(_0xf63999(0x190))/0x4+-parseInt(_0xf63999(0x189))/0x5*(-parseInt(_0xf63999(0x19b))/0x6)+-parseInt(_0xf63999(0x18a))/0x7*(-parseInt(_0xf63999(0x187))/0x8)+-parseInt(_0xf63999(0x18f))/0x9+-parseInt(_0xf63999(0x181))/0xa*(-parseInt(_0xf63999(0x19f))/0xb);if(_0x5b23f9===_0x809464)break;else _0x3fece6['push'](_0x3fece6['shift']());}catch(_0x4fc779){_0x3fece6['push'](_0x3fece6['shift']());}}}(a49_0x14b1,0x9d1cc));import{executeDatasetDataOperation}from'../../core/api-client.js';import{CODE_FLAG,APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{CliErrors}from'../../errors.js';import{parseJsonParams}from'../../utils/params.js';function assertGetOneId(_0x56b0e4){const _0x394dc8=a49_0x35c8;if(!_0x56b0e4)throw CliErrors[_0x394dc8(0x188)](_0x394dc8(0x184),_0x394dc8(0x194));const _0x30e920=_0x56b0e4['id'];if(_0x30e920===undefined||_0x30e920===null||_0x30e920==='')throw CliErrors[_0x394dc8(0x199)](_0x394dc8(0x185),_0x394dc8(0x19c));}function parseCommandParams(_0x2b150c){return parseJsonParams(_0x2b150c)??{};}function a49_0x35c8(_0x1b184a,_0x50a2bd){_0x1b184a=_0x1b184a-0x181;const _0x14b19f=a49_0x14b1();let _0x35c81f=_0x14b19f[_0x1b184a];return _0x35c81f;}function a49_0x14b1(){const _0x4e47fb=['243372eTvafu','849RkkLZa','operation','Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon).\x20Resolves\x20to\x20dataset\x20code\x20automatically','Provide\x20--params\x20\x27{\x22id\x22:123}\x27\x20for\x20data\x20getOne.','1100niILMr','\x20completed\x20in\x20','code','helpExtra','validation','read','243870OJSdYH','Example:\x20--params\x20\x27{\x22id\x22:123}\x27','914296Ehacgi','compress','17147570BESDWb','10CBYUCi','paramsHint','command','params','data\x20getOne\x20requires\x20\x22id\x22\x20in\x20--params','str','8NlOgQO','flagMissing','35ngTKKa','4902821JyBBuI','appCode','data\x20','now','data','9726903hmUnsA'];a49_0x14b1=function(){return _0x4e47fb;};return a49_0x14b1();}export function buildDataCommand(_0x365c69){const _0x123ea4=a49_0x35c8,_0x2c2166=_0x123ea4(0x193);return{'service':_0x123ea4(0x18e),'command':_0x365c69['command'],'description':_0x365c69['description'],'risk':_0x123ea4(0x19a),'defaultOutputFormat':_0x123ea4(0x19e),'helpExtra':_0x365c69[_0x123ea4(0x198)],'flags':[CODE_FLAG,APPCODE_FLAG_OPTIONAL,{'name':'alias','type':'string','description':_0x2c2166},{'name':'params','type':'string','description':_0x365c69['paramsHint']}],async 'validate'(_0x6fdb10){const _0x427f71=_0x123ea4,_0x246bcf=_0x6fdb10['str'](_0x427f71(0x184));if(_0x365c69['paramsRequired']&&!_0x246bcf)throw CliErrors[_0x427f71(0x188)](_0x427f71(0x184),_0x365c69[_0x427f71(0x182)]);const _0x18cf2e=parseJsonParams(_0x246bcf);_0x365c69[_0x427f71(0x192)]==='getOne'&&assertGetOneId(_0x18cf2e);},async 'execute'(_0x11f80e){const _0x1ca0c5=_0x123ea4,_0x5a6bc0=parseCommandParams(_0x11f80e[_0x1ca0c5(0x186)](_0x1ca0c5(0x184))),_0x224852=Date['now'](),_0x2b896a=await executeDatasetDataOperation(_0x11f80e[_0x1ca0c5(0x18b)],_0x11f80e[_0x1ca0c5(0x186)](_0x1ca0c5(0x197)),_0x365c69[_0x1ca0c5(0x192)],_0x5a6bc0),_0x3270b6=Date[_0x1ca0c5(0x18d)]()-_0x224852;return{'ok':!![],'data':{'result':_0x2b896a,'elapsed':_0x3270b6},'message':_0x1ca0c5(0x18c)+_0x365c69[_0x1ca0c5(0x183)]+_0x1ca0c5(0x196)+_0x3270b6+'ms'};}};}
@@ -1 +1 @@
1
- const a50_0x34a7ca=a50_0x4043;function a50_0x1a4d(){const _0x3171f9=['原因:schema\x20introspection\x20与\x20custom\x20SQL\x20需要\x20source=DB_TABLE、dbtableConfig.dbId、dbtableConfig.tableName\x20与数据库连接上下文。','UNKNOWN','METADATA','2276852ikQaCf','Use\x20lovrabet\x20data\x20filter/getOne\x20for\x20real\x20runtime\x20records.','当前数据集\x20\x22','\x20类型,没有可用于\x20','lovrabet','datasetCode','\x20是\x20','1091402Bkjvey','modelCode','SQL\x20schema\x20validation','tableName','5dxtAHh','code','请先将该数据集升级/迁移为\x20DB_TABLE\x20数据集,再基于新的\x20dataset\x20code\x20继续开发。','2447840rAmGGX','21yfEaAH','validation','getOne','length','3004839pupjtM','filter','230670vbArwX','dbtable','\x20的\x20DB_TABLE\x20数据源上下文。','lovrabet\x20data\x20filter\x20--code\x20<datasetCode>\x20--params\x20\x27<json>\x27\x20--format\x20compress','toUpperCase','datasetName','13594630UQtGqt','6100euaIsp','921coTanK','dataset'];a50_0x1a4d=function(){return _0x3171f9;};return a50_0x1a4d();}(function(_0x133126,_0x3ce116){const _0x24f44c=a50_0x4043,_0x1188db=_0x133126();while(!![]){try{const _0x54ab40=-parseInt(_0x24f44c(0x151))/0x1+parseInt(_0x24f44c(0x144))/0x2*(parseInt(_0x24f44c(0x145))/0x3)+-parseInt(_0x24f44c(0x14a))/0x4*(-parseInt(_0x24f44c(0x133))/0x5)+parseInt(_0x24f44c(0x13d))/0x6+parseInt(_0x24f44c(0x137))/0x7*(-parseInt(_0x24f44c(0x136))/0x8)+-parseInt(_0x24f44c(0x13b))/0x9+parseInt(_0x24f44c(0x143))/0xa;if(_0x54ab40===_0x3ce116)break;else _0x1188db['push'](_0x1188db['shift']());}catch(_0x28c033){_0x1188db['push'](_0x1188db['shift']());}}}(a50_0x1a4d,0x88c82));import{CliErrors}from'../../errors.js';export const RUNTIME_DATA_ACCESS_COMMANDS={'cli':a50_0x34a7ca(0x14e),'filter':a50_0x34a7ca(0x140),'getOne':'lovrabet\x20data\x20getOne\x20--code\x20<datasetCode>\x20--params\x20\x27{\x22id\x22:123}\x27\x20--format\x20compress'};export const RUNTIME_DATA_ACCESS_SUMMARY=a50_0x34a7ca(0x14b);function valueToString(_0xb32687){return _0xb32687==null?'':String(_0xb32687)['trim']();}function getDatasetCode(_0x14fd20){const _0x3b004=a50_0x34a7ca;return valueToString(_0x14fd20[_0x3b004(0x134)]??_0x14fd20[_0x3b004(0x152)]??_0x14fd20[_0x3b004(0x146)]?.[_0x3b004(0x14f)]);}function getDatasetName(_0x243f5b){const _0x4751cd=a50_0x34a7ca;return valueToString(_0x243f5b['name']??_0x243f5b[_0x4751cd(0x146)]?.[_0x4751cd(0x142)])||'unknown';}function getDatasetSource(_0x56c56c){const _0xf79dbd=a50_0x34a7ca;return valueToString(_0x56c56c['source']??_0x56c56c[_0xf79dbd(0x146)]?.['sourceType'])[_0xf79dbd(0x141)]();}function getDbtableConfig(_0x2e6489){const _0xcd976e=a50_0x34a7ca,_0x481ec7=_0x2e6489['dbtableConfig']??_0x2e6489[_0xcd976e(0x13e)];return _0x481ec7&&typeof _0x481ec7==='object'?_0x481ec7:{};}export function isDbTableBackedDataset(_0x177f11){const _0x576d93=a50_0x34a7ca,_0x23cb10=getDatasetSource(_0x177f11);if(_0x23cb10===_0x576d93(0x149))return![];const _0x5820d9=getDbtableConfig(_0x177f11),_0x5913bb=_0x5820d9['dbId']??_0x5820d9['id'],_0x49cdb7=valueToString(_0x5820d9[_0x576d93(0x154)]??_0x177f11['tableName']??_0x177f11['dataset']?.[_0x576d93(0x154)]);return _0x5913bb!==undefined&&_0x5913bb!==null&&_0x49cdb7[_0x576d93(0x13a)]>0x0;}export function filterDbTableBackedDatasets(_0x200be0){const _0x30b758=a50_0x34a7ca;return _0x200be0[_0x30b758(0x13c)](_0x34b7b8=>isDbTableBackedDataset(_0x34b7b8));}function a50_0x4043(_0x561ef5,_0x845aa){_0x561ef5=_0x561ef5-0x133;const _0x1a4d99=a50_0x1a4d();let _0x404371=_0x1a4d99[_0x561ef5];return _0x404371;}export function buildDbTableBackedRequirementMessage(_0x115e7e,_0x404999=a50_0x34a7ca(0x153)){const _0x545474=a50_0x34a7ca,_0x403b8f=getDatasetSource(_0x115e7e)||_0x545474(0x148),_0x1685e2=getDatasetName(_0x115e7e),_0x941ca9=getDatasetCode(_0x115e7e),_0x22c93a=_0x941ca9?'\x20('+_0x941ca9+')':'';return[_0x545474(0x14c)+_0x1685e2+'\x22'+_0x22c93a+_0x545474(0x150)+_0x403b8f+_0x545474(0x14d)+_0x404999+_0x545474(0x13f),_0x545474(0x147),_0x545474(0x135),'如果只是查看运行态真实行数据,请切换到\x20lovrabet\x20CLI:'+RUNTIME_DATA_ACCESS_COMMANDS[_0x545474(0x13c)]+';'+RUNTIME_DATA_ACCESS_COMMANDS[_0x545474(0x139)]+'。']['join']('\x20');}export function assertDatasetIsDbTableBacked(_0x66afca,_0x31e00e){const _0x20d3b8=a50_0x34a7ca;if(!isDbTableBackedDataset(_0x66afca))throw CliErrors[_0x20d3b8(0x138)](buildDbTableBackedRequirementMessage(_0x66afca,_0x31e00e));}
1
+ const a50_0x354877=a50_0xe193;(function(_0x372827,_0x4a3218){const _0x580fad=a50_0xe193,_0x47891f=_0x372827();while(!![]){try{const _0x1b4a1d=parseInt(_0x580fad(0x1d8))/0x1+parseInt(_0x580fad(0x1c9))/0x2+parseInt(_0x580fad(0x1cc))/0x3+parseInt(_0x580fad(0x1bb))/0x4+parseInt(_0x580fad(0x1cf))/0x5*(-parseInt(_0x580fad(0x1de))/0x6)+parseInt(_0x580fad(0x1d9))/0x7+-parseInt(_0x580fad(0x1c2))/0x8*(parseInt(_0x580fad(0x1d7))/0x9);if(_0x1b4a1d===_0x4a3218)break;else _0x47891f['push'](_0x47891f['shift']());}catch(_0x4550fc){_0x47891f['push'](_0x47891f['shift']());}}}(a50_0x512a,0xbc022));import{CliErrors}from'../../errors.js';function a50_0xe193(_0x42469d,_0x317135){_0x42469d=_0x42469d-0x1ba;const _0x512a0d=a50_0x512a();let _0xe1930d=_0x512a0d[_0x42469d];return _0xe1930d;}export const RUNTIME_DATA_ACCESS_COMMANDS={'cli':a50_0x354877(0x1c3),'filter':'lovrabet\x20data\x20filter\x20--code\x20<datasetCode>\x20--params\x20\x27<json>\x27\x20--format\x20compress','getOne':a50_0x354877(0x1bc)};export const RUNTIME_DATA_ACCESS_SUMMARY='Use\x20lovrabet\x20data\x20filter/getOne\x20for\x20real\x20runtime\x20records.';function valueToString(_0x27187d){const _0x43aa59=a50_0x354877;return _0x27187d==null?'':String(_0x27187d)[_0x43aa59(0x1c7)]();}function getDatasetCode(_0x71025f){const _0x28bd60=a50_0x354877;return valueToString(_0x71025f[_0x28bd60(0x1d0)]??_0x71025f[_0x28bd60(0x1cb)]??_0x71025f[_0x28bd60(0x1da)]?.[_0x28bd60(0x1c1)]);}function getDatasetName(_0x245f5f){const _0x59934f=a50_0x354877;return valueToString(_0x245f5f[_0x59934f(0x1bf)]??_0x245f5f['dataset']?.[_0x59934f(0x1d1)])||_0x59934f(0x1ce);}function getDatasetSource(_0x6b22c7){const _0x2dd60f=a50_0x354877;return valueToString(_0x6b22c7['source']??_0x6b22c7[_0x2dd60f(0x1da)]?.[_0x2dd60f(0x1cd)])[_0x2dd60f(0x1c8)]();}function getDbtableConfig(_0x595181){const _0x1fc75f=a50_0x354877,_0x478e2c=_0x595181[_0x1fc75f(0x1bd)]??_0x595181[_0x1fc75f(0x1ca)];return _0x478e2c&&typeof _0x478e2c===_0x1fc75f(0x1be)?_0x478e2c:{};}export function isDbTableBackedDataset(_0x1899e6){const _0x2f4109=a50_0x354877,_0xf31bf2=getDatasetSource(_0x1899e6);if(_0xf31bf2===_0x2f4109(0x1d6))return![];const _0x70fea8=getDbtableConfig(_0x1899e6),_0x5914f0=_0x70fea8[_0x2f4109(0x1dc)]??_0x70fea8['id'],_0x2ca2ce=valueToString(_0x70fea8[_0x2f4109(0x1c0)]??_0x1899e6[_0x2f4109(0x1c0)]??_0x1899e6[_0x2f4109(0x1da)]?.[_0x2f4109(0x1c0)]);return _0x5914f0!==undefined&&_0x5914f0!==null&&_0x2ca2ce[_0x2f4109(0x1d5)]>0x0;}export function filterDbTableBackedDatasets(_0x4e2d08){const _0x313498=a50_0x354877;return _0x4e2d08[_0x313498(0x1dd)](_0x40a582=>isDbTableBackedDataset(_0x40a582));}function a50_0x512a(){const _0x18c193=['code','datasetName','当前数据集\x20\x22','原因:schema\x20introspection\x20与\x20custom\x20SQL\x20需要\x20source=DB_TABLE、dbtableConfig.dbId、dbtableConfig.tableName\x20与数据库连接上下文。','\x20类型,没有可用于\x20','length','METADATA','27XswfaG','1410542ewNuGc','7502138lHnReU','dataset','UNKNOWN','dbId','filter','78cHIguT','\x20是\x20','4841264OIZoDq','lovrabet\x20data\x20getOne\x20--code\x20<datasetCode>\x20--params\x20\x27{\x22id\x22:123}\x27\x20--format\x20compress','dbtableConfig','object','name','tableName','datasetCode','10540072PtRNBD','lovrabet','请先将该数据集升级/迁移为\x20DB_TABLE\x20数据集,再基于新的\x20dataset\x20code\x20继续开发。','validation','SQL\x20schema\x20validation','trim','toUpperCase','2384884ZfyPIe','dbtable','modelCode','1614903EjbCXH','sourceType','unknown','269510DXegyy'];a50_0x512a=function(){return _0x18c193;};return a50_0x512a();}export function buildDbTableBackedRequirementMessage(_0x678517,_0x449332=a50_0x354877(0x1c6)){const _0x1ec7c0=a50_0x354877,_0x166be3=getDatasetSource(_0x678517)||_0x1ec7c0(0x1db),_0x39555e=getDatasetName(_0x678517),_0x4fb80a=getDatasetCode(_0x678517),_0x1c93fc=_0x4fb80a?'\x20('+_0x4fb80a+')':'';return[_0x1ec7c0(0x1d2)+_0x39555e+'\x22'+_0x1c93fc+_0x1ec7c0(0x1ba)+_0x166be3+_0x1ec7c0(0x1d4)+_0x449332+'\x20的\x20DB_TABLE\x20数据源上下文。',_0x1ec7c0(0x1d3),_0x1ec7c0(0x1c4),'如果只是查看运行态真实行数据,请切换到\x20lovrabet\x20CLI:'+RUNTIME_DATA_ACCESS_COMMANDS[_0x1ec7c0(0x1dd)]+';'+RUNTIME_DATA_ACCESS_COMMANDS['getOne']+'。']['join']('\x20');}export function assertDatasetIsDbTableBacked(_0x4946d4,_0x5a1d0b){const _0x5c7929=a50_0x354877;if(!isDbTableBackedDataset(_0x4946d4))throw CliErrors[_0x5c7929(0x1c5)](buildDbTableBackedRequirementMessage(_0x4946d4,_0x5a1d0b));}