@lovrabet/rabetbase-cli 2.3.14 → 2.3.15-beta.1

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 (263) hide show
  1. package/lib/api/api-doc.js +1 -1
  2. package/lib/api/fetch-model-list.js +1 -1
  3. package/lib/api/generate-api-file.js +1 -1
  4. package/lib/auth/auth-server-ui.js +1 -1
  5. package/lib/auth/auth-server.js +1 -1
  6. package/lib/auth/constant.js +1 -1
  7. package/lib/auth/get-cookie.js +1 -1
  8. package/lib/auth/get-session-user.js +1 -1
  9. package/lib/auth/is-session-valid.js +1 -1
  10. package/lib/auth/login-success-html.js +1 -1
  11. package/lib/auth/logout.js +1 -1
  12. package/lib/cli-flags.js +1 -1
  13. package/lib/cli.js +1 -1
  14. package/lib/commands/api/generate.js +1 -1
  15. package/lib/commands/api/index.js +1 -1
  16. package/lib/commands/api/list.js +1 -1
  17. package/lib/commands/api/pull.js +1 -1
  18. package/lib/commands/api/shared.js +1 -1
  19. package/lib/commands/app/add.js +1 -1
  20. package/lib/commands/app/index.js +1 -1
  21. package/lib/commands/app/list.js +1 -1
  22. package/lib/commands/app/remote-directory.js +1 -1
  23. package/lib/commands/app/remove.js +1 -1
  24. package/lib/commands/app/shared.js +1 -1
  25. package/lib/commands/app-config/delete.js +1 -1
  26. package/lib/commands/app-config/get.js +1 -1
  27. package/lib/commands/app-config/index.js +1 -1
  28. package/lib/commands/app-config/list.js +1 -1
  29. package/lib/commands/app-config/set.js +1 -1
  30. package/lib/commands/app-config/shared.js +1 -1
  31. package/lib/commands/auth/index.js +1 -1
  32. package/lib/commands/bff/create.js +1 -1
  33. package/lib/commands/bff/delete.js +1 -1
  34. package/lib/commands/bff/detail.js +1 -1
  35. package/lib/commands/bff/index.js +1 -1
  36. package/lib/commands/bff/list.js +1 -1
  37. package/lib/commands/bff/pull.js +1 -1
  38. package/lib/commands/bff/push.js +1 -1
  39. package/lib/commands/bff/status.js +1 -1
  40. package/lib/commands/cli-skill/index.js +1 -1
  41. package/lib/commands/cli-update.js +1 -1
  42. package/lib/commands/codegen/index.js +1 -1
  43. package/lib/commands/codegen/sdk.js +1 -1
  44. package/lib/commands/codegen/sql.js +1 -1
  45. package/lib/commands/common/app-registry.js +1 -1
  46. package/lib/commands/common/app-selector.js +1 -1
  47. package/lib/commands/common/async-task.js +1 -1
  48. package/lib/commands/common/dry-run.js +1 -1
  49. package/lib/commands/common/flags.js +1 -1
  50. package/lib/commands/common/local-file.js +1 -1
  51. package/lib/commands/common/validate.js +1 -1
  52. package/lib/commands/config/get.js +1 -1
  53. package/lib/commands/config/index.js +1 -1
  54. package/lib/commands/config/list.js +1 -1
  55. package/lib/commands/config/set.js +1 -1
  56. package/lib/commands/config/shared.js +1 -1
  57. package/lib/commands/data/filter.js +1 -1
  58. package/lib/commands/data/getOne.js +1 -1
  59. package/lib/commands/data/index.js +1 -1
  60. package/lib/commands/data/shared.js +1 -1
  61. package/lib/commands/dataset/business-group-update.js +1 -1
  62. package/lib/commands/dataset/capability.js +1 -1
  63. package/lib/commands/dataset/delete.js +1 -1
  64. package/lib/commands/dataset/detail.js +1 -1
  65. package/lib/commands/dataset/extend-update.js +1 -1
  66. package/lib/commands/dataset/field-update.js +1 -1
  67. package/lib/commands/dataset/generate.js +1 -1
  68. package/lib/commands/dataset/index.js +1 -1
  69. package/lib/commands/dataset/list.js +1 -1
  70. package/lib/commands/dataset/operations.js +1 -1
  71. package/lib/commands/dataset/relation-audit.js +1 -1
  72. package/lib/commands/dataset/relation-create.js +1 -1
  73. package/lib/commands/dataset/relation-delete.js +1 -1
  74. package/lib/commands/dataset/relation-shared.js +1 -1
  75. package/lib/commands/dataset/relation-update.js +1 -1
  76. package/lib/commands/dataset/relations.js +1 -1
  77. package/lib/commands/dataset/rename.js +1 -1
  78. package/lib/commands/dataset/restore.js +1 -1
  79. package/lib/commands/db/analysis-batching.js +1 -1
  80. package/lib/commands/db/analyze-batch-plan.js +1 -1
  81. package/lib/commands/db/analyze-cancel.js +1 -1
  82. package/lib/commands/db/analyze-start.js +1 -1
  83. package/lib/commands/db/analyze-status.js +1 -1
  84. package/lib/commands/db/create.js +1 -1
  85. package/lib/commands/db/delete.js +1 -1
  86. package/lib/commands/db/detail.js +1 -1
  87. package/lib/commands/db/diff.js +1 -1
  88. package/lib/commands/db/index.js +1 -1
  89. package/lib/commands/db/list.js +1 -1
  90. package/lib/commands/db/shared.js +1 -1
  91. package/lib/commands/db/tables.js +1 -1
  92. package/lib/commands/db/test.js +1 -1
  93. package/lib/commands/db/update.js +1 -1
  94. package/lib/commands/doctor.js +1 -1
  95. package/lib/commands/file/index.js +1 -1
  96. package/lib/commands/init/index.js +1 -1
  97. package/lib/commands/issue/index.js +1 -1
  98. package/lib/commands/issue/nudge.js +1 -1
  99. package/lib/commands/issue/report.js +1 -1
  100. package/lib/commands/issue/shared.js +1 -1
  101. package/lib/commands/logs/index.js +1 -1
  102. package/lib/commands/menu/asset-update.js +1 -1
  103. package/lib/commands/menu/delete.js +1 -1
  104. package/lib/commands/menu/external-link-create.js +1 -1
  105. package/lib/commands/menu/external-link-update.js +1 -1
  106. package/lib/commands/menu/group-create.js +1 -1
  107. package/lib/commands/menu/group-update.js +1 -1
  108. package/lib/commands/menu/index.js +1 -1
  109. package/lib/commands/menu/list.js +1 -1
  110. package/lib/commands/menu/move.js +1 -1
  111. package/lib/commands/menu/regroup-start.js +1 -1
  112. package/lib/commands/menu/shared/compare-table.js +1 -1
  113. package/lib/commands/menu/shared/delete-plan.js +1 -1
  114. package/lib/commands/menu/shared/facts.js +1 -1
  115. package/lib/commands/menu/shared/index.js +1 -1
  116. package/lib/commands/menu/shared/inquirer.js +1 -1
  117. package/lib/commands/menu/shared/local-pages.js +1 -1
  118. package/lib/commands/menu/shared/logic.js +1 -1
  119. package/lib/commands/menu/shared/mutations.js +1 -1
  120. package/lib/commands/menu/shared/service.js +1 -1
  121. package/lib/commands/menu/shared/sync-core.js +1 -1
  122. package/lib/commands/menu/shared/update-core.js +1 -1
  123. package/lib/commands/menu/shared/valid-url.js +1 -1
  124. package/lib/commands/menu/sync.js +1 -1
  125. package/lib/commands/notification/config-list.js +1 -1
  126. package/lib/commands/notification/index.js +1 -1
  127. package/lib/commands/ocr/index.js +1 -1
  128. package/lib/commands/page/generate-start.js +1 -1
  129. package/lib/commands/page/generate-status.js +1 -1
  130. package/lib/commands/page/index.js +1 -1
  131. package/lib/commands/page/pull.js +1 -1
  132. package/lib/commands/page/push.js +1 -1
  133. package/lib/commands/page/relation-audit.js +1 -1
  134. package/lib/commands/page/restore.js +1 -1
  135. package/lib/commands/page/shared.js +1 -1
  136. package/lib/commands/page/standard-page-status.js +1 -1
  137. package/lib/commands/page/sync.js +1 -1
  138. package/lib/commands/permit/index.js +1 -1
  139. package/lib/commands/permit/page-get.js +1 -1
  140. package/lib/commands/permit/page-set.js +1 -1
  141. package/lib/commands/permit/role-apis-set.js +1 -1
  142. package/lib/commands/permit/role-menus-set.js +1 -1
  143. package/lib/commands/permit/role-menus.js +1 -1
  144. package/lib/commands/permit/shared.js +1 -1
  145. package/lib/commands/project/create/enhanced-guided-create.js +1 -1
  146. package/lib/commands/project/create/format-elapsed.js +1 -1
  147. package/lib/commands/project/create/main.js +1 -1
  148. package/lib/commands/project/create/non-interactive.js +1 -1
  149. package/lib/commands/project/create/project-template-path.js +1 -1
  150. package/lib/commands/project/create/use-copy-project-template.js +1 -1
  151. package/lib/commands/project/create/use-format-code.js +1 -1
  152. package/lib/commands/project/create/use-install-dependencies.js +1 -1
  153. package/lib/commands/project/index.js +1 -1
  154. package/lib/commands/project/init.js +1 -1
  155. package/lib/commands/project/upgrade.js +1 -1
  156. package/lib/commands/registry.js +1 -1
  157. package/lib/commands/role/create.js +1 -1
  158. package/lib/commands/role/delete.js +1 -1
  159. package/lib/commands/role/detail.js +1 -1
  160. package/lib/commands/role/index.js +1 -1
  161. package/lib/commands/role/list.js +1 -1
  162. package/lib/commands/role/shared.js +1 -1
  163. package/lib/commands/role/update.js +1 -1
  164. package/lib/commands/role/user-add.js +1 -1
  165. package/lib/commands/role/user-remove.js +1 -1
  166. package/lib/commands/role/user-resolve.js +1 -1
  167. package/lib/commands/run/index.js +1 -1
  168. package/lib/commands/schema.js +1 -1
  169. package/lib/commands/sql/create.js +1 -1
  170. package/lib/commands/sql/delete.js +1 -1
  171. package/lib/commands/sql/detail.js +1 -1
  172. package/lib/commands/sql/exec.js +1 -1
  173. package/lib/commands/sql/index.js +1 -1
  174. package/lib/commands/sql/list.js +1 -1
  175. package/lib/commands/sql/pull.js +1 -1
  176. package/lib/commands/sql/push.js +1 -1
  177. package/lib/commands/sql/save.js +1 -1
  178. package/lib/commands/sql/shared.js +1 -1
  179. package/lib/commands/sql/status.js +1 -1
  180. package/lib/commands/sql/validate.js +1 -1
  181. package/lib/commands/task/index.js +1 -1
  182. package/lib/commands/task/status.js +1 -1
  183. package/lib/commands/workspace/add.js +1 -1
  184. package/lib/commands/workspace/index.js +1 -1
  185. package/lib/commands/workspace/remove.js +1 -1
  186. package/lib/config/schema.js +1 -1
  187. package/lib/constant/cdn.js +1 -1
  188. package/lib/constant/cli.js +1 -1
  189. package/lib/constant/defaults.js +1 -1
  190. package/lib/constant/domain.js +1 -1
  191. package/lib/constant/env.js +1 -1
  192. package/lib/constant/output.js +1 -1
  193. package/lib/constant/paths.js +1 -1
  194. package/lib/constant/risk.js +1 -1
  195. package/lib/context/app-resolver.js +1 -1
  196. package/lib/context/auth-resolver.js +1 -1
  197. package/lib/context/config-loader.js +1 -1
  198. package/lib/context.js +1 -1
  199. package/lib/core/alias-resolver.js +1 -1
  200. package/lib/core/api-client.js +1 -1
  201. package/lib/core/bff/config.js +1 -1
  202. package/lib/core/bff/file-system.js +1 -1
  203. package/lib/core/bff/hash.js +1 -1
  204. package/lib/core/bff/lock.js +1 -1
  205. package/lib/core/bff/utils.js +1 -1
  206. package/lib/core/db-resolver.js +1 -1
  207. package/lib/core/page/file-system.js +1 -1
  208. package/lib/core/page/hash.js +1 -1
  209. package/lib/core/page/lock.js +1 -1
  210. package/lib/core/sql-index-auditor.js +1 -1
  211. package/lib/core/sql-sync/config.js +1 -1
  212. package/lib/core/sql-sync/file-system.js +1 -1
  213. package/lib/core/sql-sync/hash.js +1 -1
  214. package/lib/core/sql-sync/lock.js +1 -1
  215. package/lib/core/sql-sync/utils.js +1 -1
  216. package/lib/core/sql-validator.js +1 -1
  217. package/lib/errors.js +1 -1
  218. package/lib/framework/build-all-flags.js +1 -1
  219. package/lib/framework/error-output.js +1 -1
  220. package/lib/framework/explicit-yes.js +1 -1
  221. package/lib/framework/flags.js +1 -1
  222. package/lib/framework/help.js +1 -1
  223. package/lib/framework/index.js +1 -1
  224. package/lib/framework/output.js +1 -1
  225. package/lib/framework/response.js +1 -1
  226. package/lib/framework/runner-alias.js +1 -1
  227. package/lib/framework/runner.js +1 -1
  228. package/lib/framework/schema-export.js +1 -1
  229. package/lib/framework/types.js +1 -1
  230. package/lib/generated/build-info.js +1 -1
  231. package/lib/help.js +1 -1
  232. package/lib/skills/main.js +1 -1
  233. package/lib/skills/npx-skills-add.js +1 -1
  234. package/lib/telemetry/cli-command-trace.js +1 -1
  235. package/lib/telemetry/cli-help-trace.js +1 -1
  236. package/lib/telemetry/ensure-cli-otel-config.js +1 -1
  237. package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
  238. package/lib/telemetry/send-cli-trace-log.js +1 -1
  239. package/lib/telemetry/send-platform-issue-collect-log.js +1 -1
  240. package/lib/utils/ai_config.js +1 -1
  241. package/lib/utils/apply-jq-filter.js +1 -1
  242. package/lib/utils/cdn-config.js +1 -1
  243. package/lib/utils/check-sdk-version.js +1 -1
  244. package/lib/utils/cli-version-check.js +1 -1
  245. package/lib/utils/cli-version-policy.js +1 -1
  246. package/lib/utils/config.js +1 -1
  247. package/lib/utils/copy-directory.js +1 -1
  248. package/lib/utils/entity-with-id.js +1 -1
  249. package/lib/utils/file-utils.js +1 -1
  250. package/lib/utils/guides-cdn.js +1 -1
  251. package/lib/utils/http-client.js +1 -1
  252. package/lib/utils/is-non-interactive.js +1 -1
  253. package/lib/utils/logger.js +1 -1
  254. package/lib/utils/params.js +1 -1
  255. package/lib/utils/platform.js +1 -1
  256. package/lib/utils/rules-cdn.js +1 -1
  257. package/lib/utils/sleep.js +1 -1
  258. package/lib/utils/template-replacer.js +1 -1
  259. package/lib/utils/update-notice.js +1 -1
  260. package/lib/utils/version.js +1 -1
  261. package/lib/utils/with-active-cookie.js +1 -1
  262. package/lib/utils/write-cli-side-channel.js +1 -1
  263. package/package.json +1 -1
