@lovrabet/rabetbase-cli 2.3.16-beta.4 → 2.3.16-beta.5

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 (560) hide show
  1. package/lib/api/api-doc.d.ts +9 -0
  2. package/lib/api/api-doc.js +1 -1
  3. package/lib/api/fetch-model-list.d.ts +2 -0
  4. package/lib/api/fetch-model-list.js +1 -1
  5. package/lib/api/generate-api-file.d.ts +8 -0
  6. package/lib/api/generate-api-file.js +1 -1
  7. package/lib/auth/auth-server-ui.d.ts +13 -0
  8. package/lib/auth/auth-server-ui.js +1 -1
  9. package/lib/auth/auth-server.d.ts +25 -0
  10. package/lib/auth/auth-server.js +1 -1
  11. package/lib/auth/constant.d.ts +2 -0
  12. package/lib/auth/constant.js +1 -1
  13. package/lib/auth/get-cookie.d.ts +1 -0
  14. package/lib/auth/get-cookie.js +1 -1
  15. package/lib/auth/get-session-user.d.ts +51 -0
  16. package/lib/auth/get-session-user.js +1 -1
  17. package/lib/auth/is-session-valid.d.ts +1 -0
  18. package/lib/auth/is-session-valid.js +1 -1
  19. package/lib/auth/login-success-html.d.ts +5 -0
  20. package/lib/auth/login-success-html.js +1 -1
  21. package/lib/auth/logout.d.ts +1 -0
  22. package/lib/auth/logout.js +1 -1
  23. package/lib/cli-flags.d.ts +12 -0
  24. package/lib/cli-flags.js +1 -1
  25. package/lib/cli.d.ts +2 -0
  26. package/lib/cli.js +1 -1
  27. package/lib/commands/api/generate.d.ts +2 -0
  28. package/lib/commands/api/generate.js +1 -1
  29. package/lib/commands/api/index.d.ts +2 -0
  30. package/lib/commands/api/index.js +1 -1
  31. package/lib/commands/api/list.d.ts +2 -0
  32. package/lib/commands/api/list.js +1 -1
  33. package/lib/commands/api/pull.d.ts +2 -0
  34. package/lib/commands/api/pull.js +1 -1
  35. package/lib/commands/api/shared.d.ts +18 -0
  36. package/lib/commands/api/shared.js +1 -1
  37. package/lib/commands/app/index.d.ts +5 -0
  38. package/lib/commands/app/index.js +1 -1
  39. package/lib/commands/app/list.d.ts +10 -0
  40. package/lib/commands/app/list.js +1 -1
  41. package/lib/commands/app/members-list.d.ts +2 -0
  42. package/lib/commands/app/members-list.js +1 -1
  43. package/lib/commands/app/remote-directory.d.ts +11 -0
  44. package/lib/commands/app/remote-directory.js +1 -1
  45. package/lib/commands/app/shared.d.ts +46 -0
  46. package/lib/commands/app/shared.js +1 -1
  47. package/lib/commands/app-config/delete.d.ts +2 -0
  48. package/lib/commands/app-config/delete.js +1 -1
  49. package/lib/commands/app-config/get.d.ts +2 -0
  50. package/lib/commands/app-config/get.js +1 -1
  51. package/lib/commands/app-config/index.d.ts +2 -0
  52. package/lib/commands/app-config/index.js +1 -1
  53. package/lib/commands/app-config/list.d.ts +2 -0
  54. package/lib/commands/app-config/list.js +1 -1
  55. package/lib/commands/app-config/set.d.ts +2 -0
  56. package/lib/commands/app-config/set.js +1 -1
  57. package/lib/commands/app-config/shared.d.ts +105 -0
  58. package/lib/commands/app-config/shared.js +1 -1
  59. package/lib/commands/auth/index.d.ts +2 -0
  60. package/lib/commands/auth/index.js +1 -1
  61. package/lib/commands/bff/create.d.ts +4 -0
  62. package/lib/commands/bff/create.js +1 -1
  63. package/lib/commands/bff/delete.d.ts +2 -0
  64. package/lib/commands/bff/delete.js +1 -1
  65. package/lib/commands/bff/detail.d.ts +2 -0
  66. package/lib/commands/bff/detail.js +1 -1
  67. package/lib/commands/bff/index.d.ts +5 -0
  68. package/lib/commands/bff/index.js +1 -1
  69. package/lib/commands/bff/list.d.ts +2 -0
  70. package/lib/commands/bff/list.js +1 -1
  71. package/lib/commands/bff/pull.d.ts +2 -0
  72. package/lib/commands/bff/pull.js +1 -1
  73. package/lib/commands/bff/push.d.ts +2 -0
  74. package/lib/commands/bff/push.js +1 -1
  75. package/lib/commands/bff/status.d.ts +2 -0
  76. package/lib/commands/bff/status.js +1 -1
  77. package/lib/commands/cli-skill/index.d.ts +8 -0
  78. package/lib/commands/cli-skill/index.js +1 -1
  79. package/lib/commands/cli-update.d.ts +2 -0
  80. package/lib/commands/cli-update.js +1 -1
  81. package/lib/commands/codegen/index.d.ts +2 -0
  82. package/lib/commands/codegen/index.js +1 -1
  83. package/lib/commands/codegen/sdk.d.ts +2 -0
  84. package/lib/commands/codegen/sdk.js +1 -1
  85. package/lib/commands/codegen/sql.d.ts +2 -0
  86. package/lib/commands/codegen/sql.js +1 -1
  87. package/lib/commands/common/app-registry.d.ts +17 -0
  88. package/lib/commands/common/app-registry.js +1 -1
  89. package/lib/commands/common/app-selector.d.ts +17 -0
  90. package/lib/commands/common/app-selector.js +1 -1
  91. package/lib/commands/common/async-task.d.ts +11 -0
  92. package/lib/commands/common/async-task.js +1 -1
  93. package/lib/commands/common/dry-run.d.ts +12 -0
  94. package/lib/commands/common/dry-run.js +1 -1
  95. package/lib/commands/common/flags.d.ts +26 -0
  96. package/lib/commands/common/flags.js +1 -1
  97. package/lib/commands/common/local-file.d.ts +6 -0
  98. package/lib/commands/common/local-file.js +1 -1
  99. package/lib/commands/common/validate.d.ts +13 -0
  100. package/lib/commands/common/validate.js +1 -1
  101. package/lib/commands/config/get.d.ts +5 -0
  102. package/lib/commands/config/get.js +1 -1
  103. package/lib/commands/config/index.d.ts +5 -0
  104. package/lib/commands/config/index.js +1 -1
  105. package/lib/commands/config/list.d.ts +5 -0
  106. package/lib/commands/config/list.js +1 -1
  107. package/lib/commands/config/set.d.ts +5 -0
  108. package/lib/commands/config/set.js +1 -1
  109. package/lib/commands/config/shared.d.ts +16 -0
  110. package/lib/commands/config/shared.js +1 -1
  111. package/lib/commands/data/filter.d.ts +7 -0
  112. package/lib/commands/data/filter.js +1 -1
  113. package/lib/commands/data/getOne.d.ts +7 -0
  114. package/lib/commands/data/getOne.js +1 -1
  115. package/lib/commands/data/index.d.ts +8 -0
  116. package/lib/commands/data/index.js +1 -1
  117. package/lib/commands/data/shared.d.ts +33 -0
  118. package/lib/commands/data/shared.js +1 -1
  119. package/lib/commands/dataset/business-group-update.d.ts +18 -0
  120. package/lib/commands/dataset/business-group-update.js +1 -1
  121. package/lib/commands/dataset/capability.d.ts +11 -0
  122. package/lib/commands/dataset/capability.js +1 -1
  123. package/lib/commands/dataset/delete.d.ts +2 -0
  124. package/lib/commands/dataset/delete.js +1 -1
  125. package/lib/commands/dataset/detail.d.ts +2 -0
  126. package/lib/commands/dataset/detail.js +1 -1
  127. package/lib/commands/dataset/extend-update.d.ts +26 -0
  128. package/lib/commands/dataset/extend-update.js +1 -1
  129. package/lib/commands/dataset/field-update.d.ts +27 -0
  130. package/lib/commands/dataset/field-update.js +1 -1
  131. package/lib/commands/dataset/generate.d.ts +3 -0
  132. package/lib/commands/dataset/generate.js +1 -1
  133. package/lib/commands/dataset/index.d.ts +2 -0
  134. package/lib/commands/dataset/index.js +1 -1
  135. package/lib/commands/dataset/list.d.ts +2 -0
  136. package/lib/commands/dataset/list.js +1 -1
  137. package/lib/commands/dataset/operations.d.ts +2 -0
  138. package/lib/commands/dataset/operations.js +1 -1
  139. package/lib/commands/dataset/relation-audit.d.ts +2 -0
  140. package/lib/commands/dataset/relation-audit.js +1 -1
  141. package/lib/commands/dataset/relation-create.d.ts +2 -0
  142. package/lib/commands/dataset/relation-create.js +1 -1
  143. package/lib/commands/dataset/relation-delete.d.ts +2 -0
  144. package/lib/commands/dataset/relation-delete.js +1 -1
  145. package/lib/commands/dataset/relation-shared.d.ts +128 -0
  146. package/lib/commands/dataset/relation-shared.js +1 -1
  147. package/lib/commands/dataset/relation-update.d.ts +2 -0
  148. package/lib/commands/dataset/relation-update.js +1 -1
  149. package/lib/commands/dataset/relations.d.ts +53 -0
  150. package/lib/commands/dataset/relations.js +1 -1
  151. package/lib/commands/dataset/rename.d.ts +17 -0
  152. package/lib/commands/dataset/rename.js +1 -1
  153. package/lib/commands/dataset/restore.d.ts +2 -0
  154. package/lib/commands/dataset/restore.js +1 -1
  155. package/lib/commands/db/analysis-batching.d.ts +30 -0
  156. package/lib/commands/db/analysis-batching.js +1 -1
  157. package/lib/commands/db/analyze-batch-plan.d.ts +2 -0
  158. package/lib/commands/db/analyze-batch-plan.js +1 -1
  159. package/lib/commands/db/analyze-cancel.d.ts +2 -0
  160. package/lib/commands/db/analyze-cancel.js +1 -1
  161. package/lib/commands/db/analyze-start.d.ts +2 -0
  162. package/lib/commands/db/analyze-start.js +1 -1
  163. package/lib/commands/db/analyze-status.d.ts +2 -0
  164. package/lib/commands/db/analyze-status.js +1 -1
  165. package/lib/commands/db/create.d.ts +2 -0
  166. package/lib/commands/db/create.js +1 -1
  167. package/lib/commands/db/delete.d.ts +2 -0
  168. package/lib/commands/db/delete.js +1 -1
  169. package/lib/commands/db/detail.d.ts +2 -0
  170. package/lib/commands/db/detail.js +1 -1
  171. package/lib/commands/db/diff.d.ts +2 -0
  172. package/lib/commands/db/diff.js +1 -1
  173. package/lib/commands/db/index.d.ts +5 -0
  174. package/lib/commands/db/index.js +1 -1
  175. package/lib/commands/db/list.d.ts +2 -0
  176. package/lib/commands/db/list.js +1 -1
  177. package/lib/commands/db/shared.d.ts +15 -0
  178. package/lib/commands/db/shared.js +1 -1
  179. package/lib/commands/db/tables.d.ts +2 -0
  180. package/lib/commands/db/tables.js +1 -1
  181. package/lib/commands/db/test.d.ts +2 -0
  182. package/lib/commands/db/test.js +1 -1
  183. package/lib/commands/db/update.d.ts +2 -0
  184. package/lib/commands/db/update.js +1 -1
  185. package/lib/commands/doctor.d.ts +2 -0
  186. package/lib/commands/doctor.js +1 -1
  187. package/lib/commands/file/index.d.ts +2 -0
  188. package/lib/commands/file/index.js +1 -1
  189. package/lib/commands/init/index.d.ts +11 -0
  190. package/lib/commands/init/index.js +1 -1
  191. package/lib/commands/issue/index.d.ts +2 -0
  192. package/lib/commands/issue/index.js +1 -1
  193. package/lib/commands/issue/nudge.d.ts +23 -0
  194. package/lib/commands/issue/nudge.js +1 -1
  195. package/lib/commands/issue/report.d.ts +2 -0
  196. package/lib/commands/issue/report.js +1 -1
  197. package/lib/commands/issue/shared.d.ts +32 -0
  198. package/lib/commands/issue/shared.js +1 -1
  199. package/lib/commands/kb/create.d.ts +2 -0
  200. package/lib/commands/kb/create.js +1 -1
  201. package/lib/commands/kb/delete.d.ts +2 -0
  202. package/lib/commands/kb/delete.js +1 -1
  203. package/lib/commands/kb/detail.d.ts +2 -0
  204. package/lib/commands/kb/detail.js +1 -1
  205. package/lib/commands/kb/index.d.ts +2 -0
  206. package/lib/commands/kb/index.js +1 -1
  207. package/lib/commands/kb/list.d.ts +2 -0
  208. package/lib/commands/kb/list.js +1 -1
  209. package/lib/commands/kb/shared.d.ts +33 -0
  210. package/lib/commands/kb/shared.js +1 -1
  211. package/lib/commands/kb/update.d.ts +2 -0
  212. package/lib/commands/kb/update.js +1 -1
  213. package/lib/commands/logs/index.d.ts +5 -0
  214. package/lib/commands/logs/index.js +1 -1
  215. package/lib/commands/menu/asset-update.d.ts +2 -0
  216. package/lib/commands/menu/asset-update.js +1 -1
  217. package/lib/commands/menu/delete.d.ts +2 -0
  218. package/lib/commands/menu/delete.js +1 -1
  219. package/lib/commands/menu/external-link-create.d.ts +3 -0
  220. package/lib/commands/menu/external-link-create.js +1 -1
  221. package/lib/commands/menu/external-link-update.d.ts +2 -0
  222. package/lib/commands/menu/external-link-update.js +1 -1
  223. package/lib/commands/menu/group-create.d.ts +2 -0
  224. package/lib/commands/menu/group-create.js +1 -1
  225. package/lib/commands/menu/group-update.d.ts +2 -0
  226. package/lib/commands/menu/group-update.js +1 -1
  227. package/lib/commands/menu/index.d.ts +17 -0
  228. package/lib/commands/menu/index.js +1 -1
  229. package/lib/commands/menu/list.d.ts +2 -0
  230. package/lib/commands/menu/list.js +1 -1
  231. package/lib/commands/menu/move.d.ts +2 -0
  232. package/lib/commands/menu/move.js +1 -1
  233. package/lib/commands/menu/regroup-start.d.ts +2 -0
  234. package/lib/commands/menu/regroup-start.js +1 -1
  235. package/lib/commands/menu/rename.d.ts +2 -0
  236. package/lib/commands/menu/rename.js +1 -1
  237. package/lib/commands/menu/shared/compare-table.d.ts +27 -0
  238. package/lib/commands/menu/shared/compare-table.js +1 -1
  239. package/lib/commands/menu/shared/delete-plan.d.ts +51 -0
  240. package/lib/commands/menu/shared/delete-plan.js +1 -1
  241. package/lib/commands/menu/shared/facts.d.ts +12 -0
  242. package/lib/commands/menu/shared/facts.js +1 -1
  243. package/lib/commands/menu/shared/index.d.ts +12 -0
  244. package/lib/commands/menu/shared/index.js +1 -1
  245. package/lib/commands/menu/shared/inquirer.d.ts +10 -0
  246. package/lib/commands/menu/shared/inquirer.js +1 -1
  247. package/lib/commands/menu/shared/local-pages.d.ts +12 -0
  248. package/lib/commands/menu/shared/local-pages.js +1 -1
  249. package/lib/commands/menu/shared/logic.d.ts +28 -0
  250. package/lib/commands/menu/shared/logic.js +1 -1
  251. package/lib/commands/menu/shared/mutations.d.ts +69 -0
  252. package/lib/commands/menu/shared/mutations.js +1 -1
  253. package/lib/commands/menu/shared/service.d.ts +17 -0
  254. package/lib/commands/menu/shared/service.js +1 -1
  255. package/lib/commands/menu/shared/sync-core.d.ts +7 -0
  256. package/lib/commands/menu/shared/sync-core.js +1 -1
  257. package/lib/commands/menu/shared/types.d.ts +162 -0
  258. package/lib/commands/menu/shared/update-core.d.ts +11 -0
  259. package/lib/commands/menu/shared/update-core.js +1 -1
  260. package/lib/commands/menu/shared/valid-url.d.ts +6 -0
  261. package/lib/commands/menu/shared/valid-url.js +1 -1
  262. package/lib/commands/menu/sync.d.ts +2 -0
  263. package/lib/commands/menu/sync.js +1 -1
  264. package/lib/commands/notification/config-list.d.ts +2 -0
  265. package/lib/commands/notification/config-list.js +1 -1
  266. package/lib/commands/notification/index.d.ts +2 -0
  267. package/lib/commands/notification/index.js +1 -1
  268. package/lib/commands/ocr/index.d.ts +2 -0
  269. package/lib/commands/ocr/index.js +1 -1
  270. package/lib/commands/page/generate-start.d.ts +2 -0
  271. package/lib/commands/page/generate-start.js +1 -1
  272. package/lib/commands/page/generate-status.d.ts +2 -0
  273. package/lib/commands/page/generate-status.js +1 -1
  274. package/lib/commands/page/index.d.ts +2 -0
  275. package/lib/commands/page/index.js +1 -1
  276. package/lib/commands/page/pull.d.ts +2 -0
  277. package/lib/commands/page/pull.js +1 -1
  278. package/lib/commands/page/push.d.ts +2 -0
  279. package/lib/commands/page/push.js +1 -1
  280. package/lib/commands/page/relation-audit.d.ts +2 -0
  281. package/lib/commands/page/relation-audit.js +1 -1
  282. package/lib/commands/page/restore.d.ts +2 -0
  283. package/lib/commands/page/restore.js +1 -1
  284. package/lib/commands/page/shared.d.ts +105 -0
  285. package/lib/commands/page/shared.js +1 -1
  286. package/lib/commands/page/standard-page-status.d.ts +2 -0
  287. package/lib/commands/page/standard-page-status.js +1 -1
  288. package/lib/commands/page/sync.d.ts +2 -0
  289. package/lib/commands/page/sync.js +1 -1
  290. package/lib/commands/permit/index.d.ts +2 -0
  291. package/lib/commands/permit/index.js +1 -1
  292. package/lib/commands/permit/page-get.d.ts +2 -0
  293. package/lib/commands/permit/page-get.js +1 -1
  294. package/lib/commands/permit/page-set.d.ts +2 -0
  295. package/lib/commands/permit/page-set.js +1 -1
  296. package/lib/commands/permit/role-apis-set.d.ts +2 -0
  297. package/lib/commands/permit/role-apis-set.js +1 -1
  298. package/lib/commands/permit/role-menus-set.d.ts +2 -0
  299. package/lib/commands/permit/role-menus-set.js +1 -1
  300. package/lib/commands/permit/role-menus.d.ts +2 -0
  301. package/lib/commands/permit/role-menus.js +1 -1
  302. package/lib/commands/permit/shared.d.ts +74 -0
  303. package/lib/commands/permit/shared.js +1 -1
  304. package/lib/commands/project/create/enhanced-guided-create.d.ts +7 -0
  305. package/lib/commands/project/create/enhanced-guided-create.js +1 -1
  306. package/lib/commands/project/create/format-elapsed.d.ts +1 -0
  307. package/lib/commands/project/create/format-elapsed.js +1 -1
  308. package/lib/commands/project/create/main.d.ts +6 -0
  309. package/lib/commands/project/create/main.js +1 -1
  310. package/lib/commands/project/create/non-interactive.d.ts +9 -0
  311. package/lib/commands/project/create/non-interactive.js +1 -1
  312. package/lib/commands/project/create/project-template-path.d.ts +4 -0
  313. package/lib/commands/project/create/project-template-path.js +1 -1
  314. package/lib/commands/project/create/use-copy-project-template.d.ts +1 -0
  315. package/lib/commands/project/create/use-copy-project-template.js +1 -1
  316. package/lib/commands/project/create/use-format-code.d.ts +1 -0
  317. package/lib/commands/project/create/use-format-code.js +1 -1
  318. package/lib/commands/project/create/use-install-dependencies.d.ts +1 -0
  319. package/lib/commands/project/create/use-install-dependencies.js +1 -1
  320. package/lib/commands/project/index.d.ts +2 -0
  321. package/lib/commands/project/index.js +1 -1
  322. package/lib/commands/project/upgrade.d.ts +1 -0
  323. package/lib/commands/project/upgrade.js +1 -1
  324. package/lib/commands/registry.d.ts +66 -0
  325. package/lib/commands/registry.js +1 -1
  326. package/lib/commands/role/create.d.ts +2 -0
  327. package/lib/commands/role/create.js +1 -1
  328. package/lib/commands/role/delete.d.ts +2 -0
  329. package/lib/commands/role/delete.js +1 -1
  330. package/lib/commands/role/detail.d.ts +2 -0
  331. package/lib/commands/role/detail.js +1 -1
  332. package/lib/commands/role/index.d.ts +2 -0
  333. package/lib/commands/role/index.js +1 -1
  334. package/lib/commands/role/list.d.ts +2 -0
  335. package/lib/commands/role/list.js +1 -1
  336. package/lib/commands/role/shared.d.ts +107 -0
  337. package/lib/commands/role/shared.js +1 -1
  338. package/lib/commands/role/update.d.ts +2 -0
  339. package/lib/commands/role/update.js +1 -1
  340. package/lib/commands/role/user-add.d.ts +2 -0
  341. package/lib/commands/role/user-add.js +1 -1
  342. package/lib/commands/role/user-remove.d.ts +2 -0
  343. package/lib/commands/role/user-remove.js +1 -1
  344. package/lib/commands/role/user-resolve.d.ts +2 -0
  345. package/lib/commands/role/user-resolve.js +1 -1
  346. package/lib/commands/run/index.d.ts +2 -0
  347. package/lib/commands/run/index.js +1 -1
  348. package/lib/commands/schema.d.ts +5 -0
  349. package/lib/commands/schema.js +1 -1
  350. package/lib/commands/sql/create.d.ts +10 -0
  351. package/lib/commands/sql/create.js +1 -1
  352. package/lib/commands/sql/delete.d.ts +5 -0
  353. package/lib/commands/sql/delete.js +1 -1
  354. package/lib/commands/sql/detail.d.ts +2 -0
  355. package/lib/commands/sql/detail.js +1 -1
  356. package/lib/commands/sql/exec.d.ts +2 -0
  357. package/lib/commands/sql/exec.js +1 -1
  358. package/lib/commands/sql/index.d.ts +5 -0
  359. package/lib/commands/sql/index.js +1 -1
  360. package/lib/commands/sql/list.d.ts +2 -0
  361. package/lib/commands/sql/list.js +1 -1
  362. package/lib/commands/sql/pull.d.ts +5 -0
  363. package/lib/commands/sql/pull.js +1 -1
  364. package/lib/commands/sql/push.d.ts +5 -0
  365. package/lib/commands/sql/push.js +1 -1
  366. package/lib/commands/sql/shared.d.ts +23 -0
  367. package/lib/commands/sql/shared.js +1 -1
  368. package/lib/commands/sql/status.d.ts +5 -0
  369. package/lib/commands/sql/status.js +1 -1
  370. package/lib/commands/sql/validate.d.ts +2 -0
  371. package/lib/commands/sql/validate.js +1 -1
  372. package/lib/commands/task/index.d.ts +2 -0
  373. package/lib/commands/task/index.js +1 -1
  374. package/lib/commands/task/status.d.ts +2 -0
  375. package/lib/commands/task/status.js +1 -1
  376. package/lib/commands/tenant/index.d.ts +2 -0
  377. package/lib/commands/tenant/index.js +1 -1
  378. package/lib/commands/tenant/members-list.d.ts +2 -0
  379. package/lib/commands/tenant/members-list.js +1 -1
  380. package/lib/commands/tenant/shared.d.ts +10 -0
  381. package/lib/commands/tenant/shared.js +1 -1
  382. package/lib/commands/workspace/add.d.ts +6 -0
  383. package/lib/commands/workspace/add.js +1 -1
  384. package/lib/commands/workspace/index.d.ts +11 -0
  385. package/lib/commands/workspace/index.js +1 -1
  386. package/lib/commands/workspace/remove.d.ts +6 -0
  387. package/lib/commands/workspace/remove.js +1 -1
  388. package/lib/config/schema.d.ts +50 -0
  389. package/lib/config/schema.js +1 -1
  390. package/lib/constant/cdn.d.ts +1 -0
  391. package/lib/constant/cdn.js +1 -1
  392. package/lib/constant/cli.d.ts +34 -0
  393. package/lib/constant/cli.js +1 -1
  394. package/lib/constant/defaults.d.ts +10 -0
  395. package/lib/constant/defaults.js +1 -1
  396. package/lib/constant/domain.d.ts +14 -0
  397. package/lib/constant/domain.js +1 -1
  398. package/lib/constant/env.d.ts +11 -0
  399. package/lib/constant/env.js +1 -1
  400. package/lib/constant/output.d.ts +1 -0
  401. package/lib/constant/output.js +1 -1
  402. package/lib/constant/paths.d.ts +5 -0
  403. package/lib/constant/paths.js +1 -1
  404. package/lib/constant/risk.d.ts +1 -0
  405. package/lib/constant/risk.js +1 -1
  406. package/lib/context/app-resolver.d.ts +36 -0
  407. package/lib/context/app-resolver.js +1 -1
  408. package/lib/context/auth-resolver.d.ts +5 -0
  409. package/lib/context/auth-resolver.js +1 -1
  410. package/lib/context/config-loader.d.ts +61 -0
  411. package/lib/context/config-loader.js +1 -1
  412. package/lib/context.d.ts +102 -0
  413. package/lib/context.js +1 -1
  414. package/lib/core/alias-resolver.d.ts +31 -0
  415. package/lib/core/alias-resolver.js +1 -1
  416. package/lib/core/api-client.d.ts +1018 -0
  417. package/lib/core/api-client.js +1 -1
  418. package/lib/core/bff/config.d.ts +8 -0
  419. package/lib/core/bff/config.js +1 -1
  420. package/lib/core/bff/file-system.d.ts +28 -0
  421. package/lib/core/bff/file-system.js +1 -1
  422. package/lib/core/bff/hash.d.ts +7 -0
  423. package/lib/core/bff/hash.js +1 -1
  424. package/lib/core/bff/lock.d.ts +25 -0
  425. package/lib/core/bff/lock.js +1 -1
  426. package/lib/core/bff/types.d.ts +92 -0
  427. package/lib/core/bff/utils.d.ts +25 -0
  428. package/lib/core/bff/utils.js +1 -1
  429. package/lib/core/db-resolver.d.ts +43 -0
  430. package/lib/core/db-resolver.js +1 -1
  431. package/lib/core/page/file-system.d.ts +6 -0
  432. package/lib/core/page/file-system.js +1 -1
  433. package/lib/core/page/hash.d.ts +4 -0
  434. package/lib/core/page/hash.js +1 -1
  435. package/lib/core/page/lock.d.ts +8 -0
  436. package/lib/core/page/lock.js +1 -1
  437. package/lib/core/page/types.d.ts +22 -0
  438. package/lib/core/sql-index-auditor.d.ts +33 -0
  439. package/lib/core/sql-index-auditor.js +1 -1
  440. package/lib/core/sql-sync/config.d.ts +7 -0
  441. package/lib/core/sql-sync/config.js +1 -1
  442. package/lib/core/sql-sync/file-system.d.ts +7 -0
  443. package/lib/core/sql-sync/file-system.js +1 -1
  444. package/lib/core/sql-sync/hash.d.ts +5 -0
  445. package/lib/core/sql-sync/hash.js +1 -1
  446. package/lib/core/sql-sync/lock.d.ts +14 -0
  447. package/lib/core/sql-sync/lock.js +1 -1
  448. package/lib/core/sql-sync/types.d.ts +43 -0
  449. package/lib/core/sql-sync/utils.d.ts +10 -0
  450. package/lib/core/sql-sync/utils.js +1 -1
  451. package/lib/core/sql-validator.d.ts +34 -0
  452. package/lib/core/sql-validator.js +1 -1
  453. package/lib/errors.d.ts +3 -0
  454. package/lib/errors.js +1 -1
  455. package/lib/framework/build-all-flags.d.ts +2 -0
  456. package/lib/framework/build-all-flags.js +1 -1
  457. package/lib/framework/error-output.d.ts +9 -0
  458. package/lib/framework/error-output.js +1 -1
  459. package/lib/framework/explicit-yes.d.ts +3 -0
  460. package/lib/framework/explicit-yes.js +1 -1
  461. package/lib/framework/flags.d.ts +3 -0
  462. package/lib/framework/flags.js +1 -1
  463. package/lib/framework/help.d.ts +4 -0
  464. package/lib/framework/help.js +1 -1
  465. package/lib/framework/index.d.ts +11 -0
  466. package/lib/framework/index.js +1 -1
  467. package/lib/framework/output.d.ts +15 -0
  468. package/lib/framework/output.js +1 -1
  469. package/lib/framework/response.d.ts +2 -0
  470. package/lib/framework/response.js +1 -1
  471. package/lib/framework/runner-alias.d.ts +14 -0
  472. package/lib/framework/runner-alias.js +1 -1
  473. package/lib/framework/runner.d.ts +36 -0
  474. package/lib/framework/runner.js +1 -1
  475. package/lib/framework/schema-export.d.ts +3 -0
  476. package/lib/framework/schema-export.js +1 -1
  477. package/lib/framework/types.d.ts +63 -0
  478. package/lib/framework/types.js +1 -1
  479. package/lib/generated/build-info.d.ts +4 -0
  480. package/lib/generated/build-info.js +1 -1
  481. package/lib/help.d.ts +1 -0
  482. package/lib/help.js +1 -1
  483. package/lib/runtime/confirmation.d.ts +4 -0
  484. package/lib/runtime/confirmation.js +1 -0
  485. package/lib/runtime/event.d.ts +5 -0
  486. package/lib/runtime/event.js +1 -0
  487. package/lib/runtime/index.d.ts +7 -0
  488. package/lib/runtime/index.js +1 -0
  489. package/lib/runtime/queue.d.ts +5 -0
  490. package/lib/runtime/queue.js +1 -0
  491. package/lib/runtime/resolve.d.ts +8 -0
  492. package/lib/runtime/resolve.js +1 -0
  493. package/lib/runtime/types.d.ts +50 -0
  494. package/lib/runtime/types.js +1 -0
  495. package/lib/skills/main.d.ts +41 -0
  496. package/lib/skills/main.js +1 -1
  497. package/lib/skills/npx-skills-add.d.ts +99 -0
  498. package/lib/skills/npx-skills-add.js +1 -1
  499. package/lib/skills/skill-presence.d.ts +44 -0
  500. package/lib/skills/skill-presence.js +1 -1
  501. package/lib/telemetry/cli-command-trace.d.ts +12 -0
  502. package/lib/telemetry/cli-command-trace.js +1 -1
  503. package/lib/telemetry/cli-help-trace.d.ts +8 -0
  504. package/lib/telemetry/cli-help-trace.js +1 -1
  505. package/lib/telemetry/ensure-cli-otel-config.d.ts +6 -0
  506. package/lib/telemetry/ensure-cli-otel-config.js +1 -1
  507. package/lib/telemetry/register-otel-exit-shutdown.d.ts +3 -0
  508. package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
  509. package/lib/telemetry/send-cli-trace-log.d.ts +17 -0
  510. package/lib/telemetry/send-cli-trace-log.js +1 -1
  511. package/lib/telemetry/send-platform-issue-collect-log.d.ts +26 -0
  512. package/lib/telemetry/send-platform-issue-collect-log.js +1 -1
  513. package/lib/types/index.d.ts +93 -0
  514. package/lib/utils/ai_config.d.ts +47 -0
  515. package/lib/utils/ai_config.js +1 -1
  516. package/lib/utils/apply-jq-filter.d.ts +1 -0
  517. package/lib/utils/apply-jq-filter.js +1 -1
  518. package/lib/utils/cdn-config.d.ts +42 -0
  519. package/lib/utils/cdn-config.js +1 -1
  520. package/lib/utils/check-sdk-version.d.ts +23 -0
  521. package/lib/utils/check-sdk-version.js +1 -1
  522. package/lib/utils/cli-version-check.d.ts +37 -0
  523. package/lib/utils/cli-version-check.js +1 -1
  524. package/lib/utils/cli-version-policy.d.ts +9 -0
  525. package/lib/utils/cli-version-policy.js +1 -1
  526. package/lib/utils/config.d.ts +42 -0
  527. package/lib/utils/config.js +1 -1
  528. package/lib/utils/copy-directory.d.ts +1 -0
  529. package/lib/utils/copy-directory.js +1 -1
  530. package/lib/utils/entity-with-id.d.ts +30 -0
  531. package/lib/utils/entity-with-id.js +1 -1
  532. package/lib/utils/file-utils.d.ts +25 -0
  533. package/lib/utils/file-utils.js +1 -1
  534. package/lib/utils/guides-cdn.d.ts +80 -0
  535. package/lib/utils/guides-cdn.js +1 -1
  536. package/lib/utils/http-client.d.ts +30 -0
  537. package/lib/utils/http-client.js +1 -1
  538. package/lib/utils/is-non-interactive.d.ts +7 -0
  539. package/lib/utils/is-non-interactive.js +1 -1
  540. package/lib/utils/logger.d.ts +62 -0
  541. package/lib/utils/logger.js +1 -1
  542. package/lib/utils/params.d.ts +15 -0
  543. package/lib/utils/params.js +1 -1
  544. package/lib/utils/platform.d.ts +21 -0
  545. package/lib/utils/platform.js +1 -1
  546. package/lib/utils/rules-cdn.d.ts +38 -0
  547. package/lib/utils/rules-cdn.js +1 -1
  548. package/lib/utils/sleep.d.ts +1 -0
  549. package/lib/utils/sleep.js +1 -1
  550. package/lib/utils/template-replacer.d.ts +55 -0
  551. package/lib/utils/template-replacer.js +1 -1
  552. package/lib/utils/update-notice.d.ts +10 -0
  553. package/lib/utils/update-notice.js +1 -1
  554. package/lib/utils/version.d.ts +1 -0
  555. package/lib/utils/version.js +1 -1
  556. package/lib/utils/with-active-cookie.d.ts +1 -0
  557. package/lib/utils/with-active-cookie.js +1 -1
  558. package/lib/utils/write-cli-side-channel.d.ts +6 -0
  559. package/lib/utils/write-cli-side-channel.js +1 -1
  560. package/package.json +9 -1
