@lovrabet/rabetbase-cli 2.1.12-beta.0 → 2.1.12-beta.2

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 (200) 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/field-update.js +1 -1
  55. package/lib/commands/dataset/index.js +1 -1
  56. package/lib/commands/dataset/link-create.js +1 -1
  57. package/lib/commands/dataset/link-delete.js +1 -1
  58. package/lib/commands/dataset/link-shared.js +1 -1
  59. package/lib/commands/dataset/link-update.js +1 -1
  60. package/lib/commands/dataset/links.js +1 -1
  61. package/lib/commands/dataset/list.js +1 -1
  62. package/lib/commands/dataset/operations.js +1 -1
  63. package/lib/commands/db/analyze-cancel.js +1 -1
  64. package/lib/commands/db/analyze-start.js +1 -1
  65. package/lib/commands/db/analyze-status.js +1 -1
  66. package/lib/commands/db/create.js +1 -1
  67. package/lib/commands/db/delete.js +1 -1
  68. package/lib/commands/db/detail.js +1 -1
  69. package/lib/commands/db/diff.js +1 -1
  70. package/lib/commands/db/index.js +1 -1
  71. package/lib/commands/db/list.js +1 -1
  72. package/lib/commands/db/shared.js +1 -1
  73. package/lib/commands/db/tables.js +1 -1
  74. package/lib/commands/db/test.js +1 -1
  75. package/lib/commands/db/update.js +1 -1
  76. package/lib/commands/doctor.js +1 -1
  77. package/lib/commands/init/index.js +1 -1
  78. package/lib/commands/issue/index.js +1 -1
  79. package/lib/commands/issue/nudge.js +1 -0
  80. package/lib/commands/issue/report.js +1 -1
  81. package/lib/commands/issue/shared.js +1 -0
  82. package/lib/commands/logs/index.js +1 -1
  83. package/lib/commands/menu/index.js +1 -1
  84. package/lib/commands/menu/shared/compare-table.js +1 -1
  85. package/lib/commands/menu/shared/index.js +1 -1
  86. package/lib/commands/menu/shared/inquirer.js +1 -1
  87. package/lib/commands/menu/shared/local-pages.js +1 -1
  88. package/lib/commands/menu/shared/logic.js +1 -1
  89. package/lib/commands/menu/shared/service.js +1 -1
  90. package/lib/commands/menu/shared/sync-core.js +1 -1
  91. package/lib/commands/menu/shared/update-core.js +1 -1
  92. package/lib/commands/menu/shared/valid-url.js +1 -1
  93. package/lib/commands/menu/sync.js +1 -1
  94. package/lib/commands/menu/update.js +1 -1
  95. package/lib/commands/page/generate-start.js +1 -1
  96. package/lib/commands/page/generate-status.js +1 -1
  97. package/lib/commands/page/index.js +1 -1
  98. package/lib/commands/page/pull.js +1 -1
  99. package/lib/commands/page/push.js +1 -1
  100. package/lib/commands/page/shared.js +1 -1
  101. package/lib/commands/page/standard-page-status.js +1 -1
  102. package/lib/commands/page/sync.js +1 -1
  103. package/lib/commands/project/create/enhanced-guided-create.js +1 -1
  104. package/lib/commands/project/create/format-elapsed.js +1 -1
  105. package/lib/commands/project/create/main.js +1 -1
  106. package/lib/commands/project/create/non-interactive.js +1 -1
  107. package/lib/commands/project/create/project-template-path.js +1 -1
  108. package/lib/commands/project/create/use-copy-project-template.js +1 -1
  109. package/lib/commands/project/create/use-format-code.js +1 -1
  110. package/lib/commands/project/create/use-install-dependencies.js +1 -1
  111. package/lib/commands/project/index.js +1 -1
  112. package/lib/commands/project/init.js +1 -1
  113. package/lib/commands/project/upgrade.js +1 -1
  114. package/lib/commands/registry.js +1 -1
  115. package/lib/commands/run/index.js +1 -1
  116. package/lib/commands/schema.js +1 -1
  117. package/lib/commands/skill/index.js +1 -1
  118. package/lib/commands/sql/create.js +1 -1
  119. package/lib/commands/sql/delete.js +1 -1
  120. package/lib/commands/sql/detail.js +1 -1
  121. package/lib/commands/sql/exec.js +1 -1
  122. package/lib/commands/sql/index.js +1 -1
  123. package/lib/commands/sql/list.js +1 -1
  124. package/lib/commands/sql/pull.js +1 -1
  125. package/lib/commands/sql/push.js +1 -1
  126. package/lib/commands/sql/save.js +1 -1
  127. package/lib/commands/sql/shared.js +1 -1
  128. package/lib/commands/sql/status.js +1 -1
  129. package/lib/commands/sql/validate.js +1 -1
  130. package/lib/config/schema.js +1 -1
  131. package/lib/constant/cdn.js +1 -1
  132. package/lib/constant/cli.js +1 -1
  133. package/lib/constant/defaults.js +1 -1
  134. package/lib/constant/domain.js +1 -1
  135. package/lib/constant/env.js +1 -1
  136. package/lib/constant/output.js +1 -1
  137. package/lib/constant/paths.js +1 -1
  138. package/lib/constant/risk.js +1 -1
  139. package/lib/context.js +1 -1
  140. package/lib/core/alias-resolver.js +1 -1
  141. package/lib/core/api-client.js +1 -1
  142. package/lib/core/bff/config.js +1 -1
  143. package/lib/core/bff/file-system.js +1 -1
  144. package/lib/core/bff/hash.js +1 -1
  145. package/lib/core/bff/lock.js +1 -1
  146. package/lib/core/bff/utils.js +1 -1
  147. package/lib/core/db-resolver.js +1 -1
  148. package/lib/core/page/file-system.js +1 -1
  149. package/lib/core/page/hash.js +1 -1
  150. package/lib/core/page/lock.js +1 -1
  151. package/lib/core/sql-sync/config.js +1 -1
  152. package/lib/core/sql-sync/file-system.js +1 -1
  153. package/lib/core/sql-sync/hash.js +1 -1
  154. package/lib/core/sql-sync/lock.js +1 -1
  155. package/lib/core/sql-sync/utils.js +1 -1
  156. package/lib/core/sql-validator.js +1 -1
  157. package/lib/errors.js +1 -1
  158. package/lib/framework/build-all-flags.js +1 -1
  159. package/lib/framework/flags.js +1 -1
  160. package/lib/framework/help.js +1 -1
  161. package/lib/framework/index.js +1 -1
  162. package/lib/framework/output.js +1 -1
  163. package/lib/framework/response.js +1 -1
  164. package/lib/framework/runner-alias.js +1 -1
  165. package/lib/framework/runner.js +1 -1
  166. package/lib/framework/schema-export.js +1 -1
  167. package/lib/framework/types.js +1 -1
  168. package/lib/generated/build-info.js +1 -1
  169. package/lib/help.js +1 -1
  170. package/lib/skills/main.js +1 -1
  171. package/lib/skills/npx-skills-add.js +1 -1
  172. package/lib/telemetry/cli-command-trace.js +1 -1
  173. package/lib/telemetry/cli-help-trace.js +1 -1
  174. package/lib/telemetry/ensure-cli-otel-config.js +1 -1
  175. package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
  176. package/lib/telemetry/send-cli-trace-log.js +1 -1
  177. package/lib/telemetry/send-platform-issue-collect-log.js +1 -1
  178. package/lib/utils/ai_config.js +1 -1
  179. package/lib/utils/apply-jq-filter.js +1 -1
  180. package/lib/utils/cdn-config.js +1 -1
  181. package/lib/utils/check-sdk-version.js +1 -1
  182. package/lib/utils/cli-version-check.js +1 -1
  183. package/lib/utils/cli-version-policy.js +1 -1
  184. package/lib/utils/config.js +1 -1
  185. package/lib/utils/copy-directory.js +1 -1
  186. package/lib/utils/entity-with-id.js +1 -1
  187. package/lib/utils/file-utils.js +1 -1
  188. package/lib/utils/guides-cdn.js +1 -1
  189. package/lib/utils/http-client.js +1 -1
  190. package/lib/utils/is-non-interactive.js +1 -1
  191. package/lib/utils/logger.js +1 -1
  192. package/lib/utils/params.js +1 -1
  193. package/lib/utils/platform.js +1 -1
  194. package/lib/utils/rules-cdn.js +1 -1
  195. package/lib/utils/sleep.js +1 -1
  196. package/lib/utils/template-replacer.js +1 -1
  197. package/lib/utils/version.js +1 -1
  198. package/lib/utils/with-active-cookie.js +1 -1
  199. package/lib/utils/write-cli-side-channel.js +1 -1
  200. package/package.json +3 -2
