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

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (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 -1
  80. package/lib/commands/issue/report.js +1 -1
  81. package/lib/commands/issue/shared.js +1 -1
  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 +1 -1
@@ -1 +1 @@
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
+ const a32_0x3e2145=a32_0x2e7a;(function(_0x44eb9d,_0x3b905b){const _0x2ed21a=a32_0x2e7a,_0x3d1b31=_0x44eb9d();while(!![]){try{const _0x52f598=-parseInt(_0x2ed21a(0x196))/0x1*(-parseInt(_0x2ed21a(0x1aa))/0x2)+-parseInt(_0x2ed21a(0x187))/0x3+parseInt(_0x2ed21a(0x184))/0x4*(parseInt(_0x2ed21a(0x19b))/0x5)+parseInt(_0x2ed21a(0x17a))/0x6+parseInt(_0x2ed21a(0x195))/0x7+-parseInt(_0x2ed21a(0x199))/0x8+-parseInt(_0x2ed21a(0x165))/0x9;if(_0x52f598===_0x3b905b)break;else _0x3d1b31['push'](_0x3d1b31['shift']());}catch(_0x4cb52c){_0x3d1b31['push'](_0x3d1b31['shift']());}}}(a32_0xb239,0xba544));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';function a32_0x2e7a(_0x9ae700,_0x38f129){_0x9ae700=_0x9ae700-0x15f;const _0xb239bd=a32_0xb239();let _0x2e7ac2=_0xb239bd[_0x9ae700];return _0x2e7ac2;}function a32_0xb239(){const _0x32bbb3=['datasetCode','unchanged','Local\x20function\x20not\x20found:\x20','2530300zqRAGb','script','stringify','851127BwZwqx','string','cleared','HOOK','Would\x20inspect\x20','Lock\x20scope\x20for\x20app\x20\x22','Force\x20push\x20ignoring\x20hash\x20protection','attempted','lockFilePath','\x20local\x20BFF\x20script(s)\x20for\x20push\x20and\x20clear\x20runtime\x20cache\x20if\x20files\x20are\x20uploaded','\x20failed,\x20','runtime\x20cache\x20cleared','Push\x20complete:\x20','lockKey','6564418omLtxw','22367eflJaO','join','bff','3320704JWksIT','name','10EoSjlM','hash','ENDPOINT','every','No\x20local\x20BFF\x20functions\x20found.','description','Push\x20only\x20the\x20named\x20function\x20(requires\x20--type)','status','Lock\x20file\x20not\x20settled\x20after\x20push\x20for\x20','\x22.\x20','boolean','datasetCodeToDataset','alias','would_push','update','62MmfgXK','remoteId','validation','functions','map','parse','force','POST','\x22\x20not\x20found\x20after\x20ensureLockScope.','19533681TXvgnj','runtime\x20cache\x20not\x20needed','type','appCode','datasetId','Run\x20`','operationType','functionNode','str','apps','values','--name\x20requires\x20--type\x20to\x20identify\x20the\x20function.','has','push','lastSync','create','runtime\x20cache\x20clear\x20failed','COMMON','bool','version',':\x20missing\x20remote\x20version.\x20Run\x20`push`\x20after\x20`pull`\x20to\x20sync\x20version\x20info.','4416654pyuaNO','get','length','some','scriptsRoot','filter','filePath'];a32_0xb239=function(){return _0x32bbb3;};return a32_0xb239();}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';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':a32_0x3e2145(0x198),'command':a32_0x3e2145(0x172),'description':'Push\x20local\x20BFF\x20scripts\x20to\x20remote','risk':'high-risk-write','flags':[{'name':a32_0x3e2145(0x167),'type':a32_0x3e2145(0x188),'description':'Push\x20only\x20this\x20script\x20type','enum':[a32_0x3e2145(0x176),a32_0x3e2145(0x19d),a32_0x3e2145(0x18a)]},{'name':a32_0x3e2145(0x19a),'type':a32_0x3e2145(0x188),'description':a32_0x3e2145(0x1a1)},{'name':a32_0x3e2145(0x162),'type':a32_0x3e2145(0x1a5),'description':a32_0x3e2145(0x18d)}],async 'dryRun'(_0x20547b){const _0x223400=a32_0x3e2145,_0x2b9b8a=loadBffProjectConfig(_0x20547b[_0x223400(0x168)]),_0x1f1276=await readBffLockFile(_0x2b9b8a['lockFilePath']),{appLock:_0xe60bf8}=ensureLockScope(_0x1f1276??createEmptyBffLock(),_0x20547b['appCode'],_0x2b9b8a[_0x223400(0x17e)],_0x223400(0x172)),_0x1f0bb8=await getTargetFunctions(_0x2b9b8a,_0x20547b),_0x5c42e5=_0x20547b[_0x223400(0x177)](_0x223400(0x162)),_0x48299a=[];for(const _0x18b6ec of _0x1f0bb8){const _0x514449=await computeFileHash(_0x18b6ec[_0x223400(0x180)]),_0x220c55=_0xe60bf8[_0x223400(0x15f)][_0x18b6ec['lockKey']],_0x4a4dc7=!!_0x220c55&&_0x220c55[_0x223400(0x19c)]===_0x514449;_0x48299a[_0x223400(0x172)]({'lockKey':_0x18b6ec[_0x223400(0x194)],'filePath':_0x18b6ec['filePath'],'remoteId':_0x220c55?.[_0x223400(0x1ab)]??null,'mode':_0x220c55?.[_0x223400(0x1ab)]?_0x223400(0x1a9):_0x223400(0x174),'status':!_0x5c42e5&&_0x4a4dc7?_0x223400(0x182):_0x223400(0x1a8)});}return{'method':_0x223400(0x163),'url':'/api/management/library/scripts/save','body':{'appCode':_0x20547b[_0x223400(0x168)],'force':_0x5c42e5,'files':_0x48299a,'cacheClearAtRuntime':_0x48299a[_0x223400(0x17d)](_0x45a381=>_0x45a381[_0x223400(0x1a2)]==='would_push'),'cacheClearAtRuntimeTimes':_0x48299a[_0x223400(0x17d)](_0x42534b=>_0x42534b[_0x223400(0x1a2)]===_0x223400(0x1a8))?CACHE_CLEAR_ATTEMPTS:0x0},'description':_0x223400(0x18b)+_0x48299a[_0x223400(0x17c)]+_0x223400(0x190)};},async 'execute'(_0x5017f2){const _0x24e446=a32_0x3e2145,_0x265db3=loadBffProjectConfig(_0x5017f2[_0x24e446(0x168)]),_0x3cd87f=await readBffLockFile(_0x265db3[_0x24e446(0x18f)]),{lockData:_0x2ccddf,appLock:_0x419b39}=ensureLockScope(_0x3cd87f??createEmptyBffLock(),_0x5017f2[_0x24e446(0x168)],_0x265db3[_0x24e446(0x17e)],_0x24e446(0x172)),_0x3b3af8=await getTargetFunctions(_0x265db3,_0x5017f2);if(_0x3b3af8[_0x24e446(0x17c)]===0x0)return{'ok':!![],'data':{'uploaded':[],'skipped':[],'failed':[]},'message':_0x24e446(0x19f)};const _0x129040=_0x5017f2[_0x24e446(0x177)](_0x24e446(0x162)),_0x204201=JSON[_0x24e446(0x161)](JSON[_0x24e446(0x186)](_0x2ccddf)),_0x2bc9cc=_0x204201['apps'][_0x5017f2[_0x24e446(0x168)]];if(!_0x2bc9cc)throw new Error(_0x24e446(0x18c)+_0x5017f2['appCode']+_0x24e446(0x164));const _0x30a71e=await buildHookMaps(_0x5017f2['appCode'],_0x5017f2['apiDir'],_0x3b3af8,_0x2bc9cc),_0xc125b9=[],_0x4c7d16=[],_0x59dc19=[];for(const _0x5a8655 of _0x3b3af8){const _0x4bca23=await computeFileHash(_0x5a8655[_0x24e446(0x180)]),_0x573336=_0x2bc9cc[_0x24e446(0x15f)][_0x5a8655[_0x24e446(0x194)]];if(!_0x129040&&_0x573336&&_0x573336[_0x24e446(0x19c)]===_0x4bca23){_0x4c7d16['push']({'lockKey':_0x5a8655[_0x24e446(0x194)],'reason':'unchanged'});continue;}try{await uploadSingleFunction(_0x5017f2[_0x24e446(0x168)],_0x5a8655,_0x2bc9cc,_0x30a71e);const _0x1d1659=_0x2bc9cc[_0x24e446(0x15f)][_0x5a8655[_0x24e446(0x194)]];_0xc125b9[_0x24e446(0x172)]({'lockKey':_0x5a8655[_0x24e446(0x194)],'remoteId':_0x1d1659?.[_0x24e446(0x1ab)]??0x0});}catch(_0xa70b6b){_0x59dc19[_0x24e446(0x172)]({'lockKey':_0x5a8655[_0x24e446(0x194)],'error':_0xa70b6b instanceof Error?_0xa70b6b['message']:String(_0xa70b6b)});}}_0x2bc9cc[_0x24e446(0x173)]=new Date()['toISOString'](),await writeBffLockFile(_0x265db3[_0x24e446(0x18f)],_0x204201),await waitForUploadedLockEntries(_0x265db3['lockFilePath'],_0x5017f2[_0x24e446(0x168)],_0xc125b9['map'](_0x2403af=>_0x2403af['lockKey']));let _0x11152d={'attempted':![],'cleared':![]};if(_0xc125b9['length']>0x0)try{let _0x2848c8='';for(let _0xa3a6cb=0x0;_0xa3a6cb<CACHE_CLEAR_ATTEMPTS;_0xa3a6cb+=0x1){_0x2848c8=await clearBffScriptCache(),_0xa3a6cb<CACHE_CLEAR_ATTEMPTS-0x1&&await sleep(CACHE_CLEAR_INTERVAL_MS);}_0x11152d={'attempted':!![],'cleared':!![],'message':_0x2848c8||'Runtime\x20script\x20cache\x20cleared.'};}catch(_0x2594ec){_0x11152d={'attempted':!![],'cleared':![],'error':_0x2594ec instanceof Error?_0x2594ec['message']:String(_0x2594ec)};}const _0x5a11ac=_0x59dc19[_0x24e446(0x17c)]===0x0&&(_0x11152d['attempted']?_0x11152d['cleared']:!![]),_0x545fac=_0x11152d[_0x24e446(0x18e)]?_0x11152d[_0x24e446(0x189)]?_0x24e446(0x192):_0x24e446(0x175):_0x24e446(0x166);return{'ok':_0x5a11ac,'data':{'uploaded':_0xc125b9,'skipped':_0x4c7d16,'failed':_0x59dc19,'cacheClear':_0x11152d},'message':_0x24e446(0x193)+_0xc125b9[_0x24e446(0x17c)]+'\x20uploaded,\x20'+_0x4c7d16['length']+'\x20skipped,\x20'+_0x59dc19['length']+_0x24e446(0x191)+_0x545fac};}};async function getTargetFunctions(_0x43b080,_0x4bf13a){const _0x549d89=a32_0x3e2145,_0x7a1e81=_0x4bf13a[_0x549d89(0x16d)](_0x549d89(0x167)),_0x409cf0=_0x4bf13a['str'](_0x549d89(0x19a)),_0x2011f7=normalizeBffType(_0x7a1e81)??undefined;if(_0x409cf0&&!_0x2011f7)throw CliErrors[_0x549d89(0x1ac)](_0x549d89(0x170));const _0x2c20b3=await scanLocalBffFunctions(_0x43b080,_0x2011f7);if(_0x409cf0){const _0x2ca210=_0x2c20b3[_0x549d89(0x17f)](_0x2c564a=>_0x2c564a[_0x549d89(0x19a)]===_0x409cf0);if(_0x2ca210['length']===0x0)throw CliErrors[_0x549d89(0x1ac)](_0x549d89(0x183)+_0x2011f7+'/'+_0x409cf0);return _0x2ca210;}return _0x2c20b3;}async function buildHookMaps(_0x2e25df,_0x48820f,_0x4d8e01,_0x3d0f96){const _0x43e629=a32_0x3e2145,_0x21d1e1=_0x4d8e01[_0x43e629(0x17d)](_0x59037e=>_0x59037e[_0x43e629(0x167)]===_0x43e629(0x18a));if(!_0x21d1e1)return{'aliasToDatasetCode':new Map(),'datasetCodeToDataset':new Map()};const _0x4427df=loadAliasMap(_0x48820f,undefined,resolveApiFilePath(_0x48820f,_0x2e25df)),_0xe885d5=new Map(_0x4427df['map'](_0x2c2272=>[_0x2c2272[_0x43e629(0x1a7)],_0x2c2272['datasetCode']]));for(const _0xd92223 of Object[_0x43e629(0x16f)](_0x3d0f96[_0x43e629(0x15f)])){_0xd92223['alias']&&_0xd92223[_0x43e629(0x181)]&&!_0xe885d5[_0x43e629(0x171)](_0xd92223['alias'])&&_0xe885d5['set'](_0xd92223[_0x43e629(0x1a7)],_0xd92223[_0x43e629(0x181)]);}const _0x5cbfed=await listDatasets(_0x2e25df),_0x2529da=new Map(_0x5cbfed[_0x43e629(0x160)](_0x2157f3=>[_0x2157f3['code'],_0x2157f3]));return{'aliasToDatasetCode':_0xe885d5,'datasetCodeToDataset':_0x2529da};}async function uploadSingleFunction(_0x41e1d2,_0x528064,_0x223f47,_0x50bd75){const _0x56be72=a32_0x3e2145,_0x4a2291=await readFile(_0x528064[_0x56be72(0x180)],'utf8'),_0x18c170=await computeFileHash(_0x528064[_0x56be72(0x180)]),_0x2b815d=_0x223f47[_0x56be72(0x15f)][_0x528064[_0x56be72(0x194)]];if(_0x2b815d?.[_0x56be72(0x1ab)]&&_0x2b815d[_0x56be72(0x178)]==null)throw CliErrors[_0x56be72(0x1ac)](_0x528064['lockKey']+_0x56be72(0x179));let _0x228791=extractScriptDescription(_0x4a2291);if(!_0x228791&&_0x2b815d?.[_0x56be72(0x1ab)]){const _0x516516=await getBffScriptInfo(_0x2b815d[_0x56be72(0x1ab)]);_0x228791=_0x516516[_0x56be72(0x1a0)]||undefined;}const _0x2d0311={'appCode':_0x41e1d2,'functionName':_0x528064[_0x56be72(0x19a)],'scriptType':_0x528064[_0x56be72(0x167)],'scriptContent':_0x4a2291};if(_0x2b815d?.['remoteId'])_0x2d0311['id']=_0x2b815d['remoteId'];if(_0x2b815d?.[_0x56be72(0x178)]!=null)_0x2d0311[_0x56be72(0x178)]=_0x2b815d[_0x56be72(0x178)];if(_0x228791)_0x2d0311[_0x56be72(0x1a0)]=_0x228791;if(_0x528064[_0x56be72(0x167)]===_0x56be72(0x18a)){const _0x3afb29=_0x528064[_0x56be72(0x1a7)];if(!_0x3afb29||!_0x528064['operationType']||!_0x528064['functionNode'])throw CliErrors[_0x56be72(0x1ac)]('Incomplete\x20HOOK\x20path:\x20'+_0x528064['lockKey']);const _0xf17d97=_0x50bd75['aliasToDatasetCode'][_0x56be72(0x17b)](_0x3afb29)??_0x2b815d?.[_0x56be72(0x181)]??_0x3afb29,_0x46bc44=_0x50bd75[_0x56be72(0x1a6)][_0x56be72(0x17b)](_0xf17d97);if(!_0x46bc44)throw CliErrors[_0x56be72(0x1ac)]('Cannot\x20resolve\x20dataset\x20for\x20\x22'+_0x3afb29+_0x56be72(0x1a4)+(_0x56be72(0x16a)+CLI_BIN_NAME+'\x20api\x20pull`\x20to\x20refresh\x20api.ts,\x20or\x20verify\x20the\x20dataset\x20exists.'));assertDatasetSupportsLocalDevelopment(_0x46bc44,'BFF\x20HOOK\x20'+_0x528064[_0x56be72(0x194)]),_0x2d0311[_0x56be72(0x169)]=_0x46bc44['id'],_0x2d0311[_0x56be72(0x16b)]=_0x528064['operationType'],_0x2d0311['functionNode']=_0x528064[_0x56be72(0x16c)];}const _0x352b0f=await saveBffScript(_0x2d0311),_0x8c2c2c=_0x352b0f['id'],_0x553bf4=_0x352b0f[_0x56be72(0x185)]??await getBffScriptInfo(_0x8c2c2c),_0x2a2caa={'hash':_0x18c170,'remoteId':_0x8c2c2c,'version':_0x553bf4[_0x56be72(0x178)]};if(_0x528064[_0x56be72(0x167)]===_0x56be72(0x18a)){const _0x58661a=_0x528064[_0x56be72(0x1a7)],_0x165e68=_0x50bd75['aliasToDatasetCode'][_0x56be72(0x17b)](_0x58661a)??_0x2b815d?.[_0x56be72(0x181)]??_0x58661a;_0x50bd75['aliasToDatasetCode']['has'](_0x58661a)?_0x2a2caa['alias']=_0x58661a:_0x2a2caa[_0x56be72(0x1a7)]=_0x2b815d?.['alias'],_0x2a2caa[_0x56be72(0x181)]=_0x165e68,_0x2a2caa[_0x56be72(0x16b)]=_0x528064[_0x56be72(0x16b)],_0x2a2caa['functionNode']=_0x528064[_0x56be72(0x16c)];}_0x223f47[_0x56be72(0x15f)][_0x528064[_0x56be72(0x194)]]=_0x2a2caa;}const LOCK_SETTLE_RETRY_COUNT=0x14,LOCK_SETTLE_DELAY_MS=0x64;async function waitForUploadedLockEntries(_0x51c51f,_0x304fad,_0x52e73f){const _0x416b3c=a32_0x3e2145;if(_0x52e73f[_0x416b3c(0x17c)]===0x0)return;for(let _0x405cf9=0x0;_0x405cf9<LOCK_SETTLE_RETRY_COUNT;_0x405cf9+=0x1){const _0x2f5316=await readBffLockFile(_0x51c51f),_0x1f3308=_0x2f5316?.[_0x416b3c(0x16e)]?.[_0x304fad]?.[_0x416b3c(0x15f)]??{},_0x21990d=_0x52e73f[_0x416b3c(0x19e)](_0x3704e9=>!!_0x1f3308[_0x3704e9]?.[_0x416b3c(0x1ab)]);if(_0x21990d)return;await sleep(LOCK_SETTLE_DELAY_MS);}throw new Error(_0x416b3c(0x1a3)+_0x52e73f[_0x416b3c(0x197)](',\x20')+'.');}
@@ -1 +1 @@
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
+ const a33_0x188832=a33_0x21d8;(function(_0x2a3798,_0x896ad8){const _0x3dd035=a33_0x21d8,_0x42b999=_0x2a3798();while(!![]){try{const _0x21d13e=parseInt(_0x3dd035(0x1ac))/0x1+parseInt(_0x3dd035(0x18f))/0x2*(-parseInt(_0x3dd035(0x193))/0x3)+-parseInt(_0x3dd035(0x196))/0x4*(-parseInt(_0x3dd035(0x1aa))/0x5)+parseInt(_0x3dd035(0x1a6))/0x6+-parseInt(_0x3dd035(0x19c))/0x7+-parseInt(_0x3dd035(0x19e))/0x8+parseInt(_0x3dd035(0x1a9))/0x9*(parseInt(_0x3dd035(0x1a5))/0xa);if(_0x21d13e===_0x896ad8)break;else _0x42b999['push'](_0x42b999['shift']());}catch(_0x3b9bc9){_0x42b999['push'](_0x42b999['shift']());}}}(a33_0x39b6,0x8cb3c));import{listBffScripts,getBffScriptStatistics}from'../../core/api-client.js';import{loadAliasMap}from'../../core/alias-resolver.js';import{resolveApiFilePath}from'../../context.js';function a33_0x21d8(_0x59386c,_0x180ab4){_0x59386c=_0x59386c-0x18d;const _0x39b620=a33_0x39b6();let _0x21d8aa=_0x39b620[_0x59386c];return _0x21d8aa;}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':a33_0x188832(0x192),'command':'status','description':a33_0x188832(0x19b),'risk':a33_0x188832(0x1a2),'flags':[{'name':a33_0x188832(0x199),'type':a33_0x188832(0x1ab),'description':a33_0x188832(0x1a8)}],async 'execute'(_0x2ffd73){const _0x47a0e0=a33_0x188832,_0x1e36cc=loadBffProjectConfig(_0x2ffd73[_0x47a0e0(0x198)]),_0x53660d=await readBffLockFile(_0x1e36cc[_0x47a0e0(0x19f)]),{appLock:_0x2c6b7a}=ensureLockScope(_0x53660d??createEmptyBffLock(),_0x2ffd73[_0x47a0e0(0x198)],_0x1e36cc[_0x47a0e0(0x19d)],_0x47a0e0(0x18e)),_0x152657=await scanLocalBffFunctions(_0x1e36cc),_0x53f083=[],_0x18b078=[],_0x80a5a9=[];for(const _0xd37be4 of _0x152657){const _0x4c5e47=await computeFileHash(_0xd37be4['filePath']),_0x3924cc=_0x2c6b7a[_0x47a0e0(0x191)][_0xd37be4['lockKey']];if(!_0x3924cc)_0x53f083['push'](_0xd37be4[_0x47a0e0(0x1a1)]);else _0x3924cc[_0x47a0e0(0x197)]!==_0x4c5e47?_0x18b078['push'](_0xd37be4[_0x47a0e0(0x1a1)]):_0x80a5a9[_0x47a0e0(0x1ad)](_0xd37be4[_0x47a0e0(0x1a1)]);}const _0x106c16=[];if(_0x2ffd73['bool'](_0x47a0e0(0x199))){const _0x653374=loadAliasMap(_0x2ffd73[_0x47a0e0(0x19a)],undefined,resolveApiFilePath(_0x2ffd73['apiDir'],_0x2ffd73[_0x47a0e0(0x198)])),_0x1186a5=new Map(_0x653374[_0x47a0e0(0x1a3)](_0x298676=>[_0x298676[_0x47a0e0(0x1a4)],_0x298676['alias']])),[_0x16886f,_0x5cd00]=await Promise['all']([listBffScripts(_0x2ffd73[_0x47a0e0(0x198)]),getBffScriptStatistics(_0x2ffd73[_0x47a0e0(0x198)])]),_0x131d93=createHookLocationMap(_0x5cd00),_0x3d559d=new Set(_0x152657[_0x47a0e0(0x1a3)](_0x5ea842=>_0x5ea842[_0x47a0e0(0x1a1)]));for(const _0x24bf83 of _0x16886f){const _0x15315d=resolveRemoteScriptTarget(_0x1e36cc,_0x24bf83,_0x131d93,_0x2c6b7a[_0x47a0e0(0x191)],_0x1186a5);_0x15315d&&!_0x3d559d[_0x47a0e0(0x190)](_0x15315d[_0x47a0e0(0x1a1)])&&_0x106c16['push'](_0x15315d['lockKey']);}}const _0x56c72=_0x53f083[_0x47a0e0(0x194)]===0x0&&_0x18b078[_0x47a0e0(0x194)]===0x0&&_0x106c16[_0x47a0e0(0x194)]===0x0;return{'ok':!![],'data':{'added':_0x53f083,'modified':_0x18b078,'unchanged':_0x80a5a9,'remoteOnly':_0x106c16},'message':_0x56c72?_0x47a0e0(0x18d):_0x53f083[_0x47a0e0(0x194)]+_0x47a0e0(0x195)+_0x18b078['length']+'\x20modified,\x20'+_0x80a5a9[_0x47a0e0(0x194)]+_0x47a0e0(0x1a7)+(_0x106c16[_0x47a0e0(0x194)]>0x0?',\x20'+_0x106c16['length']+_0x47a0e0(0x1a0):'')};}};function a33_0x39b6(){const _0x1a079d=['datasetCode','10fKDfdz','1719336AIzPOV','\x20unchanged','Also\x20check\x20for\x20remote-only\x20scripts\x20not\x20present\x20locally','4332636AEhzxs','355hLKXah','boolean','904609EDLvjs','push','All\x20BFF\x20scripts\x20are\x20in\x20sync.','status','110158cbBUvM','has','functions','bff','3dJCnKz','length','\x20added,\x20','22948mBWsiK','hash','appCode','remote','apiDir','Check\x20local\x20BFF\x20sync\x20status\x20against\x20lock\x20file','5259681krwbDP','scriptsRoot','5576944cVgyXI','lockFilePath','\x20remote-only','lockKey','read','map'];a33_0x39b6=function(){return _0x1a079d;};return a33_0x39b6();}
@@ -1 +1 @@
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
+ const a34_0x10617a=a34_0x72ed;(function(_0x57686b,_0x278c22){const _0x433857=a34_0x72ed,_0x20e037=_0x57686b();while(!![]){try{const _0x2d310d=-parseInt(_0x433857(0x138))/0x1+parseInt(_0x433857(0x13e))/0x2*(parseInt(_0x433857(0x141))/0x3)+-parseInt(_0x433857(0x160))/0x4*(-parseInt(_0x433857(0x15c))/0x5)+-parseInt(_0x433857(0x14d))/0x6*(-parseInt(_0x433857(0x151))/0x7)+parseInt(_0x433857(0x139))/0x8*(-parseInt(_0x433857(0x14a))/0x9)+parseInt(_0x433857(0x152))/0xa*(parseInt(_0x433857(0x17a))/0xb)+-parseInt(_0x433857(0x146))/0xc*(parseInt(_0x433857(0x158))/0xd);if(_0x2d310d===_0x278c22)break;else _0x20e037['push'](_0x20e037['shift']());}catch(_0x428424){_0x20e037['push'](_0x20e037['shift']());}}}(a34_0x2aa6,0x66a8f));import a34_0x3e9a0c from'chalk';import a34_0x4378b2 from'ora';import a34_0xac95b1 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 a34_0x2aa6(){const _0x120418=['Requested\x20version:\x20','\x20→\x20','Invalid\x20version:\x20','Choose\x20either\x20npm\x20beta\x20dist-tag\x20or\x20an\x20exact\x20version.','bun','cwd','filter','Checking\x20official\x20skill\x20package...','write','Checking\x20for\x20updates...','execPath','flag','\x20\x20Try\x20manually:\x20','entries','4511793WqpvMG','skills','Updated\x20to\x20v','error','beta','run','Update\x20rabetbase\x20CLI\x20to\x20the\x20latest\x20version','json','Current\x20version:\x20','\x20\x20Official\x20skill\x20update\x20failed:\x20','green','Update\x20failed','start','Unable\x20to\x20resolve\x20beta\x20version\x20from\x20npm','Already\x20on\x20requested\x20version\x20(v','toLowerCase','trim','\x20\x20Run\x20manually:\x20','inherit','pipe','boolean','slice','no-skills','red','\x20install\x20-g\x20','\x20\x20Skipped\x20skill\x20install\x20(RABETBASE_SKIP_NPX_SKILLS=1).','Install\x20a\x20specific\x20CLI\x20version','12089goLNbw','8PhmfGH','yellow','update','str','@latest','4vUcQeY','valid','...','631542SZYhVt','validation','Refresh\x20official\x20skill\x20package\x20after\x20updating','includes','\x20\x20Restart\x20your\x20terminal\x20to\x20use\x20the\x20new\x20version.','60BvlmLd','source','stableVersion','gray','6730110pNzPKR','/dist-tags','map','246804BFnERJ','length','nonInteractive','warn','77nhsMur','10dUdulH','fail','Unable\x20to\x20check\x20for\x20updates\x20(network\x20error)','https://registry.npmjs.org/-/package/','log','message','2150824zCrAiD','Already\x20up\x20to\x20date\x20(v','latest','Skipping\x20official\x20skill\x20package\x20(--no-skills).','5JIvmgq','Skip\x20official\x20skill\x20package\x20refresh\x20after\x20updating','info','unknown','2895796ieHEsK','\x20\x20Official\x20skill\x20package\x20is\x20up\x20to\x20date.','Updating\x20via\x20','npm','timeout','Version\x20comparison\x20failed','bool','Beta\x20version:\x20','string','version','object','Update\x20available:\x20'];a34_0x2aa6=function(){return _0x120418;};return a34_0x2aa6();}function getCurrentVersion(){const _0xe5af09=a34_0x72ed;return GIT_COMMIT!==_0xe5af09(0x15f)?VERSION+'\x20('+GIT_COMMIT+',\x20'+BUILD_TIME[_0xe5af09(0x132)](0x0,0xa)+')':VERSION;}function detectPackageManager(){const _0x310439=a34_0x72ed,_0x4e5416=process[_0x310439(0x176)][_0x310439(0x12c)]();if(_0x4e5416[_0x310439(0x144)]('bun'))return _0x310439(0x170);return _0x310439(0x163);}const updateFlags=[{'name':a34_0x10617a(0x17e),'type':a34_0x10617a(0x131),'description':'Install\x20the\x20version\x20from\x20npm\x20beta\x20dist-tag','default':![]},{'name':a34_0x10617a(0x169),'type':a34_0x10617a(0x168),'description':a34_0x10617a(0x137)},{'name':a34_0x10617a(0x133),'type':a34_0x10617a(0x131),'description':a34_0x10617a(0x15d),'default':![]},{'name':a34_0x10617a(0x17b),'type':'boolean','description':a34_0x10617a(0x143),'default':!![],'hidden':!![]}];function getRequestedVersion(_0x1fa496){const _0x31dd44=a34_0x10617a;return _0x1fa496[_0x31dd44(0x13c)](_0x31dd44(0x169))[_0x31dd44(0x12d)]();}function shouldSkipOfficialSkill(_0x34a344){const _0x4a432a=a34_0x10617a;return _0x34a344[_0x4a432a(0x166)](_0x4a432a(0x133))||_0x34a344[_0x4a432a(0x177)](_0x4a432a(0x17b))===![];}async function validateUpdateFlags(_0x1348cc){const _0x350033=a34_0x10617a,_0xbcf317=_0x1348cc[_0x350033(0x166)](_0x350033(0x17e)),_0x172e34=getRequestedVersion(_0x1348cc);if(_0xbcf317&&_0x172e34)throw CliErrors[_0x350033(0x142)]('--beta\x20and\x20--version\x20cannot\x20be\x20used\x20together.',_0x350033(0x16f));if(_0x172e34&&!a34_0xac95b1[_0x350033(0x13f)](_0x172e34))throw CliErrors[_0x350033(0x142)](_0x350033(0x16e)+_0x172e34,'Use\x20a\x20full\x20semver\x20such\x20as\x202.1.6\x20or\x202.1.6-beta.1.');}async function fetchNpmDistTags(){const _0x2bbaee=a34_0x10617a;try{const _0x11462a=await fetch(_0x2bbaee(0x155)+encodeURIComponent(NPM_PACKAGE_NAME)+_0x2bbaee(0x14b),{'signal':AbortSignal[_0x2bbaee(0x164)](0x2710)});if(!_0x11462a['ok'])return null;const _0x50069e=await _0x11462a[_0x2bbaee(0x181)]();if(!_0x50069e||typeof _0x50069e!==_0x2bbaee(0x16a))return null;return Object['fromEntries'](Object[_0x2bbaee(0x179)](_0x50069e)[_0x2bbaee(0x172)](([,_0x4236b7])=>typeof _0x4236b7===_0x2bbaee(0x168)&&_0x4236b7[_0x2bbaee(0x12d)]()[_0x2bbaee(0x14e)]>0x0)[_0x2bbaee(0x14c)](([_0x531197,_0x8cdb97])=>[_0x531197,String(_0x8cdb97)[_0x2bbaee(0x12d)]()]));}catch{return null;}}async function fetchNpmDistTagVersion(_0x227090){const _0x3fd215=await fetchNpmDistTags();return _0x3fd215?.[_0x227090]??null;}async function fetchLatestVersion(){const _0x5d2b96=a34_0x10617a,_0x287232=await fetchNpmDistTagVersion('latest');if(_0x287232)return _0x287232;const _0x294401=await getCdnConfig();return _0x294401?.['cli']?.[_0x5d2b96(0x148)]??null;}async function resolveTargetVersion(_0x5a9a39){const _0x2dafb1=a34_0x10617a,_0x5561fc=getRequestedVersion(_0x5a9a39);if(_0x5561fc)return{'version':_0x5561fc,'source':_0x2dafb1(0x169)};if(_0x5a9a39[_0x2dafb1(0x166)](_0x2dafb1(0x17e))){const _0x208870=await fetchNpmDistTagVersion(_0x2dafb1(0x17e));if(!_0x208870)return null;return{'version':_0x208870,'source':'beta'};}const _0x48d76f=await fetchLatestVersion();if(!_0x48d76f)return null;return{'version':_0x48d76f,'source':_0x2dafb1(0x15a)};}function shouldInstallTarget(_0x12a04a,_0x597192){const _0x52c029=a34_0x10617a;if(_0x597192['source']===_0x52c029(0x169)||_0x597192[_0x52c029(0x147)]===_0x52c029(0x17e))return!a34_0xac95b1['eq'](_0x12a04a,_0x597192[_0x52c029(0x169)]);return a34_0xac95b1['lt'](_0x12a04a,_0x597192[_0x52c029(0x169)]);}function getInstallPlanLabel(_0x38c3ca,_0x4daaf1){const _0x5e18b2=a34_0x10617a;switch(_0x4daaf1[_0x5e18b2(0x147)]){case _0x5e18b2(0x17e):return _0x5e18b2(0x167)+a34_0x3e9a0c[_0x5e18b2(0x13a)](_0x38c3ca)+_0x5e18b2(0x16d)+a34_0x3e9a0c['green'](_0x4daaf1[_0x5e18b2(0x169)]);case _0x5e18b2(0x169):return _0x5e18b2(0x16c)+a34_0x3e9a0c['yellow'](_0x38c3ca)+_0x5e18b2(0x16d)+a34_0x3e9a0c[_0x5e18b2(0x184)](_0x4daaf1[_0x5e18b2(0x169)]);case'latest':default:return _0x5e18b2(0x16b)+a34_0x3e9a0c[_0x5e18b2(0x13a)](_0x38c3ca)+_0x5e18b2(0x16d)+a34_0x3e9a0c['green'](_0x4daaf1[_0x5e18b2(0x169)]);}}async function installOfficialSkill(_0x29718a){const _0x3b3f81=a34_0x10617a;console['log'](a34_0x3e9a0c['gray'](_0x3b3f81(0x173)));const _0x1b0dab=runNpxSkillsAddGlobal(process[_0x3b3f81(0x171)](),RABETBASE_SKILL_SOURCE,{'stdio':_0x29718a?'pipe':_0x3b3f81(0x12f)});if(_0x1b0dab['skipped']){console['log'](a34_0x3e9a0c[_0x3b3f81(0x149)](_0x3b3f81(0x136)));return;}if(_0x1b0dab['ok']){console[_0x3b3f81(0x156)](a34_0x3e9a0c[_0x3b3f81(0x149)](_0x3b3f81(0x161)));return;}console[_0x3b3f81(0x150)](a34_0x3e9a0c[_0x3b3f81(0x13a)](_0x3b3f81(0x183)+(_0x1b0dab[_0x3b3f81(0x17d)]||'unknown'))),console[_0x3b3f81(0x156)](a34_0x3e9a0c['gray'](_0x3b3f81(0x12e)+NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE));}function a34_0x72ed(_0x41eae0,_0x4e1b94){_0x41eae0=_0x41eae0-0x129;const _0x2aa6f4=a34_0x2aa6();let _0x72ed73=_0x2aa6f4[_0x41eae0];return _0x72ed73;}async function execute(_0x6f6de){const _0xa0ba88=a34_0x10617a;await validateUpdateFlags(_0x6f6de);const _0x2a74e1=getCurrentVersion();console[_0xa0ba88(0x156)](_0xa0ba88(0x182)+_0x2a74e1);const _0x578e45=a34_0x4378b2(_0xa0ba88(0x175))['start'](),_0x528749=await resolveTargetVersion(_0x6f6de);if(!_0x528749){const _0x414a69=_0x6f6de['bool'](_0xa0ba88(0x17e))?_0xa0ba88(0x12a):_0xa0ba88(0x154);return _0x578e45['fail'](_0x414a69),console[_0xa0ba88(0x156)](a34_0x3e9a0c['gray']('\x20\x20Run\x20manually:\x20npm\x20install\x20-g\x20'+NPM_PACKAGE_NAME+_0xa0ba88(0x13d))),{'ok':![],'message':_0x414a69};}const _0x4b215e=a34_0xac95b1[_0xa0ba88(0x13f)](VERSION),_0x4002f2=a34_0xac95b1['valid'](_0x528749['version']);if(!_0x4b215e||!_0x4002f2)return _0x578e45['fail'](_0xa0ba88(0x165)),{'ok':![],'message':_0xa0ba88(0x165)};if(!shouldInstallTarget(_0x4b215e,_0x528749)){const _0x2585f9=_0x528749[_0xa0ba88(0x147)]==='version'?_0xa0ba88(0x12b)+_0x528749[_0xa0ba88(0x169)]+')':_0xa0ba88(0x159)+_0x528749[_0xa0ba88(0x169)]+')';return _0x578e45['succeed'](_0x2585f9),shouldSkipOfficialSkill(_0x6f6de)?console[_0xa0ba88(0x156)](a34_0x3e9a0c['gray']('Skipping\x20official\x20skill\x20package\x20(--no-skills).')):await installOfficialSkill(_0x6f6de[_0xa0ba88(0x14f)]),{'ok':!![]};}_0x578e45[_0xa0ba88(0x15e)](getInstallPlanLabel(_0x2a74e1,_0x528749));const _0x2b0d9d=detectPackageManager(),_0x161d83=_0x2b0d9d===_0xa0ba88(0x163)?resolveNpmBin(_0xa0ba88(0x163)):_0x2b0d9d,_0x4fb20e=a34_0x4378b2(_0xa0ba88(0x162)+_0x2b0d9d+_0xa0ba88(0x140))[_0xa0ba88(0x129)]();try{return await execa(_0x161d83,['install','-g',NPM_PACKAGE_NAME+'@'+_0x528749[_0xa0ba88(0x169)]],{'stdio':_0xa0ba88(0x130)}),_0x4fb20e['succeed'](_0xa0ba88(0x17c)+_0x528749['version']),console[_0xa0ba88(0x156)](a34_0x3e9a0c['gray'](_0xa0ba88(0x145))),shouldSkipOfficialSkill(_0x6f6de)?console[_0xa0ba88(0x156)](a34_0x3e9a0c['gray'](_0xa0ba88(0x15b))):await installOfficialSkill(_0x6f6de[_0xa0ba88(0x14f)]),{'ok':!![]};}catch(_0x185f41){return _0x4fb20e[_0xa0ba88(0x153)](_0xa0ba88(0x185)),console['error'](a34_0x3e9a0c[_0xa0ba88(0x134)]('\x20\x20'+_0x185f41[_0xa0ba88(0x157)])),console[_0xa0ba88(0x156)](a34_0x3e9a0c['gray'](_0xa0ba88(0x178)+_0x2b0d9d+_0xa0ba88(0x135)+NPM_PACKAGE_NAME+'@'+_0x528749['version'])),{'ok':![],'message':_0x185f41[_0xa0ba88(0x157)]};}}export const updateDefinition={'service':a34_0x10617a(0x13b),'command':a34_0x10617a(0x17f),'description':a34_0x10617a(0x180),'risk':a34_0x10617a(0x174),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':updateFlags,'validate':validateUpdateFlags,'execute':execute};
@@ -1 +1 @@
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
+ function a35_0x1ad0(_0x11d7bf,_0x56f6d4){_0x11d7bf=_0x11d7bf-0xab;const _0x409310=a35_0x4093();let _0x1ad0ca=_0x409310[_0x11d7bf];return _0x1ad0ca;}(function(_0x3d814b,_0x564f1e){const _0x23120e=a35_0x1ad0,_0x9a1b26=_0x3d814b();while(!![]){try{const _0x4016b3=-parseInt(_0x23120e(0xae))/0x1+-parseInt(_0x23120e(0xab))/0x2+parseInt(_0x23120e(0xaf))/0x3+parseInt(_0x23120e(0xad))/0x4+-parseInt(_0x23120e(0xb1))/0x5+-parseInt(_0x23120e(0xac))/0x6+parseInt(_0x23120e(0xb0))/0x7;if(_0x4016b3===_0x564f1e)break;else _0x9a1b26['push'](_0x9a1b26['shift']());}catch(_0x182f21){_0x9a1b26['push'](_0x9a1b26['shift']());}}}(a35_0x4093,0x24162));function a35_0x4093(){const _0x364412=['754992JKCbDO','51780HloSNs','231996SDjpBr','3608115MJkxEU','1410190TkaFbX','232788uroriT','1101018EEWMSh'];a35_0x4093=function(){return _0x364412;};return a35_0x4093();}import{codegenSdk}from'../../commands/codegen/sdk.js';import{codegenSql}from'../../commands/codegen/sql.js';export const codegenDefinitions=[codegenSdk,codegenSql];
@@ -1 +1 @@
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
+ const a36_0x2a26a7=a36_0x3ceb;(function(_0x4f27c5,_0x29720e){const _0x5cebd8=a36_0x3ceb,_0x8acd19=_0x4f27c5();while(!![]){try{const _0x34e19e=-parseInt(_0x5cebd8(0xb3))/0x1+parseInt(_0x5cebd8(0xb7))/0x2+parseInt(_0x5cebd8(0xb5))/0x3*(parseInt(_0x5cebd8(0xab))/0x4)+-parseInt(_0x5cebd8(0xb6))/0x5*(-parseInt(_0x5cebd8(0xb2))/0x6)+parseInt(_0x5cebd8(0xb8))/0x7+parseInt(_0x5cebd8(0xb9))/0x8+-parseInt(_0x5cebd8(0xba))/0x9;if(_0x34e19e===_0x29720e)break;else _0x8acd19['push'](_0x8acd19['shift']());}catch(_0x2dbb27){_0x8acd19['push'](_0x8acd19['shift']());}}}(a36_0x2312,0xd8086));function a36_0x3ceb(_0x3bda18,_0x54bdb2){_0x3bda18=_0x3bda18-0xa5;const _0x231276=a36_0x2312();let _0x3ceb7b=_0x231276[_0x3bda18];return _0x3ceb7b;}function a36_0x2312(){const _0x1d2d28=['operation','appCode','string','6FuJIou','1626436dEaDUv','Omit\x20import\x20statements\x20from\x20generated\x20code','27okKulY','5871415tiQnwj','2746190BLZvka','10707382URXOta','5783408kCFTDt','32778315ZdNNrT','Operation\x20name\x20(e.g.\x20filter,\x20getOne,\x20create,\x20update)','tableName','alias','skip-imports','Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon)','code','read','str','601516IENiMs','sdk','bool','name'];a36_0x2312=function(){return _0x1d2d28;};return a36_0x2312();}import{getOperationDetail,generateSdkCode}from'../../core/api-client.js';import{CODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';export const codegenSdk={'service':'codegen','command':a36_0x2a26a7(0xac),'description':'Generate\x20TypeScript\x20SDK\x20code\x20for\x20a\x20dataset\x20operation','risk':a36_0x2a26a7(0xa9),'flags':[CODE_FLAG_OPTIONAL,{'name':a36_0x2a26a7(0xa5),'type':'string','description':a36_0x2a26a7(0xa7)},{'name':'operation','type':a36_0x2a26a7(0xb1),'required':!![],'description':a36_0x2a26a7(0xbb)},{'name':a36_0x2a26a7(0xa6),'type':'boolean','description':a36_0x2a26a7(0xb4)}],async 'execute'(_0x58f243){const _0x6e7d5=a36_0x2a26a7,{dataset:_0xef9274,operation:_0x2cb26d}=await getOperationDetail(_0x58f243[_0x6e7d5(0xb0)],_0x58f243[_0x6e7d5(0xaa)](_0x6e7d5(0xa8)),_0x58f243[_0x6e7d5(0xaa)](_0x6e7d5(0xaf))),_0x378d19=generateSdkCode(_0xef9274,_0x2cb26d,{'includeImports':!_0x58f243[_0x6e7d5(0xad)](_0x6e7d5(0xa6))});return{'ok':!![],'data':{'dataset':{'name':_0xef9274[_0x6e7d5(0xae)],'code':_0xef9274[_0x6e7d5(0xa8)],'tableName':_0xef9274[_0x6e7d5(0xbc)]},'operation':_0x58f243[_0x6e7d5(0xaa)](_0x6e7d5(0xaf)),'code':_0x378d19}};}};
@@ -1 +1 @@
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
+ const a37_0x5d59e0=a37_0x2a3f;(function(_0x4a6dfd,_0x4695e7){const _0x5dc1cc=a37_0x2a3f,_0x566fd7=_0x4a6dfd();while(!![]){try{const _0x25532d=-parseInt(_0x5dc1cc(0x104))/0x1*(-parseInt(_0x5dc1cc(0xfc))/0x2)+-parseInt(_0x5dc1cc(0x108))/0x3*(parseInt(_0x5dc1cc(0xf8))/0x4)+parseInt(_0x5dc1cc(0x10f))/0x5+-parseInt(_0x5dc1cc(0x105))/0x6+-parseInt(_0x5dc1cc(0x107))/0x7+parseInt(_0x5dc1cc(0x106))/0x8*(parseInt(_0x5dc1cc(0x109))/0x9)+parseInt(_0x5dc1cc(0x10c))/0xa*(parseInt(_0x5dc1cc(0x10b))/0xb);if(_0x25532d===_0x4695e7)break;else _0x566fd7['push'](_0x566fd7['shift']());}catch(_0x4eeaa0){_0x566fd7['push'](_0x566fd7['shift']());}}}(a37_0x1212,0x2fdea));function a37_0x2a3f(_0x4ab34f,_0x5e4b48){_0x4ab34f=_0x4ab34f-0xf6;const _0x1212f7=a37_0x1212();let _0x2a3fe4=_0x1212f7[_0x4ab34f];return _0x2a3fe4;}import{getSqlQueryInfo,generateSqlCodeTemplate}from'../../core/api-client.js';function a37_0x1212(){const _0x1e6a41=['sdk','767876HiArXd','boolean','bff','appCode','713962sRmQCk','sqlcode','str','sqlCode','Omit\x20import\x20statements\x20from\x20generated\x20code','codegen','bool','string','1kVzUEB','1619190GeZxiV','24HQaeiD','1399209trFtpk','3RxDuaN','153198pGhsXG','target','66nQszuw','132870dVQQDG','Generate\x20TypeScript\x20code\x20for\x20a\x20custom\x20SQL\x20query','sql','1850130EizPus','no-imports','read'];a37_0x1212=function(){return _0x1e6a41;};return a37_0x1212();}import{SQLCODE_FLAG}from'../../commands/common/flags.js';export const codegenSql={'service':a37_0x5d59e0(0x101),'command':a37_0x5d59e0(0x10e),'description':a37_0x5d59e0(0x10d),'risk':a37_0x5d59e0(0xf6),'flags':[SQLCODE_FLAG,{'name':a37_0x5d59e0(0x10a),'type':a37_0x5d59e0(0x103),'description':'Code\x20target:\x20sdk\x20(default)\x20or\x20bff','default':'sdk','enum':[a37_0x5d59e0(0xf7),a37_0x5d59e0(0xfa)]},{'name':'no-imports','type':a37_0x5d59e0(0xf9),'description':a37_0x5d59e0(0x100)}],async 'execute'(_0x4e25a3){const _0x54e1c3=a37_0x5d59e0,_0x30ffdf=await getSqlQueryInfo(_0x4e25a3[_0x54e1c3(0xfb)],_0x4e25a3['str'](_0x54e1c3(0xfd))),_0x26e87d=_0x4e25a3[_0x54e1c3(0xfe)](_0x54e1c3(0x10a))||'sdk',_0x441f7b=generateSqlCodeTemplate(_0x30ffdf,{'target':_0x26e87d,'includeImports':!_0x4e25a3[_0x54e1c3(0x102)](_0x54e1c3(0x110))});return{'ok':!![],'data':{'sqlCode':_0x30ffdf[_0x54e1c3(0xff)],'sqlName':_0x30ffdf['sqlName'],'target':_0x26e87d,'code':_0x441f7b}};}};
@@ -1 +1 @@
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
+ (function(_0x5ab967,_0x13bb43){const _0x55117d=a38_0x1056,_0xe6ae93=_0x5ab967();while(!![]){try{const _0x4eb7e7=parseInt(_0x55117d(0x173))/0x1+parseInt(_0x55117d(0x176))/0x2+parseInt(_0x55117d(0x185))/0x3*(-parseInt(_0x55117d(0x164))/0x4)+-parseInt(_0x55117d(0x17a))/0x5+-parseInt(_0x55117d(0x171))/0x6+parseInt(_0x55117d(0x16e))/0x7*(-parseInt(_0x55117d(0x184))/0x8)+parseInt(_0x55117d(0x166))/0x9;if(_0x4eb7e7===_0x13bb43)break;else _0xe6ae93['push'](_0xe6ae93['shift']());}catch(_0x324400){_0xe6ae93['push'](_0xe6ae93['shift']());}}}(a38_0x297b,0xcb1ea));import{input,checkbox,select}from'@inquirer/prompts';import a38_0x4c244c from'chalk';import{validateAppcode}from'../../commands/common/validate.js';import{listRemoteApps}from'../../core/api-client.js';import{withActiveCookie}from'../../utils/with-active-cookie.js';function a38_0x297b(){const _0x42344f=['请选择要绑定的应用:','126208ZtSBlk','trim','(未检测到登录态,请手动输入\x20App\x20Code\x20或直接跳过)','yellow','1232930gbpSvU','gray','map','获取到\x20','Invalid\x20App\x20Code','cyan','valid','manual','(跳过,稍后通过\x20config\x20set\x20appcode\x20配置)','includes','8QdxQiN','20529tYGYKB','message','\x0a未找到可用应用。','✎\x20自定义输入\x20appcode','custom','316wdfEMz','find','30312927bCFkmy','App\x20Code:','请输入\x20App\x20Code:','\x20个应用,请选择\x20(空格勾选,\x20a=全选,\x20i=反选):','appName','\x0a无法获取远程应用列表,请手动输入。','length','\x20\x20(','6985573BVZMGt','skip','✎\x20手动输入','8302386OJagMW','appCode','569624MyVLeV','正在获取可用应用列表...'];a38_0x297b=function(){return _0x42344f;};return a38_0x297b();}function a38_0x1056(_0x32e1e5,_0x42e631){_0x32e1e5=_0x32e1e5-0x163;const _0x297b90=a38_0x297b();let _0x105631=_0x297b90[_0x32e1e5];return _0x105631;}import{writeCliSideChannelLine}from'../../utils/write-cli-side-channel.js';export async function promptCustomAppcode(){const _0xc260fa=a38_0x1056,_0x843444=await input({'message':_0xc260fa(0x168),'validate':_0x22fdda=>{const _0x4b3996=_0xc260fa,_0x559661=validateAppcode(_0x22fdda['trim']());return _0x559661[_0x4b3996(0x180)]||_0x559661[_0x4b3996(0x186)]||_0x4b3996(0x17e);}});return _0x843444[_0xc260fa(0x177)]();}export async function promptAppSelection(_0x457a78){const _0x546e74=a38_0x1056,_0x1ac057=[{'name':a38_0x4c244c[_0x546e74(0x179)](_0x546e74(0x188)),'value':-0x1},..._0x457a78['map']((_0xd36361,_0x41f766)=>({'name':_0xd36361[_0x546e74(0x16a)]+'\x20\x20'+a38_0x4c244c[_0x546e74(0x17b)]('('+_0xd36361[_0x546e74(0x172)]+')'),'value':_0x41f766}))],_0x639ebd=await checkbox({'message':_0x546e74(0x17d)+a38_0x4c244c[_0x546e74(0x17f)](_0x457a78[_0x546e74(0x16c)])+_0x546e74(0x169),'choices':_0x1ac057,'loop':![]});if(_0x639ebd[_0x546e74(0x183)](-0x1))return _0x546e74(0x163);if(_0x639ebd[_0x546e74(0x16c)]===0x0)return'custom';return _0x639ebd[_0x546e74(0x17c)](_0x54220f=>_0x457a78[_0x54220f]);}export async function promptSingleAppSelection(_0x5b9759){const _0x554dbd=a38_0x1056,_0x2725ea=[{'name':a38_0x4c244c[_0x554dbd(0x17b)](_0x554dbd(0x182)),'value':_0x554dbd(0x16f)},{'name':a38_0x4c244c[_0x554dbd(0x179)]('✎\x20自定义输入\x20appcode'),'value':'custom'},..._0x5b9759['map'](_0x4b7fef=>({'name':_0x4b7fef[_0x554dbd(0x16a)]+'\x20\x20'+a38_0x4c244c['gray']('('+_0x4b7fef[_0x554dbd(0x172)]+')'),'value':_0x4b7fef['appCode']}))],_0x479b90=await select({'message':_0x554dbd(0x175),'choices':_0x2725ea});if(_0x479b90===_0x554dbd(0x16f))return'skip';if(_0x479b90===_0x554dbd(0x163))return _0x554dbd(0x163);return _0x5b9759[_0x554dbd(0x165)](_0x6decfa=>_0x6decfa[_0x554dbd(0x172)]===_0x479b90);}export async function selectSingleAppcode(_0x3e575f){const _0x24fc7b=a38_0x1056;if(!_0x3e575f)return writeCliSideChannelLine(a38_0x4c244c['gray'](_0x24fc7b(0x178))),_fallbackOrSkip();writeCliSideChannelLine(_0x24fc7b(0x174));let _0x3e753a;try{_0x3e753a=await withActiveCookie(_0x3e575f,()=>listRemoteApps());}catch(_0x3d1ebe){writeCliSideChannelLine(a38_0x4c244c[_0x24fc7b(0x179)]('无法获取远程应用列表,请手动输入。'));if(_0x3d1ebe instanceof Error)writeCliSideChannelLine(a38_0x4c244c[_0x24fc7b(0x17b)](_0x24fc7b(0x16d)+_0x3d1ebe[_0x24fc7b(0x186)]+')'));return _fallbackOrSkip();}if(_0x3e753a['length']===0x0)return writeCliSideChannelLine(a38_0x4c244c[_0x24fc7b(0x179)]('未找到可用应用。')),_fallbackOrSkip();const _0x18f02e=await promptSingleAppSelection(_0x3e753a);if(_0x18f02e==='skip')return'';if(_0x18f02e===_0x24fc7b(0x163))return promptCustomAppcode();return _0x18f02e[_0x24fc7b(0x172)];}export async function selectMultipleApps(_0x4a702d){const _0x5adfbe=a38_0x1056;writeCliSideChannelLine(_0x5adfbe(0x174));let _0xf501d8;try{_0xf501d8=await withActiveCookie(_0x4a702d,()=>listRemoteApps());}catch(_0x40669b){writeCliSideChannelLine(_0x5adfbe(0x16b));if(_0x40669b instanceof Error)writeCliSideChannelLine('\x20\x20('+_0x40669b[_0x5adfbe(0x186)]+')');return _0x5adfbe(0x163);}if(_0xf501d8['length']===0x0)return writeCliSideChannelLine(_0x5adfbe(0x187)),'custom';return promptAppSelection(_0xf501d8);}async function _fallbackOrSkip(){const _0x5c219d=a38_0x1056,_0x49db84=await select({'message':_0x5c219d(0x167),'choices':[{'name':a38_0x4c244c['gray']('(跳过,稍后配置)'),'value':_0x5c219d(0x16f)},{'name':a38_0x4c244c[_0x5c219d(0x179)](_0x5c219d(0x170)),'value':_0x5c219d(0x181)}]});if(_0x49db84===_0x5c219d(0x16f))return'';return promptCustomAppcode();}
@@ -1 +1 @@
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
+ function a39_0x54e9(_0x3f2937,_0x352089){_0x3f2937=_0x3f2937-0x75;const _0xa67bce=a39_0xa67b();let _0x54e961=_0xa67bce[_0x3f2937];return _0x54e961;}const a39_0x3b9a8f=a39_0x54e9;(function(_0x49635c,_0x53e47f){const _0x2ad26a=a39_0x54e9,_0x5a14b3=_0x49635c();while(!![]){try{const _0x388698=-parseInt(_0x2ad26a(0x7a))/0x1*(-parseInt(_0x2ad26a(0x77))/0x2)+-parseInt(_0x2ad26a(0x7c))/0x3+-parseInt(_0x2ad26a(0x75))/0x4+-parseInt(_0x2ad26a(0x7d))/0x5+parseInt(_0x2ad26a(0x82))/0x6*(parseInt(_0x2ad26a(0x7f))/0x7)+-parseInt(_0x2ad26a(0x88))/0x8+parseInt(_0x2ad26a(0x7e))/0x9;if(_0x388698===_0x53e47f)break;else _0x5a14b3['push'](_0x5a14b3['shift']());}catch(_0x3c5a9b){_0x5a14b3['push'](_0x5a14b3['shift']());}}}(a39_0xa67b,0x5acfd));export const DATASET_CODE_PATTERN={'regex':/^[a-f0-9]{32}$/i,'description':a39_0x3b9a8f(0x8a)};function a39_0xa67b(){const _0x48ad05=['SQL\x20code\x20in\x20format\x20xxxxxxxx-xxxxxxxx\x20(e.g.\x202305f915-dd48cd4c)','sqlcode','string','5927328vrWWwW','dbtype','a\x2032-character\x20hex\x20string\x20(e.g.\x2099a909313f1fa7153186431e1c551588)','539108RtEylv','App\x20code\x20(overrides\x20config\x20file,\x20e.g.\x20app-xxxxx)','46ksZnoS','datasetcode','MYSQL','19963rJUkib','code','769041OPmBdC','1455125xLpgpU','5916366NxSdac','4749549nqSPJH','number','appcode','6wpgncb','Database\x20connection\x20ID\x20(dblink\x20id\x20from\x20db\x20list)','Dataset\x20code\x20(32-char\x20hex\x20UUID)'];a39_0xa67b=function(){return _0x48ad05;};return a39_0xa67b();}export const CODE_FLAG={'name':a39_0x3b9a8f(0x7b),'type':'string','required':!![],'description':a39_0x3b9a8f(0x84),'pattern':DATASET_CODE_PATTERN};export const CODE_FLAG_OPTIONAL={...CODE_FLAG,'required':![]};export const DATASETCODE_FLAG_OPTIONAL={...CODE_FLAG_OPTIONAL,'name':a39_0x3b9a8f(0x78),'description':a39_0x3b9a8f(0x84)};export const SQLCODE_FLAG={'name':a39_0x3b9a8f(0x86),'type':a39_0x3b9a8f(0x87),'required':!![],'description':'SQL\x20code\x20identifier\x20(format:\x20xxxxxxxx-xxxxxxxx,\x20e.g.\x202305f915-dd48cd4c)','pattern':{'regex':/^[a-f0-9]{8}-[a-f0-9]{8}$/i,'description':a39_0x3b9a8f(0x85)}};export const APPCODE_FLAG_OPTIONAL={'name':a39_0x3b9a8f(0x81),'type':a39_0x3b9a8f(0x87),'required':![],'description':a39_0x3b9a8f(0x76)};export const SQLCODE_FLAG_OPTIONAL={...SQLCODE_FLAG,'required':![]};export const DBLINK_ID_FLAG={'name':'id','type':a39_0x3b9a8f(0x80),'required':!![],'description':a39_0x3b9a8f(0x83)};export const DB_TYPE_FLAG={'name':a39_0x3b9a8f(0x89),'type':a39_0x3b9a8f(0x87),'required':!![],'description':'Database\x20product\x20type','enum':[a39_0x3b9a8f(0x79),'POSTGRESQL']};
@@ -1 +1 @@
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
+ (function(_0x444198,_0x10d1ec){const _0x15d6e2=a40_0x41d9,_0x25bfc1=_0x444198();while(!![]){try{const _0x2234e9=parseInt(_0x15d6e2(0x1a8))/0x1*(-parseInt(_0x15d6e2(0x19f))/0x2)+parseInt(_0x15d6e2(0x19c))/0x3*(-parseInt(_0x15d6e2(0x1ab))/0x4)+-parseInt(_0x15d6e2(0x1a9))/0x5*(parseInt(_0x15d6e2(0x1aa))/0x6)+parseInt(_0x15d6e2(0x1a7))/0x7+parseInt(_0x15d6e2(0x19d))/0x8*(-parseInt(_0x15d6e2(0x1a3))/0x9)+parseInt(_0x15d6e2(0x19e))/0xa*(parseInt(_0x15d6e2(0x199))/0xb)+-parseInt(_0x15d6e2(0x1a1))/0xc*(-parseInt(_0x15d6e2(0x19b))/0xd);if(_0x2234e9===_0x10d1ec)break;else _0x25bfc1['push'](_0x25bfc1['shift']());}catch(_0x391fd4){_0x25bfc1['push'](_0x25bfc1['shift']());}}}(a40_0x59a7,0xc05aa));function a40_0x59a7(){const _0x380b7a=['563717JMOFnB','test','195iWLWRg','235539qfBNQe','189288iMjgLW','10YMiLVH','7802DuONYy','Only\x20letters,\x20numbers,\x20-\x20and\x20_\x20are\x20allowed','1468812kjeoaq','App\x20Code\x20cannot\x20be\x20empty','189YtzSnq','App\x20Code\x20cannot\x20exceed\x20100\x20characters','trim','length','7432271XLGCzs','127fLvCiJ','640tXUVSt','21666LDCahp','36wecRlr'];a40_0x59a7=function(){return _0x380b7a;};return a40_0x59a7();}function a40_0x41d9(_0x4721b6,_0x48725c){_0x4721b6=_0x4721b6-0x199;const _0x59a76e=a40_0x59a7();let _0x41d970=_0x59a76e[_0x4721b6];return _0x41d970;}export function validateAppcode(_0x171a4e){const _0x212d27=a40_0x41d9,_0x475621=_0x171a4e[_0x212d27(0x1a5)]();if(!_0x475621)return{'valid':![],'message':_0x212d27(0x1a2)};if(_0x475621[_0x212d27(0x1a6)]>0x64)return{'valid':![],'message':_0x212d27(0x1a4)};if(!/^[A-Za-z0-9_-]+$/[_0x212d27(0x19a)](_0x475621))return{'valid':![],'message':_0x212d27(0x1a0)};return{'valid':!![]};}
@@ -1 +1 @@
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
+ const a41_0x1616cd=a41_0x12e0;function a41_0x3631(){const _0x4479aa=['1064970xFZFxU','Get\x20a\x20config\x20value\x20by\x20key','Key\x20not\x20found:\x20','key','object','65346IHofHc','409294bOtGgH','3536055LPxLqg','string','223592iBYHdy','appcode','13995938yPfOyE','45UwxigM','Missing\x20key.','read','\x20config\x20get\x20--key\x20<key>','1sHdCkj','config','4BOILNa','357bqzBVJ','validation','1892868jcPVyS','get'];a41_0x3631=function(){return _0x4479aa;};return a41_0x3631();}(function(_0x33f138,_0x3ca396){const _0x433aae=a41_0x12e0,_0x13f2e0=_0x33f138();while(!![]){try{const _0x2dc46f=parseInt(_0x433aae(0x1ab))/0x1*(parseInt(_0x433aae(0x1b8))/0x2)+parseInt(_0x433aae(0x1b0))/0x3*(-parseInt(_0x433aae(0x1ad))/0x4)+-parseInt(_0x433aae(0x1a2))/0x5+parseInt(_0x433aae(0x1b7))/0x6*(parseInt(_0x433aae(0x1ae))/0x7)+-parseInt(_0x433aae(0x1a4))/0x8*(parseInt(_0x433aae(0x1a7))/0x9)+-parseInt(_0x433aae(0x1b2))/0xa+parseInt(_0x433aae(0x1a6))/0xb;if(_0x2dc46f===_0x3ca396)break;else _0x13f2e0['push'](_0x13f2e0['shift']());}catch(_0x182c4d){_0x13f2e0['push'](_0x13f2e0['shift']());}}}(a41_0x3631,0x6d625));import{CliErrors}from'../../errors.js';import{readConfig}from'../../utils/config.js';import{CLI_BIN_NAME}from'../../constant/cli.js';function a41_0x12e0(_0x1db730,_0x3d71ca){_0x1db730=_0x1db730-0x1a2;const _0x3631e3=a41_0x3631();let _0x12e0ed=_0x3631e3[_0x1db730];return _0x12e0ed;}import{getConfigCommandKeyDescription}from'../../commands/config/shared.js';async function execute(_0x2c7698){const _0x5210b7=a41_0x12e0,_0x3bd2a6=_0x2c7698['str'](_0x5210b7(0x1b5));if(!_0x3bd2a6)throw CliErrors[_0x5210b7(0x1af)](_0x5210b7(0x1a8),'Usage:\x20'+CLI_BIN_NAME+_0x5210b7(0x1aa));const _0x295b4e=readConfig(),_0x3df51a=_0x3bd2a6==='app'?_0x5210b7(0x1a5):_0x3bd2a6,_0x5be059=_0x295b4e[_0x3df51a];if(_0x5be059===undefined)throw CliErrors['validation'](_0x5210b7(0x1b4)+_0x3bd2a6);return{'ok':!![],'data':typeof _0x5be059===_0x5210b7(0x1b6)?_0x5be059:{[_0x3df51a]:_0x5be059},'message':typeof _0x5be059===_0x5210b7(0x1b6)?undefined:String(_0x5be059)};}export const configGetDefinition={'service':a41_0x1616cd(0x1ac),'command':a41_0x1616cd(0x1b1),'description':a41_0x1616cd(0x1b3),'risk':a41_0x1616cd(0x1a9),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':'key','type':a41_0x1616cd(0x1a3),'description':getConfigCommandKeyDescription(),'required':!![]}],'execute':execute};
@@ -1 +1 @@
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
+ (function(_0x17b9a1,_0x26eae0){const _0x1ebcd1=a42_0x348b,_0x7086f5=_0x17b9a1();while(!![]){try{const _0x599bb1=parseInt(_0x1ebcd1(0x90))/0x1*(-parseInt(_0x1ebcd1(0x99))/0x2)+parseInt(_0x1ebcd1(0x97))/0x3+-parseInt(_0x1ebcd1(0x96))/0x4*(parseInt(_0x1ebcd1(0x92))/0x5)+parseInt(_0x1ebcd1(0x95))/0x6*(parseInt(_0x1ebcd1(0x93))/0x7)+parseInt(_0x1ebcd1(0x91))/0x8+parseInt(_0x1ebcd1(0x94))/0x9*(-parseInt(_0x1ebcd1(0x8f))/0xa)+parseInt(_0x1ebcd1(0x98))/0xb;if(_0x599bb1===_0x26eae0)break;else _0x7086f5['push'](_0x7086f5['shift']());}catch(_0x41691e){_0x7086f5['push'](_0x7086f5['shift']());}}}(a42_0x3312,0xb93bd));import{configListDefinition}from'../../commands/config/list.js';import{configGetDefinition}from'../../commands/config/get.js';function a42_0x348b(_0x45cd3e,_0x193198){_0x45cd3e=_0x45cd3e-0x8f;const _0x33123e=a42_0x3312();let _0x348b1f=_0x33123e[_0x45cd3e];return _0x348b1f;}function a42_0x3312(){const _0x565a57=['552710CKCCHq','45837apKPnC','2331256UhIKOh','5RjwKwG','1113kdHery','36ROlMWx','26484XbVaCf','4599676NfOdov','2522763JjWIuj','4259640mKIPop','4GZryDM'];a42_0x3312=function(){return _0x565a57;};return a42_0x3312();}import{configSetDefinition}from'../../commands/config/set.js';export const configDefinitions=[configListDefinition,configGetDefinition,configSetDefinition];
@@ -1 +1 @@
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
+ const a43_0x27b097=a43_0x3765;(function(_0x5677eb,_0x406a3b){const _0x325452=a43_0x3765,_0x270cd9=_0x5677eb();while(!![]){try{const _0x2e58af=-parseInt(_0x325452(0x10a))/0x1+parseInt(_0x325452(0x110))/0x2*(parseInt(_0x325452(0x10c))/0x3)+-parseInt(_0x325452(0x107))/0x4+parseInt(_0x325452(0x106))/0x5*(-parseInt(_0x325452(0x10f))/0x6)+-parseInt(_0x325452(0x105))/0x7+parseInt(_0x325452(0x111))/0x8*(parseInt(_0x325452(0x104))/0x9)+parseInt(_0x325452(0x103))/0xa;if(_0x2e58af===_0x406a3b)break;else _0x270cd9['push'](_0x270cd9['shift']());}catch(_0x1e734f){_0x270cd9['push'](_0x270cd9['shift']());}}}(a43_0x3c60,0x7575d));function a43_0x3c60(){const _0x92a490=['9VnukIO','4292841JrQloj','15MCObkn','1572416FvgAZm','list','global','670271YiVHpz','Show\x20global\x20config\x20only\x20(~/.rabetbase.json)','2726007XGBSJs','List\x20all\x20config\x20values','read','1102086qzRSsM','2eNibzc','4196816jwnXRw','12755270nZmJnc'];a43_0x3c60=function(){return _0x92a490;};return a43_0x3c60();}import{readScopedConfig}from'../../commands/config/shared.js';function a43_0x3765(_0x39a73d,_0x2a86a4){_0x39a73d=_0x39a73d-0x103;const _0x3c60bb=a43_0x3c60();let _0x376577=_0x3c60bb[_0x39a73d];return _0x376577;}import{readConfig}from'../../utils/config.js';async function execute(_0x93c8b7){const _0x364c40=a43_0x3765,_0x3dcf64=_0x93c8b7['bool'](_0x364c40(0x109))?readScopedConfig('global'):readConfig();return{'ok':!![],'data':_0x3dcf64};}export const configListDefinition={'service':'config','command':a43_0x27b097(0x108),'description':a43_0x27b097(0x10d),'risk':a43_0x27b097(0x10e),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':a43_0x27b097(0x109),'type':'boolean','description':a43_0x27b097(0x10b),'default':![]}],'execute':execute};
@@ -1 +1 @@
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
+ const a44_0xb5e21a=a44_0x2822;function a44_0xf53d(){const _0x2f0ce4=['str','boolean','Missing\x20key.','appcode','5hpCodS','92906PgZizp','config','global','Cannot\x20set\x20top-level\x20\x22appcode\x22\x20when\x20multi-app\x20config\x20already\x20exists.','Missing\x20value.','key','value','join','\x22\x20is\x20not\x20settable.','\x20(stored\x20as\x20apps\x20+\x20defaultApp)','Invalid\x20value\x20for\x20\x22','\x20app\x20use\x20<name>`,\x20or\x20pass\x20`--appcode`\x20on\x20the\x20command.','Use\x20`','Legacy\x20alias\x20\x22online\x22\x20is\x20accepted\x20and\x20stored\x20as\x20production.','2697472twVQoH','includes','locale','validation','9681512nnfeGs','Write\x20to\x20global\x20config\x20(~/.rabetbase.json)','Usage:\x20','length','bool','Invalid\x20locale\x20value.','\x20set\x20to:\x20','Config\x20value\x20is\x20invalid\x20or\x20too\x20long.','1278063jICyqj','\x22.\x20Allowed:\x20','37CSUtvG','Config\x20value','set','Global','env','app','Supported:\x20zh,\x20en,\x20zh-CN,\x20en-US','write','Settable\x20top-level\x20keys:\x20','Set\x20a\x20config\x20value','4737084uvdStv','`,\x20`','1506001AuwfgL','Project','apps','Top-level\x20key\x20\x22','keys','672378XqFFZS','Invalid\x20value\x20for\x20env.\x20Allowed:\x20production,\x20daily.','\x20appcode\x20set\x20to:\x20','string'];a44_0xf53d=function(){return _0x2f0ce4;};return a44_0xf53d();}(function(_0xb8de7e,_0x5381ee){const _0x1b3823=a44_0x2822,_0x2222c2=_0xb8de7e();while(!![]){try{const _0xf083f5=parseInt(_0x1b3823(0x130))/0x1*(parseInt(_0x1b3823(0x14a))/0x2)+-parseInt(_0x1b3823(0x13a))/0x3+-parseInt(_0x1b3823(0x122))/0x4+-parseInt(_0x1b3823(0x149))/0x5*(-parseInt(_0x1b3823(0x141))/0x6)+parseInt(_0x1b3823(0x13c))/0x7+parseInt(_0x1b3823(0x126))/0x8+-parseInt(_0x1b3823(0x12e))/0x9;if(_0xf083f5===_0x5381ee)break;else _0x2222c2['push'](_0x2222c2['shift']());}catch(_0x391620){_0x2222c2['push'](_0x2222c2['shift']());}}}(a44_0xf53d,0xd2251));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';function a44_0x2822(_0x283274,_0x17333c){_0x283274=_0x283274-0x118;const _0xf53d6a=a44_0xf53d();let _0x2822ef=_0xf53d6a[_0x283274];return _0x2822ef;}import{normalizeEnv,isProduction,isDaily}from'../../constant/env.js';async function execute(_0x3802cb){const _0x5bad62=a44_0x2822,_0x25b379=_0x3802cb['str'](_0x5bad62(0x119)),_0x608b71=_0x3802cb[_0x5bad62(0x145)](_0x5bad62(0x11a));if(!_0x25b379)throw CliErrors[_0x5bad62(0x125)](_0x5bad62(0x147),_0x5bad62(0x128)+CLI_BIN_NAME+'\x20config\x20set\x20--key\x20<key>\x20--value\x20<value>');if(_0x608b71===undefined||_0x608b71==='')throw CliErrors[_0x5bad62(0x125)](_0x5bad62(0x118),'Usage:\x20'+CLI_BIN_NAME+'\x20config\x20set\x20--key\x20<key>\x20--value\x20<value>');if(_0x608b71[_0x5bad62(0x129)]>0x1f4)throw CliErrors['validation'](_0x5bad62(0x12d));if(!isTopLevelConfigKey(_0x25b379))throw CliErrors['validation'](_0x5bad62(0x13f)+_0x25b379+_0x5bad62(0x11c),_0x5bad62(0x138)+getTopLevelConfigKeySummary());if(_0x25b379==='riskLevel')throw CliErrors[_0x5bad62(0x125)]('\x22riskLevel\x22\x20cannot\x20be\x20changed\x20via\x20the\x20CLI.');if(CONFIG_ENUM_VALUES[_0x25b379]&&!CONFIG_ENUM_VALUES[_0x25b379][_0x5bad62(0x123)](_0x608b71))throw CliErrors[_0x5bad62(0x125)](_0x5bad62(0x11e)+_0x25b379+_0x5bad62(0x12f)+CONFIG_ENUM_VALUES[_0x25b379][_0x5bad62(0x11b)](',\x20'));if(_0x25b379===_0x5bad62(0x124)&&!normalizeLocale(_0x608b71))throw CliErrors[_0x5bad62(0x125)](_0x5bad62(0x12b),_0x5bad62(0x136));const _0x330b54={'global':_0x3802cb[_0x5bad62(0x12a)]('global')},_0x448e1c=resolveWriteScope(_0x330b54),_0x59a8f4=readScopedConfig(_0x448e1c);let _0x5bfe0f=_0x25b379,_0x5dd67d=_0x608b71;_0x25b379==='app'&&(_0x5bfe0f=_0x5bad62(0x148),delete _0x59a8f4[_0x5bad62(0x135)]);_0x25b379===_0x5bad62(0x124)&&(_0x5dd67d=normalizeLocale(_0x608b71));if(_0x25b379===_0x5bad62(0x134)){_0x5dd67d=normalizeEnv(_0x608b71);if(!isProduction(_0x5dd67d)&&!isDaily(_0x5dd67d))throw CliErrors[_0x5bad62(0x125)](_0x5bad62(0x142),_0x5bad62(0x121));}if(_0x25b379===_0x5bad62(0x148)){const _0x4dd835=_0x59a8f4[_0x5bad62(0x13e)]&&typeof _0x59a8f4['apps']==='object'?Object[_0x5bad62(0x140)](_0x59a8f4[_0x5bad62(0x13e)]):[];if(_0x4dd835[_0x5bad62(0x129)]>0x0)throw CliErrors[_0x5bad62(0x125)](_0x5bad62(0x14d),_0x5bad62(0x120)+CLI_BIN_NAME+'\x20app\x20add\x20<name>\x20--appcode\x20'+_0x5dd67d+_0x5bad62(0x13b)+CLI_BIN_NAME+_0x5bad62(0x11f));const _0x3aeb01=buildCanonicalProjectConfig({..._0x59a8f4},{'appCodes':[_0x5dd67d],'env':typeof _0x59a8f4['env']===_0x5bad62(0x144)?_0x59a8f4[_0x5bad62(0x134)]:undefined});writeScopedConfig(_0x3aeb01,_0x448e1c);const _0x1493ff=_0x448e1c===_0x5bad62(0x14c)?_0x5bad62(0x133):_0x5bad62(0x13d);return{'ok':!![],'message':'✓\x20'+_0x1493ff+_0x5bad62(0x143)+_0x5dd67d+_0x5bad62(0x11d)};}_0x59a8f4[_0x5bfe0f]=_0x5dd67d,writeScopedConfig(_0x59a8f4,_0x448e1c);const _0x8bd1bc=_0x448e1c===_0x5bad62(0x14c)?'Global':_0x5bad62(0x13d);return{'ok':!![],'message':'✓\x20'+_0x8bd1bc+'\x20'+_0x5bfe0f+_0x5bad62(0x12c)+_0x5dd67d};}export const configSetDefinition={'service':a44_0xb5e21a(0x14b),'command':a44_0xb5e21a(0x132),'description':a44_0xb5e21a(0x139),'risk':a44_0xb5e21a(0x137),'requiresAuth':![],'requiresAppCode':![],'flags':[{'name':'key','type':'string','description':getConfigCommandKeyDescription(),'required':!![]},{'name':a44_0xb5e21a(0x11a),'type':'string','description':a44_0xb5e21a(0x131),'required':!![]},{'name':a44_0xb5e21a(0x14c),'type':a44_0xb5e21a(0x146),'description':a44_0xb5e21a(0x127),'default':![]}],'execute':execute};
@@ -1 +1 @@
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
+ function a45_0x1d6b(_0x4adf63,_0x1be6c5){_0x4adf63=_0x4adf63-0x159;var _0x482459=a45_0x4824();var _0x1d6bce=_0x482459[_0x4adf63];return _0x1d6bce;}(function(_0x4ce8bd,_0x361628){var _0x5612d0=a45_0x1d6b,_0x1eb157=_0x4ce8bd();while(!![]){try{var _0xd3c65d=-parseInt(_0x5612d0(0x166))/0x1*(parseInt(_0x5612d0(0x15c))/0x2)+-parseInt(_0x5612d0(0x159))/0x3*(-parseInt(_0x5612d0(0x15f))/0x4)+parseInt(_0x5612d0(0x163))/0x5+parseInt(_0x5612d0(0x15e))/0x6+parseInt(_0x5612d0(0x161))/0x7*(-parseInt(_0x5612d0(0x160))/0x8)+-parseInt(_0x5612d0(0x15d))/0x9+-parseInt(_0x5612d0(0x167))/0xa*(-parseInt(_0x5612d0(0x15a))/0xb);if(_0xd3c65d===_0x361628)break;else _0x1eb157['push'](_0x1eb157['shift']());}catch(_0x15f8e2){_0x1eb157['push'](_0x1eb157['shift']());}}}(a45_0x4824,0x53346));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(_0x49a596){var _0x3e6a1f=a45_0x1d6b;if(_0x49a596[_0x3e6a1f(0x15b)])return'global';if(!isInProject())throw CliErrors[_0x3e6a1f(0x165)]('Not\x20inside\x20a\x20project\x20(no\x20.rabetbase.json\x20found).',_0x3e6a1f(0x164)+CLI_BIN_NAME+_0x3e6a1f(0x162));return'project';}function a45_0x4824(){var _0x1bd188=['104GRHNUO','1329976xLHdbx','7UpKjYD','\x20init`\x20first.','1864635hBkiRO','Add\x20--global\x20to\x20write\x20to\x20~/.rabetbase.json,\x20or\x20run\x20`','validation','35HKdaAD','1669580PNcfHH','11265BqRoKE','44irroSm','global','4484nGkFAE','5013585duzrHe','25194yghZXt'];a45_0x4824=function(){return _0x1bd188;};return a45_0x4824();}export function readScopedConfig(_0x2f987c){return readConfigFile(resolveWriteConfigPath(_0x2f987c));}export function writeScopedConfig(_0x38b10b,_0x3d2830){writeConfigFile(resolveWriteConfigPath(_0x3d2830),_0x38b10b);}
@@ -1 +1 @@
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
+ const a46_0x3f0812=a46_0x113b;function a46_0x273d(){const _0x5a364f=['\x20\x20JSON\x20BODY\x20FIELDS\x20(pass\x20inside\x20--params)','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','join','3176YnmaSx','5988dmatfZ','\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}]','222141BmocvT','Filter\x20dataset\x20records\x20with\x20query\x20conditions','784wRSpdo','7040646OTiYtE','496JydUeG','\x20\x20\x20\x20where\x20\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Query\x20conditions','741225kqojQm','3136278tvSTKe','filter','\x20\x20\x20\x20pageSize\x20\x20\x20\x20\x20\x20Number\x20\x20\x20Records\x20per\x20page','24786SxMhYb'];a46_0x273d=function(){return _0x5a364f;};return a46_0x273d();}(function(_0x3b8f2a,_0x4f8390){const _0x487710=a46_0x113b,_0x5d695c=_0x3b8f2a();while(!![]){try{const _0x3be4a6=parseInt(_0x487710(0x10f))/0x1+-parseInt(_0x487710(0x108))/0x2+parseInt(_0x487710(0x10d))/0x3*(-parseInt(_0x487710(0x102))/0x4)+parseInt(_0x487710(0x104))/0x5+-parseInt(_0x487710(0x105))/0x6+parseInt(_0x487710(0x100))/0x7*(-parseInt(_0x487710(0x10c))/0x8)+parseInt(_0x487710(0x101))/0x9;if(_0x3be4a6===_0x4f8390)break;else _0x5d695c['push'](_0x5d695c['shift']());}catch(_0x3b3642){_0x5d695c['push'](_0x5d695c['shift']());}}}(a46_0x273d,0x4f7e6));function a46_0x113b(_0x4eb904,_0x5ba4c2){_0x4eb904=_0x4eb904-0xff;const _0x273dd8=a46_0x273d();let _0x113bb0=_0x273dd8[_0x4eb904];return _0x113bb0;}import{buildDataCommand}from'../../commands/data/shared.js';export const dataFilter=buildDataCommand({'command':a46_0x3f0812(0x106),'operation':a46_0x3f0812(0x106),'description':a46_0x3f0812(0xff),'paramsRequired':![],'paramsHint':a46_0x3f0812(0x10a),'helpExtra':[a46_0x3f0812(0x109),a46_0x3f0812(0x103),'\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_0x3f0812(0x10e),'\x20\x20\x20\x20currentPage\x20\x20\x20Number\x20\x20\x20Page\x20number\x20(starts\x20from\x201)',a46_0x3f0812(0x107)][a46_0x3f0812(0x10b)]('\x0a')});
@@ -1 +1 @@
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
+ const a47_0x589bbc=a47_0x2ca0;(function(_0x12284d,_0x5950ef){const _0x1502aa=a47_0x2ca0,_0x3e0e8a=_0x12284d();while(!![]){try{const _0x1ccafd=parseInt(_0x1502aa(0x161))/0x1+parseInt(_0x1502aa(0x160))/0x2*(-parseInt(_0x1502aa(0x158))/0x3)+parseInt(_0x1502aa(0x15b))/0x4*(parseInt(_0x1502aa(0x156))/0x5)+parseInt(_0x1502aa(0x155))/0x6+-parseInt(_0x1502aa(0x15c))/0x7*(parseInt(_0x1502aa(0x159))/0x8)+-parseInt(_0x1502aa(0x15f))/0x9*(parseInt(_0x1502aa(0x15d))/0xa)+parseInt(_0x1502aa(0x15a))/0xb;if(_0x1ccafd===_0x5950ef)break;else _0x3e0e8a['push'](_0x3e0e8a['shift']());}catch(_0x1ab165){_0x3e0e8a['push'](_0x3e0e8a['shift']());}}}(a47_0x3949,0x92270));import{buildDataCommand}from'../../commands/data/shared.js';function a47_0x2ca0(_0x42bbe2,_0x1d21d6){_0x42bbe2=_0x42bbe2-0x155;const _0x3949d3=a47_0x3949();let _0x2ca0d6=_0x3949d3[_0x42bbe2];return _0x2ca0d6;}function a47_0x3949(){const _0x45631a=['33vkhReI','242136QiCNEl','18207783OdzxiN','524QBlKDV','203tIVCkl','10tGjrSH','getOne','8774622tElizl','51088xrFctl','588730WTUtTB','1815504lOgJmt','7090oXwPKW','Get\x20a\x20single\x20record\x20by\x20ID'];a47_0x3949=function(){return _0x45631a;};return a47_0x3949();}export const dataGetOne=buildDataCommand({'command':a47_0x589bbc(0x15e),'operation':a47_0x589bbc(0x15e),'description':a47_0x589bbc(0x157),'paramsRequired':!![],'paramsHint':'JSON\x20with\x20record\x20id.\x20Example:\x20\x27{\x22id\x22:123}\x27'});
@@ -1 +1 @@
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
+ function a48_0xd0f9(_0x59bb28,_0x86cde5){_0x59bb28=_0x59bb28-0x1d1;const _0x5b53c2=a48_0x5b53();let _0xd0f9e6=_0x5b53c2[_0x59bb28];return _0xd0f9e6;}(function(_0x1883c8,_0x243a0f){const _0x1ab19c=a48_0xd0f9,_0x1c3bff=_0x1883c8();while(!![]){try{const _0x438c19=parseInt(_0x1ab19c(0x1d5))/0x1*(parseInt(_0x1ab19c(0x1d3))/0x2)+-parseInt(_0x1ab19c(0x1da))/0x3*(-parseInt(_0x1ab19c(0x1d8))/0x4)+parseInt(_0x1ab19c(0x1d4))/0x5+-parseInt(_0x1ab19c(0x1d7))/0x6+parseInt(_0x1ab19c(0x1d1))/0x7+-parseInt(_0x1ab19c(0x1d6))/0x8*(parseInt(_0x1ab19c(0x1d9))/0x9)+parseInt(_0x1ab19c(0x1d2))/0xa;if(_0x438c19===_0x243a0f)break;else _0x1c3bff['push'](_0x1c3bff['shift']());}catch(_0x5eefb4){_0x1c3bff['push'](_0x1c3bff['shift']());}}}(a48_0x5b53,0x575c0));function a48_0x5b53(){const _0x516941=['87NZWuHm','303905gUzlsn','4354100tkKDxF','2WjCZbL','1559345vCLOSo','237095iNqsWZ','477928NRZDwX','3362016jLixND','59040WTnzke','81pWvieq'];a48_0x5b53=function(){return _0x516941;};return a48_0x5b53();}import{dataFilter}from'../../commands/data/filter.js';import{dataGetOne}from'../../commands/data/getOne.js';export const dataDefinitions=[dataFilter,dataGetOne];
@@ -1 +1 @@
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
+ (function(_0x2ccbdb,_0x55e13b){const _0x22e736=a49_0x21c3,_0x39fb0d=_0x2ccbdb();while(!![]){try{const _0xad4421=parseInt(_0x22e736(0x70))/0x1*(-parseInt(_0x22e736(0x85))/0x2)+-parseInt(_0x22e736(0x6b))/0x3*(-parseInt(_0x22e736(0x72))/0x4)+-parseInt(_0x22e736(0x7f))/0x5*(parseInt(_0x22e736(0x75))/0x6)+-parseInt(_0x22e736(0x83))/0x7+-parseInt(_0x22e736(0x6f))/0x8*(-parseInt(_0x22e736(0x68))/0x9)+parseInt(_0x22e736(0x76))/0xa*(-parseInt(_0x22e736(0x7e))/0xb)+-parseInt(_0x22e736(0x71))/0xc*(-parseInt(_0x22e736(0x81))/0xd);if(_0xad4421===_0x55e13b)break;else _0x39fb0d['push'](_0x39fb0d['shift']());}catch(_0x1244b0){_0x39fb0d['push'](_0x39fb0d['shift']());}}}(a49_0x27a0,0xf3d60));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_0x27a0(){const _0x4a88f3=['10sbkSbL','compress','data\x20','params','data\x20getOne\x20requires\x20\x22id\x22\x20in\x20--params','code','\x20completed\x20in\x20','now','14803250BecVpC','42330tZgnJv','read','15223gCOClD','validation','6752767kfAFhG','Dataset\x20alias\x20defined\x20in\x20api.ts\x20(e.g.\x20order,\x20coupon).\x20Resolves\x20to\x20dataset\x20code\x20automatically','962018xiNKxi','alias','description','642609xcLHAr','string','flagMissing','60xgpLWM','command','Example:\x20--params\x20\x27{\x22id\x22:123}\x27','operation','80qvDqbd','4skKCJk','57108SgInXD','94060YmBCmr','paramsRequired','str','1080PoBKSV'];a49_0x27a0=function(){return _0x4a88f3;};return a49_0x27a0();}import{parseJsonParams}from'../../utils/params.js';function a49_0x21c3(_0x43f59f,_0x3d6623){_0x43f59f=_0x43f59f-0x66;const _0x27a081=a49_0x27a0();let _0x21c3d3=_0x27a081[_0x43f59f];return _0x21c3d3;}function assertGetOneId(_0x2a9662){const _0x655888=a49_0x21c3;if(!_0x2a9662)throw CliErrors[_0x655888(0x6a)](_0x655888(0x79),'Provide\x20--params\x20\x27{\x22id\x22:123}\x27\x20for\x20data\x20getOne.');const _0x5e69cd=_0x2a9662['id'];if(_0x5e69cd===undefined||_0x5e69cd===null||_0x5e69cd==='')throw CliErrors[_0x655888(0x82)](_0x655888(0x7a),_0x655888(0x6d));}function parseCommandParams(_0x83b7df){return parseJsonParams(_0x83b7df)??{};}export function buildDataCommand(_0xc569ec){const _0x8d2ec3=a49_0x21c3,_0x40c616=_0x8d2ec3(0x84);return{'service':'data','command':_0xc569ec[_0x8d2ec3(0x6c)],'description':_0xc569ec[_0x8d2ec3(0x67)],'risk':_0x8d2ec3(0x80),'defaultOutputFormat':_0x8d2ec3(0x77),'helpExtra':_0xc569ec['helpExtra'],'flags':[CODE_FLAG,APPCODE_FLAG_OPTIONAL,{'name':_0x8d2ec3(0x66),'type':_0x8d2ec3(0x69),'description':_0x40c616},{'name':_0x8d2ec3(0x79),'type':_0x8d2ec3(0x69),'description':_0xc569ec['paramsHint']}],async 'validate'(_0xd0dbfb){const _0x23a933=_0x8d2ec3,_0x245446=_0xd0dbfb[_0x23a933(0x74)](_0x23a933(0x79));if(_0xc569ec[_0x23a933(0x73)]&&!_0x245446)throw CliErrors['flagMissing']('params',_0xc569ec['paramsHint']);const _0x5d9922=parseJsonParams(_0x245446);_0xc569ec[_0x23a933(0x6e)]==='getOne'&&assertGetOneId(_0x5d9922);},async 'execute'(_0x5d883d){const _0x5863dd=_0x8d2ec3,_0x4d63c4=parseCommandParams(_0x5d883d[_0x5863dd(0x74)](_0x5863dd(0x79))),_0x12ebd7=Date[_0x5863dd(0x7d)](),_0x43a5d9=await executeDatasetDataOperation(_0x5d883d['appCode'],_0x5d883d[_0x5863dd(0x74)](_0x5863dd(0x7b)),_0xc569ec['operation'],_0x4d63c4),_0x25c0db=Date[_0x5863dd(0x7d)]()-_0x12ebd7;return{'ok':!![],'data':{'result':_0x43a5d9,'elapsed':_0x25c0db},'message':_0x5863dd(0x78)+_0xc569ec[_0x5863dd(0x6c)]+_0x5863dd(0x7c)+_0x25c0db+'ms'};}};}
@@ -1 +1 @@
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();}
1
+ const a50_0x24eec1=a50_0x3433;(function(_0x8537b2,_0x22f876){const _0x2bd68a=a50_0x3433,_0xadbbb7=_0x8537b2();while(!![]){try{const _0x28f02b=parseInt(_0x2bd68a(0x1dd))/0x1*(parseInt(_0x2bd68a(0x1e7))/0x2)+-parseInt(_0x2bd68a(0x1d8))/0x3+-parseInt(_0x2bd68a(0x1dc))/0x4+parseInt(_0x2bd68a(0x1ef))/0x5+-parseInt(_0x2bd68a(0x1e2))/0x6*(-parseInt(_0x2bd68a(0x1e8))/0x7)+parseInt(_0x2bd68a(0x1f3))/0x8+-parseInt(_0x2bd68a(0x1d5))/0x9;if(_0x28f02b===_0x22f876)break;else _0xadbbb7['push'](_0xadbbb7['shift']());}catch(_0x2c86b1){_0xadbbb7['push'](_0xadbbb7['shift']());}}}(a50_0x4c04,0xc3ae9));function a50_0x4c04(){const _0x27f828=['BFF\x20/\x20SQL\x20等研发态资产','dbtableConfig','Use\x20lovrabet\x20data\x20filter/getOne\x20for\x20real\x20runtime\x20records.','原因:该类研发态资产需要\x20DB\x20table、dbId、tableName\x20与数据库连接上下文,并深度依赖\x20SQL\x20执行链路。','如果只是查看运行态真实行数据,请切换到\x20lovrabet\x20CLI:','6169590umhmiV','\x20是\x20','validation','当前数据集\x20\x22','8591144mNRVlM','tableName','trim','dataset','lovrabet\x20data\x20filter\x20--code\x20<datasetCode>\x20--params\x20\x27<json>\x27\x20--format\x20compress','\x20的数据源。','15564618TFFfrY','source','join','3746679eyERfd','code','getOne','dbtable','545532DckTZm','1209979qWEfsA','lovrabet\x20data\x20getOne\x20--code\x20<datasetCode>\x20--params\x20\x27{\x22id\x22:123}\x27\x20--format\x20compress','object','dbId','datasetName','2390406wPkrvk','lovrabet','\x20类型,不适合作为\x20','datasetCode','请先将该数据集升级/迁移为\x20DB\x20table\x20数据集,再基于新的\x20dataset\x20code\x20继续开发。','2EcZsUl','7tVNoLE','filter'];a50_0x4c04=function(){return _0x27f828;};return a50_0x4c04();}import{CliErrors}from'../../errors.js';export const RUNTIME_DATA_ACCESS_COMMANDS={'cli':a50_0x24eec1(0x1e3),'filter':a50_0x24eec1(0x1d3),'getOne':a50_0x24eec1(0x1de)};export const RUNTIME_DATA_ACCESS_SUMMARY=a50_0x24eec1(0x1ec);function valueToString(_0x22b078){const _0x351159=a50_0x24eec1;return _0x22b078==null?'':String(_0x22b078)[_0x351159(0x1f5)]();}function getDatasetCode(_0x43758e){const _0x2a5962=a50_0x24eec1;return valueToString(_0x43758e[_0x2a5962(0x1d9)]??_0x43758e['modelCode']??_0x43758e['dataset']?.[_0x2a5962(0x1e5)]);}function getDatasetName(_0x240671){const _0x293323=a50_0x24eec1;return valueToString(_0x240671['name']??_0x240671['dataset']?.[_0x293323(0x1e1)])||'unknown';}function a50_0x3433(_0x4ba8ea,_0xf5c8fa){_0x4ba8ea=_0x4ba8ea-0x1d2;const _0x4c0483=a50_0x4c04();let _0x343385=_0x4c0483[_0x4ba8ea];return _0x343385;}function getDatasetSource(_0x5c5c9c){const _0x365ff8=a50_0x24eec1;return valueToString(_0x5c5c9c[_0x365ff8(0x1d6)]??_0x5c5c9c[_0x365ff8(0x1d2)]?.['sourceType'])['toUpperCase']();}function getDbtableConfig(_0x121355){const _0x16f5b7=a50_0x24eec1,_0x2ee001=_0x121355[_0x16f5b7(0x1eb)]??_0x121355[_0x16f5b7(0x1db)];return _0x2ee001&&typeof _0x2ee001===_0x16f5b7(0x1df)?_0x2ee001:{};}export function isDbBackedDataset(_0x5b27b8){const _0x2df0e4=a50_0x24eec1,_0x92205d=getDatasetSource(_0x5b27b8);if(_0x92205d==='METADATA')return![];const _0x3a0eea=getDbtableConfig(_0x5b27b8),_0x57daa0=_0x3a0eea[_0x2df0e4(0x1e0)]??_0x3a0eea['id'],_0x1b9140=valueToString(_0x3a0eea[_0x2df0e4(0x1f4)]??_0x5b27b8[_0x2df0e4(0x1f4)]??_0x5b27b8['dataset']?.['tableName']);return _0x57daa0!==undefined&&_0x57daa0!==null&&_0x1b9140['length']>0x0;}export function filterDbBackedDatasets(_0x4defb6){const _0x2c0613=a50_0x24eec1;return _0x4defb6[_0x2c0613(0x1e9)](_0x186cf1=>isDbBackedDataset(_0x186cf1));}export function buildDbTableUpgradeMessage(_0x1d20f1,_0x183faf=a50_0x24eec1(0x1ea)){const _0x1683a6=a50_0x24eec1,_0x445ed2=getDatasetSource(_0x1d20f1)||'UNKNOWN',_0x3f0958=getDatasetName(_0x1d20f1),_0x158841=getDatasetCode(_0x1d20f1),_0x3617c8=_0x158841?'\x20('+_0x158841+')':'';return[_0x1683a6(0x1f2)+_0x3f0958+'\x22'+_0x3617c8+_0x1683a6(0x1f0)+_0x445ed2+_0x1683a6(0x1e4)+_0x183faf+_0x1683a6(0x1d4),_0x1683a6(0x1ed),_0x1683a6(0x1e6),_0x1683a6(0x1ee)+RUNTIME_DATA_ACCESS_COMMANDS[_0x1683a6(0x1e9)]+';'+RUNTIME_DATA_ACCESS_COMMANDS[_0x1683a6(0x1da)]+'。'][_0x1683a6(0x1d7)]('\x20');}export function assertDatasetSupportsLocalDevelopment(_0x41cdee,_0x1fc12c){const _0x2cf86a=a50_0x24eec1;if(!isDbBackedDataset(_0x41cdee))throw CliErrors[_0x2cf86a(0x1f1)](buildDbTableUpgradeMessage(_0x41cdee,_0x1fc12c));}