@@ -1 +1 @@
1
- const a184_0x5a74a9=a184_0xc68c;(function(_0x1044f4,_0x43a99a){const _0xcb1d2b=a184_0xc68c,_0x25a718=_0x1044f4();while(!![]){try{const _0xa5f2d7=-parseInt(_0xcb1d2b(0xef))/0x1*(parseInt(_0xcb1d2b(0xf0))/0x2)+-parseInt(_0xcb1d2b(0xf4))/0x3+parseInt(_0xcb1d2b(0xd9))/0x4+-parseInt(_0xcb1d2b(0xd5))/0x5+parseInt(_0xcb1d2b(0xea))/0x6+-parseInt(_0xcb1d2b(0xe1))/0x7*(-parseInt(_0xcb1d2b(0xdc))/0x8)+parseInt(_0xcb1d2b(0xde))/0x9;if(_0xa5f2d7===_0x43a99a)break;else _0x25a718['push'](_0x25a718['shift']());}catch(_0x45511e){_0x25a718['push'](_0x25a718['shift']());}}}(a184_0x4741,0x479c1));function a184_0xc68c(_0x2f749a,_0x560a44){_0x2f749a=_0x2f749a-0xd2;const _0x4741c3=a184_0x4741();let _0xc68c69=_0x4741c3[_0x2f749a];return _0xc68c69;}import{listSqlQueries}from'../../core/api-client.js';import{loadSqlProjectConfig}from'../../core/sql-sync/config.js';import{scanLocalSqlQueries}from'../../core/sql-sync/file-system.js';import{computeSqlFileHash}from'../../core/sql-sync/hash.js';import{createEmptySqlLock,ensureSqlLockScope,readSqlLockFile}from'../../core/sql-sync/lock.js';const PAGE_SIZE=0x64;function a184_0x4741(){const _0x4594fc=['788894YqmqdY','tableData','lockKey','map','1332747gWrBDb','sqls','has','sqlRoot','1851295OrFByT','boolean','push','remote','349992gOujDz','totalCount','\x20remote-only','96ZcIkOC','All\x20SQL\x20queries\x20are\x20in\x20sync.','10806777pSwGao','read','bool','84049aJDnwZ','sql','appCode','sqlName','Also\x20check\x20for\x20remote-only\x20SQL\x20queries\x20not\x20present\x20locally','relativePath','lockFilePath','sqlCode','filePath','419598wQRjHg','status','\x20unchanged','length','\x20modified,\x20','1hrtKoP'];a184_0x4741=function(){return _0x4594fc;};return a184_0x4741();}async function fetchAllSqlCodes(_0x51456a){const _0x200dbf=a184_0xc68c,_0xaec1c2=[];let _0x369316=0x1;while(!![]){const _0x54b0eb=await listSqlQueries(_0x51456a,{'currentPage':_0x369316,'pageSize':PAGE_SIZE}),_0x3f22f7=_0x54b0eb[_0x200dbf(0xf1)]??[];_0xaec1c2['push'](..._0x3f22f7[_0x200dbf(0xf3)](_0x3f586b=>_0x3f586b[_0x200dbf(0xe8)]));if(_0x3f22f7['length']===0x0)break;const _0x114a98=_0x54b0eb['paging']?.[_0x200dbf(0xda)];if(_0x114a98!=null?_0xaec1c2['length']>=_0x114a98:_0x3f22f7[_0x200dbf(0xed)]<PAGE_SIZE)break;_0x369316++;}return _0xaec1c2;}export const sqlStatus={'service':a184_0x5a74a9(0xe2),'command':a184_0x5a74a9(0xeb),'description':'Check\x20local\x20SQL\x20sync\x20status\x20against\x20lock\x20file','risk':a184_0x5a74a9(0xdf),'flags':[{'name':'remote','type':a184_0x5a74a9(0xd6),'description':a184_0x5a74a9(0xe5)}],async 'execute'(_0x31e335){const _0x28f3e4=a184_0x5a74a9,_0x382504=loadSqlProjectConfig(_0x31e335[_0x28f3e4(0xe3)]),_0x341cbe=await readSqlLockFile(_0x382504[_0x28f3e4(0xe7)]),{appLock:_0x422519}=ensureSqlLockScope(_0x341cbe??createEmptySqlLock(),_0x382504['appCode'],_0x382504[_0x28f3e4(0xd4)],_0x28f3e4(0xeb)),_0x3b86d5=await scanLocalSqlQueries(_0x382504),_0x56c001=[],_0x32579c=[],_0x471a2a=[],_0x60d570=[],_0x445bf8=new Set(_0x3b86d5[_0x28f3e4(0xf3)](_0x595a42=>_0x595a42[_0x28f3e4(0xf2)]));for(const _0x2339b6 of _0x3b86d5){const _0x126d3=await computeSqlFileHash(_0x2339b6[_0x28f3e4(0xe9)]),_0x15640a=_0x422519[_0x28f3e4(0xd2)][_0x2339b6[_0x28f3e4(0xf2)]],_0x55af6b=!!_0x15640a&&_0x15640a['path']!==_0x2339b6[_0x28f3e4(0xe6)],_0x3f44f8=!!_0x15640a&&!!_0x2339b6['sqlName']&&_0x15640a[_0x28f3e4(0xe4)]!==_0x2339b6['sqlName'];if(!_0x15640a)_0x56c001['push'](_0x2339b6['lockKey']);else _0x15640a['hash']!==_0x126d3||_0x55af6b||_0x3f44f8?_0x32579c[_0x28f3e4(0xd7)](_0x2339b6[_0x28f3e4(0xf2)]):_0x471a2a[_0x28f3e4(0xd7)](_0x2339b6['lockKey']);}for(const _0x4a675c of Object['keys'](_0x422519[_0x28f3e4(0xd2)])){!_0x445bf8[_0x28f3e4(0xd3)](_0x4a675c)&&_0x60d570[_0x28f3e4(0xd7)](_0x4a675c);}const _0x1f35bf=[];if(_0x31e335[_0x28f3e4(0xe0)](_0x28f3e4(0xd8))){const _0x16aa9d=await fetchAllSqlCodes(_0x31e335[_0x28f3e4(0xe3)]);for(const _0x3da6f2 of _0x16aa9d){!_0x445bf8['has'](_0x3da6f2)&&!_0x422519[_0x28f3e4(0xd2)][_0x3da6f2]&&_0x1f35bf[_0x28f3e4(0xd7)](_0x3da6f2);}}const _0x5a0d0b=_0x56c001[_0x28f3e4(0xed)]===0x0&&_0x32579c[_0x28f3e4(0xed)]===0x0&&_0x60d570['length']===0x0&&_0x1f35bf[_0x28f3e4(0xed)]===0x0;return{'ok':!![],'data':{'added':_0x56c001,'modified':_0x32579c,'missing':_0x60d570,'unchanged':_0x471a2a,'remoteOnly':_0x1f35bf},'message':_0x5a0d0b?_0x28f3e4(0xdd):_0x56c001[_0x28f3e4(0xed)]+'\x20added,\x20'+_0x32579c[_0x28f3e4(0xed)]+_0x28f3e4(0xee)+_0x60d570[_0x28f3e4(0xed)]+'\x20missing,\x20'+_0x471a2a['length']+_0x28f3e4(0xec)+(_0x1f35bf[_0x28f3e4(0xed)]>0x0?',\x20'+_0x1f35bf[_0x28f3e4(0xed)]+_0x28f3e4(0xdb):'')};}};
1
+ const a184_0x16428a=a184_0x4ab5;(function(_0x245072,_0x37a913){const _0x3ecab9=a184_0x4ab5,_0x45c2c3=_0x245072();while(!![]){try{const _0x43990a=parseInt(_0x3ecab9(0xd6))/0x1+parseInt(_0x3ecab9(0xdf))/0x2+-parseInt(_0x3ecab9(0xd4))/0x3*(parseInt(_0x3ecab9(0xf3))/0x4)+parseInt(_0x3ecab9(0xf2))/0x5*(-parseInt(_0x3ecab9(0xf0))/0x6)+-parseInt(_0x3ecab9(0xd8))/0x7+parseInt(_0x3ecab9(0xe0))/0x8+parseInt(_0x3ecab9(0xd7))/0x9;if(_0x43990a===_0x37a913)break;else _0x45c2c3['push'](_0x45c2c3['shift']());}catch(_0x17ffcc){_0x45c2c3['push'](_0x45c2c3['shift']());}}}(a184_0x2bb2,0x51b70));import{listSqlQueries}from'../../core/api-client.js';import{loadSqlProjectConfig}from'../../core/sql-sync/config.js';import{scanLocalSqlQueries}from'../../core/sql-sync/file-system.js';import{computeSqlFileHash}from'../../core/sql-sync/hash.js';import{createEmptySqlLock,ensureSqlLockScope,readSqlLockFile}from'../../core/sql-sync/lock.js';function a184_0x4ab5(_0x5c19be,_0x6e57cc){_0x5c19be=_0x5c19be-0xce;const _0x2bb26c=a184_0x2bb2();let _0x4ab59a=_0x2bb26c[_0x5c19be];return _0x4ab59a;}const PAGE_SIZE=0x64;function a184_0x2bb2(){const _0x451d96=['length','filePath','lockKey','push','boolean','status','479444mdmdjm','3622376YsmkKZ','bool','keys','paging','\x20missing,\x20','sqls','read','sqlRoot','appCode','\x20remote-only','totalCount','remote','lockFilePath','has','map','relativePath','2952ziziro','All\x20SQL\x20queries\x20are\x20in\x20sync.','4390aQTvyx','8sUtVko','Also\x20check\x20for\x20remote-only\x20SQL\x20queries\x20not\x20present\x20locally','path','sqlName','hash','\x20unchanged','Check\x20local\x20SQL\x20sync\x20status\x20against\x20lock\x20file','757461pOewDn','\x20added,\x20','345179jTdDfp','5873796nygFUA','2930816GAmnct'];a184_0x2bb2=function(){return _0x451d96;};return a184_0x2bb2();}async function fetchAllSqlCodes(_0x1d40f0){const _0x4eb6d5=a184_0x4ab5,_0x593217=[];let _0x343c70=0x1;while(!![]){const _0x57a7e3=await listSqlQueries(_0x1d40f0,{'currentPage':_0x343c70,'pageSize':PAGE_SIZE}),_0x16fde7=_0x57a7e3['tableData']??[];_0x593217['push'](..._0x16fde7[_0x4eb6d5(0xee)](_0x3b72e0=>_0x3b72e0['sqlCode']));if(_0x16fde7['length']===0x0)break;const _0x4cd4e1=_0x57a7e3[_0x4eb6d5(0xe3)]?.[_0x4eb6d5(0xea)];if(_0x4cd4e1!=null?_0x593217[_0x4eb6d5(0xd9)]>=_0x4cd4e1:_0x16fde7['length']<PAGE_SIZE)break;_0x343c70++;}return _0x593217;}export const sqlStatus={'service':'sql','command':a184_0x16428a(0xde),'description':a184_0x16428a(0xd3),'risk':a184_0x16428a(0xe6),'flags':[{'name':a184_0x16428a(0xeb),'type':a184_0x16428a(0xdd),'description':a184_0x16428a(0xce)}],async 'execute'(_0x6b5081){const _0x290b98=a184_0x16428a,_0x1a1121=loadSqlProjectConfig(_0x6b5081[_0x290b98(0xe8)]),_0x31ce5a=await readSqlLockFile(_0x1a1121[_0x290b98(0xec)]),{appLock:_0x12ba9d}=ensureSqlLockScope(_0x31ce5a??createEmptySqlLock(),_0x1a1121[_0x290b98(0xe8)],_0x1a1121[_0x290b98(0xe7)],_0x290b98(0xde)),_0x56c9c3=await scanLocalSqlQueries(_0x1a1121),_0x5b8a0a=[],_0xad5876=[],_0x4e21bf=[],_0x2ac543=[],_0x4620bb=new Set(_0x56c9c3[_0x290b98(0xee)](_0x3f5707=>_0x3f5707[_0x290b98(0xdb)]));for(const _0x88aa5e of _0x56c9c3){const _0x20914f=await computeSqlFileHash(_0x88aa5e[_0x290b98(0xda)]),_0x4a4d5b=_0x12ba9d[_0x290b98(0xe5)][_0x88aa5e['lockKey']],_0x4a7f4e=!!_0x4a4d5b&&_0x4a4d5b[_0x290b98(0xcf)]!==_0x88aa5e[_0x290b98(0xef)],_0x23c12c=!!_0x4a4d5b&&!!_0x88aa5e['sqlName']&&_0x4a4d5b[_0x290b98(0xd0)]!==_0x88aa5e['sqlName'];if(!_0x4a4d5b)_0x5b8a0a[_0x290b98(0xdc)](_0x88aa5e[_0x290b98(0xdb)]);else _0x4a4d5b[_0x290b98(0xd1)]!==_0x20914f||_0x4a7f4e||_0x23c12c?_0xad5876['push'](_0x88aa5e[_0x290b98(0xdb)]):_0x4e21bf[_0x290b98(0xdc)](_0x88aa5e[_0x290b98(0xdb)]);}for(const _0x5329bc of Object[_0x290b98(0xe2)](_0x12ba9d['sqls'])){!_0x4620bb[_0x290b98(0xed)](_0x5329bc)&&_0x2ac543[_0x290b98(0xdc)](_0x5329bc);}const _0x4b100e=[];if(_0x6b5081[_0x290b98(0xe1)]('remote')){const _0x5fefde=await fetchAllSqlCodes(_0x6b5081['appCode']);for(const _0x2eafeb of _0x5fefde){!_0x4620bb[_0x290b98(0xed)](_0x2eafeb)&&!_0x12ba9d[_0x290b98(0xe5)][_0x2eafeb]&&_0x4b100e[_0x290b98(0xdc)](_0x2eafeb);}}const _0xbf1e76=_0x5b8a0a[_0x290b98(0xd9)]===0x0&&_0xad5876[_0x290b98(0xd9)]===0x0&&_0x2ac543[_0x290b98(0xd9)]===0x0&&_0x4b100e['length']===0x0;return{'ok':!![],'data':{'added':_0x5b8a0a,'modified':_0xad5876,'missing':_0x2ac543,'unchanged':_0x4e21bf,'remoteOnly':_0x4b100e},'message':_0xbf1e76?_0x290b98(0xf1):_0x5b8a0a[_0x290b98(0xd9)]+_0x290b98(0xd5)+_0xad5876[_0x290b98(0xd9)]+'\x20modified,\x20'+_0x2ac543[_0x290b98(0xd9)]+_0x290b98(0xe4)+_0x4e21bf[_0x290b98(0xd9)]+_0x290b98(0xd2)+(_0x4b100e[_0x290b98(0xd9)]>0x0?',\x20'+_0x4b100e['length']+_0x290b98(0xe9):'')};}};
@@ -0,0 +1,2 @@
1
+ import type { CommandDefinition } from "../../framework/types.js";
2
+ export declare const sqlValidate: CommandDefinition;
@@ -1 +1 @@
1
- const a185_0xbd40a4=a185_0x4bfd;function a185_0x4bfd(_0xf41c1f,_0x580157){_0xf41c1f=_0xf41c1f-0x132;const _0x450414=a185_0x4504();let _0x4bfdd5=_0x450414[_0xf41c1f];return _0x4bfdd5;}(function(_0x2187dd,_0x14dfb5){const _0x5d0104=a185_0x4bfd,_0x49937e=_0x2187dd();while(!![]){try{const _0x1f9beb=parseInt(_0x5d0104(0x139))/0x1*(-parseInt(_0x5d0104(0x15a))/0x2)+parseInt(_0x5d0104(0x15c))/0x3+parseInt(_0x5d0104(0x162))/0x4*(parseInt(_0x5d0104(0x13f))/0x5)+parseInt(_0x5d0104(0x171))/0x6+parseInt(_0x5d0104(0x161))/0x7+-parseInt(_0x5d0104(0x156))/0x8+parseInt(_0x5d0104(0x167))/0x9;if(_0x1f9beb===_0x14dfb5)break;else _0x49937e['push'](_0x49937e['shift']());}catch(_0x2d2aa7){_0x49937e['push'](_0x49937e['shift']());}}}(a185_0x4504,0xd190e));import{readFileSync,existsSync}from'node:fs';import{resolve}from'node:path';import{validateSql}from'../../core/sql-validator.js';import{auditSqlJoinIndexes}from'../../core/sql-index-auditor.js';import{getDatasetDetail,listDatasets}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{assertDatasetIsDbTableBacked,filterDbTableBackedDatasets}from'../../commands/dataset/capability.js';export const sqlValidate={'service':a185_0xbd40a4(0x166),'command':a185_0xbd40a4(0x137),'description':a185_0xbd40a4(0x140),'risk':a185_0xbd40a4(0x153),'flags':[{'name':a185_0xbd40a4(0x13c),'type':a185_0xbd40a4(0x173),'description':a185_0xbd40a4(0x14e)},{'name':'sql','type':a185_0xbd40a4(0x173),'description':'Inline\x20SQL\x20content\x20to\x20validate\x20(alternative\x20to\x20--file)'},{'name':a185_0xbd40a4(0x15b),'type':a185_0xbd40a4(0x173),'description':a185_0xbd40a4(0x142)},{'name':'check-indexes','type':a185_0xbd40a4(0x154),'description':'Audit\x20top-level\x20JOIN\x20equality\x20predicates\x20against\x20dataset\x20index\x20metadata'}],async 'execute'(_0x5c0bbf){const _0xed17a=a185_0xbd40a4,_0xff6388=_0x5c0bbf[_0xed17a(0x150)](_0xed17a(0x13c)),_0x2b8042=_0x5c0bbf[_0xed17a(0x150)](_0xed17a(0x166)),_0x18cf5c=_0x5c0bbf[_0xed17a(0x150)]('schemas'),_0x41b2d7=_0x5c0bbf[_0xed17a(0x16e)](_0xed17a(0x165));if(!_0xff6388&&!_0x2b8042)throw CliErrors[_0xed17a(0x141)](_0xed17a(0x13c),'Provide\x20--file\x20or\x20--sql');if(_0x41b2d7&&!_0x18cf5c)throw CliErrors[_0xed17a(0x16c)](_0xed17a(0x14f));let _0x4e0689;if(_0xff6388){const _0x39d2aa=resolve(process[_0xed17a(0x159)](),_0xff6388);if(!existsSync(_0x39d2aa))throw CliErrors[_0xed17a(0x16c)](_0xed17a(0x144)+_0x39d2aa);_0x4e0689=readFileSync(_0x39d2aa,'utf-8');}else _0x4e0689=_0x2b8042;const _0x2c4fb8=validateSql(_0x4e0689),_0x26bacc={'valid':_0x2c4fb8[_0xed17a(0x175)],'sqlType':_0x2c4fb8[_0xed17a(0x164)][_0xed17a(0x147)],'isSelectOnly':_0x2c4fb8[_0xed17a(0x164)][_0xed17a(0x14c)],'isDangerous':_0x2c4fb8['sqlType'][_0xed17a(0x145)],'tables':_0x2c4fb8[_0xed17a(0x132)],'parameters':_0x2c4fb8[_0xed17a(0x163)],'message':_0x2c4fb8[_0xed17a(0x146)]};_0x2c4fb8[_0xed17a(0x164)][_0xed17a(0x133)]&&(_0x26bacc[_0xed17a(0x133)]=_0x2c4fb8[_0xed17a(0x164)][_0xed17a(0x133)]);if(_0x18cf5c&&_0x2c4fb8[_0xed17a(0x175)]){const _0x419fe5=_0x18cf5c['split'](',')[_0xed17a(0x13a)](_0x21d722=>_0x21d722[_0xed17a(0x169)]())[_0xed17a(0x136)](Boolean),_0x540edb=[],_0x3836f4=[],_0x52bd41=filterDbTableBackedDatasets(await listDatasets(_0x5c0bbf[_0xed17a(0x134)])),_0x25a6d1=new Map(_0x52bd41[_0xed17a(0x13a)](_0x2333aa=>[_0x2333aa['dbtableConfig']?.['tableName']?.[_0xed17a(0x143)](),_0x2333aa]));for(const _0x2a8e69 of _0x2c4fb8['tables']){const _0x2f29de=_0x25a6d1[_0xed17a(0x158)](_0x2a8e69[_0xed17a(0x143)]());!_0x2f29de&&_0x540edb['push']('Table\x20\x22'+_0x2a8e69+'\x22\x20not\x20found\x20in\x20any\x20dataset');}for(const _0x4a7695 of _0x419fe5){let _0x1e5ce4;try{_0x1e5ce4=await getDatasetDetail(_0x4a7695);}catch{_0x540edb['push']('Dataset\x20\x22'+_0x4a7695+'\x22\x20not\x20found\x20or\x20not\x20accessible');continue;}assertDatasetIsDbTableBacked(_0x1e5ce4,_0xed17a(0x148));const _0x158cf7=Array[_0xed17a(0x16d)](_0x1e5ce4[_0xed17a(0x14a)])?_0x1e5ce4[_0xed17a(0x14a)]:[],_0x24ce44=new Set(_0x158cf7[_0xed17a(0x13a)](_0x1649db=>_0x1649db[_0xed17a(0x155)]?.[_0xed17a(0x143)]())),_0x544a72=_0x1e5ce4[_0xed17a(0x13e)]?.[_0xed17a(0x174)]||_0x1e5ce4[_0xed17a(0x174)]||_0x4a7695;_0x26bacc[_0xed17a(0x168)+_0x544a72]={'code':_0x4a7695,'tableName':_0x544a72,'fieldCount':_0x24ce44[_0xed17a(0x15e)],'fields':Array[_0xed17a(0x15d)](_0x24ce44)};if(_0x41b2d7){const _0x1fa160=normalizeDatasetIndexes(_0x1e5ce4);_0x3836f4[_0xed17a(0x135)]({'tableName':_0x544a72,..._0x1fa160});}}_0x540edb[_0xed17a(0x16a)]>0x0&&(_0x26bacc[_0xed17a(0x14d)]=_0x540edb),_0x41b2d7&&(_0x26bacc[_0xed17a(0x13d)]=auditSqlJoinIndexes(_0x4e0689,_0x3836f4));}return{'ok':_0x2c4fb8[_0xed17a(0x175)],'data':_0x26bacc,'message':_0x2c4fb8[_0xed17a(0x146)]};}};function a185_0x4504(){const _0x4d0297=['tableName','valid','tables','reason','appCode','push','filter','validate','index_type','7054QDhonG','map','split','file','joinAudit','dbtableConfig','5bCvXsZ','Validate\x20SQL\x20content\x20without\x20saving\x20(type\x20detection,\x20parameter\x20extraction,\x20optional\x20schema\x20check)','flagMissing','Comma-separated\x20dataset\x20codes\x20to\x20cross-check\x20table/column\x20names\x20against','toLowerCase','File\x20not\x20found:\x20','isDangerous','message','type','SQL\x20schema\x20validation','columnNames','fields','indexes','isSelectOnly','schemaWarnings','Path\x20to\x20the\x20SQL\x20file\x20to\x20validate','--check-indexes\x20requires\x20--schemas.','str','primary','dataset','read','boolean','name','9393280SkFdqr','pkField','get','cwd','382dZjDng','schemas','1268133csIRuC','from','size','columns','unshift','10492608VuzUkO','1916900lMjpwx','parameters','sqlType','check-indexes','sql','7687935OkXKIr','schema:','trim','length','indexName','validation','isArray','bool','find','flatMap','748566FfLXBN','index_columns','string'];a185_0x4504=function(){return _0x4d0297;};return a185_0x4504();}function normalizeDatasetIndexes(_0x2d84fe){const _0x12656f=a185_0xbd40a4,_0x57e356=Array[_0x12656f(0x16d)](_0x2d84fe?.[_0x12656f(0x152)]?.[_0x12656f(0x14b)])?_0x2d84fe[_0x12656f(0x152)]['indexes']:Array[_0x12656f(0x16d)](_0x2d84fe?.[_0x12656f(0x14b)])?_0x2d84fe['indexes']:[],_0x134eee=_0x57e356[_0x12656f(0x170)](_0x41a324=>{const _0x548dad=_0x12656f,_0x4c869a=Array['isArray'](_0x41a324?.['index_columns'])?_0x41a324[_0x548dad(0x172)]:Array['isArray'](_0x41a324?.[_0x548dad(0x149)])?_0x41a324[_0x548dad(0x149)]:Array[_0x548dad(0x16d)](_0x41a324?.[_0x548dad(0x15f)])?_0x41a324[_0x548dad(0x15f)]:[],_0x488d4c=_0x4c869a[_0x548dad(0x136)](_0x131d7f=>typeof _0x131d7f===_0x548dad(0x173))[_0x548dad(0x13a)](_0x16a485=>_0x16a485[_0x548dad(0x169)]())[_0x548dad(0x136)](Boolean);if(_0x488d4c['length']===0x0)return[];const _0xd15829=[_0x41a324?.[_0x548dad(0x16b)],_0x41a324?.['index_name'],_0x41a324?.[_0x548dad(0x155)]][_0x548dad(0x16f)](_0x40bfcd=>typeof _0x40bfcd===_0x548dad(0x173)&&_0x40bfcd[_0x548dad(0x169)]()),_0x17acb4=[_0x41a324?.[_0x548dad(0x138)],_0x41a324?.[_0x548dad(0x147)]]['find'](_0xe9f446=>typeof _0xe9f446===_0x548dad(0x173)&&_0xe9f446['trim']());return[{..._0xd15829?{'name':_0xd15829[_0x548dad(0x169)]()}:{},..._0x17acb4?{'type':_0x17acb4[_0x548dad(0x169)]()}:{},'columns':_0x488d4c}];}),_0x352a9a=[..._0x134eee],_0x5694d3=typeof _0x2d84fe?.[_0x12656f(0x13e)]?.[_0x12656f(0x157)]===_0x12656f(0x173)?_0x2d84fe[_0x12656f(0x13e)]['pkField'][_0x12656f(0x13b)](',')[_0x12656f(0x13a)](_0x469c05=>_0x469c05['trim']())[_0x12656f(0x136)](Boolean):[];return _0x5694d3[_0x12656f(0x16a)]>0x0&&_0x352a9a[_0x12656f(0x160)]({'type':_0x12656f(0x151),'columns':_0x5694d3}),{'indexes':_0x352a9a,'metadataAvailable':_0x134eee[_0x12656f(0x16a)]>0x0};}
1
+ const a185_0xb28345=a185_0x5153;(function(_0x71ce5d,_0x5f53de){const _0x357212=a185_0x5153,_0x347caa=_0x71ce5d();while(!![]){try{const _0x302fe5=parseInt(_0x357212(0x104))/0x1*(-parseInt(_0x357212(0xef))/0x2)+-parseInt(_0x357212(0xe6))/0x3*(parseInt(_0x357212(0x102))/0x4)+-parseInt(_0x357212(0xf7))/0x5+-parseInt(_0x357212(0xfc))/0x6*(parseInt(_0x357212(0x108))/0x7)+-parseInt(_0x357212(0xdf))/0x8+-parseInt(_0x357212(0x112))/0x9+parseInt(_0x357212(0x113))/0xa;if(_0x302fe5===_0x5f53de)break;else _0x347caa['push'](_0x347caa['shift']());}catch(_0x2b98c3){_0x347caa['push'](_0x347caa['shift']());}}}(a185_0x1b93,0x94531));import{readFileSync,existsSync}from'node:fs';import{resolve}from'node:path';import{validateSql}from'../../core/sql-validator.js';function a185_0x5153(_0x4a2a7a,_0x3517a){_0x4a2a7a=_0x4a2a7a-0xda;const _0x1b9339=a185_0x1b93();let _0x515316=_0x1b9339[_0x4a2a7a];return _0x515316;}function a185_0x1b93(){const _0x129e47=['1086lSeoVr','Table\x20\x22','reason','schema:','validation','appCode','31136vlzaIY','name','51403wsdsjb','--check-indexes\x20requires\x20--schemas.','Path\x20to\x20the\x20SQL\x20file\x20to\x20validate','check-indexes','15281wJpjps','sql','Inline\x20SQL\x20content\x20to\x20validate\x20(alternative\x20to\x20--file)','isArray','bool','string','flatMap','SQL\x20schema\x20validation','schemas','filter','368559RgqOFH','27227710UNocJD','trim','split','get','map','fields','tableName','Comma-separated\x20dataset\x20codes\x20to\x20cross-check\x20table/column\x20names\x20against','valid','\x22\x20not\x20found\x20or\x20not\x20accessible','sqlType','Dataset\x20\x22','find','File\x20not\x20found:\x20','1945768sNiuel','columns','message','size','toLowerCase','type','schemaWarnings','69YtwNRP','Validate\x20SQL\x20content\x20without\x20saving\x20(type\x20detection,\x20parameter\x20extraction,\x20optional\x20schema\x20check)','cwd','isDangerous','str','dbtableConfig','primary','pkField','file','34VlwAiE','isSelectOnly','dataset','Provide\x20--file\x20or\x20--sql','tables','push','index_name','validate','1915280VtbJMx','index_type','indexes','columnNames','length'];a185_0x1b93=function(){return _0x129e47;};return a185_0x1b93();}import{auditSqlJoinIndexes}from'../../core/sql-index-auditor.js';import{getDatasetDetail,listDatasets}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{assertDatasetIsDbTableBacked,filterDbTableBackedDatasets}from'../../commands/dataset/capability.js';export const sqlValidate={'service':a185_0xb28345(0x109),'command':a185_0xb28345(0xf6),'description':a185_0xb28345(0xe7),'risk':'read','flags':[{'name':a185_0xb28345(0xee),'type':'string','description':a185_0xb28345(0x106)},{'name':'sql','type':'string','description':a185_0xb28345(0x10a)},{'name':a185_0xb28345(0x110),'type':'string','description':a185_0xb28345(0x11a)},{'name':a185_0xb28345(0x107),'type':'boolean','description':'Audit\x20top-level\x20JOIN\x20equality\x20predicates\x20against\x20dataset\x20index\x20metadata'}],async 'execute'(_0x151ed0){const _0x32c802=a185_0xb28345,_0x254e5b=_0x151ed0['str'](_0x32c802(0xee)),_0x1651d1=_0x151ed0['str'](_0x32c802(0x109)),_0x5cabf0=_0x151ed0[_0x32c802(0xea)](_0x32c802(0x110)),_0x296b89=_0x151ed0[_0x32c802(0x10c)](_0x32c802(0x107));if(!_0x254e5b&&!_0x1651d1)throw CliErrors['flagMissing'](_0x32c802(0xee),_0x32c802(0xf2));if(_0x296b89&&!_0x5cabf0)throw CliErrors['validation'](_0x32c802(0x105));let _0x549b6f;if(_0x254e5b){const _0x194c60=resolve(process[_0x32c802(0xe8)](),_0x254e5b);if(!existsSync(_0x194c60))throw CliErrors[_0x32c802(0x100)](_0x32c802(0xde)+_0x194c60);_0x549b6f=readFileSync(_0x194c60,'utf-8');}else _0x549b6f=_0x1651d1;const _0x52cdfb=validateSql(_0x549b6f),_0x3032e7={'valid':_0x52cdfb[_0x32c802(0x11b)],'sqlType':_0x52cdfb['sqlType']['type'],'isSelectOnly':_0x52cdfb[_0x32c802(0xdb)][_0x32c802(0xf0)],'isDangerous':_0x52cdfb[_0x32c802(0xdb)][_0x32c802(0xe9)],'tables':_0x52cdfb[_0x32c802(0xf3)],'parameters':_0x52cdfb['parameters'],'message':_0x52cdfb[_0x32c802(0xe1)]};_0x52cdfb[_0x32c802(0xdb)][_0x32c802(0xfe)]&&(_0x3032e7[_0x32c802(0xfe)]=_0x52cdfb[_0x32c802(0xdb)]['reason']);if(_0x5cabf0&&_0x52cdfb['valid']){const _0x9d83e2=_0x5cabf0[_0x32c802(0x115)](',')['map'](_0x572636=>_0x572636['trim']())[_0x32c802(0x111)](Boolean),_0xf1d918=[],_0x24f87e=[],_0x2eacb0=filterDbTableBackedDatasets(await listDatasets(_0x151ed0[_0x32c802(0x101)])),_0x2b1909=new Map(_0x2eacb0['map'](_0x29cdc3=>[_0x29cdc3[_0x32c802(0xeb)]?.[_0x32c802(0x119)]?.[_0x32c802(0xe3)](),_0x29cdc3]));for(const _0x16c102 of _0x52cdfb['tables']){const _0x3505e0=_0x2b1909[_0x32c802(0x116)](_0x16c102[_0x32c802(0xe3)]());!_0x3505e0&&_0xf1d918[_0x32c802(0xf4)](_0x32c802(0xfd)+_0x16c102+'\x22\x20not\x20found\x20in\x20any\x20dataset');}for(const _0x1eb306 of _0x9d83e2){let _0x1f59d3;try{_0x1f59d3=await getDatasetDetail(_0x1eb306);}catch{_0xf1d918[_0x32c802(0xf4)](_0x32c802(0xdc)+_0x1eb306+_0x32c802(0xda));continue;}assertDatasetIsDbTableBacked(_0x1f59d3,_0x32c802(0x10f));const _0x2b28d7=Array['isArray'](_0x1f59d3[_0x32c802(0x118)])?_0x1f59d3['fields']:[],_0x45d683=new Set(_0x2b28d7[_0x32c802(0x117)](_0x5c515d=>_0x5c515d[_0x32c802(0x103)]?.[_0x32c802(0xe3)]())),_0x59a0ec=_0x1f59d3[_0x32c802(0xeb)]?.[_0x32c802(0x119)]||_0x1f59d3[_0x32c802(0x119)]||_0x1eb306;_0x3032e7[_0x32c802(0xff)+_0x59a0ec]={'code':_0x1eb306,'tableName':_0x59a0ec,'fieldCount':_0x45d683[_0x32c802(0xe2)],'fields':Array['from'](_0x45d683)};if(_0x296b89){const _0x42ed2f=normalizeDatasetIndexes(_0x1f59d3);_0x24f87e[_0x32c802(0xf4)]({'tableName':_0x59a0ec,..._0x42ed2f});}}_0xf1d918[_0x32c802(0xfb)]>0x0&&(_0x3032e7[_0x32c802(0xe5)]=_0xf1d918),_0x296b89&&(_0x3032e7['joinAudit']=auditSqlJoinIndexes(_0x549b6f,_0x24f87e));}return{'ok':_0x52cdfb[_0x32c802(0x11b)],'data':_0x3032e7,'message':_0x52cdfb['message']};}};function normalizeDatasetIndexes(_0x64d56){const _0x1ef771=a185_0xb28345,_0x57ef57=Array['isArray'](_0x64d56?.['dataset']?.[_0x1ef771(0xf9)])?_0x64d56[_0x1ef771(0xf1)][_0x1ef771(0xf9)]:Array[_0x1ef771(0x10b)](_0x64d56?.[_0x1ef771(0xf9)])?_0x64d56[_0x1ef771(0xf9)]:[],_0x132df8=_0x57ef57[_0x1ef771(0x10e)](_0x29a27c=>{const _0x2c70ae=_0x1ef771,_0x56162e=Array['isArray'](_0x29a27c?.['index_columns'])?_0x29a27c['index_columns']:Array[_0x2c70ae(0x10b)](_0x29a27c?.['columnNames'])?_0x29a27c[_0x2c70ae(0xfa)]:Array[_0x2c70ae(0x10b)](_0x29a27c?.[_0x2c70ae(0xe0)])?_0x29a27c[_0x2c70ae(0xe0)]:[],_0x3d551a=_0x56162e['filter'](_0xddb1e=>typeof _0xddb1e===_0x2c70ae(0x10d))[_0x2c70ae(0x117)](_0x4d358b=>_0x4d358b[_0x2c70ae(0x114)]())['filter'](Boolean);if(_0x3d551a[_0x2c70ae(0xfb)]===0x0)return[];const _0x28b80c=[_0x29a27c?.['indexName'],_0x29a27c?.[_0x2c70ae(0xf5)],_0x29a27c?.[_0x2c70ae(0x103)]][_0x2c70ae(0xdd)](_0x51a925=>typeof _0x51a925==='string'&&_0x51a925[_0x2c70ae(0x114)]()),_0xc91eca=[_0x29a27c?.[_0x2c70ae(0xf8)],_0x29a27c?.[_0x2c70ae(0xe4)]][_0x2c70ae(0xdd)](_0x2f24ac=>typeof _0x2f24ac===_0x2c70ae(0x10d)&&_0x2f24ac['trim']());return[{..._0x28b80c?{'name':_0x28b80c[_0x2c70ae(0x114)]()}:{},..._0xc91eca?{'type':_0xc91eca[_0x2c70ae(0x114)]()}:{},'columns':_0x3d551a}];}),_0x532dff=[..._0x132df8],_0x692d25=typeof _0x64d56?.['dbtableConfig']?.[_0x1ef771(0xed)]===_0x1ef771(0x10d)?_0x64d56['dbtableConfig']['pkField'][_0x1ef771(0x115)](',')['map'](_0x3ebff1=>_0x3ebff1[_0x1ef771(0x114)]())[_0x1ef771(0x111)](Boolean):[];return _0x692d25[_0x1ef771(0xfb)]>0x0&&_0x532dff['unshift']({'type':_0x1ef771(0xec),'columns':_0x692d25}),{'indexes':_0x532dff,'metadataAvailable':_0x132df8[_0x1ef771(0xfb)]>0x0};}
@@ -0,0 +1,2 @@
1
+ import type { CommandDefinition } from "../../framework/types.js";
2
+ export declare const taskDefinitions: CommandDefinition[];
@@ -1 +1 @@
1
- function a186_0x12ba(){const _0x2c3720=['3525XztVeH','335aXwVow','9taafWT','93702xmpvdm','160IQpAHq','4764xfsxcw','71780isJOLQ','2825676uLpTsW','14159lyaQoq','6019464IRemCN','27103384EVzCZG'];a186_0x12ba=function(){return _0x2c3720;};return a186_0x12ba();}(function(_0x1d94a2,_0x3bbb89){const _0x5d8a90=a186_0x3c33,_0x5441f9=_0x1d94a2();while(!![]){try{const _0x3f4956=-parseInt(_0x5d8a90(0xe3))/0x1*(-parseInt(_0x5d8a90(0xdf))/0x2)+parseInt(_0x5d8a90(0xe6))/0x3*(parseInt(_0x5d8a90(0xe0))/0x4)+parseInt(_0x5d8a90(0xe7))/0x5*(parseInt(_0x5d8a90(0xe9))/0x6)+parseInt(_0x5d8a90(0xe2))/0x7+parseInt(_0x5d8a90(0xe4))/0x8*(-parseInt(_0x5d8a90(0xe8))/0x9)+-parseInt(_0x5d8a90(0xe1))/0xa+-parseInt(_0x5d8a90(0xe5))/0xb;if(_0x3f4956===_0x3bbb89)break;else _0x5441f9['push'](_0x5441f9['shift']());}catch(_0x21fd13){_0x5441f9['push'](_0x5441f9['shift']());}}}(a186_0x12ba,0xb9345));function a186_0x3c33(_0x500f01,_0x14053a){_0x500f01=_0x500f01-0xdf;const _0x12baa6=a186_0x12ba();let _0x3c33d8=_0x12baa6[_0x500f01];return _0x3c33d8;}import{taskStatus}from'../../commands/task/status.js';export const taskDefinitions=[taskStatus];
1
+ (function(_0x55f282,_0x120b77){const _0x546da7=a186_0x2ca8,_0x2afe1f=_0x55f282();while(!![]){try{const _0x90af39=parseInt(_0x546da7(0x169))/0x1+parseInt(_0x546da7(0x16c))/0x2*(-parseInt(_0x546da7(0x16e))/0x3)+-parseInt(_0x546da7(0x167))/0x4+parseInt(_0x546da7(0x16a))/0x5*(parseInt(_0x546da7(0x168))/0x6)+parseInt(_0x546da7(0x16b))/0x7+-parseInt(_0x546da7(0x166))/0x8*(-parseInt(_0x546da7(0x16f))/0x9)+-parseInt(_0x546da7(0x16d))/0xa;if(_0x90af39===_0x120b77)break;else _0x2afe1f['push'](_0x2afe1f['shift']());}catch(_0x3d33d5){_0x2afe1f['push'](_0x2afe1f['shift']());}}}(a186_0x367b,0x6b2dd));function a186_0x367b(){const _0x4cd374=['204200LUIZjl','2880088zUKHBB','36PPXwOU','385986cgsWcF','503670JDAlfa','3357473IUhRJu','20926pBkdkY','7574590vojbdD','33RmYnJC','198NYrVwI'];a186_0x367b=function(){return _0x4cd374;};return a186_0x367b();}import{taskStatus}from'../../commands/task/status.js';function a186_0x2ca8(_0x37028f,_0x1c7b87){_0x37028f=_0x37028f-0x166;const _0x367bdb=a186_0x367b();let _0x2ca85d=_0x367bdb[_0x37028f];return _0x2ca85d;}export const taskDefinitions=[taskStatus];
@@ -0,0 +1,2 @@
1
+ import type { CommandDefinition } from "../../framework/types.js";
2
+ export declare const taskStatus: CommandDefinition;
@@ -1 +1 @@
1
- const a187_0x5a74cc=a187_0x20aa;(function(_0x50a6a,_0x527892){const _0x5e657f=a187_0x20aa,_0x25670a=_0x50a6a();while(!![]){try{const _0x5e88f9=parseInt(_0x5e657f(0x108))/0x1*(parseInt(_0x5e657f(0xff))/0x2)+parseInt(_0x5e657f(0x100))/0x3*(parseInt(_0x5e657f(0xfb))/0x4)+-parseInt(_0x5e657f(0xfe))/0x5+-parseInt(_0x5e657f(0x107))/0x6+-parseInt(_0x5e657f(0x105))/0x7+-parseInt(_0x5e657f(0x104))/0x8+parseInt(_0x5e657f(0x10b))/0x9;if(_0x5e88f9===_0x527892)break;else _0x25670a['push'](_0x25670a['shift']());}catch(_0x25db11){_0x25670a['push'](_0x25670a['shift']());}}}(a187_0x1129,0x6df5b));import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{asyncTaskMessage,buildAsyncTaskStatusCommand,normalizeAsyncTask}from'../../commands/common/async-task.js';import{getAsyncTaskStatus}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';function a187_0x1129(){const _0x358491=['task','Task\x20status\x20response\x20id\x20mismatch:\x20requested\x20','930660MdXBTP','14636TWuaZT','10503ivPBEr','compress','isTerminal','trim','6168104DzcuLv','2936556vkEAil','task-id','5152872LJUhfX','101roSUtU','flagMissing','apiError','12132639iMCVBU','status','read','taskId','appCode','684zYUtJh'];a187_0x1129=function(){return _0x358491;};return a187_0x1129();}function a187_0x20aa(_0x10dc97,_0x1fc8a3){_0x10dc97=_0x10dc97-0xfb;const _0x1129fe=a187_0x1129();let _0x20aace=_0x1129fe[_0x10dc97];return _0x20aace;}export const taskStatus={'service':a187_0x5a74cc(0xfc),'command':a187_0x5a74cc(0x10c),'description':'Query\x20an\x20asynchronous\x20task;\x20repeat\x20for\x20PENDING\x20or\x20PROCESSING\x20until\x20SUCCESS\x20or\x20FAILED','risk':a187_0x5a74cc(0x10d),'defaultOutputFormat':a187_0x5a74cc(0x101),'structuredErrors':!![],'flags':[{'name':a187_0x5a74cc(0x106),'type':'string','required':!![],'description':'Task\x20id\x20returned\x20by\x20an\x20asynchronous\x20platform\x20command'},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x187f09){const _0x24fb34=a187_0x5a74cc;if(!_0x187f09['str'](_0x24fb34(0x106))['trim']())throw CliErrors[_0x24fb34(0x109)](_0x24fb34(0x106));},async 'execute'(_0x505aff){const _0x4527fa=a187_0x5a74cc,_0xbc5dc1=_0x505aff['str'](_0x4527fa(0x106))[_0x4527fa(0x103)](),_0x378a82=normalizeAsyncTask(await getAsyncTaskStatus(_0xbc5dc1,_0x505aff['appCode'],_0x505aff['cookie']));if(_0x378a82[_0x4527fa(0x10e)]!==_0xbc5dc1)throw CliErrors[_0x4527fa(0x10a)](_0x4527fa(0xfd)+_0xbc5dc1+',\x20received\x20'+_0x378a82[_0x4527fa(0x10e)]+'.');const _0x5232df=buildAsyncTaskStatusCommand(_0x378a82[_0x4527fa(0x10e)],_0x505aff[_0x4527fa(0x10f)]);return{'ok':!![],'message':asyncTaskMessage(_0x378a82),'data':{'appCode':_0x505aff[_0x4527fa(0x10f)],..._0x378a82,'query':_0x378a82[_0x4527fa(0x102)]?null:{'command':_0x5232df}}};}};
1
+ function a187_0x46bd(_0x16b20a,_0x36cfd3){_0x16b20a=_0x16b20a-0x110;const _0x1caa6d=a187_0x1caa();let _0x46bde7=_0x1caa6d[_0x16b20a];return _0x46bde7;}const a187_0xc4dfc6=a187_0x46bd;(function(_0x5bf062,_0x5a320d){const _0x50f93c=a187_0x46bd,_0x184c7e=_0x5bf062();while(!![]){try{const _0x37151a=parseInt(_0x50f93c(0x124))/0x1*(parseInt(_0x50f93c(0x112))/0x2)+parseInt(_0x50f93c(0x12a))/0x3+parseInt(_0x50f93c(0x125))/0x4*(parseInt(_0x50f93c(0x115))/0x5)+parseInt(_0x50f93c(0x129))/0x6*(parseInt(_0x50f93c(0x127))/0x7)+parseInt(_0x50f93c(0x114))/0x8+parseInt(_0x50f93c(0x11d))/0x9*(-parseInt(_0x50f93c(0x121))/0xa)+-parseInt(_0x50f93c(0x120))/0xb;if(_0x37151a===_0x5a320d)break;else _0x184c7e['push'](_0x184c7e['shift']());}catch(_0x5966a6){_0x184c7e['push'](_0x184c7e['shift']());}}}(a187_0x1caa,0x82ed4));import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function a187_0x1caa(){const _0x27ad13=['4713961dQENhs','read','6trEeQk','791949NgGwuf','Task\x20id\x20returned\x20by\x20an\x20asynchronous\x20platform\x20command',',\x20received\x20','16ViFeWd','status','562392drhAYb','110wRPhuI','task-id','compress','taskId','appCode','apiError','flagMissing','Task\x20status\x20response\x20id\x20mismatch:\x20requested\x20','7583616CoIqQw','string','cookie','11259281QtUhFq','10YhhaPx','task','trim','108838kIWQCr','95284jtIYic','str'];a187_0x1caa=function(){return _0x27ad13;};return a187_0x1caa();}import{asyncTaskMessage,buildAsyncTaskStatusCommand,normalizeAsyncTask}from'../../commands/common/async-task.js';import{getAsyncTaskStatus}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';export const taskStatus={'service':a187_0xc4dfc6(0x122),'command':a187_0xc4dfc6(0x113),'description':'Query\x20an\x20asynchronous\x20task;\x20repeat\x20for\x20PENDING\x20or\x20PROCESSING\x20until\x20SUCCESS\x20or\x20FAILED','risk':a187_0xc4dfc6(0x128),'defaultOutputFormat':a187_0xc4dfc6(0x117),'structuredErrors':!![],'flags':[{'name':'task-id','type':a187_0xc4dfc6(0x11e),'required':!![],'description':a187_0xc4dfc6(0x110)},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x267fe5){const _0x46b972=a187_0xc4dfc6;if(!_0x267fe5[_0x46b972(0x126)](_0x46b972(0x116))['trim']())throw CliErrors[_0x46b972(0x11b)](_0x46b972(0x116));},async 'execute'(_0x35d14e){const _0x2d0996=a187_0xc4dfc6,_0x36169b=_0x35d14e[_0x2d0996(0x126)]('task-id')[_0x2d0996(0x123)](),_0x204ade=normalizeAsyncTask(await getAsyncTaskStatus(_0x36169b,_0x35d14e[_0x2d0996(0x119)],_0x35d14e[_0x2d0996(0x11f)]));if(_0x204ade[_0x2d0996(0x118)]!==_0x36169b)throw CliErrors[_0x2d0996(0x11a)](_0x2d0996(0x11c)+_0x36169b+_0x2d0996(0x111)+_0x204ade[_0x2d0996(0x118)]+'.');const _0xe9aa4e=buildAsyncTaskStatusCommand(_0x204ade[_0x2d0996(0x118)],_0x35d14e[_0x2d0996(0x119)]);return{'ok':!![],'message':asyncTaskMessage(_0x204ade),'data':{'appCode':_0x35d14e[_0x2d0996(0x119)],..._0x204ade,'query':_0x204ade['isTerminal']?null:{'command':_0xe9aa4e}}};}};
@@ -0,0 +1,2 @@
1
+ import type { CommandDefinition } from "../../framework/types.js";
2
+ export declare const tenantDefinitions: CommandDefinition[];
@@ -1 +1 @@
1
- function a188_0x53b5(){const _0x11417b=['1611144sMCWCt','16nqYmJX','519486AElVMN','48XDlNMB','5294600QlAHRH','403399BigNrN','598428cfdWZl','7679581ezniEJ','264567kpRuqC'];a188_0x53b5=function(){return _0x11417b;};return a188_0x53b5();}function a188_0x51de(_0x2bded8,_0x94a04d){_0x2bded8=_0x2bded8-0x18c;const _0x53b5=a188_0x53b5();let _0x51de26=_0x53b5[_0x2bded8];return _0x51de26;}(function(_0x336643,_0x1e9d62){const _0x13af30=a188_0x51de,_0x355a48=_0x336643();while(!![]){try{const _0x4fce7b=-parseInt(_0x13af30(0x18c))/0x1+parseInt(_0x13af30(0x190))/0x2+-parseInt(_0x13af30(0x18f))/0x3*(parseInt(_0x13af30(0x191))/0x4)+-parseInt(_0x13af30(0x194))/0x5+parseInt(_0x13af30(0x192))/0x6+parseInt(_0x13af30(0x18e))/0x7+-parseInt(_0x13af30(0x193))/0x8*(-parseInt(_0x13af30(0x18d))/0x9);if(_0x4fce7b===_0x1e9d62)break;else _0x355a48['push'](_0x355a48['shift']());}catch(_0x5a84bd){_0x355a48['push'](_0x355a48['shift']());}}}(a188_0x53b5,0x8beb9));import{tenantMembersListDefinition}from'../../commands/tenant/members-list.js';export const tenantDefinitions=[tenantMembersListDefinition];
1
+ (function(_0x3d1efb,_0xd0776){const _0x281e16=a188_0x3fc4,_0x18953c=_0x3d1efb();while(!![]){try{const _0x5ddbae=-parseInt(_0x281e16(0xd3))/0x1*(-parseInt(_0x281e16(0xd0))/0x2)+-parseInt(_0x281e16(0xd6))/0x3*(-parseInt(_0x281e16(0xcb))/0x4)+-parseInt(_0x281e16(0xca))/0x5*(-parseInt(_0x281e16(0xcf))/0x6)+parseInt(_0x281e16(0xd2))/0x7*(-parseInt(_0x281e16(0xce))/0x8)+parseInt(_0x281e16(0xd4))/0x9*(-parseInt(_0x281e16(0xcd))/0xa)+parseInt(_0x281e16(0xd1))/0xb+-parseInt(_0x281e16(0xd5))/0xc*(-parseInt(_0x281e16(0xcc))/0xd);if(_0x5ddbae===_0xd0776)break;else _0x18953c['push'](_0x18953c['shift']());}catch(_0x37dbe6){_0x18953c['push'](_0x18953c['shift']());}}}(a188_0x37d9,0x3172d));import{tenantMembersListDefinition}from'../../commands/tenant/members-list.js';function a188_0x3fc4(_0x470677,_0x25b01b){_0x470677=_0x470677-0xca;const _0x37d932=a188_0x37d9();let _0x3fc4eb=_0x37d932[_0x470677];return _0x3fc4eb;}export const tenantDefinitions=[tenantMembersListDefinition];function a188_0x37d9(){const _0x12d2d9=['26GVzsQa','60LVUbxR','3069656LpAYcW','26382VEjdvF','1846qFnSmD','1604966fOrZtn','7vxzBkB','406tNXIEp','541035ojGRYK','1236372xLxYww','3HnFMtz','145bazvLn','370876ghpgyE'];a188_0x37d9=function(){return _0x12d2d9;};return a188_0x37d9();}
@@ -0,0 +1,2 @@
1
+ import type { CommandDefinition } from "../../framework/types.js";
2
+ export declare const tenantMembersListDefinition: CommandDefinition;
@@ -1 +1 @@
1
- const a189_0x1074d9=a189_0x58d0;function a189_0x58d0(_0xd9c15,_0x41b16e){_0xd9c15=_0xd9c15-0x118;const _0x473dd5=a189_0x473d();let _0x58d0be=_0x473dd5[_0xd9c15];return _0x58d0be;}(function(_0xdbcae6,_0x5b7bfb){const _0x5da28b=a189_0x58d0,_0x52eb91=_0xdbcae6();while(!![]){try{const _0x1e5c19=-parseInt(_0x5da28b(0x11b))/0x1+parseInt(_0x5da28b(0x123))/0x2+parseInt(_0x5da28b(0x121))/0x3+-parseInt(_0x5da28b(0x122))/0x4+-parseInt(_0x5da28b(0x128))/0x5*(-parseInt(_0x5da28b(0x11a))/0x6)+parseInt(_0x5da28b(0x125))/0x7*(parseInt(_0x5da28b(0x118))/0x8)+-parseInt(_0x5da28b(0x11c))/0x9;if(_0x1e5c19===_0x5b7bfb)break;else _0x52eb91['push'](_0x52eb91['shift']());}catch(_0x1d6728){_0x52eb91['push'](_0x52eb91['shift']());}}}(a189_0x473d,0xbce7b));function a189_0x473d(){const _0x4f1347=['\x20tenant\x20member(s)','8Drutpb','trim','1037886rWMXmc','703983cUzzKA','11055501jbszQL','List\x20members\x20of\x20a\x20tenant\x20available\x20to\x20the\x20current\x20account','str','tenant','members-list','2075298IbOnPN','299164MzeEHj','2946738gyEYas','length','3099614RpWAUM','flagMissing','tenant-code','5AaImeW'];a189_0x473d=function(){return _0x4f1347;};return a189_0x473d();}import{listCurrentUserTenantMemberships,listTenantDirectoryMembers}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{assertTenantAccessible,projectTenantMembers}from'../../commands/tenant/shared.js';export const tenantMembersListDefinition={'service':a189_0x1074d9(0x11f),'command':a189_0x1074d9(0x120),'description':a189_0x1074d9(0x11d),'risk':'read','requiresAuth':!![],'requiresAppCode':![],'structuredErrors':!![],'flags':[{'name':a189_0x1074d9(0x127),'type':'string','required':!![],'description':'Exact\x20tenant\x20code'}],async 'validate'(_0x380c4d){const _0x419a8d=a189_0x1074d9;if(!_0x380c4d[_0x419a8d(0x11e)](_0x419a8d(0x127))[_0x419a8d(0x119)]())throw CliErrors[_0x419a8d(0x126)](_0x419a8d(0x127),'Pass\x20--tenant-code\x20<code>.');},async 'execute'(_0x39cdfa){const _0x57a485=a189_0x1074d9,_0x40fae6=_0x39cdfa[_0x57a485(0x11e)](_0x57a485(0x127))[_0x57a485(0x119)](),_0x3156fe=await listCurrentUserTenantMemberships();assertTenantAccessible(_0x40fae6,_0x3156fe);const _0x559cdd=projectTenantMembers(await listTenantDirectoryMembers(_0x40fae6));return{'ok':!![],'data':{'tenantCode':_0x40fae6,'items':_0x559cdd,'totalCount':_0x559cdd[_0x57a485(0x124)]},'message':'Found\x20'+_0x559cdd[_0x57a485(0x124)]+_0x57a485(0x129)};}};
1
+ function a189_0x596b(){const _0x320105=['\x20tenant\x20member(s)','260gCRjyU','16783EAwods','str','70654EwrBdK','50334qEwLQn','4kTWiWd','45regxRb','1365JWhauE','13iyCLNy','43638RPHISi','trim','12086124cUDXEX','550323CKcsiZ','flagMissing','1174296bhegTd','tenant','11FLpviO','Pass\x20--tenant-code\x20<code>.','string','71920tYYmQK','Exact\x20tenant\x20code','members-list','tenant-code','length'];a189_0x596b=function(){return _0x320105;};return a189_0x596b();}const a189_0x4552de=a189_0x5906;(function(_0x4e712d,_0x549511){const _0x5be4ea=a189_0x5906,_0x5b3fa1=_0x4e712d();while(!![]){try{const _0x3323b2=-parseInt(_0x5be4ea(0x1ca))/0x1*(parseInt(_0x5be4ea(0x1c5))/0x2)+-parseInt(_0x5be4ea(0x1c6))/0x3*(-parseInt(_0x5be4ea(0x1c7))/0x4)+parseInt(_0x5be4ea(0x1c8))/0x5*(parseInt(_0x5be4ea(0x1d0))/0x6)+parseInt(_0x5be4ea(0x1c9))/0x7*(-parseInt(_0x5be4ea(0x1d5))/0x8)+-parseInt(_0x5be4ea(0x1ce))/0x9*(parseInt(_0x5be4ea(0x1db))/0xa)+-parseInt(_0x5be4ea(0x1d2))/0xb*(parseInt(_0x5be4ea(0x1cd))/0xc)+parseInt(_0x5be4ea(0x1c3))/0xd*(parseInt(_0x5be4ea(0x1cb))/0xe);if(_0x3323b2===_0x549511)break;else _0x5b3fa1['push'](_0x5b3fa1['shift']());}catch(_0x30fd81){_0x5b3fa1['push'](_0x5b3fa1['shift']());}}}(a189_0x596b,0xf26c9));function a189_0x5906(_0x2f330b,_0x4e5999){_0x2f330b=_0x2f330b-0x1c3;const _0x596b45=a189_0x596b();let _0x5906e3=_0x596b45[_0x2f330b];return _0x5906e3;}import{listCurrentUserTenantMemberships,listTenantDirectoryMembers}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{assertTenantAccessible,projectTenantMembers}from'../../commands/tenant/shared.js';export const tenantMembersListDefinition={'service':a189_0x4552de(0x1d1),'command':a189_0x4552de(0x1d7),'description':'List\x20members\x20of\x20a\x20tenant\x20available\x20to\x20the\x20current\x20account','risk':'read','requiresAuth':!![],'requiresAppCode':![],'structuredErrors':!![],'flags':[{'name':a189_0x4552de(0x1d8),'type':a189_0x4552de(0x1d4),'required':!![],'description':a189_0x4552de(0x1d6)}],async 'validate'(_0x488c81){const _0x50c74f=a189_0x4552de;if(!_0x488c81[_0x50c74f(0x1c4)](_0x50c74f(0x1d8))[_0x50c74f(0x1cc)]())throw CliErrors[_0x50c74f(0x1cf)]('tenant-code',_0x50c74f(0x1d3));},async 'execute'(_0x4b05e0){const _0x9113b=a189_0x4552de,_0x4fd1c5=_0x4b05e0[_0x9113b(0x1c4)]('tenant-code')['trim'](),_0x833956=await listCurrentUserTenantMemberships();assertTenantAccessible(_0x4fd1c5,_0x833956);const _0x34ee53=projectTenantMembers(await listTenantDirectoryMembers(_0x4fd1c5));return{'ok':!![],'data':{'tenantCode':_0x4fd1c5,'items':_0x34ee53,'totalCount':_0x34ee53['length']},'message':'Found\x20'+_0x34ee53[_0x9113b(0x1d9)]+_0x9113b(0x1da)};}};
@@ -0,0 +1,10 @@
1
+ import type { TenantDirectoryMember, TenantMembership } from "../../core/api-client.js";
2
+ export interface TenantMemberProjection {
3
+ userId: number;
4
+ username: string | null;
5
+ displayName: string | null;
6
+ role: "ADMIN" | "MEMBER";
7
+ status: string | null;
8
+ }
9
+ export declare function projectTenantMembers(members: TenantDirectoryMember[]): TenantMemberProjection[];
10
+ export declare function assertTenantAccessible(tenantCode: string, memberships: TenantMembership[]): void;
@@ -1 +1 @@
1
- function a190_0xa83e(){const _0x14e7f5=['username','1737884FMcumg','Tenant\x20\x22','10660SgoHnU','ADMIN','status','18708129QqxJAt','9VzazRH','232022BJMCIk','trim','7659RHOELC','1931224zwGLJH','some','displayName','adminFlag','sort','userId','10070GIJcHJ','tenantCode','4278GvGSMu','role','878439aZVcgj','MEMBER','isFinite','152VVNZrn'];a190_0xa83e=function(){return _0x14e7f5;};return a190_0xa83e();}function a190_0x54a4(_0x5458d1,_0x21c3b5){_0x5458d1=_0x5458d1-0x115;const _0xa83e1e=a190_0xa83e();let _0x54a40a=_0xa83e1e[_0x5458d1];return _0x54a40a;}(function(_0x523ce1,_0x15d187){const _0x14e715=a190_0x54a4,_0x29ce6b=_0x523ce1();while(!![]){try{const _0xe812d5=-parseInt(_0x14e715(0x117))/0x1+-parseInt(_0x14e715(0x126))/0x2+-parseInt(_0x14e715(0x122))/0x3*(-parseInt(_0x14e715(0x11c))/0x4)+-parseInt(_0x14e715(0x11e))/0x5*(-parseInt(_0x14e715(0x115))/0x6)+-parseInt(_0x14e715(0x123))/0x7*(-parseInt(_0x14e715(0x11a))/0x8)+-parseInt(_0x14e715(0x125))/0x9*(-parseInt(_0x14e715(0x12c))/0xa)+-parseInt(_0x14e715(0x121))/0xb;if(_0xe812d5===_0x15d187)break;else _0x29ce6b['push'](_0x29ce6b['shift']());}catch(_0x4591ff){_0x29ce6b['push'](_0x29ce6b['shift']());}}}(a190_0xa83e,0xbae1e));import{CliErrors}from'../../errors.js';function textOrNull(_0x2588de){const _0x34452b=a190_0x54a4,_0x12da64=_0x2588de?.[_0x34452b(0x124)]();return _0x12da64?_0x12da64:null;}export function projectTenantMembers(_0x482948){const _0x3ae92f=a190_0x54a4,_0x111378=new Map();for(const _0x2b1126 of _0x482948){const _0x51ef88=Number(_0x2b1126[_0x3ae92f(0x12b)]);if(!Number[_0x3ae92f(0x119)](_0x51ef88)||_0x51ef88<=0x0)continue;const _0x511450={'userId':_0x51ef88,'username':textOrNull(_0x2b1126[_0x3ae92f(0x11b)]),'displayName':textOrNull(_0x2b1126['nickname']),'role':_0x2b1126[_0x3ae92f(0x129)]===!![]?_0x3ae92f(0x11f):_0x3ae92f(0x118),'status':textOrNull(_0x2b1126[_0x3ae92f(0x120)])},_0x38baad=_0x111378['get'](_0x51ef88);if(!_0x38baad){_0x111378['set'](_0x51ef88,_0x511450);continue;}_0x38baad[_0x3ae92f(0x11b)]??=_0x511450[_0x3ae92f(0x11b)],_0x38baad[_0x3ae92f(0x128)]??=_0x511450[_0x3ae92f(0x128)],_0x38baad['status']??=_0x511450[_0x3ae92f(0x120)];if(_0x511450[_0x3ae92f(0x116)]===_0x3ae92f(0x11f))_0x38baad[_0x3ae92f(0x116)]=_0x3ae92f(0x11f);}return[..._0x111378['values']()][_0x3ae92f(0x12a)]((_0x2cf9f8,_0x4faacf)=>_0x2cf9f8['userId']-_0x4faacf[_0x3ae92f(0x12b)]);}export function assertTenantAccessible(_0xccc99c,_0x436116){const _0x5501b1=a190_0x54a4;if(_0x436116[_0x5501b1(0x127)](_0x1dd54d=>_0x1dd54d[_0x5501b1(0x12d)]===_0xccc99c))return;throw CliErrors['validation'](_0x5501b1(0x11d)+_0xccc99c+'\x22\x20is\x20not\x20available\x20to\x20the\x20current\x20account.','Check\x20--tenant-code\x20or\x20login\x20with\x20an\x20account\x20that\x20belongs\x20to\x20this\x20tenant.');}
1
+ function a190_0x5138(){const _0x5936f7=['values','ADMIN','8792819OWeLBN','displayName','tenantCode','adminFlag','role','set','12QRjcTf','status','username','MEMBER','508431zwxCfD','nickname','12738030UKfRWd','2738150hvYmGd','1072730vMozcJ','12MsGCvw','1062386AeRTky','isFinite','13664696bptJDX','some','9uMCFkv','trim','\x22\x20is\x20not\x20available\x20to\x20the\x20current\x20account.','userId'];a190_0x5138=function(){return _0x5936f7;};return a190_0x5138();}(function(_0x27cb02,_0x31caa0){const _0x333d58=a190_0x30f3,_0x61c02d=_0x27cb02();while(!![]){try{const _0xc0ea8b=-parseInt(_0x333d58(0x1cc))/0x1+-parseInt(_0x333d58(0x1c9))/0x2+parseInt(_0x333d58(0x1c6))/0x3*(-parseInt(_0x333d58(0x1cb))/0x4)+-parseInt(_0x333d58(0x1ca))/0x5*(parseInt(_0x333d58(0x1c2))/0x6)+parseInt(_0x333d58(0x1bc))/0x7+-parseInt(_0x333d58(0x1b4))/0x8*(-parseInt(_0x333d58(0x1b6))/0x9)+parseInt(_0x333d58(0x1c8))/0xa;if(_0xc0ea8b===_0x31caa0)break;else _0x61c02d['push'](_0x61c02d['shift']());}catch(_0x221e69){_0x61c02d['push'](_0x61c02d['shift']());}}}(a190_0x5138,0xd429f));import{CliErrors}from'../../errors.js';function a190_0x30f3(_0x320287,_0x477870){_0x320287=_0x320287-0x1b4;const _0x51386d=a190_0x5138();let _0x30f3d0=_0x51386d[_0x320287];return _0x30f3d0;}function textOrNull(_0x191e0f){const _0x508676=a190_0x30f3,_0x4a3b09=_0x191e0f?.[_0x508676(0x1b7)]();return _0x4a3b09?_0x4a3b09:null;}export function projectTenantMembers(_0x248115){const _0x14f294=a190_0x30f3,_0x3f36f3=new Map();for(const _0x53aeb4 of _0x248115){const _0x5a98e7=Number(_0x53aeb4[_0x14f294(0x1b9)]);if(!Number[_0x14f294(0x1cd)](_0x5a98e7)||_0x5a98e7<=0x0)continue;const _0x4cbb8a={'userId':_0x5a98e7,'username':textOrNull(_0x53aeb4[_0x14f294(0x1c4)]),'displayName':textOrNull(_0x53aeb4[_0x14f294(0x1c7)]),'role':_0x53aeb4[_0x14f294(0x1bf)]===!![]?'ADMIN':_0x14f294(0x1c5),'status':textOrNull(_0x53aeb4[_0x14f294(0x1c3)])},_0x72ccbd=_0x3f36f3['get'](_0x5a98e7);if(!_0x72ccbd){_0x3f36f3[_0x14f294(0x1c1)](_0x5a98e7,_0x4cbb8a);continue;}_0x72ccbd[_0x14f294(0x1c4)]??=_0x4cbb8a['username'],_0x72ccbd[_0x14f294(0x1bd)]??=_0x4cbb8a[_0x14f294(0x1bd)],_0x72ccbd[_0x14f294(0x1c3)]??=_0x4cbb8a[_0x14f294(0x1c3)];if(_0x4cbb8a[_0x14f294(0x1c0)]===_0x14f294(0x1bb))_0x72ccbd['role']='ADMIN';}return[..._0x3f36f3[_0x14f294(0x1ba)]()]['sort']((_0x59e3de,_0x1faa3a)=>_0x59e3de[_0x14f294(0x1b9)]-_0x1faa3a[_0x14f294(0x1b9)]);}export function assertTenantAccessible(_0x20714a,_0x202306){const _0x1d1599=a190_0x30f3;if(_0x202306[_0x1d1599(0x1b5)](_0x38a295=>_0x38a295[_0x1d1599(0x1be)]===_0x20714a))return;throw CliErrors['validation']('Tenant\x20\x22'+_0x20714a+_0x1d1599(0x1b8),'Check\x20--tenant-code\x20or\x20login\x20with\x20an\x20account\x20that\x20belongs\x20to\x20this\x20tenant.');}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * rabetbase workspace add <name> --appcode <code>
3
+ * 往当前工作环境(默认当前项目,`--global` 则全局)登记一个应用 profile。
4
+ */
5
+ import type { CommandDefinition } from "../../framework/types.js";
6
+ export declare const workspaceAddDefinition: CommandDefinition;
@@ -1 +1 @@
1
- function a191_0x718c(_0x29f16e,_0x24c581){_0x29f16e=_0x29f16e-0x197;const _0x9dfb2=a191_0x9dfb();let _0x718c8e=_0x9dfb2[_0x29f16e];return _0x718c8e;}const a191_0x4ac470=a191_0x718c;(function(_0x364861,_0x2ca853){const _0x58ee81=a191_0x718c,_0x3a61b3=_0x364861();while(!![]){try{const _0x2d52cb=-parseInt(_0x58ee81(0x1a4))/0x1+-parseInt(_0x58ee81(0x19c))/0x2+parseInt(_0x58ee81(0x198))/0x3+-parseInt(_0x58ee81(0x19d))/0x4*(-parseInt(_0x58ee81(0x1a1))/0x5)+parseInt(_0x58ee81(0x19e))/0x6+-parseInt(_0x58ee81(0x19a))/0x7*(parseInt(_0x58ee81(0x197))/0x8)+parseInt(_0x58ee81(0x1a0))/0x9*(parseInt(_0x58ee81(0x19b))/0xa);if(_0x2d52cb===_0x2ca853)break;else _0x3a61b3['push'](_0x3a61b3['shift']());}catch(_0x410010){_0x3a61b3['push'](_0x3a61b3['shift']());}}}(a191_0x9dfb,0x1e3be));import{buildAppAddFlags,runAppAdd,validateAppName}from'../../commands/common/app-registry.js';function a191_0x9dfb(){const _0xb16b05=['12010gXLFrw','55144asVEaj','95672YKPNtD','1289508eCasQH','name','747yZeqAN','5IeJLOI','App\x20profile\x20name','write','46969XmJitz','workspace\x20add','1984ULzOvz','116004UedQnl','Register\x20an\x20app\x20profile\x20in\x20the\x20current\x20workspace\x20(or\x20--global)','5047FfslNM'];a191_0x9dfb=function(){return _0xb16b05;};return a191_0x9dfb();}export const workspaceAddDefinition={'service':'workspace','command':'add','description':a191_0x4ac470(0x199),'risk':a191_0x4ac470(0x1a3),'requiresAuth':![],'requiresAppCode':![],'args':[{'name':a191_0x4ac470(0x19f),'description':a191_0x4ac470(0x1a2),'required':!![]}],'flags':buildAppAddFlags(),'validate':_0x695a0a=>validateAppName(_0x695a0a,a191_0x4ac470(0x1a5)),'execute':_0xf2243=>runAppAdd(_0xf2243,a191_0x4ac470(0x1a5))};
1
+ function a191_0x42a9(){const _0x35a1fc=['App\x20profile\x20name','4JfaPbI','1899lFcyNi','14200ZGFDHw','854meonhs','8125968NteRie','1004476WbpBHW','1635255rXMiIY','workspace\x20add','3142356sZlFXo','7YgdIFu','workspace','add','Register\x20an\x20app\x20profile\x20in\x20the\x20current\x20workspace\x20(or\x20--global)','name','9qUhaqM','48jQCmnr','write','4043770rpAjrM'];a191_0x42a9=function(){return _0x35a1fc;};return a191_0x42a9();}function a191_0x3b1d(_0x1f62e0,_0x4ad5fb){_0x1f62e0=_0x1f62e0-0x195;const _0x42a901=a191_0x42a9();let _0x3b1d9c=_0x42a901[_0x1f62e0];return _0x3b1d9c;}const a191_0x5df045=a191_0x3b1d;(function(_0x5e9fc6,_0x20c46a){const _0x2f548b=a191_0x3b1d,_0x473bbe=_0x5e9fc6();while(!![]){try{const _0x4eb82d=-parseInt(_0x2f548b(0x197))/0x1+parseInt(_0x2f548b(0x198))/0x2*(parseInt(_0x2f548b(0x196))/0x3)+-parseInt(_0x2f548b(0x195))/0x4*(parseInt(_0x2f548b(0x19b))/0x5)+parseInt(_0x2f548b(0x19d))/0x6*(parseInt(_0x2f548b(0x19e))/0x7)+parseInt(_0x2f548b(0x199))/0x8+parseInt(_0x2f548b(0x1a3))/0x9*(-parseInt(_0x2f548b(0x1a6))/0xa)+-parseInt(_0x2f548b(0x19a))/0xb*(parseInt(_0x2f548b(0x1a4))/0xc);if(_0x4eb82d===_0x20c46a)break;else _0x473bbe['push'](_0x473bbe['shift']());}catch(_0x42a308){_0x473bbe['push'](_0x473bbe['shift']());}}}(a191_0x42a9,0xaa9f7));import{buildAppAddFlags,runAppAdd,validateAppName}from'../../commands/common/app-registry.js';export const workspaceAddDefinition={'service':a191_0x5df045(0x19f),'command':a191_0x5df045(0x1a0),'description':a191_0x5df045(0x1a1),'risk':a191_0x5df045(0x1a5),'requiresAuth':![],'requiresAppCode':![],'args':[{'name':a191_0x5df045(0x1a2),'description':a191_0x5df045(0x1a7),'required':!![]}],'flags':buildAppAddFlags(),'validate':_0xb23338=>validateAppName(_0xb23338,a191_0x5df045(0x19c)),'execute':_0x53495f=>runAppAdd(_0x53495f,a191_0x5df045(0x19c))};
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Workspace commands configure the current directory only.
3
+ *
4
+ * This is the business-facing replacement for app init/use style commands:
5
+ * rabetbase workspace init --appcode <code>
6
+ * rabetbase workspace use --app <name>
7
+ */
8
+ import type { CommandDefinition } from "../../framework/types.js";
9
+ declare const WORKSPACE_USAGE = "rabetbase workspace <init|use> --app <name> [--appcode <code>]";
10
+ export declare const workspaceDefinitions: CommandDefinition[];
11
+ export { WORKSPACE_USAGE };
@@ -1 +1 @@
1
- const a192_0x123c3f=a192_0x1c6c;(function(_0xa1d0f9,_0x58fdb1){const _0x35d4fe=a192_0x1c6c,_0x28c771=_0xa1d0f9();while(!![]){try{const _0x21361a=-parseInt(_0x35d4fe(0x17b))/0x1*(parseInt(_0x35d4fe(0x19c))/0x2)+-parseInt(_0x35d4fe(0x184))/0x3+-parseInt(_0x35d4fe(0x16c))/0x4*(-parseInt(_0x35d4fe(0x17c))/0x5)+parseInt(_0x35d4fe(0x16f))/0x6+parseInt(_0x35d4fe(0x164))/0x7+-parseInt(_0x35d4fe(0x193))/0x8*(-parseInt(_0x35d4fe(0x19a))/0x9)+-parseInt(_0x35d4fe(0x175))/0xa;if(_0x21361a===_0x58fdb1)break;else _0x28c771['push'](_0x28c771['shift']());}catch(_0xc03e1e){_0x28c771['push'](_0x28c771['shift']());}}}(a192_0x167d,0x48c0a));import{CliErrors}from'../../errors.js';import{CLI_BIN_NAME}from'../../constant/cli.js';import{RABETBASE_ENV_VALUES}from'../../constant/env.js';function a192_0x167d(){const _0x836fb5=['Default\x20page\x20size\x20for\x20this\x20workspace\x20app\x20profile','Default\x20output\x20format\x20for\x20this\x20workspace\x20app\x20profile','\x20workspace\x20<init|use>\x20--app\x20<name>\x20[--appcode\x20<code>]','use','workspace','env','init','.\x20Credentials:\x20not\x20written.','16MokAQO','number','initialized','isArray','riskLevel','join','workspace.','1977057ruJVOu','pageSize','8ARBMkK','apiDir','locale','format','2966733kVdThj','\x20(appcode:\x20','string','write','\x20workspace\x20use\x20--app\x20<name>`.','keys','App\x20profile\x20name\x20to\x20use\x20in\x20this\x20workspace','defaultApp','11540zxtUyS','flag',').\x20Config:\x20','1240182Yrsrqm','Missing\x20workspace\x20app\x20selector.','app','Workspace\x20','Invalid\x20appcode:\x20','Switch\x20the\x20current\x20workspace\x20app\x20binding','4516420HbFKrZ','object','appcode','project','Use\x20`','globalConfig','1637dFSbOQ','325TtBECa','apps','updated','App\x20code\x20to\x20bind\x20to\x20this\x20workspace','App\x20\x22','Pass\x20--appcode\x20<code>,\x20or\x20choose\x20one\x20of:\x20','Locale\x20for\x20this\x20workspace\x20app\x20profile','Risk\x20level\x20for\x20this\x20workspace\x20app\x20profile','1503609bimALb','defaultFormat','trim','validation','str','\x20--app\x20','\x20workspace\x20init\x20--appcode\x20<code>`\x20or\x20`'];a192_0x167d=function(){return _0x836fb5;};return a192_0x167d();}import{RABETBASE_OUTPUT_FORMAT_VALUES}from'../../constant/output.js';import{RISK_LEVEL_VALUES}from'../../constant/risk.js';import{validateAppcode}from'../../commands/common/validate.js';import{readConfigFile,readRawConfigWithLayers,resolveWriteConfigPath,writeConfigFile}from'../../context.js';import{workspaceAddDefinition}from'../../commands/workspace/add.js';function a192_0x1c6c(_0x2f052a,_0x4d2921){_0x2f052a=_0x2f052a-0x164;const _0x167d82=a192_0x167d();let _0x1c6cd0=_0x167d82[_0x2f052a];return _0x1c6cd0;}import{workspaceRemoveDefinition}from'../../commands/workspace/remove.js';const WORKSPACE_USAGE=CLI_BIN_NAME+a192_0x123c3f(0x18d),SAFE_PROFILE_KEYS=[a192_0x123c3f(0x177),a192_0x123c3f(0x190),a192_0x123c3f(0x19d),a192_0x123c3f(0x19f),'pageSize','riskLevel',a192_0x123c3f(0x19e)],workspaceFlags=[{'name':a192_0x123c3f(0x171),'type':a192_0x123c3f(0x166),'description':a192_0x123c3f(0x16a)},{'name':a192_0x123c3f(0x177),'type':a192_0x123c3f(0x166),'description':a192_0x123c3f(0x17f)},{'name':'env','type':a192_0x123c3f(0x166),'description':'Target\x20environment','enum':[...RABETBASE_ENV_VALUES]},{'name':a192_0x123c3f(0x19d),'type':'string','description':'API\x20directory\x20path\x20for\x20this\x20workspace\x20app\x20profile'},{'name':a192_0x123c3f(0x185),'type':a192_0x123c3f(0x166),'description':a192_0x123c3f(0x18c),'enum':[...RABETBASE_OUTPUT_FORMAT_VALUES]},{'name':'pageSize','type':a192_0x123c3f(0x194),'description':a192_0x123c3f(0x18b)},{'name':a192_0x123c3f(0x197),'type':'string','description':a192_0x123c3f(0x183),'enum':[...RISK_LEVEL_VALUES]},{'name':a192_0x123c3f(0x19e),'type':'string','description':a192_0x123c3f(0x182)}];function isRecord(_0x595513){const _0x17a10b=a192_0x123c3f;return!!_0x595513&&typeof _0x595513===_0x17a10b(0x176)&&!Array[_0x17a10b(0x196)](_0x595513);}function assertValidAppcode(_0xc35b38){const _0x248570=a192_0x123c3f,{valid:_0x426066,message:_0x4ef61b}=validateAppcode(_0xc35b38);if(!_0x426066)throw CliErrors[_0x248570(0x187)](_0x248570(0x173)+_0xc35b38,_0x4ef61b);}function sanitizeProfile(_0x2dd2d4){if(!isRecord(_0x2dd2d4))return{};const _0x32b89d={};for(const _0x246ae1 of SAFE_PROFILE_KEYS){if(_0x2dd2d4[_0x246ae1]!==undefined)_0x32b89d[_0x246ae1]=_0x2dd2d4[_0x246ae1];}return _0x32b89d;}function cloneProfile(_0x30567e){return isRecord(_0x30567e)?{..._0x30567e}:{};}function collectWorkspaceProfileOverrides(_0x3bedc8){const _0x25a7e2=a192_0x123c3f,_0x3ee978={},_0x406754=_0x3bedc8['str']('env'),_0xdf2d91=_0x3bedc8['str']('apiDir'),_0x17363b=_0x3bedc8['str']('defaultFormat'),_0xe82f7f=_0x3bedc8[_0x25a7e2(0x16d)]('pageSize'),_0x270206=_0x3bedc8[_0x25a7e2(0x188)]('riskLevel'),_0x2fe9d6=_0x3bedc8['str']('locale');if(_0x406754)_0x3ee978['env']=_0x406754;if(_0xdf2d91)_0x3ee978[_0x25a7e2(0x19d)]=_0xdf2d91;if(_0x17363b)_0x3ee978[_0x25a7e2(0x19f)]=_0x17363b;if(_0xe82f7f!==undefined&&_0xe82f7f!=='')_0x3ee978[_0x25a7e2(0x19b)]=Number(_0xe82f7f);if(_0x270206)_0x3ee978[_0x25a7e2(0x197)]=_0x270206;if(_0x2fe9d6)_0x3ee978['locale']=_0x2fe9d6;return _0x3ee978;}async function validateWorkspaceArgs(_0x2ba6b3){const _0x12fde8=a192_0x123c3f,_0x26e0c1=_0x2ba6b3[_0x12fde8(0x188)]('app')['trim'](),_0x2ded00=_0x2ba6b3['str'](_0x12fde8(0x177))[_0x12fde8(0x186)]();if(!_0x26e0c1&&!_0x2ded00)throw CliErrors[_0x12fde8(0x187)](_0x12fde8(0x170),_0x12fde8(0x179)+CLI_BIN_NAME+'\x20workspace\x20init\x20--appcode\x20<code>`\x20or\x20`'+CLI_BIN_NAME+_0x12fde8(0x168));if(_0x2ded00)assertValidAppcode(_0x2ded00);}function resolveKnownApps(){const _0x171705=a192_0x123c3f,{config:_0x3cbb4d,layers:_0x3e7519}=readRawConfigWithLayers(),_0x654608=isRecord(_0x3cbb4d[_0x171705(0x17d)])?_0x3cbb4d[_0x171705(0x17d)]:{},_0x1b5952=isRecord(_0x3e7519[_0x171705(0x17a)][_0x171705(0x17d)])?_0x3e7519[_0x171705(0x17a)][_0x171705(0x17d)]:{};return{..._0x1b5952,..._0x654608};}async function configureWorkspace(_0x24e16c,_0x5ba6c1){const _0x313f1b=a192_0x123c3f,_0xeaf0d2=_0x24e16c[_0x313f1b(0x188)](_0x313f1b(0x171))['trim'](),_0x5bf998=_0x24e16c['str'](_0x313f1b(0x177))[_0x313f1b(0x186)](),_0x4e8085=_0xeaf0d2||_0x5bf998;if(!_0x4e8085)throw CliErrors[_0x313f1b(0x187)](_0x313f1b(0x170),'Use\x20`'+CLI_BIN_NAME+_0x313f1b(0x18a)+CLI_BIN_NAME+_0x313f1b(0x168));if(_0x5bf998)assertValidAppcode(_0x5bf998);const _0x405805=resolveWriteConfigPath(_0x313f1b(0x178)),_0x2ba002=readConfigFile(_0x405805),_0x55c610=resolveKnownApps(),_0x43a0ff=isRecord(_0x2ba002[_0x313f1b(0x17d)])?{..._0x2ba002[_0x313f1b(0x17d)]}:{},_0x490d33=cloneProfile(_0x43a0ff[_0x4e8085]),_0x51c13c=sanitizeProfile(_0x55c610[_0x4e8085]),_0xda0157=_0x5bf998?{}:_0x51c13c,_0x20f243=_0x5bf998||_0xda0157[_0x313f1b(0x177)];if(!_0x20f243){const _0x4aac19=Object[_0x313f1b(0x169)](_0x55c610),_0x34b0f2=_0x4aac19['length']===0x0?_0x313f1b(0x179)+CLI_BIN_NAME+'\x20workspace\x20'+_0x5ba6c1+_0x313f1b(0x189)+_0x4e8085+'\x20--appcode\x20<code>`.':_0x313f1b(0x181)+_0x4aac19[_0x313f1b(0x198)](',\x20');throw CliErrors[_0x313f1b(0x187)](_0x313f1b(0x180)+_0x4e8085+'\x22\x20not\x20found.',_0x34b0f2);}assertValidAppcode(String(_0x20f243));const _0x22af8d={..._0xda0157,..._0x490d33,'appcode':String(_0x20f243),...collectWorkspaceProfileOverrides(_0x24e16c)};return _0x43a0ff[_0x4e8085]=_0x22af8d,_0x2ba002[_0x313f1b(0x17d)]=_0x43a0ff,_0x2ba002[_0x313f1b(0x16b)]=_0x4e8085,delete _0x2ba002[_0x313f1b(0x177)],delete _0x2ba002[_0x313f1b(0x171)],_0x22af8d[_0x313f1b(0x190)]&&(_0x2ba002['env']=_0x22af8d[_0x313f1b(0x190)]),writeConfigFile(_0x405805,_0x2ba002),{'ok':!![],'message':_0x313f1b(0x172)+(_0x5ba6c1===_0x313f1b(0x191)?_0x313f1b(0x195):_0x313f1b(0x17e))+':\x20'+_0x4e8085+_0x313f1b(0x165)+_0x22af8d[_0x313f1b(0x177)]+_0x313f1b(0x16e)+_0x405805+_0x313f1b(0x192),'data':{'operation':_0x313f1b(0x199)+_0x5ba6c1,'configPath':_0x405805,'app':_0x4e8085,'appcode':_0x22af8d[_0x313f1b(0x177)],'env':_0x22af8d[_0x313f1b(0x190)]??null,'credentialsWritten':![]}};}const workspaceInitDefinition={'service':a192_0x123c3f(0x18f),'command':a192_0x123c3f(0x191),'description':'Initialize\x20the\x20current\x20workspace\x20app\x20binding','risk':a192_0x123c3f(0x167),'requiresAuth':![],'requiresAppCode':![],'args':[],'flags':workspaceFlags,'validate':validateWorkspaceArgs,'execute':_0xcc748f=>configureWorkspace(_0xcc748f,'init')},workspaceUseDefinition={'service':a192_0x123c3f(0x18f),'command':a192_0x123c3f(0x18e),'description':a192_0x123c3f(0x174),'risk':a192_0x123c3f(0x167),'requiresAuth':![],'requiresAppCode':![],'args':[],'flags':workspaceFlags,'validate':validateWorkspaceArgs,'execute':_0x19e0ac=>configureWorkspace(_0x19e0ac,a192_0x123c3f(0x18e))};export const workspaceDefinitions=[workspaceInitDefinition,workspaceUseDefinition,workspaceAddDefinition,workspaceRemoveDefinition];export{WORKSPACE_USAGE};
1
+ const a192_0xa40f16=a192_0xebfa;function a192_0x58f4(){const _0x2e94ad=['2FycxoQ','workspace','\x20--appcode\x20<code>`.','\x20workspace\x20','object','Missing\x20workspace\x20app\x20selector.','app','flag','1139488wQwgxe','validation','globalConfig','str','trim','appcode','Pass\x20--appcode\x20<code>,\x20or\x20choose\x20one\x20of:\x20','env','defaultApp','45rgfmLM','Risk\x20level\x20for\x20this\x20workspace\x20app\x20profile','\x20workspace\x20init\x20--appcode\x20<code>`\x20or\x20`','411830rqRbyH','string','updated','\x20workspace\x20use\x20--app\x20<name>`.','2462733KFIGtL','Default\x20page\x20size\x20for\x20this\x20workspace\x20app\x20profile','apps','110938xZpIXz','App\x20code\x20to\x20bind\x20to\x20this\x20workspace','locale','\x20workspace\x20<init|use>\x20--app\x20<name>\x20[--appcode\x20<code>]','initialized','number','\x20(appcode:\x20','Use\x20`','8XOpBCC','Target\x20environment','6YfmyyK','riskLevel','1972619KJjGIU','Invalid\x20appcode:\x20','format','isArray','Initialize\x20the\x20current\x20workspace\x20app\x20binding','1659770UVAclF','init',').\x20Config:\x20','apiDir','pageSize','Switch\x20the\x20current\x20workspace\x20app\x20binding','.\x20Credentials:\x20not\x20written.','90339MKzGIE','keys','\x22\x20not\x20found.','\x20--app\x20','defaultFormat'];a192_0x58f4=function(){return _0x2e94ad;};return a192_0x58f4();}(function(_0x1cca7f,_0x643f77){const _0x212dd6=a192_0xebfa,_0x2483b5=_0x1cca7f();while(!![]){try{const _0x93d7ee=parseInt(_0x212dd6(0x1da))/0x1*(parseInt(_0x212dd6(0x1f5))/0x2)+-parseInt(_0x212dd6(0x1d5))/0x3*(parseInt(_0x212dd6(0x1c5))/0x4)+parseInt(_0x212dd6(0x1ce))/0x5+parseInt(_0x212dd6(0x1c7))/0x6*(parseInt(_0x212dd6(0x1f2))/0x7)+-parseInt(_0x212dd6(0x1e2))/0x8+parseInt(_0x212dd6(0x1eb))/0x9*(-parseInt(_0x212dd6(0x1ee))/0xa)+-parseInt(_0x212dd6(0x1c9))/0xb;if(_0x93d7ee===_0x643f77)break;else _0x2483b5['push'](_0x2483b5['shift']());}catch(_0x20f73e){_0x2483b5['push'](_0x2483b5['shift']());}}}(a192_0x58f4,0x327d5));import{CliErrors}from'../../errors.js';import{CLI_BIN_NAME}from'../../constant/cli.js';import{RABETBASE_ENV_VALUES}from'../../constant/env.js';import{RABETBASE_OUTPUT_FORMAT_VALUES}from'../../constant/output.js';import{RISK_LEVEL_VALUES}from'../../constant/risk.js';import{validateAppcode}from'../../commands/common/validate.js';import{readConfigFile,readRawConfigWithLayers,resolveWriteConfigPath,writeConfigFile}from'../../context.js';import{workspaceAddDefinition}from'../../commands/workspace/add.js';import{workspaceRemoveDefinition}from'../../commands/workspace/remove.js';const WORKSPACE_USAGE=CLI_BIN_NAME+a192_0xa40f16(0x1f8),SAFE_PROFILE_KEYS=[a192_0xa40f16(0x1e7),a192_0xa40f16(0x1e9),a192_0xa40f16(0x1d1),'format',a192_0xa40f16(0x1d2),a192_0xa40f16(0x1c8),'locale'],workspaceFlags=[{'name':'app','type':a192_0xa40f16(0x1ef),'description':'App\x20profile\x20name\x20to\x20use\x20in\x20this\x20workspace'},{'name':a192_0xa40f16(0x1e7),'type':'string','description':a192_0xa40f16(0x1f6)},{'name':a192_0xa40f16(0x1e9),'type':a192_0xa40f16(0x1ef),'description':a192_0xa40f16(0x1c6),'enum':[...RABETBASE_ENV_VALUES]},{'name':a192_0xa40f16(0x1d1),'type':a192_0xa40f16(0x1ef),'description':'API\x20directory\x20path\x20for\x20this\x20workspace\x20app\x20profile'},{'name':a192_0xa40f16(0x1d9),'type':'string','description':'Default\x20output\x20format\x20for\x20this\x20workspace\x20app\x20profile','enum':[...RABETBASE_OUTPUT_FORMAT_VALUES]},{'name':a192_0xa40f16(0x1d2),'type':a192_0xa40f16(0x1c2),'description':a192_0xa40f16(0x1f3)},{'name':'riskLevel','type':a192_0xa40f16(0x1ef),'description':a192_0xa40f16(0x1ec),'enum':[...RISK_LEVEL_VALUES]},{'name':'locale','type':a192_0xa40f16(0x1ef),'description':'Locale\x20for\x20this\x20workspace\x20app\x20profile'}];function isRecord(_0x6968cd){const _0x3122dd=a192_0xa40f16;return!!_0x6968cd&&typeof _0x6968cd===_0x3122dd(0x1de)&&!Array[_0x3122dd(0x1cc)](_0x6968cd);}function assertValidAppcode(_0xc256e0){const _0x3c90a8=a192_0xa40f16,{valid:_0x16b9a5,message:_0x2035d9}=validateAppcode(_0xc256e0);if(!_0x16b9a5)throw CliErrors[_0x3c90a8(0x1e3)](_0x3c90a8(0x1ca)+_0xc256e0,_0x2035d9);}function sanitizeProfile(_0x5b4a73){if(!isRecord(_0x5b4a73))return{};const _0x2c783f={};for(const _0x1d032c of SAFE_PROFILE_KEYS){if(_0x5b4a73[_0x1d032c]!==undefined)_0x2c783f[_0x1d032c]=_0x5b4a73[_0x1d032c];}return _0x2c783f;}function cloneProfile(_0x5a35d2){return isRecord(_0x5a35d2)?{..._0x5a35d2}:{};}function collectWorkspaceProfileOverrides(_0x296d66){const _0x1488e5=a192_0xa40f16,_0xbbbf32={},_0x3f7a0e=_0x296d66[_0x1488e5(0x1e5)](_0x1488e5(0x1e9)),_0x301f44=_0x296d66['str'](_0x1488e5(0x1d1)),_0x25592d=_0x296d66[_0x1488e5(0x1e5)](_0x1488e5(0x1d9)),_0x4dc0fc=_0x296d66[_0x1488e5(0x1e1)](_0x1488e5(0x1d2)),_0xa21e33=_0x296d66[_0x1488e5(0x1e5)]('riskLevel'),_0x506c48=_0x296d66['str'](_0x1488e5(0x1f7));if(_0x3f7a0e)_0xbbbf32['env']=_0x3f7a0e;if(_0x301f44)_0xbbbf32[_0x1488e5(0x1d1)]=_0x301f44;if(_0x25592d)_0xbbbf32[_0x1488e5(0x1cb)]=_0x25592d;if(_0x4dc0fc!==undefined&&_0x4dc0fc!=='')_0xbbbf32[_0x1488e5(0x1d2)]=Number(_0x4dc0fc);if(_0xa21e33)_0xbbbf32[_0x1488e5(0x1c8)]=_0xa21e33;if(_0x506c48)_0xbbbf32['locale']=_0x506c48;return _0xbbbf32;}function a192_0xebfa(_0x2c8cb2,_0x1fcf0d){_0x2c8cb2=_0x2c8cb2-0x1c2;const _0x58f432=a192_0x58f4();let _0xebfade=_0x58f432[_0x2c8cb2];return _0xebfade;}async function validateWorkspaceArgs(_0x52dce1){const _0x545739=a192_0xa40f16,_0x160fb7=_0x52dce1['str']('app')[_0x545739(0x1e6)](),_0x467d26=_0x52dce1[_0x545739(0x1e5)]('appcode')[_0x545739(0x1e6)]();if(!_0x160fb7&&!_0x467d26)throw CliErrors[_0x545739(0x1e3)]('Missing\x20workspace\x20app\x20selector.',_0x545739(0x1c4)+CLI_BIN_NAME+_0x545739(0x1ed)+CLI_BIN_NAME+_0x545739(0x1f1));if(_0x467d26)assertValidAppcode(_0x467d26);}function resolveKnownApps(){const _0x11ecb2=a192_0xa40f16,{config:_0x4f5291,layers:_0x247982}=readRawConfigWithLayers(),_0x3ae7c6=isRecord(_0x4f5291[_0x11ecb2(0x1f4)])?_0x4f5291[_0x11ecb2(0x1f4)]:{},_0x153bb6=isRecord(_0x247982[_0x11ecb2(0x1e4)][_0x11ecb2(0x1f4)])?_0x247982['globalConfig'][_0x11ecb2(0x1f4)]:{};return{..._0x153bb6,..._0x3ae7c6};}async function configureWorkspace(_0x47db71,_0x19471b){const _0x59bc9b=a192_0xa40f16,_0x5badaa=_0x47db71[_0x59bc9b(0x1e5)](_0x59bc9b(0x1e0))[_0x59bc9b(0x1e6)](),_0x2a89a1=_0x47db71[_0x59bc9b(0x1e5)](_0x59bc9b(0x1e7))['trim'](),_0xa5450=_0x5badaa||_0x2a89a1;if(!_0xa5450)throw CliErrors[_0x59bc9b(0x1e3)](_0x59bc9b(0x1df),_0x59bc9b(0x1c4)+CLI_BIN_NAME+'\x20workspace\x20init\x20--appcode\x20<code>`\x20or\x20`'+CLI_BIN_NAME+'\x20workspace\x20use\x20--app\x20<name>`.');if(_0x2a89a1)assertValidAppcode(_0x2a89a1);const _0xcaee9c=resolveWriteConfigPath('project'),_0x432a50=readConfigFile(_0xcaee9c),_0x53d8d7=resolveKnownApps(),_0x3ba9b2=isRecord(_0x432a50[_0x59bc9b(0x1f4)])?{..._0x432a50[_0x59bc9b(0x1f4)]}:{},_0xc2cc9=cloneProfile(_0x3ba9b2[_0xa5450]),_0xf774f4=sanitizeProfile(_0x53d8d7[_0xa5450]),_0x5a727c=_0x2a89a1?{}:_0xf774f4,_0xf504e2=_0x2a89a1||_0x5a727c['appcode'];if(!_0xf504e2){const _0xe7bcff=Object[_0x59bc9b(0x1d6)](_0x53d8d7),_0x53ed1c=_0xe7bcff['length']===0x0?_0x59bc9b(0x1c4)+CLI_BIN_NAME+_0x59bc9b(0x1dd)+_0x19471b+_0x59bc9b(0x1d8)+_0xa5450+_0x59bc9b(0x1dc):_0x59bc9b(0x1e8)+_0xe7bcff['join'](',\x20');throw CliErrors[_0x59bc9b(0x1e3)]('App\x20\x22'+_0xa5450+_0x59bc9b(0x1d7),_0x53ed1c);}assertValidAppcode(String(_0xf504e2));const _0x3c0240={..._0x5a727c,..._0xc2cc9,'appcode':String(_0xf504e2),...collectWorkspaceProfileOverrides(_0x47db71)};return _0x3ba9b2[_0xa5450]=_0x3c0240,_0x432a50[_0x59bc9b(0x1f4)]=_0x3ba9b2,_0x432a50[_0x59bc9b(0x1ea)]=_0xa5450,delete _0x432a50['appcode'],delete _0x432a50[_0x59bc9b(0x1e0)],_0x3c0240['env']&&(_0x432a50['env']=_0x3c0240[_0x59bc9b(0x1e9)]),writeConfigFile(_0xcaee9c,_0x432a50),{'ok':!![],'message':'Workspace\x20'+(_0x19471b===_0x59bc9b(0x1cf)?_0x59bc9b(0x1f9):_0x59bc9b(0x1f0))+':\x20'+_0xa5450+_0x59bc9b(0x1c3)+_0x3c0240[_0x59bc9b(0x1e7)]+_0x59bc9b(0x1d0)+_0xcaee9c+_0x59bc9b(0x1d4),'data':{'operation':'workspace.'+_0x19471b,'configPath':_0xcaee9c,'app':_0xa5450,'appcode':_0x3c0240[_0x59bc9b(0x1e7)],'env':_0x3c0240['env']??null,'credentialsWritten':![]}};}const workspaceInitDefinition={'service':'workspace','command':a192_0xa40f16(0x1cf),'description':a192_0xa40f16(0x1cd),'risk':'write','requiresAuth':![],'requiresAppCode':![],'args':[],'flags':workspaceFlags,'validate':validateWorkspaceArgs,'execute':_0x5830a4=>configureWorkspace(_0x5830a4,a192_0xa40f16(0x1cf))},workspaceUseDefinition={'service':a192_0xa40f16(0x1db),'command':'use','description':a192_0xa40f16(0x1d3),'risk':'write','requiresAuth':![],'requiresAppCode':![],'args':[],'flags':workspaceFlags,'validate':validateWorkspaceArgs,'execute':_0x377ce8=>configureWorkspace(_0x377ce8,'use')};export const workspaceDefinitions=[workspaceInitDefinition,workspaceUseDefinition,workspaceAddDefinition,workspaceRemoveDefinition];export{WORKSPACE_USAGE};
@@ -0,0 +1,6 @@
1
+ /**
2
+ * rabetbase workspace remove <name>
3
+ * 从当前工作环境(默认当前项目,`--global` 则全局)移除一个应用 profile。
4
+ */
5
+ import type { CommandDefinition } from "../../framework/types.js";
6
+ export declare const workspaceRemoveDefinition: CommandDefinition;
@@ -1 +1 @@
1
- const a193_0x54532f=a193_0xb7c4;function a193_0xb7c4(_0x487d43,_0x2c548f){_0x487d43=_0x487d43-0xcd;const _0x5cad4f=a193_0x5cad();let _0xb7c45b=_0x5cad4f[_0x487d43];return _0xb7c45b;}(function(_0x44c9f2,_0x28feb0){const _0x2a8ed1=a193_0xb7c4,_0x151fa2=_0x44c9f2();while(!![]){try{const _0x32b27d=-parseInt(_0x2a8ed1(0xcf))/0x1+parseInt(_0x2a8ed1(0xd8))/0x2*(parseInt(_0x2a8ed1(0xd1))/0x3)+-parseInt(_0x2a8ed1(0xd2))/0x4*(parseInt(_0x2a8ed1(0xda))/0x5)+-parseInt(_0x2a8ed1(0xd4))/0x6+parseInt(_0x2a8ed1(0xce))/0x7+parseInt(_0x2a8ed1(0xdb))/0x8*(parseInt(_0x2a8ed1(0xdc))/0x9)+-parseInt(_0x2a8ed1(0xd3))/0xa;if(_0x32b27d===_0x28feb0)break;else _0x151fa2['push'](_0x151fa2['shift']());}catch(_0xf24d48){_0x151fa2['push'](_0x151fa2['shift']());}}}(a193_0x5cad,0x9c548));function a193_0x5cad(){const _0x25e960=['964893fFqKxJ','5756XutERc','741560kOoDvG','489042NjuJOZ','remove','workspace\x20remove','name','2AWzGDP','App\x20profile\x20name\x20to\x20remove','2255OdDCdZ','10140728nFMsqc','9GswmUl','workspace','write','6500200aqdgon','1072842MBXYIi','Remove\x20an\x20app\x20profile\x20from\x20the\x20current\x20workspace\x20(or\x20--global)'];a193_0x5cad=function(){return _0x25e960;};return a193_0x5cad();}import{buildAppRemoveFlags,runAppRemove,validateAppName}from'../../commands/common/app-registry.js';export const workspaceRemoveDefinition={'service':a193_0x54532f(0xdd),'command':a193_0x54532f(0xd5),'description':a193_0x54532f(0xd0),'risk':a193_0x54532f(0xcd),'requiresAuth':![],'requiresAppCode':![],'args':[{'name':a193_0x54532f(0xd7),'description':a193_0x54532f(0xd9),'required':!![]}],'flags':buildAppRemoveFlags(),'validate':_0x5e4d50=>validateAppName(_0x5e4d50,a193_0x54532f(0xd6)),'execute':_0x381b4c=>runAppRemove(_0x381b4c,a193_0x54532f(0xd6))};
1
+ const a193_0x746d20=a193_0x408a;(function(_0x21a1dd,_0xa62ecb){const _0x2390e0=a193_0x408a,_0x2a89be=_0x21a1dd();while(!![]){try{const _0x54b222=parseInt(_0x2390e0(0x142))/0x1*(parseInt(_0x2390e0(0x14d))/0x2)+-parseInt(_0x2390e0(0x14c))/0x3*(parseInt(_0x2390e0(0x14b))/0x4)+-parseInt(_0x2390e0(0x146))/0x5*(-parseInt(_0x2390e0(0x13f))/0x6)+-parseInt(_0x2390e0(0x145))/0x7+parseInt(_0x2390e0(0x144))/0x8+parseInt(_0x2390e0(0x143))/0x9*(parseInt(_0x2390e0(0x147))/0xa)+parseInt(_0x2390e0(0x14e))/0xb*(-parseInt(_0x2390e0(0x14a))/0xc);if(_0x54b222===_0xa62ecb)break;else _0x2a89be['push'](_0x2a89be['shift']());}catch(_0x51318d){_0x2a89be['push'](_0x2a89be['shift']());}}}(a193_0x49cd,0x52996));import{buildAppRemoveFlags,runAppRemove,validateAppName}from'../../commands/common/app-registry.js';function a193_0x49cd(){const _0x313b7e=['write','307534rsKqVt','639XJjWTS','4168840nsNNfL','1047088ThGGTD','345Twekaf','9590fizNnx','workspace\x20remove','name','60pgDkDI','1452ZpvSDH','1560TwrLch','2wHMlmT','1736174vvhwXj','49488cLAlBj','App\x20profile\x20name\x20to\x20remove'];a193_0x49cd=function(){return _0x313b7e;};return a193_0x49cd();}function a193_0x408a(_0x161786,_0x2bbd47){_0x161786=_0x161786-0x13f;const _0x49cdb8=a193_0x49cd();let _0x408ace=_0x49cdb8[_0x161786];return _0x408ace;}export const workspaceRemoveDefinition={'service':'workspace','command':'remove','description':'Remove\x20an\x20app\x20profile\x20from\x20the\x20current\x20workspace\x20(or\x20--global)','risk':a193_0x746d20(0x141),'requiresAuth':![],'requiresAppCode':![],'args':[{'name':a193_0x746d20(0x149),'description':a193_0x746d20(0x140),'required':!![]}],'flags':buildAppRemoveFlags(),'validate':_0x1b5ba1=>validateAppName(_0x1b5ba1,a193_0x746d20(0x148)),'execute':_0x52fe38=>runAppRemove(_0x52fe38,a193_0x746d20(0x148))};
@@ -0,0 +1,50 @@
1
+ import type { FlagDef } from "../framework/types.js";
2
+ export { DEFAULT_CONFIG_VALUES } from "../constant/defaults.js";
3
+ export declare const PROJECT_CREATE_INHERITABLE_KEYS: readonly ["cookie", "accessKey", "locale", "format", "riskLevel"];
4
+ export interface ConfigMetadataFields {
5
+ version?: string;
6
+ createdAt?: string;
7
+ migratedAt?: string;
8
+ migratedFrom?: string;
9
+ }
10
+ export declare const TOP_LEVEL_CONFIG_KEYS: Set<string>;
11
+ export declare const CONFIG_ENUM_VALUES: Record<string, string[]>;
12
+ export declare function formatConfigKeyList(keys: Iterable<string>): string;
13
+ export declare function getTopLevelConfigKeyList(): string[];
14
+ export declare function isTopLevelConfigKey(key: string): boolean;
15
+ export declare function getTopLevelConfigKeySummary(): string;
16
+ export declare function getConfigCommandKeyDescription(): string;
17
+ export declare const APP_PROFILE_FLAG_KEY_MAP: Record<string, string>;
18
+ export declare function getAppProfileFlagDefs(): FlagDef[];
19
+ export declare function collectAppProfileOverrides(getFlagValue: (name: string) => string): Record<string, any>;
20
+ export declare function buildAppProfileListFields(profile: Record<string, any>): Record<string, unknown>;
21
+ export declare function buildAppDoctorFields(profile: Record<string, any>, effective: {
22
+ env: string;
23
+ apiDir: string;
24
+ cookie?: string;
25
+ accessKey?: string;
26
+ }): {
27
+ env: {
28
+ value: string;
29
+ source: "app" | "inherit";
30
+ };
31
+ apiDir: {
32
+ value: string;
33
+ source: "app" | "inherit";
34
+ };
35
+ cookie: {
36
+ value?: string;
37
+ source: "app" | "inherit";
38
+ };
39
+ accessKey: {
40
+ value?: string;
41
+ source: "app" | "inherit";
42
+ };
43
+ };
44
+ export declare function buildCanonicalAppConfig(appCodes: string[], env?: string): Record<string, any>;
45
+ export declare function buildCanonicalProjectConfig(base: Record<string, unknown>, options: {
46
+ appCodes?: string[];
47
+ env?: string;
48
+ metadata?: ConfigMetadataFields;
49
+ }): Record<string, any>;
50
+ export declare function normalizeLocale(value: string): "zh-CN" | "en-US" | null;
@@ -1 +1 @@
1
- const a194_0x74540a=a194_0x5949;(function(_0x346251,_0x3a0f9e){const _0x197272=a194_0x5949,_0x12c576=_0x346251();while(!![]){try{const _0x3cd4d9=parseInt(_0x197272(0x197))/0x1*(parseInt(_0x197272(0x1b8))/0x2)+-parseInt(_0x197272(0x1a1))/0x3+parseInt(_0x197272(0x1a4))/0x4*(-parseInt(_0x197272(0x1a9))/0x5)+parseInt(_0x197272(0x1ac))/0x6*(-parseInt(_0x197272(0x1a0))/0x7)+-parseInt(_0x197272(0x198))/0x8+parseInt(_0x197272(0x1af))/0x9*(-parseInt(_0x197272(0x1ae))/0xa)+parseInt(_0x197272(0x1ab))/0xb;if(_0x3cd4d9===_0x3a0f9e)break;else _0x12c576['push'](_0x12c576['shift']());}catch(_0x187fc9){_0x12c576['push'](_0x12c576['shift']());}}}(a194_0x4dce,0xe3235));import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';import{RABETBASE_ENV_VALUES}from'../constant/env.js';import{RABETBASE_OUTPUT_FORMAT_VALUES}from'../constant/output.js';import{RISK_LEVEL_VALUES}from'../constant/risk.js';export{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';function a194_0x4dce(){const _0x41f16d=['apiDir','52684940koHhHv','5682DfVwHR','format','44370CEWDty','1413jTMpYv','defaultApp','accessKey','riskLevel','app','locale','inherit','Auth\x20cookie','Config\x20key\x20(','6xfwrIi','zh-CN','cookie','trim','join','Access\x20key','pageSize','string','Default\x20page\x20size','Locale','env','102965ItACKp','8677744iXYeYA','number','defaultFormat','en-US','length','toLowerCase','apps','filter','7462CLRASZ','2429622tFpZpt','Target\x20environment','Risk\x20level','100sGmBfj','API\x20directory\x20path','keys','has','appcode','113475ddvoon'];a194_0x4dce=function(){return _0x41f16d;};return a194_0x4dce();}export const PROJECT_CREATE_INHERITABLE_KEYS=[a194_0x74540a(0x18e),a194_0x74540a(0x1b1),a194_0x74540a(0x1b4),'format',a194_0x74540a(0x1b2)];export const TOP_LEVEL_CONFIG_KEYS=new Set(['appcode',a194_0x74540a(0x196),a194_0x74540a(0x1b4),a194_0x74540a(0x1ad),a194_0x74540a(0x18e),a194_0x74540a(0x1b1),'apiDir']);export const CONFIG_ENUM_VALUES={'env':[...RABETBASE_ENV_VALUES],'format':[...RABETBASE_OUTPUT_FORMAT_VALUES]};export function formatConfigKeyList(_0x137b8e){const _0x111f5d=a194_0x74540a;return[..._0x137b8e][_0x111f5d(0x190)](',\x20');}export function getTopLevelConfigKeyList(){return[...TOP_LEVEL_CONFIG_KEYS];}export function isTopLevelConfigKey(_0x3d860d){const _0x44c23f=a194_0x74540a;return TOP_LEVEL_CONFIG_KEYS[_0x44c23f(0x1a7)](_0x3d860d);}export function getTopLevelConfigKeySummary(){return formatConfigKeyList(getTopLevelConfigKeyList());}export function getConfigCommandKeyDescription(){const _0x3d9ae0=a194_0x74540a;return _0x3d9ae0(0x1b7)+getTopLevelConfigKeySummary()+')';}export const APP_PROFILE_FLAG_KEY_MAP={'env':a194_0x74540a(0x196),'apiDir':'apiDir','cookie':a194_0x74540a(0x18e),'accessKey':a194_0x74540a(0x1b1),'defaultFormat':a194_0x74540a(0x1ad),'pageSize':'pageSize','riskLevel':a194_0x74540a(0x1b2),'locale':a194_0x74540a(0x1b4)};export function getAppProfileFlagDefs(){const _0x1002d0=a194_0x74540a;return[{'name':_0x1002d0(0x196),'type':'string','description':_0x1002d0(0x1a2),'enum':[...RABETBASE_ENV_VALUES]},{'name':'apiDir','type':'string','description':_0x1002d0(0x1a5)},{'name':_0x1002d0(0x18e),'type':_0x1002d0(0x193),'description':_0x1002d0(0x1b6),'hidden':!![]},{'name':_0x1002d0(0x1b1),'type':_0x1002d0(0x193),'description':_0x1002d0(0x191),'hidden':!![]},{'name':_0x1002d0(0x19a),'type':_0x1002d0(0x193),'description':'Default\x20output\x20format\x20for\x20this\x20app\x20(profile)','enum':[...RABETBASE_OUTPUT_FORMAT_VALUES]},{'name':_0x1002d0(0x192),'type':_0x1002d0(0x199),'description':_0x1002d0(0x194)},{'name':_0x1002d0(0x1b2),'type':_0x1002d0(0x193),'description':_0x1002d0(0x1a3),'enum':[...RISK_LEVEL_VALUES]},{'name':_0x1002d0(0x1b4),'type':_0x1002d0(0x193),'description':_0x1002d0(0x195)}];}export function collectAppProfileOverrides(_0x6513a2){const _0xe0ac60=a194_0x74540a,_0xc20016={};for(const [_0x5e42cf,_0x5d854d]of Object['entries'](APP_PROFILE_FLAG_KEY_MAP)){const _0x30f759=_0x6513a2(_0x5e42cf);if(!_0x30f759)continue;_0xc20016[_0x5d854d]=_0x5d854d===_0xe0ac60(0x192)?Number(_0x30f759):_0x30f759;}return _0xc20016;}export function buildAppProfileListFields(_0xab5833){const _0x556d48=a194_0x74540a;return{'env':_0xab5833['env']??null,'apiDir':_0xab5833[_0x556d48(0x1aa)]??null,'hasCookie':!!_0xab5833['cookie'],'hasAccessKey':!!_0xab5833[_0x556d48(0x1b1)],'format':_0xab5833[_0x556d48(0x1ad)]??null,'pageSize':_0xab5833[_0x556d48(0x192)]??null,'riskLevel':_0xab5833['riskLevel']??null,'locale':_0xab5833[_0x556d48(0x1b4)]??null};}export function buildAppDoctorFields(_0x10e88f,_0x5e82a2){const _0x442011=a194_0x74540a;return{'env':{'value':_0x10e88f['env']||_0x5e82a2[_0x442011(0x196)],'source':_0x10e88f[_0x442011(0x196)]?'app':'inherit'},'apiDir':{'value':_0x10e88f[_0x442011(0x1aa)]||_0x5e82a2[_0x442011(0x1aa)],'source':_0x10e88f[_0x442011(0x1aa)]?_0x442011(0x1b3):_0x442011(0x1b5)},'cookie':{'value':_0x10e88f[_0x442011(0x18e)]||_0x5e82a2[_0x442011(0x18e)],'source':_0x10e88f[_0x442011(0x18e)]?'app':'inherit'},'accessKey':{'value':_0x10e88f[_0x442011(0x1b1)]||_0x5e82a2[_0x442011(0x1b1)],'source':_0x10e88f[_0x442011(0x1b1)]?'app':_0x442011(0x1b5)}};}function a194_0x5949(_0x2088c5,_0x57dd37){_0x2088c5=_0x2088c5-0x18e;const _0x4dce25=a194_0x4dce();let _0x594922=_0x4dce25[_0x2088c5];return _0x594922;}export function buildCanonicalAppConfig(_0xd34ff1,_0x231835){const _0x4ebe5a=a194_0x74540a,_0x2cbe99=_0xd34ff1['map'](_0x337ea=>String(_0x337ea||'')[_0x4ebe5a(0x18f)]())[_0x4ebe5a(0x19f)](Boolean);if(_0x2cbe99['length']===0x0)return{};const _0x523fb8={};for(const _0x30f6c1 of _0x2cbe99){_0x523fb8[_0x30f6c1]=_0x231835?{'appcode':_0x30f6c1,'env':_0x231835}:{'appcode':_0x30f6c1};}return{'apps':_0x523fb8,'defaultApp':_0x2cbe99[0x0]};}export function buildCanonicalProjectConfig(_0x4c15d8,_0xaa6750){const _0x21d2e9=a194_0x74540a,{appCodes:appCodes=[],env:_0x4a342a,metadata:_0x3ffa3a}=_0xaa6750,_0x15d5cc={..._0x4c15d8,..._0x3ffa3a||{}};delete _0x15d5cc[_0x21d2e9(0x1a8)],delete _0x15d5cc['app'];if(_0x4a342a)_0x15d5cc[_0x21d2e9(0x196)]=_0x4a342a;else!_0x15d5cc[_0x21d2e9(0x196)]&&(_0x15d5cc['env']=DEFAULT_CONFIG_VALUES[_0x21d2e9(0x196)]);const _0x4989ca=buildCanonicalAppConfig(appCodes,_0x15d5cc[_0x21d2e9(0x196)]);return Object[_0x21d2e9(0x1a6)](_0x4989ca)[_0x21d2e9(0x19c)]>0x0&&(_0x15d5cc[_0x21d2e9(0x19e)]=_0x4989ca[_0x21d2e9(0x19e)],_0x15d5cc[_0x21d2e9(0x1b0)]=_0x4989ca[_0x21d2e9(0x1b0)]),_0x15d5cc;}const LOCALE_MAP={'zh':a194_0x74540a(0x1b9),'zh-cn':a194_0x74540a(0x1b9),'zh_cn':a194_0x74540a(0x1b9),'en':a194_0x74540a(0x19b),'en-us':a194_0x74540a(0x19b),'en_us':'en-US'};export function normalizeLocale(_0x255c9a){const _0x5829a0=a194_0x74540a;if(!_0x255c9a)return null;return LOCALE_MAP[_0x255c9a[_0x5829a0(0x19d)]()]??null;}
1
+ const a194_0x5e5c23=a194_0x55e2;(function(_0x1dbdb0,_0x49489c){const _0x28783f=a194_0x55e2,_0x551331=_0x1dbdb0();while(!![]){try{const _0x4cfa54=parseInt(_0x28783f(0x173))/0x1*(parseInt(_0x28783f(0x169))/0x2)+-parseInt(_0x28783f(0x179))/0x3+-parseInt(_0x28783f(0x16d))/0x4+parseInt(_0x28783f(0x178))/0x5*(-parseInt(_0x28783f(0x161))/0x6)+parseInt(_0x28783f(0x168))/0x7+-parseInt(_0x28783f(0x17e))/0x8+parseInt(_0x28783f(0x172))/0x9;if(_0x4cfa54===_0x49489c)break;else _0x551331['push'](_0x551331['shift']());}catch(_0x13be34){_0x551331['push'](_0x551331['shift']());}}}(a194_0x39e5,0x60b69));import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';import{RABETBASE_ENV_VALUES}from'../constant/env.js';import{RABETBASE_OUTPUT_FORMAT_VALUES}from'../constant/output.js';import{RISK_LEVEL_VALUES}from'../constant/risk.js';function a194_0x55e2(_0x3598e2,_0x5c2755){_0x3598e2=_0x3598e2-0x15d;const _0x39e55f=a194_0x39e5();let _0x55e29e=_0x39e55f[_0x3598e2];return _0x55e29e;}export{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';export const PROJECT_CREATE_INHERITABLE_KEYS=[a194_0x5e5c23(0x17d),a194_0x5e5c23(0x17b),a194_0x5e5c23(0x182),'format',a194_0x5e5c23(0x165)];function a194_0x39e5(){const _0x4a3155=['Auth\x20cookie','9273357UKLpxl','1BFuZwC','inherit','string','keys','Default\x20page\x20size','155PlxdEM','1657275nHXdaA','zh-CN','accessKey','filter','cookie','1917544BMmSnB','Config\x20key\x20(','length','app','locale','apps','Access\x20key','appcode','Default\x20output\x20format\x20for\x20this\x20app\x20(profile)','entries','en-US','25884whJPYG','map','format','defaultApp','riskLevel','join','apiDir','2249940qmrJtM','631226RDgSBA','API\x20directory\x20path','pageSize','toLowerCase','1381668KQskUA','Risk\x20level','env','defaultFormat'];a194_0x39e5=function(){return _0x4a3155;};return a194_0x39e5();}export const TOP_LEVEL_CONFIG_KEYS=new Set([a194_0x5e5c23(0x15d),a194_0x5e5c23(0x16f),'locale','format',a194_0x5e5c23(0x17d),a194_0x5e5c23(0x17b),a194_0x5e5c23(0x167)]);export const CONFIG_ENUM_VALUES={'env':[...RABETBASE_ENV_VALUES],'format':[...RABETBASE_OUTPUT_FORMAT_VALUES]};export function formatConfigKeyList(_0x99b40f){const _0x41fddc=a194_0x5e5c23;return[..._0x99b40f][_0x41fddc(0x166)](',\x20');}export function getTopLevelConfigKeyList(){return[...TOP_LEVEL_CONFIG_KEYS];}export function isTopLevelConfigKey(_0x118ec9){return TOP_LEVEL_CONFIG_KEYS['has'](_0x118ec9);}export function getTopLevelConfigKeySummary(){return formatConfigKeyList(getTopLevelConfigKeyList());}export function getConfigCommandKeyDescription(){const _0x3a851e=a194_0x5e5c23;return _0x3a851e(0x17f)+getTopLevelConfigKeySummary()+')';}export const APP_PROFILE_FLAG_KEY_MAP={'env':a194_0x5e5c23(0x16f),'apiDir':'apiDir','cookie':a194_0x5e5c23(0x17d),'accessKey':'accessKey','defaultFormat':a194_0x5e5c23(0x163),'pageSize':a194_0x5e5c23(0x16b),'riskLevel':a194_0x5e5c23(0x165),'locale':a194_0x5e5c23(0x182)};export function getAppProfileFlagDefs(){const _0x1f4818=a194_0x5e5c23;return[{'name':_0x1f4818(0x16f),'type':_0x1f4818(0x175),'description':'Target\x20environment','enum':[...RABETBASE_ENV_VALUES]},{'name':_0x1f4818(0x167),'type':_0x1f4818(0x175),'description':_0x1f4818(0x16a)},{'name':_0x1f4818(0x17d),'type':_0x1f4818(0x175),'description':_0x1f4818(0x171),'hidden':!![]},{'name':_0x1f4818(0x17b),'type':_0x1f4818(0x175),'description':_0x1f4818(0x184),'hidden':!![]},{'name':_0x1f4818(0x170),'type':_0x1f4818(0x175),'description':_0x1f4818(0x15e),'enum':[...RABETBASE_OUTPUT_FORMAT_VALUES]},{'name':'pageSize','type':'number','description':_0x1f4818(0x177)},{'name':_0x1f4818(0x165),'type':_0x1f4818(0x175),'description':_0x1f4818(0x16e),'enum':[...RISK_LEVEL_VALUES]},{'name':_0x1f4818(0x182),'type':'string','description':'Locale'}];}export function collectAppProfileOverrides(_0x44ebbd){const _0x5c398d=a194_0x5e5c23,_0x259c00={};for(const [_0x2ebce0,_0xae9a87]of Object[_0x5c398d(0x15f)](APP_PROFILE_FLAG_KEY_MAP)){const _0x2b26fb=_0x44ebbd(_0x2ebce0);if(!_0x2b26fb)continue;_0x259c00[_0xae9a87]=_0xae9a87===_0x5c398d(0x16b)?Number(_0x2b26fb):_0x2b26fb;}return _0x259c00;}export function buildAppProfileListFields(_0x19bd45){const _0x58debb=a194_0x5e5c23;return{'env':_0x19bd45[_0x58debb(0x16f)]??null,'apiDir':_0x19bd45[_0x58debb(0x167)]??null,'hasCookie':!!_0x19bd45[_0x58debb(0x17d)],'hasAccessKey':!!_0x19bd45['accessKey'],'format':_0x19bd45[_0x58debb(0x163)]??null,'pageSize':_0x19bd45[_0x58debb(0x16b)]??null,'riskLevel':_0x19bd45[_0x58debb(0x165)]??null,'locale':_0x19bd45[_0x58debb(0x182)]??null};}export function buildAppDoctorFields(_0x4a27c3,_0x496d22){const _0x14e153=a194_0x5e5c23;return{'env':{'value':_0x4a27c3[_0x14e153(0x16f)]||_0x496d22['env'],'source':_0x4a27c3[_0x14e153(0x16f)]?_0x14e153(0x181):_0x14e153(0x174)},'apiDir':{'value':_0x4a27c3[_0x14e153(0x167)]||_0x496d22['apiDir'],'source':_0x4a27c3['apiDir']?_0x14e153(0x181):'inherit'},'cookie':{'value':_0x4a27c3['cookie']||_0x496d22[_0x14e153(0x17d)],'source':_0x4a27c3['cookie']?'app':'inherit'},'accessKey':{'value':_0x4a27c3[_0x14e153(0x17b)]||_0x496d22['accessKey'],'source':_0x4a27c3[_0x14e153(0x17b)]?_0x14e153(0x181):'inherit'}};}export function buildCanonicalAppConfig(_0x47f949,_0x4de7e7){const _0x20c203=a194_0x5e5c23,_0x2bec36=_0x47f949[_0x20c203(0x162)](_0xf29d90=>String(_0xf29d90||'')['trim']())[_0x20c203(0x17c)](Boolean);if(_0x2bec36[_0x20c203(0x180)]===0x0)return{};const _0x396bd6={};for(const _0x4d506c of _0x2bec36){_0x396bd6[_0x4d506c]=_0x4de7e7?{'appcode':_0x4d506c,'env':_0x4de7e7}:{'appcode':_0x4d506c};}return{'apps':_0x396bd6,'defaultApp':_0x2bec36[0x0]};}export function buildCanonicalProjectConfig(_0x5a8cf0,_0x53a030){const _0x3ffd33=a194_0x5e5c23,{appCodes:appCodes=[],env:_0x59b64b,metadata:_0x1022d8}=_0x53a030,_0x28d3c4={..._0x5a8cf0,..._0x1022d8||{}};delete _0x28d3c4[_0x3ffd33(0x15d)],delete _0x28d3c4[_0x3ffd33(0x181)];if(_0x59b64b)_0x28d3c4[_0x3ffd33(0x16f)]=_0x59b64b;else!_0x28d3c4[_0x3ffd33(0x16f)]&&(_0x28d3c4[_0x3ffd33(0x16f)]=DEFAULT_CONFIG_VALUES[_0x3ffd33(0x16f)]);const _0x176a20=buildCanonicalAppConfig(appCodes,_0x28d3c4[_0x3ffd33(0x16f)]);return Object[_0x3ffd33(0x176)](_0x176a20)[_0x3ffd33(0x180)]>0x0&&(_0x28d3c4[_0x3ffd33(0x183)]=_0x176a20[_0x3ffd33(0x183)],_0x28d3c4[_0x3ffd33(0x164)]=_0x176a20['defaultApp']),_0x28d3c4;}const LOCALE_MAP={'zh':a194_0x5e5c23(0x17a),'zh-cn':a194_0x5e5c23(0x17a),'zh_cn':a194_0x5e5c23(0x17a),'en':a194_0x5e5c23(0x160),'en-us':a194_0x5e5c23(0x160),'en_us':a194_0x5e5c23(0x160)};export function normalizeLocale(_0x5442e4){const _0x141eb3=a194_0x5e5c23;if(!_0x5442e4)return null;return LOCALE_MAP[_0x5442e4[_0x141eb3(0x16c)]()]??null;}
@@ -0,0 +1 @@
1
+ export declare const CLI_VERSION_POLICY_URL = "https://g.lovrabet.com/dist/rabetbase-cli/config/index.json";
@@ -1 +1 @@
1
- const a195_0x6f66da=a195_0x41b8;(function(_0x8813ff,_0x463c2f){const _0x591ed5=a195_0x41b8,_0x19ba26=_0x8813ff();while(!![]){try{const _0x49d416=parseInt(_0x591ed5(0x19b))/0x1+parseInt(_0x591ed5(0x1a0))/0x2+-parseInt(_0x591ed5(0x1a1))/0x3*(-parseInt(_0x591ed5(0x19d))/0x4)+parseInt(_0x591ed5(0x19c))/0x5+parseInt(_0x591ed5(0x1a3))/0x6*(-parseInt(_0x591ed5(0x1a2))/0x7)+parseInt(_0x591ed5(0x199))/0x8*(-parseInt(_0x591ed5(0x19a))/0x9)+-parseInt(_0x591ed5(0x19f))/0xa;if(_0x49d416===_0x463c2f)break;else _0x19ba26['push'](_0x19ba26['shift']());}catch(_0x14831d){_0x19ba26['push'](_0x19ba26['shift']());}}}(a195_0x3972,0x2b4e5));export const CLI_VERSION_POLICY_URL=a195_0x6f66da(0x19e);function a195_0x41b8(_0x2241dc,_0x29eff5){_0x2241dc=_0x2241dc-0x199;const _0x397279=a195_0x3972();let _0x41b823=_0x397279[_0x2241dc];return _0x41b823;}function a195_0x3972(){const _0x1a723b=['4341mRJqhu','7udPPHW','1179726FXjUwd','88NthRre','117801EtGEOR','87184QTgGng','654535jrBZPo','344tuskmf','https://g.lovrabet.com/dist/rabetbase-cli/config/index.json','1260680KqaThc','603032aNyaGJ'];a195_0x3972=function(){return _0x1a723b;};return a195_0x3972();}
1
+ function a195_0x4aee(_0x2d164a,_0x1e832a){_0x2d164a=_0x2d164a-0xe8;const _0x51de8a=a195_0x51de();let _0x4aee02=_0x51de8a[_0x2d164a];return _0x4aee02;}const a195_0x19979b=a195_0x4aee;(function(_0x363225,_0x22ac8d){const _0x1c6afb=a195_0x4aee,_0x3fd0c5=_0x363225();while(!![]){try{const _0x5126ce=-parseInt(_0x1c6afb(0xee))/0x1+-parseInt(_0x1c6afb(0xe9))/0x2*(-parseInt(_0x1c6afb(0xea))/0x3)+-parseInt(_0x1c6afb(0xe8))/0x4+parseInt(_0x1c6afb(0xf1))/0x5+parseInt(_0x1c6afb(0xef))/0x6+-parseInt(_0x1c6afb(0xf0))/0x7+parseInt(_0x1c6afb(0xeb))/0x8*(parseInt(_0x1c6afb(0xed))/0x9);if(_0x5126ce===_0x22ac8d)break;else _0x3fd0c5['push'](_0x3fd0c5['shift']());}catch(_0x255990){_0x3fd0c5['push'](_0x3fd0c5['shift']());}}}(a195_0x51de,0x5a08b));export const CLI_VERSION_POLICY_URL=a195_0x19979b(0xec);function a195_0x51de(){const _0x5d9eec=['1422SGvMnm','674454KghjgK','1567848pgrrFq','3478181RRTTdo','3109245HfnrcF','1763484gkaEiX','4MVKJXp','875073xgIWRT','26048jxcYTA','https://g.lovrabet.com/dist/rabetbase-cli/config/index.json'];a195_0x51de=function(){return _0x5d9eec;};return a195_0x51de();}
@@ -0,0 +1,34 @@
1
+ /**
2
+ * 全局安装后的可执行文件名(与 package.json 的 bin 字段一致)
3
+ */
4
+ export declare const CLI_BIN_NAME = "rabetbase";
5
+ /**
6
+ * 产品显示名称(用于 help 标题等需要展示产品全名的地方)
7
+ */
8
+ export declare const CLI_DISPLAY_NAME = "Rabetbase CLI";
9
+ /**
10
+ * npm 包名(用于升级提示等)
11
+ */
12
+ export declare const NPM_PACKAGE_NAME = "@lovrabet/rabetbase-cli";
13
+ /**
14
+ * 全局 Flag 定义——单一来源。
15
+ * meow flags 配置和 generateFullHelp 的 GLOBAL OPTIONS 均从此派生,
16
+ * 避免两处各自维护时的不同步。
17
+ *
18
+ * hint:展示在 help 里的格式提示(可选),如 `<code>` 或 `production | daily`。
19
+ * hidden:命令级透传 flag,meow 需要感知但不在 GLOBAL OPTIONS 里展示。
20
+ */
21
+ export interface GlobalFlagDef {
22
+ name: string;
23
+ meowKey: string;
24
+ type: "string" | "boolean";
25
+ description: string;
26
+ hint?: string;
27
+ hidden?: boolean;
28
+ }
29
+ export declare const GLOBAL_FLAGS: GlobalFlagDef[];
30
+ export declare const PIPELINE_FLAG_NAMES: Set<string>;
31
+ /** 从 GLOBAL_FLAGS 生成 meow flags 配置对象 */
32
+ export declare function buildMeowFlags(): Record<string, {
33
+ type: "string" | "boolean";
34
+ }>;