@@ -1 +1 @@
1
- const a32_0x1bd07c=a32_0x3739;function a32_0x11c1(){const _0x4df4be=['datasetId','bool','27swNibv','functions','would_push','HOOK','attempted','length','101600qxqZNu','Cannot\x20resolve\x20dataset\x20for\x20\x22','6985062PPuDyY','operationType','type','Run\x20`','create','parse','str','ENDPOINT','code','version','update','toISOString','372BKiXND','message','Push\x20only\x20the\x20named\x20function\x20(requires\x20--type)','join','/api/management/library/scripts/save','force','Would\x20inspect\x20','get','push','filePath','BFF\x20HOOK\x20','string','lockFilePath','alias','scriptsRoot','18kPjKqq','functionNode','1298312SBVGdY','remoteId','some','script','23191420IJziio','high-risk-write','validation','3266776fYSFYf','utf8','cleared','apiDir','COMMON','unchanged','\x20local\x20BFF\x20script(s)\x20for\x20push\x20and\x20clear\x20runtime\x20cache\x20if\x20files\x20are\x20uploaded','823913AeXUBt','Push\x20local\x20BFF\x20scripts\x20to\x20remote','\x20failed,\x20','has','POST','appCode','6830JaJzbj','Push\x20only\x20this\x20script\x20type','\x22.\x20','aliasToDatasetCode','boolean','Lock\x20file\x20not\x20settled\x20after\x20push\x20for\x20','\x22\x20not\x20found\x20after\x20ensureLockScope.','datasetCode','Force\x20push\x20ignoring\x20hash\x20protection','status','map','\x20uploaded,\x20','name','lockKey','Runtime\x20script\x20cache\x20cleared.','\x20skipped,\x20','--name\x20requires\x20--type\x20to\x20identify\x20the\x20function.','set'];a32_0x11c1=function(){return _0x4df4be;};return a32_0x11c1();}(function(_0x5c8762,_0xc4b996){const _0x1f4204=a32_0x3739,_0x32788b=_0x5c8762();while(!![]){try{const _0x5edf5c=-parseInt(_0x1f4204(0x1b0))/0x1+-parseInt(_0x1f4204(0x1b6))/0x2*(parseInt(_0x1f4204(0x191))/0x3)+-parseInt(_0x1f4204(0x1a9))/0x4+-parseInt(_0x1f4204(0x183))/0x5*(-parseInt(_0x1f4204(0x1a0))/0x6)+parseInt(_0x1f4204(0x185))/0x7+-parseInt(_0x1f4204(0x1a2))/0x8*(parseInt(_0x1f4204(0x1ca))/0x9)+parseInt(_0x1f4204(0x1a6))/0xa;if(_0x5edf5c===_0xc4b996)break;else _0x32788b['push'](_0x32788b['shift']());}catch(_0x3b3e52){_0x32788b['push'](_0x32788b['shift']());}}}(a32_0x11c1,0xc9e9a));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';import{sleep}from'../../utils/sleep.js';import{CliErrors}from'../../errors.js';function a32_0x3739(_0x5d7de2,_0x3c6295){_0x5d7de2=_0x5d7de2-0x182;const _0x11c1cc=a32_0x11c1();let _0x3739f5=_0x11c1cc[_0x5d7de2];return _0x3739f5;}import{CLI_BIN_NAME}from'../../constant/cli.js';import{assertDatasetSupportsLocalDevelopment}from'../../commands/dataset/capability.js';const CACHE_CLEAR_ATTEMPTS=0x2,CACHE_CLEAR_INTERVAL_MS=0x12c;export const bffPush={'service':'bff','command':'push','description':a32_0x1bd07c(0x1b1),'risk':a32_0x1bd07c(0x1a7),'flags':[{'name':a32_0x1bd07c(0x187),'type':a32_0x1bd07c(0x19c),'description':a32_0x1bd07c(0x1b7),'enum':[a32_0x1bd07c(0x1ad),a32_0x1bd07c(0x18c),a32_0x1bd07c(0x1cd)]},{'name':a32_0x1bd07c(0x1c2),'type':a32_0x1bd07c(0x19c),'description':a32_0x1bd07c(0x193)},{'name':a32_0x1bd07c(0x196),'type':a32_0x1bd07c(0x1ba),'description':a32_0x1bd07c(0x1be)}],async 'dryRun'(_0x44ad3a){const _0x119ad0=a32_0x1bd07c,_0x34ad2a=loadBffProjectConfig(_0x44ad3a['appCode']),_0x4b0388=await readBffLockFile(_0x34ad2a[_0x119ad0(0x19d)]),{appLock:_0x1b6f55}=ensureLockScope(_0x4b0388??createEmptyBffLock(),_0x44ad3a[_0x119ad0(0x1b5)],_0x34ad2a[_0x119ad0(0x19f)],_0x119ad0(0x199)),_0x49aeee=await getTargetFunctions(_0x34ad2a,_0x44ad3a),_0x27fdab=_0x44ad3a[_0x119ad0(0x1c9)]('force'),_0x46c4fd=[];for(const _0x52b9ba of _0x49aeee){const _0x5d5d64=await computeFileHash(_0x52b9ba[_0x119ad0(0x19a)]),_0x1658f1=_0x1b6f55['functions'][_0x52b9ba[_0x119ad0(0x1c3)]],_0x1607d5=!!_0x1658f1&&_0x1658f1['hash']===_0x5d5d64;_0x46c4fd[_0x119ad0(0x199)]({'lockKey':_0x52b9ba[_0x119ad0(0x1c3)],'filePath':_0x52b9ba[_0x119ad0(0x19a)],'remoteId':_0x1658f1?.[_0x119ad0(0x1a3)]??null,'mode':_0x1658f1?.['remoteId']?_0x119ad0(0x18f):_0x119ad0(0x189),'status':!_0x27fdab&&_0x1607d5?_0x119ad0(0x1ae):_0x119ad0(0x1cc)});}return{'method':_0x119ad0(0x1b4),'url':_0x119ad0(0x195),'body':{'appCode':_0x44ad3a[_0x119ad0(0x1b5)],'force':_0x27fdab,'files':_0x46c4fd,'cacheClearAtRuntime':_0x46c4fd['some'](_0x25781f=>_0x25781f[_0x119ad0(0x1bf)]===_0x119ad0(0x1cc)),'cacheClearAtRuntimeTimes':_0x46c4fd[_0x119ad0(0x1a4)](_0x28c69a=>_0x28c69a['status']===_0x119ad0(0x1cc))?CACHE_CLEAR_ATTEMPTS:0x0},'description':_0x119ad0(0x197)+_0x46c4fd[_0x119ad0(0x182)]+_0x119ad0(0x1af)};},async 'execute'(_0x5cad47){const _0xd2a20f=a32_0x1bd07c,_0x69bd1c=loadBffProjectConfig(_0x5cad47[_0xd2a20f(0x1b5)]),_0x34a24c=await readBffLockFile(_0x69bd1c[_0xd2a20f(0x19d)]),{lockData:_0x3248c1,appLock:_0xc0206e}=ensureLockScope(_0x34a24c??createEmptyBffLock(),_0x5cad47[_0xd2a20f(0x1b5)],_0x69bd1c[_0xd2a20f(0x19f)],_0xd2a20f(0x199)),_0x31eb9b=await getTargetFunctions(_0x69bd1c,_0x5cad47);if(_0x31eb9b[_0xd2a20f(0x182)]===0x0)return{'ok':!![],'data':{'uploaded':[],'skipped':[],'failed':[]},'message':'No\x20local\x20BFF\x20functions\x20found.'};const _0x9827e=_0x5cad47['bool'](_0xd2a20f(0x196)),_0x348f15=JSON[_0xd2a20f(0x18a)](JSON['stringify'](_0x3248c1)),_0x206dca=_0x348f15['apps'][_0x5cad47[_0xd2a20f(0x1b5)]];if(!_0x206dca)throw new Error('Lock\x20scope\x20for\x20app\x20\x22'+_0x5cad47[_0xd2a20f(0x1b5)]+_0xd2a20f(0x1bc));const _0x3facc1=await buildHookMaps(_0x5cad47[_0xd2a20f(0x1b5)],_0x5cad47[_0xd2a20f(0x1ac)],_0x31eb9b,_0x206dca),_0x214ffc=[],_0x30a8ba=[],_0x37268b=[];for(const _0x5160db of _0x31eb9b){const _0x1fd3c9=await computeFileHash(_0x5160db[_0xd2a20f(0x19a)]),_0x5ac3ac=_0x206dca[_0xd2a20f(0x1cb)][_0x5160db['lockKey']];if(!_0x9827e&&_0x5ac3ac&&_0x5ac3ac['hash']===_0x1fd3c9){_0x30a8ba[_0xd2a20f(0x199)]({'lockKey':_0x5160db[_0xd2a20f(0x1c3)],'reason':_0xd2a20f(0x1ae)});continue;}try{await uploadSingleFunction(_0x5cad47[_0xd2a20f(0x1b5)],_0x5160db,_0x206dca,_0x3facc1);const _0x49f44b=_0x206dca[_0xd2a20f(0x1cb)][_0x5160db[_0xd2a20f(0x1c3)]];_0x214ffc['push']({'lockKey':_0x5160db[_0xd2a20f(0x1c3)],'remoteId':_0x49f44b?.[_0xd2a20f(0x1a3)]??0x0});}catch(_0x5b9fd7){_0x37268b[_0xd2a20f(0x199)]({'lockKey':_0x5160db[_0xd2a20f(0x1c3)],'error':_0x5b9fd7 instanceof Error?_0x5b9fd7[_0xd2a20f(0x192)]:String(_0x5b9fd7)});}}_0x206dca['lastSync']=new Date()[_0xd2a20f(0x190)](),await writeBffLockFile(_0x69bd1c[_0xd2a20f(0x19d)],_0x348f15),await waitForUploadedLockEntries(_0x69bd1c[_0xd2a20f(0x19d)],_0x5cad47[_0xd2a20f(0x1b5)],_0x214ffc[_0xd2a20f(0x1c0)](_0x41fa3b=>_0x41fa3b[_0xd2a20f(0x1c3)]));let _0xe240ca={'attempted':![],'cleared':![]};if(_0x214ffc[_0xd2a20f(0x182)]>0x0)try{let _0x5d5d68='';for(let _0x2875b4=0x0;_0x2875b4<CACHE_CLEAR_ATTEMPTS;_0x2875b4+=0x1){_0x5d5d68=await clearBffScriptCache(),_0x2875b4<CACHE_CLEAR_ATTEMPTS-0x1&&await sleep(CACHE_CLEAR_INTERVAL_MS);}_0xe240ca={'attempted':!![],'cleared':!![],'message':_0x5d5d68||_0xd2a20f(0x1c4)};}catch(_0x29683b){_0xe240ca={'attempted':!![],'cleared':![],'error':_0x29683b instanceof Error?_0x29683b['message']:String(_0x29683b)};}const _0xaea9f8=_0x37268b[_0xd2a20f(0x182)]===0x0&&(_0xe240ca[_0xd2a20f(0x1ce)]?_0xe240ca['cleared']:!![]),_0x3f6701=_0xe240ca[_0xd2a20f(0x1ce)]?_0xe240ca[_0xd2a20f(0x1ab)]?'runtime\x20cache\x20cleared':'runtime\x20cache\x20clear\x20failed':'runtime\x20cache\x20not\x20needed';return{'ok':_0xaea9f8,'data':{'uploaded':_0x214ffc,'skipped':_0x30a8ba,'failed':_0x37268b,'cacheClear':_0xe240ca},'message':'Push\x20complete:\x20'+_0x214ffc['length']+_0xd2a20f(0x1c1)+_0x30a8ba[_0xd2a20f(0x182)]+_0xd2a20f(0x1c5)+_0x37268b['length']+_0xd2a20f(0x1b2)+_0x3f6701};}};async function getTargetFunctions(_0x2fd1d1,_0x5c55cd){const _0x19cadf=a32_0x1bd07c,_0x20ac62=_0x5c55cd[_0x19cadf(0x18b)](_0x19cadf(0x187)),_0x2cdf9f=_0x5c55cd[_0x19cadf(0x18b)]('name'),_0x9a52f5=normalizeBffType(_0x20ac62)??undefined;if(_0x2cdf9f&&!_0x9a52f5)throw CliErrors[_0x19cadf(0x1a8)](_0x19cadf(0x1c6));const _0x19b82e=await scanLocalBffFunctions(_0x2fd1d1,_0x9a52f5);if(_0x2cdf9f){const _0x30576b=_0x19b82e['filter'](_0x4d32af=>_0x4d32af[_0x19cadf(0x1c2)]===_0x2cdf9f);if(_0x30576b[_0x19cadf(0x182)]===0x0)throw CliErrors[_0x19cadf(0x1a8)]('Local\x20function\x20not\x20found:\x20'+_0x9a52f5+'/'+_0x2cdf9f);return _0x30576b;}return _0x19b82e;}async function buildHookMaps(_0x4709f9,_0x286227,_0x45c206,_0x597a1b){const _0x54edad=a32_0x1bd07c,_0x360813=_0x45c206[_0x54edad(0x1a4)](_0x33dacf=>_0x33dacf['type']===_0x54edad(0x1cd));if(!_0x360813)return{'aliasToDatasetCode':new Map(),'datasetCodeToDataset':new Map()};const _0x3aa924=loadAliasMap(_0x286227,undefined,resolveApiFilePath(_0x286227,_0x4709f9)),_0x200deb=new Map(_0x3aa924['map'](_0x127701=>[_0x127701['alias'],_0x127701[_0x54edad(0x1bd)]]));for(const _0x28ad8c of Object['values'](_0x597a1b[_0x54edad(0x1cb)])){_0x28ad8c['alias']&&_0x28ad8c[_0x54edad(0x1bd)]&&!_0x200deb[_0x54edad(0x1b3)](_0x28ad8c[_0x54edad(0x19e)])&&_0x200deb[_0x54edad(0x1c7)](_0x28ad8c[_0x54edad(0x19e)],_0x28ad8c['datasetCode']);}const _0x5cbd6c=await listDatasets(_0x4709f9),_0x58308b=new Map(_0x5cbd6c[_0x54edad(0x1c0)](_0x32c721=>[_0x32c721[_0x54edad(0x18d)],_0x32c721]));return{'aliasToDatasetCode':_0x200deb,'datasetCodeToDataset':_0x58308b};}async function uploadSingleFunction(_0x4b5026,_0x110184,_0x2f39a5,_0x56199d){const _0x848ddd=a32_0x1bd07c,_0x32b33b=await readFile(_0x110184['filePath'],_0x848ddd(0x1aa)),_0x1df2a3=await computeFileHash(_0x110184[_0x848ddd(0x19a)]),_0x24748a=_0x2f39a5['functions'][_0x110184[_0x848ddd(0x1c3)]];if(_0x24748a?.[_0x848ddd(0x1a3)]&&_0x24748a[_0x848ddd(0x18e)]==null)throw CliErrors['validation'](_0x110184[_0x848ddd(0x1c3)]+':\x20missing\x20remote\x20version.\x20Run\x20`push`\x20after\x20`pull`\x20to\x20sync\x20version\x20info.');let _0x17ce9e=extractScriptDescription(_0x32b33b);if(!_0x17ce9e&&_0x24748a?.[_0x848ddd(0x1a3)]){const _0x48e12a=await getBffScriptInfo(_0x24748a[_0x848ddd(0x1a3)]);_0x17ce9e=_0x48e12a['description']||undefined;}const _0x3852dd={'appCode':_0x4b5026,'functionName':_0x110184[_0x848ddd(0x1c2)],'scriptType':_0x110184['type'],'scriptContent':_0x32b33b};if(_0x24748a?.[_0x848ddd(0x1a3)])_0x3852dd['id']=_0x24748a[_0x848ddd(0x1a3)];if(_0x24748a?.[_0x848ddd(0x18e)]!=null)_0x3852dd['version']=_0x24748a[_0x848ddd(0x18e)];if(_0x17ce9e)_0x3852dd['description']=_0x17ce9e;if(_0x110184[_0x848ddd(0x187)]==='HOOK'){const _0x3f8ba0=_0x110184[_0x848ddd(0x19e)];if(!_0x3f8ba0||!_0x110184[_0x848ddd(0x186)]||!_0x110184[_0x848ddd(0x1a1)])throw CliErrors[_0x848ddd(0x1a8)]('Incomplete\x20HOOK\x20path:\x20'+_0x110184[_0x848ddd(0x1c3)]);const _0x549aed=_0x56199d[_0x848ddd(0x1b9)][_0x848ddd(0x198)](_0x3f8ba0)??_0x24748a?.['datasetCode']??_0x3f8ba0,_0x4aacd6=_0x56199d['datasetCodeToDataset'][_0x848ddd(0x198)](_0x549aed);if(!_0x4aacd6)throw CliErrors[_0x848ddd(0x1a8)](_0x848ddd(0x184)+_0x3f8ba0+_0x848ddd(0x1b8)+(_0x848ddd(0x188)+CLI_BIN_NAME+'\x20api\x20pull`\x20to\x20refresh\x20api.ts,\x20or\x20verify\x20the\x20dataset\x20exists.'));assertDatasetSupportsLocalDevelopment(_0x4aacd6,_0x848ddd(0x19b)+_0x110184[_0x848ddd(0x1c3)]),_0x3852dd[_0x848ddd(0x1c8)]=_0x4aacd6['id'],_0x3852dd[_0x848ddd(0x186)]=_0x110184[_0x848ddd(0x186)],_0x3852dd[_0x848ddd(0x1a1)]=_0x110184[_0x848ddd(0x1a1)];}const _0x267cce=await saveBffScript(_0x3852dd),_0xfbb374=_0x267cce['id'],_0x1678ed=_0x267cce[_0x848ddd(0x1a5)]??await getBffScriptInfo(_0xfbb374),_0x176cf8={'hash':_0x1df2a3,'remoteId':_0xfbb374,'version':_0x1678ed[_0x848ddd(0x18e)]};if(_0x110184['type']===_0x848ddd(0x1cd)){const _0x231143=_0x110184[_0x848ddd(0x19e)],_0x58a033=_0x56199d['aliasToDatasetCode']['get'](_0x231143)??_0x24748a?.[_0x848ddd(0x1bd)]??_0x231143;_0x56199d[_0x848ddd(0x1b9)]['has'](_0x231143)?_0x176cf8[_0x848ddd(0x19e)]=_0x231143:_0x176cf8[_0x848ddd(0x19e)]=_0x24748a?.[_0x848ddd(0x19e)],_0x176cf8[_0x848ddd(0x1bd)]=_0x58a033,_0x176cf8[_0x848ddd(0x186)]=_0x110184['operationType'],_0x176cf8[_0x848ddd(0x1a1)]=_0x110184[_0x848ddd(0x1a1)];}_0x2f39a5[_0x848ddd(0x1cb)][_0x110184[_0x848ddd(0x1c3)]]=_0x176cf8;}const LOCK_SETTLE_RETRY_COUNT=0x14,LOCK_SETTLE_DELAY_MS=0x64;async function waitForUploadedLockEntries(_0x46e190,_0x4e7d3c,_0x3c4a08){const _0x48c72c=a32_0x1bd07c;if(_0x3c4a08[_0x48c72c(0x182)]===0x0)return;for(let _0x43b059=0x0;_0x43b059<LOCK_SETTLE_RETRY_COUNT;_0x43b059+=0x1){const _0x32a5f8=await readBffLockFile(_0x46e190),_0x57eec1=_0x32a5f8?.['apps']?.[_0x4e7d3c]?.[_0x48c72c(0x1cb)]??{},_0x62f979=_0x3c4a08['every'](_0x3ae559=>!!_0x57eec1[_0x3ae559]?.[_0x48c72c(0x1a3)]);if(_0x62f979)return;await sleep(LOCK_SETTLE_DELAY_MS);}throw new Error(_0x48c72c(0x1bb)+_0x3c4a08[_0x48c72c(0x194)](',\x20')+'.');}
1
+ const a32_0xd5035f=a32_0x5bfe;(function(_0x819273,_0x518404){const _0x3f0eb3=a32_0x5bfe,_0x43d6b0=_0x819273();while(!![]){try{const _0x22ea2a=-parseInt(_0x3f0eb3(0x14b))/0x1*(parseInt(_0x3f0eb3(0x133))/0x2)+-parseInt(_0x3f0eb3(0x13c))/0x3+-parseInt(_0x3f0eb3(0x13e))/0x4+-parseInt(_0x3f0eb3(0x14e))/0x5+parseInt(_0x3f0eb3(0x128))/0x6*(-parseInt(_0x3f0eb3(0x15b))/0x7)+-parseInt(_0x3f0eb3(0x120))/0x8+parseInt(_0x3f0eb3(0x132))/0x9*(parseInt(_0x3f0eb3(0x157))/0xa);if(_0x22ea2a===_0x518404)break;else _0x43d6b0['push'](_0x43d6b0['shift']());}catch(_0x3c3ec7){_0x43d6b0['push'](_0x43d6b0['shift']());}}}(a32_0x2714,0x20689));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';function a32_0x2714(){const _0x52beac=['\x20local\x20BFF\x20script(s)\x20for\x20push\x20and\x20clear\x20runtime\x20cache\x20if\x20files\x20are\x20uploaded','1259816XBXBBC','\x20api\x20pull`\x20to\x20refresh\x20api.ts,\x20or\x20verify\x20the\x20dataset\x20exists.','type','join','BFF\x20HOOK\x20','Push\x20complete:\x20','\x22.\x20','Cannot\x20resolve\x20dataset\x20for\x20\x22','27726SyMQJg','apiDir','\x20skipped,\x20','would_push','Push\x20local\x20BFF\x20scripts\x20to\x20remote','has','description','filePath','scriptsRoot','map','81XuUsOx','7118zGxrpI','str','No\x20local\x20BFF\x20functions\x20found.','message','boolean','Incomplete\x20HOOK\x20path:\x20','force','lockFilePath','apps','523077pMEcHx','alias','798564oELmtj','Push\x20only\x20this\x20script\x20type','functions','runtime\x20cache\x20clear\x20failed','get','push','version','cleared','values','\x20failed,\x20','COMMON','utf8',':\x20missing\x20remote\x20version.\x20Run\x20`push`\x20after\x20`pull`\x20to\x20sync\x20version\x20info.','49LbziHV','status','unchanged','688305uYlSkn','ENDPOINT','validation','update','every','datasetCodeToDataset','string','datasetCode','Lock\x20scope\x20for\x20app\x20\x22','1120690ztGezr','hash','name','functionNode','49vUcLwA','HOOK','bool','Force\x20push\x20ignoring\x20hash\x20protection','POST','appCode','aliasToDatasetCode','length','/api/management/library/scripts/save','filter','remoteId','operationType','lastSync','lockKey','runtime\x20cache\x20cleared','Runtime\x20script\x20cache\x20cleared.','attempted','toISOString','some'];a32_0x2714=function(){return _0x52beac;};return a32_0x2714();}import{extractScriptDescription}from'../../core/bff/utils.js';import{sleep}from'../../utils/sleep.js';import{CliErrors}from'../../errors.js';function a32_0x5bfe(_0x20e6eb,_0x4f5b78){_0x20e6eb=_0x20e6eb-0x119;const _0x27145a=a32_0x2714();let _0x5bfe93=_0x27145a[_0x20e6eb];return _0x5bfe93;}import{CLI_BIN_NAME}from'../../constant/cli.js';import{assertDatasetSupportsLocalDevelopment}from'../../commands/dataset/capability.js';const CACHE_CLEAR_ATTEMPTS=0x2,CACHE_CLEAR_INTERVAL_MS=0x12c;export const bffPush={'service':'bff','command':a32_0xd5035f(0x143),'description':a32_0xd5035f(0x12c),'risk':'high-risk-write','flags':[{'name':a32_0xd5035f(0x122),'type':a32_0xd5035f(0x154),'description':a32_0xd5035f(0x13f),'enum':[a32_0xd5035f(0x148),a32_0xd5035f(0x14f),a32_0xd5035f(0x15c)]},{'name':a32_0xd5035f(0x159),'type':a32_0xd5035f(0x154),'description':'Push\x20only\x20the\x20named\x20function\x20(requires\x20--type)'},{'name':a32_0xd5035f(0x139),'type':a32_0xd5035f(0x137),'description':a32_0xd5035f(0x15e)}],async 'dryRun'(_0x53e72d){const _0x10265d=a32_0xd5035f,_0x2ff9a0=loadBffProjectConfig(_0x53e72d[_0x10265d(0x160)]),_0x48718d=await readBffLockFile(_0x2ff9a0[_0x10265d(0x13a)]),{appLock:_0x258f4c}=ensureLockScope(_0x48718d??createEmptyBffLock(),_0x53e72d[_0x10265d(0x160)],_0x2ff9a0[_0x10265d(0x130)],'push'),_0x2a3650=await getTargetFunctions(_0x2ff9a0,_0x53e72d),_0x20b9e6=_0x53e72d[_0x10265d(0x15d)](_0x10265d(0x139)),_0x2a8b4a=[];for(const _0x58d58f of _0x2a3650){const _0x5e29a9=await computeFileHash(_0x58d58f[_0x10265d(0x12f)]),_0x20389d=_0x258f4c[_0x10265d(0x140)][_0x58d58f[_0x10265d(0x119)]],_0x2bf3d6=!!_0x20389d&&_0x20389d[_0x10265d(0x158)]===_0x5e29a9;_0x2a8b4a[_0x10265d(0x143)]({'lockKey':_0x58d58f['lockKey'],'filePath':_0x58d58f[_0x10265d(0x12f)],'remoteId':_0x20389d?.[_0x10265d(0x165)]??null,'mode':_0x20389d?.[_0x10265d(0x165)]?_0x10265d(0x151):'create','status':!_0x20b9e6&&_0x2bf3d6?_0x10265d(0x14d):_0x10265d(0x12b)});}return{'method':_0x10265d(0x15f),'url':_0x10265d(0x163),'body':{'appCode':_0x53e72d['appCode'],'force':_0x20b9e6,'files':_0x2a8b4a,'cacheClearAtRuntime':_0x2a8b4a[_0x10265d(0x11e)](_0x137c03=>_0x137c03[_0x10265d(0x14c)]===_0x10265d(0x12b)),'cacheClearAtRuntimeTimes':_0x2a8b4a['some'](_0x1b3a53=>_0x1b3a53[_0x10265d(0x14c)]===_0x10265d(0x12b))?CACHE_CLEAR_ATTEMPTS:0x0},'description':'Would\x20inspect\x20'+_0x2a8b4a[_0x10265d(0x162)]+_0x10265d(0x11f)};},async 'execute'(_0x4447a1){const _0x346358=a32_0xd5035f,_0x5ead31=loadBffProjectConfig(_0x4447a1[_0x346358(0x160)]),_0x2ee21e=await readBffLockFile(_0x5ead31[_0x346358(0x13a)]),{lockData:_0x383f9b,appLock:_0x40dbac}=ensureLockScope(_0x2ee21e??createEmptyBffLock(),_0x4447a1[_0x346358(0x160)],_0x5ead31['scriptsRoot'],_0x346358(0x143)),_0x210a65=await getTargetFunctions(_0x5ead31,_0x4447a1);if(_0x210a65[_0x346358(0x162)]===0x0)return{'ok':!![],'data':{'uploaded':[],'skipped':[],'failed':[]},'message':_0x346358(0x135)};const _0x11afa7=_0x4447a1['bool'](_0x346358(0x139)),_0x41cb49=JSON['parse'](JSON['stringify'](_0x383f9b)),_0x38e8b6=_0x41cb49[_0x346358(0x13b)][_0x4447a1[_0x346358(0x160)]];if(!_0x38e8b6)throw new Error(_0x346358(0x156)+_0x4447a1[_0x346358(0x160)]+'\x22\x20not\x20found\x20after\x20ensureLockScope.');const _0x5ca900=await buildHookMaps(_0x4447a1[_0x346358(0x160)],_0x4447a1[_0x346358(0x129)],_0x210a65,_0x38e8b6),_0x34e25c=[],_0x300274=[],_0x4ed2f7=[];for(const _0x509eb8 of _0x210a65){const _0x411036=await computeFileHash(_0x509eb8[_0x346358(0x12f)]),_0x27f362=_0x38e8b6[_0x346358(0x140)][_0x509eb8['lockKey']];if(!_0x11afa7&&_0x27f362&&_0x27f362['hash']===_0x411036){_0x300274[_0x346358(0x143)]({'lockKey':_0x509eb8['lockKey'],'reason':_0x346358(0x14d)});continue;}try{await uploadSingleFunction(_0x4447a1['appCode'],_0x509eb8,_0x38e8b6,_0x5ca900);const _0x506878=_0x38e8b6[_0x346358(0x140)][_0x509eb8[_0x346358(0x119)]];_0x34e25c[_0x346358(0x143)]({'lockKey':_0x509eb8[_0x346358(0x119)],'remoteId':_0x506878?.[_0x346358(0x165)]??0x0});}catch(_0xbfc552){_0x4ed2f7[_0x346358(0x143)]({'lockKey':_0x509eb8[_0x346358(0x119)],'error':_0xbfc552 instanceof Error?_0xbfc552['message']:String(_0xbfc552)});}}_0x38e8b6[_0x346358(0x167)]=new Date()[_0x346358(0x11d)](),await writeBffLockFile(_0x5ead31[_0x346358(0x13a)],_0x41cb49),await waitForUploadedLockEntries(_0x5ead31[_0x346358(0x13a)],_0x4447a1['appCode'],_0x34e25c[_0x346358(0x131)](_0x6ac6aa=>_0x6ac6aa[_0x346358(0x119)]));let _0x260bf3={'attempted':![],'cleared':![]};if(_0x34e25c[_0x346358(0x162)]>0x0)try{let _0x4daa58='';for(let _0x58790d=0x0;_0x58790d<CACHE_CLEAR_ATTEMPTS;_0x58790d+=0x1){_0x4daa58=await clearBffScriptCache(),_0x58790d<CACHE_CLEAR_ATTEMPTS-0x1&&await sleep(CACHE_CLEAR_INTERVAL_MS);}_0x260bf3={'attempted':!![],'cleared':!![],'message':_0x4daa58||_0x346358(0x11b)};}catch(_0x515090){_0x260bf3={'attempted':!![],'cleared':![],'error':_0x515090 instanceof Error?_0x515090[_0x346358(0x136)]:String(_0x515090)};}const _0x2c2763=_0x4ed2f7[_0x346358(0x162)]===0x0&&(_0x260bf3[_0x346358(0x11c)]?_0x260bf3[_0x346358(0x145)]:!![]),_0x5775a1=_0x260bf3[_0x346358(0x11c)]?_0x260bf3['cleared']?_0x346358(0x11a):_0x346358(0x141):'runtime\x20cache\x20not\x20needed';return{'ok':_0x2c2763,'data':{'uploaded':_0x34e25c,'skipped':_0x300274,'failed':_0x4ed2f7,'cacheClear':_0x260bf3},'message':_0x346358(0x125)+_0x34e25c['length']+'\x20uploaded,\x20'+_0x300274['length']+_0x346358(0x12a)+_0x4ed2f7[_0x346358(0x162)]+_0x346358(0x147)+_0x5775a1};}};async function getTargetFunctions(_0x3a88a3,_0x1a498b){const _0x91b42c=a32_0xd5035f,_0x8236b3=_0x1a498b[_0x91b42c(0x134)](_0x91b42c(0x122)),_0x3dbe17=_0x1a498b[_0x91b42c(0x134)](_0x91b42c(0x159)),_0x4f2d11=normalizeBffType(_0x8236b3)??undefined;if(_0x3dbe17&&!_0x4f2d11)throw CliErrors[_0x91b42c(0x150)]('--name\x20requires\x20--type\x20to\x20identify\x20the\x20function.');const _0x430c4c=await scanLocalBffFunctions(_0x3a88a3,_0x4f2d11);if(_0x3dbe17){const _0x55293e=_0x430c4c[_0x91b42c(0x164)](_0x250fab=>_0x250fab['name']===_0x3dbe17);if(_0x55293e[_0x91b42c(0x162)]===0x0)throw CliErrors['validation']('Local\x20function\x20not\x20found:\x20'+_0x4f2d11+'/'+_0x3dbe17);return _0x55293e;}return _0x430c4c;}async function buildHookMaps(_0x1db216,_0x3960d9,_0x5ce0d9,_0x1aeb43){const _0x555ca=a32_0xd5035f,_0x2c6ae4=_0x5ce0d9['some'](_0x3c43ed=>_0x3c43ed[_0x555ca(0x122)]===_0x555ca(0x15c));if(!_0x2c6ae4)return{'aliasToDatasetCode':new Map(),'datasetCodeToDataset':new Map()};const _0x215cbf=loadAliasMap(_0x3960d9,undefined,resolveApiFilePath(_0x3960d9,_0x1db216)),_0x2eaa39=new Map(_0x215cbf[_0x555ca(0x131)](_0x223717=>[_0x223717[_0x555ca(0x13d)],_0x223717[_0x555ca(0x155)]]));for(const _0x3c6cf7 of Object[_0x555ca(0x146)](_0x1aeb43[_0x555ca(0x140)])){_0x3c6cf7[_0x555ca(0x13d)]&&_0x3c6cf7[_0x555ca(0x155)]&&!_0x2eaa39[_0x555ca(0x12d)](_0x3c6cf7[_0x555ca(0x13d)])&&_0x2eaa39['set'](_0x3c6cf7[_0x555ca(0x13d)],_0x3c6cf7[_0x555ca(0x155)]);}const _0x30e471=await listDatasets(_0x1db216),_0x1cc2ea=new Map(_0x30e471[_0x555ca(0x131)](_0x2fde5e=>[_0x2fde5e['code'],_0x2fde5e]));return{'aliasToDatasetCode':_0x2eaa39,'datasetCodeToDataset':_0x1cc2ea};}async function uploadSingleFunction(_0x22cb12,_0x14a1ec,_0x56a3e4,_0x202f9f){const _0x2442a5=a32_0xd5035f,_0x540203=await readFile(_0x14a1ec['filePath'],_0x2442a5(0x149)),_0x16132a=await computeFileHash(_0x14a1ec[_0x2442a5(0x12f)]),_0x35309a=_0x56a3e4['functions'][_0x14a1ec[_0x2442a5(0x119)]];if(_0x35309a?.[_0x2442a5(0x165)]&&_0x35309a[_0x2442a5(0x144)]==null)throw CliErrors['validation'](_0x14a1ec[_0x2442a5(0x119)]+_0x2442a5(0x14a));let _0x3c4aa3=extractScriptDescription(_0x540203);if(!_0x3c4aa3&&_0x35309a?.[_0x2442a5(0x165)]){const _0x520f13=await getBffScriptInfo(_0x35309a['remoteId']);_0x3c4aa3=_0x520f13[_0x2442a5(0x12e)]||undefined;}const _0x2ff859={'appCode':_0x22cb12,'functionName':_0x14a1ec[_0x2442a5(0x159)],'scriptType':_0x14a1ec[_0x2442a5(0x122)],'scriptContent':_0x540203};if(_0x35309a?.[_0x2442a5(0x165)])_0x2ff859['id']=_0x35309a[_0x2442a5(0x165)];if(_0x35309a?.[_0x2442a5(0x144)]!=null)_0x2ff859['version']=_0x35309a[_0x2442a5(0x144)];if(_0x3c4aa3)_0x2ff859['description']=_0x3c4aa3;if(_0x14a1ec[_0x2442a5(0x122)]===_0x2442a5(0x15c)){const _0x3de7a0=_0x14a1ec[_0x2442a5(0x13d)];if(!_0x3de7a0||!_0x14a1ec[_0x2442a5(0x166)]||!_0x14a1ec[_0x2442a5(0x15a)])throw CliErrors[_0x2442a5(0x150)](_0x2442a5(0x138)+_0x14a1ec[_0x2442a5(0x119)]);const _0x57b53d=_0x202f9f[_0x2442a5(0x161)][_0x2442a5(0x142)](_0x3de7a0)??_0x35309a?.[_0x2442a5(0x155)]??_0x3de7a0,_0x5aea08=_0x202f9f[_0x2442a5(0x153)]['get'](_0x57b53d);if(!_0x5aea08)throw CliErrors[_0x2442a5(0x150)](_0x2442a5(0x127)+_0x3de7a0+_0x2442a5(0x126)+('Run\x20`'+CLI_BIN_NAME+_0x2442a5(0x121)));assertDatasetSupportsLocalDevelopment(_0x5aea08,_0x2442a5(0x124)+_0x14a1ec[_0x2442a5(0x119)]),_0x2ff859['datasetId']=_0x5aea08['id'],_0x2ff859[_0x2442a5(0x166)]=_0x14a1ec[_0x2442a5(0x166)],_0x2ff859[_0x2442a5(0x15a)]=_0x14a1ec[_0x2442a5(0x15a)];}const _0x5c5405=await saveBffScript(_0x2ff859),_0xcb2437=_0x5c5405['id'],_0x4ad903=_0x5c5405['script']??await getBffScriptInfo(_0xcb2437),_0x1ea8ab={'hash':_0x16132a,'remoteId':_0xcb2437,'version':_0x4ad903['version']};if(_0x14a1ec[_0x2442a5(0x122)]===_0x2442a5(0x15c)){const _0x476ad3=_0x14a1ec[_0x2442a5(0x13d)],_0x3ac85b=_0x202f9f[_0x2442a5(0x161)][_0x2442a5(0x142)](_0x476ad3)??_0x35309a?.[_0x2442a5(0x155)]??_0x476ad3;_0x202f9f[_0x2442a5(0x161)][_0x2442a5(0x12d)](_0x476ad3)?_0x1ea8ab['alias']=_0x476ad3:_0x1ea8ab[_0x2442a5(0x13d)]=_0x35309a?.[_0x2442a5(0x13d)],_0x1ea8ab[_0x2442a5(0x155)]=_0x3ac85b,_0x1ea8ab[_0x2442a5(0x166)]=_0x14a1ec[_0x2442a5(0x166)],_0x1ea8ab[_0x2442a5(0x15a)]=_0x14a1ec[_0x2442a5(0x15a)];}_0x56a3e4[_0x2442a5(0x140)][_0x14a1ec[_0x2442a5(0x119)]]=_0x1ea8ab;}const LOCK_SETTLE_RETRY_COUNT=0x14,LOCK_SETTLE_DELAY_MS=0x64;async function waitForUploadedLockEntries(_0x11a282,_0x1d334f,_0x3fc497){const _0x2cd658=a32_0xd5035f;if(_0x3fc497[_0x2cd658(0x162)]===0x0)return;for(let _0xa493d4=0x0;_0xa493d4<LOCK_SETTLE_RETRY_COUNT;_0xa493d4+=0x1){const _0x47c86d=await readBffLockFile(_0x11a282),_0x7e73fa=_0x47c86d?.[_0x2cd658(0x13b)]?.[_0x1d334f]?.[_0x2cd658(0x140)]??{},_0x171034=_0x3fc497[_0x2cd658(0x152)](_0xb3d5a8=>!!_0x7e73fa[_0xb3d5a8]?.[_0x2cd658(0x165)]);if(_0x171034)return;await sleep(LOCK_SETTLE_DELAY_MS);}throw new Error('Lock\x20file\x20not\x20settled\x20after\x20push\x20for\x20'+_0x3fc497[_0x2cd658(0x123)](',\x20')+'.');}
@@ -1 +1 @@
1
- const a33_0xd10583=a33_0x2561;(function(_0x3a8914,_0x4f33b4){const _0x32cdaf=a33_0x2561,_0x40251c=_0x3a8914();while(!![]){try{const _0x44cfab=-parseInt(_0x32cdaf(0x1be))/0x1*(parseInt(_0x32cdaf(0x1c7))/0x2)+parseInt(_0x32cdaf(0x1c5))/0x3+-parseInt(_0x32cdaf(0x1c9))/0x4*(-parseInt(_0x32cdaf(0x1c2))/0x5)+-parseInt(_0x32cdaf(0x1d3))/0x6+-parseInt(_0x32cdaf(0x1cc))/0x7*(-parseInt(_0x32cdaf(0x1c6))/0x8)+parseInt(_0x32cdaf(0x1c8))/0x9+-parseInt(_0x32cdaf(0x1d2))/0xa;if(_0x44cfab===_0x4f33b4)break;else _0x40251c['push'](_0x40251c['shift']());}catch(_0x48b75a){_0x40251c['push'](_0x40251c['shift']());}}}(a33_0x3e69,0x26f63));function a33_0x2561(_0x1876b4,_0x1e727d){_0x1876b4=_0x1876b4-0x1bb;const _0x3e69fc=a33_0x3e69();let _0x2561be=_0x3e69fc[_0x1876b4];return _0x2561be;}function a33_0x3e69(){const _0x247121=['\x20modified,\x20','remote','Check\x20local\x20BFF\x20sync\x20status\x20against\x20lock\x20file','4228930qzmneN','827580apZVPR','All\x20BFF\x20scripts\x20are\x20in\x20sync.','all','status','apiDir','appCode','boolean','alias','5FPRpbK','length','read','lockKey','24265wQWMlI','hash','has','953799koRSCA','1096gyBJTp','119502NVNKhw','1654695ikVpSn','184EmcYyx','datasetCode','push','15029izYZsb','scriptsRoot','map'];a33_0x3e69=function(){return _0x247121;};return a33_0x3e69();}import{listBffScripts,getBffScriptStatistics}from'../../core/api-client.js';import{loadAliasMap}from'../../core/alias-resolver.js';import{resolveApiFilePath}from'../../context.js';import{loadBffProjectConfig}from'../../core/bff/config.js';import{createHookLocationMap,resolveRemoteScriptTarget,scanLocalBffFunctions}from'../../core/bff/file-system.js';import{computeFileHash}from'../../core/bff/hash.js';import{createEmptyBffLock,ensureLockScope,readBffLockFile}from'../../core/bff/lock.js';export const bffStatus={'service':'bff','command':'status','description':a33_0xd10583(0x1d1),'risk':a33_0xd10583(0x1c0),'flags':[{'name':a33_0xd10583(0x1d0),'type':a33_0xd10583(0x1bc),'description':'Also\x20check\x20for\x20remote-only\x20scripts\x20not\x20present\x20locally'}],async 'execute'(_0x33aec2){const _0x556be4=a33_0xd10583,_0x48b9ad=loadBffProjectConfig(_0x33aec2[_0x556be4(0x1bb)]),_0x5dae3b=await readBffLockFile(_0x48b9ad['lockFilePath']),{appLock:_0x5c67d8}=ensureLockScope(_0x5dae3b??createEmptyBffLock(),_0x33aec2['appCode'],_0x48b9ad[_0x556be4(0x1cd)],_0x556be4(0x1d6)),_0x5b7af1=await scanLocalBffFunctions(_0x48b9ad),_0x2ec231=[],_0x1e273a=[],_0x3da0ec=[];for(const _0x456290 of _0x5b7af1){const _0x3e2ead=await computeFileHash(_0x456290['filePath']),_0x3379a9=_0x5c67d8['functions'][_0x456290[_0x556be4(0x1c1)]];if(!_0x3379a9)_0x2ec231['push'](_0x456290[_0x556be4(0x1c1)]);else _0x3379a9[_0x556be4(0x1c3)]!==_0x3e2ead?_0x1e273a[_0x556be4(0x1cb)](_0x456290['lockKey']):_0x3da0ec[_0x556be4(0x1cb)](_0x456290[_0x556be4(0x1c1)]);}const _0x3bfe18=[];if(_0x33aec2['bool'](_0x556be4(0x1d0))){const _0x419922=loadAliasMap(_0x33aec2[_0x556be4(0x1d7)],undefined,resolveApiFilePath(_0x33aec2['apiDir'],_0x33aec2['appCode'])),_0x56b553=new Map(_0x419922[_0x556be4(0x1ce)](_0x4f3810=>[_0x4f3810[_0x556be4(0x1ca)],_0x4f3810[_0x556be4(0x1bd)]])),[_0x3cadbd,_0x176d22]=await Promise[_0x556be4(0x1d5)]([listBffScripts(_0x33aec2[_0x556be4(0x1bb)]),getBffScriptStatistics(_0x33aec2[_0x556be4(0x1bb)])]),_0x72c8ae=createHookLocationMap(_0x176d22),_0x32c9ed=new Set(_0x5b7af1[_0x556be4(0x1ce)](_0x41537b=>_0x41537b['lockKey']));for(const _0x384b04 of _0x3cadbd){const _0x349817=resolveRemoteScriptTarget(_0x48b9ad,_0x384b04,_0x72c8ae,_0x5c67d8['functions'],_0x56b553);_0x349817&&!_0x32c9ed[_0x556be4(0x1c4)](_0x349817[_0x556be4(0x1c1)])&&_0x3bfe18['push'](_0x349817['lockKey']);}}const _0x29ad49=_0x2ec231[_0x556be4(0x1bf)]===0x0&&_0x1e273a[_0x556be4(0x1bf)]===0x0&&_0x3bfe18[_0x556be4(0x1bf)]===0x0;return{'ok':!![],'data':{'added':_0x2ec231,'modified':_0x1e273a,'unchanged':_0x3da0ec,'remoteOnly':_0x3bfe18},'message':_0x29ad49?_0x556be4(0x1d4):_0x2ec231[_0x556be4(0x1bf)]+'\x20added,\x20'+_0x1e273a['length']+_0x556be4(0x1cf)+_0x3da0ec[_0x556be4(0x1bf)]+'\x20unchanged'+(_0x3bfe18[_0x556be4(0x1bf)]>0x0?',\x20'+_0x3bfe18[_0x556be4(0x1bf)]+'\x20remote-only':'')};}};
1
+ const a33_0x2f4b5f=a33_0x3c8e;function a33_0x3c8e(_0x134c44,_0x7bcad8){_0x134c44=_0x134c44-0x17a;const _0x4e3a0b=a33_0x4e3a();let _0x3c8e71=_0x4e3a0b[_0x134c44];return _0x3c8e71;}(function(_0x11ca93,_0x38f5e7){const _0x5507d0=a33_0x3c8e,_0x3f804e=_0x11ca93();while(!![]){try{const _0x55001d=-parseInt(_0x5507d0(0x18a))/0x1*(-parseInt(_0x5507d0(0x184))/0x2)+-parseInt(_0x5507d0(0x196))/0x3+-parseInt(_0x5507d0(0x17b))/0x4+-parseInt(_0x5507d0(0x199))/0x5+parseInt(_0x5507d0(0x185))/0x6+parseInt(_0x5507d0(0x18c))/0x7+-parseInt(_0x5507d0(0x18f))/0x8;if(_0x55001d===_0x38f5e7)break;else _0x3f804e['push'](_0x3f804e['shift']());}catch(_0x66b931){_0x3f804e['push'](_0x3f804e['shift']());}}}(a33_0x4e3a,0x18dd7));import{listBffScripts,getBffScriptStatistics}from'../../core/api-client.js';import{loadAliasMap}from'../../core/alias-resolver.js';import{resolveApiFilePath}from'../../context.js';import{loadBffProjectConfig}from'../../core/bff/config.js';import{createHookLocationMap,resolveRemoteScriptTarget,scanLocalBffFunctions}from'../../core/bff/file-system.js';function a33_0x4e3a(){const _0x412fc9=['780320soMQIB','boolean','has','bff','status','remote','appCode','scriptsRoot','functions','2qQnhzT','1167696uhJjjk','Also\x20check\x20for\x20remote-only\x20scripts\x20not\x20present\x20locally','all','datasetCode','Check\x20local\x20BFF\x20sync\x20status\x20against\x20lock\x20file','115873okORGq','\x20remote-only','680820EWFbEL','bool','push','43600NcpGML','lockKey','filePath','apiDir','length','All\x20BFF\x20scripts\x20are\x20in\x20sync.','lockFilePath','116757tHgUaN','map','alias','332265EWBDFj','\x20added,\x20','\x20modified,\x20'];a33_0x4e3a=function(){return _0x412fc9;};return a33_0x4e3a();}import{computeFileHash}from'../../core/bff/hash.js';import{createEmptyBffLock,ensureLockScope,readBffLockFile}from'../../core/bff/lock.js';export const bffStatus={'service':a33_0x2f4b5f(0x17e),'command':'status','description':a33_0x2f4b5f(0x189),'risk':'read','flags':[{'name':a33_0x2f4b5f(0x180),'type':a33_0x2f4b5f(0x17c),'description':a33_0x2f4b5f(0x186)}],async 'execute'(_0x2c059d){const _0x220b00=a33_0x2f4b5f,_0x29dd45=loadBffProjectConfig(_0x2c059d['appCode']),_0x5363b1=await readBffLockFile(_0x29dd45[_0x220b00(0x195)]),{appLock:_0x1f4f39}=ensureLockScope(_0x5363b1??createEmptyBffLock(),_0x2c059d['appCode'],_0x29dd45[_0x220b00(0x182)],_0x220b00(0x17f)),_0x5cead1=await scanLocalBffFunctions(_0x29dd45),_0x2c3111=[],_0x413325=[],_0x2bac46=[];for(const _0x1d1bb3 of _0x5cead1){const _0xdafe78=await computeFileHash(_0x1d1bb3[_0x220b00(0x191)]),_0x3e2bfa=_0x1f4f39[_0x220b00(0x183)][_0x1d1bb3['lockKey']];if(!_0x3e2bfa)_0x2c3111['push'](_0x1d1bb3[_0x220b00(0x190)]);else _0x3e2bfa['hash']!==_0xdafe78?_0x413325[_0x220b00(0x18e)](_0x1d1bb3[_0x220b00(0x190)]):_0x2bac46[_0x220b00(0x18e)](_0x1d1bb3['lockKey']);}const _0xf6b5da=[];if(_0x2c059d[_0x220b00(0x18d)](_0x220b00(0x180))){const _0x1bb284=loadAliasMap(_0x2c059d[_0x220b00(0x192)],undefined,resolveApiFilePath(_0x2c059d[_0x220b00(0x192)],_0x2c059d[_0x220b00(0x181)])),_0x13b37b=new Map(_0x1bb284['map'](_0x360fdf=>[_0x360fdf[_0x220b00(0x188)],_0x360fdf[_0x220b00(0x198)]])),[_0x45e33b,_0x4e7f21]=await Promise[_0x220b00(0x187)]([listBffScripts(_0x2c059d[_0x220b00(0x181)]),getBffScriptStatistics(_0x2c059d[_0x220b00(0x181)])]),_0x211df3=createHookLocationMap(_0x4e7f21),_0x151042=new Set(_0x5cead1[_0x220b00(0x197)](_0x164f3a=>_0x164f3a[_0x220b00(0x190)]));for(const _0x2bb096 of _0x45e33b){const _0x26fff4=resolveRemoteScriptTarget(_0x29dd45,_0x2bb096,_0x211df3,_0x1f4f39['functions'],_0x13b37b);_0x26fff4&&!_0x151042[_0x220b00(0x17d)](_0x26fff4[_0x220b00(0x190)])&&_0xf6b5da[_0x220b00(0x18e)](_0x26fff4['lockKey']);}}const _0x44e307=_0x2c3111[_0x220b00(0x193)]===0x0&&_0x413325[_0x220b00(0x193)]===0x0&&_0xf6b5da[_0x220b00(0x193)]===0x0;return{'ok':!![],'data':{'added':_0x2c3111,'modified':_0x413325,'unchanged':_0x2bac46,'remoteOnly':_0xf6b5da},'message':_0x44e307?_0x220b00(0x194):_0x2c3111[_0x220b00(0x193)]+_0x220b00(0x19a)+_0x413325[_0x220b00(0x193)]+_0x220b00(0x17a)+_0x2bac46[_0x220b00(0x193)]+'\x20unchanged'+(_0xf6b5da[_0x220b00(0x193)]>0x0?',\x20'+_0xf6b5da[_0x220b00(0x193)]+_0x220b00(0x18b):'')};}};
@@ -1 +1 @@
1
- const a34_0x4e7d0f=a34_0x4bd3;(function(_0x11c11d,_0x222549){const _0x185c9b=a34_0x4bd3,_0x1d84a2=_0x11c11d();while(!![]){try{const _0x3215b8=-parseInt(_0x185c9b(0x10a))/0x1+-parseInt(_0x185c9b(0x129))/0x2+-parseInt(_0x185c9b(0x144))/0x3+-parseInt(_0x185c9b(0x13f))/0x4+-parseInt(_0x185c9b(0x11d))/0x5+-parseInt(_0x185c9b(0x13e))/0x6*(parseInt(_0x185c9b(0x135))/0x7)+parseInt(_0x185c9b(0x14c))/0x8;if(_0x3215b8===_0x222549)break;else _0x1d84a2['push'](_0x1d84a2['shift']());}catch(_0x497d6f){_0x1d84a2['push'](_0x1d84a2['shift']());}}}(a34_0x5132,0xac687));import a34_0x51aacc from'chalk';import a34_0x5a031f from'ora';import a34_0x12f417 from'semver';import{execa}from'execa';function a34_0x4bd3(_0x4f0576,_0x19e667){_0x4f0576=_0x4f0576-0xfd;const _0x51320c=a34_0x5132();let _0x4bd3b0=_0x51320c[_0x4f0576];return _0x4bd3b0;}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{getCdnConfig}from'../utils/cdn-config.js';function a34_0x5132(){const _0x1c539f=['Unable\x20to\x20check\x20for\x20updates\x20(network\x20error)','skipped','520232KqgAph','@latest','nonInteractive','Version\x20comparison\x20failed','unknown','\x20\x20Official\x20skill\x20update\x20failed:\x20','warn','map','Current\x20version:\x20','beta','gray','update','log','\x20\x20Run\x20manually:\x20','Unable\x20to\x20resolve\x20beta\x20version\x20from\x20npm','Choose\x20either\x20npm\x20beta\x20dist-tag\x20or\x20an\x20exact\x20version.','length','--beta\x20and\x20--version\x20cannot\x20be\x20used\x20together.','Refresh\x20official\x20skill\x20package\x20after\x20updating','4394655dWpjTr','\x20\x20Run\x20manually:\x20npm\x20install\x20-g\x20','fail','yellow','/dist-tags','stableVersion','https://registry.npmjs.org/-/package/','green','\x20\x20Try\x20manually:\x20','Checking\x20for\x20updates...','execPath','\x20→\x20','988892gsCQAJ','npm','object','inherit','\x20\x20Skipped\x20skill\x20install\x20(RABETBASE_SKIP_NPX_SKILLS=1).','bool','str','Update\x20available:\x20','...','start','message','skills','231RusTax','cli','version','Skip\x20official\x20skill\x20package\x20refresh\x20after\x20updating','Already\x20on\x20requested\x20version\x20(v','succeed','\x20install\x20-g\x20','latest','boolean','15078sIbfUW','1283060NkwLUc','Beta\x20version:\x20','Already\x20up\x20to\x20date\x20(v','no-skills','entries','3725463VSHpxK','error','Install\x20a\x20specific\x20CLI\x20version','validation','run','valid','info','includes','33962456YNatjX','bun','Install\x20the\x20version\x20from\x20npm\x20beta\x20dist-tag','filter','string','install','toLowerCase','trim','fromEntries','source','Use\x20a\x20full\x20semver\x20such\x20as\x202.1.6\x20or\x202.1.6-beta.1.','Skipping\x20official\x20skill\x20package\x20(--no-skills).','\x20\x20Official\x20skill\x20package\x20is\x20up\x20to\x20date.','Update\x20failed'];a34_0x5132=function(){return _0x1c539f;};return a34_0x5132();}import{resolveNpmBin}from'../utils/platform.js';function getCurrentVersion(){const _0x4f4ef2=a34_0x4bd3;return GIT_COMMIT!==_0x4f4ef2(0x10e)?VERSION+'\x20('+GIT_COMMIT+',\x20'+BUILD_TIME['slice'](0x0,0xa)+')':VERSION;}function detectPackageManager(){const _0x3860b7=a34_0x4bd3,_0xda17d2=process[_0x3860b7(0x127)][_0x3860b7(0x100)]();if(_0xda17d2[_0x3860b7(0x14b)](_0x3860b7(0x14d)))return'bun';return _0x3860b7(0x12a);}const updateFlags=[{'name':a34_0x4e7d0f(0x113),'type':'boolean','description':a34_0x4e7d0f(0x14e),'default':![]},{'name':a34_0x4e7d0f(0x137),'type':'string','description':a34_0x4e7d0f(0x146)},{'name':a34_0x4e7d0f(0x142),'type':a34_0x4e7d0f(0x13d),'description':a34_0x4e7d0f(0x138),'default':![]},{'name':a34_0x4e7d0f(0x134),'type':a34_0x4e7d0f(0x13d),'description':a34_0x4e7d0f(0x11c),'default':!![],'hidden':!![]}];function getRequestedVersion(_0x2b6faf){const _0x1531c8=a34_0x4e7d0f;return _0x2b6faf[_0x1531c8(0x12f)](_0x1531c8(0x137))[_0x1531c8(0x101)]();}function shouldSkipOfficialSkill(_0x29600b){const _0x37a591=a34_0x4e7d0f;return _0x29600b[_0x37a591(0x12e)](_0x37a591(0x142))||_0x29600b['flag'](_0x37a591(0x134))===![];}async function validateUpdateFlags(_0x6f5de5){const _0x1a0c56=a34_0x4e7d0f,_0x2cf81a=_0x6f5de5['bool'](_0x1a0c56(0x113)),_0x194057=getRequestedVersion(_0x6f5de5);if(_0x2cf81a&&_0x194057)throw CliErrors[_0x1a0c56(0x147)](_0x1a0c56(0x11b),_0x1a0c56(0x119));if(_0x194057&&!a34_0x12f417['valid'](_0x194057))throw CliErrors['validation']('Invalid\x20version:\x20'+_0x194057,_0x1a0c56(0x104));}async function fetchNpmDistTags(){const _0x5267fd=a34_0x4e7d0f;try{const _0x402ec7=await fetch(_0x5267fd(0x123)+encodeURIComponent(NPM_PACKAGE_NAME)+_0x5267fd(0x121),{'signal':AbortSignal['timeout'](0x2710)});if(!_0x402ec7['ok'])return null;const _0x451182=await _0x402ec7['json']();if(!_0x451182||typeof _0x451182!==_0x5267fd(0x12b))return null;return Object[_0x5267fd(0x102)](Object[_0x5267fd(0x143)](_0x451182)[_0x5267fd(0xfd)](([,_0x41c05f])=>typeof _0x41c05f===_0x5267fd(0xfe)&&_0x41c05f[_0x5267fd(0x101)]()[_0x5267fd(0x11a)]>0x0)[_0x5267fd(0x111)](([_0x297c71,_0x4b490a])=>[_0x297c71,String(_0x4b490a)['trim']()]));}catch{return null;}}async function fetchNpmDistTagVersion(_0x4ebdd5){const _0x1e35df=await fetchNpmDistTags();return _0x1e35df?.[_0x4ebdd5]??null;}async function fetchLatestVersion(){const _0xf77897=a34_0x4e7d0f,_0x4d9306=await fetchNpmDistTagVersion('latest');if(_0x4d9306)return _0x4d9306;const _0x4678a0=await getCdnConfig();return _0x4678a0?.[_0xf77897(0x136)]?.[_0xf77897(0x122)]??null;}async function resolveTargetVersion(_0x186a33){const _0x39ffa2=a34_0x4e7d0f,_0x2935f2=getRequestedVersion(_0x186a33);if(_0x2935f2)return{'version':_0x2935f2,'source':_0x39ffa2(0x137)};if(_0x186a33[_0x39ffa2(0x12e)]('beta')){const _0xdb4372=await fetchNpmDistTagVersion('beta');if(!_0xdb4372)return null;return{'version':_0xdb4372,'source':_0x39ffa2(0x113)};}const _0x445989=await fetchLatestVersion();if(!_0x445989)return null;return{'version':_0x445989,'source':'latest'};}function shouldInstallTarget(_0x2c4074,_0x4b71a4){const _0x8baaf8=a34_0x4e7d0f;if(_0x4b71a4['source']===_0x8baaf8(0x137)||_0x4b71a4[_0x8baaf8(0x103)]===_0x8baaf8(0x113))return!a34_0x12f417['eq'](_0x2c4074,_0x4b71a4[_0x8baaf8(0x137)]);return a34_0x12f417['lt'](_0x2c4074,_0x4b71a4[_0x8baaf8(0x137)]);}function getInstallPlanLabel(_0x2f916e,_0x3d04e2){const _0x24ebd1=a34_0x4e7d0f;switch(_0x3d04e2[_0x24ebd1(0x103)]){case _0x24ebd1(0x113):return _0x24ebd1(0x140)+a34_0x51aacc[_0x24ebd1(0x120)](_0x2f916e)+_0x24ebd1(0x128)+a34_0x51aacc['green'](_0x3d04e2[_0x24ebd1(0x137)]);case _0x24ebd1(0x137):return'Requested\x20version:\x20'+a34_0x51aacc['yellow'](_0x2f916e)+_0x24ebd1(0x128)+a34_0x51aacc[_0x24ebd1(0x124)](_0x3d04e2[_0x24ebd1(0x137)]);case _0x24ebd1(0x13c):default:return _0x24ebd1(0x130)+a34_0x51aacc[_0x24ebd1(0x120)](_0x2f916e)+_0x24ebd1(0x128)+a34_0x51aacc[_0x24ebd1(0x124)](_0x3d04e2[_0x24ebd1(0x137)]);}}async function installOfficialSkill(_0x3668e9){const _0x7ae593=a34_0x4e7d0f;console[_0x7ae593(0x116)](a34_0x51aacc['gray']('Checking\x20official\x20skill\x20package...'));const _0x25c6f8=runNpxSkillsAddGlobal(process['cwd'](),RABETBASE_SKILL_SOURCE,{'stdio':_0x3668e9?'pipe':_0x7ae593(0x12c)});if(_0x25c6f8[_0x7ae593(0x109)]){console[_0x7ae593(0x116)](a34_0x51aacc[_0x7ae593(0x114)](_0x7ae593(0x12d)));return;}if(_0x25c6f8['ok']){console[_0x7ae593(0x116)](a34_0x51aacc[_0x7ae593(0x114)](_0x7ae593(0x106)));return;}console[_0x7ae593(0x110)](a34_0x51aacc[_0x7ae593(0x120)](_0x7ae593(0x10f)+(_0x25c6f8[_0x7ae593(0x145)]||_0x7ae593(0x10e)))),console[_0x7ae593(0x116)](a34_0x51aacc[_0x7ae593(0x114)](_0x7ae593(0x117)+NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE));}async function execute(_0x564236){const _0x434291=a34_0x4e7d0f;await validateUpdateFlags(_0x564236);const _0x4aebd8=getCurrentVersion();console[_0x434291(0x116)](_0x434291(0x112)+_0x4aebd8);const _0x243490=a34_0x5a031f(_0x434291(0x126))[_0x434291(0x132)](),_0x2c5fd7=await resolveTargetVersion(_0x564236);if(!_0x2c5fd7){const _0xee84d4=_0x564236[_0x434291(0x12e)](_0x434291(0x113))?_0x434291(0x118):_0x434291(0x108);return _0x243490[_0x434291(0x11f)](_0xee84d4),console['log'](a34_0x51aacc['gray'](_0x434291(0x11e)+NPM_PACKAGE_NAME+_0x434291(0x10b))),{'ok':![],'message':_0xee84d4};}const _0x4cc1ca=a34_0x12f417[_0x434291(0x149)](VERSION),_0x131f02=a34_0x12f417[_0x434291(0x149)](_0x2c5fd7[_0x434291(0x137)]);if(!_0x4cc1ca||!_0x131f02)return _0x243490['fail'](_0x434291(0x10d)),{'ok':![],'message':_0x434291(0x10d)};if(!shouldInstallTarget(_0x4cc1ca,_0x2c5fd7)){const _0x5a704b=_0x2c5fd7[_0x434291(0x103)]===_0x434291(0x137)?_0x434291(0x139)+_0x2c5fd7[_0x434291(0x137)]+')':_0x434291(0x141)+_0x2c5fd7[_0x434291(0x137)]+')';return _0x243490[_0x434291(0x13a)](_0x5a704b),shouldSkipOfficialSkill(_0x564236)?console['log'](a34_0x51aacc['gray'](_0x434291(0x105))):await installOfficialSkill(_0x564236[_0x434291(0x10c)]),{'ok':!![]};}_0x243490[_0x434291(0x14a)](getInstallPlanLabel(_0x4aebd8,_0x2c5fd7));const _0x155db9=detectPackageManager(),_0x205836=_0x155db9===_0x434291(0x12a)?resolveNpmBin(_0x434291(0x12a)):_0x155db9,_0x3087bc=a34_0x5a031f('Updating\x20via\x20'+_0x155db9+_0x434291(0x131))[_0x434291(0x132)]();try{return await execa(_0x205836,[_0x434291(0xff),'-g',NPM_PACKAGE_NAME+'@'+_0x2c5fd7[_0x434291(0x137)]],{'stdio':'pipe'}),_0x3087bc['succeed']('Updated\x20to\x20v'+_0x2c5fd7[_0x434291(0x137)]),console['log'](a34_0x51aacc[_0x434291(0x114)]('\x20\x20Restart\x20your\x20terminal\x20to\x20use\x20the\x20new\x20version.')),shouldSkipOfficialSkill(_0x564236)?console[_0x434291(0x116)](a34_0x51aacc[_0x434291(0x114)](_0x434291(0x105))):await installOfficialSkill(_0x564236[_0x434291(0x10c)]),{'ok':!![]};}catch(_0x110154){return _0x3087bc['fail'](_0x434291(0x107)),console[_0x434291(0x145)](a34_0x51aacc['red']('\x20\x20'+_0x110154['message'])),console[_0x434291(0x116)](a34_0x51aacc[_0x434291(0x114)](_0x434291(0x125)+_0x155db9+_0x434291(0x13b)+NPM_PACKAGE_NAME+'@'+_0x2c5fd7[_0x434291(0x137)])),{'ok':![],'message':_0x110154[_0x434291(0x133)]};}}export const updateDefinition={'service':a34_0x4e7d0f(0x115),'command':a34_0x4e7d0f(0x148),'description':'Update\x20rabetbase\x20CLI\x20to\x20the\x20latest\x20version','risk':'write','requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':updateFlags,'validate':validateUpdateFlags,'execute':execute};
1
+ const a34_0x54f429=a34_0x427f;(function(_0xb9cde6,_0x2e88ce){const _0xc2eceb=a34_0x427f,_0x1d51c9=_0xb9cde6();while(!![]){try{const _0x12e913=-parseInt(_0xc2eceb(0x18b))/0x1+parseInt(_0xc2eceb(0x156))/0x2*(-parseInt(_0xc2eceb(0x155))/0x3)+-parseInt(_0xc2eceb(0x193))/0x4+-parseInt(_0xc2eceb(0x15e))/0x5*(parseInt(_0xc2eceb(0x194))/0x6)+-parseInt(_0xc2eceb(0x153))/0x7+parseInt(_0xc2eceb(0x19f))/0x8*(parseInt(_0xc2eceb(0x173))/0x9)+-parseInt(_0xc2eceb(0x185))/0xa*(-parseInt(_0xc2eceb(0x18d))/0xb);if(_0x12e913===_0x2e88ce)break;else _0x1d51c9['push'](_0x1d51c9['shift']());}catch(_0x34be29){_0x1d51c9['push'](_0x1d51c9['shift']());}}}(a34_0x1a65,0x6d7ad));import a34_0x4ae2b4 from'chalk';import a34_0x3d62d4 from'ora';import a34_0x557cc0 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{getCdnConfig}from'../utils/cdn-config.js';import{resolveNpmBin}from'../utils/platform.js';function getCurrentVersion(){const _0x445daa=a34_0x427f;return GIT_COMMIT!==_0x445daa(0x161)?VERSION+'\x20('+GIT_COMMIT+',\x20'+BUILD_TIME[_0x445daa(0x170)](0x0,0xa)+')':VERSION;}function detectPackageManager(){const _0x869b07=a34_0x427f,_0x1694bb=process[_0x869b07(0x176)][_0x869b07(0x169)]();if(_0x1694bb['includes']('bun'))return _0x869b07(0x196);return _0x869b07(0x16a);}const updateFlags=[{'name':a34_0x54f429(0x15d),'type':'boolean','description':a34_0x54f429(0x16f),'default':![]},{'name':a34_0x54f429(0x187),'type':'string','description':a34_0x54f429(0x16d)},{'name':a34_0x54f429(0x18f),'type':a34_0x54f429(0x18e),'description':a34_0x54f429(0x182),'default':![]},{'name':a34_0x54f429(0x1a0),'type':a34_0x54f429(0x18e),'description':'Refresh\x20official\x20skill\x20package\x20after\x20updating','default':!![],'hidden':!![]}];function getRequestedVersion(_0x3f5c4f){const _0x397a69=a34_0x54f429;return _0x3f5c4f[_0x397a69(0x180)](_0x397a69(0x187))[_0x397a69(0x17a)]();}function shouldSkipOfficialSkill(_0x1e72e1){const _0x4bb7da=a34_0x54f429;return _0x1e72e1[_0x4bb7da(0x163)](_0x4bb7da(0x18f))||_0x1e72e1[_0x4bb7da(0x17e)](_0x4bb7da(0x1a0))===![];}async function validateUpdateFlags(_0x122e7c){const _0xa76e44=a34_0x54f429,_0x305f72=_0x122e7c[_0xa76e44(0x163)](_0xa76e44(0x15d)),_0x1fe63c=getRequestedVersion(_0x122e7c);if(_0x305f72&&_0x1fe63c)throw CliErrors[_0xa76e44(0x188)](_0xa76e44(0x150),_0xa76e44(0x16b));if(_0x1fe63c&&!a34_0x557cc0[_0xa76e44(0x152)](_0x1fe63c))throw CliErrors['validation'](_0xa76e44(0x17b)+_0x1fe63c,'Use\x20a\x20full\x20semver\x20such\x20as\x202.1.6\x20or\x202.1.6-beta.1.');}function a34_0x427f(_0x4d2222,_0x144bbe){_0x4d2222=_0x4d2222-0x14f;const _0x1a65fb=a34_0x1a65();let _0x427f18=_0x1a65fb[_0x4d2222];return _0x427f18;}async function fetchNpmDistTags(){const _0x4f3454=a34_0x54f429;try{const _0x183265=await fetch(_0x4f3454(0x192)+encodeURIComponent(NPM_PACKAGE_NAME)+_0x4f3454(0x158),{'signal':AbortSignal[_0x4f3454(0x162)](0x2710)});if(!_0x183265['ok'])return null;const _0x49e139=await _0x183265[_0x4f3454(0x19a)]();if(!_0x49e139||typeof _0x49e139!=='object')return null;return Object['fromEntries'](Object[_0x4f3454(0x19e)](_0x49e139)[_0x4f3454(0x184)](([,_0x237700])=>typeof _0x237700===_0x4f3454(0x17c)&&_0x237700['trim']()['length']>0x0)[_0x4f3454(0x198)](([_0x264287,_0x5553c2])=>[_0x264287,String(_0x5553c2)[_0x4f3454(0x17a)]()]));}catch{return null;}}async function fetchNpmDistTagVersion(_0x2b01e7){const _0x351f27=await fetchNpmDistTags();return _0x351f27?.[_0x2b01e7]??null;}async function fetchLatestVersion(){const _0x5e22b7=a34_0x54f429,_0x36671a=await fetchNpmDistTagVersion(_0x5e22b7(0x179));if(_0x36671a)return _0x36671a;const _0x40530c=await getCdnConfig();return _0x40530c?.[_0x5e22b7(0x171)]?.['stableVersion']??null;}async function resolveTargetVersion(_0x55f563){const _0x461821=a34_0x54f429,_0x3e6913=getRequestedVersion(_0x55f563);if(_0x3e6913)return{'version':_0x3e6913,'source':_0x461821(0x187)};if(_0x55f563[_0x461821(0x163)](_0x461821(0x15d))){const _0x3283b2=await fetchNpmDistTagVersion(_0x461821(0x15d));if(!_0x3283b2)return null;return{'version':_0x3283b2,'source':_0x461821(0x15d)};}const _0x165f34=await fetchLatestVersion();if(!_0x165f34)return null;return{'version':_0x165f34,'source':'latest'};}function a34_0x1a65(){const _0x75bb83=['run','str','message','Skip\x20official\x20skill\x20package\x20refresh\x20after\x20updating','start','filter','402610NxcraA','skipped','version','validation','...','succeed','373095kzqYbm','Current\x20version:\x20','627qFiCxD','boolean','no-skills','Unable\x20to\x20check\x20for\x20updates\x20(network\x20error)','Version\x20comparison\x20failed','https://registry.npmjs.org/-/package/','132548IAylJh','6PPIgIn','\x20\x20Try\x20manually:\x20','bun','install','map','source','json','\x20→\x20','log','inherit','entries','8znEOlE','skills','gray','pipe','--beta\x20and\x20--version\x20cannot\x20be\x20used\x20together.','error','valid','4867149liXuSB','\x20\x20Skipped\x20skill\x20install\x20(RABETBASE_SKIP_NPX_SKILLS=1).','4188WpiDkZ','150dMqduJ','Unable\x20to\x20resolve\x20beta\x20version\x20from\x20npm','/dist-tags','update','Update\x20available:\x20','\x20install\x20-g\x20','Already\x20up\x20to\x20date\x20(v','beta','4010990NJEwjx','fail','nonInteractive','unknown','timeout','bool','green','red','@latest','yellow','\x20\x20Restart\x20your\x20terminal\x20to\x20use\x20the\x20new\x20version.','toLowerCase','npm','Choose\x20either\x20npm\x20beta\x20dist-tag\x20or\x20an\x20exact\x20version.','Update\x20rabetbase\x20CLI\x20to\x20the\x20latest\x20version','Install\x20a\x20specific\x20CLI\x20version','Updating\x20via\x20','Install\x20the\x20version\x20from\x20npm\x20beta\x20dist-tag','slice','cli','Requested\x20version:\x20','1457901ekpmfp','Beta\x20version:\x20','Update\x20failed','execPath','Skipping\x20official\x20skill\x20package\x20(--no-skills).','cwd','latest','trim','Invalid\x20version:\x20','string','Updated\x20to\x20v','flag'];a34_0x1a65=function(){return _0x75bb83;};return a34_0x1a65();}function shouldInstallTarget(_0xb22925,_0x23215b){const _0x3f548b=a34_0x54f429;if(_0x23215b['source']===_0x3f548b(0x187)||_0x23215b[_0x3f548b(0x199)]==='beta')return!a34_0x557cc0['eq'](_0xb22925,_0x23215b[_0x3f548b(0x187)]);return a34_0x557cc0['lt'](_0xb22925,_0x23215b[_0x3f548b(0x187)]);}function getInstallPlanLabel(_0x2e8c8c,_0x2284a5){const _0x82d98e=a34_0x54f429;switch(_0x2284a5[_0x82d98e(0x199)]){case'beta':return _0x82d98e(0x174)+a34_0x4ae2b4['yellow'](_0x2e8c8c)+_0x82d98e(0x19b)+a34_0x4ae2b4[_0x82d98e(0x164)](_0x2284a5['version']);case _0x82d98e(0x187):return _0x82d98e(0x172)+a34_0x4ae2b4[_0x82d98e(0x167)](_0x2e8c8c)+'\x20→\x20'+a34_0x4ae2b4[_0x82d98e(0x164)](_0x2284a5[_0x82d98e(0x187)]);case _0x82d98e(0x179):default:return _0x82d98e(0x15a)+a34_0x4ae2b4[_0x82d98e(0x167)](_0x2e8c8c)+'\x20→\x20'+a34_0x4ae2b4[_0x82d98e(0x164)](_0x2284a5[_0x82d98e(0x187)]);}}async function installOfficialSkill(_0x2da369){const _0x46477f=a34_0x54f429;console[_0x46477f(0x19c)](a34_0x4ae2b4[_0x46477f(0x1a1)]('Checking\x20official\x20skill\x20package...'));const _0x277d9e=runNpxSkillsAddGlobal(process[_0x46477f(0x178)](),RABETBASE_SKILL_SOURCE,{'stdio':_0x2da369?_0x46477f(0x14f):_0x46477f(0x19d)});if(_0x277d9e[_0x46477f(0x186)]){console['log'](a34_0x4ae2b4[_0x46477f(0x1a1)](_0x46477f(0x154)));return;}if(_0x277d9e['ok']){console[_0x46477f(0x19c)](a34_0x4ae2b4[_0x46477f(0x1a1)]('\x20\x20Official\x20skill\x20package\x20is\x20up\x20to\x20date.'));return;}console['warn'](a34_0x4ae2b4[_0x46477f(0x167)]('\x20\x20Official\x20skill\x20update\x20failed:\x20'+(_0x277d9e['error']||'unknown'))),console[_0x46477f(0x19c)](a34_0x4ae2b4[_0x46477f(0x1a1)]('\x20\x20Run\x20manually:\x20'+NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE));}async function execute(_0x143b7f){const _0x1d6cea=a34_0x54f429;await validateUpdateFlags(_0x143b7f);const _0x1d42c4=getCurrentVersion();console[_0x1d6cea(0x19c)](_0x1d6cea(0x18c)+_0x1d42c4);const _0x9fa3=a34_0x3d62d4('Checking\x20for\x20updates...')[_0x1d6cea(0x183)](),_0x54243c=await resolveTargetVersion(_0x143b7f);if(!_0x54243c){const _0x4a6b1d=_0x143b7f['bool'](_0x1d6cea(0x15d))?_0x1d6cea(0x157):_0x1d6cea(0x190);return _0x9fa3['fail'](_0x4a6b1d),console['log'](a34_0x4ae2b4[_0x1d6cea(0x1a1)]('\x20\x20Run\x20manually:\x20npm\x20install\x20-g\x20'+NPM_PACKAGE_NAME+_0x1d6cea(0x166))),{'ok':![],'message':_0x4a6b1d};}const _0x48c705=a34_0x557cc0['valid'](VERSION),_0x443258=a34_0x557cc0[_0x1d6cea(0x152)](_0x54243c['version']);if(!_0x48c705||!_0x443258)return _0x9fa3[_0x1d6cea(0x15f)](_0x1d6cea(0x191)),{'ok':![],'message':_0x1d6cea(0x191)};if(!shouldInstallTarget(_0x48c705,_0x54243c)){const _0xa2b29d=_0x54243c[_0x1d6cea(0x199)]===_0x1d6cea(0x187)?'Already\x20on\x20requested\x20version\x20(v'+_0x54243c[_0x1d6cea(0x187)]+')':_0x1d6cea(0x15c)+_0x54243c['version']+')';return _0x9fa3[_0x1d6cea(0x18a)](_0xa2b29d),shouldSkipOfficialSkill(_0x143b7f)?console[_0x1d6cea(0x19c)](a34_0x4ae2b4['gray'](_0x1d6cea(0x177))):await installOfficialSkill(_0x143b7f[_0x1d6cea(0x160)]),{'ok':!![]};}_0x9fa3['info'](getInstallPlanLabel(_0x1d42c4,_0x54243c));const _0x4d038d=detectPackageManager(),_0x4ce389=_0x4d038d===_0x1d6cea(0x16a)?resolveNpmBin(_0x1d6cea(0x16a)):_0x4d038d,_0x2c34aa=a34_0x3d62d4(_0x1d6cea(0x16e)+_0x4d038d+_0x1d6cea(0x189))[_0x1d6cea(0x183)]();try{return await execa(_0x4ce389,[_0x1d6cea(0x197),'-g',NPM_PACKAGE_NAME+'@'+_0x54243c['version']],{'stdio':_0x1d6cea(0x14f)}),_0x2c34aa['succeed'](_0x1d6cea(0x17d)+_0x54243c['version']),console[_0x1d6cea(0x19c)](a34_0x4ae2b4[_0x1d6cea(0x1a1)](_0x1d6cea(0x168))),shouldSkipOfficialSkill(_0x143b7f)?console[_0x1d6cea(0x19c)](a34_0x4ae2b4[_0x1d6cea(0x1a1)](_0x1d6cea(0x177))):await installOfficialSkill(_0x143b7f[_0x1d6cea(0x160)]),{'ok':!![]};}catch(_0x2d9ad2){return _0x2c34aa[_0x1d6cea(0x15f)](_0x1d6cea(0x175)),console[_0x1d6cea(0x151)](a34_0x4ae2b4[_0x1d6cea(0x165)]('\x20\x20'+_0x2d9ad2[_0x1d6cea(0x181)])),console[_0x1d6cea(0x19c)](a34_0x4ae2b4[_0x1d6cea(0x1a1)](_0x1d6cea(0x195)+_0x4d038d+_0x1d6cea(0x15b)+NPM_PACKAGE_NAME+'@'+_0x54243c[_0x1d6cea(0x187)])),{'ok':![],'message':_0x2d9ad2[_0x1d6cea(0x181)]};}}export const updateDefinition={'service':a34_0x54f429(0x159),'command':a34_0x54f429(0x17f),'description':a34_0x54f429(0x16c),'risk':'write','requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':updateFlags,'validate':validateUpdateFlags,'execute':execute};
@@ -1 +1 @@
1
- (function(_0x38c703,_0x2cb44f){const _0x4c44b5=a35_0x5946,_0x334988=_0x38c703();while(!![]){try{const _0x115360=-parseInt(_0x4c44b5(0x15c))/0x1*(-parseInt(_0x4c44b5(0x159))/0x2)+-parseInt(_0x4c44b5(0x155))/0x3*(parseInt(_0x4c44b5(0x15d))/0x4)+parseInt(_0x4c44b5(0x15a))/0x5+-parseInt(_0x4c44b5(0x158))/0x6*(-parseInt(_0x4c44b5(0x152))/0x7)+parseInt(_0x4c44b5(0x153))/0x8*(parseInt(_0x4c44b5(0x15e))/0x9)+-parseInt(_0x4c44b5(0x157))/0xa*(-parseInt(_0x4c44b5(0x154))/0xb)+parseInt(_0x4c44b5(0x15b))/0xc*(-parseInt(_0x4c44b5(0x156))/0xd);if(_0x115360===_0x2cb44f)break;else _0x334988['push'](_0x334988['shift']());}catch(_0x19a402){_0x334988['push'](_0x334988['shift']());}}}(a35_0x29ba,0x5167c));import{codegenSdk}from'../../commands/codegen/sdk.js';function a35_0x5946(_0xa70b3f,_0xabccce){_0xa70b3f=_0xa70b3f-0x152;const _0x29bab0=a35_0x29ba();let _0x594626=_0x29bab0[_0xa70b3f];return _0x594626;}function a35_0x29ba(){const _0x47f979=['808615iwPAtz','492OkPhSZ','216GKRWsV','4VmiTcI','72wRJFsW','83069HonRCC','5984yjWBsu','3039421xypIBD','1695462lYoDKW','247754tSIOPb','20LbrEEX','222qaOZtT','4820gAgDAS'];a35_0x29ba=function(){return _0x47f979;};return a35_0x29ba();}import{codegenSql}from'../../commands/codegen/sql.js';export const codegenDefinitions=[codegenSdk,codegenSql];
1
+ (function(_0x7c0774,_0x513c05){const _0x1e152c=a35_0x13e5,_0x26aac6=_0x7c0774();while(!![]){try{const _0x26474a=-parseInt(_0x1e152c(0x9c))/0x1+-parseInt(_0x1e152c(0xa0))/0x2*(parseInt(_0x1e152c(0x9f))/0x3)+parseInt(_0x1e152c(0xa1))/0x4+-parseInt(_0x1e152c(0x9d))/0x5*(-parseInt(_0x1e152c(0x9a))/0x6)+parseInt(_0x1e152c(0x9b))/0x7*(parseInt(_0x1e152c(0x9e))/0x8)+-parseInt(_0x1e152c(0xa2))/0x9+-parseInt(_0x1e152c(0xa3))/0xa;if(_0x26474a===_0x513c05)break;else _0x26aac6['push'](_0x26aac6['shift']());}catch(_0x38f3be){_0x26aac6['push'](_0x26aac6['shift']());}}}(a35_0x2270,0xd5d59));function a35_0x2270(){const _0x1414d5=['93576klrDlZ','1200447sDhGla','4ZiPCNR','6443304NLLSzJ','3558726LMEyHM','5511770TpYubz','6FVbSfn','273JoIKpy','12440AzzIor','2840925Fmeqhn'];a35_0x2270=function(){return _0x1414d5;};return a35_0x2270();}import{codegenSdk}from'../../commands/codegen/sdk.js';import{codegenSql}from'../../commands/codegen/sql.js';function a35_0x13e5(_0x563b70,_0xadea73){_0x563b70=_0x563b70-0x9a;const _0x2270f6=a35_0x2270();let _0x13e518=_0x2270f6[_0x563b70];return _0x13e518;}export const codegenDefinitions=[codegenSdk,codegenSql];
@@ -1 +1 @@
1
- const a36_0x572393=a36_0x1288;(function(_0x23d6d6,_0x31cf50){const _0x2951cd=a36_0x1288,_0x47126d=_0x23d6d6();while(!![]){try{const _0x129890=parseInt(_0x2951cd(0x15f))/0x1*(parseInt(_0x2951cd(0x160))/0x2)+parseInt(_0x2951cd(0x16c))/0x3+-parseInt(_0x2951cd(0x170))/0x4+parseInt(_0x2951cd(0x173))/0x5+parseInt(_0x2951cd(0x16b))/0x6*(-parseInt(_0x2951cd(0x16f))/0x7)+-parseInt(_0x2951cd(0x169))/0x8+-parseInt(_0x2951cd(0x16d))/0x9;if(_0x129890===_0x31cf50)break;else _0x47126d['push'](_0x47126d['shift']());}catch(_0x7089a9){_0x47126d['push'](_0x47126d['shift']());}}}(a36_0x2701,0x4e74d));import{getOperationDetail,generateSdkCode}from'../../core/api-client.js';import{CODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function a36_0x2701(){const _0x1d05e6=['codegen','Omit\x20import\x20statements\x20from\x20generated\x20code','4817312JvFqGG','alias','789024UgpGZr','1902321KDEZbs','1613772ZlkRmj','Generate\x20TypeScript\x20SDK\x20code\x20for\x20a\x20dataset\x20operation','28jhaTrt','686984NtVHyj','string','skip-imports','2959205renndM','code','str','574643FfmiKz','2wNEqOw','Operation\x20name\x20(e.g.\x20filter,\x20getOne,\x20create,\x20update)','boolean','bool','operation','read','sdk'];a36_0x2701=function(){return _0x1d05e6;};return a36_0x2701();}function a36_0x1288(_0x407f9e,_0x263d72){_0x407f9e=_0x407f9e-0x15d;const _0x270198=a36_0x2701();let _0x128888=_0x270198[_0x407f9e];return _0x128888;}export const codegenSdk={'service':a36_0x572393(0x167),'command':a36_0x572393(0x166),'description':a36_0x572393(0x16e),'risk':a36_0x572393(0x165),'flags':[CODE_FLAG_OPTIONAL,{'name':a36_0x572393(0x16a),'type':a36_0x572393(0x171),'description':'Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon)'},{'name':a36_0x572393(0x164),'type':a36_0x572393(0x171),'required':!![],'description':a36_0x572393(0x161)},{'name':a36_0x572393(0x172),'type':a36_0x572393(0x162),'description':a36_0x572393(0x168)}],async 'execute'(_0x5b8301){const _0x5f477f=a36_0x572393,{dataset:_0x327d91,operation:_0x570473}=await getOperationDetail(_0x5b8301['appCode'],_0x5b8301['str']('code'),_0x5b8301['str'](_0x5f477f(0x164))),_0x2f4e4d=generateSdkCode(_0x327d91,_0x570473,{'includeImports':!_0x5b8301[_0x5f477f(0x163)](_0x5f477f(0x172))});return{'ok':!![],'data':{'dataset':{'name':_0x327d91['name'],'code':_0x327d91[_0x5f477f(0x15d)],'tableName':_0x327d91['tableName']},'operation':_0x5b8301[_0x5f477f(0x15e)]('operation'),'code':_0x2f4e4d}};}};
1
+ const a36_0x343d3b=a36_0x9061;function a36_0x9061(_0x3d18cf,_0x2e4128){_0x3d18cf=_0x3d18cf-0xdd;const _0x532dfd=a36_0x532d();let _0x9061db=_0x532dfd[_0x3d18cf];return _0x9061db;}(function(_0x28759c,_0x3988a3){const _0x424c8c=a36_0x9061,_0x4a90f6=_0x28759c();while(!![]){try{const _0x588009=-parseInt(_0x424c8c(0xef))/0x1+-parseInt(_0x424c8c(0xe8))/0x2+parseInt(_0x424c8c(0xdf))/0x3+-parseInt(_0x424c8c(0xe0))/0x4*(parseInt(_0x424c8c(0xf0))/0x5)+parseInt(_0x424c8c(0xde))/0x6*(-parseInt(_0x424c8c(0xe9))/0x7)+parseInt(_0x424c8c(0xed))/0x8+parseInt(_0x424c8c(0xeb))/0x9;if(_0x588009===_0x3988a3)break;else _0x4a90f6['push'](_0x4a90f6['shift']());}catch(_0x5869c2){_0x4a90f6['push'](_0x4a90f6['shift']());}}}(a36_0x532d,0xb1ae4));import{getOperationDetail,generateSdkCode}from'../../core/api-client.js';function a36_0x532d(){const _0x5034fa=['Generate\x20TypeScript\x20SDK\x20code\x20for\x20a\x20dataset\x20operation','read','str','sdk','588koiwMb','4308471wheqiI','84636NzqPaz','operation','Omit\x20import\x20statements\x20from\x20generated\x20code','string','skip-imports','codegen','code','bool','461204JlilpH','80857UvZnIL','Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon)','20903157tqRKVj','name','7790208yvOOet','tableName','1393745NmjCzr','295ySABNn','Operation\x20name\x20(e.g.\x20filter,\x20getOne,\x20create,\x20update)'];a36_0x532d=function(){return _0x5034fa;};return a36_0x532d();}import{CODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';export const codegenSdk={'service':a36_0x343d3b(0xe5),'command':a36_0x343d3b(0xdd),'description':a36_0x343d3b(0xf2),'risk':a36_0x343d3b(0xf3),'flags':[CODE_FLAG_OPTIONAL,{'name':'alias','type':a36_0x343d3b(0xe3),'description':a36_0x343d3b(0xea)},{'name':a36_0x343d3b(0xe1),'type':'string','required':!![],'description':a36_0x343d3b(0xf1)},{'name':a36_0x343d3b(0xe4),'type':'boolean','description':a36_0x343d3b(0xe2)}],async 'execute'(_0x5b0b7d){const _0x1f211c=a36_0x343d3b,{dataset:_0x34ff1a,operation:_0x424b41}=await getOperationDetail(_0x5b0b7d['appCode'],_0x5b0b7d['str'](_0x1f211c(0xe6)),_0x5b0b7d[_0x1f211c(0xf4)](_0x1f211c(0xe1))),_0xa07510=generateSdkCode(_0x34ff1a,_0x424b41,{'includeImports':!_0x5b0b7d[_0x1f211c(0xe7)](_0x1f211c(0xe4))});return{'ok':!![],'data':{'dataset':{'name':_0x34ff1a[_0x1f211c(0xec)],'code':_0x34ff1a[_0x1f211c(0xe6)],'tableName':_0x34ff1a[_0x1f211c(0xee)]},'operation':_0x5b0b7d['str'](_0x1f211c(0xe1)),'code':_0xa07510}};}};
@@ -1 +1 @@
1
- const a37_0x55423b=a37_0x3c7a;(function(_0x3b3ec5,_0x3163eb){const _0x37dc59=a37_0x3c7a,_0x99549=_0x3b3ec5();while(!![]){try{const _0x3bca25=-parseInt(_0x37dc59(0xde))/0x1*(-parseInt(_0x37dc59(0xf0))/0x2)+-parseInt(_0x37dc59(0xe7))/0x3*(-parseInt(_0x37dc59(0xe5))/0x4)+-parseInt(_0x37dc59(0xe1))/0x5+parseInt(_0x37dc59(0xeb))/0x6*(parseInt(_0x37dc59(0xd5))/0x7)+parseInt(_0x37dc59(0xe8))/0x8+-parseInt(_0x37dc59(0xef))/0x9*(parseInt(_0x37dc59(0xd9))/0xa)+-parseInt(_0x37dc59(0xe0))/0xb;if(_0x3bca25===_0x3163eb)break;else _0x99549['push'](_0x99549['shift']());}catch(_0x3e847f){_0x99549['push'](_0x99549['shift']());}}}(a37_0x1307,0x5a959));import{getSqlQueryInfo,generateSqlCodeTemplate}from'../../core/api-client.js';function a37_0x1307(){const _0x4063fc=['679539CdkVSy','codegen','sql','sqlCode','10AEtgqS','string','sqlcode','appCode','Generate\x20TypeScript\x20code\x20for\x20a\x20custom\x20SQL\x20query','302074bfZFnd','str','11589182wWeYhm','2863790YDPYMR','Code\x20target:\x20sdk\x20(default)\x20or\x20bff','boolean','no-imports','34124izaMtn','read','213FsyqEo','4339680XZzPiV','target','bool','18yIyQNH','sqlName','Omit\x20import\x20statements\x20from\x20generated\x20code','sdk','415683XqlCCE','4HwYziC'];a37_0x1307=function(){return _0x4063fc;};return a37_0x1307();}function a37_0x3c7a(_0x53627b,_0x16df0d){_0x53627b=_0x53627b-0xd5;const _0x130737=a37_0x1307();let _0x3c7a7a=_0x130737[_0x53627b];return _0x3c7a7a;}import{SQLCODE_FLAG}from'../../commands/common/flags.js';export const codegenSql={'service':a37_0x55423b(0xd6),'command':a37_0x55423b(0xd7),'description':a37_0x55423b(0xdd),'risk':a37_0x55423b(0xe6),'flags':[SQLCODE_FLAG,{'name':a37_0x55423b(0xe9),'type':a37_0x55423b(0xda),'description':a37_0x55423b(0xe2),'default':a37_0x55423b(0xee),'enum':['sdk','bff']},{'name':a37_0x55423b(0xe4),'type':a37_0x55423b(0xe3),'description':a37_0x55423b(0xed)}],async 'execute'(_0x43b7ba){const _0x2ffbc3=a37_0x55423b,_0x2d3db3=await getSqlQueryInfo(_0x43b7ba[_0x2ffbc3(0xdc)],_0x43b7ba['str'](_0x2ffbc3(0xdb))),_0x1d50d8=_0x43b7ba[_0x2ffbc3(0xdf)](_0x2ffbc3(0xe9))||_0x2ffbc3(0xee),_0x4bc366=generateSqlCodeTemplate(_0x2d3db3,{'target':_0x1d50d8,'includeImports':!_0x43b7ba[_0x2ffbc3(0xea)](_0x2ffbc3(0xe4))});return{'ok':!![],'data':{'sqlCode':_0x2d3db3[_0x2ffbc3(0xd8)],'sqlName':_0x2d3db3[_0x2ffbc3(0xec)],'target':_0x1d50d8,'code':_0x4bc366}};}};
1
+ const a37_0x3bc79b=a37_0x253a;(function(_0x4d2a2f,_0x298e07){const _0x1bfff1=a37_0x253a,_0xf8811e=_0x4d2a2f();while(!![]){try{const _0x8e21b9=-parseInt(_0x1bfff1(0x156))/0x1+parseInt(_0x1bfff1(0x15a))/0x2+-parseInt(_0x1bfff1(0x159))/0x3*(parseInt(_0x1bfff1(0x151))/0x4)+parseInt(_0x1bfff1(0x14b))/0x5+-parseInt(_0x1bfff1(0x152))/0x6+-parseInt(_0x1bfff1(0x15d))/0x7*(-parseInt(_0x1bfff1(0x15e))/0x8)+-parseInt(_0x1bfff1(0x14a))/0x9*(parseInt(_0x1bfff1(0x157))/0xa);if(_0x8e21b9===_0x298e07)break;else _0xf8811e['push'](_0xf8811e['shift']());}catch(_0x2440b7){_0xf8811e['push'](_0xf8811e['shift']());}}}(a37_0x25ef,0x2d818));import{getSqlQueryInfo,generateSqlCodeTemplate}from'../../core/api-client.js';import{SQLCODE_FLAG}from'../../commands/common/flags.js';function a37_0x25ef(){const _0xeb3166=['619532crWAOb','sdk','string','42WcVvqz','342904bqLhlf','appCode','read','sql','bool','1422YBfvpR','1615480CGGdBk','Generate\x20TypeScript\x20code\x20for\x20a\x20custom\x20SQL\x20query','sqlCode','target','bff','Omit\x20import\x20statements\x20from\x20generated\x20code','4SMtIDT','1992414AcZAmt','Code\x20target:\x20sdk\x20(default)\x20or\x20bff','str','no-imports','186960BVozhz','3950EGbeDe','sqlName','366627cJmGTT'];a37_0x25ef=function(){return _0xeb3166;};return a37_0x25ef();}function a37_0x253a(_0x13471e,_0x2a1607){_0x13471e=_0x13471e-0x146;const _0x25ef80=a37_0x25ef();let _0x253aac=_0x25ef80[_0x13471e];return _0x253aac;}export const codegenSql={'service':'codegen','command':a37_0x3bc79b(0x148),'description':a37_0x3bc79b(0x14c),'risk':a37_0x3bc79b(0x147),'flags':[SQLCODE_FLAG,{'name':a37_0x3bc79b(0x14e),'type':a37_0x3bc79b(0x15c),'description':a37_0x3bc79b(0x153),'default':a37_0x3bc79b(0x15b),'enum':[a37_0x3bc79b(0x15b),a37_0x3bc79b(0x14f)]},{'name':a37_0x3bc79b(0x155),'type':'boolean','description':a37_0x3bc79b(0x150)}],async 'execute'(_0x50af53){const _0x49ce5e=a37_0x3bc79b,_0x480e3c=await getSqlQueryInfo(_0x50af53[_0x49ce5e(0x146)],_0x50af53[_0x49ce5e(0x154)]('sqlcode')),_0x3c5adc=_0x50af53[_0x49ce5e(0x154)](_0x49ce5e(0x14e))||_0x49ce5e(0x15b),_0x34f2ea=generateSqlCodeTemplate(_0x480e3c,{'target':_0x3c5adc,'includeImports':!_0x50af53[_0x49ce5e(0x149)](_0x49ce5e(0x155))});return{'ok':!![],'data':{'sqlCode':_0x480e3c[_0x49ce5e(0x14d)],'sqlName':_0x480e3c[_0x49ce5e(0x158)],'target':_0x3c5adc,'code':_0x34f2ea}};}};
@@ -1 +1 @@
1
- (function(_0x239bb0,_0x413492){const _0x1419b6=a38_0x18a9,_0x382560=_0x239bb0();while(!![]){try{const _0x52827c=-parseInt(_0x1419b6(0x15a))/0x1*(-parseInt(_0x1419b6(0x148))/0x2)+-parseInt(_0x1419b6(0x156))/0x3*(-parseInt(_0x1419b6(0x158))/0x4)+parseInt(_0x1419b6(0x145))/0x5+-parseInt(_0x1419b6(0x141))/0x6+-parseInt(_0x1419b6(0x140))/0x7+parseInt(_0x1419b6(0x149))/0x8*(-parseInt(_0x1419b6(0x14c))/0x9)+-parseInt(_0x1419b6(0x157))/0xa;if(_0x52827c===_0x413492)break;else _0x382560['push'](_0x382560['shift']());}catch(_0x3c015){_0x382560['push'](_0x382560['shift']());}}}(a38_0x36cf,0xbbded));function a38_0x18a9(_0x62fd2d,_0x18cf37){_0x62fd2d=_0x62fd2d-0x13a;const _0x36cf72=a38_0x36cf();let _0x18a9b2=_0x36cf72[_0x62fd2d];return _0x18a9b2;}import{input,checkbox,select}from'@inquirer/prompts';import a38_0x268f2e from'chalk';function a38_0x36cf(){const _0x45bf10=['yellow','manual','map','(跳过,稍后通过\x20config\x20set\x20appcode\x20配置)','message','trim','length','请选择要绑定的应用:','11538fnwKco','6881010lmgOkf','976VRiQjr','正在获取可用应用列表...','3ibXTBu','\x20\x20(','includes','(未检测到登录态,请手动输入\x20App\x20Code\x20或直接跳过)','\x0a未找到可用应用。','cyan','gray','✎\x20自定义输入\x20appcode','Invalid\x20App\x20Code','App\x20Code:','\x0a无法获取远程应用列表,请手动输入。','未找到可用应用。','无法获取远程应用列表,请手动输入。','1626303DUEAQY','311244iRZlMM','(跳过,稍后配置)','skip','✎\x20手动输入','3697380RtWbHa','custom','appCode','113726GHDDbK','144ixCzqD','appName','valid','53334LNiWsO','请输入\x20App\x20Code:'];a38_0x36cf=function(){return _0x45bf10;};return a38_0x36cf();}import{validateAppcode}from'../../commands/common/validate.js';import{listRemoteApps}from'../../core/api-client.js';import{withActiveCookie}from'../../utils/with-active-cookie.js';import{writeCliSideChannelLine}from'../../utils/write-cli-side-channel.js';export async function promptCustomAppcode(){const _0x54febc=a38_0x18a9,_0x441e6d=await input({'message':_0x54febc(0x14d),'validate':_0x17ed75=>{const _0x521419=_0x54febc,_0x418960=validateAppcode(_0x17ed75[_0x521419(0x153)]());return _0x418960[_0x521419(0x14b)]||_0x418960[_0x521419(0x152)]||_0x521419(0x13b);}});return _0x441e6d[_0x54febc(0x153)]();}export async function promptAppSelection(_0x236fb5){const _0x38bb76=a38_0x18a9,_0x20f6f6=[{'name':a38_0x268f2e[_0x38bb76(0x14e)](_0x38bb76(0x13a)),'value':-0x1},..._0x236fb5[_0x38bb76(0x150)]((_0x677ad0,_0x3268a5)=>({'name':_0x677ad0[_0x38bb76(0x14a)]+'\x20\x20'+a38_0x268f2e[_0x38bb76(0x160)]('('+_0x677ad0[_0x38bb76(0x147)]+')'),'value':_0x3268a5}))],_0x2572b9=await checkbox({'message':'获取到\x20'+a38_0x268f2e[_0x38bb76(0x15f)](_0x236fb5[_0x38bb76(0x154)])+'\x20个应用,请选择\x20(空格勾选,\x20a=全选,\x20i=反选):','choices':_0x20f6f6,'loop':![]});if(_0x2572b9[_0x38bb76(0x15c)](-0x1))return'custom';if(_0x2572b9[_0x38bb76(0x154)]===0x0)return _0x38bb76(0x146);return _0x2572b9[_0x38bb76(0x150)](_0x54ab34=>_0x236fb5[_0x54ab34]);}export async function promptSingleAppSelection(_0x137506){const _0x574ec5=a38_0x18a9,_0x45781f=[{'name':a38_0x268f2e[_0x574ec5(0x160)](_0x574ec5(0x151)),'value':'skip'},{'name':a38_0x268f2e[_0x574ec5(0x14e)](_0x574ec5(0x13a)),'value':_0x574ec5(0x146)},..._0x137506[_0x574ec5(0x150)](_0x40dd7a=>({'name':_0x40dd7a[_0x574ec5(0x14a)]+'\x20\x20'+a38_0x268f2e[_0x574ec5(0x160)]('('+_0x40dd7a['appCode']+')'),'value':_0x40dd7a[_0x574ec5(0x147)]}))],_0x249b87=await select({'message':_0x574ec5(0x155),'choices':_0x45781f});if(_0x249b87==='skip')return _0x574ec5(0x143);if(_0x249b87===_0x574ec5(0x146))return _0x574ec5(0x146);return _0x137506['find'](_0x3be17f=>_0x3be17f[_0x574ec5(0x147)]===_0x249b87);}export async function selectSingleAppcode(_0x101030){const _0xe214cf=a38_0x18a9;if(!_0x101030)return writeCliSideChannelLine(a38_0x268f2e[_0xe214cf(0x160)](_0xe214cf(0x15d))),_fallbackOrSkip();writeCliSideChannelLine(_0xe214cf(0x159));let _0x2f38fd;try{_0x2f38fd=await withActiveCookie(_0x101030,()=>listRemoteApps());}catch(_0x24e222){writeCliSideChannelLine(a38_0x268f2e[_0xe214cf(0x14e)](_0xe214cf(0x13f)));if(_0x24e222 instanceof Error)writeCliSideChannelLine(a38_0x268f2e[_0xe214cf(0x160)]('\x20\x20('+_0x24e222[_0xe214cf(0x152)]+')'));return _fallbackOrSkip();}if(_0x2f38fd[_0xe214cf(0x154)]===0x0)return writeCliSideChannelLine(a38_0x268f2e[_0xe214cf(0x14e)](_0xe214cf(0x13e))),_fallbackOrSkip();const _0x300b69=await promptSingleAppSelection(_0x2f38fd);if(_0x300b69===_0xe214cf(0x143))return'';if(_0x300b69===_0xe214cf(0x146))return promptCustomAppcode();return _0x300b69[_0xe214cf(0x147)];}export async function selectMultipleApps(_0x46bc5d){const _0x1f1ec3=a38_0x18a9;writeCliSideChannelLine('正在获取可用应用列表...');let _0x44904d;try{_0x44904d=await withActiveCookie(_0x46bc5d,()=>listRemoteApps());}catch(_0x39d11a){writeCliSideChannelLine(_0x1f1ec3(0x13d));if(_0x39d11a instanceof Error)writeCliSideChannelLine(_0x1f1ec3(0x15b)+_0x39d11a[_0x1f1ec3(0x152)]+')');return _0x1f1ec3(0x146);}if(_0x44904d['length']===0x0)return writeCliSideChannelLine(_0x1f1ec3(0x15e)),_0x1f1ec3(0x146);return promptAppSelection(_0x44904d);}async function _fallbackOrSkip(){const _0x342dc2=a38_0x18a9,_0x1f9850=await select({'message':_0x342dc2(0x13c),'choices':[{'name':a38_0x268f2e[_0x342dc2(0x160)](_0x342dc2(0x142)),'value':'skip'},{'name':a38_0x268f2e['yellow'](_0x342dc2(0x144)),'value':_0x342dc2(0x14f)}]});if(_0x1f9850===_0x342dc2(0x143))return'';return promptCustomAppcode();}
1
+ (function(_0x1138d8,_0x4e6e62){const _0x38ab40=a38_0x308a,_0x3f8007=_0x1138d8();while(!![]){try{const _0x3e1887=-parseInt(_0x38ab40(0xaf))/0x1*(parseInt(_0x38ab40(0xae))/0x2)+-parseInt(_0x38ab40(0xc2))/0x3*(parseInt(_0x38ab40(0xbc))/0x4)+parseInt(_0x38ab40(0xb6))/0x5+-parseInt(_0x38ab40(0xa7))/0x6*(parseInt(_0x38ab40(0xbb))/0x7)+parseInt(_0x38ab40(0x9d))/0x8*(-parseInt(_0x38ab40(0xb0))/0x9)+parseInt(_0x38ab40(0xbf))/0xa*(-parseInt(_0x38ab40(0xb1))/0xb)+parseInt(_0x38ab40(0xc0))/0xc*(parseInt(_0x38ab40(0xa1))/0xd);if(_0x3e1887===_0x4e6e62)break;else _0x3f8007['push'](_0x3f8007['shift']());}catch(_0x17ec5e){_0x3f8007['push'](_0x3f8007['shift']());}}}(a38_0x531d,0x86f7e));import{input,checkbox,select}from'@inquirer/prompts';import a38_0x9df6d7 from'chalk';import{validateAppcode}from'../../commands/common/validate.js';import{listRemoteApps}from'../../core/api-client.js';function a38_0x531d(){const _0x13c09d=['Invalid\x20App\x20Code','custom','✎\x20自定义输入\x20appcode','appName','\x20\x20(','2142IdSqGm','735NxxMYP','171jOJjBs','1204291prafTq','请选择要绑定的应用:','gray','\x0a未找到可用应用。','message','5402855HweJED','trim','(跳过,稍后配置)','appCode','✎\x20手动输入','3325OrDhlU','109996sJZBUb','map','(跳过,稍后通过\x20config\x20set\x20appcode\x20配置)','40wXDvPU','276UZKDjF','manual','78ZxUgOV','yellow','App\x20Code:','skip','185768lmYIlh','find','获取到\x20','\x0a无法获取远程应用列表,请手动输入。','1475071TjuNOR','请输入\x20App\x20Code:','valid','未找到可用应用。','\x20个应用,请选择\x20(空格勾选,\x20a=全选,\x20i=反选):','length','9552MEtUPG','(未检测到登录态,请手动输入\x20App\x20Code\x20或直接跳过)'];a38_0x531d=function(){return _0x13c09d;};return a38_0x531d();}import{withActiveCookie}from'../../utils/with-active-cookie.js';import{writeCliSideChannelLine}from'../../utils/write-cli-side-channel.js';export async function promptCustomAppcode(){const _0x510c19=a38_0x308a,_0x39fdce=await input({'message':_0x510c19(0xa2),'validate':_0x37ad09=>{const _0x401de0=_0x510c19,_0x1057f6=validateAppcode(_0x37ad09[_0x401de0(0xb7)]());return _0x1057f6[_0x401de0(0xa3)]||_0x1057f6[_0x401de0(0xb5)]||_0x401de0(0xa9);}});return _0x39fdce[_0x510c19(0xb7)]();}function a38_0x308a(_0xdeabb0,_0x1d8601){_0xdeabb0=_0xdeabb0-0x9c;const _0x531dff=a38_0x531d();let _0x308a54=_0x531dff[_0xdeabb0];return _0x308a54;}export async function promptAppSelection(_0x3055c3){const _0x2d6d8f=a38_0x308a,_0x46459f=[{'name':a38_0x9df6d7[_0x2d6d8f(0xc3)](_0x2d6d8f(0xab)),'value':-0x1},..._0x3055c3['map']((_0x57d897,_0x5e93f4)=>({'name':_0x57d897[_0x2d6d8f(0xac)]+'\x20\x20'+a38_0x9df6d7[_0x2d6d8f(0xb3)]('('+_0x57d897['appCode']+')'),'value':_0x5e93f4}))],_0x1ea8ca=await checkbox({'message':_0x2d6d8f(0x9f)+a38_0x9df6d7['cyan'](_0x3055c3[_0x2d6d8f(0xa6)])+_0x2d6d8f(0xa5),'choices':_0x46459f,'loop':![]});if(_0x1ea8ca['includes'](-0x1))return _0x2d6d8f(0xaa);if(_0x1ea8ca[_0x2d6d8f(0xa6)]===0x0)return'custom';return _0x1ea8ca['map'](_0x3523b5=>_0x3055c3[_0x3523b5]);}export async function promptSingleAppSelection(_0x289a92){const _0x1e1104=a38_0x308a,_0x164627=[{'name':a38_0x9df6d7[_0x1e1104(0xb3)](_0x1e1104(0xbe)),'value':_0x1e1104(0x9c)},{'name':a38_0x9df6d7[_0x1e1104(0xc3)](_0x1e1104(0xab)),'value':_0x1e1104(0xaa)},..._0x289a92[_0x1e1104(0xbd)](_0x1a080c=>({'name':_0x1a080c['appName']+'\x20\x20'+a38_0x9df6d7[_0x1e1104(0xb3)]('('+_0x1a080c[_0x1e1104(0xb9)]+')'),'value':_0x1a080c[_0x1e1104(0xb9)]}))],_0x35cb27=await select({'message':_0x1e1104(0xb2),'choices':_0x164627});if(_0x35cb27===_0x1e1104(0x9c))return _0x1e1104(0x9c);if(_0x35cb27==='custom')return'custom';return _0x289a92[_0x1e1104(0x9e)](_0x142d44=>_0x142d44[_0x1e1104(0xb9)]===_0x35cb27);}export async function selectSingleAppcode(_0xcb2c02){const _0x169bce=a38_0x308a;if(!_0xcb2c02)return writeCliSideChannelLine(a38_0x9df6d7['gray'](_0x169bce(0xa8))),_fallbackOrSkip();writeCliSideChannelLine('正在获取可用应用列表...');let _0x7ea7cc;try{_0x7ea7cc=await withActiveCookie(_0xcb2c02,()=>listRemoteApps());}catch(_0x2241e6){writeCliSideChannelLine(a38_0x9df6d7[_0x169bce(0xc3)]('无法获取远程应用列表,请手动输入。'));if(_0x2241e6 instanceof Error)writeCliSideChannelLine(a38_0x9df6d7[_0x169bce(0xb3)](_0x169bce(0xad)+_0x2241e6[_0x169bce(0xb5)]+')'));return _fallbackOrSkip();}if(_0x7ea7cc['length']===0x0)return writeCliSideChannelLine(a38_0x9df6d7[_0x169bce(0xc3)](_0x169bce(0xa4))),_fallbackOrSkip();const _0x27ece2=await promptSingleAppSelection(_0x7ea7cc);if(_0x27ece2===_0x169bce(0x9c))return'';if(_0x27ece2==='custom')return promptCustomAppcode();return _0x27ece2[_0x169bce(0xb9)];}export async function selectMultipleApps(_0x1e07fe){const _0x3de53b=a38_0x308a;writeCliSideChannelLine('正在获取可用应用列表...');let _0x1755c4;try{_0x1755c4=await withActiveCookie(_0x1e07fe,()=>listRemoteApps());}catch(_0x227305){writeCliSideChannelLine(_0x3de53b(0xa0));if(_0x227305 instanceof Error)writeCliSideChannelLine(_0x3de53b(0xad)+_0x227305[_0x3de53b(0xb5)]+')');return'custom';}if(_0x1755c4['length']===0x0)return writeCliSideChannelLine(_0x3de53b(0xb4)),_0x3de53b(0xaa);return promptAppSelection(_0x1755c4);}async function _fallbackOrSkip(){const _0xe4a4da=a38_0x308a,_0x49b8a5=await select({'message':_0xe4a4da(0xc4),'choices':[{'name':a38_0x9df6d7[_0xe4a4da(0xb3)](_0xe4a4da(0xb8)),'value':'skip'},{'name':a38_0x9df6d7[_0xe4a4da(0xc3)](_0xe4a4da(0xba)),'value':_0xe4a4da(0xc1)}]});if(_0x49b8a5==='skip')return'';return promptCustomAppcode();}
@@ -1 +1 @@
1
- const a39_0x532aad=a39_0x98c7;(function(_0x5f1773,_0xc03456){const _0x11e137=a39_0x98c7,_0x45530b=_0x5f1773();while(!![]){try{const _0x362840=-parseInt(_0x11e137(0x10b))/0x1*(-parseInt(_0x11e137(0x10c))/0x2)+-parseInt(_0x11e137(0x105))/0x3+parseInt(_0x11e137(0xf8))/0x4+parseInt(_0x11e137(0xfa))/0x5*(-parseInt(_0x11e137(0x106))/0x6)+parseInt(_0x11e137(0xff))/0x7*(-parseInt(_0x11e137(0xfd))/0x8)+parseInt(_0x11e137(0xfb))/0x9+parseInt(_0x11e137(0x108))/0xa;if(_0x362840===_0xc03456)break;else _0x45530b['push'](_0x45530b['shift']());}catch(_0x37751d){_0x45530b['push'](_0x45530b['shift']());}}}(a39_0x4b1b,0x855f0));function a39_0x4b1b(){const _0x4bb443=['198602LaAvFl','code','number','3507852lkIjTI','SQL\x20code\x20identifier\x20(format:\x20xxxxxxxx-xxxxxxxx,\x20e.g.\x202305f915-dd48cd4c)','505lmOlVa','4254183RhdHUT','Dataset\x20code\x20(32-char\x20hex\x20UUID)','2780616tWwRpi','string','7euUGqV','datasetcode','dbtype','App\x20code\x20(overrides\x20config\x20file,\x20e.g.\x20app-xxxxx)','MYSQL','SQL\x20code\x20in\x20format\x20xxxxxxxx-xxxxxxxx\x20(e.g.\x202305f915-dd48cd4c)','2702943YgQPXL','8046BhZsRW','Database\x20connection\x20ID\x20(dblink\x20id\x20from\x20db\x20list)','4813360AtsfZL','POSTGRESQL','a\x2032-character\x20hex\x20string\x20(e.g.\x2099a909313f1fa7153186431e1c551588)','1nRVanq'];a39_0x4b1b=function(){return _0x4bb443;};return a39_0x4b1b();}export const DATASET_CODE_PATTERN={'regex':/^[a-f0-9]{32}$/i,'description':a39_0x532aad(0x10a)};export const CODE_FLAG={'name':a39_0x532aad(0x10d),'type':a39_0x532aad(0xfe),'required':!![],'description':a39_0x532aad(0xfc),'pattern':DATASET_CODE_PATTERN};export const CODE_FLAG_OPTIONAL={...CODE_FLAG,'required':![]};export const DATASETCODE_FLAG_OPTIONAL={...CODE_FLAG_OPTIONAL,'name':a39_0x532aad(0x100),'description':a39_0x532aad(0xfc)};export const SQLCODE_FLAG={'name':'sqlcode','type':a39_0x532aad(0xfe),'required':!![],'description':a39_0x532aad(0xf9),'pattern':{'regex':/^[a-f0-9]{8}-[a-f0-9]{8}$/i,'description':a39_0x532aad(0x104)}};export const APPCODE_FLAG_OPTIONAL={'name':'appcode','type':a39_0x532aad(0xfe),'required':![],'description':a39_0x532aad(0x102)};export const SQLCODE_FLAG_OPTIONAL={...SQLCODE_FLAG,'required':![]};function a39_0x98c7(_0x5cd1e7,_0x1e7b54){_0x5cd1e7=_0x5cd1e7-0xf8;const _0x4b1b8d=a39_0x4b1b();let _0x98c7e7=_0x4b1b8d[_0x5cd1e7];return _0x98c7e7;}export const DBLINK_ID_FLAG={'name':'id','type':a39_0x532aad(0x10e),'required':!![],'description':a39_0x532aad(0x107)};export const DB_TYPE_FLAG={'name':a39_0x532aad(0x101),'type':'string','required':!![],'description':'Database\x20product\x20type','enum':[a39_0x532aad(0x103),a39_0x532aad(0x109)]};
1
+ const a39_0x28a337=a39_0x3725;(function(_0xd2b132,_0x51e06f){const _0x775ebc=a39_0x3725,_0x5ba870=_0xd2b132();while(!![]){try{const _0x4949cb=-parseInt(_0x775ebc(0xf0))/0x1+-parseInt(_0x775ebc(0xf4))/0x2*(parseInt(_0x775ebc(0xe5))/0x3)+parseInt(_0x775ebc(0xe3))/0x4*(parseInt(_0x775ebc(0xe2))/0x5)+parseInt(_0x775ebc(0xe4))/0x6*(parseInt(_0x775ebc(0xf1))/0x7)+-parseInt(_0x775ebc(0xea))/0x8+-parseInt(_0x775ebc(0xf6))/0x9+parseInt(_0x775ebc(0xeb))/0xa;if(_0x4949cb===_0x51e06f)break;else _0x5ba870['push'](_0x5ba870['shift']());}catch(_0x5b1198){_0x5ba870['push'](_0x5ba870['shift']());}}}(a39_0x5a19,0x6f99b));export const DATASET_CODE_PATTERN={'regex':/^[a-f0-9]{32}$/i,'description':a39_0x28a337(0xf2)};export const CODE_FLAG={'name':a39_0x28a337(0xf7),'type':'string','required':!![],'description':a39_0x28a337(0xef),'pattern':DATASET_CODE_PATTERN};export const CODE_FLAG_OPTIONAL={...CODE_FLAG,'required':![]};export const DATASETCODE_FLAG_OPTIONAL={...CODE_FLAG_OPTIONAL,'name':a39_0x28a337(0xee),'description':a39_0x28a337(0xef)};function a39_0x3725(_0x36b1e6,_0x29e0ba){_0x36b1e6=_0x36b1e6-0xe1;const _0x5a1947=a39_0x5a19();let _0x372587=_0x5a1947[_0x36b1e6];return _0x372587;}export const SQLCODE_FLAG={'name':a39_0x28a337(0xf3),'type':a39_0x28a337(0xe1),'required':!![],'description':a39_0x28a337(0xf5),'pattern':{'regex':/^[a-f0-9]{8}-[a-f0-9]{8}$/i,'description':'SQL\x20code\x20in\x20format\x20xxxxxxxx-xxxxxxxx\x20(e.g.\x202305f915-dd48cd4c)'}};export const APPCODE_FLAG_OPTIONAL={'name':a39_0x28a337(0xe9),'type':a39_0x28a337(0xe1),'required':![],'description':a39_0x28a337(0xec)};function a39_0x5a19(){const _0x3badb9=['Dataset\x20code\x20(32-char\x20hex\x20UUID)','79758BsiTYN','204162gsZFno','a\x2032-character\x20hex\x20string\x20(e.g.\x2099a909313f1fa7153186431e1c551588)','sqlcode','10dZODjr','SQL\x20code\x20identifier\x20(format:\x20xxxxxxxx-xxxxxxxx,\x20e.g.\x202305f915-dd48cd4c)','1967742SmaBHP','code','string','53245YWQRFE','12oUWYIL','162ECthoC','168123acCQrd','dbtype','number','Database\x20product\x20type','appcode','6759984Zrnqmo','10612850vloVkm','App\x20code\x20(overrides\x20config\x20file,\x20e.g.\x20app-xxxxx)','MYSQL','datasetcode'];a39_0x5a19=function(){return _0x3badb9;};return a39_0x5a19();}export const SQLCODE_FLAG_OPTIONAL={...SQLCODE_FLAG,'required':![]};export const DBLINK_ID_FLAG={'name':'id','type':a39_0x28a337(0xe7),'required':!![],'description':'Database\x20connection\x20ID\x20(dblink\x20id\x20from\x20db\x20list)'};export const DB_TYPE_FLAG={'name':a39_0x28a337(0xe6),'type':'string','required':!![],'description':a39_0x28a337(0xe8),'enum':[a39_0x28a337(0xed),'POSTGRESQL']};
@@ -1 +1 @@
1
- function a40_0x22ac(_0x19c86c,_0x28178a){_0x19c86c=_0x19c86c-0x1e4;const _0x2306b2=a40_0x2306();let _0x22ac6f=_0x2306b2[_0x19c86c];return _0x22ac6f;}(function(_0x1c5e89,_0x4b4fe0){const _0x2fd063=a40_0x22ac,_0x20f001=_0x1c5e89();while(!![]){try{const _0x24b35f=parseInt(_0x2fd063(0x1ec))/0x1+-parseInt(_0x2fd063(0x1e7))/0x2+-parseInt(_0x2fd063(0x1eb))/0x3*(parseInt(_0x2fd063(0x1e4))/0x4)+parseInt(_0x2fd063(0x1e9))/0x5+-parseInt(_0x2fd063(0x1ee))/0x6*(-parseInt(_0x2fd063(0x1e8))/0x7)+-parseInt(_0x2fd063(0x1e6))/0x8+parseInt(_0x2fd063(0x1f1))/0x9*(parseInt(_0x2fd063(0x1ed))/0xa);if(_0x24b35f===_0x4b4fe0)break;else _0x20f001['push'](_0x20f001['shift']());}catch(_0x25fbaa){_0x20f001['push'](_0x20f001['shift']());}}}(a40_0x2306,0xc6c65));export function validateAppcode(_0x66ab9c){const _0x72f62f=a40_0x22ac,_0x59c04c=_0x66ab9c[_0x72f62f(0x1e5)]();if(!_0x59c04c)return{'valid':![],'message':_0x72f62f(0x1f2)};if(_0x59c04c['length']>0x64)return{'valid':![],'message':_0x72f62f(0x1ea)};if(!/^[A-Za-z0-9_-]+$/[_0x72f62f(0x1f0)](_0x59c04c))return{'valid':![],'message':_0x72f62f(0x1ef)};return{'valid':!![]};}function a40_0x2306(){const _0x5b4e63=['7986624wKqzTh','32520KoQVmE','494844tlZEcr','2343365PYbYLk','App\x20Code\x20cannot\x20exceed\x20100\x20characters','6WWYJMI','535217JUMEuS','139970GInDVc','24eOVRoF','Only\x20letters,\x20numbers,\x20-\x20and\x20_\x20are\x20allowed','test','369NotSwa','App\x20Code\x20cannot\x20be\x20empty','63532KXNfKR','trim'];a40_0x2306=function(){return _0x5b4e63;};return a40_0x2306();}
1
+ function a40_0x4297(_0x32bb2b,_0x1b06b5){_0x32bb2b=_0x32bb2b-0x17a;const _0x1ddf3a=a40_0x1ddf();let _0x4297fb=_0x1ddf3a[_0x32bb2b];return _0x4297fb;}(function(_0xc04ecb,_0x3424c8){const _0x55cee5=a40_0x4297,_0x2fa2ca=_0xc04ecb();while(!![]){try{const _0x255da0=parseInt(_0x55cee5(0x17b))/0x1+parseInt(_0x55cee5(0x17f))/0x2+parseInt(_0x55cee5(0x188))/0x3*(-parseInt(_0x55cee5(0x17d))/0x4)+-parseInt(_0x55cee5(0x183))/0x5*(-parseInt(_0x55cee5(0x17e))/0x6)+-parseInt(_0x55cee5(0x185))/0x7*(parseInt(_0x55cee5(0x186))/0x8)+parseInt(_0x55cee5(0x17c))/0x9*(parseInt(_0x55cee5(0x181))/0xa)+-parseInt(_0x55cee5(0x17a))/0xb;if(_0x255da0===_0x3424c8)break;else _0x2fa2ca['push'](_0x2fa2ca['shift']());}catch(_0x2ad360){_0x2fa2ca['push'](_0x2fa2ca['shift']());}}}(a40_0x1ddf,0xac91d));function a40_0x1ddf(){const _0x3b763f=['Only\x20letters,\x20numbers,\x20-\x20and\x20_\x20are\x20allowed','1442098ZyxPEq','40TeJZCi','trim','888BYZCtV','10881035ikHVdO','6237ooetuP','9718011DVTYQP','13792uMBShC','12rUDFVU','2804740mhJsDK','length','10RPkbuO','App\x20Code\x20cannot\x20be\x20empty','3145805xTsnAr'];a40_0x1ddf=function(){return _0x3b763f;};return a40_0x1ddf();}export function validateAppcode(_0xd9bafc){const _0x272b75=a40_0x4297,_0x39656b=_0xd9bafc[_0x272b75(0x187)]();if(!_0x39656b)return{'valid':![],'message':_0x272b75(0x182)};if(_0x39656b[_0x272b75(0x180)]>0x64)return{'valid':![],'message':'App\x20Code\x20cannot\x20exceed\x20100\x20characters'};if(!/^[A-Za-z0-9_-]+$/['test'](_0x39656b))return{'valid':![],'message':_0x272b75(0x184)};return{'valid':!![]};}
@@ -1 +1 @@
1
- const a41_0x4661dc=a41_0x1d8e;function a41_0x1d8e(_0x218983,_0x24903a){_0x218983=_0x218983-0x18e;const _0x3f1ed5=a41_0x3f1e();let _0x1d8e1a=_0x3f1ed5[_0x218983];return _0x1d8e1a;}(function(_0x2e615f,_0x3c34c5){const _0x2e3332=a41_0x1d8e,_0xf2666b=_0x2e615f();while(!![]){try{const _0x98e1f5=-parseInt(_0x2e3332(0x19b))/0x1*(-parseInt(_0x2e3332(0x198))/0x2)+-parseInt(_0x2e3332(0x196))/0x3+-parseInt(_0x2e3332(0x190))/0x4+-parseInt(_0x2e3332(0x199))/0x5+-parseInt(_0x2e3332(0x18f))/0x6+-parseInt(_0x2e3332(0x194))/0x7+parseInt(_0x2e3332(0x192))/0x8;if(_0x98e1f5===_0x3c34c5)break;else _0xf2666b['push'](_0xf2666b['shift']());}catch(_0x41d318){_0xf2666b['push'](_0xf2666b['shift']());}}}(a41_0x3f1e,0x7ec0b));import{CliErrors}from'../../errors.js';import{readConfig}from'../../utils/config.js';import{CLI_BIN_NAME}from'../../constant/cli.js';import{getConfigCommandKeyDescription}from'../../commands/config/shared.js';function a41_0x3f1e(){const _0xf92b8d=['759632vajtSO','key','24386984rUNkQB','\x20config\x20get\x20--key\x20<key>','6882456iTlRvT','str','2892966rPCPqT','string','8zEPCwC','4911385uTICZB','config','246913qbLSre','validation','get','Usage:\x20','read','object','appcode','2382786nThWbl'];a41_0x3f1e=function(){return _0xf92b8d;};return a41_0x3f1e();}async function execute(_0x494f7e){const _0x26cab0=a41_0x1d8e,_0x5d83b3=_0x494f7e[_0x26cab0(0x195)](_0x26cab0(0x191));if(!_0x5d83b3)throw CliErrors[_0x26cab0(0x19c)]('Missing\x20key.',_0x26cab0(0x19e)+CLI_BIN_NAME+_0x26cab0(0x193));const _0x13c1b7=readConfig(),_0x343304=_0x5d83b3==='app'?_0x26cab0(0x18e):_0x5d83b3,_0x17d11e=_0x13c1b7[_0x343304];if(_0x17d11e===undefined)throw CliErrors[_0x26cab0(0x19c)]('Key\x20not\x20found:\x20'+_0x5d83b3);return{'ok':!![],'data':typeof _0x17d11e===_0x26cab0(0x1a0)?_0x17d11e:{[_0x343304]:_0x17d11e},'message':typeof _0x17d11e===_0x26cab0(0x1a0)?undefined:String(_0x17d11e)};}export const configGetDefinition={'service':a41_0x4661dc(0x19a),'command':a41_0x4661dc(0x19d),'description':'Get\x20a\x20config\x20value\x20by\x20key','risk':a41_0x4661dc(0x19f),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a41_0x4661dc(0x191),'type':a41_0x4661dc(0x197),'description':getConfigCommandKeyDescription(),'required':!![]}],'execute':execute};
1
+ const a41_0x17345e=a41_0x34e3;(function(_0x49216f,_0x5df963){const _0x584173=a41_0x34e3,_0x2c224b=_0x49216f();while(!![]){try{const _0x575daa=-parseInt(_0x584173(0xa4))/0x1*(parseInt(_0x584173(0x9f))/0x2)+-parseInt(_0x584173(0x9e))/0x3*(-parseInt(_0x584173(0xa7))/0x4)+parseInt(_0x584173(0xa2))/0x5+-parseInt(_0x584173(0x9b))/0x6+parseInt(_0x584173(0xa6))/0x7*(parseInt(_0x584173(0x99))/0x8)+-parseInt(_0x584173(0x96))/0x9*(-parseInt(_0x584173(0x98))/0xa)+-parseInt(_0x584173(0xa3))/0xb;if(_0x575daa===_0x5df963)break;else _0x2c224b['push'](_0x2c224b['shift']());}catch(_0xc621db){_0x2c224b['push'](_0x2c224b['shift']());}}}(a41_0x4686,0x5eb91));function a41_0x4686(){const _0xb76a2f=['appcode','3101190ezfyKn','48xjGRnz','\x20config\x20get\x20--key\x20<key>','2968128bDoaRz','object','validation','2062569WdCbhS','604eNfzVO','Missing\x20key.','Key\x20not\x20found:\x20','1382555vrGUkZ','5400318jghSdj','1205LwlDpY','string','540596AoaRzH','4xtBhUA','Usage:\x20','key','9raytIi'];a41_0x4686=function(){return _0xb76a2f;};return a41_0x4686();}function a41_0x34e3(_0x52bb64,_0x458732){_0x52bb64=_0x52bb64-0x96;const _0x4686e9=a41_0x4686();let _0x34e3f7=_0x4686e9[_0x52bb64];return _0x34e3f7;}import{CliErrors}from'../../errors.js';import{readConfig}from'../../utils/config.js';import{CLI_BIN_NAME}from'../../constant/cli.js';import{getConfigCommandKeyDescription}from'../../commands/config/shared.js';async function execute(_0x5dcbd2){const _0x12f0c0=a41_0x34e3,_0x4a1b1c=_0x5dcbd2['str'](_0x12f0c0(0xa9));if(!_0x4a1b1c)throw CliErrors[_0x12f0c0(0x9d)](_0x12f0c0(0xa0),_0x12f0c0(0xa8)+CLI_BIN_NAME+_0x12f0c0(0x9a));const _0x4adff4=readConfig(),_0x3edad2=_0x4a1b1c==='app'?_0x12f0c0(0x97):_0x4a1b1c,_0x1970ae=_0x4adff4[_0x3edad2];if(_0x1970ae===undefined)throw CliErrors[_0x12f0c0(0x9d)](_0x12f0c0(0xa1)+_0x4a1b1c);return{'ok':!![],'data':typeof _0x1970ae===_0x12f0c0(0x9c)?_0x1970ae:{[_0x3edad2]:_0x1970ae},'message':typeof _0x1970ae===_0x12f0c0(0x9c)?undefined:String(_0x1970ae)};}export const configGetDefinition={'service':'config','command':'get','description':'Get\x20a\x20config\x20value\x20by\x20key','risk':'read','requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a41_0x17345e(0xa9),'type':a41_0x17345e(0xa5),'description':getConfigCommandKeyDescription(),'required':!![]}],'execute':execute};
@@ -1 +1 @@
1
- (function(_0x11f1b5,_0x3ca6d1){const _0x3c5322=a42_0x3c7c,_0x3d33fa=_0x11f1b5();while(!![]){try{const _0x581e4e=parseInt(_0x3c5322(0xc0))/0x1*(-parseInt(_0x3c5322(0xc6))/0x2)+parseInt(_0x3c5322(0xc1))/0x3*(parseInt(_0x3c5322(0xc2))/0x4)+-parseInt(_0x3c5322(0xbe))/0x5+parseInt(_0x3c5322(0xc5))/0x6+-parseInt(_0x3c5322(0xc4))/0x7*(parseInt(_0x3c5322(0xc8))/0x8)+-parseInt(_0x3c5322(0xc3))/0x9*(parseInt(_0x3c5322(0xc7))/0xa)+parseInt(_0x3c5322(0xbf))/0xb;if(_0x581e4e===_0x3ca6d1)break;else _0x3d33fa['push'](_0x3d33fa['shift']());}catch(_0x423388){_0x3d33fa['push'](_0x3d33fa['shift']());}}}(a42_0x336a,0x33aef));import{configListDefinition}from'../../commands/config/list.js';import{configGetDefinition}from'../../commands/config/get.js';function a42_0x336a(){const _0x2cb8e6=['20SRWjxr','2521089UArjgM','2100TmBViD','242946CUyHtR','447920WjALmi','10cPNCGn','536SsiEHP','1007680CKDGub','8118561gvXYeA','1nVpFpD','95322iaCnxT'];a42_0x336a=function(){return _0x2cb8e6;};return a42_0x336a();}import{configSetDefinition}from'../../commands/config/set.js';function a42_0x3c7c(_0x326f64,_0x19d9de){_0x326f64=_0x326f64-0xbe;const _0x336a29=a42_0x336a();let _0x3c7c2c=_0x336a29[_0x326f64];return _0x3c7c2c;}export const configDefinitions=[configListDefinition,configGetDefinition,configSetDefinition];
1
+ (function(_0x364418,_0x47a1a7){const _0x86f5cd=a42_0x2f51,_0x2f7a24=_0x364418();while(!![]){try{const _0x2f043c=-parseInt(_0x86f5cd(0xd5))/0x1+-parseInt(_0x86f5cd(0xd4))/0x2*(parseInt(_0x86f5cd(0xd0))/0x3)+parseInt(_0x86f5cd(0xcf))/0x4*(parseInt(_0x86f5cd(0xd2))/0x5)+parseInt(_0x86f5cd(0xd8))/0x6*(parseInt(_0x86f5cd(0xd6))/0x7)+-parseInt(_0x86f5cd(0xd3))/0x8+-parseInt(_0x86f5cd(0xce))/0x9*(parseInt(_0x86f5cd(0xd1))/0xa)+parseInt(_0x86f5cd(0xd7))/0xb*(-parseInt(_0x86f5cd(0xcd))/0xc);if(_0x2f043c===_0x47a1a7)break;else _0x2f7a24['push'](_0x2f7a24['shift']());}catch(_0x309415){_0x2f7a24['push'](_0x2f7a24['shift']());}}}(a42_0xf72f,0x5b2f5));function a42_0x2f51(_0x100504,_0x2476f5){_0x100504=_0x100504-0xcd;const _0xf72f03=a42_0xf72f();let _0x2f517b=_0xf72f03[_0x100504];return _0x2f517b;}import{configListDefinition}from'../../commands/config/list.js';import{configGetDefinition}from'../../commands/config/get.js';import{configSetDefinition}from'../../commands/config/set.js';function a42_0xf72f(){const _0x59e45c=['4357XhQFfq','2976967mgnTEY','11SpjMON','6WpewFg','1263636CMgkyf','160929sYFPbB','5956kppNNW','285333tpyeMG','90WzPdRr','1945eJsydB','1361584zoOaCs','4kzCFmX'];a42_0xf72f=function(){return _0x59e45c;};return a42_0xf72f();}export const configDefinitions=[configListDefinition,configGetDefinition,configSetDefinition];
@@ -1 +1 @@
1
- const a43_0x1e6b6e=a43_0x5e53;(function(_0x28a266,_0x5426e6){const _0x4cdf03=a43_0x5e53,_0x584a07=_0x28a266();while(!![]){try{const _0x15d8d1=-parseInt(_0x4cdf03(0x158))/0x1+-parseInt(_0x4cdf03(0x153))/0x2+parseInt(_0x4cdf03(0x151))/0x3*(-parseInt(_0x4cdf03(0x15d))/0x4)+parseInt(_0x4cdf03(0x159))/0x5+parseInt(_0x4cdf03(0x15b))/0x6*(-parseInt(_0x4cdf03(0x15e))/0x7)+-parseInt(_0x4cdf03(0x15c))/0x8*(-parseInt(_0x4cdf03(0x157))/0x9)+parseInt(_0x4cdf03(0x156))/0xa;if(_0x15d8d1===_0x5426e6)break;else _0x584a07['push'](_0x584a07['shift']());}catch(_0x379726){_0x584a07['push'](_0x584a07['shift']());}}}(a43_0x4215,0x9684a));import{readScopedConfig}from'../../commands/config/shared.js';function a43_0x5e53(_0x5d6248,_0xb08f98){_0x5d6248=_0x5d6248-0x150;const _0x42157e=a43_0x4215();let _0x5e53c1=_0x42157e[_0x5d6248];return _0x5e53c1;}import{readConfig}from'../../utils/config.js';async function execute(_0x222f0d){const _0x214978=a43_0x5e53,_0x68d8a0=_0x222f0d[_0x214978(0x150)](_0x214978(0x155))?readScopedConfig('global'):readConfig();return{'ok':!![],'data':_0x68d8a0};}function a43_0x4215(){const _0x46f751=['9pcwSSx','1228345lWuFXa','5611065DBjNsT','read','25002mtBlkp','5792600XxmZJP','274280fhAvxo','623rJMTbE','Show\x20global\x20config\x20only\x20(~/.rabetbase.json)','bool','33YNTtZQ','List\x20all\x20config\x20values','1581928OnnVST','boolean','global','19146760SnOjFr'];a43_0x4215=function(){return _0x46f751;};return a43_0x4215();}export const configListDefinition={'service':'config','command':'list','description':a43_0x1e6b6e(0x152),'risk':a43_0x1e6b6e(0x15a),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a43_0x1e6b6e(0x155),'type':a43_0x1e6b6e(0x154),'description':a43_0x1e6b6e(0x15f),'default':![]}],'execute':execute};
1
+ const a43_0x2eaee7=a43_0x490f;(function(_0x1c68a5,_0x3e6054){const _0x55ef87=a43_0x490f,_0x32d7e8=_0x1c68a5();while(!![]){try{const _0x4fd7f8=-parseInt(_0x55ef87(0x19c))/0x1+parseInt(_0x55ef87(0x198))/0x2+-parseInt(_0x55ef87(0x196))/0x3+-parseInt(_0x55ef87(0x195))/0x4*(parseInt(_0x55ef87(0x19a))/0x5)+parseInt(_0x55ef87(0x1a0))/0x6*(parseInt(_0x55ef87(0x191))/0x7)+parseInt(_0x55ef87(0x19b))/0x8+parseInt(_0x55ef87(0x192))/0x9*(-parseInt(_0x55ef87(0x19e))/0xa);if(_0x4fd7f8===_0x3e6054)break;else _0x32d7e8['push'](_0x32d7e8['shift']());}catch(_0x18c02b){_0x32d7e8['push'](_0x32d7e8['shift']());}}}(a43_0x4f04,0xad4c9));import{readScopedConfig}from'../../commands/config/shared.js';function a43_0x490f(_0xae5926,_0x50155e){_0xae5926=_0xae5926-0x191;const _0x4f0486=a43_0x4f04();let _0x490f94=_0x4f0486[_0xae5926];return _0x490f94;}import{readConfig}from'../../utils/config.js';async function execute(_0x31c964){const _0x56e4b2=a43_0x490f,_0x5a4047=_0x31c964[_0x56e4b2(0x197)](_0x56e4b2(0x19d))?readScopedConfig(_0x56e4b2(0x19d)):readConfig();return{'ok':!![],'data':_0x5a4047};}export const configListDefinition={'service':a43_0x2eaee7(0x199),'command':a43_0x2eaee7(0x193),'description':a43_0x2eaee7(0x19f),'risk':'read','requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a43_0x2eaee7(0x19d),'type':'boolean','description':a43_0x2eaee7(0x194),'default':![]}],'execute':execute};function a43_0x4f04(){const _0x261ebc=['532130XEdqqS','List\x20all\x20config\x20values','151908hBkxGp','259HlOrdH','261AQFPLZ','list','Show\x20global\x20config\x20only\x20(~/.rabetbase.json)','12nBjSKY','69462EmwCcr','bool','1979284nWKfaP','config','498795qfdLtI','9251056YKuYTh','507349srLBvg','global'];a43_0x4f04=function(){return _0x261ebc;};return a43_0x4f04();}
@@ -1 +1 @@
1
- const a44_0xd10609=a44_0x5071;(function(_0x2cbf10,_0x34472e){const _0x9c448b=a44_0x5071,_0x388b56=_0x2cbf10();while(!![]){try{const _0x2509dc=parseInt(_0x9c448b(0x13d))/0x1*(-parseInt(_0x9c448b(0x150))/0x2)+-parseInt(_0x9c448b(0x158))/0x3+-parseInt(_0x9c448b(0x162))/0x4*(parseInt(_0x9c448b(0x16c))/0x5)+parseInt(_0x9c448b(0x15e))/0x6+-parseInt(_0x9c448b(0x157))/0x7+parseInt(_0x9c448b(0x13e))/0x8*(-parseInt(_0x9c448b(0x166))/0x9)+parseInt(_0x9c448b(0x14c))/0xa;if(_0x2509dc===_0x34472e)break;else _0x388b56['push'](_0x388b56['shift']());}catch(_0x10d060){_0x388b56['push'](_0x388b56['shift']());}}}(a44_0x308c,0x886d7));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(_0x55a756){const _0x3cfdfc=a44_0x5071,_0x3f5615=_0x55a756[_0x3cfdfc(0x142)](_0x3cfdfc(0x152)),_0x279797=_0x55a756['str'](_0x3cfdfc(0x15f));if(!_0x3f5615)throw CliErrors[_0x3cfdfc(0x165)](_0x3cfdfc(0x15c),_0x3cfdfc(0x156)+CLI_BIN_NAME+_0x3cfdfc(0x147));if(_0x279797===undefined||_0x279797==='')throw CliErrors[_0x3cfdfc(0x165)](_0x3cfdfc(0x159),_0x3cfdfc(0x156)+CLI_BIN_NAME+_0x3cfdfc(0x147));if(_0x279797[_0x3cfdfc(0x143)]>0x1f4)throw CliErrors['validation'](_0x3cfdfc(0x13f));if(!isTopLevelConfigKey(_0x3f5615))throw CliErrors[_0x3cfdfc(0x165)](_0x3cfdfc(0x14f)+_0x3f5615+_0x3cfdfc(0x140),'Settable\x20top-level\x20keys:\x20'+getTopLevelConfigKeySummary());if(_0x3f5615===_0x3cfdfc(0x141))throw CliErrors[_0x3cfdfc(0x165)](_0x3cfdfc(0x154));if(CONFIG_ENUM_VALUES[_0x3f5615]&&!CONFIG_ENUM_VALUES[_0x3f5615][_0x3cfdfc(0x168)](_0x279797))throw CliErrors['validation'](_0x3cfdfc(0x169)+_0x3f5615+_0x3cfdfc(0x15d)+CONFIG_ENUM_VALUES[_0x3f5615][_0x3cfdfc(0x15b)](',\x20'));if(_0x3f5615===_0x3cfdfc(0x155)&&!normalizeLocale(_0x279797))throw CliErrors[_0x3cfdfc(0x165)](_0x3cfdfc(0x151),_0x3cfdfc(0x146));const _0x565dd9={'global':_0x55a756[_0x3cfdfc(0x16d)](_0x3cfdfc(0x160))},_0x4ed66e=resolveWriteScope(_0x565dd9),_0x517c08=readScopedConfig(_0x4ed66e);let _0x17df7e=_0x3f5615,_0x59a3d6=_0x279797;_0x3f5615===_0x3cfdfc(0x144)&&(_0x17df7e=_0x3cfdfc(0x16b),delete _0x517c08[_0x3cfdfc(0x144)]);_0x3f5615===_0x3cfdfc(0x155)&&(_0x59a3d6=normalizeLocale(_0x279797));if(_0x3f5615===_0x3cfdfc(0x161)){_0x59a3d6=normalizeEnv(_0x279797);if(!isProduction(_0x59a3d6)&&!isDaily(_0x59a3d6))throw CliErrors[_0x3cfdfc(0x165)](_0x3cfdfc(0x14a),'Legacy\x20alias\x20\x22online\x22\x20is\x20accepted\x20and\x20stored\x20as\x20production.');}if(_0x3f5615==='appcode'){const _0x37d8e1=_0x517c08['apps']&&typeof _0x517c08[_0x3cfdfc(0x149)]===_0x3cfdfc(0x14e)?Object[_0x3cfdfc(0x13c)](_0x517c08[_0x3cfdfc(0x149)]):[];if(_0x37d8e1[_0x3cfdfc(0x143)]>0x0)throw CliErrors['validation'](_0x3cfdfc(0x164),'Use\x20`'+CLI_BIN_NAME+_0x3cfdfc(0x14d)+_0x59a3d6+'`,\x20`'+CLI_BIN_NAME+_0x3cfdfc(0x163));const _0x3c7df2=buildCanonicalProjectConfig({..._0x517c08},{'appCodes':[_0x59a3d6],'env':typeof _0x517c08[_0x3cfdfc(0x161)]===_0x3cfdfc(0x16e)?_0x517c08[_0x3cfdfc(0x161)]:undefined});writeScopedConfig(_0x3c7df2,_0x4ed66e);const _0x5deb06=_0x4ed66e===_0x3cfdfc(0x160)?'Global':_0x3cfdfc(0x153);return{'ok':!![],'message':'✓\x20'+_0x5deb06+_0x3cfdfc(0x148)+_0x59a3d6+_0x3cfdfc(0x167)};}_0x517c08[_0x17df7e]=_0x59a3d6,writeScopedConfig(_0x517c08,_0x4ed66e);const _0x57d64d=_0x4ed66e===_0x3cfdfc(0x160)?_0x3cfdfc(0x145):'Project';return{'ok':!![],'message':'✓\x20'+_0x57d64d+'\x20'+_0x17df7e+_0x3cfdfc(0x15a)+_0x59a3d6};}export const configSetDefinition={'service':a44_0xd10609(0x170),'command':a44_0xd10609(0x14b),'description':'Set\x20a\x20config\x20value','risk':a44_0xd10609(0x172),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':'key','type':a44_0xd10609(0x16e),'description':getConfigCommandKeyDescription(),'required':!![]},{'name':a44_0xd10609(0x15f),'type':'string','description':a44_0xd10609(0x16f),'required':!![]},{'name':a44_0xd10609(0x160),'type':a44_0xd10609(0x16a),'description':a44_0xd10609(0x171),'default':![]}],'execute':execute};function a44_0x5071(_0x5a4a63,_0x5d5079){_0x5a4a63=_0x5a4a63-0x13c;const _0x308c5e=a44_0x308c();let _0x507179=_0x308c5e[_0x5a4a63];return _0x507179;}function a44_0x308c(){const _0x46bb0f=['\x20config\x20set\x20--key\x20<key>\x20--value\x20<value>','\x20appcode\x20set\x20to:\x20','apps','Invalid\x20value\x20for\x20env.\x20Allowed:\x20production,\x20daily.','set','36058240lKBixE','\x20app\x20add\x20<name>\x20--appcode\x20','object','Top-level\x20key\x20\x22','6uiLOcl','Invalid\x20locale\x20value.','key','Project','\x22riskLevel\x22\x20cannot\x20be\x20changed\x20via\x20the\x20CLI.','locale','Usage:\x20','7235011qOISaN','2897346NksGgz','Missing\x20value.','\x20set\x20to:\x20','join','Missing\x20key.','\x22.\x20Allowed:\x20','2040456FSIEca','value','global','env','12iCtnhc','\x20app\x20use\x20<name>`,\x20or\x20pass\x20`--appcode`\x20on\x20the\x20command.','Cannot\x20set\x20top-level\x20\x22appcode\x22\x20when\x20multi-app\x20config\x20already\x20exists.','validation','560484lOdXLi','\x20(stored\x20as\x20apps\x20+\x20defaultApp)','includes','Invalid\x20value\x20for\x20\x22','boolean','appcode','1164925aHxhIs','bool','string','Config\x20value','config','Write\x20to\x20global\x20config\x20(~/.rabetbase.json)','write','keys','1249FqPJQr','88MfnGrQ','Config\x20value\x20is\x20invalid\x20or\x20too\x20long.','\x22\x20is\x20not\x20settable.','riskLevel','str','length','app','Global','Supported:\x20zh,\x20en,\x20zh-CN,\x20en-US'];a44_0x308c=function(){return _0x46bb0f;};return a44_0x308c();}
1
+ const a44_0x5531b6=a44_0x10cc;(function(_0x21af7f,_0x5cc42d){const _0x2664b1=a44_0x10cc,_0x835034=_0x21af7f();while(!![]){try{const _0x14d2ac=parseInt(_0x2664b1(0x1b4))/0x1+parseInt(_0x2664b1(0x1b2))/0x2*(parseInt(_0x2664b1(0x1b9))/0x3)+parseInt(_0x2664b1(0x1a7))/0x4+parseInt(_0x2664b1(0x1ca))/0x5+parseInt(_0x2664b1(0x1d3))/0x6*(parseInt(_0x2664b1(0x1c0))/0x7)+parseInt(_0x2664b1(0x1bd))/0x8+-parseInt(_0x2664b1(0x1c6))/0x9;if(_0x14d2ac===_0x5cc42d)break;else _0x835034['push'](_0x835034['shift']());}catch(_0x41bf8c){_0x835034['push'](_0x835034['shift']());}}}(a44_0x3f0b,0x56637));function a44_0x10cc(_0x146d64,_0x5693de){_0x146d64=_0x146d64-0x1a1;const _0x3f0ba8=a44_0x3f0b();let _0x10cc91=_0x3f0ba8[_0x146d64];return _0x10cc91;}import{CliErrors}from'../../errors.js';function a44_0x3f0b(){const _0x4d8ac2=['Invalid\x20value\x20for\x20\x22','45756TqLNPh','config','value','Usage:\x20','join','riskLevel','Global','Write\x20to\x20global\x20config\x20(~/.rabetbase.json)','1698660bUjCAG','Top-level\x20key\x20\x22','Config\x20value','appcode','bool','\x20app\x20use\x20<name>`,\x20or\x20pass\x20`--appcode`\x20on\x20the\x20command.','set','Config\x20value\x20is\x20invalid\x20or\x20too\x20long.','\x20appcode\x20set\x20to:\x20','keys','`,\x20`','2MKEYCs','string','534353nbQmMj','\x20set\x20to:\x20','\x22riskLevel\x22\x20cannot\x20be\x20changed\x20via\x20the\x20CLI.','apps','Missing\x20value.','1821819zjdscL','length','\x20(stored\x20as\x20apps\x20+\x20defaultApp)','env','3418872thUHci','object','Use\x20`','385QLCtoy','Invalid\x20locale\x20value.','Project','Set\x20a\x20config\x20value','Invalid\x20value\x20for\x20env.\x20Allowed:\x20production,\x20daily.','global','22015809yXkhau','write','str','app','1934840KkMmCK','validation','Supported:\x20zh,\x20en,\x20zh-CN,\x20en-US','Missing\x20key.','\x20config\x20set\x20--key\x20<key>\x20--value\x20<value>','boolean','\x20app\x20add\x20<name>\x20--appcode\x20','locale'];a44_0x3f0b=function(){return _0x4d8ac2;};return a44_0x3f0b();}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(_0x5e5eb2){const _0x1b7bbf=a44_0x10cc,_0x21350c=_0x5e5eb2[_0x1b7bbf(0x1c8)]('key'),_0x2fa7cc=_0x5e5eb2[_0x1b7bbf(0x1c8)](_0x1b7bbf(0x1a1));if(!_0x21350c)throw CliErrors[_0x1b7bbf(0x1cb)](_0x1b7bbf(0x1cd),'Usage:\x20'+CLI_BIN_NAME+_0x1b7bbf(0x1ce));if(_0x2fa7cc===undefined||_0x2fa7cc==='')throw CliErrors[_0x1b7bbf(0x1cb)](_0x1b7bbf(0x1b8),_0x1b7bbf(0x1a2)+CLI_BIN_NAME+'\x20config\x20set\x20--key\x20<key>\x20--value\x20<value>');if(_0x2fa7cc[_0x1b7bbf(0x1ba)]>0x1f4)throw CliErrors[_0x1b7bbf(0x1cb)](_0x1b7bbf(0x1ae));if(!isTopLevelConfigKey(_0x21350c))throw CliErrors[_0x1b7bbf(0x1cb)](_0x1b7bbf(0x1a8)+_0x21350c+'\x22\x20is\x20not\x20settable.','Settable\x20top-level\x20keys:\x20'+getTopLevelConfigKeySummary());if(_0x21350c===_0x1b7bbf(0x1a4))throw CliErrors['validation'](_0x1b7bbf(0x1b6));if(CONFIG_ENUM_VALUES[_0x21350c]&&!CONFIG_ENUM_VALUES[_0x21350c]['includes'](_0x2fa7cc))throw CliErrors[_0x1b7bbf(0x1cb)](_0x1b7bbf(0x1d2)+_0x21350c+'\x22.\x20Allowed:\x20'+CONFIG_ENUM_VALUES[_0x21350c][_0x1b7bbf(0x1a3)](',\x20'));if(_0x21350c==='locale'&&!normalizeLocale(_0x2fa7cc))throw CliErrors[_0x1b7bbf(0x1cb)](_0x1b7bbf(0x1c1),_0x1b7bbf(0x1cc));const _0x39b1ca={'global':_0x5e5eb2[_0x1b7bbf(0x1ab)](_0x1b7bbf(0x1c5))},_0x15ecef=resolveWriteScope(_0x39b1ca),_0x3a70d9=readScopedConfig(_0x15ecef);let _0xf0f281=_0x21350c,_0x512cdd=_0x2fa7cc;_0x21350c===_0x1b7bbf(0x1c9)&&(_0xf0f281=_0x1b7bbf(0x1aa),delete _0x3a70d9[_0x1b7bbf(0x1c9)]);_0x21350c===_0x1b7bbf(0x1d1)&&(_0x512cdd=normalizeLocale(_0x2fa7cc));if(_0x21350c===_0x1b7bbf(0x1bc)){_0x512cdd=normalizeEnv(_0x2fa7cc);if(!isProduction(_0x512cdd)&&!isDaily(_0x512cdd))throw CliErrors[_0x1b7bbf(0x1cb)](_0x1b7bbf(0x1c4),'Legacy\x20alias\x20\x22online\x22\x20is\x20accepted\x20and\x20stored\x20as\x20production.');}if(_0x21350c===_0x1b7bbf(0x1aa)){const _0x459e3a=_0x3a70d9[_0x1b7bbf(0x1b7)]&&typeof _0x3a70d9[_0x1b7bbf(0x1b7)]===_0x1b7bbf(0x1be)?Object[_0x1b7bbf(0x1b0)](_0x3a70d9['apps']):[];if(_0x459e3a[_0x1b7bbf(0x1ba)]>0x0)throw CliErrors[_0x1b7bbf(0x1cb)]('Cannot\x20set\x20top-level\x20\x22appcode\x22\x20when\x20multi-app\x20config\x20already\x20exists.',_0x1b7bbf(0x1bf)+CLI_BIN_NAME+_0x1b7bbf(0x1d0)+_0x512cdd+_0x1b7bbf(0x1b1)+CLI_BIN_NAME+_0x1b7bbf(0x1ac));const _0x23b7d8=buildCanonicalProjectConfig({..._0x3a70d9},{'appCodes':[_0x512cdd],'env':typeof _0x3a70d9[_0x1b7bbf(0x1bc)]===_0x1b7bbf(0x1b3)?_0x3a70d9[_0x1b7bbf(0x1bc)]:undefined});writeScopedConfig(_0x23b7d8,_0x15ecef);const _0x4e4aa3=_0x15ecef==='global'?_0x1b7bbf(0x1a5):'Project';return{'ok':!![],'message':'✓\x20'+_0x4e4aa3+_0x1b7bbf(0x1af)+_0x512cdd+_0x1b7bbf(0x1bb)};}_0x3a70d9[_0xf0f281]=_0x512cdd,writeScopedConfig(_0x3a70d9,_0x15ecef);const _0x1d31cc=_0x15ecef===_0x1b7bbf(0x1c5)?'Global':_0x1b7bbf(0x1c2);return{'ok':!![],'message':'✓\x20'+_0x1d31cc+'\x20'+_0xf0f281+_0x1b7bbf(0x1b5)+_0x512cdd};}export const configSetDefinition={'service':a44_0x5531b6(0x1d4),'command':a44_0x5531b6(0x1ad),'description':a44_0x5531b6(0x1c3),'risk':a44_0x5531b6(0x1c7),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':'key','type':a44_0x5531b6(0x1b3),'description':getConfigCommandKeyDescription(),'required':!![]},{'name':a44_0x5531b6(0x1a1),'type':'string','description':a44_0x5531b6(0x1a9),'required':!![]},{'name':a44_0x5531b6(0x1c5),'type':a44_0x5531b6(0x1cf),'description':a44_0x5531b6(0x1a6),'default':![]}],'execute':execute};
@@ -1 +1 @@
1
- (function(_0x9d30e4,_0x1fc967){var _0x527512=a45_0x4a96,_0x1df081=_0x9d30e4();while(!![]){try{var _0x2daabd=parseInt(_0x527512(0xaa))/0x1*(parseInt(_0x527512(0xae))/0x2)+-parseInt(_0x527512(0xb3))/0x3+parseInt(_0x527512(0xac))/0x4+-parseInt(_0x527512(0xab))/0x5+-parseInt(_0x527512(0xaf))/0x6+parseInt(_0x527512(0xb2))/0x7+parseInt(_0x527512(0xb1))/0x8;if(_0x2daabd===_0x1fc967)break;else _0x1df081['push'](_0x1df081['shift']());}catch(_0x11aa07){_0x1df081['push'](_0x1df081['shift']());}}}(a45_0x438d,0x86ac5));import{CLI_BIN_NAME}from'../../constant/cli.js';function a45_0x4a96(_0x518e65,_0x223494){_0x518e65=_0x518e65-0xa9;var _0x438d26=a45_0x438d();var _0x4a966e=_0x438d26[_0x518e65];return _0x4a966e;}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(_0x4ed3de){var _0x4264cd=a45_0x4a96;if(_0x4ed3de['global'])return _0x4264cd(0xa9);if(!isInProject())throw CliErrors[_0x4264cd(0xb0)]('Not\x20inside\x20a\x20project\x20(no\x20.rabetbase.json\x20found).',_0x4264cd(0xad)+CLI_BIN_NAME+'\x20init`\x20first.');return'project';}export function readScopedConfig(_0x475b4a){return readConfigFile(resolveWriteConfigPath(_0x475b4a));}export function writeScopedConfig(_0x3c7784,_0x169d0b){writeConfigFile(resolveWriteConfigPath(_0x169d0b),_0x3c7784);}function a45_0x438d(){var _0x1ece60=['Add\x20--global\x20to\x20write\x20to\x20~/.rabetbase.json,\x20or\x20run\x20`','132wtdFNO','5943810KayChS','validation','10998168qcGLWv','2391368XnaEeH','2556348nDXRQg','global','6052luXkVI','316225LkOPCq','1367160WaNUoS'];a45_0x438d=function(){return _0x1ece60;};return a45_0x438d();}
1
+ function a45_0x1f10(_0x1ea89e,_0x2912a1){_0x1ea89e=_0x1ea89e-0x143;var _0x394c56=a45_0x394c();var _0x1f109a=_0x394c56[_0x1ea89e];return _0x1f109a;}(function(_0xffbff1,_0x2470f4){var _0x3f589c=a45_0x1f10,_0x1c9e17=_0xffbff1();while(!![]){try{var _0x279e6c=parseInt(_0x3f589c(0x14d))/0x1+parseInt(_0x3f589c(0x14f))/0x2+parseInt(_0x3f589c(0x148))/0x3+parseInt(_0x3f589c(0x146))/0x4+-parseInt(_0x3f589c(0x14c))/0x5+-parseInt(_0x3f589c(0x14e))/0x6+parseInt(_0x3f589c(0x144))/0x7*(-parseInt(_0x3f589c(0x147))/0x8);if(_0x279e6c===_0x2470f4)break;else _0x1c9e17['push'](_0x1c9e17['shift']());}catch(_0x1ae79d){_0x1c9e17['push'](_0x1c9e17['shift']());}}}(a45_0x394c,0xa84ee));function a45_0x394c(){var _0x18dfea=['\x20init`\x20first.','70JOzVDz','validation','4113168FwUype','178528DskMjJ','2770518iGJAta','Add\x20--global\x20to\x20write\x20to\x20~/.rabetbase.json,\x20or\x20run\x20`','global','project','5522610atgpNS','775456FWwfNO','6839826Sbtwgo','859578dAHWJh'];a45_0x394c=function(){return _0x18dfea;};return a45_0x394c();}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(_0x4825b4){var _0x321b90=a45_0x1f10;if(_0x4825b4[_0x321b90(0x14a)])return _0x321b90(0x14a);if(!isInProject())throw CliErrors[_0x321b90(0x145)]('Not\x20inside\x20a\x20project\x20(no\x20.rabetbase.json\x20found).',_0x321b90(0x149)+CLI_BIN_NAME+_0x321b90(0x143));return _0x321b90(0x14b);}export function readScopedConfig(_0x46622b){return readConfigFile(resolveWriteConfigPath(_0x46622b));}export function writeScopedConfig(_0x3b7248,_0x982909){writeConfigFile(resolveWriteConfigPath(_0x982909),_0x3b7248);}
@@ -1 +1 @@
1
- function a46_0x187a(_0x152d85,_0x58645b){_0x152d85=_0x152d85-0x19f;const _0x40103f=a46_0x4010();let _0x187ac6=_0x40103f[_0x152d85];return _0x187ac6;}const a46_0x2e57f6=a46_0x187a;(function(_0x33f63b,_0x241077){const _0x377c38=a46_0x187a,_0x5e3af4=_0x33f63b();while(!![]){try{const _0x45d03c=parseInt(_0x377c38(0x1a4))/0x1*(-parseInt(_0x377c38(0x1ae))/0x2)+-parseInt(_0x377c38(0x1a7))/0x3*(-parseInt(_0x377c38(0x1b2))/0x4)+-parseInt(_0x377c38(0x1a9))/0x5*(parseInt(_0x377c38(0x1a0))/0x6)+-parseInt(_0x377c38(0x19f))/0x7*(-parseInt(_0x377c38(0x1b1))/0x8)+-parseInt(_0x377c38(0x1a6))/0x9*(-parseInt(_0x377c38(0x1a2))/0xa)+parseInt(_0x377c38(0x1af))/0xb*(parseInt(_0x377c38(0x1aa))/0xc)+parseInt(_0x377c38(0x1a5))/0xd*(-parseInt(_0x377c38(0x1ad))/0xe);if(_0x45d03c===_0x241077)break;else _0x5e3af4['push'](_0x5e3af4['shift']());}catch(_0x3e1acf){_0x5e3af4['push'](_0x5e3af4['shift']());}}}(a46_0x4010,0xa6672));import{buildDataCommand}from'../../commands/data/shared.js';export const dataFilter=buildDataCommand({'command':'filter','operation':'filter','description':a46_0x2e57f6(0x1b3),'paramsRequired':![],'paramsHint':a46_0x2e57f6(0x1b0),'helpExtra':[a46_0x2e57f6(0x1ac),a46_0x2e57f6(0x1a8),'\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_0x2e57f6(0x1a3),'\x20\x20\x20\x20currentPage\x20\x20\x20Number\x20\x20\x20Page\x20number\x20(starts\x20from\x201)',a46_0x2e57f6(0x1a1)][a46_0x2e57f6(0x1ab)]('\x0a')});function a46_0x4010(){const _0x5bfcd4=['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','8wVBhbs','4WHPZZj','Filter\x20dataset\x20records\x20with\x20query\x20conditions','8141791oTNYRs','426EFpscq','\x20\x20\x20\x20pageSize\x20\x20\x20\x20\x20\x20Number\x20\x20\x20Records\x20per\x20page','2045990REjdTZ','\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}]','1eGWRfA','91507eJXuAI','27SebjHl','682323dyJjlV','\x20\x20\x20\x20where\x20\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Query\x20conditions','24785EQyIvx','4584Qibycd','join','\x20\x20JSON\x20BODY\x20FIELDS\x20(pass\x20inside\x20--params)','3962vrjuQy','538354TVwLxL','37158VIbxAj'];a46_0x4010=function(){return _0x5bfcd4;};return a46_0x4010();}
1
+ const a46_0x8c6a97=a46_0xd4fa;(function(_0x2dc841,_0x6e4ec3){const _0x1c1c04=a46_0xd4fa,_0x8f0cd=_0x2dc841();while(!![]){try{const _0x4ae71c=-parseInt(_0x1c1c04(0x17a))/0x1*(-parseInt(_0x1c1c04(0x179))/0x2)+parseInt(_0x1c1c04(0x17e))/0x3+parseInt(_0x1c1c04(0x17c))/0x4+parseInt(_0x1c1c04(0x17d))/0x5+parseInt(_0x1c1c04(0x176))/0x6+-parseInt(_0x1c1c04(0x178))/0x7*(parseInt(_0x1c1c04(0x185))/0x8)+-parseInt(_0x1c1c04(0x17b))/0x9;if(_0x4ae71c===_0x6e4ec3)break;else _0x8f0cd['push'](_0x8f0cd['shift']());}catch(_0x54369b){_0x8f0cd['push'](_0x8f0cd['shift']());}}}(a46_0x44cd,0x42834));import{buildDataCommand}from'../../commands/data/shared.js';export const dataFilter=buildDataCommand({'command':'filter','operation':a46_0x8c6a97(0x174),'description':a46_0x8c6a97(0x177),'paramsRequired':![],'paramsHint':a46_0x8c6a97(0x184),'helpExtra':[a46_0x8c6a97(0x175),'\x20\x20\x20\x20where\x20\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Query\x20conditions',a46_0x8c6a97(0x182),a46_0x8c6a97(0x180),a46_0x8c6a97(0x181),a46_0x8c6a97(0x17f)][a46_0x8c6a97(0x183)]('\x0a')});function a46_0xd4fa(_0x41ee70,_0x26511){_0x41ee70=_0x41ee70-0x174;const _0x44cdb0=a46_0x44cd();let _0xd4fac0=_0x44cdb0[_0x41ee70];return _0xd4fac0;}function a46_0x44cd(){const _0x4d2b8a=['6434550bgXjxq','347940fDHLQq','1276030CMxDCw','1171830nicwgD','\x20\x20\x20\x20pageSize\x20\x20\x20\x20\x20\x20Number\x20\x20\x20Records\x20per\x20page','\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\x20currentPage\x20\x20\x20Number\x20\x20\x20Page\x20number\x20(starts\x20from\x201)','\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]','join','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','24EDYYes','filter','\x20\x20JSON\x20BODY\x20FIELDS\x20(pass\x20inside\x20--params)','2974260EFSQbg','Filter\x20dataset\x20records\x20with\x20query\x20conditions','702331SOkmFo','59874aRQoHA','2EbkHrO'];a46_0x44cd=function(){return _0x4d2b8a;};return a46_0x44cd();}
@@ -1 +1 @@
1
- const a47_0x12f8db=a47_0x5130;(function(_0x422ff2,_0x381e8f){const _0x1f0a03=a47_0x5130,_0x11de91=_0x422ff2();while(!![]){try{const _0x30ab51=parseInt(_0x1f0a03(0x9b))/0x1*(parseInt(_0x1f0a03(0x9f))/0x2)+-parseInt(_0x1f0a03(0x9c))/0x3*(parseInt(_0x1f0a03(0xa2))/0x4)+parseInt(_0x1f0a03(0xa0))/0x5+-parseInt(_0x1f0a03(0x9a))/0x6*(parseInt(_0x1f0a03(0xa3))/0x7)+parseInt(_0x1f0a03(0xa5))/0x8+-parseInt(_0x1f0a03(0x9e))/0x9*(parseInt(_0x1f0a03(0xa4))/0xa)+parseInt(_0x1f0a03(0x99))/0xb;if(_0x30ab51===_0x381e8f)break;else _0x11de91['push'](_0x11de91['shift']());}catch(_0x532180){_0x11de91['push'](_0x11de91['shift']());}}}(a47_0x1ff4,0x29817));import{buildDataCommand}from'../../commands/data/shared.js';export const dataGetOne=buildDataCommand({'command':a47_0x12f8db(0xa6),'operation':a47_0x12f8db(0xa6),'description':a47_0x12f8db(0xa1),'paramsRequired':!![],'paramsHint':a47_0x12f8db(0x9d)});function a47_0x5130(_0x2fc1b8,_0x1f2123){_0x2fc1b8=_0x2fc1b8-0x99;const _0x1ff4d7=a47_0x1ff4();let _0x513048=_0x1ff4d7[_0x2fc1b8];return _0x513048;}function a47_0x1ff4(){const _0x343769=['getOne','129063nUXZGR','5682YDWOiw','5okOLyJ','3OAtFkW','JSON\x20with\x20record\x20id.\x20Example:\x20\x27{\x22id\x22:123}\x27','2500434KggOtB','51670seyTza','1506515eWbcQM','Get\x20a\x20single\x20record\x20by\x20ID','781796GUOQlZ','217VfzGZD','10SdFKbR','1843424FvDlVE'];a47_0x1ff4=function(){return _0x343769;};return a47_0x1ff4();}
1
+ function a47_0x4bc1(){const _0x51149c=['6yMnHmT','254vhDSfT','1152473RrCbsv','3281179pxgLpZ','1699432FEnpCg','61655aSkine','24qcthYu','getOne','5937wQwouV','50lsmMUs','156393wfOJEU','JSON\x20with\x20record\x20id.\x20Example:\x20\x27{\x22id\x22:123}\x27','2850635niXaPC','Get\x20a\x20single\x20record\x20by\x20ID'];a47_0x4bc1=function(){return _0x51149c;};return a47_0x4bc1();}const a47_0x59a336=a47_0x1d41;function a47_0x1d41(_0x512a86,_0x300a81){_0x512a86=_0x512a86-0x6d;const _0x4bc1ff=a47_0x4bc1();let _0x1d4150=_0x4bc1ff[_0x512a86];return _0x1d4150;}(function(_0x2e15ad,_0x11bf5b){const _0xcb4357=a47_0x1d41,_0x508d81=_0x2e15ad();while(!![]){try{const _0x31e8e9=-parseInt(_0xcb4357(0x6e))/0x1+-parseInt(_0xcb4357(0x78))/0x2*(-parseInt(_0xcb4357(0x71))/0x3)+parseInt(_0xcb4357(0x6d))/0x4+-parseInt(_0xcb4357(0x75))/0x5*(-parseInt(_0xcb4357(0x77))/0x6)+parseInt(_0xcb4357(0x79))/0x7*(-parseInt(_0xcb4357(0x6f))/0x8)+parseInt(_0xcb4357(0x73))/0x9*(-parseInt(_0xcb4357(0x72))/0xa)+-parseInt(_0xcb4357(0x7a))/0xb;if(_0x31e8e9===_0x11bf5b)break;else _0x508d81['push'](_0x508d81['shift']());}catch(_0x4b2035){_0x508d81['push'](_0x508d81['shift']());}}}(a47_0x4bc1,0x4a9a4));import{buildDataCommand}from'../../commands/data/shared.js';export const dataGetOne=buildDataCommand({'command':'getOne','operation':a47_0x59a336(0x70),'description':a47_0x59a336(0x76),'paramsRequired':!![],'paramsHint':a47_0x59a336(0x74)});
@@ -1 +1 @@
1
- function a48_0x5d84(_0x330d36,_0x3b9755){_0x330d36=_0x330d36-0x1d8;const _0x234025=a48_0x2340();let _0x5d8450=_0x234025[_0x330d36];return _0x5d8450;}(function(_0x1245b0,_0x25d49b){const _0x5721cc=a48_0x5d84,_0x1a254b=_0x1245b0();while(!![]){try{const _0x51aff3=-parseInt(_0x5721cc(0x1db))/0x1*(parseInt(_0x5721cc(0x1e2))/0x2)+-parseInt(_0x5721cc(0x1d8))/0x3*(-parseInt(_0x5721cc(0x1e3))/0x4)+parseInt(_0x5721cc(0x1e0))/0x5*(-parseInt(_0x5721cc(0x1da))/0x6)+-parseInt(_0x5721cc(0x1df))/0x7+-parseInt(_0x5721cc(0x1de))/0x8+-parseInt(_0x5721cc(0x1e1))/0x9*(-parseInt(_0x5721cc(0x1dc))/0xa)+-parseInt(_0x5721cc(0x1dd))/0xb*(-parseInt(_0x5721cc(0x1d9))/0xc);if(_0x51aff3===_0x25d49b)break;else _0x1a254b['push'](_0x1a254b['shift']());}catch(_0x5aec0d){_0x1a254b['push'](_0x1a254b['shift']());}}}(a48_0x2340,0x9d9e5));import{dataFilter}from'../../commands/data/filter.js';import{dataGetOne}from'../../commands/data/getOne.js';function a48_0x2340(){const _0x890143=['5494071QStpfQ','975272JRxgmB','8375605veJCiP','5674675kaDCDn','1071dSpIOz','18BQmjoG','46912YxSUwN','24zgOCEC','84cTdZAK','6IPEBdw','56099VtRkhP','1160YBPpXl'];a48_0x2340=function(){return _0x890143;};return a48_0x2340();}export const dataDefinitions=[dataFilter,dataGetOne];
1
+ function a48_0x10a4(_0x25fc76,_0x4123a5){_0x25fc76=_0x25fc76-0x153;const _0x1d600d=a48_0x1d60();let _0x10a438=_0x1d600d[_0x25fc76];return _0x10a438;}(function(_0x1c9282,_0x4eddbd){const _0x307c7b=a48_0x10a4,_0x2c2e99=_0x1c9282();while(!![]){try{const _0x50caa3=parseInt(_0x307c7b(0x15b))/0x1*(-parseInt(_0x307c7b(0x155))/0x2)+parseInt(_0x307c7b(0x158))/0x3+-parseInt(_0x307c7b(0x153))/0x4*(-parseInt(_0x307c7b(0x154))/0x5)+-parseInt(_0x307c7b(0x159))/0x6*(-parseInt(_0x307c7b(0x15c))/0x7)+parseInt(_0x307c7b(0x156))/0x8+parseInt(_0x307c7b(0x15a))/0x9*(parseInt(_0x307c7b(0x157))/0xa)+-parseInt(_0x307c7b(0x15d))/0xb;if(_0x50caa3===_0x4eddbd)break;else _0x2c2e99['push'](_0x2c2e99['shift']());}catch(_0x2287c3){_0x2c2e99['push'](_0x2c2e99['shift']());}}}(a48_0x1d60,0x9df9b));import{dataFilter}from'../../commands/data/filter.js';import{dataGetOne}from'../../commands/data/getOne.js';function a48_0x1d60(){const _0x4d6d8d=['1012015vqWZjm','7keTIOz','16166722UdnKFf','1683828IkRILu','5pfsDll','2Qmoyam','1959104rVAcgo','91530xPyVfw','6537DNwQIT','7680138ueCmmN','1161RJmgkk'];a48_0x1d60=function(){return _0x4d6d8d;};return a48_0x1d60();}export const dataDefinitions=[dataFilter,dataGetOne];
@@ -1 +1 @@
1
- (function(_0x58206a,_0x401637){const _0x39299d=a49_0x1268,_0x4d27c4=_0x58206a();while(!![]){try{const _0x5a4597=parseInt(_0x39299d(0x131))/0x1+-parseInt(_0x39299d(0x12b))/0x2+parseInt(_0x39299d(0x12d))/0x3+parseInt(_0x39299d(0x11b))/0x4+-parseInt(_0x39299d(0x123))/0x5*(parseInt(_0x39299d(0x11e))/0x6)+-parseInt(_0x39299d(0x121))/0x7+parseInt(_0x39299d(0x127))/0x8;if(_0x5a4597===_0x401637)break;else _0x4d27c4['push'](_0x4d27c4['shift']());}catch(_0xa186c7){_0x4d27c4['push'](_0x4d27c4['shift']());}}}(a49_0x2a0f,0xd5441));import{executeDatasetDataOperation}from'../../core/api-client.js';import{CODE_FLAG,APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{CliErrors}from'../../errors.js';function a49_0x2a0f(){const _0x3517ec=['1186425kCNyOg','description','string','data\x20','21974064eRtSmO','str','data','alias','2158762boKBsM','Example:\x20--params\x20\x27{\x22id\x22:123}\x27','108717bRBKms','operation','validation','\x20completed\x20in\x20','280061WcZEYA','now','paramsRequired','Provide\x20--params\x20\x27{\x22id\x22:123}\x27\x20for\x20data\x20getOne.','params','compress','Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon).\x20Resolves\x20to\x20dataset\x20code\x20automatically','4342876ycOtVH','command','appCode','30UZonHX','flagMissing','paramsHint','7066038ZBwSfi','code'];a49_0x2a0f=function(){return _0x3517ec;};return a49_0x2a0f();}function a49_0x1268(_0x3394d0,_0x823aff){_0x3394d0=_0x3394d0-0x115;const _0x2a0f89=a49_0x2a0f();let _0x1268fd=_0x2a0f89[_0x3394d0];return _0x1268fd;}import{parseJsonParams}from'../../utils/params.js';function assertGetOneId(_0x44e83c){const _0x26a898=a49_0x1268;if(!_0x44e83c)throw CliErrors['flagMissing'](_0x26a898(0x118),_0x26a898(0x117));const _0x307928=_0x44e83c['id'];if(_0x307928===undefined||_0x307928===null||_0x307928==='')throw CliErrors[_0x26a898(0x12f)]('data\x20getOne\x20requires\x20\x22id\x22\x20in\x20--params',_0x26a898(0x12c));}function parseCommandParams(_0x2df3ba){return parseJsonParams(_0x2df3ba)??{};}export function buildDataCommand(_0x225c71){const _0x4af1a9=a49_0x1268,_0x4deb40=_0x4af1a9(0x11a);return{'service':_0x4af1a9(0x129),'command':_0x225c71[_0x4af1a9(0x11c)],'description':_0x225c71[_0x4af1a9(0x124)],'risk':'read','defaultOutputFormat':_0x4af1a9(0x119),'helpExtra':_0x225c71['helpExtra'],'flags':[CODE_FLAG,APPCODE_FLAG_OPTIONAL,{'name':_0x4af1a9(0x12a),'type':_0x4af1a9(0x125),'description':_0x4deb40},{'name':'params','type':_0x4af1a9(0x125),'description':_0x225c71[_0x4af1a9(0x120)]}],async 'validate'(_0x1e2fb2){const _0x5644be=_0x4af1a9,_0x5a02a4=_0x1e2fb2[_0x5644be(0x128)](_0x5644be(0x118));if(_0x225c71[_0x5644be(0x116)]&&!_0x5a02a4)throw CliErrors[_0x5644be(0x11f)](_0x5644be(0x118),_0x225c71[_0x5644be(0x120)]);const _0x5eaa9e=parseJsonParams(_0x5a02a4);_0x225c71[_0x5644be(0x12e)]==='getOne'&&assertGetOneId(_0x5eaa9e);},async 'execute'(_0xfa935){const _0x49d473=_0x4af1a9,_0x4ef048=parseCommandParams(_0xfa935[_0x49d473(0x128)](_0x49d473(0x118))),_0x2c3aee=Date[_0x49d473(0x115)](),_0x2b6345=await executeDatasetDataOperation(_0xfa935[_0x49d473(0x11d)],_0xfa935['str'](_0x49d473(0x122)),_0x225c71[_0x49d473(0x12e)],_0x4ef048),_0x5adf31=Date[_0x49d473(0x115)]()-_0x2c3aee;return{'ok':!![],'data':{'result':_0x2b6345,'elapsed':_0x5adf31},'message':_0x49d473(0x126)+_0x225c71['command']+_0x49d473(0x130)+_0x5adf31+'ms'};}};}
1
+ function a49_0x3d15(_0xf50e82,_0x3c49dc){_0xf50e82=_0xf50e82-0x154;const _0x193210=a49_0x1932();let _0x3d1526=_0x193210[_0xf50e82];return _0x3d1526;}(function(_0x4f3f39,_0x29f407){const _0x74640b=a49_0x3d15,_0x4a2e98=_0x4f3f39();while(!![]){try{const _0x1e0925=parseInt(_0x74640b(0x157))/0x1+parseInt(_0x74640b(0x168))/0x2+parseInt(_0x74640b(0x15b))/0x3*(-parseInt(_0x74640b(0x169))/0x4)+-parseInt(_0x74640b(0x15f))/0x5+parseInt(_0x74640b(0x158))/0x6*(-parseInt(_0x74640b(0x16e))/0x7)+parseInt(_0x74640b(0x156))/0x8+parseInt(_0x74640b(0x160))/0x9*(parseInt(_0x74640b(0x166))/0xa);if(_0x1e0925===_0x29f407)break;else _0x4a2e98['push'](_0x4a2e98['shift']());}catch(_0x41e1d8){_0x4a2e98['push'](_0x4a2e98['shift']());}}}(a49_0x1932,0x3752a));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(_0x394526){const _0x529ed5=a49_0x3d15;if(!_0x394526)throw CliErrors[_0x529ed5(0x162)](_0x529ed5(0x16f),_0x529ed5(0x16a));const _0x260d90=_0x394526['id'];if(_0x260d90===undefined||_0x260d90===null||_0x260d90==='')throw CliErrors[_0x529ed5(0x15c)](_0x529ed5(0x16c),'Example:\x20--params\x20\x27{\x22id\x22:123}\x27');}function parseCommandParams(_0x449ea1){return parseJsonParams(_0x449ea1)??{};}function a49_0x1932(){const _0x2fb3a2=['166313QzMrZs','params','description','now','2979480ESunkI','230198YMcvhE','42Yeteas','compress','helpExtra','3RGkkjx','validation','str','code','147260LIMZwF','33444RMDSfS','read','flagMissing','getOne','string','alias','10jujosy','appCode','186402AohEhw','1108732QyXzBc','Provide\x20--params\x20\x27{\x22id\x22:123}\x27\x20for\x20data\x20getOne.','operation','data\x20getOne\x20requires\x20\x22id\x22\x20in\x20--params','command'];a49_0x1932=function(){return _0x2fb3a2;};return a49_0x1932();}export function buildDataCommand(_0x37431b){const _0xc975e6=a49_0x3d15,_0x47d16c='Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon).\x20Resolves\x20to\x20dataset\x20code\x20automatically';return{'service':'data','command':_0x37431b[_0xc975e6(0x16d)],'description':_0x37431b[_0xc975e6(0x154)],'risk':_0xc975e6(0x161),'defaultOutputFormat':_0xc975e6(0x159),'helpExtra':_0x37431b[_0xc975e6(0x15a)],'flags':[CODE_FLAG,APPCODE_FLAG_OPTIONAL,{'name':_0xc975e6(0x165),'type':_0xc975e6(0x164),'description':_0x47d16c},{'name':_0xc975e6(0x16f),'type':'string','description':_0x37431b['paramsHint']}],async 'validate'(_0xd60534){const _0x2a04=_0xc975e6,_0x2841df=_0xd60534[_0x2a04(0x15d)]('params');if(_0x37431b['paramsRequired']&&!_0x2841df)throw CliErrors[_0x2a04(0x162)]('params',_0x37431b['paramsHint']);const _0x117ca5=parseJsonParams(_0x2841df);_0x37431b[_0x2a04(0x16b)]===_0x2a04(0x163)&&assertGetOneId(_0x117ca5);},async 'execute'(_0x22c9b3){const _0x858e39=_0xc975e6,_0x2f44ff=parseCommandParams(_0x22c9b3[_0x858e39(0x15d)](_0x858e39(0x16f))),_0x42fb08=Date[_0x858e39(0x155)](),_0x9e1fd2=await executeDatasetDataOperation(_0x22c9b3[_0x858e39(0x167)],_0x22c9b3[_0x858e39(0x15d)](_0x858e39(0x15e)),_0x37431b['operation'],_0x2f44ff),_0x5e8658=Date[_0x858e39(0x155)]()-_0x42fb08;return{'ok':!![],'data':{'result':_0x9e1fd2,'elapsed':_0x5e8658},'message':'data\x20'+_0x37431b[_0x858e39(0x16d)]+'\x20completed\x20in\x20'+_0x5e8658+'ms'};}};}
@@ -1 +1 @@
1
- const a50_0x26140f=a50_0x336f;function a50_0x369e(){const _0x95b329=['3356755ymdgoC','lovrabet\x20data\x20getOne\x20--code\x20<datasetCode>\x20--params\x20\x27{\x22id\x22:123}\x27\x20--format\x20compress','object','\x20是\x20','name','1325481nyBKgg','filter','modelCode','当前数据集\x20\x22','BFF\x20/\x20SQL\x20等研发态资产','dbtable','length','join','UNKNOWN','12LSLkGz','METADATA','5118848DcGvEF','dbtableConfig','769806vqtZyF','\x20类型,不适合作为\x20','getOne','如果只是查看运行态真实行数据,请切换到\x20lovrabet\x20CLI:','224ALUZqA','95178eBrNfI','10844nljxXe','原因:该类研发态资产需要\x20DB\x20table、dbId、tableName\x20与数据库连接上下文,并深度依赖\x20SQL\x20执行链路。','validation','1538972HQNSUd','dataset','Use\x20lovrabet\x20data\x20filter/getOne\x20for\x20real\x20runtime\x20records.','code','toUpperCase','tableName','datasetCode'];a50_0x369e=function(){return _0x95b329;};return a50_0x369e();}function a50_0x336f(_0x504815,_0x1130bf){_0x504815=_0x504815-0x12c;const _0x369e98=a50_0x369e();let _0x336ffa=_0x369e98[_0x504815];return _0x336ffa;}(function(_0xb1dc25,_0x23bd49){const _0x3f712f=a50_0x336f,_0x412a81=_0xb1dc25();while(!![]){try{const _0x1cfd89=-parseInt(_0x3f712f(0x13a))/0x1*(-parseInt(_0x3f712f(0x144))/0x2)+-parseInt(_0x3f712f(0x131))/0x3+parseInt(_0x3f712f(0x147))/0x4+-parseInt(_0x3f712f(0x12c))/0x5+parseInt(_0x3f712f(0x143))/0x6*(parseInt(_0x3f712f(0x142))/0x7)+parseInt(_0x3f712f(0x13c))/0x8+-parseInt(_0x3f712f(0x13e))/0x9;if(_0x1cfd89===_0x23bd49)break;else _0x412a81['push'](_0x412a81['shift']());}catch(_0x644a15){_0x412a81['push'](_0x412a81['shift']());}}}(a50_0x369e,0x614e7));import{CliErrors}from'../../errors.js';export const RUNTIME_DATA_ACCESS_COMMANDS={'cli':'lovrabet','filter':'lovrabet\x20data\x20filter\x20--code\x20<datasetCode>\x20--params\x20\x27<json>\x27\x20--format\x20compress','getOne':a50_0x26140f(0x12d)};export const RUNTIME_DATA_ACCESS_SUMMARY=a50_0x26140f(0x149);function valueToString(_0x4ff38f){return _0x4ff38f==null?'':String(_0x4ff38f)['trim']();}function getDatasetCode(_0x51ded7){const _0x57e9f8=a50_0x26140f;return valueToString(_0x51ded7[_0x57e9f8(0x14a)]??_0x51ded7[_0x57e9f8(0x133)]??_0x51ded7['dataset']?.[_0x57e9f8(0x14d)]);}function getDatasetName(_0x14dfca){const _0x505fb7=a50_0x26140f;return valueToString(_0x14dfca[_0x505fb7(0x130)]??_0x14dfca['dataset']?.['datasetName'])||'unknown';}function getDatasetSource(_0x7f9a26){const _0x199567=a50_0x26140f;return valueToString(_0x7f9a26['source']??_0x7f9a26[_0x199567(0x148)]?.['sourceType'])[_0x199567(0x14b)]();}function getDbtableConfig(_0x3ef0d1){const _0x390d83=a50_0x26140f,_0x4bccac=_0x3ef0d1[_0x390d83(0x13d)]??_0x3ef0d1[_0x390d83(0x136)];return _0x4bccac&&typeof _0x4bccac===_0x390d83(0x12e)?_0x4bccac:{};}export function isDbBackedDataset(_0x2bd559){const _0x74525=a50_0x26140f,_0x3d32d9=getDatasetSource(_0x2bd559);if(_0x3d32d9===_0x74525(0x13b))return![];const _0x361826=getDbtableConfig(_0x2bd559),_0x5deb20=_0x361826['dbId']??_0x361826['id'],_0x5b32bf=valueToString(_0x361826['tableName']??_0x2bd559['tableName']??_0x2bd559[_0x74525(0x148)]?.[_0x74525(0x14c)]);return _0x5deb20!==undefined&&_0x5deb20!==null&&_0x5b32bf[_0x74525(0x137)]>0x0;}export function filterDbBackedDatasets(_0x3a0da9){const _0x1719e9=a50_0x26140f;return _0x3a0da9[_0x1719e9(0x132)](_0x54cc24=>isDbBackedDataset(_0x54cc24));}export function buildDbTableUpgradeMessage(_0x35e47f,_0x3c732d=a50_0x26140f(0x135)){const _0x503eb2=a50_0x26140f,_0x5b1c92=getDatasetSource(_0x35e47f)||_0x503eb2(0x139),_0x5cad8c=getDatasetName(_0x35e47f),_0x4c47bc=getDatasetCode(_0x35e47f),_0x1bebca=_0x4c47bc?'\x20('+_0x4c47bc+')':'';return[_0x503eb2(0x134)+_0x5cad8c+'\x22'+_0x1bebca+_0x503eb2(0x12f)+_0x5b1c92+_0x503eb2(0x13f)+_0x3c732d+'\x20的数据源。',_0x503eb2(0x145),'请先将该数据集升级/迁移为\x20DB\x20table\x20数据集,再基于新的\x20dataset\x20code\x20继续开发。',_0x503eb2(0x141)+RUNTIME_DATA_ACCESS_COMMANDS[_0x503eb2(0x132)]+';'+RUNTIME_DATA_ACCESS_COMMANDS[_0x503eb2(0x140)]+'。'][_0x503eb2(0x138)]('\x20');}export function assertDatasetSupportsLocalDevelopment(_0x5155ff,_0x52d410){const _0x2017b7=a50_0x26140f;if(!isDbBackedDataset(_0x5155ff))throw CliErrors[_0x2017b7(0x146)](buildDbTableUpgradeMessage(_0x5155ff,_0x52d410));}
1
+ const a50_0x953211=a50_0x376f;(function(_0x42a364,_0x2592ab){const _0x22e8ec=a50_0x376f,_0x20aed9=_0x42a364();while(!![]){try{const _0x105928=parseInt(_0x22e8ec(0x87))/0x1*(parseInt(_0x22e8ec(0xa9))/0x2)+-parseInt(_0x22e8ec(0x88))/0x3+-parseInt(_0x22e8ec(0xa1))/0x4*(-parseInt(_0x22e8ec(0x8a))/0x5)+parseInt(_0x22e8ec(0x9c))/0x6*(-parseInt(_0x22e8ec(0x93))/0x7)+parseInt(_0x22e8ec(0x8d))/0x8*(-parseInt(_0x22e8ec(0x8f))/0x9)+-parseInt(_0x22e8ec(0xa3))/0xa+parseInt(_0x22e8ec(0xa6))/0xb;if(_0x105928===_0x2592ab)break;else _0x20aed9['push'](_0x20aed9['shift']());}catch(_0xaff0f4){_0x20aed9['push'](_0x20aed9['shift']());}}}(a50_0x2f9a,0xb943c));import{CliErrors}from'../../errors.js';export const RUNTIME_DATA_ACCESS_COMMANDS={'cli':'lovrabet','filter':'lovrabet\x20data\x20filter\x20--code\x20<datasetCode>\x20--params\x20\x27<json>\x27\x20--format\x20compress','getOne':'lovrabet\x20data\x20getOne\x20--code\x20<datasetCode>\x20--params\x20\x27{\x22id\x22:123}\x27\x20--format\x20compress'};function a50_0x376f(_0xba59b8,_0x4986a3){_0xba59b8=_0xba59b8-0x86;const _0x2f9aa2=a50_0x2f9a();let _0x376f58=_0x2f9aa2[_0xba59b8];return _0x376f58;}export const RUNTIME_DATA_ACCESS_SUMMARY=a50_0x953211(0x8c);function valueToString(_0x2566c4){return _0x2566c4==null?'':String(_0x2566c4)['trim']();}function getDatasetCode(_0x2f996f){const _0x53ec2c=a50_0x953211;return valueToString(_0x2f996f[_0x53ec2c(0x98)]??_0x2f996f[_0x53ec2c(0x8e)]??_0x2f996f[_0x53ec2c(0x95)]?.[_0x53ec2c(0x89)]);}function getDatasetName(_0x22b1a7){const _0x5c6f14=a50_0x953211;return valueToString(_0x22b1a7[_0x5c6f14(0x97)]??_0x22b1a7[_0x5c6f14(0x95)]?.[_0x5c6f14(0x86)])||_0x5c6f14(0x90);}function getDatasetSource(_0x2e2c2a){const _0x46e1af=a50_0x953211;return valueToString(_0x2e2c2a['source']??_0x2e2c2a[_0x46e1af(0x95)]?.[_0x46e1af(0x99)])['toUpperCase']();}function getDbtableConfig(_0x352ede){const _0x532193=a50_0x953211,_0x36e974=_0x352ede[_0x532193(0x9f)]??_0x352ede[_0x532193(0xa4)];return _0x36e974&&typeof _0x36e974===_0x532193(0x9a)?_0x36e974:{};}export function isDbBackedDataset(_0xc761d0){const _0x57bea6=a50_0x953211,_0x515706=getDatasetSource(_0xc761d0);if(_0x515706===_0x57bea6(0x9d))return![];const _0x28b098=getDbtableConfig(_0xc761d0),_0x33056a=_0x28b098[_0x57bea6(0xa0)]??_0x28b098['id'],_0x19495d=valueToString(_0x28b098['tableName']??_0xc761d0[_0x57bea6(0x96)]??_0xc761d0[_0x57bea6(0x95)]?.[_0x57bea6(0x96)]);return _0x33056a!==undefined&&_0x33056a!==null&&_0x19495d['length']>0x0;}export function filterDbBackedDatasets(_0x38cc71){const _0x3bdfc5=a50_0x953211;return _0x38cc71[_0x3bdfc5(0x9e)](_0xa2f90e=>isDbBackedDataset(_0xa2f90e));}export function buildDbTableUpgradeMessage(_0x2d4521,_0x2c7bb9=a50_0x953211(0x91)){const _0x440056=a50_0x953211,_0xb4fb6=getDatasetSource(_0x2d4521)||'UNKNOWN',_0xb71766=getDatasetName(_0x2d4521),_0x51735f=getDatasetCode(_0x2d4521),_0x35ccf3=_0x51735f?'\x20('+_0x51735f+')':'';return[_0x440056(0xa7)+_0xb71766+'\x22'+_0x35ccf3+_0x440056(0x9b)+_0xb4fb6+_0x440056(0xa2)+_0x2c7bb9+_0x440056(0xa8),_0x440056(0x94),'请先将该数据集升级/迁移为\x20DB\x20table\x20数据集,再基于新的\x20dataset\x20code\x20继续开发。','如果只是查看运行态真实行数据,请切换到\x20lovrabet\x20CLI:'+RUNTIME_DATA_ACCESS_COMMANDS[_0x440056(0x9e)]+';'+RUNTIME_DATA_ACCESS_COMMANDS[_0x440056(0xa5)]+'。'][_0x440056(0x92)]('\x20');}export function assertDatasetSupportsLocalDevelopment(_0x938dca,_0x3e1ae1){const _0x370323=a50_0x953211;if(!isDbBackedDataset(_0x938dca))throw CliErrors[_0x370323(0x8b)](buildDbTableUpgradeMessage(_0x938dca,_0x3e1ae1));}function a50_0x2f9a(){const _0x20c6ec=['当前数据集\x20\x22','\x20的数据源。','3082zmfdtb','datasetName','674CIeGJj','2041833ThwSJx','datasetCode','1144530AaClvZ','validation','Use\x20lovrabet\x20data\x20filter/getOne\x20for\x20real\x20runtime\x20records.','900696QQYySK','modelCode','27mFHZFd','unknown','BFF\x20/\x20SQL\x20等研发态资产','join','7iaFtsf','原因:该类研发态资产需要\x20DB\x20table、dbId、tableName\x20与数据库连接上下文,并深度依赖\x20SQL\x20执行链路。','dataset','tableName','name','code','sourceType','object','\x20是\x20','4105038vkBDJg','METADATA','filter','dbtableConfig','dbId','12uSUswm','\x20类型,不适合作为\x20','13947130hgcWWs','dbtable','getOne','23438250WYGbSL'];a50_0x2f9a=function(){return _0x20c6ec;};return a50_0x2f9a();}