@@ -1 +1 @@
1
- const a92_0x3a1dbd=a92_0x36a0;function a92_0x5c80(){const _0x24b53d=['******','New\x20description','dbparam','string','29387zBIsES','Current\x20or\x20replacement\x20password.\x20Required\x20when\x20the\x20server\x20returns\x20a\x20masked\x20password','Invalid\x20--dburl:\x20expected\x20host:port,\x20got\x20\x22','validation','str','trim','num','10TNcrJR','4631292xjTvqg','POST','New\x20database\x20name','199984TqHhke','The\x20server\x20returned\x20a\x20masked\x20database\x20password.\x20Pass\x20the\x20current\x20or\x20replacement\x20password\x20explicitly\x20with\x20--password\x20to\x20update\x20this\x20connection\x20safely.','Update\x20a\x20database\x20connection\x20by\x20merging\x20supplied\x20fields\x20into\x20the\x20current\x20server\x20record.\x20A\x20masked\x20server\x20password\x20requires\x20explicit\x20--password','183192UlRmEO','password','--password\x20must\x20contain\x20the\x20real\x20database\x20password,\x20not\x20a\x20masked\x20value.','dbParam','has','dbUrl','dbname','/smartapi/dblink/update','157362MktWJg','dbdesc','929072qMjsVE','547461NPAOEz','username','42KwtJSC','New\x20connection\x20parameter\x20string','Updated\x20db\x20link\x20','New\x20host:port','dburl','New\x20username','10TmjBat'];a92_0x5c80=function(){return _0x24b53d;};return a92_0x5c80();}(function(_0x3e0f61,_0x5262c0){const _0x23c2ec=a92_0x36a0,_0x5e059f=_0x3e0f61();while(!![]){try{const _0x55316e=-parseInt(_0x23c2ec(0x90))/0x1+-parseInt(_0x23c2ec(0x78))/0x2+parseInt(_0x23c2ec(0x83))/0x3+-parseInt(_0x23c2ec(0x82))/0x4+-parseInt(_0x23c2ec(0x71))/0x5*(parseInt(_0x23c2ec(0x80))/0x6)+-parseInt(_0x23c2ec(0x85))/0x7*(parseInt(_0x23c2ec(0x75))/0x8)+parseInt(_0x23c2ec(0x72))/0x9*(parseInt(_0x23c2ec(0x8b))/0xa);if(_0x55316e===_0x5262c0)break;else _0x5e059f['push'](_0x5e059f['shift']());}catch(_0x2940ff){_0x5e059f['push'](_0x5e059f['shift']());}}}(a92_0x5c80,0x22846));import{getDbLinkInfo,updateDbLink}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{APPCODE_FLAG_OPTIONAL,DBLINK_ID_FLAG}from'../../commands/common/flags.js';import{sanitizeDbLinkForOutput,validateDbUrl}from'../../commands/db/shared.js';import{normalizeEntityWithIdResponse}from'../../utils/entity-with-id.js';const MASKED_PASSWORD_VALUES=new Set([a92_0x3a1dbd(0x8c),'[redacted]']);function a92_0x36a0(_0x480edd,_0x426944){_0x480edd=_0x480edd-0x6f;const _0x5c807b=a92_0x5c80();let _0x36a058=_0x5c807b[_0x480edd];return _0x36a058;}function mergeDbLinkUpdate(_0x31c8bd,_0x2f6c04){const _0x3d078a=a92_0x3a1dbd,_0x713ca8={..._0x31c8bd},_0x2fbcea=_0x2f6c04[_0x3d078a(0x94)]('password');if(_0x2fbcea&&MASKED_PASSWORD_VALUES[_0x3d078a(0x7c)](_0x2fbcea))throw CliErrors[_0x3d078a(0x93)](_0x3d078a(0x7a));if(!_0x2fbcea&&MASKED_PASSWORD_VALUES[_0x3d078a(0x7c)](String(_0x31c8bd[_0x3d078a(0x79)]??'')))throw CliErrors[_0x3d078a(0x93)](_0x3d078a(0x76));const _0x21c3af=_0x2f6c04['str'](_0x3d078a(0x7e));if(_0x21c3af)_0x713ca8['dbName']=_0x21c3af;const _0x50061e=_0x2f6c04[_0x3d078a(0x94)](_0x3d078a(0x89));if(_0x50061e)_0x713ca8[_0x3d078a(0x7d)]=_0x50061e[_0x3d078a(0x6f)]();const _0x1bccc4=_0x2f6c04[_0x3d078a(0x94)]('username');if(_0x1bccc4)_0x713ca8[_0x3d078a(0x84)]=_0x1bccc4;if(_0x2fbcea)_0x713ca8[_0x3d078a(0x79)]=_0x2fbcea;const _0x226440=_0x2f6c04['str'](_0x3d078a(0x8e));if(_0x226440)_0x713ca8[_0x3d078a(0x7b)]=_0x226440;const _0x2720e6=_0x2f6c04[_0x3d078a(0x94)](_0x3d078a(0x81));if(_0x2720e6)_0x713ca8['dbDesc']=_0x2720e6;return _0x713ca8;}export const dbUpdate={'service':'db','command':'update','description':a92_0x3a1dbd(0x77),'risk':'write','flags':[DBLINK_ID_FLAG,APPCODE_FLAG_OPTIONAL,{'name':a92_0x3a1dbd(0x7e),'type':a92_0x3a1dbd(0x8f),'description':a92_0x3a1dbd(0x74)},{'name':a92_0x3a1dbd(0x89),'type':'string','description':a92_0x3a1dbd(0x88)},{'name':a92_0x3a1dbd(0x84),'type':a92_0x3a1dbd(0x8f),'description':a92_0x3a1dbd(0x8a)},{'name':'password','type':a92_0x3a1dbd(0x8f),'description':a92_0x3a1dbd(0x91)},{'name':'dbparam','type':a92_0x3a1dbd(0x8f),'description':a92_0x3a1dbd(0x86)},{'name':'dbdesc','type':a92_0x3a1dbd(0x8f),'description':a92_0x3a1dbd(0x8d)}],async 'validate'(_0x345fc0){const _0x3a6068=a92_0x3a1dbd,_0x38942b=_0x345fc0[_0x3a6068(0x94)](_0x3a6068(0x89));if(_0x38942b&&!validateDbUrl(_0x38942b[_0x3a6068(0x6f)]()))throw CliErrors['validation'](_0x3a6068(0x92)+_0x38942b+'\x22');},async 'dryRun'(_0x582ac5){const _0x3ef5b0=a92_0x3a1dbd,_0x588388=_0x582ac5['num']('id'),_0x13fdbd=await getDbLinkInfo(_0x588388),_0x235c79=mergeDbLinkUpdate(_0x13fdbd,_0x582ac5),_0x716f03=sanitizeDbLinkForOutput(_0x235c79);return{'method':_0x3ef5b0(0x73),'url':_0x3ef5b0(0x7f),'body':_0x716f03,'description':'Merged\x20server\x20record\x20with\x20CLI\x20overrides;\x20password\x20redacted\x20in\x20preview'};},async 'execute'(_0xc579ac){const _0x2b099e=a92_0x3a1dbd,_0x460be3=_0xc579ac[_0x2b099e(0x70)]('id'),_0xd9e8bf=await getDbLinkInfo(_0x460be3),_0x1c12b2=mergeDbLinkUpdate(_0xd9e8bf,_0xc579ac),{id:_0x5f2058,entity:_0x1681b6}=normalizeEntityWithIdResponse(await updateDbLink(_0x1c12b2));return{'ok':!![],'data':sanitizeDbLinkForOutput(_0x1681b6),'message':_0x2b099e(0x87)+(_0x5f2058??_0x460be3)};}};
1
+ const a92_0x2841cf=a92_0x79d1;(function(_0x3afcbd,_0x40e383){const _0x480fc7=a92_0x79d1,_0x594de9=_0x3afcbd();while(!![]){try{const _0x282cab=-parseInt(_0x480fc7(0x1da))/0x1*(parseInt(_0x480fc7(0x1db))/0x2)+-parseInt(_0x480fc7(0x1e3))/0x3+parseInt(_0x480fc7(0x1cf))/0x4+parseInt(_0x480fc7(0x1c7))/0x5*(-parseInt(_0x480fc7(0x1de))/0x6)+parseInt(_0x480fc7(0x1d4))/0x7+-parseInt(_0x480fc7(0x1d7))/0x8+parseInt(_0x480fc7(0x1d0))/0x9;if(_0x282cab===_0x40e383)break;else _0x594de9['push'](_0x594de9['shift']());}catch(_0x5adbfe){_0x594de9['push'](_0x594de9['shift']());}}}(a92_0x396e,0x9af85));import{getDbLinkInfo,updateDbLink}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';function a92_0x396e(){const _0x2993e2=['Updated\x20db\x20link\x20','dburl','dbDesc','838350zRhAoT','string','dbparam','has','POST','str','num','9865mRpgGS','New\x20username','Update\x20a\x20database\x20connection\x20by\x20merging\x20supplied\x20fields\x20into\x20the\x20current\x20server\x20record.\x20A\x20masked\x20server\x20password\x20requires\x20explicit\x20--password','username','New\x20description','dbUrl','validation','Merged\x20server\x20record\x20with\x20CLI\x20overrides;\x20password\x20redacted\x20in\x20preview','3216588hQILOw','11184579FjyNSu','trim','write','Current\x20or\x20replacement\x20password.\x20Required\x20when\x20the\x20server\x20returns\x20a\x20masked\x20password','2053744DsbHAi','New\x20database\x20name','dbdesc','5620856HzIUHP','Invalid\x20--dburl:\x20expected\x20host:port,\x20got\x20\x22','The\x20server\x20returned\x20a\x20masked\x20database\x20password.\x20Pass\x20the\x20current\x20or\x20replacement\x20password\x20explicitly\x20with\x20--password\x20to\x20update\x20this\x20connection\x20safely.','425533pGcONg','2zYOAKs','dbname','New\x20connection\x20parameter\x20string','906YxmCvN','password'];a92_0x396e=function(){return _0x2993e2;};return a92_0x396e();}function a92_0x79d1(_0x45332f,_0x3a2518){_0x45332f=_0x45332f-0x1c3;const _0x396ea4=a92_0x396e();let _0x79d1b4=_0x396ea4[_0x45332f];return _0x79d1b4;}import{APPCODE_FLAG_OPTIONAL,DBLINK_ID_FLAG}from'../../commands/common/flags.js';import{sanitizeDbLinkForOutput,validateDbUrl}from'../../commands/db/shared.js';import{normalizeEntityWithIdResponse}from'../../utils/entity-with-id.js';const MASKED_PASSWORD_VALUES=new Set(['******','[redacted]']);function mergeDbLinkUpdate(_0xf958ed,_0x3212c8){const _0x14b903=a92_0x79d1,_0x49745b={..._0xf958ed},_0x451819=_0x3212c8[_0x14b903(0x1c5)]('password');if(_0x451819&&MASKED_PASSWORD_VALUES[_0x14b903(0x1c3)](_0x451819))throw CliErrors['validation']('--password\x20must\x20contain\x20the\x20real\x20database\x20password,\x20not\x20a\x20masked\x20value.');if(!_0x451819&&MASKED_PASSWORD_VALUES[_0x14b903(0x1c3)](String(_0xf958ed[_0x14b903(0x1df)]??'')))throw CliErrors[_0x14b903(0x1cd)](_0x14b903(0x1d9));const _0x4e249d=_0x3212c8['str'](_0x14b903(0x1dc));if(_0x4e249d)_0x49745b['dbName']=_0x4e249d;const _0x2119e0=_0x3212c8[_0x14b903(0x1c5)](_0x14b903(0x1e1));if(_0x2119e0)_0x49745b[_0x14b903(0x1cc)]=_0x2119e0[_0x14b903(0x1d1)]();const _0x5cb511=_0x3212c8['str']('username');if(_0x5cb511)_0x49745b['username']=_0x5cb511;if(_0x451819)_0x49745b[_0x14b903(0x1df)]=_0x451819;const _0x4b220a=_0x3212c8[_0x14b903(0x1c5)]('dbparam');if(_0x4b220a)_0x49745b['dbParam']=_0x4b220a;const _0x3b7c3c=_0x3212c8['str'](_0x14b903(0x1d6));if(_0x3b7c3c)_0x49745b[_0x14b903(0x1e2)]=_0x3b7c3c;return _0x49745b;}export const dbUpdate={'service':'db','command':'update','description':a92_0x2841cf(0x1c9),'risk':a92_0x2841cf(0x1d2),'flags':[DBLINK_ID_FLAG,APPCODE_FLAG_OPTIONAL,{'name':a92_0x2841cf(0x1dc),'type':'string','description':a92_0x2841cf(0x1d5)},{'name':a92_0x2841cf(0x1e1),'type':a92_0x2841cf(0x1e4),'description':'New\x20host:port'},{'name':a92_0x2841cf(0x1ca),'type':a92_0x2841cf(0x1e4),'description':a92_0x2841cf(0x1c8)},{'name':a92_0x2841cf(0x1df),'type':a92_0x2841cf(0x1e4),'description':a92_0x2841cf(0x1d3)},{'name':a92_0x2841cf(0x1e5),'type':a92_0x2841cf(0x1e4),'description':a92_0x2841cf(0x1dd)},{'name':'dbdesc','type':a92_0x2841cf(0x1e4),'description':a92_0x2841cf(0x1cb)}],async 'validate'(_0x5bca10){const _0x571f7f=a92_0x2841cf,_0x1469d0=_0x5bca10[_0x571f7f(0x1c5)](_0x571f7f(0x1e1));if(_0x1469d0&&!validateDbUrl(_0x1469d0['trim']()))throw CliErrors['validation'](_0x571f7f(0x1d8)+_0x1469d0+'\x22');},async 'dryRun'(_0x38df27){const _0x517033=a92_0x2841cf,_0x57f759=_0x38df27[_0x517033(0x1c6)]('id'),_0x22c81e=await getDbLinkInfo(_0x57f759),_0x5b4670=mergeDbLinkUpdate(_0x22c81e,_0x38df27),_0x535d7b=sanitizeDbLinkForOutput(_0x5b4670);return{'method':_0x517033(0x1c4),'url':'/smartapi/dblink/update','body':_0x535d7b,'description':_0x517033(0x1ce)};},async 'execute'(_0xfce181){const _0x27a702=a92_0x2841cf,_0x13089f=_0xfce181[_0x27a702(0x1c6)]('id'),_0x17fd6e=await getDbLinkInfo(_0x13089f),_0x2e87d9=mergeDbLinkUpdate(_0x17fd6e,_0xfce181),{id:_0x9e3a7d,entity:_0x457316}=normalizeEntityWithIdResponse(await updateDbLink(_0x2e87d9));return{'ok':!![],'data':sanitizeDbLinkForOutput(_0x457316),'message':_0x27a702(0x1e0)+(_0x9e3a7d??_0x13089f)};}};
@@ -1 +1 @@
1
- const a93_0x1a4e7e=a93_0x2f70;(function(_0x298ead,_0x4dc2b6){const _0x43b0b8=a93_0x2f70,_0x59188b=_0x298ead();while(!![]){try{const _0x37f669=parseInt(_0x43b0b8(0xbb))/0x1*(-parseInt(_0x43b0b8(0xd1))/0x2)+parseInt(_0x43b0b8(0xe1))/0x3+parseInt(_0x43b0b8(0xe7))/0x4+-parseInt(_0x43b0b8(0xf2))/0x5+parseInt(_0x43b0b8(0xd2))/0x6*(-parseInt(_0x43b0b8(0xea))/0x7)+-parseInt(_0x43b0b8(0xc5))/0x8*(-parseInt(_0x43b0b8(0xbd))/0x9)+parseInt(_0x43b0b8(0xc1))/0xa;if(_0x37f669===_0x4dc2b6)break;else _0x59188b['push'](_0x59188b['shift']());}catch(_0x1e1a83){_0x59188b['push'](_0x59188b['shift']());}}}(a93_0x395d,0x90c32));function a93_0x2f70(_0x4b4936,_0x2057ed){_0x4b4936=_0x4b4936-0xb8;const _0x395d89=a93_0x395d();let _0x2f7067=_0x395d89[_0x4b4936];return _0x2f7067;}import a93_0x4e12ce from'chalk';import{CLI_BIN_NAME}from'../constant/cli.js';import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';import{VERSION,GIT_COMMIT,BUILD_TIME}from'../generated/build-info.js';import{getApiDomain,getUserDomain,getRuntimeDomain}from'../constant/domain.js';import{getProjectConfigPath,getGlobalConfigPath,buildConfigFromFlags,inspectCliConfigJsonFile}from'../context.js';import{getIsSessionValid}from'../auth/is-session-valid.js';import{getCookie}from'../auth/get-cookie.js';function a93_0x395d(){const _0x5f5991=['3024892tdKWSz','(none)','apps','7YamlYC','accessKey','\x20\x20Apps','red','\x20\x20\x20\x20appcode:\x20\x20\x20\x20','raw','gray','read','5782860YkTNuk','value','\x20\x20Platform:\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20verbose:\x20\x20\x20\x20\x20\x20\x20\x20\x20','✗\x20Not\x20logged\x20in','✓\x20Valid','env','status','\x20←\x20current','\x20\x20env:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','green','repeat','\x20\x20apiDomain:\x20\x20\x20\x20\x20\x20\x20','cookie','(set\x20via\x20file,\x20length=','appCode','\x20\x20explicitAppName:\x20','verbose','\x20\x20\x20\x20apiDir:\x20\x20\x20\x20\x20','explicitAppName','\x20\x20\x20\x20accessKey:\x20\x20','\x20\x20\x20\x20cookie:\x20\x20\x20\x20\x20','\x20\x20Project:\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20defaultApp:\x20\x20\x20\x20\x20\x20','keys','\x20\x20Merged\x20Config','padEnd','5PaJsja','\x20\x20apiDir:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','27yHFTPU','\x20\x20Config\x20JSON','✗\x20Expired','apiDir','18752760VpkeHc','empty','(not\x20found)','format','1060272xmaFTu','riskLevel','missing','Global','\x20\x20─','Diagnose\x20CLI\x20configuration\x20and\x20connectivity','⚠\x20Empty\x20(treated\x20as\x20{})','bold','\x20\x20Status:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','unknown','message','\x20\x20cookie:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','432996VaGuaN','6373746AmlgDP','log','version','source','\x20doctor','\x20\x20runtimeDomain:\x20\x20\x20','defaultApp','(default:\x20','doctor','\x20\x20CLI\x20Version:\x20\x20\x20\x20\x20','✓\x20Valid\x20JSON','\x20\x20pageSize:\x20\x20\x20\x20\x20\x20\x20\x20','check','\x20\x20currentApp:\x20\x20\x20\x20\x20\x20','appcode','2595594bhcuRR','\x20\x20\x20\x20env:\x20\x20\x20\x20\x20\x20\x20\x20','currentApp','\x20(default)','(set,\x20length=','length'];a93_0x395d=function(){return _0x5f5991;};return a93_0x395d();}import{buildAppDoctorFields}from'../config/schema.js';async function execute(_0x3d2f2f){const _0xa5420f=a93_0x2f70,_0xef471f=GIT_COMMIT!==_0xa5420f(0xce)?VERSION+'\x20('+GIT_COMMIT+',\x20'+BUILD_TIME['slice'](0x0,0xa)+')':VERSION,_0x311593=buildConfigFromFlags({}),_0x4c760c=getCookie();console['log'](),console[_0xa5420f(0xd3)](a93_0x4e12ce[_0xa5420f(0xcc)](CLI_BIN_NAME+_0xa5420f(0xd6))),console[_0xa5420f(0xd3)](a93_0x4e12ce[_0xa5420f(0xf0)]('─'[_0xa5420f(0xfd)](0x32))),console[_0xa5420f(0xd3)](_0xa5420f(0xdb)+_0xef471f),console[_0xa5420f(0xd3)]('\x20\x20Node:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+process[_0xa5420f(0xd4)]),console[_0xa5420f(0xd3)](_0xa5420f(0xf4)+process['platform']+'\x20'+process['arch']),console[_0xa5420f(0xd3)](),console[_0xa5420f(0xd3)](a93_0x4e12ce[_0xa5420f(0xcc)]('\x20\x20Config\x20Files')),console[_0xa5420f(0xd3)](a93_0x4e12ce[_0xa5420f(0xf0)]('\x20\x20─'[_0xa5420f(0xfd)](0x1e)));const _0x497fb8=getGlobalConfigPath(),_0x22fb88=getProjectConfigPath();console[_0xa5420f(0xd3)]('\x20\x20Global:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+(_0x497fb8||a93_0x4e12ce[_0xa5420f(0xf0)](_0xa5420f(0xc3)))),console[_0xa5420f(0xd3)](_0xa5420f(0x108)+(_0x22fb88||a93_0x4e12ce[_0xa5420f(0xf0)]('(not\x20found)'))),console[_0xa5420f(0xd3)](),console[_0xa5420f(0xd3)](a93_0x4e12ce['bold'](_0xa5420f(0xbe))),console[_0xa5420f(0xd3)](a93_0x4e12ce[_0xa5420f(0xf0)]('\x20\x20─'[_0xa5420f(0xfd)](0x1e)));const _0x319668=(_0x2afa03,_0x33e8d0)=>{const _0x2f06e4=_0xa5420f;if(!_0x33e8d0){console[_0x2f06e4(0xd3)]('\x20\x20'+_0x2afa03[_0x2f06e4(0xba)](0x11)+'\x20'+a93_0x4e12ce[_0x2f06e4(0xf0)]('(no\x20file)'));return;}const _0x1bf963=inspectCliConfigJsonFile(_0x33e8d0);if(_0x1bf963[_0x2f06e4(0xf9)]==='ok')console[_0x2f06e4(0xd3)]('\x20\x20'+_0x2afa03[_0x2f06e4(0xba)](0x11)+'\x20'+a93_0x4e12ce['green'](_0x2f06e4(0xdc)));else{if(_0x1bf963[_0x2f06e4(0xf9)]===_0x2f06e4(0xc2))console[_0x2f06e4(0xd3)]('\x20\x20'+_0x2afa03['padEnd'](0x11)+'\x20'+a93_0x4e12ce['yellow'](_0x2f06e4(0xcb)));else _0x1bf963[_0x2f06e4(0xf9)]===_0x2f06e4(0xc7)?console[_0x2f06e4(0xd3)]('\x20\x20'+_0x2afa03[_0x2f06e4(0xba)](0x11)+'\x20'+a93_0x4e12ce[_0x2f06e4(0xf0)]('(missing)')):(console[_0x2f06e4(0xd3)]('\x20\x20'+_0x2afa03[_0x2f06e4(0xba)](0x11)+'\x20'+a93_0x4e12ce[_0x2f06e4(0xed)]('✗\x20Invalid\x20JSON')),console[_0x2f06e4(0xd3)]('\x20\x20'+''['padEnd'](0x11)+'\x20'+a93_0x4e12ce[_0x2f06e4(0xed)](_0x1bf963[_0x2f06e4(0xcf)])));}};_0x319668(_0xa5420f(0xc8),_0x497fb8),_0x319668('Project',_0x22fb88),console['log'](),console[_0xa5420f(0xd3)](a93_0x4e12ce['bold'](_0xa5420f(0xb9))),console['log'](a93_0x4e12ce[_0xa5420f(0xf0)](_0xa5420f(0xc9)['repeat'](0x1e))),console[_0xa5420f(0xd3)]('\x20\x20appCode:\x20\x20\x20\x20\x20\x20\x20\x20\x20'+(_0x311593[_0xa5420f(0x101)]||a93_0x4e12ce[_0xa5420f(0xed)]('(not\x20set)'))),console[_0xa5420f(0xd3)](_0xa5420f(0xfb)+_0x311593[_0xa5420f(0xf8)]),console[_0xa5420f(0xd3)]('\x20\x20locale:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x311593['locale']),console['log'](_0xa5420f(0xbc)+_0x311593[_0xa5420f(0xc0)]),console[_0xa5420f(0xd3)](_0xa5420f(0x109)+(_0x311593[_0xa5420f(0xd8)]||a93_0x4e12ce[_0xa5420f(0xf0)]('(none)'))),console[_0xa5420f(0xd3)](_0xa5420f(0xdf)+(_0x311593[_0xa5420f(0xe3)]||a93_0x4e12ce['gray']('(none)'))),console['log'](_0xa5420f(0x102)+(_0x311593[_0xa5420f(0x105)]||a93_0x4e12ce['gray'](_0xa5420f(0xe8)))),console[_0xa5420f(0xd3)]('\x20\x20format:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+(_0x311593[_0xa5420f(0xc4)]||a93_0x4e12ce[_0xa5420f(0xf0)](_0xa5420f(0xd9)+DEFAULT_CONFIG_VALUES[_0xa5420f(0xc4)]+')'))),console[_0xa5420f(0xd3)](_0xa5420f(0xdd)+(_0x311593['pageSize']??a93_0x4e12ce[_0xa5420f(0xf0)]('(default)'))),console[_0xa5420f(0xd3)]('\x20\x20riskLevel:\x20\x20\x20\x20\x20\x20\x20'+_0x311593[_0xa5420f(0xc6)]),console[_0xa5420f(0xd3)](_0xa5420f(0xf5)+_0x311593[_0xa5420f(0x103)]),console['log'](_0xa5420f(0xd0)+(_0x311593['cookie']?a93_0x4e12ce[_0xa5420f(0xfc)](_0xa5420f(0xe5)+_0x311593['cookie'][_0xa5420f(0xe6)]+')'):_0x4c760c?a93_0x4e12ce['green'](_0xa5420f(0x100)+_0x4c760c[_0xa5420f(0xe6)]+')'):a93_0x4e12ce[_0xa5420f(0xf0)](_0xa5420f(0xe8))));const _0x1a9cc6=Object[_0xa5420f(0xb8)](_0x311593[_0xa5420f(0xe9)]);if(_0x1a9cc6[_0xa5420f(0xe6)]>0x0){console[_0xa5420f(0xd3)](),console[_0xa5420f(0xd3)](a93_0x4e12ce['bold'](_0xa5420f(0xec))),console[_0xa5420f(0xd3)](a93_0x4e12ce['gray'](_0xa5420f(0xc9)['repeat'](0x1e)));for(const _0x415d10 of _0x1a9cc6){const _0x4f2911=_0x311593[_0xa5420f(0xe9)][_0x415d10],_0x161e4f=_0x415d10===_0x311593[_0xa5420f(0xd8)],_0x4cdc9f=_0x415d10===_0x311593['currentApp'],_0x2fba31=_0x4cdc9f?a93_0x4e12ce['green'](_0xa5420f(0xfa)):'',_0x4fa2a2=_0x161e4f?_0xa5420f(0xe4):'';console[_0xa5420f(0xd3)]('\x20\x20'+_0x415d10+_0x4fa2a2+_0x2fba31),console[_0xa5420f(0xd3)](_0xa5420f(0xee)+_0x4f2911[_0xa5420f(0xe0)]);const _0x1dee7f=buildAppDoctorFields(_0x4f2911,{'env':_0x311593[_0xa5420f(0xf8)],'apiDir':_0x311593[_0xa5420f(0xef)][_0xa5420f(0xc0)]||DEFAULT_CONFIG_VALUES['apiDir'],'cookie':_0x311593['cookie']||_0x4c760c||undefined,'accessKey':_0x311593[_0xa5420f(0xeb)]});console[_0xa5420f(0xd3)](_0xa5420f(0xe2)+_0x1dee7f[_0xa5420f(0xf8)][_0xa5420f(0xf3)]+'\x20\x20'+a93_0x4e12ce[_0xa5420f(0xf0)]('('+_0x1dee7f[_0xa5420f(0xf8)][_0xa5420f(0xd5)]+')')),console['log'](_0xa5420f(0x104)+_0x1dee7f['apiDir']['value']+'\x20\x20'+a93_0x4e12ce[_0xa5420f(0xf0)]('('+_0x1dee7f[_0xa5420f(0xc0)][_0xa5420f(0xd5)]+')'));const _0xc2a94b=_0x1dee7f[_0xa5420f(0xff)][_0xa5420f(0xf3)]?a93_0x4e12ce['green'](_0xa5420f(0xe5)+_0x1dee7f[_0xa5420f(0xff)][_0xa5420f(0xf3)][_0xa5420f(0xe6)]+')'):a93_0x4e12ce[_0xa5420f(0xf0)](_0xa5420f(0xe8));console[_0xa5420f(0xd3)](_0xa5420f(0x107)+_0xc2a94b+'\x20\x20'+a93_0x4e12ce[_0xa5420f(0xf0)]('('+_0x1dee7f['cookie'][_0xa5420f(0xd5)]+')'));const _0x57cf93=_0x1dee7f[_0xa5420f(0xeb)][_0xa5420f(0xf3)]?a93_0x4e12ce['green']('(set,\x20length='+_0x1dee7f[_0xa5420f(0xeb)][_0xa5420f(0xf3)][_0xa5420f(0xe6)]+')'):a93_0x4e12ce[_0xa5420f(0xf0)]('(none)');console['log'](_0xa5420f(0x106)+_0x57cf93+'\x20\x20'+a93_0x4e12ce[_0xa5420f(0xf0)]('('+_0x1dee7f[_0xa5420f(0xeb)][_0xa5420f(0xd5)]+')'));}}console[_0xa5420f(0xd3)](),console[_0xa5420f(0xd3)](a93_0x4e12ce[_0xa5420f(0xcc)]('\x20\x20API\x20Endpoints')),console[_0xa5420f(0xd3)](a93_0x4e12ce['gray'](_0xa5420f(0xc9)['repeat'](0x1e))),console[_0xa5420f(0xd3)](_0xa5420f(0xfe)+getApiDomain()),console[_0xa5420f(0xd3)]('\x20\x20userDomain:\x20\x20\x20\x20\x20\x20'+getUserDomain()),console[_0xa5420f(0xd3)](_0xa5420f(0xd7)+getRuntimeDomain()),console[_0xa5420f(0xd3)](),console[_0xa5420f(0xd3)](a93_0x4e12ce[_0xa5420f(0xcc)]('\x20\x20Auth')),console[_0xa5420f(0xd3)](a93_0x4e12ce['gray'](_0xa5420f(0xc9)[_0xa5420f(0xfd)](0x1e)));if(_0x4c760c){const _0x6ef2b6=await getIsSessionValid();console['log'](_0xa5420f(0xcd)+(_0x6ef2b6?a93_0x4e12ce[_0xa5420f(0xfc)](_0xa5420f(0xf7)):a93_0x4e12ce['red'](_0xa5420f(0xbf))));}else console[_0xa5420f(0xd3)]('\x20\x20Status:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+a93_0x4e12ce['red'](_0xa5420f(0xf6)));return console[_0xa5420f(0xd3)](),{'ok':!![]};}export const doctorDefinition={'service':a93_0x1a4e7e(0xda),'command':a93_0x1a4e7e(0xde),'description':a93_0x1a4e7e(0xca),'risk':a93_0x1a4e7e(0xf1),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],'execute':execute};
1
+ const a93_0x1412e9=a93_0x188e;(function(_0x4941c8,_0x28cd98){const _0x15dd73=a93_0x188e,_0x19e549=_0x4941c8();while(!![]){try{const _0x57deb1=parseInt(_0x15dd73(0x8c))/0x1+-parseInt(_0x15dd73(0xbe))/0x2+-parseInt(_0x15dd73(0xb4))/0x3*(parseInt(_0x15dd73(0x97))/0x4)+parseInt(_0x15dd73(0xae))/0x5+-parseInt(_0x15dd73(0x93))/0x6+parseInt(_0x15dd73(0x90))/0x7+parseInt(_0x15dd73(0x76))/0x8*(parseInt(_0x15dd73(0x7d))/0x9);if(_0x57deb1===_0x28cd98)break;else _0x19e549['push'](_0x19e549['shift']());}catch(_0x401c3f){_0x19e549['push'](_0x19e549['shift']());}}}(a93_0x4efe,0x3cdbb));import a93_0x4f0c0e from'chalk';import{CLI_BIN_NAME}from'../constant/cli.js';import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';function a93_0x4efe(){const _0x1aec5a=['(set\x20via\x20file,\x20length=','\x20\x20locale:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20Project:\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20pageSize:\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20runtimeDomain:\x20\x20\x20','red','\x20\x20riskLevel:\x20\x20\x20\x20\x20\x20\x20','\x20\x20Merged\x20Config','status','apiDir','(none)','currentApp','921010iVwApd','yellow','check','repeat','\x20\x20\x20\x20apiDir:\x20\x20\x20\x20\x20','(set,\x20length=','454449bdLpTh','\x20\x20apiDir:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','(not\x20found)','env','value','raw','\x20\x20appCode:\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20doctor','cookie','(not\x20set)','976278cnxQUf','appCode','read','\x20\x20Apps','missing','Global','\x20\x20userDomain:\x20\x20\x20\x20\x20\x20','\x20\x20defaultApp:\x20\x20\x20\x20\x20\x20','✗\x20Invalid\x20JSON','88fqltQh','riskLevel','gray','keys','\x20\x20Node:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','pageSize','\x20\x20env:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','589689qoOGbY','\x20\x20\x20\x20appcode:\x20\x20\x20\x20','\x20\x20\x20\x20env:\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20format:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20apiDomain:\x20\x20\x20\x20\x20\x20\x20','padEnd','\x20\x20─','platform','log','\x20\x20Status:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','defaultApp','\x20\x20Global:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','accessKey','locale','\x20(default)','134028lkQZVg','⚠\x20Empty\x20(treated\x20as\x20{})','✗\x20Not\x20logged\x20in','arch','3401125RieXUa','Project','bold','1997838gJrPPH','green','source','\x20\x20\x20\x20cookie:\x20\x20\x20\x20\x20','12GbmcvS','(no\x20file)','length','doctor','\x20\x20CLI\x20Version:\x20\x20\x20\x20\x20','empty','(default)','explicitAppName','✓\x20Valid','(missing)','✗\x20Expired'];a93_0x4efe=function(){return _0x1aec5a;};return a93_0x4efe();}import{VERSION,GIT_COMMIT,BUILD_TIME}from'../generated/build-info.js';import{getApiDomain,getUserDomain,getRuntimeDomain}from'../constant/domain.js';function a93_0x188e(_0x4e4cbb,_0x1bb8c6){_0x4e4cbb=_0x4e4cbb-0x73;const _0x4efe55=a93_0x4efe();let _0x188e94=_0x4efe55[_0x4e4cbb];return _0x188e94;}import{getProjectConfigPath,getGlobalConfigPath,buildConfigFromFlags,inspectCliConfigJsonFile}from'../context.js';import{getIsSessionValid}from'../auth/is-session-valid.js';import{getCookie}from'../auth/get-cookie.js';import{buildAppDoctorFields}from'../config/schema.js';async function execute(_0x4ee96f){const _0x14e8f8=a93_0x188e,_0x1e8355=GIT_COMMIT!=='unknown'?VERSION+'\x20('+GIT_COMMIT+',\x20'+BUILD_TIME['slice'](0x0,0xa)+')':VERSION,_0x3126e8=buildConfigFromFlags({}),_0x26f5e5=getCookie();console['log'](),console['log'](a93_0x4f0c0e[_0x14e8f8(0x92)](CLI_BIN_NAME+_0x14e8f8(0xbb))),console['log'](a93_0x4f0c0e['gray']('─'[_0x14e8f8(0xb1)](0x32))),console[_0x14e8f8(0x85)](_0x14e8f8(0x9b)+_0x1e8355),console[_0x14e8f8(0x85)](_0x14e8f8(0x7a)+process['version']),console[_0x14e8f8(0x85)]('\x20\x20Platform:\x20\x20\x20\x20\x20\x20\x20\x20'+process[_0x14e8f8(0x84)]+'\x20'+process[_0x14e8f8(0x8f)]),console[_0x14e8f8(0x85)](),console['log'](a93_0x4f0c0e[_0x14e8f8(0x92)]('\x20\x20Config\x20Files')),console[_0x14e8f8(0x85)](a93_0x4f0c0e['gray'](_0x14e8f8(0x83)['repeat'](0x1e)));const _0xb9db42=getGlobalConfigPath(),_0xb2375b=getProjectConfigPath();console[_0x14e8f8(0x85)](_0x14e8f8(0x88)+(_0xb9db42||a93_0x4f0c0e[_0x14e8f8(0x78)]('(not\x20found)'))),console[_0x14e8f8(0x85)](_0x14e8f8(0xa4)+(_0xb2375b||a93_0x4f0c0e['gray'](_0x14e8f8(0xb6)))),console[_0x14e8f8(0x85)](),console[_0x14e8f8(0x85)](a93_0x4f0c0e[_0x14e8f8(0x92)]('\x20\x20Config\x20JSON')),console[_0x14e8f8(0x85)](a93_0x4f0c0e[_0x14e8f8(0x78)](_0x14e8f8(0x83)[_0x14e8f8(0xb1)](0x1e)));const _0x27833e=(_0x352541,_0x211d0a)=>{const _0x5b5c17=_0x14e8f8;if(!_0x211d0a){console[_0x5b5c17(0x85)]('\x20\x20'+_0x352541[_0x5b5c17(0x82)](0x11)+'\x20'+a93_0x4f0c0e[_0x5b5c17(0x78)](_0x5b5c17(0x98)));return;}const _0x2a19b7=inspectCliConfigJsonFile(_0x211d0a);if(_0x2a19b7[_0x5b5c17(0xaa)]==='ok')console[_0x5b5c17(0x85)]('\x20\x20'+_0x352541[_0x5b5c17(0x82)](0x11)+'\x20'+a93_0x4f0c0e['green']('✓\x20Valid\x20JSON'));else{if(_0x2a19b7['status']===_0x5b5c17(0x9c))console[_0x5b5c17(0x85)]('\x20\x20'+_0x352541[_0x5b5c17(0x82)](0x11)+'\x20'+a93_0x4f0c0e[_0x5b5c17(0xaf)](_0x5b5c17(0x8d)));else _0x2a19b7['status']===_0x5b5c17(0xc2)?console['log']('\x20\x20'+_0x352541[_0x5b5c17(0x82)](0x11)+'\x20'+a93_0x4f0c0e[_0x5b5c17(0x78)](_0x5b5c17(0xa0))):(console[_0x5b5c17(0x85)]('\x20\x20'+_0x352541['padEnd'](0x11)+'\x20'+a93_0x4f0c0e[_0x5b5c17(0xa7)](_0x5b5c17(0x75))),console[_0x5b5c17(0x85)]('\x20\x20'+''[_0x5b5c17(0x82)](0x11)+'\x20'+a93_0x4f0c0e[_0x5b5c17(0xa7)](_0x2a19b7['message'])));}};_0x27833e(_0x14e8f8(0xc3),_0xb9db42),_0x27833e(_0x14e8f8(0x91),_0xb2375b),console[_0x14e8f8(0x85)](),console[_0x14e8f8(0x85)](a93_0x4f0c0e[_0x14e8f8(0x92)](_0x14e8f8(0xa9))),console[_0x14e8f8(0x85)](a93_0x4f0c0e[_0x14e8f8(0x78)](_0x14e8f8(0x83)[_0x14e8f8(0xb1)](0x1e))),console[_0x14e8f8(0x85)](_0x14e8f8(0xba)+(_0x3126e8[_0x14e8f8(0xbf)]||a93_0x4f0c0e[_0x14e8f8(0xa7)](_0x14e8f8(0xbd)))),console[_0x14e8f8(0x85)](_0x14e8f8(0x7c)+_0x3126e8['env']),console['log'](_0x14e8f8(0xa3)+_0x3126e8[_0x14e8f8(0x8a)]),console[_0x14e8f8(0x85)](_0x14e8f8(0xb5)+_0x3126e8[_0x14e8f8(0xab)]),console[_0x14e8f8(0x85)](_0x14e8f8(0x74)+(_0x3126e8[_0x14e8f8(0x87)]||a93_0x4f0c0e[_0x14e8f8(0x78)](_0x14e8f8(0xac)))),console[_0x14e8f8(0x85)]('\x20\x20currentApp:\x20\x20\x20\x20\x20\x20'+(_0x3126e8[_0x14e8f8(0xad)]||a93_0x4f0c0e[_0x14e8f8(0x78)](_0x14e8f8(0xac)))),console[_0x14e8f8(0x85)]('\x20\x20explicitAppName:\x20'+(_0x3126e8[_0x14e8f8(0x9e)]||a93_0x4f0c0e[_0x14e8f8(0x78)](_0x14e8f8(0xac)))),console[_0x14e8f8(0x85)](_0x14e8f8(0x80)+(_0x3126e8['format']||a93_0x4f0c0e['gray']('(default:\x20'+DEFAULT_CONFIG_VALUES['format']+')'))),console[_0x14e8f8(0x85)](_0x14e8f8(0xa5)+(_0x3126e8[_0x14e8f8(0x7b)]??a93_0x4f0c0e[_0x14e8f8(0x78)](_0x14e8f8(0x9d)))),console[_0x14e8f8(0x85)](_0x14e8f8(0xa8)+_0x3126e8[_0x14e8f8(0x77)]),console[_0x14e8f8(0x85)]('\x20\x20verbose:\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x3126e8['verbose']),console[_0x14e8f8(0x85)]('\x20\x20cookie:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+(_0x3126e8[_0x14e8f8(0xbc)]?a93_0x4f0c0e[_0x14e8f8(0x94)](_0x14e8f8(0xb3)+_0x3126e8[_0x14e8f8(0xbc)][_0x14e8f8(0x99)]+')'):_0x26f5e5?a93_0x4f0c0e['green'](_0x14e8f8(0xa2)+_0x26f5e5[_0x14e8f8(0x99)]+')'):a93_0x4f0c0e[_0x14e8f8(0x78)](_0x14e8f8(0xac))));const _0x32c95e=Object[_0x14e8f8(0x79)](_0x3126e8['apps']);if(_0x32c95e[_0x14e8f8(0x99)]>0x0){console[_0x14e8f8(0x85)](),console[_0x14e8f8(0x85)](a93_0x4f0c0e['bold'](_0x14e8f8(0xc1))),console[_0x14e8f8(0x85)](a93_0x4f0c0e[_0x14e8f8(0x78)](_0x14e8f8(0x83)[_0x14e8f8(0xb1)](0x1e)));for(const _0x4cc175 of _0x32c95e){const _0x5e57f2=_0x3126e8['apps'][_0x4cc175],_0x3b7c9a=_0x4cc175===_0x3126e8[_0x14e8f8(0x87)],_0x4e6a15=_0x4cc175===_0x3126e8['currentApp'],_0xef217b=_0x4e6a15?a93_0x4f0c0e[_0x14e8f8(0x94)]('\x20←\x20current'):'',_0x2e1e4b=_0x3b7c9a?_0x14e8f8(0x8b):'';console[_0x14e8f8(0x85)]('\x20\x20'+_0x4cc175+_0x2e1e4b+_0xef217b),console[_0x14e8f8(0x85)](_0x14e8f8(0x7e)+_0x5e57f2['appcode']);const _0x336dd7=buildAppDoctorFields(_0x5e57f2,{'env':_0x3126e8[_0x14e8f8(0xb7)],'apiDir':_0x3126e8[_0x14e8f8(0xb9)][_0x14e8f8(0xab)]||DEFAULT_CONFIG_VALUES[_0x14e8f8(0xab)],'cookie':_0x3126e8[_0x14e8f8(0xbc)]||_0x26f5e5||undefined,'accessKey':_0x3126e8[_0x14e8f8(0x89)]});console[_0x14e8f8(0x85)](_0x14e8f8(0x7f)+_0x336dd7[_0x14e8f8(0xb7)][_0x14e8f8(0xb8)]+'\x20\x20'+a93_0x4f0c0e[_0x14e8f8(0x78)]('('+_0x336dd7[_0x14e8f8(0xb7)]['source']+')')),console[_0x14e8f8(0x85)](_0x14e8f8(0xb2)+_0x336dd7['apiDir']['value']+'\x20\x20'+a93_0x4f0c0e[_0x14e8f8(0x78)]('('+_0x336dd7[_0x14e8f8(0xab)][_0x14e8f8(0x95)]+')'));const _0x61ab38=_0x336dd7[_0x14e8f8(0xbc)][_0x14e8f8(0xb8)]?a93_0x4f0c0e[_0x14e8f8(0x94)](_0x14e8f8(0xb3)+_0x336dd7[_0x14e8f8(0xbc)][_0x14e8f8(0xb8)]['length']+')'):a93_0x4f0c0e[_0x14e8f8(0x78)](_0x14e8f8(0xac));console[_0x14e8f8(0x85)](_0x14e8f8(0x96)+_0x61ab38+'\x20\x20'+a93_0x4f0c0e[_0x14e8f8(0x78)]('('+_0x336dd7['cookie'][_0x14e8f8(0x95)]+')'));const _0x23351a=_0x336dd7['accessKey'][_0x14e8f8(0xb8)]?a93_0x4f0c0e[_0x14e8f8(0x94)](_0x14e8f8(0xb3)+_0x336dd7[_0x14e8f8(0x89)]['value']['length']+')'):a93_0x4f0c0e['gray'](_0x14e8f8(0xac));console[_0x14e8f8(0x85)]('\x20\x20\x20\x20accessKey:\x20\x20'+_0x23351a+'\x20\x20'+a93_0x4f0c0e[_0x14e8f8(0x78)]('('+_0x336dd7[_0x14e8f8(0x89)][_0x14e8f8(0x95)]+')'));}}console[_0x14e8f8(0x85)](),console[_0x14e8f8(0x85)](a93_0x4f0c0e['bold']('\x20\x20API\x20Endpoints')),console[_0x14e8f8(0x85)](a93_0x4f0c0e['gray']('\x20\x20─'[_0x14e8f8(0xb1)](0x1e))),console[_0x14e8f8(0x85)](_0x14e8f8(0x81)+getApiDomain()),console['log'](_0x14e8f8(0x73)+getUserDomain()),console[_0x14e8f8(0x85)](_0x14e8f8(0xa6)+getRuntimeDomain()),console[_0x14e8f8(0x85)](),console['log'](a93_0x4f0c0e[_0x14e8f8(0x92)]('\x20\x20Auth')),console['log'](a93_0x4f0c0e['gray']('\x20\x20─'[_0x14e8f8(0xb1)](0x1e)));if(_0x26f5e5){const _0xfe67bc=await getIsSessionValid();console[_0x14e8f8(0x85)]('\x20\x20Status:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+(_0xfe67bc?a93_0x4f0c0e[_0x14e8f8(0x94)](_0x14e8f8(0x9f)):a93_0x4f0c0e[_0x14e8f8(0xa7)](_0x14e8f8(0xa1))));}else console[_0x14e8f8(0x85)](_0x14e8f8(0x86)+a93_0x4f0c0e[_0x14e8f8(0xa7)](_0x14e8f8(0x8e)));return console[_0x14e8f8(0x85)](),{'ok':!![]};}export const doctorDefinition={'service':a93_0x1412e9(0x9a),'command':a93_0x1412e9(0xb0),'description':'Diagnose\x20CLI\x20configuration\x20and\x20connectivity','risk':a93_0x1412e9(0xc0),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],'execute':execute};
@@ -1 +1 @@
1
- const a94_0x2ae059=a94_0x756f;function a94_0x756f(_0x330fc1,_0x5a54ae){_0x330fc1=_0x330fc1-0x10f;const _0x4bb96c=a94_0x4bb9();let _0x756f79=_0x4bb96c[_0x330fc1];return _0x756f79;}(function(_0x1eed0e,_0x1639bb){const _0x26e3ad=a94_0x756f,_0x14055c=_0x1eed0e();while(!![]){try{const _0x1dcd27=-parseInt(_0x26e3ad(0x11b))/0x1+-parseInt(_0x26e3ad(0x111))/0x2*(parseInt(_0x26e3ad(0x122))/0x3)+parseInt(_0x26e3ad(0x11a))/0x4*(parseInt(_0x26e3ad(0x128))/0x5)+parseInt(_0x26e3ad(0x11e))/0x6*(-parseInt(_0x26e3ad(0x10f))/0x7)+parseInt(_0x26e3ad(0x12c))/0x8+-parseInt(_0x26e3ad(0x117))/0x9*(parseInt(_0x26e3ad(0x12e))/0xa)+parseInt(_0x26e3ad(0x133))/0xb;if(_0x1dcd27===_0x1639bb)break;else _0x14055c['push'](_0x14055c['shift']());}catch(_0x3c1ece){_0x14055c['push'](_0x14055c['shift']());}}}(a94_0x4bb9,0xeb297));import{requireDevelopmentUploadFile}from'../../commands/common/local-file.js';import{queryDevelopmentFileUrl,uploadDevelopmentFile}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';const FILE_FLAG={'name':a94_0x2ae059(0x124),'type':'string','required':!![],'description':'Path\x20to\x20the\x20local\x20file\x20to\x20upload'},FILEPATH_FLAG={'name':a94_0x2ae059(0x11f),'type':a94_0x2ae059(0x12d),'required':!![],'description':a94_0x2ae059(0x116)},DOWNLOAD_FLAG={'name':a94_0x2ae059(0x11c),'type':'boolean','description':a94_0x2ae059(0x112)},LONG_TERM_FLAG={'name':a94_0x2ae059(0x110),'type':a94_0x2ae059(0x129),'description':a94_0x2ae059(0x126)};function requireFilePath(_0x5bfe2a){const _0x1e11c0=a94_0x2ae059,_0x1a9996=_0x5bfe2a[_0x1e11c0(0x114)]();if(!_0x1a9996)throw CliErrors[_0x1e11c0(0x12b)](_0x1e11c0(0x120));return _0x1a9996;}function a94_0x4bb9(){const _0x329528=['69SiibVB','Preview:\x20upload\x20','file','\x20to\x20development\x20app\x20','Return\x20a\x203-year\x20URL\x20for\x20URL-only\x20content\x20embedding\x20such\x20as\x20rich\x20text,\x20Markdown,\x20or\x20HTML','bool','9592845lmmCmV','boolean','filePath','validation','11671144AdVUVD','string','832660bfsNHo','str','Upload\x20a\x20local\x20file\x20and\x20return\x20filePath\x20for\x20durable\x20references','File','upload','15830155eptcJk','56567xjvJUl','long-term','88158ifWEnb','Return\x20a\x20short-lived\x20download\x20URL\x20instead\x20of\x20a\x20short-lived\x20preview\x20URL','read','trim','query-url','Development\x20filePath\x20returned\x20by\x20file\x20upload;\x20store\x20it\x20in\x20file\x20fields\x20and\x20durable\x20data','153CrqGVt','path','Query\x20a\x20short-lived\x20URL\x20for\x20preview,\x20download,\x20or\x20immediate\x20access','4JhpGaS','1044198kgbCau','download','Uploaded\x20file.\x20Store\x20filePath\x20for\x20durable\x20references;\x20use\x20file\x20query-url\x20for\x20short-lived\x20access.','282UvpbgB','filepath','filePath\x20is\x20required.','appCode'];a94_0x4bb9=function(){return _0x329528;};return a94_0x4bb9();}const fileUpload={'service':'file','command':a94_0x2ae059(0x132),'description':a94_0x2ae059(0x130),'risk':'read','flags':[FILE_FLAG],async 'dryRun'(_0x43b7b8){const _0xfe49c2=a94_0x2ae059,_0x42e521=requireDevelopmentUploadFile(_0x43b7b8['str'](_0xfe49c2(0x124)),_0xfe49c2(0x131));return{'method':'POST','url':'/smartapi/common/uploadFile','body':{'appCode':_0x43b7b8['appCode'],'multipart':{'file':_0x42e521}},'description':_0xfe49c2(0x123)+_0x42e521['path']+_0xfe49c2(0x125)+_0x43b7b8[_0xfe49c2(0x121)]};},async 'execute'(_0x157f2b){const _0x1129ca=a94_0x2ae059,_0xb7f9f7=requireDevelopmentUploadFile(_0x157f2b[_0x1129ca(0x12f)](_0x1129ca(0x124)),_0x1129ca(0x131)),_0x5155fc=await uploadDevelopmentFile(_0x157f2b[_0x1129ca(0x121)],_0xb7f9f7[_0x1129ca(0x118)]);return{'ok':!![],'data':_0x5155fc,'message':_0x5155fc[_0x1129ca(0x12a)]?'Uploaded\x20file:\x20'+_0x5155fc[_0x1129ca(0x12a)]+'.\x20Store\x20filePath\x20for\x20durable\x20references;\x20use\x20file\x20query-url\x20for\x20short-lived\x20access.':_0x1129ca(0x11d)};}},fileQueryUrl={'service':a94_0x2ae059(0x124),'command':a94_0x2ae059(0x115),'description':a94_0x2ae059(0x119),'risk':a94_0x2ae059(0x113),'flags':[FILEPATH_FLAG,DOWNLOAD_FLAG,LONG_TERM_FLAG],async 'execute'(_0x4cd9df){const _0x100157=a94_0x2ae059,_0x32eb11=requireFilePath(_0x4cd9df[_0x100157(0x12f)](_0x100157(0x11f))),_0x886c2b=await queryDevelopmentFileUrl(_0x32eb11,{'download':_0x4cd9df[_0x100157(0x127)]('download'),'longTerm':_0x4cd9df[_0x100157(0x127)](_0x100157(0x110))});return{'ok':!![],'data':_0x886c2b};}};export const fileDefinitions=[fileUpload,fileQueryUrl];
1
+ const a94_0x9f5835=a94_0x596f;(function(_0x2afae,_0x347259){const _0x37ea1f=a94_0x596f,_0x57c218=_0x2afae();while(!![]){try{const _0x286a0a=parseInt(_0x37ea1f(0xc9))/0x1*(-parseInt(_0x37ea1f(0xe5))/0x2)+-parseInt(_0x37ea1f(0xdc))/0x3*(-parseInt(_0x37ea1f(0xea))/0x4)+parseInt(_0x37ea1f(0xd9))/0x5*(parseInt(_0x37ea1f(0xcf))/0x6)+parseInt(_0x37ea1f(0xeb))/0x7*(-parseInt(_0x37ea1f(0xe8))/0x8)+parseInt(_0x37ea1f(0xca))/0x9+-parseInt(_0x37ea1f(0xd5))/0xa+-parseInt(_0x37ea1f(0xd7))/0xb*(-parseInt(_0x37ea1f(0xcb))/0xc);if(_0x286a0a===_0x347259)break;else _0x57c218['push'](_0x57c218['shift']());}catch(_0x2be55a){_0x57c218['push'](_0x57c218['shift']());}}}(a94_0x48cb,0x1e36b));function a94_0x596f(_0x1f48ae,_0x1063b8){_0x1f48ae=_0x1f48ae-0xc7;const _0x48cbe6=a94_0x48cb();let _0x596f88=_0x48cbe6[_0x1f48ae];return _0x596f88;}import{requireDevelopmentUploadFile}from'../../commands/common/local-file.js';import{queryDevelopmentFileUrl,uploadDevelopmentFile}from'../../core/api-client.js';function a94_0x48cb(){const _0x3d919e=['file','11052zGIKLC','Path\x20to\x20the\x20local\x20file\x20to\x20upload','/smartapi/common/uploadFile','appCode','path','Uploaded\x20file.\x20Store\x20filePath\x20for\x20durable\x20references;\x20use\x20file\x20query-url\x20for\x20short-lived\x20access.','download','read','Upload\x20a\x20local\x20file\x20and\x20return\x20filePath\x20for\x20durable\x20references','2okgxUs','Return\x20a\x20short-lived\x20download\x20URL\x20instead\x20of\x20a\x20short-lived\x20preview\x20URL','Preview:\x20upload\x20','344504XtHIAP','Query\x20a\x20short-lived\x20URL\x20for\x20preview,\x20download,\x20or\x20immediate\x20access','44sfBwHz','35ZFncAE','\x20to\x20development\x20app\x20','filepath','query-url','138289pQoupU','1459224YjHFqf','144144SLXYaI','string','str','bool','2004STvutO','Return\x20a\x203-year\x20URL\x20for\x20URL-only\x20content\x20embedding\x20such\x20as\x20rich\x20text,\x20Markdown,\x20or\x20HTML','File','.\x20Store\x20filePath\x20for\x20durable\x20references;\x20use\x20file\x20query-url\x20for\x20short-lived\x20access.','filePath','Development\x20filePath\x20returned\x20by\x20file\x20upload;\x20store\x20it\x20in\x20file\x20fields\x20and\x20durable\x20data','71010IXfeMZ','boolean','88OubvjM','long-term','2780omtFQH','POST'];a94_0x48cb=function(){return _0x3d919e;};return a94_0x48cb();}import{CliErrors}from'../../errors.js';const FILE_FLAG={'name':a94_0x9f5835(0xdb),'type':a94_0x9f5835(0xcc),'required':!![],'description':a94_0x9f5835(0xdd)},FILEPATH_FLAG={'name':a94_0x9f5835(0xc7),'type':'string','required':!![],'description':a94_0x9f5835(0xd4)},DOWNLOAD_FLAG={'name':a94_0x9f5835(0xe2),'type':a94_0x9f5835(0xd6),'description':a94_0x9f5835(0xe6)},LONG_TERM_FLAG={'name':a94_0x9f5835(0xd8),'type':a94_0x9f5835(0xd6),'description':a94_0x9f5835(0xd0)};function requireFilePath(_0x2e0a8e){const _0x30f6b5=_0x2e0a8e['trim']();if(!_0x30f6b5)throw CliErrors['validation']('filePath\x20is\x20required.');return _0x30f6b5;}const fileUpload={'service':a94_0x9f5835(0xdb),'command':'upload','description':a94_0x9f5835(0xe4),'risk':'read','flags':[FILE_FLAG],async 'dryRun'(_0x53aa6b){const _0x233f55=a94_0x9f5835,_0x234710=requireDevelopmentUploadFile(_0x53aa6b[_0x233f55(0xcd)]('file'),_0x233f55(0xd1));return{'method':_0x233f55(0xda),'url':_0x233f55(0xde),'body':{'appCode':_0x53aa6b[_0x233f55(0xdf)],'multipart':{'file':_0x234710}},'description':_0x233f55(0xe7)+_0x234710[_0x233f55(0xe0)]+_0x233f55(0xec)+_0x53aa6b['appCode']};},async 'execute'(_0x379040){const _0x452c84=a94_0x9f5835,_0x5cfeaa=requireDevelopmentUploadFile(_0x379040[_0x452c84(0xcd)](_0x452c84(0xdb)),'File'),_0x3e0ece=await uploadDevelopmentFile(_0x379040[_0x452c84(0xdf)],_0x5cfeaa[_0x452c84(0xe0)]);return{'ok':!![],'data':_0x3e0ece,'message':_0x3e0ece[_0x452c84(0xd3)]?'Uploaded\x20file:\x20'+_0x3e0ece[_0x452c84(0xd3)]+_0x452c84(0xd2):_0x452c84(0xe1)};}},fileQueryUrl={'service':a94_0x9f5835(0xdb),'command':a94_0x9f5835(0xc8),'description':a94_0x9f5835(0xe9),'risk':a94_0x9f5835(0xe3),'flags':[FILEPATH_FLAG,DOWNLOAD_FLAG,LONG_TERM_FLAG],async 'execute'(_0x1582f2){const _0xcea1a5=a94_0x9f5835,_0x21c7c0=requireFilePath(_0x1582f2[_0xcea1a5(0xcd)]('filepath')),_0x9426ab=await queryDevelopmentFileUrl(_0x21c7c0,{'download':_0x1582f2[_0xcea1a5(0xce)](_0xcea1a5(0xe2)),'longTerm':_0x1582f2[_0xcea1a5(0xce)]('long-term')});return{'ok':!![],'data':_0x9426ab};}};export const fileDefinitions=[fileUpload,fileQueryUrl];
@@ -1 +1 @@
1
- const a95_0x2183f0=a95_0x3db8;(function(_0x356acd,_0x48a1c8){const _0x26a625=a95_0x3db8,_0x2fda0c=_0x356acd();while(!![]){try{const _0x17e265=parseInt(_0x26a625(0x160))/0x1*(-parseInt(_0x26a625(0x18d))/0x2)+-parseInt(_0x26a625(0x186))/0x3*(parseInt(_0x26a625(0x179))/0x4)+-parseInt(_0x26a625(0x182))/0x5*(parseInt(_0x26a625(0x17f))/0x6)+parseInt(_0x26a625(0x166))/0x7+-parseInt(_0x26a625(0x167))/0x8+parseInt(_0x26a625(0x16a))/0x9*(parseInt(_0x26a625(0x16d))/0xa)+parseInt(_0x26a625(0x180))/0xb;if(_0x17e265===_0x48a1c8)break;else _0x2fda0c['push'](_0x2fda0c['shift']());}catch(_0x1bb721){_0x2fda0c['push'](_0x2fda0c['shift']());}}}(a95_0x23c4,0xb9fbf));import{NEW_CONFIG_NAME,LEGACY_CONFIG_NAMES,writeConfigFile,resolveWriteConfigPath}from'../../context.js';import{upgradeApp}from'../../commands/project/upgrade.js';import{getCliVersion}from'../../utils/version.js';function a95_0x23c4(){const _0x4e688b=['str','map','\x20\x20Config:\x20','production','.rabetbase.json\x20already\x20exists\x20in\x20current\x20directory.','33131OxzvJG','\x20project\x20upgrade`\x20to\x20migrate\x20from\x20legacy\x20config.','defaultApp','appcode','检测到旧配置文件,正在自动升级...\x0a','flagMissing','3347428NTmDOz','10116712fJHfNG','appCode','\x20init\x20--appcode\x20<code>\x20[--env\x20<env>]','4440753IdkOim','global','boolean','20KYEgmT','custom','log','Use\x20`','\x20\x20Default:\x20','validation','Smart\x20init:\x20auto-detect,\x20upgrade,\x20or\x20select\x20app\x20from\x20platform','\x20\x20Env:\x20','write','init','env','\x20\x20Apps:\x20','523468sTvvgK','some','cwd','message','\x20config','project','222jpoEQW','29068754bADgJw','Delegate\x20to\x20legacy\x20Ink\x20init\x20flow','108435kkoFJZ','run','Target\x20environment','../../commands/project/init.js','24cSAYXo','\x0a✓\x20Successfully\x20initialized\x20','toLocaleString','Usage:\x20','valid','yes','bool','14bsscjh','App\x20code\x20to\x20initialize\x20with'];a95_0x23c4=function(){return _0x4e688b;};return a95_0x23c4();}import{CliErrors}from'../../errors.js';import{CLI_BIN_NAME}from'../../constant/cli.js';import{RABETBASE_ENV_VALUES}from'../../constant/env.js';import{existsSync}from'node:fs';import{resolve}from'node:path';import{validateAppcode}from'../../commands/common/validate.js';import{promptCustomAppcode,selectMultipleApps}from'../../commands/common/app-selector.js';import{getCookie}from'../../auth/get-cookie.js';import{buildCanonicalProjectConfig}from'../../config/schema.js';function syntheticApp(_0x5c692d){return{'appCode':_0x5c692d,'appName':_0x5c692d};}function writeInitConfig(_0x218646,_0x2d5b41,_0x39098a){const _0x466a44=a95_0x3db8,_0x39c877=resolveWriteConfigPath(_0x218646),_0x3aa159=buildCanonicalProjectConfig({},{'appCodes':_0x2d5b41[_0x466a44(0x190)](_0x4d0f8d=>_0x4d0f8d[_0x466a44(0x168)]),'env':_0x39098a,'metadata':{'version':getCliVersion(),'createdAt':new Date()[_0x466a44(0x188)]()}});writeConfigFile(_0x39c877,_0x3aa159);const _0x29cfba=_0x218646===_0x466a44(0x16b)?_0x466a44(0x16b):_0x466a44(0x17e);console[_0x466a44(0x16f)](_0x466a44(0x187)+_0x29cfba+_0x466a44(0x17d)),console[_0x466a44(0x16f)](_0x466a44(0x178)+_0x2d5b41['map'](_0x2c9ec2=>_0x2c9ec2[_0x466a44(0x168)])['join'](',\x20')),console[_0x466a44(0x16f)](_0x466a44(0x171)+_0x3aa159[_0x466a44(0x162)]),console[_0x466a44(0x16f)](_0x466a44(0x174)+_0x3aa159[_0x466a44(0x177)]),console['log'](_0x466a44(0x15d)+_0x39c877);}async function runSmartInit(_0x3c25ec){const _0x52bcb2=a95_0x3db8,_0x340fe0=process[_0x52bcb2(0x17b)](),_0x94a5c1=_0x3c25ec['bool'](_0x52bcb2(0x16b))?_0x52bcb2(0x16b):'project',_0x3e6f0c=_0x3c25ec['str'](_0x52bcb2(0x177))||_0x52bcb2(0x15e),_0x35c219=_0x3c25ec[_0x52bcb2(0x18f)]('appcode')||undefined,_0x578644=_0x3c25ec[_0x52bcb2(0x18c)](_0x52bcb2(0x17e));if(_0x578644){const {initConfig:_0x5796d9}=await import(_0x52bcb2(0x185));return _0x5796d9({'appcode':_0x35c219,'env':_0x3e6f0c,'autoYes':_0x3c25ec[_0x52bcb2(0x18c)](_0x52bcb2(0x18b))});}if(_0x94a5c1===_0x52bcb2(0x17e)){const _0x44bd9=existsSync(resolve(_0x340fe0,NEW_CONFIG_NAME)),_0x5787db=LEGACY_CONFIG_NAMES[_0x52bcb2(0x17a)](_0x588500=>existsSync(resolve(_0x340fe0,_0x588500)));if(_0x5787db&&!_0x44bd9)return console[_0x52bcb2(0x16f)](_0x52bcb2(0x164)),upgradeApp(_0x3c25ec['nonInteractive'],{'yes':_0x3c25ec[_0x52bcb2(0x18c)]('yes')});if(_0x44bd9)throw CliErrors[_0x52bcb2(0x172)](_0x52bcb2(0x15f),_0x52bcb2(0x170)+CLI_BIN_NAME+_0x52bcb2(0x161));}if(_0x35c219){const _0x3e12ae=validateAppcode(_0x35c219);if(!_0x3e12ae[_0x52bcb2(0x18a)])throw CliErrors['validation'](_0x3e12ae[_0x52bcb2(0x17c)]);writeInitConfig(_0x94a5c1,[syntheticApp(_0x35c219)],_0x3e6f0c);return;}if(_0x3c25ec['nonInteractive'])throw CliErrors[_0x52bcb2(0x165)](_0x52bcb2(0x163),_0x52bcb2(0x189)+CLI_BIN_NAME+_0x52bcb2(0x169));const _0x2451af=getCookie(),_0x53bd7b=await selectMultipleApps(_0x2451af),_0x42dd8d=_0x53bd7b===_0x52bcb2(0x16e)?[syntheticApp(await promptCustomAppcode())]:_0x53bd7b;writeInitConfig(_0x94a5c1,_0x42dd8d,_0x3e6f0c);}function a95_0x3db8(_0x387405,_0x6d6c54){_0x387405=_0x387405-0x15d;const _0x23c4ff=a95_0x23c4();let _0x3db8eb=_0x23c4ff[_0x387405];return _0x3db8eb;}const initFlags=[{'name':'global','type':a95_0x2183f0(0x16c),'description':'Write\x20to\x20global\x20config\x20instead\x20of\x20project','default':![]},{'name':a95_0x2183f0(0x177),'type':'string','description':a95_0x2183f0(0x184),'default':a95_0x2183f0(0x15e),'enum':[...RABETBASE_ENV_VALUES]},{'name':a95_0x2183f0(0x163),'type':'string','description':a95_0x2183f0(0x18e)},{'name':a95_0x2183f0(0x17e),'type':a95_0x2183f0(0x16c),'description':a95_0x2183f0(0x181),'default':![]},{'name':a95_0x2183f0(0x18b),'type':a95_0x2183f0(0x16c),'description':'Auto-confirm\x20prompts','default':![]}];export const initDefinitions=[{'service':a95_0x2183f0(0x176),'command':a95_0x2183f0(0x183),'description':a95_0x2183f0(0x173),'risk':a95_0x2183f0(0x175),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':initFlags,async 'execute'(_0x78c0d3){return await runSmartInit(_0x78c0d3),{'ok':!![]};}}];
1
+ const a95_0x12093a=a95_0x552e;(function(_0x4ba8b8,_0x25ff66){const _0x213df2=a95_0x552e,_0x6798c=_0x4ba8b8();while(!![]){try{const _0x4397e1=-parseInt(_0x213df2(0x159))/0x1+-parseInt(_0x213df2(0x161))/0x2*(parseInt(_0x213df2(0x175))/0x3)+-parseInt(_0x213df2(0x176))/0x4+-parseInt(_0x213df2(0x15c))/0x5+-parseInt(_0x213df2(0x180))/0x6*(parseInt(_0x213df2(0x173))/0x7)+parseInt(_0x213df2(0x16a))/0x8+-parseInt(_0x213df2(0x152))/0x9*(-parseInt(_0x213df2(0x171))/0xa);if(_0x4397e1===_0x25ff66)break;else _0x6798c['push'](_0x6798c['shift']());}catch(_0xaa7f62){_0x6798c['push'](_0x6798c['shift']());}}}(a95_0xcea4,0x3e774));function a95_0x552e(_0x498775,_0xb1a161){_0x498775=_0x498775-0x150;const _0xcea412=a95_0xcea4();let _0x552e2f=_0xcea412[_0x498775];return _0x552e2f;}import{NEW_CONFIG_NAME,LEGACY_CONFIG_NAMES,writeConfigFile,resolveWriteConfigPath}from'../../context.js';import{upgradeApp}from'../../commands/project/upgrade.js';import{getCliVersion}from'../../utils/version.js';import{CliErrors}from'../../errors.js';import{CLI_BIN_NAME}from'../../constant/cli.js';import{RABETBASE_ENV_VALUES}from'../../constant/env.js';import{existsSync}from'node:fs';function a95_0xcea4(){const _0xb121ec=['Auto-confirm\x20prompts','\x20\x20Config:\x20','appCode','Usage:\x20','Use\x20`','Target\x20environment','init','../../commands/project/init.js','120396qDSUOW','run','Delegate\x20to\x20legacy\x20Ink\x20init\x20flow','\x0a✓\x20Successfully\x20initialized\x20','str','\x20init\x20--appcode\x20<code>\x20[--env\x20<env>]','981HGMkKX','flagMissing','validation','Write\x20to\x20global\x20config\x20instead\x20of\x20project','custom','toLocaleString','bool','246852tTyuok','Smart\x20init:\x20auto-detect,\x20upgrade,\x20or\x20select\x20app\x20from\x20platform','yes','2482695nkJNHx','some','检测到旧配置文件,正在自动升级...\x0a','join','defaultApp','893842kEabmy','nonInteractive','boolean','.rabetbase.json\x20already\x20exists\x20in\x20current\x20directory.','production','env','map','App\x20code\x20to\x20initialize\x20with','cwd','562624lcduDq','project','\x20config','global','appcode','write','\x20project\x20upgrade`\x20to\x20migrate\x20from\x20legacy\x20config.','205420oYONUC','\x20\x20Env:\x20','161dUZROd','log','3ypAinA','1606864nuRYeq','valid'];a95_0xcea4=function(){return _0xb121ec;};return a95_0xcea4();}import{resolve}from'node:path';import{validateAppcode}from'../../commands/common/validate.js';import{promptCustomAppcode,selectMultipleApps}from'../../commands/common/app-selector.js';import{getCookie}from'../../auth/get-cookie.js';import{buildCanonicalProjectConfig}from'../../config/schema.js';function syntheticApp(_0x163c18){return{'appCode':_0x163c18,'appName':_0x163c18};}function writeInitConfig(_0x3d878f,_0x2c7643,_0x187837){const _0x127873=a95_0x552e,_0x997e72=resolveWriteConfigPath(_0x3d878f),_0x56cdb6=buildCanonicalProjectConfig({},{'appCodes':_0x2c7643[_0x127873(0x167)](_0xaaf5af=>_0xaaf5af[_0x127873(0x17a)]),'env':_0x187837,'metadata':{'version':getCliVersion(),'createdAt':new Date()[_0x127873(0x157)]()}});writeConfigFile(_0x997e72,_0x56cdb6);const _0x1ea0ed=_0x3d878f===_0x127873(0x16d)?'global':'project';console[_0x127873(0x174)](_0x127873(0x183)+_0x1ea0ed+_0x127873(0x16c)),console['log']('\x20\x20Apps:\x20'+_0x2c7643[_0x127873(0x167)](_0x57b039=>_0x57b039['appCode'])[_0x127873(0x15f)](',\x20')),console['log']('\x20\x20Default:\x20'+_0x56cdb6[_0x127873(0x160)]),console[_0x127873(0x174)](_0x127873(0x172)+_0x56cdb6[_0x127873(0x166)]),console[_0x127873(0x174)](_0x127873(0x179)+_0x997e72);}async function runSmartInit(_0x478c41){const _0x4037b1=a95_0x552e,_0x40ef37=process[_0x4037b1(0x169)](),_0x407e64=_0x478c41[_0x4037b1(0x158)](_0x4037b1(0x16d))?_0x4037b1(0x16d):_0x4037b1(0x16b),_0x21c3a6=_0x478c41[_0x4037b1(0x150)]('env')||_0x4037b1(0x165),_0x53418f=_0x478c41[_0x4037b1(0x150)]('appcode')||undefined,_0x1d231e=_0x478c41[_0x4037b1(0x158)](_0x4037b1(0x16b));if(_0x1d231e){const {initConfig:_0x4224dc}=await import(_0x4037b1(0x17f));return _0x4224dc({'appcode':_0x53418f,'env':_0x21c3a6,'autoYes':_0x478c41['bool'](_0x4037b1(0x15b))});}if(_0x407e64===_0x4037b1(0x16b)){const _0x55cc48=existsSync(resolve(_0x40ef37,NEW_CONFIG_NAME)),_0x38d3cd=LEGACY_CONFIG_NAMES[_0x4037b1(0x15d)](_0x271d2f=>existsSync(resolve(_0x40ef37,_0x271d2f)));if(_0x38d3cd&&!_0x55cc48)return console[_0x4037b1(0x174)](_0x4037b1(0x15e)),upgradeApp(_0x478c41[_0x4037b1(0x162)],{'yes':_0x478c41[_0x4037b1(0x158)](_0x4037b1(0x15b))});if(_0x55cc48)throw CliErrors[_0x4037b1(0x154)](_0x4037b1(0x164),_0x4037b1(0x17c)+CLI_BIN_NAME+_0x4037b1(0x170));}if(_0x53418f){const _0x467319=validateAppcode(_0x53418f);if(!_0x467319[_0x4037b1(0x177)])throw CliErrors[_0x4037b1(0x154)](_0x467319['message']);writeInitConfig(_0x407e64,[syntheticApp(_0x53418f)],_0x21c3a6);return;}if(_0x478c41[_0x4037b1(0x162)])throw CliErrors[_0x4037b1(0x153)](_0x4037b1(0x16e),_0x4037b1(0x17b)+CLI_BIN_NAME+_0x4037b1(0x151));const _0x2d5a7d=getCookie(),_0x1414ee=await selectMultipleApps(_0x2d5a7d),_0x28a310=_0x1414ee===_0x4037b1(0x156)?[syntheticApp(await promptCustomAppcode())]:_0x1414ee;writeInitConfig(_0x407e64,_0x28a310,_0x21c3a6);}const initFlags=[{'name':'global','type':'boolean','description':a95_0x12093a(0x155),'default':![]},{'name':a95_0x12093a(0x166),'type':'string','description':a95_0x12093a(0x17d),'default':a95_0x12093a(0x165),'enum':[...RABETBASE_ENV_VALUES]},{'name':a95_0x12093a(0x16e),'type':'string','description':a95_0x12093a(0x168)},{'name':a95_0x12093a(0x16b),'type':a95_0x12093a(0x163),'description':a95_0x12093a(0x182),'default':![]},{'name':a95_0x12093a(0x15b),'type':a95_0x12093a(0x163),'description':a95_0x12093a(0x178),'default':![]}];export const initDefinitions=[{'service':a95_0x12093a(0x17e),'command':a95_0x12093a(0x181),'description':a95_0x12093a(0x15a),'risk':a95_0x12093a(0x16f),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':initFlags,async 'execute'(_0x19218a){return await runSmartInit(_0x19218a),{'ok':!![]};}}];
@@ -1 +1 @@
1
- function a96_0x1729(_0x37acbb,_0x388d55){_0x37acbb=_0x37acbb-0x81;const _0x305710=a96_0x3057();let _0x1729be=_0x305710[_0x37acbb];return _0x1729be;}(function(_0x46d78f,_0x5a8343){const _0x275961=a96_0x1729,_0x40ba3f=_0x46d78f();while(!![]){try{const _0x28a3ec=parseInt(_0x275961(0x89))/0x1+parseInt(_0x275961(0x8a))/0x2*(-parseInt(_0x275961(0x88))/0x3)+parseInt(_0x275961(0x8b))/0x4*(parseInt(_0x275961(0x83))/0x5)+parseInt(_0x275961(0x85))/0x6+parseInt(_0x275961(0x84))/0x7*(parseInt(_0x275961(0x86))/0x8)+-parseInt(_0x275961(0x81))/0x9*(-parseInt(_0x275961(0x82))/0xa)+-parseInt(_0x275961(0x87))/0xb;if(_0x28a3ec===_0x5a8343)break;else _0x40ba3f['push'](_0x40ba3f['shift']());}catch(_0x145ee7){_0x40ba3f['push'](_0x40ba3f['shift']());}}}(a96_0x3057,0xb559c));function a96_0x3057(){const _0xdc77b=['45rSwZLG','2890260KWUQBK','672995KHohji','74207IrXUmY','2752236uamOlc','920NvmLUY','33679976cjbmNn','33mScqVk','1152943PUKOkU','232520ssRDwF','24EoHbOZ'];a96_0x3057=function(){return _0xdc77b;};return a96_0x3057();}import{issueReport}from'../../commands/issue/report.js';export const issueDefinitions=[issueReport];
1
+ (function(_0x360992,_0x4b8d47){const _0x27ee3a=a96_0x5c0b,_0xe98171=_0x360992();while(!![]){try{const _0xb1d81b=parseInt(_0x27ee3a(0xb2))/0x1+parseInt(_0x27ee3a(0xba))/0x2*(-parseInt(_0x27ee3a(0xb8))/0x3)+-parseInt(_0x27ee3a(0xb9))/0x4+parseInt(_0x27ee3a(0xb7))/0x5*(parseInt(_0x27ee3a(0xb5))/0x6)+-parseInt(_0x27ee3a(0xb4))/0x7+-parseInt(_0x27ee3a(0xb3))/0x8+parseInt(_0x27ee3a(0xb6))/0x9;if(_0xb1d81b===_0x4b8d47)break;else _0xe98171['push'](_0xe98171['shift']());}catch(_0x2569cb){_0xe98171['push'](_0xe98171['shift']());}}}(a96_0x30a9,0x3d27b));import{issueReport}from'../../commands/issue/report.js';export const issueDefinitions=[issueReport];function a96_0x5c0b(_0x18a8f8,_0x30a91b){_0x18a8f8=_0x18a8f8-0xb2;const _0x30a9a6=a96_0x30a9();let _0x5c0b82=_0x30a9a6[_0x18a8f8];return _0x5c0b82;}function a96_0x30a9(){const _0x3f3f22=['2935898wBxydg','19914zMeXLs','13945365LXPgrs','65UHUyYt','9GwMmbx','1892140qEFvkW','78336xYyJUm','126475QvYwTZ','3669304ZJbJrk'];a96_0x30a9=function(){return _0x3f3f22;};return a96_0x30a9();}
@@ -1 +1 @@
1
- const a97_0x1a7a05=a97_0x4ea2;(function(_0x92bcc,_0x4b19a6){const _0x2537b3=a97_0x4ea2,_0x5765f7=_0x92bcc();while(!![]){try{const _0x167288=parseInt(_0x2537b3(0x1a7))/0x1*(-parseInt(_0x2537b3(0x1ba))/0x2)+parseInt(_0x2537b3(0x1c2))/0x3*(-parseInt(_0x2537b3(0x1a9))/0x4)+-parseInt(_0x2537b3(0x1b2))/0x5+-parseInt(_0x2537b3(0x1a6))/0x6+-parseInt(_0x2537b3(0x1ac))/0x7+-parseInt(_0x2537b3(0x1b9))/0x8+parseInt(_0x2537b3(0x1b0))/0x9;if(_0x167288===_0x4b19a6)break;else _0x5765f7['push'](_0x5765f7['shift']());}catch(_0xb1674d){_0x5765f7['push'](_0x5765f7['shift']());}}}(a97_0x187f,0xc4ab7));import{CliError}from'../../errors.js';import{CLI_BIN_NAME}from'../../constant/cli.js';function a97_0x187f(){const _0x43ecab=['issue','45564786KXNMEf','unknown_command','968600XtMffT','not_in_project','report','\x20issue\x20report\x20\x5c','code','\x20\x20\x20\x20--description\x20\x22Steps\x20to\x20reproduce,\x20expected\x20vs\x20actual,\x20and\x20any\x20relevant\x20logs.\x22','write','5166512Rzeimv','32IdfowZ','flag_missing','network_error','command','length','service','\x20\x20(Cookies\x20/\x20Authorization\x20/\x20access\x20keys\x20are\x20automatically\x20redacted\x20before\x20upload.)','stderr','8982vFigLT','Hit\x20a\x20','=1\x20to\x20silence\x20this\x20hint.','cancelled','replace','\x20bug?\x20Help\x20us\x20fix\x20it:','trim','2175324IGDrRz','91534chlvFV','has','508LNkPna','auth_required','message','8472275tmMDGg','slice','validation_error'];a97_0x187f=function(){return _0x43ecab;};return a97_0x187f();}export const NUDGE_OPT_OUT_ENV='RABETBASE_DISABLE_ISSUE_NUDGE';const NUDGE_SUPPRESSED_CODES=new Set([a97_0x1a7a05(0x1c5),a97_0x1a7a05(0x1aa),'config_missing',a97_0x1a7a05(0x1b3),a97_0x1a7a05(0x1b1),a97_0x1a7a05(0x1bb),a97_0x1a7a05(0x1ae),a97_0x1a7a05(0x1bc)]),defaultWriter=_0x68d3b2=>{const _0x121039=a97_0x1a7a05;process[_0x121039(0x1c1)][_0x121039(0x1b8)](_0x68d3b2);};export function shouldNudgeForError(_0x181374,_0x357c3a){const _0x227f80=a97_0x1a7a05;if(process.env[NUDGE_OPT_OUT_ENV]==='1')return![];if(_0x357c3a[_0x227f80(0x1bf)]===_0x227f80(0x1af)&&_0x357c3a[_0x227f80(0x1bd)]===_0x227f80(0x1b4))return![];if(_0x181374 instanceof CliError)return!NUDGE_SUPPRESSED_CODES[_0x227f80(0x1a8)](_0x181374[_0x227f80(0x1b6)]);return!![];}function a97_0x4ea2(_0x1ac727,_0x1109e0){_0x1ac727=_0x1ac727-0x1a6;const _0x187f26=a97_0x187f();let _0x4ea2a3=_0x187f26[_0x1ac727];return _0x4ea2a3;}export function printIssueReportNudgeForError(_0x1fe5b0,_0x480832,_0x15020d=defaultWriter){if(!shouldNudgeForError(_0x1fe5b0,_0x480832))return;const _0x28a72f=buildSuggestedTitle(_0x1fe5b0,_0x480832);_0x15020d(formatNudge(_0x28a72f));}function buildSuggestedTitle(_0x520213,_0x318e04){const _0xbb61f1=a97_0x1a7a05,_0x3dc8dc=_0x520213 instanceof Error?_0x520213[_0xbb61f1(0x1ab)]:String(_0x520213),_0x11910e=_0x3dc8dc[_0xbb61f1(0x1c6)](/[\r\n]+/g,'\x20')[_0xbb61f1(0x1c6)](/\s+/g,'\x20')[_0xbb61f1(0x1c8)]()[_0xbb61f1(0x1ad)](0x0,0x78)[_0xbb61f1(0x1c6)](/"/g,'\x5c\x22'),_0x592df8=CLI_BIN_NAME+'\x20'+_0x318e04[_0xbb61f1(0x1bf)]+'\x20'+_0x318e04[_0xbb61f1(0x1bd)];return _0x11910e[_0xbb61f1(0x1be)]>0x0?_0x592df8+':\x20'+_0x11910e:_0x592df8;}function formatNudge(_0x4c9c4e){const _0x5ec43d=a97_0x1a7a05;return['',_0x5ec43d(0x1c3)+CLI_BIN_NAME+_0x5ec43d(0x1c7),'\x20\x20'+CLI_BIN_NAME+_0x5ec43d(0x1b5),'\x20\x20\x20\x20--title\x20\x22'+_0x4c9c4e+'\x22\x20\x5c',_0x5ec43d(0x1b7),_0x5ec43d(0x1c0),'\x20\x20Set\x20'+NUDGE_OPT_OUT_ENV+_0x5ec43d(0x1c4),'']['join']('\x0a');}
1
+ const a97_0x4a0c46=a97_0x5e20;(function(_0x2693bb,_0x5c19a1){const _0x371759=a97_0x5e20,_0x30e7e9=_0x2693bb();while(!![]){try{const _0x35e57b=parseInt(_0x371759(0x18e))/0x1+-parseInt(_0x371759(0x18d))/0x2*(parseInt(_0x371759(0x18c))/0x3)+parseInt(_0x371759(0x18b))/0x4*(-parseInt(_0x371759(0x185))/0x5)+-parseInt(_0x371759(0x191))/0x6+parseInt(_0x371759(0x175))/0x7*(-parseInt(_0x371759(0x186))/0x8)+-parseInt(_0x371759(0x189))/0x9*(parseInt(_0x371759(0x173))/0xa)+parseInt(_0x371759(0x17c))/0xb;if(_0x35e57b===_0x5c19a1)break;else _0x30e7e9['push'](_0x30e7e9['shift']());}catch(_0xe9ce5f){_0x30e7e9['push'](_0x30e7e9['shift']());}}}(a97_0x2e1b,0x227c3));import{CliError}from'../../errors.js';function a97_0x5e20(_0x16ced5,_0x53adf4){_0x16ced5=_0x16ced5-0x172;const _0x2e1b27=a97_0x2e1b();let _0x5e20e1=_0x2e1b27[_0x16ced5];return _0x5e20e1;}import{CLI_BIN_NAME}from'../../constant/cli.js';function a97_0x2e1b(){const _0x4a8cf3=['code','not_in_project','\x22\x20\x5c','command','report','\x20\x20\x20\x20--description\x20\x22Steps\x20to\x20reproduce,\x20expected\x20vs\x20actual,\x20and\x20any\x20relevant\x20logs.\x22','\x20\x20(Cookies\x20/\x20Authorization\x20/\x20access\x20keys\x20are\x20automatically\x20redacted\x20before\x20upload.)','\x20\x20Set\x20','209730eicItI','8iAoAVu','replace','write','1763523kxVfKQ','trim','20jZNVoJ','6gMKIRH','241426zqXRXT','175427afNTQU','config_missing','length','323238VOnmiR','flag_missing','RABETBASE_DISABLE_ISSUE_NUDGE','issue','service','\x20issue\x20report\x20\x5c','10LRZRsp','slice','445823csDGbj','Hit\x20a\x20','network_error','cancelled','validation_error','message','=1\x20to\x20silence\x20this\x20hint.','8035379mqVVws'];a97_0x2e1b=function(){return _0x4a8cf3;};return a97_0x2e1b();}export const NUDGE_OPT_OUT_ENV=a97_0x4a0c46(0x193);const NUDGE_SUPPRESSED_CODES=new Set([a97_0x4a0c46(0x178),'auth_required',a97_0x4a0c46(0x18f),a97_0x4a0c46(0x17e),'unknown_command',a97_0x4a0c46(0x192),a97_0x4a0c46(0x179),a97_0x4a0c46(0x177)]),defaultWriter=_0x3ae7a7=>{const _0x11361a=a97_0x4a0c46;process['stderr'][_0x11361a(0x188)](_0x3ae7a7);};export function shouldNudgeForError(_0x4ea103,_0x26df6a){const _0x4b020d=a97_0x4a0c46;if(process.env[NUDGE_OPT_OUT_ENV]==='1')return![];if(_0x26df6a[_0x4b020d(0x195)]===_0x4b020d(0x194)&&_0x26df6a[_0x4b020d(0x180)]===_0x4b020d(0x181))return![];if(_0x4ea103 instanceof CliError)return!NUDGE_SUPPRESSED_CODES['has'](_0x4ea103[_0x4b020d(0x17d)]);return!![];}export function printIssueReportNudgeForError(_0x51b3d5,_0x3936fd,_0x4672bc=defaultWriter){if(!shouldNudgeForError(_0x51b3d5,_0x3936fd))return;const _0x3360db=buildSuggestedTitle(_0x51b3d5,_0x3936fd);_0x4672bc(formatNudge(_0x3360db));}function buildSuggestedTitle(_0x186c90,_0x35e1f6){const _0x33188b=a97_0x4a0c46,_0x5e2c90=_0x186c90 instanceof Error?_0x186c90[_0x33188b(0x17a)]:String(_0x186c90),_0x19ab63=_0x5e2c90[_0x33188b(0x187)](/[\r\n]+/g,'\x20')[_0x33188b(0x187)](/\s+/g,'\x20')[_0x33188b(0x18a)]()[_0x33188b(0x174)](0x0,0x78)['replace'](/"/g,'\x5c\x22'),_0x2676f2=CLI_BIN_NAME+'\x20'+_0x35e1f6[_0x33188b(0x195)]+'\x20'+_0x35e1f6['command'];return _0x19ab63[_0x33188b(0x190)]>0x0?_0x2676f2+':\x20'+_0x19ab63:_0x2676f2;}function formatNudge(_0x126af9){const _0x16479c=a97_0x4a0c46;return['',_0x16479c(0x176)+CLI_BIN_NAME+'\x20bug?\x20Help\x20us\x20fix\x20it:','\x20\x20'+CLI_BIN_NAME+_0x16479c(0x172),'\x20\x20\x20\x20--title\x20\x22'+_0x126af9+_0x16479c(0x17f),_0x16479c(0x182),_0x16479c(0x183),_0x16479c(0x184)+NUDGE_OPT_OUT_ENV+_0x16479c(0x17b),'']['join']('\x0a');}
@@ -1 +1 @@
1
- const a98_0x1f5744=a98_0x24ad;(function(_0x184529,_0x301434){const _0x1d9841=a98_0x24ad,_0x2e1202=_0x184529();while(!![]){try{const _0x289359=parseInt(_0x1d9841(0x17e))/0x1+-parseInt(_0x1d9841(0x179))/0x2*(-parseInt(_0x1d9841(0x17a))/0x3)+-parseInt(_0x1d9841(0x158))/0x4+parseInt(_0x1d9841(0x16f))/0x5+-parseInt(_0x1d9841(0x16b))/0x6*(parseInt(_0x1d9841(0x176))/0x7)+parseInt(_0x1d9841(0x178))/0x8+-parseInt(_0x1d9841(0x16e))/0x9;if(_0x289359===_0x301434)break;else _0x2e1202['push'](_0x2e1202['shift']());}catch(_0x50c404){_0x2e1202['push'](_0x2e1202['shift']());}}}(a98_0x49b4,0xcf7ba));import{existsSync}from'node:fs';import{readFile}from'node:fs/promises';import{resolve}from'node:path';import{CliErrors}from'../../errors.js';import{sanitizeIssueDescription}from'../../commands/issue/shared.js';import{PLATFORM_ISSUE_SPAN_NAME,PLATFORM_ISSUE_TRACE_NAME,sendPlatformIssueCollectLog}from'../../telemetry/send-platform-issue-collect-log.js';const DESCRIPTION_FILE_FLAG=a98_0x1f5744(0x163);function a98_0x24ad(_0x43d36e,_0x44fdea){_0x43d36e=_0x43d36e-0x153;const _0x49b401=a98_0x49b4();let _0x24adb5=_0x49b401[_0x43d36e];return _0x24adb5;}export const issueReport={'service':a98_0x1f5744(0x187),'command':a98_0x1f5744(0x16a),'description':a98_0x1f5744(0x15e),'risk':a98_0x1f5744(0x157),'requiresAuth':!![],'requiresAppCode':![],'defaultOutputFormat':a98_0x1f5744(0x164),'flags':[{'name':a98_0x1f5744(0x173),'type':a98_0x1f5744(0x17d),'required':!![],'description':a98_0x1f5744(0x177)},{'name':a98_0x1f5744(0x153),'type':a98_0x1f5744(0x17d),'description':a98_0x1f5744(0x15a)},{'name':DESCRIPTION_FILE_FLAG,'type':a98_0x1f5744(0x17d),'description':'Path\x20to\x20a\x20markdown\x20file\x20whose\x20contents\x20become\x20issue.description'}],async 'validate'(_0x4df9bd){const _0x584df0=a98_0x1f5744,_0x31887a=_0x4df9bd['str'](_0x584df0(0x173))[_0x584df0(0x17c)](),_0x4ecddb=_0x4df9bd[_0x584df0(0x15c)](_0x584df0(0x153))[_0x584df0(0x17c)](),_0x1a2a35=_0x4df9bd[_0x584df0(0x15c)](DESCRIPTION_FILE_FLAG)[_0x584df0(0x17c)]();if(!_0x31887a)throw CliErrors['flagMissing'](_0x584df0(0x173),_0x584df0(0x174));const _0x5b875b=_0x4ecddb[_0x584df0(0x185)]>0x0,_0x5ab030=_0x1a2a35[_0x584df0(0x185)]>0x0;if(_0x5b875b===_0x5ab030)throw CliErrors[_0x584df0(0x17b)]('Provide\x20exactly\x20one\x20of\x20--description\x20or\x20--description-file.',_0x584df0(0x17f));if(_0x5ab030){const _0x4858fb=resolve(process[_0x584df0(0x186)](),_0x1a2a35);if(!existsSync(_0x4858fb))throw CliErrors[_0x584df0(0x17b)](_0x584df0(0x181)+_0x4858fb);}},async 'dryRun'(_0x11a1d8){const _0x3bf250=a98_0x1f5744,_0x477185=await prepareIssueReport(_0x11a1d8);return{'method':_0x3bf250(0x159),'url':'otel://'+PLATFORM_ISSUE_TRACE_NAME+'/'+PLATFORM_ISSUE_SPAN_NAME,'body':{'traceName':PLATFORM_ISSUE_TRACE_NAME,'spanName':PLATFORM_ISSUE_SPAN_NAME,'logData':{'issue.title':_0x477185[_0x3bf250(0x173)],'issue.description':_0x477185[_0x3bf250(0x153)],'issue.description_original_bytes':_0x477185[_0x3bf250(0x188)][_0x3bf250(0x180)],'issue.description_truncated':_0x477185[_0x3bf250(0x188)][_0x3bf250(0x184)],'issue.description_redactions':_0x477185[_0x3bf250(0x188)][_0x3bf250(0x15d)],'issue.description_redaction_kinds':_0x477185['sanitize'][_0x3bf250(0x165)][_0x3bf250(0x156)](',')}},'description':['Send\x20platform\x20issue\x20collect\x20log\x20via\x20the\x20CLI\x20telemetry\x20adapter',_0x3bf250(0x175)+_0x477185['descriptionSource'],_0x477185[_0x3bf250(0x172)]?_0x3bf250(0x155)+_0x477185[_0x3bf250(0x172)]:null,_0x477185[_0x3bf250(0x188)][_0x3bf250(0x184)]?_0x3bf250(0x189)+_0x477185['sanitize'][_0x3bf250(0x180)]+_0x3bf250(0x169):null,_0x477185[_0x3bf250(0x188)][_0x3bf250(0x15d)]>0x0?'redactions:\x20'+_0x477185[_0x3bf250(0x188)][_0x3bf250(0x15d)]+'\x20('+_0x477185[_0x3bf250(0x188)][_0x3bf250(0x165)][_0x3bf250(0x156)](',\x20')+')':null]['filter'](Boolean)[_0x3bf250(0x156)]('\x0a')};},async 'execute'(_0x50893f){const _0x1839e9=a98_0x1f5744,_0x1f3417=await prepareIssueReport(_0x50893f);try{await sendPlatformIssueCollectLog({'title':_0x1f3417['title'],'description':_0x1f3417[_0x1839e9(0x153)],'sanitize':{'originalBytes':_0x1f3417[_0x1839e9(0x188)][_0x1839e9(0x180)],'truncated':_0x1f3417[_0x1839e9(0x188)]['truncated'],'redactionCount':_0x1f3417[_0x1839e9(0x188)][_0x1839e9(0x15d)],'redactionKinds':_0x1f3417['sanitize']['redactionKinds']}});}catch(_0x23410d){throw CliErrors[_0x1839e9(0x170)](_0x1839e9(0x18a)+(_0x23410d instanceof Error?_0x23410d['message']:String(_0x23410d)),_0x1839e9(0x16c));}return{'ok':!![],'message':buildResultMessage(_0x1f3417['sanitize']),'data':{'traceName':PLATFORM_ISSUE_TRACE_NAME,'spanName':PLATFORM_ISSUE_SPAN_NAME,'logDataKeys':[_0x1839e9(0x166),'issue.description',_0x1839e9(0x161),_0x1839e9(0x171),_0x1839e9(0x18b),_0x1839e9(0x15b)],'issue':{'title':_0x1f3417[_0x1839e9(0x173)],'descriptionLength':_0x1f3417['description'][_0x1839e9(0x185)],'descriptionSource':_0x1f3417['descriptionSource'],..._0x1f3417[_0x1839e9(0x172)]?{'descriptionFile':_0x1f3417[_0x1839e9(0x172)]}:{},'sanitize':{'originalBytes':_0x1f3417[_0x1839e9(0x188)][_0x1839e9(0x180)],'truncated':_0x1f3417[_0x1839e9(0x188)][_0x1839e9(0x184)],'redactions':_0x1f3417['sanitize'][_0x1839e9(0x15d)],'redactionKinds':_0x1f3417[_0x1839e9(0x188)][_0x1839e9(0x165)]}}}};}};function a98_0x49b4(){const _0x2fad0c=['762320qydFul','Use\x20--description\x20for\x20short\x20markdown\x20text,\x20or\x20--description-file\x20for\x20full\x20issue\x20context.','originalBytes','File\x20not\x20found:\x20','file','Platform\x20issue\x20reported','truncated','length','cwd','issue','sanitize','truncated:\x20original\x20','Failed\x20to\x20report\x20platform\x20issue:\x20','issue.description_redactions','description','Write\x20markdown\x20context\x20into\x20the\x20file\x20before\x20retrying.','descriptionFile:\x20','join','write','4192588oaqhiX','POST','Inline\x20markdown\x20issue\x20description\x20(alternative\x20to\x20--description-file)','issue.description_redaction_kinds','str','redactionCount','Report\x20a\x20platform\x20issue\x20with\x20title\x20and\x20markdown\x20context','Platform\x20issue\x20reported\x20(','Issue\x20description\x20cannot\x20be\x20empty.','issue.description_original_bytes','redacted\x20','description-file','compress','redactionKinds','issue.title','Provide\x20non-empty\x20markdown\x20content\x20via\x20--description\x20or\x20--description-file.','push','\x20bytes','report','156jjaKdB','Check\x20telemetry\x20configuration\x20and\x20network\x20reachability,\x20then\x20retry.','inline','7280307QASkRJ','5024455NNiTyc','apiError','issue.description_truncated','descriptionFilePath','title','Provide\x20--title\x20with\x20a\x20one-line\x20issue\x20summary.','descriptionSource:\x20','777cyJoJx','One-line\x20issue\x20summary','5903968tIjShU','2GsLoNL','613797VGaOSD','validation','trim','string'];a98_0x49b4=function(){return _0x2fad0c;};return a98_0x49b4();}function buildResultMessage(_0x275d1e){const _0x2a8b3f=a98_0x1f5744,_0x2048b0=[];return _0x275d1e[_0x2a8b3f(0x184)]&&_0x2048b0[_0x2a8b3f(0x168)]('truncated\x20from\x20'+_0x275d1e[_0x2a8b3f(0x180)]+_0x2a8b3f(0x169)),_0x275d1e['redactionCount']>0x0&&_0x2048b0['push'](_0x2a8b3f(0x162)+_0x275d1e[_0x2a8b3f(0x15d)]+'\x20secret(s):\x20'+_0x275d1e[_0x2a8b3f(0x165)]['join'](',\x20')),_0x2048b0[_0x2a8b3f(0x185)]===0x0?_0x2a8b3f(0x183):_0x2a8b3f(0x15f)+_0x2048b0['join'](';\x20')+')';}async function prepareIssueReport(_0x3a5c19){const _0x30ae3d=a98_0x1f5744,_0x3b6c35=_0x3a5c19['str']('title')['trim'](),_0x28317d=_0x3a5c19[_0x30ae3d(0x15c)]('description'),_0x47d103=_0x3a5c19[_0x30ae3d(0x15c)](DESCRIPTION_FILE_FLAG)[_0x30ae3d(0x17c)]();if(!_0x47d103){const _0x6478bf=_0x28317d;if(!_0x6478bf[_0x30ae3d(0x17c)]())throw CliErrors[_0x30ae3d(0x17b)](_0x30ae3d(0x160),_0x30ae3d(0x167));const _0x18bf5d=sanitizeIssueDescription(_0x6478bf);return{'title':_0x3b6c35,'description':_0x18bf5d[_0x30ae3d(0x153)],'descriptionSource':_0x30ae3d(0x16d),'sanitize':_0x18bf5d};}const _0x36bc7e=resolve(process[_0x30ae3d(0x186)](),_0x47d103),_0x18ff70=await readFile(_0x36bc7e,'utf8');if(!_0x18ff70[_0x30ae3d(0x17c)]())throw CliErrors[_0x30ae3d(0x17b)]('Issue\x20description\x20file\x20is\x20empty:\x20'+_0x36bc7e,_0x30ae3d(0x154));const _0x2e9f4d=sanitizeIssueDescription(_0x18ff70);return{'title':_0x3b6c35,'description':_0x2e9f4d[_0x30ae3d(0x153)],'descriptionSource':_0x30ae3d(0x182),'descriptionFilePath':_0x36bc7e,'sanitize':_0x2e9f4d};}
1
+ const a98_0x7e8a3d=a98_0x35f6;(function(_0x4208b6,_0x8a2dfc){const _0x458731=a98_0x35f6,_0xa87915=_0x4208b6();while(!![]){try{const _0x25c03b=-parseInt(_0x458731(0x170))/0x1+parseInt(_0x458731(0x159))/0x2+parseInt(_0x458731(0x14b))/0x3*(-parseInt(_0x458731(0x152))/0x4)+parseInt(_0x458731(0x181))/0x5+-parseInt(_0x458731(0x15d))/0x6*(parseInt(_0x458731(0x156))/0x7)+parseInt(_0x458731(0x14e))/0x8*(parseInt(_0x458731(0x148))/0x9)+parseInt(_0x458731(0x15a))/0xa;if(_0x25c03b===_0x8a2dfc)break;else _0xa87915['push'](_0xa87915['shift']());}catch(_0x30ae09){_0xa87915['push'](_0xa87915['shift']());}}}(a98_0x6c6d,0xcb716));import{existsSync}from'node:fs';import{readFile}from'node:fs/promises';import{resolve}from'node:path';import{CliErrors}from'../../errors.js';function a98_0x35f6(_0x13d4a8,_0x3697cc){_0x13d4a8=_0x13d4a8-0x146;const _0x6c6d4=a98_0x6c6d();let _0x35f6a9=_0x6c6d4[_0x13d4a8];return _0x35f6a9;}import{sanitizeIssueDescription}from'../../commands/issue/shared.js';import{PLATFORM_ISSUE_SPAN_NAME,PLATFORM_ISSUE_TRACE_NAME,sendPlatformIssueCollectLog}from'../../telemetry/send-platform-issue-collect-log.js';const DESCRIPTION_FILE_FLAG=a98_0x7e8a3d(0x154);export const issueReport={'service':a98_0x7e8a3d(0x16b),'command':a98_0x7e8a3d(0x174),'description':a98_0x7e8a3d(0x149),'risk':a98_0x7e8a3d(0x161),'requiresAuth':!![],'requiresAppCode':![],'defaultOutputFormat':a98_0x7e8a3d(0x172),'flags':[{'name':a98_0x7e8a3d(0x157),'type':'string','required':!![],'description':'One-line\x20issue\x20summary'},{'name':a98_0x7e8a3d(0x173),'type':a98_0x7e8a3d(0x169),'description':a98_0x7e8a3d(0x162)},{'name':DESCRIPTION_FILE_FLAG,'type':a98_0x7e8a3d(0x169),'description':a98_0x7e8a3d(0x153)}],async 'validate'(_0x5c1992){const _0x35ce15=a98_0x7e8a3d,_0x2db3f7=_0x5c1992[_0x35ce15(0x171)](_0x35ce15(0x157))[_0x35ce15(0x15f)](),_0x57d4f0=_0x5c1992[_0x35ce15(0x171)](_0x35ce15(0x173))[_0x35ce15(0x15f)](),_0x17c791=_0x5c1992[_0x35ce15(0x171)](DESCRIPTION_FILE_FLAG)[_0x35ce15(0x15f)]();if(!_0x2db3f7)throw CliErrors[_0x35ce15(0x14d)](_0x35ce15(0x157),_0x35ce15(0x176));const _0x20bbde=_0x57d4f0[_0x35ce15(0x16a)]>0x0,_0xa359ee=_0x17c791[_0x35ce15(0x16a)]>0x0;if(_0x20bbde===_0xa359ee)throw CliErrors[_0x35ce15(0x163)](_0x35ce15(0x168),'Use\x20--description\x20for\x20short\x20markdown\x20text,\x20or\x20--description-file\x20for\x20full\x20issue\x20context.');if(_0xa359ee){const _0x86033d=resolve(process[_0x35ce15(0x175)](),_0x17c791);if(!existsSync(_0x86033d))throw CliErrors[_0x35ce15(0x163)](_0x35ce15(0x165)+_0x86033d);}},async 'dryRun'(_0x3b1413){const _0x3e5fce=a98_0x7e8a3d,_0x5439e5=await prepareIssueReport(_0x3b1413);return{'method':'POST','url':'otel://'+PLATFORM_ISSUE_TRACE_NAME+'/'+PLATFORM_ISSUE_SPAN_NAME,'body':{'traceName':PLATFORM_ISSUE_TRACE_NAME,'spanName':PLATFORM_ISSUE_SPAN_NAME,'logData':{'issue.title':_0x5439e5[_0x3e5fce(0x157)],'issue.description':_0x5439e5['description'],'issue.description_original_bytes':_0x5439e5[_0x3e5fce(0x155)][_0x3e5fce(0x146)],'issue.description_truncated':_0x5439e5[_0x3e5fce(0x155)][_0x3e5fce(0x147)],'issue.description_redactions':_0x5439e5[_0x3e5fce(0x155)]['redactionCount'],'issue.description_redaction_kinds':_0x5439e5[_0x3e5fce(0x155)][_0x3e5fce(0x164)][_0x3e5fce(0x14a)](',')}},'description':['Send\x20platform\x20issue\x20collect\x20log\x20via\x20the\x20CLI\x20telemetry\x20adapter',_0x3e5fce(0x16d)+_0x5439e5[_0x3e5fce(0x16c)],_0x5439e5[_0x3e5fce(0x166)]?_0x3e5fce(0x150)+_0x5439e5[_0x3e5fce(0x166)]:null,_0x5439e5[_0x3e5fce(0x155)][_0x3e5fce(0x147)]?_0x3e5fce(0x14c)+_0x5439e5[_0x3e5fce(0x155)]['originalBytes']+'\x20bytes':null,_0x5439e5[_0x3e5fce(0x155)][_0x3e5fce(0x17a)]>0x0?_0x3e5fce(0x160)+_0x5439e5[_0x3e5fce(0x155)][_0x3e5fce(0x17a)]+'\x20('+_0x5439e5['sanitize']['redactionKinds'][_0x3e5fce(0x14a)](',\x20')+')':null][_0x3e5fce(0x17e)](Boolean)[_0x3e5fce(0x14a)]('\x0a')};},async 'execute'(_0x152a25){const _0x536096=a98_0x7e8a3d,_0x4259c0=await prepareIssueReport(_0x152a25);try{await sendPlatformIssueCollectLog({'title':_0x4259c0['title'],'description':_0x4259c0[_0x536096(0x173)],'sanitize':{'originalBytes':_0x4259c0[_0x536096(0x155)][_0x536096(0x146)],'truncated':_0x4259c0[_0x536096(0x155)]['truncated'],'redactionCount':_0x4259c0[_0x536096(0x155)][_0x536096(0x17a)],'redactionKinds':_0x4259c0[_0x536096(0x155)][_0x536096(0x164)]}});}catch(_0x5b5472){throw CliErrors[_0x536096(0x178)](_0x536096(0x16f)+(_0x5b5472 instanceof Error?_0x5b5472[_0x536096(0x180)]:String(_0x5b5472)),_0x536096(0x16e));}return{'ok':!![],'message':buildResultMessage(_0x4259c0['sanitize']),'data':{'traceName':PLATFORM_ISSUE_TRACE_NAME,'spanName':PLATFORM_ISSUE_SPAN_NAME,'logDataKeys':['issue.title',_0x536096(0x167),'issue.description_original_bytes','issue.description_truncated',_0x536096(0x17c),_0x536096(0x15b)],'issue':{'title':_0x4259c0['title'],'descriptionLength':_0x4259c0['description'][_0x536096(0x16a)],'descriptionSource':_0x4259c0[_0x536096(0x16c)],..._0x4259c0['descriptionFilePath']?{'descriptionFile':_0x4259c0['descriptionFilePath']}:{},'sanitize':{'originalBytes':_0x4259c0['sanitize'][_0x536096(0x146)],'truncated':_0x4259c0[_0x536096(0x155)][_0x536096(0x147)],'redactions':_0x4259c0['sanitize'][_0x536096(0x17a)],'redactionKinds':_0x4259c0[_0x536096(0x155)]['redactionKinds']}}}};}};function buildResultMessage(_0x12932f){const _0x57886d=a98_0x7e8a3d,_0x4b29e4=[];return _0x12932f[_0x57886d(0x147)]&&_0x4b29e4['push'](_0x57886d(0x177)+_0x12932f['originalBytes']+_0x57886d(0x14f)),_0x12932f[_0x57886d(0x17a)]>0x0&&_0x4b29e4['push']('redacted\x20'+_0x12932f[_0x57886d(0x17a)]+_0x57886d(0x179)+_0x12932f[_0x57886d(0x164)][_0x57886d(0x14a)](',\x20')),_0x4b29e4['length']===0x0?'Platform\x20issue\x20reported':_0x57886d(0x17f)+_0x4b29e4[_0x57886d(0x14a)](';\x20')+')';}function a98_0x6c6d(){const _0xe12f1c=['inline','filter','Platform\x20issue\x20reported\x20(','message','6073265FVBsrU','originalBytes','truncated','12879VajVev','Report\x20a\x20platform\x20issue\x20with\x20title\x20and\x20markdown\x20context','join','2808dndkjW','truncated:\x20original\x20','flagMissing','672iPnhht','\x20bytes','descriptionFile:\x20','Provide\x20non-empty\x20markdown\x20content\x20via\x20--description\x20or\x20--description-file.','6924edjdCy','Path\x20to\x20a\x20markdown\x20file\x20whose\x20contents\x20become\x20issue.description','description-file','sanitize','7JVjMbm','title','Write\x20markdown\x20context\x20into\x20the\x20file\x20before\x20retrying.','328248ruvaIG','16641260Phrpsd','issue.description_redaction_kinds','utf8','2055306UToVlu','Issue\x20description\x20file\x20is\x20empty:\x20','trim','redactions:\x20','write','Inline\x20markdown\x20issue\x20description\x20(alternative\x20to\x20--description-file)','validation','redactionKinds','File\x20not\x20found:\x20','descriptionFilePath','issue.description','Provide\x20exactly\x20one\x20of\x20--description\x20or\x20--description-file.','string','length','issue','descriptionSource','descriptionSource:\x20','Check\x20telemetry\x20configuration\x20and\x20network\x20reachability,\x20then\x20retry.','Failed\x20to\x20report\x20platform\x20issue:\x20','367038ZevyGN','str','compress','description','report','cwd','Provide\x20--title\x20with\x20a\x20one-line\x20issue\x20summary.','truncated\x20from\x20','apiError','\x20secret(s):\x20','redactionCount','Issue\x20description\x20cannot\x20be\x20empty.','issue.description_redactions'];a98_0x6c6d=function(){return _0xe12f1c;};return a98_0x6c6d();}async function prepareIssueReport(_0x9a9605){const _0x5543d3=a98_0x7e8a3d,_0x1a09db=_0x9a9605['str'](_0x5543d3(0x157))['trim'](),_0x71be4f=_0x9a9605[_0x5543d3(0x171)](_0x5543d3(0x173)),_0xc9ff72=_0x9a9605[_0x5543d3(0x171)](DESCRIPTION_FILE_FLAG)['trim']();if(!_0xc9ff72){const _0x28f83d=_0x71be4f;if(!_0x28f83d[_0x5543d3(0x15f)]())throw CliErrors[_0x5543d3(0x163)](_0x5543d3(0x17b),_0x5543d3(0x151));const _0x549abc=sanitizeIssueDescription(_0x28f83d);return{'title':_0x1a09db,'description':_0x549abc[_0x5543d3(0x173)],'descriptionSource':_0x5543d3(0x17d),'sanitize':_0x549abc};}const _0x6708c8=resolve(process[_0x5543d3(0x175)](),_0xc9ff72),_0x2b5994=await readFile(_0x6708c8,_0x5543d3(0x15c));if(!_0x2b5994['trim']())throw CliErrors['validation'](_0x5543d3(0x15e)+_0x6708c8,_0x5543d3(0x158));const _0x2c6579=sanitizeIssueDescription(_0x2b5994);return{'title':_0x1a09db,'description':_0x2c6579[_0x5543d3(0x173)],'descriptionSource':'file','descriptionFilePath':_0x6708c8,'sanitize':_0x2c6579};}
@@ -1 +1 @@
1
- const a99_0x53fa73=a99_0x119f;(function(_0x4093e5,_0x34e2a4){const _0x34f2f0=a99_0x119f,_0x5b4a90=_0x4093e5();while(!![]){try{const _0x5bd9c2=parseInt(_0x34f2f0(0x18e))/0x1+-parseInt(_0x34f2f0(0x17b))/0x2*(-parseInt(_0x34f2f0(0x18c))/0x3)+parseInt(_0x34f2f0(0x191))/0x4+-parseInt(_0x34f2f0(0x180))/0x5*(-parseInt(_0x34f2f0(0x188))/0x6)+parseInt(_0x34f2f0(0x192))/0x7+parseInt(_0x34f2f0(0x195))/0x8+parseInt(_0x34f2f0(0x183))/0x9*(-parseInt(_0x34f2f0(0x18d))/0xa);if(_0x5bd9c2===_0x34e2a4)break;else _0x5b4a90['push'](_0x5b4a90['shift']());}catch(_0x25287e){_0x5b4a90['push'](_0x5b4a90['shift']());}}}(a99_0x56db,0xbb727));function a99_0x119f(_0x40a1db,_0x561123){_0x40a1db=_0x40a1db-0x17a;const _0x56db0f=a99_0x56db();let _0x119fd3=_0x56db0f[_0x40a1db];return _0x119fd3;}export const ISSUE_DESCRIPTION_MAX_BYTES=0x100*0x400;const TRUNCATION_NOTICE='\x0a\x0a[...TRUNCATED\x20by\x20rabetbase-cli...]',REDACTION_RULES=[{'kind':a99_0x53fa73(0x189),'pattern':/(cookie\s*[:=]\s*)[^\s;,'"`]+/gi,'label':a99_0x53fa73(0x17d)},{'kind':a99_0x53fa73(0x185),'pattern':/(authorization\s*:\s*)(bearer|basic|token)\s+[^\s'"`]+/gi,'label':a99_0x53fa73(0x182)},{'kind':'private-key','pattern':/-----BEGIN [A-Z0-9 ]*PRIVATE KEY-----[\s\S]*?-----END [A-Z0-9 ]*PRIVATE KEY-----/g,'label':'REDACTED:private-key'},{'kind':a99_0x53fa73(0x17c),'pattern':/((?:aliyun_)?(?:access|secret)[_-]?key(?:[_-]?id)?\s*[:=]\s*)['"]?[A-Za-z0-9/+_\-]{8,}['"]?/gi,'label':a99_0x53fa73(0x193)},{'kind':a99_0x53fa73(0x181),'pattern':/(pass(?:word|wd)\s*[:=]\s*)['"]?[^\s'"`]+['"]?/gi,'label':a99_0x53fa73(0x186)},{'kind':a99_0x53fa73(0x184),'pattern':/\beyJ[A-Za-z0-9_-]{10,}\.[A-Za-z0-9_-]{10,}\.[A-Za-z0-9_-]{10,}\b/g,'label':'REDACTED:bearer-jwt'}];export function sanitizeIssueDescription(_0x35b4d7){const _0x5d0fa3=a99_0x53fa73,_0x12e8cd=Buffer[_0x5d0fa3(0x194)](_0x35b4d7,_0x5d0fa3(0x17f)),_0x1cf6aa=process.env.RABETBASE_ISSUE_RAW_DESCRIPTION==='1';let _0x2b5b4e=_0x35b4d7,_0x3665b0=0x0;const _0x294b65=[];if(!_0x1cf6aa){const _0x215b52=protectOssAccessKeyIds(_0x2b5b4e);_0x2b5b4e=_0x215b52[_0x5d0fa3(0x18f)];for(const _0x3813fc of REDACTION_RULES){let _0x44547a=0x0;_0x2b5b4e=_0x2b5b4e['replace'](_0x3813fc['pattern'],(_0x3c98db,_0x93b48f)=>{_0x44547a+=0x1;const _0x4e7836=typeof _0x93b48f==='string'?_0x93b48f:'';return _0x4e7836+'['+_0x3813fc['label']+']';}),_0x44547a>0x0&&(_0x3665b0+=_0x44547a,!_0x294b65['includes'](_0x3813fc[_0x5d0fa3(0x18b)])&&_0x294b65[_0x5d0fa3(0x17e)](_0x3813fc[_0x5d0fa3(0x18b)]));}_0x2b5b4e=_0x215b52[_0x5d0fa3(0x187)](_0x2b5b4e);}let _0x257eff=![];if(Buffer[_0x5d0fa3(0x194)](_0x2b5b4e,_0x5d0fa3(0x17f))>ISSUE_DESCRIPTION_MAX_BYTES){_0x257eff=!![];const _0x302c9b=Buffer[_0x5d0fa3(0x194)](TRUNCATION_NOTICE,_0x5d0fa3(0x17f)),_0x14e2a7=Math['max'](0x0,ISSUE_DESCRIPTION_MAX_BYTES-_0x302c9b);_0x2b5b4e=sliceUtf8Bytes(_0x2b5b4e,_0x14e2a7)+TRUNCATION_NOTICE;}return{'description':_0x2b5b4e,'originalBytes':_0x12e8cd,'truncated':_0x257eff,'redactionCount':_0x3665b0,'redactionKinds':_0x294b65};}function protectOssAccessKeyIds(_0x39ba2c){const _0x1815b9=a99_0x53fa73,_0xe37683=[],_0x39df9a=_0x39ba2c[_0x1815b9(0x18a)](/([?&])OSSAccessKeyId=([A-Za-z0-9/+_\-]{8,})/gi,(_0x3993c0,_0x3fa202)=>{const _0x59c63e=_0x1815b9,_0x4b0994=_0xe37683[_0x59c63e(0x17e)](_0x3993c0['slice'](_0x3fa202[_0x59c63e(0x17a)]))-0x1;return _0x3fa202+'__RB_OSS_ID_'+_0x4b0994+'__';});return{'description':_0x39df9a,'restore':_0x3a1ea3=>_0x3a1ea3['replace'](/([?&])__RB_OSS_ID_(\d+)__/g,(_0x3442c0,_0x1e460c,_0x2c6b13)=>{const _0x48e2d1=_0xe37683[Number(_0x2c6b13)];return _0x48e2d1===undefined?_0x3442c0:''+_0x1e460c+_0x48e2d1;})};}function sliceUtf8Bytes(_0x566f29,_0x5ba14f){const _0xfbad62=a99_0x53fa73;if(_0x5ba14f<=0x0)return'';const _0x26557a=Buffer['from'](_0x566f29,_0xfbad62(0x17f));if(_0x26557a['byteLength']<=_0x5ba14f)return _0x566f29;let _0x4c141e=_0x5ba14f;while(_0x4c141e>0x0){const _0x4df49c=_0x26557a[_0x4c141e];if(_0x4df49c===undefined||(_0x4df49c&0xc0)!==0x80)break;_0x4c141e-=0x1;}return _0x26557a[_0xfbad62(0x196)](0x0,_0x4c141e)[_0xfbad62(0x190)](_0xfbad62(0x17f));}function a99_0x56db(){const _0x14864f=['byteLength','373960UDSiMQ','subarray','length','1419798XSWkIe','access-key','REDACTED:cookie','push','utf8','3864235LOmVgR','password','REDACTED:authorization','99261aWFQmh','bearer-jwt','authorization','REDACTED:password','restore','6joNrdL','cookie','replace','kind','3MDyQcV','2130KujUwl','875086gZEfGk','description','toString','2575660NJenlK','479276kfweuP','REDACTED:access-key'];a99_0x56db=function(){return _0x14864f;};return a99_0x56db();}
1
+ const a99_0x29f5bf=a99_0x13ca;(function(_0x4460cf,_0x35fb46){const _0x5e6fd0=a99_0x13ca,_0x29f010=_0x4460cf();while(!![]){try{const _0x31babf=parseInt(_0x5e6fd0(0x13e))/0x1+-parseInt(_0x5e6fd0(0x134))/0x2+parseInt(_0x5e6fd0(0x133))/0x3*(parseInt(_0x5e6fd0(0x139))/0x4)+parseInt(_0x5e6fd0(0x14d))/0x5+parseInt(_0x5e6fd0(0x132))/0x6*(parseInt(_0x5e6fd0(0x144))/0x7)+parseInt(_0x5e6fd0(0x140))/0x8*(-parseInt(_0x5e6fd0(0x130))/0x9)+parseInt(_0x5e6fd0(0x138))/0xa;if(_0x31babf===_0x35fb46)break;else _0x29f010['push'](_0x29f010['shift']());}catch(_0x5a28cf){_0x29f010['push'](_0x29f010['shift']());}}}(a99_0x35a7,0xa1ba6));export const ISSUE_DESCRIPTION_MAX_BYTES=0x100*0x400;const TRUNCATION_NOTICE='\x0a\x0a[...TRUNCATED\x20by\x20rabetbase-cli...]',REDACTION_RULES=[{'kind':a99_0x29f5bf(0x149),'pattern':/(cookie\s*[:=]\s*)[^\s;,'"`]+/gi,'label':'REDACTED:cookie'},{'kind':a99_0x29f5bf(0x13c),'pattern':/(authorization\s*:\s*)(bearer|basic|token)\s+[^\s'"`]+/gi,'label':'REDACTED:authorization'},{'kind':a99_0x29f5bf(0x131),'pattern':/-----BEGIN [A-Z0-9 ]*PRIVATE KEY-----[\s\S]*?-----END [A-Z0-9 ]*PRIVATE KEY-----/g,'label':a99_0x29f5bf(0x150)},{'kind':a99_0x29f5bf(0x148),'pattern':/((?:aliyun_)?(?:access|secret)[_-]?key(?:[_-]?id)?\s*[:=]\s*)['"]?[A-Za-z0-9/+_\-]{8,}['"]?/gi,'label':a99_0x29f5bf(0x136)},{'kind':a99_0x29f5bf(0x14e),'pattern':/(pass(?:word|wd)\s*[:=]\s*)['"]?[^\s'"`]+['"]?/gi,'label':a99_0x29f5bf(0x143)},{'kind':a99_0x29f5bf(0x147),'pattern':/\beyJ[A-Za-z0-9_-]{10,}\.[A-Za-z0-9_-]{10,}\.[A-Za-z0-9_-]{10,}\b/g,'label':a99_0x29f5bf(0x137)}];function a99_0x13ca(_0x3d56eb,_0x3346e3){_0x3d56eb=_0x3d56eb-0x12d;const _0x35a7cb=a99_0x35a7();let _0x13ca29=_0x35a7cb[_0x3d56eb];return _0x13ca29;}export function sanitizeIssueDescription(_0x1c2268){const _0x2e456b=a99_0x29f5bf,_0x5f0526=Buffer[_0x2e456b(0x12e)](_0x1c2268,_0x2e456b(0x12f)),_0x5cdedd=process.env.RABETBASE_ISSUE_RAW_DESCRIPTION==='1';let _0x24f98e=_0x1c2268,_0x1f2520=0x0;const _0x36c76c=[];if(!_0x5cdedd){const _0x2d744c=protectOssAccessKeyIds(_0x24f98e);_0x24f98e=_0x2d744c[_0x2e456b(0x141)];for(const _0x50591a of REDACTION_RULES){let _0x44af88=0x0;_0x24f98e=_0x24f98e[_0x2e456b(0x14c)](_0x50591a[_0x2e456b(0x142)],(_0x38064e,_0x1db4d9)=>{const _0x37cba8=_0x2e456b;_0x44af88+=0x1;const _0x2b164a=typeof _0x1db4d9===_0x37cba8(0x13a)?_0x1db4d9:'';return _0x2b164a+'['+_0x50591a[_0x37cba8(0x14b)]+']';}),_0x44af88>0x0&&(_0x1f2520+=_0x44af88,!_0x36c76c[_0x2e456b(0x14f)](_0x50591a[_0x2e456b(0x146)])&&_0x36c76c[_0x2e456b(0x145)](_0x50591a[_0x2e456b(0x146)]));}_0x24f98e=_0x2d744c['restore'](_0x24f98e);}let _0x398a91=![];if(Buffer[_0x2e456b(0x12e)](_0x24f98e,'utf8')>ISSUE_DESCRIPTION_MAX_BYTES){_0x398a91=!![];const _0x39e11d=Buffer[_0x2e456b(0x12e)](TRUNCATION_NOTICE,_0x2e456b(0x12f)),_0x5471b7=Math[_0x2e456b(0x13b)](0x0,ISSUE_DESCRIPTION_MAX_BYTES-_0x39e11d);_0x24f98e=sliceUtf8Bytes(_0x24f98e,_0x5471b7)+TRUNCATION_NOTICE;}return{'description':_0x24f98e,'originalBytes':_0x5f0526,'truncated':_0x398a91,'redactionCount':_0x1f2520,'redactionKinds':_0x36c76c};}function protectOssAccessKeyIds(_0x2d0e41){const _0x1fd95d=a99_0x29f5bf,_0x2ede18=[],_0x49debd=_0x2d0e41[_0x1fd95d(0x14c)](/([?&])OSSAccessKeyId=([A-Za-z0-9/+_\-]{8,})/gi,(_0x3bb57e,_0x4bd0ab)=>{const _0x12554d=_0x1fd95d,_0x2147e4=_0x2ede18[_0x12554d(0x145)](_0x3bb57e[_0x12554d(0x14a)](_0x4bd0ab[_0x12554d(0x12d)]))-0x1;return _0x4bd0ab+_0x12554d(0x135)+_0x2147e4+'__';});return{'description':_0x49debd,'restore':_0x4dd170=>_0x4dd170[_0x1fd95d(0x14c)](/([?&])__RB_OSS_ID_(\d+)__/g,(_0x4db376,_0x33fe2b,_0x4dc64f)=>{const _0x1630e2=_0x2ede18[Number(_0x4dc64f)];return _0x1630e2===undefined?_0x4db376:''+_0x33fe2b+_0x1630e2;})};}function sliceUtf8Bytes(_0x11a1a1,_0x3b64a8){const _0x346daa=a99_0x29f5bf;if(_0x3b64a8<=0x0)return'';const _0x53fb8b=Buffer[_0x346daa(0x13f)](_0x11a1a1,_0x346daa(0x12f));if(_0x53fb8b['byteLength']<=_0x3b64a8)return _0x11a1a1;let _0x7518be=_0x3b64a8;while(_0x7518be>0x0){const _0x336ef3=_0x53fb8b[_0x7518be];if(_0x336ef3===undefined||(_0x336ef3&0xc0)!==0x80)break;_0x7518be-=0x1;}return _0x53fb8b[_0x346daa(0x13d)](0x0,_0x7518be)['toString'](_0x346daa(0x12f));}function a99_0x35a7(){const _0x2a761f=['private-key','131598FnIxmI','138cceKVk','1131616mKNaGZ','__RB_OSS_ID_','REDACTED:access-key','REDACTED:bearer-jwt','4582500CkDmTc','28076JNOjrK','string','max','authorization','subarray','5556YiJyxJ','from','408632JxgWgz','description','pattern','REDACTED:password','259gvhdpt','push','kind','bearer-jwt','access-key','cookie','slice','label','replace','4535100wXwFfb','password','includes','REDACTED:private-key','length','byteLength','utf8','225BncQeS'];a99_0x35a7=function(){return _0x2a761f;};return a99_0x35a7();}
@@ -1 +1 @@
1
- const a100_0x4631f5=a100_0x33af;(function(_0x1008a6,_0x3ad94f){const _0x85422f=a100_0x33af,_0x21dc57=_0x1008a6();while(!![]){try{const _0x726b7d=-parseInt(_0x85422f(0x129))/0x1+-parseInt(_0x85422f(0x11f))/0x2*(parseInt(_0x85422f(0x13c))/0x3)+-parseInt(_0x85422f(0x139))/0x4+parseInt(_0x85422f(0x126))/0x5*(parseInt(_0x85422f(0x11d))/0x6)+parseInt(_0x85422f(0x128))/0x7*(-parseInt(_0x85422f(0x122))/0x8)+parseInt(_0x85422f(0x121))/0x9+parseInt(_0x85422f(0x138))/0xa;if(_0x726b7d===_0x3ad94f)break;else _0x21dc57['push'](_0x21dc57['shift']());}catch(_0xbea8a3){_0x21dc57['push'](_0x21dc57['shift']());}}}(a100_0xde17,0x8df96));import{logger}from'../../utils/logger.js';function a100_0x33af(_0x202d04,_0x13a7bb){_0x202d04=_0x202d04-0x11c;const _0xde1719=a100_0xde17();let _0x33aff0=_0xde1719[_0x202d04];return _0x33aff0;}function a100_0xde17(){const _0x126d98=['forEach','log','keys','error','details','Clear\x20command\x20history\x20logs','en-US','22809460qEuxnl','4083404FqkPEe','length','*\x20Lovrabet\x20CLI\x20logs:\x0a','91254Tliaed','duration','210hxQDsC','level','8nCSaWs','toLocaleString','9858753vhVghT','536cgwfBW','stringify','warn','timestamp','84805hModZV','View\x20command\x20history\x20logs','113428XoDAXL','1160281ikHOZX','\x20\x20\x20Duration:\x20','logs','command','\x20\x20\x20Time:\x20','\x20\x20\x20Details:\x20','read','show'];a100_0xde17=function(){return _0x126d98;};return a100_0xde17();}function printLogs(_0x394ffa){const _0x5e8aba=a100_0x33af;if(_0x394ffa['length']===0x0){console['log']('*\x20No\x20logs\x20found');return;}console[_0x5e8aba(0x132)](_0x5e8aba(0x13b)),_0x394ffa[_0x5e8aba(0x131)]((_0x5559ef,_0x5c7c25)=>{const _0x3b32da=_0x5e8aba,_0x6b8d15=new Date(_0x5559ef[_0x3b32da(0x125)])[_0x3b32da(0x120)](_0x3b32da(0x137)),_0x5b4892=_0x5559ef[_0x3b32da(0x11e)]==='success'?'√':_0x5559ef['level']===_0x3b32da(0x134)?'×':_0x5559ef[_0x3b32da(0x11e)]===_0x3b32da(0x124)?'!':'i';console[_0x3b32da(0x132)](_0x5c7c25+0x1+'.\x20'+_0x5b4892+'\x20['+_0x5559ef[_0x3b32da(0x12c)]+']\x20'+_0x5559ef['message']),console[_0x3b32da(0x132)](_0x3b32da(0x12d)+_0x6b8d15),_0x5559ef[_0x3b32da(0x11c)]&&console['log'](_0x3b32da(0x12a)+_0x5559ef[_0x3b32da(0x11c)]+'ms'),_0x5559ef[_0x3b32da(0x135)]&&Object[_0x3b32da(0x133)](_0x5559ef[_0x3b32da(0x135)])[_0x3b32da(0x13a)]>0x0&&console[_0x3b32da(0x132)](_0x3b32da(0x12e)+JSON[_0x3b32da(0x123)](_0x5559ef[_0x3b32da(0x135)],null,0x2)),console[_0x3b32da(0x132)]('');});}export const logsDefinitions=[{'service':'logs','command':a100_0x4631f5(0x130),'description':a100_0x4631f5(0x127),'risk':a100_0x4631f5(0x12f),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x627739){return printLogs(logger['readLogs']()),{'ok':!![]};}},{'service':a100_0x4631f5(0x12b),'command':'clear','description':a100_0x4631f5(0x136),'risk':'write','requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x16487f){const _0x2be28d=a100_0x4631f5;return logger['clearLogs'](),console[_0x2be28d(0x132)]('*\x20Logs\x20cleared'),{'ok':!![]};}}];
1
+ const a100_0x35dbf0=a100_0x1332;function a100_0x909f(){const _0x5499a2=['length','readLogs','*\x20Lovrabet\x20CLI\x20logs:\x0a','1226596IfPNtC','*\x20No\x20logs\x20found','keys','toLocaleString','\x20\x20\x20Time:\x20','command','2430ibkMMx','168432DwDQuH','details','log','stringify','clear','logs','240074beWuJB','clearLogs','533144FQGbpk','read','\x20\x20\x20Details:\x20','750QazsZP','warn','44404FRsdNl','message','72mlVkak','duration','*\x20Logs\x20cleared','85374zPikcS','write','forEach','show','timestamp','error','Clear\x20command\x20history\x20logs','en-US','View\x20command\x20history\x20logs','level'];a100_0x909f=function(){return _0x5499a2;};return a100_0x909f();}(function(_0x152a34,_0xce89c3){const _0x26855e=a100_0x1332,_0x17fb1f=_0x152a34();while(!![]){try{const _0x318945=-parseInt(_0x26855e(0x9d))/0x1+parseInt(_0x26855e(0xa4))/0x2+-parseInt(_0x26855e(0x83))/0x3+-parseInt(_0x26855e(0x97))/0x4+-parseInt(_0x26855e(0xa2))/0x5*(-parseInt(_0x26855e(0x96))/0x6)+-parseInt(_0x26855e(0x90))/0x7+-parseInt(_0x26855e(0x9f))/0x8*(-parseInt(_0x26855e(0x80))/0x9);if(_0x318945===_0xce89c3)break;else _0x17fb1f['push'](_0x17fb1f['shift']());}catch(_0x4f32f7){_0x17fb1f['push'](_0x17fb1f['shift']());}}}(a100_0x909f,0x1fcb4));import{logger}from'../../utils/logger.js';function a100_0x1332(_0x40c994,_0x39f9d7){_0x40c994=_0x40c994-0x80;const _0x909ffe=a100_0x909f();let _0x13326d=_0x909ffe[_0x40c994];return _0x13326d;}function printLogs(_0x2ac990){const _0x5b50ea=a100_0x1332;if(_0x2ac990[_0x5b50ea(0x8d)]===0x0){console['log'](_0x5b50ea(0x91));return;}console['log'](_0x5b50ea(0x8f)),_0x2ac990[_0x5b50ea(0x85)]((_0x36a929,_0x4107a3)=>{const _0x110154=_0x5b50ea,_0x42b4da=new Date(_0x36a929[_0x110154(0x87)])[_0x110154(0x93)](_0x110154(0x8a)),_0x177cc0=_0x36a929[_0x110154(0x8c)]==='success'?'√':_0x36a929[_0x110154(0x8c)]===_0x110154(0x88)?'×':_0x36a929[_0x110154(0x8c)]===_0x110154(0xa3)?'!':'i';console[_0x110154(0x99)](_0x4107a3+0x1+'.\x20'+_0x177cc0+'\x20['+_0x36a929[_0x110154(0x95)]+']\x20'+_0x36a929[_0x110154(0xa5)]),console['log'](_0x110154(0x94)+_0x42b4da),_0x36a929['duration']&&console[_0x110154(0x99)]('\x20\x20\x20Duration:\x20'+_0x36a929[_0x110154(0x81)]+'ms'),_0x36a929[_0x110154(0x98)]&&Object[_0x110154(0x92)](_0x36a929[_0x110154(0x98)])[_0x110154(0x8d)]>0x0&&console['log'](_0x110154(0xa1)+JSON[_0x110154(0x9a)](_0x36a929['details'],null,0x2)),console[_0x110154(0x99)]('');});}export const logsDefinitions=[{'service':'logs','command':a100_0x35dbf0(0x86),'description':a100_0x35dbf0(0x8b),'risk':a100_0x35dbf0(0xa0),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0xded926){const _0x42dcfd=a100_0x35dbf0;return printLogs(logger[_0x42dcfd(0x8e)]()),{'ok':!![]};}},{'service':a100_0x35dbf0(0x9c),'command':a100_0x35dbf0(0x9b),'description':a100_0x35dbf0(0x89),'risk':a100_0x35dbf0(0x84),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x6ad30b){const _0x35cea8=a100_0x35dbf0;return logger[_0x35cea8(0x9e)](),console[_0x35cea8(0x99)](_0x35cea8(0x82)),{'ok':!![]};}}];
@@ -1 +1 @@
1
- const a101_0x44c761=a101_0x1a6a;(function(_0x508653,_0x2a10c0){const _0x4c06b0=a101_0x1a6a,_0x461117=_0x508653();while(!![]){try{const _0x5a264b=-parseInt(_0x4c06b0(0x167))/0x1+parseInt(_0x4c06b0(0x137))/0x2*(parseInt(_0x4c06b0(0x174))/0x3)+-parseInt(_0x4c06b0(0x15a))/0x4*(-parseInt(_0x4c06b0(0x146))/0x5)+parseInt(_0x4c06b0(0x143))/0x6+-parseInt(_0x4c06b0(0x162))/0x7*(-parseInt(_0x4c06b0(0x158))/0x8)+-parseInt(_0x4c06b0(0x14f))/0x9*(parseInt(_0x4c06b0(0x183))/0xa)+parseInt(_0x4c06b0(0x182))/0xb*(-parseInt(_0x4c06b0(0x140))/0xc);if(_0x5a264b===_0x2a10c0)break;else _0x461117['push'](_0x461117['shift']());}catch(_0x2492fc){_0x461117['push'](_0x461117['shift']());}}}(a101_0x3dde,0xebbc4));import a101_0x48f567 from'chalk';import{filterMenusWithResources,fetchOnlineMenuList}from'../../commands/menu/shared/logic.js';import{renderUpdateSummary}from'../../commands/menu/shared/compare-table.js';import{askJsUrl,askCssUrl,askConfirm,startSpinner,stopSpinner,isInteractive,requireInteractive}from'../../commands/menu/shared/inquirer.js';import{CliErrors}from'../../errors.js';import{writeCliSideChannelLine}from'../../utils/write-cli-side-channel.js';function a101_0x3dde(){const _0x1af3b4=['\x20menu(s)\x20with\x20JS:\x20','Menu\x20asset\x20update\x20failed','rawFlags','JSON:\x20{\x22jsUrl\x22:\x22https://...js\x22,\x22cssUrl\x22:\x22https://...css\x22}','7aMvEFq','--all\x20cannot\x20be\x20combined\x20with\x20--menu-ids\x20or\x20--paths.','replace','--menu-ids\x20must\x20contain\x20positive\x20safe\x20integers.','Updating\x20','778214VcuEEw','\x20menu\x20resource\x20set(s).','Pre-fill\x20JS/CSS\x20URLs\x20to\x20update.\x20','Exact\x20comma-separated\x20menu\x20paths\x20to\x20update','flag','Updated\x20','bool','jsUrl','script','params','stringify','Failed\x20to\x20fetch\x20online\x20menu\x20list','cyan','266100rypHvX','mode','Online\x20menu\x20list\x20fetched','\x20menu(s)\x20updated','cookie','menu','parse','\x20menu(s)','menu\x20asset-update\x20requires\x20an\x20explicit\x20target:\x20pass\x20--all,\x20--menu-ids,\x20or\x20--paths.','str','yes','patch','length','trim','22ocQita','10sQOkHO','object','\x20updated.','all','import','yellow','fetch','filter','!\x20No\x20menus\x20with\x20existing\x20resources\x20found','cssUrl','26QftjBe','Fetching\x20online\x20menu\x20list...','split','message','\x20failed.','Exact\x20comma-separated\x20menu\x20IDs\x20to\x20update','paths','string','label','3848244DfDwNh','map','validation','10934664aGwwws','POST','Invalid\x20--load-mode.\x20Allowed\x20values:\x20import,\x20script,\x20fetch','478305nrIoAZ','selectedAppName','asset-update','force','Allow\x20replace\x20mode\x20to\x20remove\x20existing\x20JS\x20resources','patch\x20replaces\x20a\x20supplied\x20type\x20only\x20when\x20the\x20existing\x20target\x20is\x20unambiguous','isSafeInteger','menu\x20asset-update\x20requires\x20a\x20project\x20context\x20or\x20explicit\x20--appcode.\x20','/smartapi/menu/update','13595886fskxId','skipped','Menu\x20asset\x20update\x20completed:\x20','Resource\x20update\x20mode:\x20replace\x20rewrites\x20resources\x20from\x20supplied\x20URLs;\x20','appCode','high-risk-write','updated','diffs','load-mode','5066296uycAdB','failed','12smYfss','menu-ids','boolean','appcode'];a101_0x3dde=function(){return _0x1af3b4;};return a101_0x3dde();}import{runMenuUpdateCore}from'../../commands/menu/shared/update-core.js';import{selectMenusForUpdate}from'../../commands/menu/shared/update-core.js';import{isInProject}from'../../context.js';export const menuAssetUpdate={'service':a101_0x44c761(0x179),'command':a101_0x44c761(0x148),'description':'Update\x20CDN\x20asset\x20URLs\x20for\x20selected\x20online\x20menus\x20with\x20existing\x20resources','risk':a101_0x44c761(0x154),'flags':[{'name':'params','type':a101_0x44c761(0x13e),'description':a101_0x44c761(0x169)+a101_0x44c761(0x161)},{'name':a101_0x44c761(0x175),'type':a101_0x44c761(0x13e),'description':a101_0x44c761(0x152)+a101_0x44c761(0x14b),'enum':['replace','patch'],'default':a101_0x44c761(0x17f)},{'name':a101_0x44c761(0x149),'type':a101_0x44c761(0x15c),'description':a101_0x44c761(0x14a)},{'name':'menu-ids','type':a101_0x44c761(0x13e),'description':a101_0x44c761(0x13c)},{'name':a101_0x44c761(0x13d),'type':'string','description':a101_0x44c761(0x16a)},{'name':a101_0x44c761(0x130),'type':'boolean','description':'Explicitly\x20update\x20every\x20menu\x20that\x20has\x20resources'},{'name':a101_0x44c761(0x157),'type':a101_0x44c761(0x13e),'enum':[a101_0x44c761(0x131),a101_0x44c761(0x16f),a101_0x44c761(0x133)],'description':'Explicitly\x20change\x20the\x20microfrontend\x20resource\x20loading\x20mode'}],async 'dryRun'(_0x1f576c){const _0x53fff9=a101_0x44c761;ensureRunnableContext(_0x1f576c['rawFlags'],_0x1f576c[_0x53fff9(0x147)]);const _0x2c5b22=await runMenuUpdateCore(_0x1f576c[_0x53fff9(0x153)],_0x1f576c[_0x53fff9(0x178)],_0x1f576c[_0x53fff9(0x17d)](_0x53fff9(0x170)),{'mode':parseMode(_0x1f576c['str'](_0x53fff9(0x175))),'dryRun':!![],'force':_0x1f576c[_0x53fff9(0x16d)](_0x53fff9(0x149)),'selection':parseSelection(_0x1f576c),'loadScriptMode':parseLoadScriptMode(_0x1f576c[_0x53fff9(0x17d)](_0x53fff9(0x157)))});return{'method':_0x53fff9(0x144),'url':_0x53fff9(0x14e),'body':_0x2c5b22,'description':_0x2c5b22[_0x53fff9(0x150)]?'No\x20menus\x20with\x20existing\x20resources\x20would\x20be\x20updated.':'Would\x20update\x20'+(_0x2c5b22[_0x53fff9(0x156)]?.[_0x53fff9(0x180)]??0x0)+_0x53fff9(0x168)};},async 'execute'(_0x366680){const _0x266117=a101_0x44c761;ensureRunnableContext(_0x366680[_0x266117(0x160)],_0x366680[_0x266117(0x147)]);const _0x5816d9=_0x366680[_0x266117(0x16b)](_0x266117(0x17e)),_0x55f2a4=_0x366680['str'](_0x266117(0x170)),_0x2d1d80=parseMode(_0x366680[_0x266117(0x17d)](_0x266117(0x175))),_0x49a487=_0x366680['bool'](_0x266117(0x149)),_0x17a61a=parseLoadScriptMode(_0x366680[_0x266117(0x17d)](_0x266117(0x157))),_0x217fad=parseParams(_0x55f2a4),_0x6303ee=!!(_0x217fad[_0x266117(0x16e)]||_0x217fad[_0x266117(0x136)]);if(_0x5816d9||_0x6303ee&&!isInteractive()){const _0x3b23dc=await runMenuUpdateCore(_0x366680[_0x266117(0x153)],_0x366680[_0x266117(0x178)],_0x55f2a4,{'mode':_0x2d1d80,'force':_0x49a487,'selection':parseSelection(_0x366680),'loadScriptMode':_0x17a61a});return _0x3b23dc['skipped']?writeCliSideChannelLine(_0x266117(0x135)):(writeCliSideChannelLine('✓\x20Menu\x20asset\x20update\x20completed:\x20'+_0x3b23dc[_0x266117(0x155)]+_0x266117(0x177)),_0x3b23dc[_0x266117(0x159)]>0x0&&writeCliSideChannelLine('!\x20'+_0x3b23dc[_0x266117(0x159)]+'\x20menu(s)\x20failed')),{'ok':_0x3b23dc[_0x266117(0x159)]===0x0,'data':_0x3b23dc,'message':_0x3b23dc[_0x266117(0x150)]?'Menu\x20asset\x20update\x20skipped':_0x266117(0x151)+_0x3b23dc['updated']+'\x20updated,\x20'+_0x3b23dc['failed']+'\x20failed.'};}requireInteractive();const _0x16ab95=startSpinner(_0x266117(0x138));let _0x1480e7;try{_0x1480e7=await fetchOnlineMenuList(_0x366680[_0x266117(0x153)],_0x366680['cookie']),stopSpinner(_0x16ab95,_0x266117(0x176),!![]);}catch(_0x51fa57){stopSpinner(_0x16ab95,_0x266117(0x172),![]);throw CliErrors[_0x266117(0x142)](_0x51fa57 instanceof Error?_0x51fa57['message']:_0x266117(0x172));}const _0x2ee8cb=filterMenusWithResources(_0x1480e7),_0x3edc55=parseSelection(_0x366680,![]),_0x16c3df=_0x3edc55?selectMenusForUpdate(_0x2ee8cb,_0x3edc55):_0x2ee8cb;if(_0x16c3df[_0x266117(0x180)]===0x0)return writeCliSideChannelLine(a101_0x48f567[_0x266117(0x132)]('\x20\x20!\x20No\x20menus\x20with\x20existing\x20resources\x20found')),{'ok':!![]};writeCliSideChannelLine(''),writeCliSideChannelLine(a101_0x48f567[_0x266117(0x173)]('\x20\x20Found\x20'+_0x16c3df[_0x266117(0x180)]+'\x20menu(s)\x20with\x20existing\x20resources')),writeCliSideChannelLine(renderUpdateSummary(_0x16c3df[_0x266117(0x141)](_0x4291f5=>_0x4291f5[_0x266117(0x13f)]),[_0x217fad[_0x266117(0x16e)],_0x217fad[_0x266117(0x136)]])),writeCliSideChannelLine('');let _0xb015b7=_0x217fad[_0x266117(0x16e)],_0xb700b9=_0x217fad['cssUrl'];!_0xb015b7&&(_0xb015b7=await askJsUrl());!_0xb700b9&&(_0xb700b9=await askCssUrl());const _0x547a91=await askConfirm('\x20\x20Update\x20'+_0x16c3df[_0x266117(0x180)]+_0x266117(0x15e)+_0xb015b7+'\x20and\x20CSS:\x20'+_0xb700b9+'?');if(!_0x547a91)return writeCliSideChannelLine(a101_0x48f567['gray']('\x20\x20Cancelled.')),{'ok':!![]};const _0x53b989=startSpinner(_0x266117(0x166)+_0x16c3df['length']+'\x20menu(s)...');try{const _0x1b0172=await runMenuUpdateCore(_0x366680[_0x266117(0x153)],_0x366680[_0x266117(0x178)],JSON[_0x266117(0x171)]({'jsUrl':_0xb015b7,'cssUrl':_0xb700b9}),{'mode':_0x2d1d80,'force':_0x49a487,'selection':{'all':![],'menuIds':_0x16c3df[_0x266117(0x141)](_0x3d3925=>_0x3d3925['id']),'paths':[]},'loadScriptMode':_0x17a61a});return stopSpinner(_0x53b989,_0x266117(0x16c)+_0x1b0172[_0x266117(0x155)]+_0x266117(0x17b),_0x1b0172['failed']===0x0),{'ok':_0x1b0172[_0x266117(0x159)]===0x0,'data':_0x1b0172,'message':_0x1b0172['failed']>0x0?_0x266117(0x151)+_0x1b0172[_0x266117(0x155)]+'\x20updated,\x20'+_0x1b0172[_0x266117(0x159)]+_0x266117(0x13b):_0x266117(0x151)+_0x1b0172[_0x266117(0x155)]+_0x266117(0x185)};}catch(_0x19958f){stopSpinner(_0x53b989,_0x266117(0x15f),![]);throw CliErrors[_0x266117(0x142)](_0x19958f instanceof Error?_0x19958f[_0x266117(0x13a)]:'Menu\x20asset\x20update\x20failed');}}};function a101_0x1a6a(_0x41e93c,_0x4b3705){_0x41e93c=_0x41e93c-0x130;const _0x3dde6d=a101_0x3dde();let _0x1a6ad0=_0x3dde6d[_0x41e93c];return _0x1a6ad0;}function ensureRunnableContext(_0x305604,_0x441b89){const _0x18a0b5=a101_0x44c761,_0x740c3f=_0x305604[_0x18a0b5(0x15d)]?String(_0x305604['appcode'])[_0x18a0b5(0x181)]():'';if(!isInProject()&&!_0x441b89&&!_0x740c3f)throw CliErrors[_0x18a0b5(0x142)](_0x18a0b5(0x14d)+'Run\x20inside\x20a\x20directory\x20with\x20.rabetbase.json,\x20or\x20pass\x20--appcode\x20<code>.');}function parseMode(_0x5f5b93){const _0x26dd84=a101_0x44c761;if(!_0x5f5b93)return _0x26dd84(0x17f);if(_0x5f5b93===_0x26dd84(0x164)||_0x5f5b93===_0x26dd84(0x17f))return _0x5f5b93;throw CliErrors[_0x26dd84(0x142)]('Invalid\x20--mode.\x20Allowed\x20values:\x20replace,\x20patch');}function parseSelection(_0x1dfb63,_0x5ec077=!![]){const _0x2a6374=a101_0x44c761,_0xc8a0ed=_0x1dfb63[_0x2a6374(0x16d)](_0x2a6374(0x130)),_0xc6c17d=parseMenuIds(_0x1dfb63[_0x2a6374(0x17d)](_0x2a6374(0x15b))),_0x23d0ca=parseCsv(_0x1dfb63['str'](_0x2a6374(0x13d))),_0x4acd2e=_0xc6c17d[_0x2a6374(0x180)]>0x0||_0x23d0ca[_0x2a6374(0x180)]>0x0;if(_0xc8a0ed&&_0x4acd2e)throw CliErrors[_0x2a6374(0x142)](_0x2a6374(0x163));if(!_0xc8a0ed&&!_0x4acd2e){if(!_0x5ec077)return undefined;throw CliErrors['validation'](_0x2a6374(0x17c));}return{'all':_0xc8a0ed,'menuIds':_0xc6c17d,'paths':_0x23d0ca};}function parseMenuIds(_0x482da8){const _0x8d789d=a101_0x44c761,_0x5b857f=parseCsv(_0x482da8),_0x56c387=_0x5b857f[_0x8d789d(0x141)](Number);if(_0x56c387['some'](_0x427e7e=>!Number[_0x8d789d(0x14c)](_0x427e7e)||_0x427e7e<=0x0))throw CliErrors[_0x8d789d(0x142)](_0x8d789d(0x165));return[...new Set(_0x56c387)];}function parseCsv(_0x3ac599){const _0x21e357=a101_0x44c761;return[...new Set(_0x3ac599[_0x21e357(0x139)](',')[_0x21e357(0x141)](_0x14ef37=>_0x14ef37[_0x21e357(0x181)]())[_0x21e357(0x134)](Boolean))];}function parseLoadScriptMode(_0x1cc0d4){const _0x367a13=a101_0x44c761;if(!_0x1cc0d4)return undefined;if(_0x1cc0d4===_0x367a13(0x131)||_0x1cc0d4===_0x367a13(0x16f)||_0x1cc0d4===_0x367a13(0x133))return _0x1cc0d4;throw CliErrors[_0x367a13(0x142)](_0x367a13(0x145));}function parseParams(_0x4117ee){const _0x9b9ec3=a101_0x44c761;if(!_0x4117ee)return{};try{const _0x2bc967=JSON[_0x9b9ec3(0x17a)](_0x4117ee);if(typeof _0x2bc967!==_0x9b9ec3(0x184)||_0x2bc967===null||Array['isArray'](_0x2bc967))return{};return{'jsUrl':typeof _0x2bc967[_0x9b9ec3(0x16e)]===_0x9b9ec3(0x13e)?_0x2bc967[_0x9b9ec3(0x16e)][_0x9b9ec3(0x181)]():undefined,'cssUrl':typeof _0x2bc967[_0x9b9ec3(0x136)]===_0x9b9ec3(0x13e)?_0x2bc967[_0x9b9ec3(0x136)][_0x9b9ec3(0x181)]():undefined};}catch{return{};}}
1
+ const a101_0x4de99c=a101_0x26ee;(function(_0x5efa91,_0x4153a5){const _0x2ac3a2=a101_0x26ee,_0x141af1=_0x5efa91();while(!![]){try{const _0xd05a9f=parseInt(_0x2ac3a2(0xf3))/0x1*(parseInt(_0x2ac3a2(0x108))/0x2)+parseInt(_0x2ac3a2(0x115))/0x3+parseInt(_0x2ac3a2(0x11c))/0x4*(-parseInt(_0x2ac3a2(0xef))/0x5)+-parseInt(_0x2ac3a2(0x127))/0x6*(-parseInt(_0x2ac3a2(0xe7))/0x7)+parseInt(_0x2ac3a2(0x104))/0x8*(parseInt(_0x2ac3a2(0x123))/0x9)+-parseInt(_0x2ac3a2(0xea))/0xa*(-parseInt(_0x2ac3a2(0x136))/0xb)+-parseInt(_0x2ac3a2(0x11e))/0xc*(parseInt(_0x2ac3a2(0xfa))/0xd);if(_0xd05a9f===_0x4153a5)break;else _0x141af1['push'](_0x141af1['shift']());}catch(_0x683aac){_0x141af1['push'](_0x141af1['shift']());}}}(a101_0x52f7,0x5dc2e));import a101_0x268cf9 from'chalk';import{filterMenusWithResources,fetchOnlineMenuList}from'../../commands/menu/shared/logic.js';import{renderUpdateSummary}from'../../commands/menu/shared/compare-table.js';import{askJsUrl,askCssUrl,askConfirm,startSpinner,stopSpinner,isInteractive,requireInteractive}from'../../commands/menu/shared/inquirer.js';import{CliErrors}from'../../errors.js';import{writeCliSideChannelLine}from'../../utils/write-cli-side-channel.js';import{runMenuUpdateCore}from'../../commands/menu/shared/update-core.js';import{selectMenusForUpdate}from'../../commands/menu/shared/update-core.js';import{isInProject}from'../../context.js';export const menuAssetUpdate={'service':a101_0x4de99c(0xe3),'command':a101_0x4de99c(0x125),'description':'Update\x20CDN\x20asset\x20URLs\x20for\x20selected\x20online\x20menus\x20with\x20existing\x20resources','risk':a101_0x4de99c(0xec),'flags':[{'name':a101_0x4de99c(0x116),'type':a101_0x4de99c(0x121),'description':a101_0x4de99c(0x134)+'JSON:\x20{\x22jsUrl\x22:\x22https://...js\x22,\x22cssUrl\x22:\x22https://...css\x22}'},{'name':a101_0x4de99c(0x138),'type':'string','description':a101_0x4de99c(0x12c)+a101_0x4de99c(0x13b),'enum':[a101_0x4de99c(0x11b),a101_0x4de99c(0x105)],'default':a101_0x4de99c(0x105)},{'name':a101_0x4de99c(0x11d),'type':a101_0x4de99c(0x114),'description':a101_0x4de99c(0xe6)},{'name':a101_0x4de99c(0xf9),'type':a101_0x4de99c(0x121),'description':'Exact\x20comma-separated\x20menu\x20IDs\x20to\x20update'},{'name':a101_0x4de99c(0xf8),'type':'string','description':a101_0x4de99c(0xfc)},{'name':a101_0x4de99c(0x112),'type':'boolean','description':a101_0x4de99c(0x111)},{'name':a101_0x4de99c(0xfb),'type':a101_0x4de99c(0x121),'enum':[a101_0x4de99c(0xee),a101_0x4de99c(0x117),a101_0x4de99c(0x103)],'description':a101_0x4de99c(0x10f)}],async 'dryRun'(_0x16978b){const _0x2e14f4=a101_0x4de99c;ensureRunnableContext(_0x16978b[_0x2e14f4(0x128)],_0x16978b['selectedAppName']);const _0x4ac947=await runMenuUpdateCore(_0x16978b[_0x2e14f4(0xe8)],_0x16978b[_0x2e14f4(0x13d)],_0x16978b['str'](_0x2e14f4(0x116)),{'mode':parseMode(_0x16978b[_0x2e14f4(0x12b)](_0x2e14f4(0x138))),'dryRun':!![],'force':_0x16978b[_0x2e14f4(0xf0)]('force'),'selection':parseSelection(_0x16978b),'loadScriptMode':parseLoadScriptMode(_0x16978b['str'](_0x2e14f4(0xfb)))});return{'method':'POST','url':'/smartapi/menu/update','body':_0x4ac947,'description':_0x4ac947[_0x2e14f4(0x12f)]?'No\x20menus\x20with\x20existing\x20resources\x20would\x20be\x20updated.':'Would\x20update\x20'+(_0x4ac947[_0x2e14f4(0x132)]?.[_0x2e14f4(0xf4)]??0x0)+_0x2e14f4(0xe1)};},async 'execute'(_0x1adfa4){const _0x2a0efa=a101_0x4de99c;ensureRunnableContext(_0x1adfa4[_0x2a0efa(0x128)],_0x1adfa4[_0x2a0efa(0x113)]);const _0x5adec9=_0x1adfa4[_0x2a0efa(0xfd)](_0x2a0efa(0x100)),_0x11ca4d=_0x1adfa4[_0x2a0efa(0x12b)]('params'),_0x538ee6=parseMode(_0x1adfa4['str'](_0x2a0efa(0x138))),_0x3db007=_0x1adfa4[_0x2a0efa(0xf0)](_0x2a0efa(0x11d)),_0x41e9ff=parseLoadScriptMode(_0x1adfa4['str'](_0x2a0efa(0xfb))),_0x308805=parseParams(_0x11ca4d),_0x462243=!!(_0x308805[_0x2a0efa(0x131)]||_0x308805[_0x2a0efa(0x101)]);if(_0x5adec9||_0x462243&&!isInteractive()){const _0x47f17c=await runMenuUpdateCore(_0x1adfa4['appCode'],_0x1adfa4['cookie'],_0x11ca4d,{'mode':_0x538ee6,'force':_0x3db007,'selection':parseSelection(_0x1adfa4),'loadScriptMode':_0x41e9ff});return _0x47f17c[_0x2a0efa(0x12f)]?writeCliSideChannelLine(_0x2a0efa(0x106)):(writeCliSideChannelLine('✓\x20Menu\x20asset\x20update\x20completed:\x20'+_0x47f17c['updated']+_0x2a0efa(0xe2)),_0x47f17c[_0x2a0efa(0x130)]>0x0&&writeCliSideChannelLine('!\x20'+_0x47f17c[_0x2a0efa(0x130)]+_0x2a0efa(0xf1))),{'ok':_0x47f17c[_0x2a0efa(0x130)]===0x0,'data':_0x47f17c,'message':_0x47f17c[_0x2a0efa(0x12f)]?_0x2a0efa(0xfe):'Menu\x20asset\x20update\x20completed:\x20'+_0x47f17c[_0x2a0efa(0x107)]+'\x20updated,\x20'+_0x47f17c[_0x2a0efa(0x130)]+_0x2a0efa(0xed)};}requireInteractive();const _0x3e3800=startSpinner(_0x2a0efa(0xe5));let _0x4392e7;try{_0x4392e7=await fetchOnlineMenuList(_0x1adfa4['appCode'],_0x1adfa4[_0x2a0efa(0x13d)]),stopSpinner(_0x3e3800,_0x2a0efa(0x12e),!![]);}catch(_0x374370){stopSpinner(_0x3e3800,_0x2a0efa(0x135),![]);throw CliErrors[_0x2a0efa(0x122)](_0x374370 instanceof Error?_0x374370['message']:_0x2a0efa(0x135));}const _0x267d6a=filterMenusWithResources(_0x4392e7),_0x43262f=parseSelection(_0x1adfa4,![]),_0xf2b9a2=_0x43262f?selectMenusForUpdate(_0x267d6a,_0x43262f):_0x267d6a;if(_0xf2b9a2[_0x2a0efa(0xf4)]===0x0)return writeCliSideChannelLine(a101_0x268cf9[_0x2a0efa(0x124)]('\x20\x20!\x20No\x20menus\x20with\x20existing\x20resources\x20found')),{'ok':!![]};writeCliSideChannelLine(''),writeCliSideChannelLine(a101_0x268cf9[_0x2a0efa(0x10b)](_0x2a0efa(0xf2)+_0xf2b9a2[_0x2a0efa(0xf4)]+_0x2a0efa(0x12a))),writeCliSideChannelLine(renderUpdateSummary(_0xf2b9a2['map'](_0x35ecc6=>_0x35ecc6[_0x2a0efa(0x11a)]),[_0x308805[_0x2a0efa(0x131)],_0x308805[_0x2a0efa(0x101)]])),writeCliSideChannelLine('');let _0x1e1fc1=_0x308805[_0x2a0efa(0x131)],_0x11f73f=_0x308805[_0x2a0efa(0x101)];!_0x1e1fc1&&(_0x1e1fc1=await askJsUrl());!_0x11f73f&&(_0x11f73f=await askCssUrl());const _0x479590=await askConfirm(_0x2a0efa(0x109)+_0xf2b9a2[_0x2a0efa(0xf4)]+_0x2a0efa(0x102)+_0x1e1fc1+'\x20and\x20CSS:\x20'+_0x11f73f+'?');if(!_0x479590)return writeCliSideChannelLine(a101_0x268cf9[_0x2a0efa(0xeb)]('\x20\x20Cancelled.')),{'ok':!![]};const _0xf388a3=startSpinner(_0x2a0efa(0x13c)+_0xf2b9a2['length']+_0x2a0efa(0xf6));try{const _0x5fd0fd=await runMenuUpdateCore(_0x1adfa4[_0x2a0efa(0xe8)],_0x1adfa4[_0x2a0efa(0x13d)],JSON[_0x2a0efa(0x12d)]({'jsUrl':_0x1e1fc1,'cssUrl':_0x11f73f}),{'mode':_0x538ee6,'force':_0x3db007,'selection':{'all':![],'menuIds':_0xf2b9a2['map'](_0x4bba83=>_0x4bba83['id']),'paths':[]},'loadScriptMode':_0x41e9ff});return stopSpinner(_0xf388a3,_0x2a0efa(0x13a)+_0x5fd0fd[_0x2a0efa(0x107)]+_0x2a0efa(0x10e),_0x5fd0fd[_0x2a0efa(0x130)]===0x0),{'ok':_0x5fd0fd[_0x2a0efa(0x130)]===0x0,'data':_0x5fd0fd,'message':_0x5fd0fd[_0x2a0efa(0x130)]>0x0?'Menu\x20asset\x20update\x20completed:\x20'+_0x5fd0fd[_0x2a0efa(0x107)]+_0x2a0efa(0xf5)+_0x5fd0fd[_0x2a0efa(0x130)]+_0x2a0efa(0xed):'Menu\x20asset\x20update\x20completed:\x20'+_0x5fd0fd[_0x2a0efa(0x107)]+_0x2a0efa(0x119)};}catch(_0x50a043){stopSpinner(_0xf388a3,'Menu\x20asset\x20update\x20failed',![]);throw CliErrors[_0x2a0efa(0x122)](_0x50a043 instanceof Error?_0x50a043['message']:_0x2a0efa(0x110));}}};function ensureRunnableContext(_0x5e3ffa,_0x338ff6){const _0x36c713=a101_0x4de99c,_0x56ba2f=_0x5e3ffa[_0x36c713(0x10d)]?String(_0x5e3ffa[_0x36c713(0x10d)])[_0x36c713(0xff)]():'';if(!isInProject()&&!_0x338ff6&&!_0x56ba2f)throw CliErrors[_0x36c713(0x122)](_0x36c713(0xe4)+_0x36c713(0x139));}function a101_0x26ee(_0x1906bc,_0x574f15){_0x1906bc=_0x1906bc-0xe1;const _0x52f73f=a101_0x52f7();let _0x26eeb6=_0x52f73f[_0x1906bc];return _0x26eeb6;}function parseMode(_0x2a6d71){const _0x5cabdc=a101_0x4de99c;if(!_0x2a6d71)return _0x5cabdc(0x105);if(_0x2a6d71===_0x5cabdc(0x11b)||_0x2a6d71==='patch')return _0x2a6d71;throw CliErrors[_0x5cabdc(0x122)](_0x5cabdc(0x120));}function parseSelection(_0x4cc22e,_0x5853dc=!![]){const _0x5d5e3f=a101_0x4de99c,_0x1eb06c=_0x4cc22e[_0x5d5e3f(0xf0)](_0x5d5e3f(0x112)),_0x58af57=parseMenuIds(_0x4cc22e[_0x5d5e3f(0x12b)](_0x5d5e3f(0xf9))),_0x2af278=parseCsv(_0x4cc22e[_0x5d5e3f(0x12b)](_0x5d5e3f(0xf8))),_0x31c8ce=_0x58af57[_0x5d5e3f(0xf4)]>0x0||_0x2af278[_0x5d5e3f(0xf4)]>0x0;if(_0x1eb06c&&_0x31c8ce)throw CliErrors[_0x5d5e3f(0x122)]('--all\x20cannot\x20be\x20combined\x20with\x20--menu-ids\x20or\x20--paths.');if(!_0x1eb06c&&!_0x31c8ce){if(!_0x5853dc)return undefined;throw CliErrors[_0x5d5e3f(0x122)](_0x5d5e3f(0x137));}return{'all':_0x1eb06c,'menuIds':_0x58af57,'paths':_0x2af278};}function a101_0x52f7(){const _0x10a3fc=['cookie','\x20menu\x20resource\x20set(s).','\x20menu(s)\x20updated','menu','menu\x20asset-update\x20requires\x20a\x20project\x20context\x20or\x20explicit\x20--appcode.\x20','Fetching\x20online\x20menu\x20list...','Allow\x20replace\x20mode\x20to\x20remove\x20existing\x20JS\x20resources','336PlosVw','appCode','--menu-ids\x20must\x20contain\x20positive\x20safe\x20integers.','90LVyRkR','gray','high-risk-write','\x20failed.','import','5oKfDmL','bool','\x20menu(s)\x20failed','\x20\x20Found\x20','4xhvDhZ','length','\x20updated,\x20','\x20menu(s)...','isSafeInteger','paths','menu-ids','1781BtZriy','load-mode','Exact\x20comma-separated\x20menu\x20paths\x20to\x20update','flag','Menu\x20asset\x20update\x20skipped','trim','yes','cssUrl','\x20menu(s)\x20with\x20JS:\x20','fetch','56QhRTJH','patch','!\x20No\x20menus\x20with\x20existing\x20resources\x20found','updated','202414UvGaiO','\x20\x20Update\x20','isArray','cyan','object','appcode','\x20menu(s)','Explicitly\x20change\x20the\x20microfrontend\x20resource\x20loading\x20mode','Menu\x20asset\x20update\x20failed','Explicitly\x20update\x20every\x20menu\x20that\x20has\x20resources','all','selectedAppName','boolean','932325ZKRlEf','params','script','some','\x20updated.','label','replace','1641736WNlyvM','force','132372yfHWQR','parse','Invalid\x20--mode.\x20Allowed\x20values:\x20replace,\x20patch','string','validation','985239eTMyWh','yellow','asset-update','Invalid\x20--load-mode.\x20Allowed\x20values:\x20import,\x20script,\x20fetch','30354WGjuXS','rawFlags','map','\x20menu(s)\x20with\x20existing\x20resources','str','Resource\x20update\x20mode:\x20replace\x20rewrites\x20resources\x20from\x20supplied\x20URLs;\x20','stringify','Online\x20menu\x20list\x20fetched','skipped','failed','jsUrl','diffs','filter','Pre-fill\x20JS/CSS\x20URLs\x20to\x20update.\x20','Failed\x20to\x20fetch\x20online\x20menu\x20list','710105vDURzu','menu\x20asset-update\x20requires\x20an\x20explicit\x20target:\x20pass\x20--all,\x20--menu-ids,\x20or\x20--paths.','mode','Run\x20inside\x20a\x20directory\x20with\x20.rabetbase.json,\x20or\x20pass\x20--appcode\x20<code>.','Updated\x20','patch\x20replaces\x20a\x20supplied\x20type\x20only\x20when\x20the\x20existing\x20target\x20is\x20unambiguous','Updating\x20'];a101_0x52f7=function(){return _0x10a3fc;};return a101_0x52f7();}function parseMenuIds(_0x4a6e18){const _0x4853e1=a101_0x4de99c,_0x551e0d=parseCsv(_0x4a6e18),_0x103445=_0x551e0d[_0x4853e1(0x129)](Number);if(_0x103445[_0x4853e1(0x118)](_0x2e5e2c=>!Number[_0x4853e1(0xf7)](_0x2e5e2c)||_0x2e5e2c<=0x0))throw CliErrors[_0x4853e1(0x122)](_0x4853e1(0xe9));return[...new Set(_0x103445)];}function parseCsv(_0xd34d80){const _0x16a5a5=a101_0x4de99c;return[...new Set(_0xd34d80['split'](',')[_0x16a5a5(0x129)](_0x343e3e=>_0x343e3e[_0x16a5a5(0xff)]())[_0x16a5a5(0x133)](Boolean))];}function parseLoadScriptMode(_0x507f59){const _0x567788=a101_0x4de99c;if(!_0x507f59)return undefined;if(_0x507f59===_0x567788(0xee)||_0x507f59==='script'||_0x507f59===_0x567788(0x103))return _0x507f59;throw CliErrors[_0x567788(0x122)](_0x567788(0x126));}function parseParams(_0x14f7ec){const _0xbaecc3=a101_0x4de99c;if(!_0x14f7ec)return{};try{const _0x531851=JSON[_0xbaecc3(0x11f)](_0x14f7ec);if(typeof _0x531851!==_0xbaecc3(0x10c)||_0x531851===null||Array[_0xbaecc3(0x10a)](_0x531851))return{};return{'jsUrl':typeof _0x531851[_0xbaecc3(0x131)]===_0xbaecc3(0x121)?_0x531851[_0xbaecc3(0x131)][_0xbaecc3(0xff)]():undefined,'cssUrl':typeof _0x531851[_0xbaecc3(0x101)]===_0xbaecc3(0x121)?_0x531851[_0xbaecc3(0x101)][_0xbaecc3(0xff)]():undefined};}catch{return{};}}
@@ -1 +1 @@
1
- const a102_0x522b70=a102_0x4716;(function(_0x44e1fe,_0x4646c6){const _0xecaf63=a102_0x4716,_0xb038b1=_0x44e1fe();while(!![]){try{const _0x457994=-parseInt(_0xecaf63(0x1e6))/0x1*(parseInt(_0xecaf63(0x220))/0x2)+-parseInt(_0xecaf63(0x23a))/0x3*(-parseInt(_0xecaf63(0x230))/0x4)+parseInt(_0xecaf63(0x21d))/0x5+-parseInt(_0xecaf63(0x238))/0x6*(-parseInt(_0xecaf63(0x252))/0x7)+parseInt(_0xecaf63(0x24a))/0x8+parseInt(_0xecaf63(0x1f5))/0x9*(-parseInt(_0xecaf63(0x24b))/0xa)+parseInt(_0xecaf63(0x1f9))/0xb*(-parseInt(_0xecaf63(0x21b))/0xc);if(_0x457994===_0x4646c6)break;else _0xb038b1['push'](_0xb038b1['shift']());}catch(_0x382ffd){_0xb038b1['push'](_0xb038b1['shift']());}}}(a102_0x5e92,0x420c0));import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{assertMenuDeletePlanCurrent,assertMenuDeletePlanExecutable,createMenuDeletePlanFile,mutationPlanFromDeleteFile,readMenuDeletePlan,writeMenuDeletePlan}from'../../commands/menu/shared/delete-plan.js';import{fetchMenuSnapshot}from'../../commands/menu/shared/facts.js';import{MENU_EXPECT_FLAGS,MENU_ID_FLAG,asVerificationError,assertExpectedState,describeMenuErrorCause,fetchMutationSnapshot,hasFlag,mapMenuApiError,menuDryRunResult,menuError,menuFailure,mutationResult,requireExplicitYes,requireMenu,validateExactId}from'../../commands/menu/shared/mutations.js';import{batchDeleteMenuEntities}from'../../commands/menu/shared/service.js';function a102_0x4716(_0x4303b4,_0x2803fd){_0x4303b4=_0x4303b4-0x1d4;const _0x5e9242=a102_0x5e92();let _0x471623=_0x5e9242[_0x4303b4];return _0x471623;}import{CliError,CliErrors}from'../../errors.js';const BACKEND=[{'method':'POST','path':'/smartapi/menu/batchDelete'}],MENU_DELETE_ID_FLAG={...MENU_ID_FLAG,'required':![],'description':'Exact\x20menu\x20id\x20(required\x20with\x20--dry-run)'},MENU_DELETE_RECURSIVE_FLAG={'name':a102_0x522b70(0x23f),'type':a102_0x522b70(0x1e2),'description':'Include\x20every\x20descendant\x20of\x20the\x20exact\x20folder\x20id,\x20deleting\x20leaves\x20first'},MENU_DELETE_PLAN_OUT_FLAG={'name':'plan-out','type':a102_0x522b70(0x208),'description':'Required\x20with\x20--dry-run;\x20write\x20the\x20reviewed\x20plan\x20to\x20a\x20new\x20local\x20JSON\x20file'},MENU_DELETE_PLAN_FLAG={'name':'plan','type':'string','description':a102_0x522b70(0x1f1)};export const menuDelete={'service':'menu','command':a102_0x522b70(0x211),'description':a102_0x522b70(0x20b),'risk':a102_0x522b70(0x22d),'structuredErrors':!![],'flags':[MENU_DELETE_ID_FLAG,MENU_DELETE_RECURSIVE_FLAG,MENU_DELETE_PLAN_OUT_FLAG,MENU_DELETE_PLAN_FLAG,...MENU_EXPECT_FLAGS,APPCODE_FLAG_OPTIONAL],async 'validate'(_0x50c363){const _0x27dbc7=a102_0x522b70;_0x50c363[_0x27dbc7(0x243)]('dry-run')?validateDeleteDryRunInput(_0x50c363):validateDeleteExecuteInput(_0x50c363),requireExplicitYes(_0x50c363);},async 'dryRun'(_0x3ec5b6){const _0x1fb3e9=a102_0x522b70;validateDeleteDryRunInput(_0x3ec5b6);const _0x4d123e=await buildDeletePlan(_0x3ec5b6),_0x4d41f9=createMenuDeletePlanFile(_0x3ec5b6[_0x1fb3e9(0x20a)],_0x4d123e),_0x2870ef=await writeMenuDeletePlan(_0x3ec5b6['str']('plan-out'),_0x4d41f9),_0xd7eef5=mutationResult({..._0x4d123e,'planFile':{'path':_0x2870ef,'createdAt':_0x4d41f9[_0x1fb3e9(0x24e)],'expiresAt':_0x4d41f9[_0x1fb3e9(0x1f0)]}});return menuDryRunResult(_0xd7eef5,{'method':'POST','url':_0x1fb3e9(0x212),'body':{'idList':_0xd7eef5[_0x1fb3e9(0x245)]},'description':'Would\x20batch\x20delete\x20'+(_0xd7eef5[_0x1fb3e9(0x245)]?.[_0x1fb3e9(0x218)]??0x1)+_0x1fb3e9(0x215)+_0xd7eef5[_0x1fb3e9(0x1f4)]['id']+_0x1fb3e9(0x246)+_0x2870ef+'.'});},async 'execute'(_0x3046af){const _0x53fb9d=a102_0x522b70;requireExplicitYes(_0x3046af),validateDeleteExecuteInput(_0x3046af);const _0x5879ce=await readMenuDeletePlan(_0x3046af['str']('plan')),_0x303cdd=mutationPlanFromDeleteFile(_0x5879ce[_0x53fb9d(0x1fd)],_0x5879ce[_0x53fb9d(0x20e)]),_0x1312e8=_0x5879ce['plan'][_0x53fb9d(0x24d)]['id'];try{assertMenuDeletePlanExecutable(_0x5879ce[_0x53fb9d(0x1fd)],_0x3046af[_0x53fb9d(0x20a)]);}catch(_0x5590f8){throw menuFailure(asMenuError(_0x5590f8),_0x303cdd,{'stage':_0x53fb9d(0x228),'failed':{'id':_0x1312e8}});}let _0x5150c8,_0x55b87b;try{_0x5150c8=await fetchMutationSnapshot(_0x3046af,'execute\x20reviewed\x20delete\x20plan',_0x1312e8),_0x55b87b=assertMenuDeletePlanCurrent(_0x5879ce[_0x53fb9d(0x1fd)],_0x3046af[_0x53fb9d(0x20a)],_0x5150c8),assertDeleteTargetsComplete(_0x5879ce['plan'],_0x5150c8),_0x55b87b['forEach'](_0x237346=>assertDeleteSafety(_0x237346,_0x5879ce[_0x53fb9d(0x1fd)]['recursive'])),assertNoSharedPages(_0x5150c8,_0x55b87b),assertCascadeMatchesPlan(_0x303cdd,_0x55b87b);}catch(_0x120d2c){throw menuFailure(asMenuError(_0x120d2c),_0x303cdd,{'stage':_0x53fb9d(0x232),'failed':{'id':_0x1312e8}});}const _0x1a9783=_0x5879ce[_0x53fb9d(0x1fd)][_0x53fb9d(0x245)];let _0x377370;try{_0x377370=await batchDeleteMenuEntities(_0x3046af[_0x53fb9d(0x251)],_0x1a9783);}catch(_0x7b2e8e){const _0xa04eef=mapMenuApiError(_0x7b2e8e,_0x53fb9d(0x1ed)),_0x2ee284=[_0x53fb9d(0x250)];let _0xd0f07c;try{_0xd0f07c=await readDeleteOutcome(_0x3046af,_0x1a9783);}catch(_0x3e0c0e){const _0x34c2bb=describeMenuErrorCause(_0x3e0c0e,_0x53fb9d(0x1da),_0x1312e8);_0x2ee284[_0x53fb9d(0x1e0)](_0x53fb9d(0x1d6)+_0x34c2bb[_0x53fb9d(0x21e)]+_0x53fb9d(0x241)+_0x34c2bb[_0x53fb9d(0x1ee)]);throw menuFailure(_0xa04eef,_0x303cdd,{'stage':'batch-delete','failed':{'targetIds':_0x1a9783,'targetIdsAbsent':_0x53fb9d(0x1d5),..._0x34c2bb},'warnings':_0x2ee284,'verification':{'status':_0x53fb9d(0x205),'lookupCommand':'rabetbase\x20menu\x20list\x20--format\x20json','targetIds':_0x1a9783}});}throw menuFailure(_0xa04eef,_0x303cdd,{'stage':_0x53fb9d(0x1d7),'succeeded':_0xd0f07c['absentIds'][_0x53fb9d(0x1d4)](_0x29c87a=>({'id':_0x29c87a,'deleted':!![]})),'failed':{'targetIds':_0x1a9783,'absentIds':_0xd0f07c[_0x53fb9d(0x1f7)],'remainingIds':_0xd0f07c[_0x53fb9d(0x1ea)]},'warnings':_0x2ee284,'verification':verificationFromOutcome(_0xd0f07c)});}if(_0x377370!==_0x1a9783[_0x53fb9d(0x218)]){const _0x2385a0=menuError(_0x53fb9d(0x233),_0x53fb9d(0x23c)+_0x377370+_0x53fb9d(0x221)+_0x1a9783[_0x53fb9d(0x218)]+'.',_0x53fb9d(0x237)),_0x237b70=[_0x53fb9d(0x206)];let _0x469144;try{_0x469144=await readDeleteOutcome(_0x3046af,_0x1a9783);}catch(_0x5caaa2){const _0xe08e21=describeMenuErrorCause(_0x5caaa2,_0x53fb9d(0x222),_0x1312e8);_0x237b70[_0x53fb9d(0x1e0)](_0x53fb9d(0x234)+_0xe08e21['causeCode']+_0x53fb9d(0x241)+_0xe08e21['causeMessage']);throw menuFailure(_0x2385a0,_0x303cdd,{'stage':_0x53fb9d(0x1d7),'failed':{'targetIds':_0x1a9783,'expectedCount':_0x1a9783[_0x53fb9d(0x218)],'reportedDeletedCount':_0x377370,'targetIdsAbsent':_0x53fb9d(0x1d5),..._0xe08e21},'warnings':_0x237b70,'verification':{'status':_0x53fb9d(0x205),'lookupCommand':'rabetbase\x20menu\x20list\x20--format\x20json','targetIds':_0x1a9783}});}throw menuFailure(_0x2385a0,_0x303cdd,{'stage':_0x53fb9d(0x1d7),'succeeded':_0x469144['absentIds'][_0x53fb9d(0x1d4)](_0x5191a0=>({'id':_0x5191a0,'deleted':!![]})),'failed':{'targetIds':_0x1a9783,'expectedCount':_0x1a9783['length'],'reportedDeletedCount':_0x377370,'absentIds':_0x469144[_0x53fb9d(0x1f7)],'remainingIds':_0x469144[_0x53fb9d(0x1ea)]},'warnings':_0x237b70,'verification':verificationFromOutcome(_0x469144)});}let _0x5c0f9b;try{_0x5c0f9b=await readDeleteOutcome(_0x3046af,_0x1a9783);}catch(_0x12bffd){const _0x5e98bc=describeMenuErrorCause(_0x12bffd,'verify\x20batch\x20delete',_0x1312e8),_0x5badcc=asVerificationError(_0x12bffd,_0x53fb9d(0x1ff)+_0x1312e8+_0x53fb9d(0x236));throw menuFailure(_0x5badcc,_0x303cdd,{'stage':_0x53fb9d(0x226),'succeeded':_0x1a9783[_0x53fb9d(0x1d4)](_0x3331ad=>({'id':_0x3331ad,'deleteRequested':!![]})),'failed':{'id':_0x1312e8,'targetIds':_0x1a9783,'targetIdsAbsent':_0x53fb9d(0x1d5),..._0x5e98bc},'warnings':[_0x53fb9d(0x22c)],'verification':{'status':_0x53fb9d(0x205),'lookupCommand':_0x53fb9d(0x21f),'targetIds':_0x1a9783}});}if(_0x5c0f9b[_0x53fb9d(0x1ea)][_0x53fb9d(0x218)]>0x0){const _0x39159b=menuError(_0x53fb9d(0x1e3),_0x53fb9d(0x1fa)+_0x5c0f9b['remainingIds'][_0x53fb9d(0x1db)](',\x20')+'.','Inspect\x20the\x20latest\x20menu\x20facts\x20and\x20generate\x20a\x20new\x20delete\x20plan;\x20do\x20not\x20retry\x20this\x20plan.');throw menuFailure(_0x39159b,_0x303cdd,{'stage':_0x53fb9d(0x226),'succeeded':_0x1a9783[_0x53fb9d(0x1d4)](_0x274fa6=>({'id':_0x274fa6,'deleteRequested':!![]})),'failed':{'id':_0x1312e8,'targetIds':_0x1a9783,'absentIds':_0x5c0f9b[_0x53fb9d(0x1f7)],'remainingIds':_0x5c0f9b[_0x53fb9d(0x1ea)]},'warnings':['The\x20backend\x20acknowledged\x20the\x20batch\x20request,\x20but\x20final\x20menu\x20facts\x20did\x20not\x20confirm\x20every\x20deletion.'],'verification':verificationFromOutcome(_0x5c0f9b)});}const _0x369880=_0x1a9783[_0x53fb9d(0x1d4)](_0xe8212d=>({'id':_0xe8212d,'deleted':!![]})),_0x598636=mutationResult({..._0x303cdd,'dryRun':![],'succeeded':_0x369880,'verification':{'checkedBy':'menu\x20list','plannedSnapshotHash':_0x303cdd[_0x53fb9d(0x24c)],'finalSnapshotHash':_0x5c0f9b['snapshot']['hash'],'reportedDeletedCount':_0x377370,'targetAbsent':!_0x5c0f9b[_0x53fb9d(0x1f3)]['byId'][_0x53fb9d(0x200)](_0x1312e8),'allTargetsAbsent':!![],'targetIds':_0x1a9783}});return{'ok':!![],'data':_0x598636,'message':'Deleted\x20'+_0x369880[_0x53fb9d(0x218)]+'\x20menu(s)\x20under\x20exact\x20id\x20'+_0x1312e8+'.'};}};async function readDeleteOutcome(_0x4dfedf,_0x26fa69){const _0x3c4154=a102_0x522b70,_0x153ef3=await fetchMenuSnapshot(_0x4dfedf[_0x3c4154(0x20a)],_0x4dfedf[_0x3c4154(0x251)]);return{'snapshot':_0x153ef3,'absentIds':_0x26fa69[_0x3c4154(0x225)](_0x5bc295=>!_0x153ef3[_0x3c4154(0x229)][_0x3c4154(0x200)](_0x5bc295)),'remainingIds':_0x26fa69[_0x3c4154(0x225)](_0x5714c1=>_0x153ef3[_0x3c4154(0x229)][_0x3c4154(0x200)](_0x5714c1))};}function verificationFromOutcome(_0x51d9d1){const _0x1e9534=a102_0x522b70;return{'checkedBy':'menu\x20list','absentIds':_0x51d9d1[_0x1e9534(0x1f7)],'remainingIds':_0x51d9d1[_0x1e9534(0x1ea)]};}function validateDeleteDryRunInput(_0x277da6){const _0x27d102=a102_0x522b70;validateExactId(_0x277da6);if(!hasFlag(_0x277da6,_0x27d102(0x22a))||!_0x277da6[_0x27d102(0x1f8)](_0x27d102(0x22a))[_0x27d102(0x202)]())throw CliErrors['flagMissing'](_0x27d102(0x22a),_0x27d102(0x207));if(hasFlag(_0x277da6,_0x27d102(0x1fd)))throw CliErrors[_0x27d102(0x1e8)](_0x27d102(0x249));}function validateDeleteExecuteInput(_0x28e440){const _0x4f7017=a102_0x522b70;if(!hasFlag(_0x28e440,_0x4f7017(0x1fd))||!_0x28e440[_0x4f7017(0x1f8)](_0x4f7017(0x1fd))['trim']())throw CliErrors['flagMissing']('plan',_0x4f7017(0x1fb));const _0x1711ff=['id',_0x4f7017(0x23f),_0x4f7017(0x22a),_0x4f7017(0x1e9),_0x4f7017(0x217),_0x4f7017(0x223)]['filter'](_0x3bcf90=>hasFlag(_0x28e440,_0x3bcf90));if(_0x1711ff[_0x4f7017(0x218)]>0x0)throw CliErrors['validation'](_0x4f7017(0x1e5)+_0x1711ff[_0x4f7017(0x1d4)](_0x4bbcfb=>'--'+_0x4bbcfb)[_0x4f7017(0x1db)](',\x20')+'.');}async function buildDeletePlan(_0x3df04b){const _0x52a913=a102_0x522b70,_0x3d9043=validateExactId(_0x3df04b),_0x2bda66=await fetchMutationSnapshot(_0x3df04b,_0x52a913(0x247),_0x3d9043),_0x6964dc=requireMenu(_0x2bda66,_0x3d9043);assertExpectedState(_0x3df04b,_0x6964dc);const _0x2e52c8=_0x3df04b['bool'](_0x52a913(0x23f));let _0x124002;if(_0x2e52c8){if(_0x6964dc['type']['trim']()[_0x52a913(0x1f2)]()!==_0x52a913(0x23e))throw menuError(_0x52a913(0x20c),_0x52a913(0x224)+_0x6964dc['id']+_0x52a913(0x242)+(_0x6964dc[_0x52a913(0x231)]||_0x52a913(0x23d))+_0x52a913(0x213));_0x124002=collectDeleteTargets(_0x2bda66,_0x6964dc),_0x124002[_0x52a913(0x1e7)](_0x299406=>assertDeleteSafety(_0x299406,!![]));}else assertDeleteSafety(_0x6964dc),_0x124002=[_0x6964dc];assertNoSharedPages(_0x2bda66,_0x124002);const _0x458f7c=_0x124002[_0x52a913(0x1d4)](_0x499236=>_0x499236['id']),_0x37e99e=cascadeForTargets(_0x124002),_0x47a0a3=_0x37e99e[_0x52a913(0x203)][_0x52a913(0x218)]>0x0?[_0x52a913(0x24f)]:[];return mutationResult({'operation':_0x52a913(0x211),'selector':{'id':_0x3d9043,'recursive':_0x2e52c8},'before':_0x6964dc,'after':null,'dryRun':!![],'backend':[...BACKEND],'plannedActions':[{'stage':_0x52a913(0x1e4),'method':_0x52a913(0x1df),'path':'/smartapi/menu/batchDelete','body':{'idList':_0x458f7c}}],'targets':_0x124002,'deleteOrder':_0x458f7c,'snapshotHash':_0x2bda66[_0x52a913(0x219)],'cascade':_0x37e99e,'warnings':_0x47a0a3});}function assertDeleteSafety(_0x3fce48,_0x32a38d=![]){const _0x1ce1dc=a102_0x522b70,_0x17a7b9=_0x3fce48['type']['trim']()[_0x1ce1dc(0x1f2)]()===_0x1ce1dc(0x23e);if(_0x3fce48[_0x1ce1dc(0x1fc)]>0x0&&(!_0x32a38d||!_0x17a7b9))throw menuError(_0x1ce1dc(0x239),_0x1ce1dc(0x224)+_0x3fce48['id']+_0x1ce1dc(0x209)+_0x3fce48['childrenCount']+_0x1ce1dc(0x1ec),_0x1ce1dc(0x227)+_0x3fce48[_0x1ce1dc(0x1f6)][_0x1ce1dc(0x1db)](',\x20'));if(_0x17a7b9&&_0x3fce48['pageId']!=null)throw menuError(_0x1ce1dc(0x1e1),_0x1ce1dc(0x23b)+_0x3fce48['id']+_0x1ce1dc(0x20d)+_0x3fce48[_0x1ce1dc(0x21c)]+_0x1ce1dc(0x22e),_0x1ce1dc(0x21a));if(!_0x17a7b9)return;if(!_0x3fce48['resourcesValid'])throw menuError(_0x1ce1dc(0x210),_0x1ce1dc(0x23b)+_0x3fce48['id']+_0x1ce1dc(0x240),_0x1ce1dc(0x1de));if(_0x3fce48[_0x1ce1dc(0x248)][_0x1ce1dc(0x218)]>0x0)throw menuError('menu_folder_has_resources',_0x1ce1dc(0x23b)+_0x3fce48['id']+'\x20still\x20references\x20'+_0x3fce48[_0x1ce1dc(0x248)][_0x1ce1dc(0x218)]+_0x1ce1dc(0x1dc),'Remove\x20or\x20verify\x20the\x20resource\x20bindings\x20in\x20the\x20platform\x20before\x20deleting\x20the\x20folder.');}function a102_0x5e92(){const _0x22dd2d=['recursive','\x20has\x20an\x20unreadable\x20extend.resources\x20value\x20and\x20cannot\x20be\x20proven\x20empty.','):\x20','\x20is\x20type\x20\x22','bool','Menu\x20delete\x20plan\x20does\x20not\x20contain\x20the\x20complete\x20current\x20subtree\x20in\x20leaf-first\x20order.','deleteOrder',';\x20execution\x20must\x20consume\x20','plan\x20delete','resources','--plan\x20cannot\x20be\x20combined\x20with\x20--dry-run;\x20use\x20--plan-out.','4215488AcMlru','3030vHYwfe','snapshotHash','target','createdAt','Deleting\x20page-bound\x20menus\x20invokes\x20the\x20platform\x27s\x20existing\x20page\x20and\x20PageSchema\x20cascade;\x20listed\x20page\x20ids\x20are\x20direct\x20menu\x20bindings.','The\x20batch\x20delete\x20may\x20have\x20partially\x20applied;\x20inspect\x20the\x20latest\x20menu\x20facts\x20before\x20creating\x20a\x20new\x20plan.','cookie','7FZiGgc','map','unconfirmed','Post-failure\x20menu\x20readback\x20failed\x20(','batch-delete','Keep\x20every\x20shared\x20page\x20reference\x20outside\x20this\x20operation,\x20or\x20choose\x20a\x20folder\x20whose\x20complete\x20subtree\x20contains\x20all\x20references.','Menu\x20delete\x20plan\x20cascade\x20does\x20not\x20match\x20the\x20reviewed\x20target\x20page\x20facts.','read\x20menu\x20state\x20after\x20batch\x20delete\x20failure','join','\x20resource\x20URL(s).','Generate\x20a\x20new\x20plan\x20with\x20--dry-run\x20--plan-out\x20and\x20do\x20not\x20remove\x20or\x20reorder\x20targets.','Inspect\x20and\x20repair\x20the\x20folder\x20resource\x20binding\x20in\x20the\x20platform\x20before\x20deleting\x20it.','POST','push','menu_delete_page_bound','boolean','menu_verification_failed','batch-delete-menu','Menu\x20delete\x20execution\x20consumes\x20only\x20--plan;\x20remove\x20','223YoOazN','forEach','validation','expect-parent-id','remainingIds','menu_page_shared','\x20direct\x20child\x20menu(s)\x20and\x20cannot\x20be\x20deleted.','batch\x20delete','causeMessage','cascade','expiresAt','Required\x20for\x20execution;\x20consume\x20an\x20unexpired\x20plan\x20created\x20by\x20--plan-out','toLowerCase','snapshot','selector','9693DHYzrY','childrenIds','absentIds','str','398695dHgddr','One\x20or\x20more\x20planned\x20menus\x20are\x20still\x20present\x20after\x20the\x20batch\x20delete\x20request:\x20','--plan\x20is\x20required\x20for\x20menu\x20delete\x20execution.','childrenCount','plan','message','Batch\x20delete\x20request\x20for\x20menu\x20','has','size','trim','pages','menu_tree_invalid','failed','The\x20batch\x20response\x20count\x20did\x20not\x20match\x20the\x20reviewed\x20target\x20count;\x20do\x20not\x20retry\x20the\x20same\x20plan.','--plan-out\x20is\x20required\x20for\x20menu\x20delete\x20dry-run\x20so\x20execution\x20can\x20consume\x20the\x20reviewed\x20plan.','string','\x20has\x20','appCode','Delete\x20an\x20exact\x20menu\x20or\x20a\x20folder\x20subtree\x20from\x20a\x20reviewed\x20plan','menu_recursive_requires_folder','\x20is\x20unexpectedly\x20bound\x20to\x20page\x20','path','stringify','menu_folder_resources_invalid','delete','/smartapi/menu/batchDelete','\x22;\x20--recursive\x20requires\x20a\x20folder\x20root.','menu_plan_invalid','\x20menu(s)\x20under\x20exact\x20id\x20','menus','expect-path','length','hash','Inspect\x20the\x20folder\x20in\x20the\x20platform\x20before\x20deleting\x20it.','252GiNOaV','pageId','903505vkFmKR','causeCode','rabetbase\x20menu\x20list\x20--format\x20json','1682OzWLXM','\x20deleted\x20menus;\x20expected\x20','read\x20menu\x20state\x20after\x20batch\x20delete\x20count\x20mismatch','expected-children-count','Menu\x20','filter','verification','Handle\x20child\x20ids\x20in\x20the\x20platform\x20first:\x20','plan-validation','byId','plan-out','add','The\x20batch\x20delete\x20request\x20was\x20accepted,\x20but\x20its\x20final\x20online\x20state\x20is\x20unconfirmed.','high-risk-write','\x20and\x20cannot\x20be\x20deleted\x20safely.','Page\x20bindings\x20are\x20referenced\x20by\x20menus\x20outside\x20the\x20delete\x20plan:\x20','4RobENN','type','pre-write-plan-validation','menu_batch_delete_count_mismatch','Post-mismatch\x20menu\x20readback\x20failed\x20(','page\x20','\x20completed\x20but\x20readback\x20could\x20not\x20confirm\x20absence','Inspect\x20the\x20latest\x20menu\x20facts\x20and\x20generate\x20a\x20new\x20delete\x20plan;\x20do\x20not\x20retry\x20this\x20plan.','3204246lcmDfG','menu_non_empty','911607ZPygdZ','Folder\x20','Backend\x20reported\x20','unknown','folder'];a102_0x5e92=function(){return _0x22dd2d;};return a102_0x5e92();}function collectDeleteTargets(_0x5b62d1,_0x54337f){const _0x567a1c=[],_0x16da3c=new Set(),_0x445789=new Set(),_0x1400c9=_0x2c72db=>{const _0x2b019a=a102_0x4716;if(_0x16da3c['has'](_0x2c72db['id']))throw menuError('menu_tree_invalid','Menu\x20tree\x20contains\x20a\x20cycle\x20at\x20menu\x20'+_0x2c72db['id']+'.');if(_0x445789['has'](_0x2c72db['id']))return;_0x16da3c[_0x2b019a(0x22b)](_0x2c72db['id']);for(const _0x19222e of _0x2c72db[_0x2b019a(0x1f6)]){const _0x5a6fa8=_0x5b62d1[_0x2b019a(0x229)]['get'](_0x19222e);if(!_0x5a6fa8)throw menuError(_0x2b019a(0x204),_0x2b019a(0x224)+_0x2c72db['id']+'\x20references\x20missing\x20child\x20'+_0x19222e+'.');_0x1400c9(_0x5a6fa8);}_0x16da3c['delete'](_0x2c72db['id']),_0x445789[_0x2b019a(0x22b)](_0x2c72db['id']),_0x567a1c[_0x2b019a(0x1e0)](_0x2c72db);};return _0x1400c9(_0x54337f),_0x567a1c;}function assertDeleteTargetsComplete(_0x4dd9bf,_0x5e78ea){const _0x42c3be=a102_0x522b70,_0x4ed747=requireMenu(_0x5e78ea,_0x4dd9bf[_0x42c3be(0x24d)]['id']);if(_0x4dd9bf[_0x42c3be(0x23f)]&&_0x4ed747[_0x42c3be(0x231)]['trim']()[_0x42c3be(0x1f2)]()!=='folder')throw menuError(_0x42c3be(0x214),'Recursive\x20menu\x20delete\x20plan\x20root\x20'+_0x4ed747['id']+'\x20is\x20not\x20a\x20folder.');const _0x3ce2cb=_0x4dd9bf[_0x42c3be(0x23f)]?collectDeleteTargets(_0x5e78ea,_0x4ed747)['map'](_0x4b2590=>_0x4b2590['id']):[_0x4ed747['id']];if(JSON[_0x42c3be(0x20f)](_0x4dd9bf['deleteOrder'])!==JSON[_0x42c3be(0x20f)](_0x3ce2cb))throw menuError('menu_plan_invalid',_0x42c3be(0x244),_0x42c3be(0x1dd));}function assertNoSharedPages(_0x13f04a,_0x44864d){const _0x3c63f7=a102_0x522b70,_0x50f16c=new Set(_0x44864d[_0x3c63f7(0x1d4)](_0x372d94=>_0x372d94['id'])),_0x4839c1=new Set(_0x44864d[_0x3c63f7(0x1d4)](_0x15db46=>_0x15db46[_0x3c63f7(0x21c)])[_0x3c63f7(0x225)](_0xecd3a=>_0xecd3a!=null));if(_0x4839c1[_0x3c63f7(0x201)]===0x0)return;const _0x52443d=_0x13f04a[_0x3c63f7(0x216)][_0x3c63f7(0x225)](_0x1ccc35=>!_0x50f16c['has'](_0x1ccc35['id'])&&_0x1ccc35[_0x3c63f7(0x21c)]!=null&&_0x4839c1[_0x3c63f7(0x200)](_0x1ccc35['pageId']));if(_0x52443d[_0x3c63f7(0x218)]===0x0)return;const _0x566c81=_0x52443d['map'](_0x44864a=>_0x3c63f7(0x235)+_0x44864a['pageId']+'\x20->\x20menu\x20'+_0x44864a['id'])['join'](',\x20');throw menuError(_0x3c63f7(0x1eb),_0x3c63f7(0x22f)+_0x566c81+'.',_0x3c63f7(0x1d8));}function assertCascadeMatchesPlan(_0x5cf003,_0x1c5581){const _0x535e2f=a102_0x522b70,_0xef22be=cascadeForTargets(_0x1c5581);if(JSON[_0x535e2f(0x20f)](_0x5cf003[_0x535e2f(0x1ef)])!==JSON[_0x535e2f(0x20f)](_0xef22be))throw menuError(_0x535e2f(0x214),_0x535e2f(0x1d9));}function cascadeForTargets(_0x4b62ee){const _0x4cf6b0=a102_0x522b70,_0x284a64=_0x4b62ee['map'](_0xde0cca=>_0xde0cca[_0x4cf6b0(0x21c)])[_0x4cf6b0(0x225)](_0x41b210=>_0x41b210!=null)[_0x4cf6b0(0x225)]((_0x5ee773,_0x5b8996,_0x49af2a)=>_0x49af2a['indexOf'](_0x5ee773)===_0x5b8996);return{'pages':_0x284a64,'pageSchemaAffected':_0x284a64[_0x4cf6b0(0x218)]>0x0};}function asMenuError(_0x5338b){const _0x1a3811=a102_0x522b70;return _0x5338b instanceof CliError?_0x5338b:menuError(_0x1a3811(0x214),_0x5338b instanceof Error?_0x5338b[_0x1a3811(0x1fe)]:String(_0x5338b));}
1
+ const a102_0x5416ef=a102_0x522e;(function(_0x302c8d,_0x521dfa){const _0x30e2e7=a102_0x522e,_0x59ff15=_0x302c8d();while(!![]){try{const _0x521c4b=-parseInt(_0x30e2e7(0x120))/0x1+parseInt(_0x30e2e7(0x192))/0x2*(-parseInt(_0x30e2e7(0x12e))/0x3)+-parseInt(_0x30e2e7(0x143))/0x4+parseInt(_0x30e2e7(0x14a))/0x5*(-parseInt(_0x30e2e7(0x13b))/0x6)+-parseInt(_0x30e2e7(0x181))/0x7*(parseInt(_0x30e2e7(0x141))/0x8)+parseInt(_0x30e2e7(0x18d))/0x9+parseInt(_0x30e2e7(0x144))/0xa;if(_0x521c4b===_0x521dfa)break;else _0x59ff15['push'](_0x59ff15['shift']());}catch(_0x56b7ad){_0x59ff15['push'](_0x59ff15['shift']());}}}(a102_0x564f,0x68fae));import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{assertMenuDeletePlanCurrent,assertMenuDeletePlanExecutable,createMenuDeletePlanFile,mutationPlanFromDeleteFile,readMenuDeletePlan,writeMenuDeletePlan}from'../../commands/menu/shared/delete-plan.js';import{fetchMenuSnapshot}from'../../commands/menu/shared/facts.js';import{MENU_EXPECT_FLAGS,MENU_ID_FLAG,asVerificationError,assertExpectedState,describeMenuErrorCause,fetchMutationSnapshot,hasFlag,mapMenuApiError,menuDryRunResult,menuError,menuFailure,mutationResult,requireExplicitYes,requireMenu,validateExactId}from'../../commands/menu/shared/mutations.js';function a102_0x564f(){const _0x1e648f=['childrenIds','menu_plan_invalid','Inspect\x20the\x20folder\x20in\x20the\x20platform\x20before\x20deleting\x20it.','expiresAt','Menu\x20delete\x20plan\x20does\x20not\x20contain\x20the\x20complete\x20current\x20subtree\x20in\x20leaf-first\x20order.','causeCode','Menu\x20tree\x20contains\x20a\x20cycle\x20at\x20menu\x20','Required\x20with\x20--dry-run;\x20write\x20the\x20reviewed\x20plan\x20to\x20a\x20new\x20local\x20JSON\x20file','expect-parent-id','childrenCount','batch-delete-menu','Post-mismatch\x20menu\x20readback\x20failed\x20(','Delete\x20an\x20exact\x20menu\x20or\x20a\x20folder\x20subtree\x20from\x20a\x20reviewed\x20plan','failed','batch\x20delete','hash','Exact\x20menu\x20id\x20(required\x20with\x20--dry-run)','1168237eUUbmr','cookie','causeMessage','\x22;\x20--recursive\x20requires\x20a\x20folder\x20root.','indexOf','resources','plan\x20delete','POST','plan','menu','has','menu_folder_has_resources','3312279lOlQdF','toLowerCase','menu_delete_page_bound','type','unconfirmed','140dyePzc','forEach','read\x20menu\x20state\x20after\x20batch\x20delete\x20failure','\x20is\x20not\x20a\x20folder.','size','\x20references\x20missing\x20child\x20','--plan\x20is\x20required\x20for\x20menu\x20delete\x20execution.','Required\x20for\x20execution;\x20consume\x20an\x20unexpired\x20plan\x20created\x20by\x20--plan-out','The\x20backend\x20acknowledged\x20the\x20batch\x20request,\x20but\x20final\x20menu\x20facts\x20did\x20not\x20confirm\x20every\x20deletion.','absentIds','dry-run','Backend\x20reported\x20','expect-path','324501VkSOKI','str','\x20deleted\x20menus;\x20expected\x20','menus','Menu\x20delete\x20execution\x20consumes\x20only\x20--plan;\x20remove\x20','Folder\x20',';\x20execution\x20must\x20consume\x20','The\x20batch\x20response\x20count\x20did\x20not\x20match\x20the\x20reviewed\x20target\x20count;\x20do\x20not\x20retry\x20the\x20same\x20plan.','Inspect\x20the\x20latest\x20menu\x20facts\x20and\x20generate\x20a\x20new\x20delete\x20plan;\x20do\x20not\x20retry\x20this\x20plan.','plan-validation','\x20has\x20','batch-delete','verify\x20batch\x20delete','target','29961MxGhHX','add','Include\x20every\x20descendant\x20of\x20the\x20exact\x20folder\x20id,\x20deleting\x20leaves\x20first','map','):\x20','trim','appCode','Deleting\x20page-bound\x20menus\x20invokes\x20the\x20platform\x27s\x20existing\x20page\x20and\x20PageSchema\x20cascade;\x20listed\x20page\x20ids\x20are\x20direct\x20menu\x20bindings.','resourcesValid','Menu\x20','page\x20','Keep\x20every\x20shared\x20page\x20reference\x20outside\x20this\x20operation,\x20or\x20choose\x20a\x20folder\x20whose\x20complete\x20subtree\x20contains\x20all\x20references.','/smartapi/menu/batchDelete','1074UESsio','Recursive\x20menu\x20delete\x20plan\x20root\x20','\x20direct\x20child\x20menu(s)\x20and\x20cannot\x20be\x20deleted.','verification','plan-out','The\x20batch\x20delete\x20may\x20have\x20partially\x20applied;\x20inspect\x20the\x20latest\x20menu\x20facts\x20before\x20creating\x20a\x20new\x20plan.','24wAxyEh','menu_tree_invalid','294136XKVVWj','17909720AGrFxw','filter','The\x20batch\x20delete\x20request\x20was\x20accepted,\x20but\x20its\x20final\x20online\x20state\x20is\x20unconfirmed.','deleteOrder','--plan-out\x20is\x20required\x20for\x20menu\x20delete\x20dry-run\x20so\x20execution\x20can\x20consume\x20the\x20reviewed\x20plan.','bool','3665aIMKLu','Inspect\x20and\x20repair\x20the\x20folder\x20resource\x20binding\x20in\x20the\x20platform\x20before\x20deleting\x20it.','Generate\x20a\x20new\x20plan\x20with\x20--dry-run\x20--plan-out\x20and\x20do\x20not\x20remove\x20or\x20reorder\x20targets.','read\x20menu\x20state\x20after\x20batch\x20delete\x20count\x20mismatch','\x20menu(s)\x20under\x20exact\x20id\x20','menu_page_shared','stringify','snapshotHash','unknown','message','Menu\x20delete\x20plan\x20cascade\x20does\x20not\x20match\x20the\x20reviewed\x20target\x20page\x20facts.','rabetbase\x20menu\x20list\x20--format\x20json','Batch\x20delete\x20request\x20for\x20menu\x20','folder','validation','\x20has\x20an\x20unreadable\x20extend.resources\x20value\x20and\x20cannot\x20be\x20proven\x20empty.','delete','execute\x20reviewed\x20delete\x20plan','menu_recursive_requires_folder','Remove\x20or\x20verify\x20the\x20resource\x20bindings\x20in\x20the\x20platform\x20before\x20deleting\x20the\x20folder.','Would\x20batch\x20delete\x20','byId','string','length','join','Post-failure\x20menu\x20readback\x20failed\x20(','flagMissing','menu_folder_resources_invalid','recursive','\x20and\x20cannot\x20be\x20deleted\x20safely.','get','menu_verification_failed','\x20completed\x20but\x20readback\x20could\x20not\x20confirm\x20absence','push','menu_non_empty','pageId','remainingIds','menu\x20list'];a102_0x564f=function(){return _0x1e648f;};return a102_0x564f();}import{batchDeleteMenuEntities}from'../../commands/menu/shared/service.js';import{CliError,CliErrors}from'../../errors.js';const BACKEND=[{'method':a102_0x5416ef(0x188),'path':'/smartapi/menu/batchDelete'}],MENU_DELETE_ID_FLAG={...MENU_ID_FLAG,'required':![],'description':a102_0x5416ef(0x180)},MENU_DELETE_RECURSIVE_FLAG={'name':a102_0x5416ef(0x166),'type':'boolean','description':a102_0x5416ef(0x130)},MENU_DELETE_PLAN_OUT_FLAG={'name':'plan-out','type':a102_0x5416ef(0x160),'description':a102_0x5416ef(0x177)},MENU_DELETE_PLAN_FLAG={'name':'plan','type':a102_0x5416ef(0x160),'description':a102_0x5416ef(0x11a)};export const menuDelete={'service':a102_0x5416ef(0x18a),'command':'delete','description':a102_0x5416ef(0x17c),'risk':'high-risk-write','structuredErrors':!![],'flags':[MENU_DELETE_ID_FLAG,MENU_DELETE_RECURSIVE_FLAG,MENU_DELETE_PLAN_OUT_FLAG,MENU_DELETE_PLAN_FLAG,...MENU_EXPECT_FLAGS,APPCODE_FLAG_OPTIONAL],async 'validate'(_0x35f40e){const _0x3f8954=a102_0x5416ef;_0x35f40e[_0x3f8954(0x149)](_0x3f8954(0x11d))?validateDeleteDryRunInput(_0x35f40e):validateDeleteExecuteInput(_0x35f40e),requireExplicitYes(_0x35f40e);},async 'dryRun'(_0x3f28da){const _0x20dd7e=a102_0x5416ef;validateDeleteDryRunInput(_0x3f28da);const _0x532b3e=await buildDeletePlan(_0x3f28da),_0x49857a=createMenuDeletePlanFile(_0x3f28da[_0x20dd7e(0x134)],_0x532b3e),_0x39656e=await writeMenuDeletePlan(_0x3f28da[_0x20dd7e(0x121)]('plan-out'),_0x49857a),_0x1c3188=mutationResult({..._0x532b3e,'planFile':{'path':_0x39656e,'createdAt':_0x49857a['createdAt'],'expiresAt':_0x49857a[_0x20dd7e(0x173)]}});return menuDryRunResult(_0x1c3188,{'method':'POST','url':_0x20dd7e(0x13a),'body':{'idList':_0x1c3188[_0x20dd7e(0x147)]},'description':_0x20dd7e(0x15e)+(_0x1c3188[_0x20dd7e(0x147)]?.[_0x20dd7e(0x161)]??0x1)+_0x20dd7e(0x14e)+_0x1c3188['selector']['id']+_0x20dd7e(0x126)+_0x39656e+'.'});},async 'execute'(_0x3e7993){const _0x404019=a102_0x5416ef;requireExplicitYes(_0x3e7993),validateDeleteExecuteInput(_0x3e7993);const _0x161c3e=await readMenuDeletePlan(_0x3e7993[_0x404019(0x121)](_0x404019(0x189))),_0x3d5536=mutationPlanFromDeleteFile(_0x161c3e[_0x404019(0x189)],_0x161c3e['path']),_0x5d4d4b=_0x161c3e['plan'][_0x404019(0x12d)]['id'];try{assertMenuDeletePlanExecutable(_0x161c3e[_0x404019(0x189)],_0x3e7993[_0x404019(0x134)]);}catch(_0x4a89e4){throw menuFailure(asMenuError(_0x4a89e4),_0x3d5536,{'stage':_0x404019(0x129),'failed':{'id':_0x5d4d4b}});}let _0x45ef03,_0x10a3c1;try{_0x45ef03=await fetchMutationSnapshot(_0x3e7993,_0x404019(0x15b),_0x5d4d4b),_0x10a3c1=assertMenuDeletePlanCurrent(_0x161c3e['plan'],_0x3e7993[_0x404019(0x134)],_0x45ef03),assertDeleteTargetsComplete(_0x161c3e[_0x404019(0x189)],_0x45ef03),_0x10a3c1[_0x404019(0x193)](_0x20ae9d=>assertDeleteSafety(_0x20ae9d,_0x161c3e[_0x404019(0x189)][_0x404019(0x166)])),assertNoSharedPages(_0x45ef03,_0x10a3c1),assertCascadeMatchesPlan(_0x3d5536,_0x10a3c1);}catch(_0x345b41){throw menuFailure(asMenuError(_0x345b41),_0x3d5536,{'stage':'pre-write-plan-validation','failed':{'id':_0x5d4d4b}});}const _0x14aa7c=_0x161c3e[_0x404019(0x189)][_0x404019(0x147)];let _0x2c6edb;try{_0x2c6edb=await batchDeleteMenuEntities(_0x3e7993[_0x404019(0x182)],_0x14aa7c);}catch(_0x35f628){const _0x3368b5=mapMenuApiError(_0x35f628,_0x404019(0x17e)),_0x1ddb15=[_0x404019(0x140)];let _0x56acc0;try{_0x56acc0=await readDeleteOutcome(_0x3e7993,_0x14aa7c);}catch(_0xc013df){const _0x73f9b9=describeMenuErrorCause(_0xc013df,_0x404019(0x115),_0x5d4d4b);_0x1ddb15['push'](_0x404019(0x163)+_0x73f9b9[_0x404019(0x175)]+_0x404019(0x132)+_0x73f9b9[_0x404019(0x183)]);throw menuFailure(_0x3368b5,_0x3d5536,{'stage':_0x404019(0x12b),'failed':{'targetIds':_0x14aa7c,'targetIdsAbsent':_0x404019(0x191),..._0x73f9b9},'warnings':_0x1ddb15,'verification':{'status':_0x404019(0x17d),'lookupCommand':_0x404019(0x155),'targetIds':_0x14aa7c}});}throw menuFailure(_0x3368b5,_0x3d5536,{'stage':_0x404019(0x12b),'succeeded':_0x56acc0[_0x404019(0x11c)][_0x404019(0x131)](_0x1e5bcd=>({'id':_0x1e5bcd,'deleted':!![]})),'failed':{'targetIds':_0x14aa7c,'absentIds':_0x56acc0[_0x404019(0x11c)],'remainingIds':_0x56acc0[_0x404019(0x16e)]},'warnings':_0x1ddb15,'verification':verificationFromOutcome(_0x56acc0)});}if(_0x2c6edb!==_0x14aa7c[_0x404019(0x161)]){const _0x1bbcc5=menuError('menu_batch_delete_count_mismatch',_0x404019(0x11e)+_0x2c6edb+_0x404019(0x122)+_0x14aa7c['length']+'.',_0x404019(0x128)),_0x1a4ccb=[_0x404019(0x127)];let _0x29e2ae;try{_0x29e2ae=await readDeleteOutcome(_0x3e7993,_0x14aa7c);}catch(_0x36b5cb){const _0x5c444b=describeMenuErrorCause(_0x36b5cb,_0x404019(0x14d),_0x5d4d4b);_0x1a4ccb[_0x404019(0x16b)](_0x404019(0x17b)+_0x5c444b[_0x404019(0x175)]+'):\x20'+_0x5c444b['causeMessage']);throw menuFailure(_0x1bbcc5,_0x3d5536,{'stage':_0x404019(0x12b),'failed':{'targetIds':_0x14aa7c,'expectedCount':_0x14aa7c[_0x404019(0x161)],'reportedDeletedCount':_0x2c6edb,'targetIdsAbsent':_0x404019(0x191),..._0x5c444b},'warnings':_0x1a4ccb,'verification':{'status':'failed','lookupCommand':_0x404019(0x155),'targetIds':_0x14aa7c}});}throw menuFailure(_0x1bbcc5,_0x3d5536,{'stage':_0x404019(0x12b),'succeeded':_0x29e2ae[_0x404019(0x11c)]['map'](_0x52315e=>({'id':_0x52315e,'deleted':!![]})),'failed':{'targetIds':_0x14aa7c,'expectedCount':_0x14aa7c[_0x404019(0x161)],'reportedDeletedCount':_0x2c6edb,'absentIds':_0x29e2ae['absentIds'],'remainingIds':_0x29e2ae[_0x404019(0x16e)]},'warnings':_0x1a4ccb,'verification':verificationFromOutcome(_0x29e2ae)});}let _0x4661ea;try{_0x4661ea=await readDeleteOutcome(_0x3e7993,_0x14aa7c);}catch(_0x2027ae){const _0x13e9d1=describeMenuErrorCause(_0x2027ae,_0x404019(0x12c),_0x5d4d4b),_0x2d2d46=asVerificationError(_0x2027ae,_0x404019(0x156)+_0x5d4d4b+_0x404019(0x16a));throw menuFailure(_0x2d2d46,_0x3d5536,{'stage':_0x404019(0x13e),'succeeded':_0x14aa7c[_0x404019(0x131)](_0x4028c3=>({'id':_0x4028c3,'deleteRequested':!![]})),'failed':{'id':_0x5d4d4b,'targetIds':_0x14aa7c,'targetIdsAbsent':_0x404019(0x191),..._0x13e9d1},'warnings':[_0x404019(0x146)],'verification':{'status':'failed','lookupCommand':_0x404019(0x155),'targetIds':_0x14aa7c}});}if(_0x4661ea['remainingIds'][_0x404019(0x161)]>0x0){const _0x5de547=menuError(_0x404019(0x169),'One\x20or\x20more\x20planned\x20menus\x20are\x20still\x20present\x20after\x20the\x20batch\x20delete\x20request:\x20'+_0x4661ea[_0x404019(0x16e)][_0x404019(0x162)](',\x20')+'.',_0x404019(0x128));throw menuFailure(_0x5de547,_0x3d5536,{'stage':_0x404019(0x13e),'succeeded':_0x14aa7c[_0x404019(0x131)](_0x56316a=>({'id':_0x56316a,'deleteRequested':!![]})),'failed':{'id':_0x5d4d4b,'targetIds':_0x14aa7c,'absentIds':_0x4661ea[_0x404019(0x11c)],'remainingIds':_0x4661ea[_0x404019(0x16e)]},'warnings':[_0x404019(0x11b)],'verification':verificationFromOutcome(_0x4661ea)});}const _0x5e2477=_0x14aa7c['map'](_0x514b6e=>({'id':_0x514b6e,'deleted':!![]})),_0x21314c=mutationResult({..._0x3d5536,'dryRun':![],'succeeded':_0x5e2477,'verification':{'checkedBy':_0x404019(0x16f),'plannedSnapshotHash':_0x3d5536[_0x404019(0x151)],'finalSnapshotHash':_0x4661ea['snapshot'][_0x404019(0x17f)],'reportedDeletedCount':_0x2c6edb,'targetAbsent':!_0x4661ea['snapshot']['byId'][_0x404019(0x18b)](_0x5d4d4b),'allTargetsAbsent':!![],'targetIds':_0x14aa7c}});return{'ok':!![],'data':_0x21314c,'message':'Deleted\x20'+_0x5e2477[_0x404019(0x161)]+_0x404019(0x14e)+_0x5d4d4b+'.'};}};async function readDeleteOutcome(_0x4a14b0,_0x2b2260){const _0x5a8f81=a102_0x5416ef,_0x496302=await fetchMenuSnapshot(_0x4a14b0['appCode'],_0x4a14b0[_0x5a8f81(0x182)]);return{'snapshot':_0x496302,'absentIds':_0x2b2260[_0x5a8f81(0x145)](_0x4d7d8e=>!_0x496302[_0x5a8f81(0x15f)]['has'](_0x4d7d8e)),'remainingIds':_0x2b2260[_0x5a8f81(0x145)](_0x3ab016=>_0x496302[_0x5a8f81(0x15f)]['has'](_0x3ab016))};}function verificationFromOutcome(_0x33b909){const _0x485d6a=a102_0x5416ef;return{'checkedBy':_0x485d6a(0x16f),'absentIds':_0x33b909['absentIds'],'remainingIds':_0x33b909[_0x485d6a(0x16e)]};}function validateDeleteDryRunInput(_0x4b321f){const _0x2d342a=a102_0x5416ef;validateExactId(_0x4b321f);if(!hasFlag(_0x4b321f,_0x2d342a(0x13f))||!_0x4b321f[_0x2d342a(0x121)](_0x2d342a(0x13f))['trim']())throw CliErrors[_0x2d342a(0x164)](_0x2d342a(0x13f),_0x2d342a(0x148));if(hasFlag(_0x4b321f,'plan'))throw CliErrors[_0x2d342a(0x158)]('--plan\x20cannot\x20be\x20combined\x20with\x20--dry-run;\x20use\x20--plan-out.');}function validateDeleteExecuteInput(_0x949f12){const _0x316497=a102_0x5416ef;if(!hasFlag(_0x949f12,_0x316497(0x189))||!_0x949f12[_0x316497(0x121)](_0x316497(0x189))[_0x316497(0x133)]())throw CliErrors[_0x316497(0x164)]('plan',_0x316497(0x119));const _0x1aee3d=['id',_0x316497(0x166),_0x316497(0x13f),_0x316497(0x178),_0x316497(0x11f),'expected-children-count'][_0x316497(0x145)](_0x9a2e54=>hasFlag(_0x949f12,_0x9a2e54));if(_0x1aee3d[_0x316497(0x161)]>0x0)throw CliErrors[_0x316497(0x158)](_0x316497(0x124)+_0x1aee3d[_0x316497(0x131)](_0x506c0f=>'--'+_0x506c0f)[_0x316497(0x162)](',\x20')+'.');}async function buildDeletePlan(_0x23a694){const _0x2cecd4=a102_0x5416ef,_0x42c210=validateExactId(_0x23a694),_0x417fe2=await fetchMutationSnapshot(_0x23a694,_0x2cecd4(0x187),_0x42c210),_0x40dbd4=requireMenu(_0x417fe2,_0x42c210);assertExpectedState(_0x23a694,_0x40dbd4);const _0x13033c=_0x23a694[_0x2cecd4(0x149)](_0x2cecd4(0x166));let _0xdc41e1;if(_0x13033c){if(_0x40dbd4['type'][_0x2cecd4(0x133)]()[_0x2cecd4(0x18e)]()!==_0x2cecd4(0x157))throw menuError(_0x2cecd4(0x15c),_0x2cecd4(0x137)+_0x40dbd4['id']+'\x20is\x20type\x20\x22'+(_0x40dbd4[_0x2cecd4(0x190)]||_0x2cecd4(0x152))+_0x2cecd4(0x184));_0xdc41e1=collectDeleteTargets(_0x417fe2,_0x40dbd4),_0xdc41e1['forEach'](_0x3efc16=>assertDeleteSafety(_0x3efc16,!![]));}else assertDeleteSafety(_0x40dbd4),_0xdc41e1=[_0x40dbd4];assertNoSharedPages(_0x417fe2,_0xdc41e1);const _0x58d804=_0xdc41e1[_0x2cecd4(0x131)](_0x1d4dce=>_0x1d4dce['id']),_0xda9db2=cascadeForTargets(_0xdc41e1),_0x2ff5ee=_0xda9db2['pages'][_0x2cecd4(0x161)]>0x0?[_0x2cecd4(0x135)]:[];return mutationResult({'operation':_0x2cecd4(0x15a),'selector':{'id':_0x42c210,'recursive':_0x13033c},'before':_0x40dbd4,'after':null,'dryRun':!![],'backend':[...BACKEND],'plannedActions':[{'stage':_0x2cecd4(0x17a),'method':_0x2cecd4(0x188),'path':'/smartapi/menu/batchDelete','body':{'idList':_0x58d804}}],'targets':_0xdc41e1,'deleteOrder':_0x58d804,'snapshotHash':_0x417fe2[_0x2cecd4(0x17f)],'cascade':_0xda9db2,'warnings':_0x2ff5ee});}function assertDeleteSafety(_0x5c140e,_0x5610fb=![]){const _0x169dd5=a102_0x5416ef,_0x15ad60=_0x5c140e[_0x169dd5(0x190)][_0x169dd5(0x133)]()[_0x169dd5(0x18e)]()===_0x169dd5(0x157);if(_0x5c140e[_0x169dd5(0x179)]>0x0&&(!_0x5610fb||!_0x15ad60))throw menuError(_0x169dd5(0x16c),_0x169dd5(0x137)+_0x5c140e['id']+_0x169dd5(0x12a)+_0x5c140e[_0x169dd5(0x179)]+_0x169dd5(0x13d),'Handle\x20child\x20ids\x20in\x20the\x20platform\x20first:\x20'+_0x5c140e[_0x169dd5(0x170)][_0x169dd5(0x162)](',\x20'));if(_0x15ad60&&_0x5c140e['pageId']!=null)throw menuError(_0x169dd5(0x18f),_0x169dd5(0x125)+_0x5c140e['id']+'\x20is\x20unexpectedly\x20bound\x20to\x20page\x20'+_0x5c140e[_0x169dd5(0x16d)]+_0x169dd5(0x167),_0x169dd5(0x172));if(!_0x15ad60)return;if(!_0x5c140e[_0x169dd5(0x136)])throw menuError(_0x169dd5(0x165),_0x169dd5(0x125)+_0x5c140e['id']+_0x169dd5(0x159),_0x169dd5(0x14b));if(_0x5c140e[_0x169dd5(0x186)][_0x169dd5(0x161)]>0x0)throw menuError(_0x169dd5(0x18c),_0x169dd5(0x125)+_0x5c140e['id']+'\x20still\x20references\x20'+_0x5c140e[_0x169dd5(0x186)]['length']+'\x20resource\x20URL(s).',_0x169dd5(0x15d));}function collectDeleteTargets(_0x132392,_0x613295){const _0x454e75=[],_0x264e4c=new Set(),_0x6521e9=new Set(),_0x267164=_0x2248bd=>{const _0x391f6f=a102_0x522e;if(_0x264e4c[_0x391f6f(0x18b)](_0x2248bd['id']))throw menuError(_0x391f6f(0x142),_0x391f6f(0x176)+_0x2248bd['id']+'.');if(_0x6521e9[_0x391f6f(0x18b)](_0x2248bd['id']))return;_0x264e4c[_0x391f6f(0x12f)](_0x2248bd['id']);for(const _0x279094 of _0x2248bd['childrenIds']){const _0x1676cd=_0x132392[_0x391f6f(0x15f)][_0x391f6f(0x168)](_0x279094);if(!_0x1676cd)throw menuError(_0x391f6f(0x142),_0x391f6f(0x137)+_0x2248bd['id']+_0x391f6f(0x118)+_0x279094+'.');_0x267164(_0x1676cd);}_0x264e4c['delete'](_0x2248bd['id']),_0x6521e9[_0x391f6f(0x12f)](_0x2248bd['id']),_0x454e75[_0x391f6f(0x16b)](_0x2248bd);};return _0x267164(_0x613295),_0x454e75;}function assertDeleteTargetsComplete(_0x26d227,_0x396fda){const _0x4d71c7=a102_0x5416ef,_0xe64d28=requireMenu(_0x396fda,_0x26d227['target']['id']);if(_0x26d227[_0x4d71c7(0x166)]&&_0xe64d28['type'][_0x4d71c7(0x133)]()[_0x4d71c7(0x18e)]()!==_0x4d71c7(0x157))throw menuError(_0x4d71c7(0x171),_0x4d71c7(0x13c)+_0xe64d28['id']+_0x4d71c7(0x116));const _0x5f5234=_0x26d227['recursive']?collectDeleteTargets(_0x396fda,_0xe64d28)[_0x4d71c7(0x131)](_0xf9ede=>_0xf9ede['id']):[_0xe64d28['id']];if(JSON['stringify'](_0x26d227[_0x4d71c7(0x147)])!==JSON[_0x4d71c7(0x150)](_0x5f5234))throw menuError(_0x4d71c7(0x171),_0x4d71c7(0x174),_0x4d71c7(0x14c));}function assertNoSharedPages(_0x4dd078,_0x3fbb51){const _0x33ba83=a102_0x5416ef,_0x191e95=new Set(_0x3fbb51[_0x33ba83(0x131)](_0x13326b=>_0x13326b['id'])),_0x49ea78=new Set(_0x3fbb51['map'](_0x4df16f=>_0x4df16f[_0x33ba83(0x16d)])[_0x33ba83(0x145)](_0x1dc4df=>_0x1dc4df!=null));if(_0x49ea78[_0x33ba83(0x117)]===0x0)return;const _0x5e2558=_0x4dd078[_0x33ba83(0x123)][_0x33ba83(0x145)](_0x57e9e8=>!_0x191e95[_0x33ba83(0x18b)](_0x57e9e8['id'])&&_0x57e9e8[_0x33ba83(0x16d)]!=null&&_0x49ea78[_0x33ba83(0x18b)](_0x57e9e8[_0x33ba83(0x16d)]));if(_0x5e2558[_0x33ba83(0x161)]===0x0)return;const _0x465b3a=_0x5e2558['map'](_0x4be7e6=>_0x33ba83(0x138)+_0x4be7e6[_0x33ba83(0x16d)]+'\x20->\x20menu\x20'+_0x4be7e6['id'])[_0x33ba83(0x162)](',\x20');throw menuError(_0x33ba83(0x14f),'Page\x20bindings\x20are\x20referenced\x20by\x20menus\x20outside\x20the\x20delete\x20plan:\x20'+_0x465b3a+'.',_0x33ba83(0x139));}function a102_0x522e(_0x10026b,_0x5bf136){_0x10026b=_0x10026b-0x115;const _0x564f3b=a102_0x564f();let _0x522e7e=_0x564f3b[_0x10026b];return _0x522e7e;}function assertCascadeMatchesPlan(_0x55809a,_0x53987b){const _0x5c7b33=a102_0x5416ef,_0x2a9a1c=cascadeForTargets(_0x53987b);if(JSON['stringify'](_0x55809a['cascade'])!==JSON['stringify'](_0x2a9a1c))throw menuError('menu_plan_invalid',_0x5c7b33(0x154));}function cascadeForTargets(_0x43dd9d){const _0xb674aa=a102_0x5416ef,_0x251794=_0x43dd9d[_0xb674aa(0x131)](_0x3a37ed=>_0x3a37ed[_0xb674aa(0x16d)])[_0xb674aa(0x145)](_0x57d454=>_0x57d454!=null)[_0xb674aa(0x145)]((_0x420196,_0x48dbf1,_0x20ff05)=>_0x20ff05[_0xb674aa(0x185)](_0x420196)===_0x48dbf1);return{'pages':_0x251794,'pageSchemaAffected':_0x251794[_0xb674aa(0x161)]>0x0};}function asMenuError(_0x14ecb8){const _0x45efba=a102_0x5416ef;return _0x14ecb8 instanceof CliError?_0x14ecb8:menuError('menu_plan_invalid',_0x14ecb8 instanceof Error?_0x14ecb8[_0x45efba(0x153)]:String(_0x14ecb8));}