@lovrabet/rabetbase-cli 2.3.12-beta.1 → 2.3.12

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 (260) hide show
  1. package/lib/api/api-doc.js +1 -1
  2. package/lib/api/fetch-model-list.js +1 -1
  3. package/lib/api/generate-api-file.js +1 -1
  4. package/lib/auth/auth-server-ui.js +1 -1
  5. package/lib/auth/auth-server.js +1 -1
  6. package/lib/auth/constant.js +1 -1
  7. package/lib/auth/get-cookie.js +1 -1
  8. package/lib/auth/get-session-user.js +1 -1
  9. package/lib/auth/is-session-valid.js +1 -1
  10. package/lib/auth/login-success-html.js +1 -1
  11. package/lib/auth/logout.js +1 -1
  12. package/lib/cli-flags.js +1 -1
  13. package/lib/cli.js +1 -1
  14. package/lib/commands/api/generate.js +1 -1
  15. package/lib/commands/api/index.js +1 -1
  16. package/lib/commands/api/list.js +1 -1
  17. package/lib/commands/api/pull.js +1 -1
  18. package/lib/commands/api/shared.js +1 -1
  19. package/lib/commands/app/add.js +1 -1
  20. package/lib/commands/app/index.js +1 -1
  21. package/lib/commands/app/list.js +1 -1
  22. package/lib/commands/app/remote-directory.js +1 -1
  23. package/lib/commands/app/remove.js +1 -1
  24. package/lib/commands/app/shared.js +1 -1
  25. package/lib/commands/app-config/delete.js +1 -1
  26. package/lib/commands/app-config/get.js +1 -1
  27. package/lib/commands/app-config/index.js +1 -1
  28. package/lib/commands/app-config/list.js +1 -1
  29. package/lib/commands/app-config/set.js +1 -1
  30. package/lib/commands/app-config/shared.js +1 -1
  31. package/lib/commands/auth/index.js +1 -1
  32. package/lib/commands/bff/create.js +1 -1
  33. package/lib/commands/bff/delete.js +1 -1
  34. package/lib/commands/bff/detail.js +1 -1
  35. package/lib/commands/bff/index.js +1 -1
  36. package/lib/commands/bff/list.js +1 -1
  37. package/lib/commands/bff/pull.js +1 -1
  38. package/lib/commands/bff/push.js +1 -1
  39. package/lib/commands/bff/status.js +1 -1
  40. package/lib/commands/cli-skill/index.js +1 -1
  41. package/lib/commands/cli-update.js +1 -1
  42. package/lib/commands/codegen/index.js +1 -1
  43. package/lib/commands/codegen/sdk.js +1 -1
  44. package/lib/commands/codegen/sql.js +1 -1
  45. package/lib/commands/common/app-registry.js +1 -1
  46. package/lib/commands/common/app-selector.js +1 -1
  47. package/lib/commands/common/async-task.js +1 -1
  48. package/lib/commands/common/dry-run.js +1 -1
  49. package/lib/commands/common/flags.js +1 -1
  50. package/lib/commands/common/local-file.js +1 -1
  51. package/lib/commands/common/validate.js +1 -1
  52. package/lib/commands/config/get.js +1 -1
  53. package/lib/commands/config/index.js +1 -1
  54. package/lib/commands/config/list.js +1 -1
  55. package/lib/commands/config/set.js +1 -1
  56. package/lib/commands/config/shared.js +1 -1
  57. package/lib/commands/data/filter.js +1 -1
  58. package/lib/commands/data/getOne.js +1 -1
  59. package/lib/commands/data/index.js +1 -1
  60. package/lib/commands/data/shared.js +1 -1
  61. package/lib/commands/dataset/business-group-update.js +1 -1
  62. package/lib/commands/dataset/capability.js +1 -1
  63. package/lib/commands/dataset/delete.js +1 -1
  64. package/lib/commands/dataset/detail.js +1 -1
  65. package/lib/commands/dataset/extend-update.js +1 -1
  66. package/lib/commands/dataset/field-update.js +1 -1
  67. package/lib/commands/dataset/generate.js +1 -1
  68. package/lib/commands/dataset/index.js +1 -1
  69. package/lib/commands/dataset/list.js +1 -1
  70. package/lib/commands/dataset/operations.js +1 -1
  71. package/lib/commands/dataset/relation-audit.js +1 -1
  72. package/lib/commands/dataset/relation-create.js +1 -1
  73. package/lib/commands/dataset/relation-delete.js +1 -1
  74. package/lib/commands/dataset/relation-shared.js +1 -1
  75. package/lib/commands/dataset/relation-update.js +1 -1
  76. package/lib/commands/dataset/relations.js +1 -1
  77. package/lib/commands/dataset/rename.js +1 -1
  78. package/lib/commands/dataset/restore.js +1 -1
  79. package/lib/commands/db/analysis-batching.js +1 -1
  80. package/lib/commands/db/analyze-batch-plan.js +1 -1
  81. package/lib/commands/db/analyze-cancel.js +1 -1
  82. package/lib/commands/db/analyze-start.js +1 -1
  83. package/lib/commands/db/analyze-status.js +1 -1
  84. package/lib/commands/db/create.js +1 -1
  85. package/lib/commands/db/delete.js +1 -1
  86. package/lib/commands/db/detail.js +1 -1
  87. package/lib/commands/db/diff.js +1 -1
  88. package/lib/commands/db/index.js +1 -1
  89. package/lib/commands/db/list.js +1 -1
  90. package/lib/commands/db/shared.js +1 -1
  91. package/lib/commands/db/tables.js +1 -1
  92. package/lib/commands/db/test.js +1 -1
  93. package/lib/commands/db/update.js +1 -1
  94. package/lib/commands/doctor.js +1 -1
  95. package/lib/commands/file/index.js +1 -1
  96. package/lib/commands/init/index.js +1 -1
  97. package/lib/commands/issue/index.js +1 -1
  98. package/lib/commands/issue/nudge.js +1 -1
  99. package/lib/commands/issue/report.js +1 -1
  100. package/lib/commands/issue/shared.js +1 -1
  101. package/lib/commands/logs/index.js +1 -1
  102. package/lib/commands/menu/delete.js +1 -1
  103. package/lib/commands/menu/external-link-create.js +1 -1
  104. package/lib/commands/menu/group-create.js +1 -1
  105. package/lib/commands/menu/group-update.js +1 -1
  106. package/lib/commands/menu/index.js +1 -1
  107. package/lib/commands/menu/list.js +1 -1
  108. package/lib/commands/menu/move.js +1 -1
  109. package/lib/commands/menu/regroup-start.js +1 -1
  110. package/lib/commands/menu/shared/compare-table.js +1 -1
  111. package/lib/commands/menu/shared/delete-plan.js +1 -1
  112. package/lib/commands/menu/shared/facts.js +1 -1
  113. package/lib/commands/menu/shared/index.js +1 -1
  114. package/lib/commands/menu/shared/inquirer.js +1 -1
  115. package/lib/commands/menu/shared/local-pages.js +1 -1
  116. package/lib/commands/menu/shared/logic.js +1 -1
  117. package/lib/commands/menu/shared/mutations.js +1 -1
  118. package/lib/commands/menu/shared/service.js +1 -1
  119. package/lib/commands/menu/shared/sync-core.js +1 -1
  120. package/lib/commands/menu/shared/update-core.js +1 -1
  121. package/lib/commands/menu/shared/valid-url.js +1 -1
  122. package/lib/commands/menu/sync.js +1 -1
  123. package/lib/commands/menu/update.js +1 -1
  124. package/lib/commands/notification/config-list.js +1 -1
  125. package/lib/commands/notification/index.js +1 -1
  126. package/lib/commands/page/generate-start.js +1 -1
  127. package/lib/commands/page/generate-status.js +1 -1
  128. package/lib/commands/page/index.js +1 -1
  129. package/lib/commands/page/pull.js +1 -1
  130. package/lib/commands/page/push.js +1 -1
  131. package/lib/commands/page/relation-audit.js +1 -1
  132. package/lib/commands/page/shared.js +1 -1
  133. package/lib/commands/page/standard-page-status.js +1 -1
  134. package/lib/commands/page/sync.js +1 -1
  135. package/lib/commands/permit/index.js +1 -1
  136. package/lib/commands/permit/page-get.js +1 -1
  137. package/lib/commands/permit/page-set.js +1 -1
  138. package/lib/commands/permit/role-apis-set.js +1 -1
  139. package/lib/commands/permit/role-menus-set.js +1 -1
  140. package/lib/commands/permit/role-menus.js +1 -1
  141. package/lib/commands/permit/shared.js +1 -1
  142. package/lib/commands/project/create/enhanced-guided-create.js +1 -1
  143. package/lib/commands/project/create/format-elapsed.js +1 -1
  144. package/lib/commands/project/create/main.js +1 -1
  145. package/lib/commands/project/create/non-interactive.js +1 -1
  146. package/lib/commands/project/create/project-template-path.js +1 -1
  147. package/lib/commands/project/create/use-copy-project-template.js +1 -1
  148. package/lib/commands/project/create/use-format-code.js +1 -1
  149. package/lib/commands/project/create/use-install-dependencies.js +1 -1
  150. package/lib/commands/project/index.js +1 -1
  151. package/lib/commands/project/init.js +1 -1
  152. package/lib/commands/project/upgrade.js +1 -1
  153. package/lib/commands/registry.js +1 -1
  154. package/lib/commands/role/create.js +1 -1
  155. package/lib/commands/role/delete.js +1 -1
  156. package/lib/commands/role/detail.js +1 -1
  157. package/lib/commands/role/index.js +1 -1
  158. package/lib/commands/role/list.js +1 -1
  159. package/lib/commands/role/shared.js +1 -1
  160. package/lib/commands/role/update.js +1 -1
  161. package/lib/commands/role/user-add.js +1 -1
  162. package/lib/commands/role/user-remove.js +1 -1
  163. package/lib/commands/role/user-resolve.js +1 -1
  164. package/lib/commands/run/index.js +1 -1
  165. package/lib/commands/schema.js +1 -1
  166. package/lib/commands/sql/create.js +1 -1
  167. package/lib/commands/sql/delete.js +1 -1
  168. package/lib/commands/sql/detail.js +1 -1
  169. package/lib/commands/sql/exec.js +1 -1
  170. package/lib/commands/sql/index.js +1 -1
  171. package/lib/commands/sql/list.js +1 -1
  172. package/lib/commands/sql/pull.js +1 -1
  173. package/lib/commands/sql/push.js +1 -1
  174. package/lib/commands/sql/save.js +1 -1
  175. package/lib/commands/sql/shared.js +1 -1
  176. package/lib/commands/sql/status.js +1 -1
  177. package/lib/commands/sql/validate.js +1 -1
  178. package/lib/commands/task/index.js +1 -1
  179. package/lib/commands/task/status.js +1 -1
  180. package/lib/commands/workspace/add.js +1 -1
  181. package/lib/commands/workspace/index.js +1 -1
  182. package/lib/commands/workspace/remove.js +1 -1
  183. package/lib/config/schema.js +1 -1
  184. package/lib/constant/cdn.js +1 -1
  185. package/lib/constant/cli.js +1 -1
  186. package/lib/constant/defaults.js +1 -1
  187. package/lib/constant/domain.js +1 -1
  188. package/lib/constant/env.js +1 -1
  189. package/lib/constant/output.js +1 -1
  190. package/lib/constant/paths.js +1 -1
  191. package/lib/constant/risk.js +1 -1
  192. package/lib/context/app-resolver.js +1 -1
  193. package/lib/context/auth-resolver.js +1 -1
  194. package/lib/context/config-loader.js +1 -1
  195. package/lib/context.js +1 -1
  196. package/lib/core/alias-resolver.js +1 -1
  197. package/lib/core/api-client.js +1 -1
  198. package/lib/core/bff/config.js +1 -1
  199. package/lib/core/bff/file-system.js +1 -1
  200. package/lib/core/bff/hash.js +1 -1
  201. package/lib/core/bff/lock.js +1 -1
  202. package/lib/core/bff/utils.js +1 -1
  203. package/lib/core/db-resolver.js +1 -1
  204. package/lib/core/page/file-system.js +1 -1
  205. package/lib/core/page/hash.js +1 -1
  206. package/lib/core/page/lock.js +1 -1
  207. package/lib/core/sql-index-auditor.js +1 -1
  208. package/lib/core/sql-sync/config.js +1 -1
  209. package/lib/core/sql-sync/file-system.js +1 -1
  210. package/lib/core/sql-sync/hash.js +1 -1
  211. package/lib/core/sql-sync/lock.js +1 -1
  212. package/lib/core/sql-sync/utils.js +1 -1
  213. package/lib/core/sql-validator.js +1 -1
  214. package/lib/errors.js +1 -1
  215. package/lib/framework/build-all-flags.js +1 -1
  216. package/lib/framework/error-output.js +1 -1
  217. package/lib/framework/explicit-yes.js +1 -1
  218. package/lib/framework/flags.js +1 -1
  219. package/lib/framework/help.js +1 -1
  220. package/lib/framework/index.js +1 -1
  221. package/lib/framework/output.js +1 -1
  222. package/lib/framework/response.js +1 -1
  223. package/lib/framework/runner-alias.js +1 -1
  224. package/lib/framework/runner.js +1 -1
  225. package/lib/framework/schema-export.js +1 -1
  226. package/lib/framework/types.js +1 -1
  227. package/lib/generated/build-info.js +1 -1
  228. package/lib/help.js +1 -1
  229. package/lib/skills/main.js +1 -1
  230. package/lib/skills/npx-skills-add.js +1 -1
  231. package/lib/telemetry/cli-command-trace.js +1 -1
  232. package/lib/telemetry/cli-help-trace.js +1 -1
  233. package/lib/telemetry/ensure-cli-otel-config.js +1 -1
  234. package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
  235. package/lib/telemetry/send-cli-trace-log.js +1 -1
  236. package/lib/telemetry/send-platform-issue-collect-log.js +1 -1
  237. package/lib/utils/ai_config.js +1 -1
  238. package/lib/utils/apply-jq-filter.js +1 -1
  239. package/lib/utils/cdn-config.js +1 -1
  240. package/lib/utils/check-sdk-version.js +1 -1
  241. package/lib/utils/cli-version-check.js +1 -1
  242. package/lib/utils/cli-version-policy.js +1 -1
  243. package/lib/utils/config.js +1 -1
  244. package/lib/utils/copy-directory.js +1 -1
  245. package/lib/utils/entity-with-id.js +1 -1
  246. package/lib/utils/file-utils.js +1 -1
  247. package/lib/utils/guides-cdn.js +1 -1
  248. package/lib/utils/http-client.js +1 -1
  249. package/lib/utils/is-non-interactive.js +1 -1
  250. package/lib/utils/logger.js +1 -1
  251. package/lib/utils/params.js +1 -1
  252. package/lib/utils/platform.js +1 -1
  253. package/lib/utils/rules-cdn.js +1 -1
  254. package/lib/utils/sleep.js +1 -1
  255. package/lib/utils/template-replacer.js +1 -1
  256. package/lib/utils/update-notice.js +1 -1
  257. package/lib/utils/version.js +1 -1
  258. package/lib/utils/with-active-cookie.js +1 -1
  259. package/lib/utils/write-cli-side-channel.js +1 -1
  260. package/package.json +1 -1
@@ -1 +1 @@
1
- (function(_0x619ba7,_0x49e3ab){const _0x4d89cd=a145_0x3475,_0x41e2bd=_0x619ba7();while(!![]){try{const _0x222e46=parseInt(_0x4d89cd(0x13c))/0x1*(parseInt(_0x4d89cd(0x130))/0x2)+-parseInt(_0x4d89cd(0x13b))/0x3+-parseInt(_0x4d89cd(0x125))/0x4*(parseInt(_0x4d89cd(0x118))/0x5)+parseInt(_0x4d89cd(0x129))/0x6+-parseInt(_0x4d89cd(0x11c))/0x7+-parseInt(_0x4d89cd(0x126))/0x8*(parseInt(_0x4d89cd(0x103))/0x9)+parseInt(_0x4d89cd(0x114))/0xa*(parseInt(_0x4d89cd(0x139))/0xb);if(_0x222e46===_0x49e3ab)break;else _0x41e2bd['push'](_0x41e2bd['shift']());}catch(_0x6399de){_0x41e2bd['push'](_0x41e2bd['shift']());}}}(a145_0x3b7e,0xcf928));import a145_0x523b96 from'path';import a145_0x3f6743 from'fs/promises';import{existsSync}from'fs';import{CLI_BIN_NAME}from'../../../constant/cli.js';import{DEFAULT_API_DIR}from'../../../constant/paths.js';function a145_0x3475(_0x23e63d,_0x4fc759){_0x23e63d=_0x23e63d-0x101;const _0x3b7e81=a145_0x3b7e();let _0x347579=_0x3b7e81[_0x23e63d];return _0x347579;}function a145_0x3b7e(){const _0x35e0bc=['139wfvVfH','parse','A\x20project\x20created\x20with\x20Lovrabet\x20CLI','toLocaleString','195354OLgOFo','bun\x20run\x20format','\x20\x20rabetbase\x20run\x20start\x0a','\x20\x20Installing\x20dependencies...','\x20\x20√\x20Configuration\x20file\x20created','length','\x20\x20√\x20Code\x20formatted','stringify','log','constants','*\x20Creating\x20project\x20','Project\x20name\x20cannot\x20be\x20empty.','ignore','test','writeFile','validation','\x20\x20√\x20Project\x20template\x20created','30urhyUT','Cannot\x20create\x20project\x20in\x20current\x20directory.','env','\x20\x20Pulling\x20API\x20configuration...','5741165qUgiFT','Project\x20directory\x20\x22','cwd','name','10191580lUOPTj','bun','Project\x20name\x20is\x20too\x20long,\x20maximum\x20100\x20characters.','\x20created\x20successfully!','access','Use\x20a\x20different\x20project\x20name.','\x20model(s)','npm','production','4HyAXEP','616OUTlJu','\x0a√\x20Project\x20','\x20dataset(s),\x20generated\x20','9288696rydJEw','Check\x20directory\x20permissions.','description','...','bun\x20--version','chdir','\x20\x20√\x20package.json\x20updated','11464vDqhZs','\x20\x20√\x20Pulled\x20','\x20\x20√\x20Dependency\x20install\x20skipped\x20(non-interactive)','trim','string','package.json','resolve','utf-8','belowMinimum','11530904NOFrqB','join','1091715LMgCia'];a145_0x3b7e=function(){return _0x35e0bc;};return a145_0x3b7e();}import{exec,execSync}from'child_process';import{copyDirectory}from'../../../utils/copy-directory.js';import{promisify}from'util';import{assertCliVersionSupported,checkCliVersion,printCliUpgradeWarning}from'../../../utils/cli-version-check.js';import{writeConfigFile,NEW_CONFIG_NAME}from'../../../context.js';import{readConfig}from'../../../utils/config.js';import{getCliVersion}from'../../../utils/version.js';import{CliErrors}from'../../../errors.js';import{fetchModelList}from'../../../core/api-client.js';import{generateApiFile}from'../../../api/generate-api-file.js';import{initEnv}from'../../../constant/env.js';import{getSubAppReactDemoTemplateDir}from'../../../commands/project/create/project-template-path.js';import{PROJECT_CREATE_INHERITABLE_KEYS,buildCanonicalProjectConfig}from'../../../config/schema.js';const execAsync=promisify(exec);export async function createProjectNonInteractive(_0x224570,_0x58e167,_0x117d9f,_0x5264dc){const _0x1cec4b=a145_0x3475,_0xa4c3d0=await checkCliVersion();(_0xa4c3d0['needsUpgrade']||_0xa4c3d0[_0x1cec4b(0x138)])&&(printCliUpgradeWarning(_0xa4c3d0),assertCliVersionSupported(_0xa4c3d0));if(!_0x224570||_0x224570[_0x1cec4b(0x133)]()==='')throw CliErrors['validation'](_0x1cec4b(0x10e));const _0x8c566d=/[<>:"|?*\x00-\x1f\x7f]/;if(_0x8c566d[_0x1cec4b(0x110)](_0x224570))throw CliErrors[_0x1cec4b(0x112)]('Project\x20name\x20contains\x20invalid\x20characters.','Not\x20allowed:\x20<\x20>\x20:\x20\x22\x20|\x20?\x20*\x20and\x20control\x20characters');if(_0x224570[_0x1cec4b(0x108)]>0x64)throw CliErrors[_0x1cec4b(0x112)](_0x1cec4b(0x11e));const _0x41ce0a=a145_0x523b96[_0x1cec4b(0x136)](process[_0x1cec4b(0x11a)](),_0x224570);if(existsSync(_0x41ce0a))throw CliErrors[_0x1cec4b(0x112)](_0x1cec4b(0x119)+_0x224570+'\x22\x20already\x20exists.',_0x1cec4b(0x121));try{const _0x22314e=a145_0x523b96['dirname'](_0x41ce0a);await a145_0x3f6743[_0x1cec4b(0x120)](_0x22314e,a145_0x3f6743[_0x1cec4b(0x10c)]['W_OK']);}catch{throw CliErrors['validation'](_0x1cec4b(0x115),_0x1cec4b(0x12a));}try{console[_0x1cec4b(0x10b)](_0x1cec4b(0x10d)+_0x224570+_0x1cec4b(0x12c));const _0x17d641=getSubAppReactDemoTemplateDir();await copyDirectory(_0x17d641,_0x41ce0a),console[_0x1cec4b(0x10b)](_0x1cec4b(0x113)),await updatePackageJsonName(_0x224570),console['log'](_0x1cec4b(0x12f)),console[_0x1cec4b(0x10b)](_0x1cec4b(0x106)),console[_0x1cec4b(0x10b)](_0x1cec4b(0x132)),await formatCode(_0x41ce0a),console[_0x1cec4b(0x10b)](_0x1cec4b(0x109)),await configureProject(_0x224570,_0x117d9f,_0x58e167),console[_0x1cec4b(0x10b)](_0x1cec4b(0x107)),_0x117d9f&&await pullApiConfig(_0x41ce0a,_0x117d9f,_0x58e167,_0x5264dc),console['log'](_0x1cec4b(0x127)+_0x224570+_0x1cec4b(0x11f)),console[_0x1cec4b(0x10b)]('\x0a\x20\x20cd\x20'+_0x224570),console[_0x1cec4b(0x10b)](_0x1cec4b(0x105));}catch(_0x935334){try{existsSync(_0x41ce0a)&&await a145_0x3f6743['rm'](_0x41ce0a,{'recursive':!![],'force':!![]});}catch{}throw _0x935334;}}async function updatePackageJsonName(_0x1284e8){const _0x562a6c=a145_0x3475,_0x39a6ab=a145_0x523b96[_0x562a6c(0x136)](process[_0x562a6c(0x11a)](),_0x1284e8),_0xfede28=a145_0x523b96[_0x562a6c(0x13a)](_0x39a6ab,_0x562a6c(0x135)),_0x34bf65=await a145_0x3f6743['readFile'](_0xfede28,_0x562a6c(0x137)),_0x111b6f=JSON[_0x562a6c(0x13d)](_0x34bf65);_0x111b6f[_0x562a6c(0x11b)]=_0x1284e8,_0x111b6f[_0x562a6c(0x12b)]=_0x562a6c(0x101),await a145_0x3f6743[_0x562a6c(0x111)](_0xfede28,JSON[_0x562a6c(0x10a)](_0x111b6f,null,0x2)+'\x0a');}function detectPackageManager(){const _0x500da6=a145_0x3475;try{return execSync(_0x500da6(0x12d),{'stdio':_0x500da6(0x10f)}),_0x500da6(0x11d);}catch{return _0x500da6(0x123);}}async function formatCode(_0x1dde95){const _0x427bc7=a145_0x3475;try{await execAsync(_0x427bc7(0x104),{'cwd':_0x1dde95});}catch{}}async function configureProject(_0xfa8708,_0x1fc8aa,_0x58c316){const _0x2aa609=a145_0x3475,_0x379b55=a145_0x523b96[_0x2aa609(0x136)](process[_0x2aa609(0x11a)](),_0xfa8708),_0x4af65b=a145_0x523b96[_0x2aa609(0x13a)](_0x379b55,NEW_CONFIG_NAME),_0x1d9daf=readConfig(),_0x2149d6=typeof _0x1d9daf[_0x2aa609(0x116)]===_0x2aa609(0x134)?_0x1d9daf[_0x2aa609(0x116)]:undefined,_0x502036={};for(const _0x341031 of PROJECT_CREATE_INHERITABLE_KEYS){if(_0x1d9daf[_0x341031]!=null)_0x502036[_0x341031]=_0x1d9daf[_0x341031];}const _0x5244f6=buildCanonicalProjectConfig(_0x502036,{'appCodes':_0x1fc8aa?[_0x1fc8aa]:[],'env':_0x58c316||_0x2149d6||'production','metadata':{'createdAt':new Date()[_0x2aa609(0x102)](),'version':getCliVersion()}});writeConfigFile(_0x4af65b,_0x5244f6);}async function pullApiConfig(_0x2b808b,_0x47823e,_0x58ceb2,_0x19e69b){const _0xbb41f3=a145_0x3475,_0x4d2bcb=process[_0xbb41f3(0x11a)]();try{process[_0xbb41f3(0x12e)](_0x2b808b);const _0x35c3dd=_0x58ceb2||_0xbb41f3(0x124);initEnv(_0x35c3dd),console['log'](_0xbb41f3(0x117));const {configArray:_0xd2b950}=await fetchModelList(_0x47823e,_0x19e69b||''),_0x287ab1=await generateApiFile(_0xd2b950,'',_0x47823e,!![],_0x35c3dd,DEFAULT_API_DIR);console[_0xbb41f3(0x10b)](_0xbb41f3(0x131)+_0xd2b950[_0xbb41f3(0x108)]+_0xbb41f3(0x128)+_0x287ab1['modelCount']+_0xbb41f3(0x122));}catch(_0x46b038){console[_0xbb41f3(0x10b)]('\x20\x20!\x20API\x20pull\x20failed,\x20run\x20`'+CLI_BIN_NAME+'\x20api\x20pull`\x20manually\x20later.');}finally{process[_0xbb41f3(0x12e)](_0x4d2bcb);}}
1
+ (function(_0x3859c2,_0x53912d){const _0x390b13=a145_0xe407,_0x56ef4f=_0x3859c2();while(!![]){try{const _0x3f6c83=parseInt(_0x390b13(0xfd))/0x1*(parseInt(_0x390b13(0x12a))/0x2)+parseInt(_0x390b13(0x11b))/0x3*(parseInt(_0x390b13(0x130))/0x4)+-parseInt(_0x390b13(0x113))/0x5+parseInt(_0x390b13(0x107))/0x6*(parseInt(_0x390b13(0x11a))/0x7)+-parseInt(_0x390b13(0x105))/0x8+parseInt(_0x390b13(0x12e))/0x9+-parseInt(_0x390b13(0x129))/0xa*(parseInt(_0x390b13(0x12c))/0xb);if(_0x3f6c83===_0x53912d)break;else _0x56ef4f['push'](_0x56ef4f['shift']());}catch(_0x3e23c6){_0x56ef4f['push'](_0x56ef4f['shift']());}}}(a145_0x5da1,0x88441));import a145_0x28b2b0 from'path';import a145_0x38600c from'fs/promises';import{existsSync}from'fs';import{CLI_BIN_NAME}from'../../../constant/cli.js';import{DEFAULT_API_DIR}from'../../../constant/paths.js';import{exec,execSync}from'child_process';import{copyDirectory}from'../../../utils/copy-directory.js';import{promisify}from'util';import{assertCliVersionSupported,checkCliVersion,printCliUpgradeWarning}from'../../../utils/cli-version-check.js';function a145_0xe407(_0xe67cbf,_0x54b138){_0xe67cbf=_0xe67cbf-0xf7;const _0x5da10e=a145_0x5da1();let _0xe40738=_0x5da10e[_0xe67cbf];return _0xe40738;}import{writeConfigFile,NEW_CONFIG_NAME}from'../../../context.js';import{readConfig}from'../../../utils/config.js';import{getCliVersion}from'../../../utils/version.js';import{CliErrors}from'../../../errors.js';import{fetchModelList}from'../../../core/api-client.js';import{generateApiFile}from'../../../api/generate-api-file.js';import{initEnv}from'../../../constant/env.js';import{getSubAppReactDemoTemplateDir}from'../../../commands/project/create/project-template-path.js';import{PROJECT_CREATE_INHERITABLE_KEYS,buildCanonicalProjectConfig}from'../../../config/schema.js';const execAsync=promisify(exec);export async function createProjectNonInteractive(_0x31800e,_0x2b14aa,_0x442539,_0x26bbd4){const _0x1ec66b=a145_0xe407,_0x5c3550=await checkCliVersion();(_0x5c3550[_0x1ec66b(0x131)]||_0x5c3550[_0x1ec66b(0x11f)])&&(printCliUpgradeWarning(_0x5c3550),assertCliVersionSupported(_0x5c3550));if(!_0x31800e||_0x31800e['trim']()==='')throw CliErrors[_0x1ec66b(0xff)](_0x1ec66b(0x125));const _0x2bb5b4=/[<>:"|?*\x00-\x1f\x7f]/;if(_0x2bb5b4[_0x1ec66b(0xfe)](_0x31800e))throw CliErrors[_0x1ec66b(0xff)](_0x1ec66b(0x122),_0x1ec66b(0x109));if(_0x31800e[_0x1ec66b(0x108)]>0x64)throw CliErrors[_0x1ec66b(0xff)](_0x1ec66b(0x120));const _0x516c1f=a145_0x28b2b0['resolve'](process['cwd'](),_0x31800e);if(existsSync(_0x516c1f))throw CliErrors[_0x1ec66b(0xff)]('Project\x20directory\x20\x22'+_0x31800e+'\x22\x20already\x20exists.',_0x1ec66b(0x104));try{const _0x486391=a145_0x28b2b0[_0x1ec66b(0x10b)](_0x516c1f);await a145_0x38600c[_0x1ec66b(0x124)](_0x486391,a145_0x38600c[_0x1ec66b(0x12b)][_0x1ec66b(0x10f)]);}catch{throw CliErrors[_0x1ec66b(0xff)](_0x1ec66b(0x121),_0x1ec66b(0x126));}try{console['log'](_0x1ec66b(0xfc)+_0x31800e+_0x1ec66b(0x10c));const _0x5aa628=getSubAppReactDemoTemplateDir();await copyDirectory(_0x5aa628,_0x516c1f),console['log'](_0x1ec66b(0x128)),await updatePackageJsonName(_0x31800e),console[_0x1ec66b(0x12f)](_0x1ec66b(0x119)),console[_0x1ec66b(0x12f)]('\x20\x20Installing\x20dependencies...'),console[_0x1ec66b(0x12f)](_0x1ec66b(0x10e)),await formatCode(_0x516c1f),console[_0x1ec66b(0x12f)](_0x1ec66b(0x101)),await configureProject(_0x31800e,_0x442539,_0x2b14aa),console[_0x1ec66b(0x12f)](_0x1ec66b(0x115)),_0x442539&&await pullApiConfig(_0x516c1f,_0x442539,_0x2b14aa,_0x26bbd4),console[_0x1ec66b(0x12f)](_0x1ec66b(0xfa)+_0x31800e+_0x1ec66b(0x111)),console[_0x1ec66b(0x12f)](_0x1ec66b(0x11d)+_0x31800e),console['log'](_0x1ec66b(0x117));}catch(_0x47c973){try{existsSync(_0x516c1f)&&await a145_0x38600c['rm'](_0x516c1f,{'recursive':!![],'force':!![]});}catch{}throw _0x47c973;}}async function updatePackageJsonName(_0x482c69){const _0x3776fd=a145_0xe407,_0x1c26d9=a145_0x28b2b0['resolve'](process['cwd'](),_0x482c69),_0x5ed16c=a145_0x28b2b0[_0x3776fd(0x11c)](_0x1c26d9,_0x3776fd(0x123)),_0x3bb155=await a145_0x38600c[_0x3776fd(0x102)](_0x5ed16c,'utf-8'),_0x1f6228=JSON[_0x3776fd(0xf7)](_0x3bb155);_0x1f6228[_0x3776fd(0x103)]=_0x482c69,_0x1f6228[_0x3776fd(0xf8)]='A\x20project\x20created\x20with\x20Lovrabet\x20CLI',await a145_0x38600c['writeFile'](_0x5ed16c,JSON[_0x3776fd(0x100)](_0x1f6228,null,0x2)+'\x0a');}function detectPackageManager(){const _0x2e1943=a145_0xe407;try{return execSync(_0x2e1943(0xf9),{'stdio':'ignore'}),_0x2e1943(0x11e);}catch{return _0x2e1943(0x118);}}async function formatCode(_0xd071d3){const _0x4b6d1e=a145_0xe407;try{await execAsync(_0x4b6d1e(0x112),{'cwd':_0xd071d3});}catch{}}function a145_0x5da1(){const _0x508e48=['env','dirname','...','\x20dataset(s),\x20generated\x20','\x20\x20√\x20Dependency\x20install\x20skipped\x20(non-interactive)','W_OK','\x20\x20√\x20Pulled\x20','\x20created\x20successfully!','bun\x20run\x20format','344555nnCuSF','string','\x20\x20√\x20Configuration\x20file\x20created','cwd','\x20\x20rabetbase\x20run\x20start\x0a','npm','\x20\x20√\x20package.json\x20updated','84ViZPUG','759uxrMnC','join','\x0a\x20\x20cd\x20','bun','belowMinimum','Project\x20name\x20is\x20too\x20long,\x20maximum\x20100\x20characters.','Cannot\x20create\x20project\x20in\x20current\x20directory.','Project\x20name\x20contains\x20invalid\x20characters.','package.json','access','Project\x20name\x20cannot\x20be\x20empty.','Check\x20directory\x20permissions.','chdir','\x20\x20√\x20Project\x20template\x20created','484450erAanG','8ogTwer','constants','231mDxjjg','\x20model(s)','4467510MgdXHt','log','3568iLfKPv','needsUpgrade','modelCount','parse','description','bun\x20--version','\x0a√\x20Project\x20','production','*\x20Creating\x20project\x20','179131ImTGSI','test','validation','stringify','\x20\x20√\x20Code\x20formatted','readFile','name','Use\x20a\x20different\x20project\x20name.','2962184sReynb','\x20\x20!\x20API\x20pull\x20failed,\x20run\x20`','288042CfzgSL','length','Not\x20allowed:\x20<\x20>\x20:\x20\x22\x20|\x20?\x20*\x20and\x20control\x20characters'];a145_0x5da1=function(){return _0x508e48;};return a145_0x5da1();}async function configureProject(_0x28ecbc,_0x4f7214,_0x3bf2f4){const _0x4de08b=a145_0xe407,_0x16f911=a145_0x28b2b0['resolve'](process[_0x4de08b(0x116)](),_0x28ecbc),_0x23a6b2=a145_0x28b2b0[_0x4de08b(0x11c)](_0x16f911,NEW_CONFIG_NAME),_0x4bc169=readConfig(),_0x5a00c1=typeof _0x4bc169[_0x4de08b(0x10a)]===_0x4de08b(0x114)?_0x4bc169[_0x4de08b(0x10a)]:undefined,_0x44e9ee={};for(const _0x60803 of PROJECT_CREATE_INHERITABLE_KEYS){if(_0x4bc169[_0x60803]!=null)_0x44e9ee[_0x60803]=_0x4bc169[_0x60803];}const _0x1a9872=buildCanonicalProjectConfig(_0x44e9ee,{'appCodes':_0x4f7214?[_0x4f7214]:[],'env':_0x3bf2f4||_0x5a00c1||_0x4de08b(0xfb),'metadata':{'createdAt':new Date()['toLocaleString'](),'version':getCliVersion()}});writeConfigFile(_0x23a6b2,_0x1a9872);}async function pullApiConfig(_0x567f32,_0x13c3cd,_0x50cd3a,_0x4609a1){const _0x215c25=a145_0xe407,_0x972e60=process[_0x215c25(0x116)]();try{process['chdir'](_0x567f32);const _0x306118=_0x50cd3a||_0x215c25(0xfb);initEnv(_0x306118),console[_0x215c25(0x12f)]('\x20\x20Pulling\x20API\x20configuration...');const {configArray:_0x28d37e}=await fetchModelList(_0x13c3cd,_0x4609a1||''),_0xf9c380=await generateApiFile(_0x28d37e,'',_0x13c3cd,!![],_0x306118,DEFAULT_API_DIR);console['log'](_0x215c25(0x110)+_0x28d37e[_0x215c25(0x108)]+_0x215c25(0x10d)+_0xf9c380[_0x215c25(0x132)]+_0x215c25(0x12d));}catch(_0x1fd158){console[_0x215c25(0x12f)](_0x215c25(0x106)+CLI_BIN_NAME+'\x20api\x20pull`\x20manually\x20later.');}finally{process[_0x215c25(0x127)](_0x972e60);}}
@@ -1 +1 @@
1
- const a146_0x19aef7=a146_0x37f6;function a146_0x37f6(_0xe5ac7c,_0x4841f2){_0xe5ac7c=_0xe5ac7c-0xb2;const _0x16850b=a146_0x1685();let _0x37f6c9=_0x16850b[_0xe5ac7c];return _0x37f6c9;}function a146_0x1685(){const _0x10834d=['join','projects','dirname','2201938XvzYsV','3757790vCqszv','3444300TdWleG','7982112ikTvlj','templates','../../../../','1351302yaDwXf','3464GBIvpI','868729BOvYPE','31199RzFqIE','resolve','sub-app-react-demo'];a146_0x1685=function(){return _0x10834d;};return a146_0x1685();}(function(_0x5d846c,_0x149bc7){const _0x20abb7=a146_0x37f6,_0x5edb82=_0x5d846c();while(!![]){try{const _0x599995=-parseInt(_0x20abb7(0xba))/0x1+-parseInt(_0x20abb7(0xb2))/0x2+-parseInt(_0x20abb7(0xb8))/0x3+parseInt(_0x20abb7(0xb4))/0x4+-parseInt(_0x20abb7(0xb3))/0x5+parseInt(_0x20abb7(0xb5))/0x6+parseInt(_0x20abb7(0xbb))/0x7*(parseInt(_0x20abb7(0xb9))/0x8);if(_0x599995===_0x149bc7)break;else _0x5edb82['push'](_0x5edb82['shift']());}catch(_0x4550e3){_0x5edb82['push'](_0x5edb82['shift']());}}}(a146_0x1685,0xe7d72));import a146_0x5b5994 from'node:path';import{fileURLToPath}from'node:url';const __dirname=a146_0x5b5994[a146_0x19aef7(0xc0)](fileURLToPath(import.meta.url));export function getRabetbaseCliPackageRoot(){const _0x4d2736=a146_0x19aef7;return a146_0x5b5994[_0x4d2736(0xbc)](__dirname,_0x4d2736(0xb7));}export function getSubAppReactDemoTemplateDir(){const _0x511afd=a146_0x19aef7;return a146_0x5b5994[_0x511afd(0xbe)](getRabetbaseCliPackageRoot(),_0x511afd(0xb6),_0x511afd(0xbf),_0x511afd(0xbd));}
1
+ const a146_0x2da697=a146_0x6a40;(function(_0x3a9ef0,_0x3cf1fb){const _0x6cf36f=a146_0x6a40,_0xf68fff=_0x3a9ef0();while(!![]){try{const _0x504235=parseInt(_0x6cf36f(0x15a))/0x1+parseInt(_0x6cf36f(0x15f))/0x2*(-parseInt(_0x6cf36f(0x159))/0x3)+parseInt(_0x6cf36f(0x15d))/0x4*(parseInt(_0x6cf36f(0x15e))/0x5)+-parseInt(_0x6cf36f(0x15b))/0x6+-parseInt(_0x6cf36f(0x162))/0x7+-parseInt(_0x6cf36f(0x160))/0x8*(-parseInt(_0x6cf36f(0x154))/0x9)+parseInt(_0x6cf36f(0x158))/0xa*(parseInt(_0x6cf36f(0x161))/0xb);if(_0x504235===_0x3cf1fb)break;else _0xf68fff['push'](_0xf68fff['shift']());}catch(_0x57cde1){_0xf68fff['push'](_0xf68fff['shift']());}}}(a146_0x426e,0x76a86));import a146_0x21625a from'node:path';function a146_0x6a40(_0x18ddd0,_0x20c9b5){_0x18ddd0=_0x18ddd0-0x153;const _0x426e77=a146_0x426e();let _0x6a40fb=_0x426e77[_0x18ddd0];return _0x6a40fb;}import{fileURLToPath}from'node:url';const __dirname=a146_0x21625a[a146_0x2da697(0x155)](fileURLToPath(import.meta.url));export function getRabetbaseCliPackageRoot(){const _0x20efd5=a146_0x2da697;return a146_0x21625a['resolve'](__dirname,_0x20efd5(0x157));}function a146_0x426e(){const _0x166db7=['42143HPdTSQ','860478XhLNvJ','projects','892YsEjrl','5545rUHhLe','4szHhME','152ThFeFV','404536DRSJYI','4992610BdLQzv','join','359343ngblva','dirname','templates','../../../../','180NfoJDG','551049ozZLky'];a146_0x426e=function(){return _0x166db7;};return a146_0x426e();}export function getSubAppReactDemoTemplateDir(){const _0x46bb0a=a146_0x2da697;return a146_0x21625a[_0x46bb0a(0x153)](getRabetbaseCliPackageRoot(),_0x46bb0a(0x156),_0x46bb0a(0x15c),'sub-app-react-demo');}
@@ -1 +1 @@
1
- (function(_0x55e122,_0x279748){const _0x1f3d07=a147_0x32db,_0x21dc92=_0x55e122();while(!![]){try{const _0x45d6a2=parseInt(_0x1f3d07(0x1b4))/0x1*(-parseInt(_0x1f3d07(0x1ae))/0x2)+parseInt(_0x1f3d07(0x1b5))/0x3*(-parseInt(_0x1f3d07(0x1aa))/0x4)+parseInt(_0x1f3d07(0x1b1))/0x5+-parseInt(_0x1f3d07(0x1b2))/0x6+parseInt(_0x1f3d07(0x1ab))/0x7*(-parseInt(_0x1f3d07(0x1b7))/0x8)+-parseInt(_0x1f3d07(0x1b3))/0x9+parseInt(_0x1f3d07(0x1b0))/0xa;if(_0x45d6a2===_0x279748)break;else _0x21dc92['push'](_0x21dc92['shift']());}catch(_0x243a15){_0x21dc92['push'](_0x21dc92['shift']());}}}(a147_0x3445,0x3565a));import a147_0x51f137 from'node:path';import{copyDirectory}from'../../../utils/copy-directory.js';import{formatElapsed}from'../../../commands/project/create/format-elapsed.js';import{logger}from'../../../utils/logger.js';function a147_0x32db(_0xb2a620,_0xa55a49){_0xb2a620=_0xb2a620-0x1a8;const _0x3445ca=a147_0x3445();let _0x32db82=_0x3445ca[_0xb2a620];return _0x32db82;}import{getSubAppReactDemoTemplateDir}from'../../../commands/project/create/project-template-path.js';function a147_0x3445(){const _0x193bfc=['119256xgiBTu','cwd','开始复制项目模板','now','copy','error','3828DhYgSj','182TDsJfU','message','resolve','2NTBhoJ','info','11735530COjTrj','2026580pfoHIw','962082CtWCZg','2623266LlnlzM','173361NsVyzC','1089wlfESV','success'];a147_0x3445=function(){return _0x193bfc;};return a147_0x3445();}const templateDir=getSubAppReactDemoTemplateDir();export async function copyProjectTemplate(_0x1c66a3){const _0x39b563=a147_0x32db,_0x17995f=Date[_0x39b563(0x1ba)](),_0x3f0105=a147_0x51f137[_0x39b563(0x1ad)](process[_0x39b563(0x1b8)](),_0x1c66a3);try{logger[_0x39b563(0x1af)](_0x39b563(0x1a8),_0x39b563(0x1b9),{'projectCode':_0x1c66a3,'templateDir':templateDir}),await copyDirectory(templateDir,_0x3f0105);const _0x16c8e8=Date['now']()-_0x17995f;logger[_0x39b563(0x1b6)](_0x39b563(0x1a8),'项目模板复制完成',_0x16c8e8,{'projectCode':_0x1c66a3});}catch(_0x35a0c8){const _0x49612f=Date[_0x39b563(0x1ba)]()-_0x17995f;logger[_0x39b563(0x1a9)]('copy','项目模板复制失败',{'projectCode':_0x1c66a3,'error':_0x35a0c8 instanceof Error?_0x35a0c8[_0x39b563(0x1ac)]:String(_0x35a0c8),'duration':_0x49612f});throw _0x35a0c8;}return formatElapsed(_0x17995f);}
1
+ function a147_0x5e59(_0x4cc5b4,_0x4438d5){_0x4cc5b4=_0x4cc5b4-0x1a2;const _0x67776=a147_0x6777();let _0x5e59b8=_0x67776[_0x4cc5b4];return _0x5e59b8;}function a147_0x6777(){const _0x1d426d=['message','275548QiNMFU','copy','780534xrERZY','102697fjQXQt','2149679ftjSXW','项目模板复制失败','cwd','50dfRubj','error','info','3WFYcrw','230280izhMUi','784618cMwgYj','1715070dPtfnG','6lwlxoZ','resolve','now'];a147_0x6777=function(){return _0x1d426d;};return a147_0x6777();}(function(_0x4c97a0,_0x165a30){const _0x12ef3a=a147_0x5e59,_0x2c07b1=_0x4c97a0();while(!![]){try{const _0x53ff88=parseInt(_0x12ef3a(0x1a6))/0x1+parseInt(_0x12ef3a(0x1af))/0x2*(-parseInt(_0x12ef3a(0x1ad))/0x3)+parseInt(_0x12ef3a(0x1a3))/0x4+-parseInt(_0x12ef3a(0x1b0))/0x5*(parseInt(_0x12ef3a(0x1b1))/0x6)+parseInt(_0x12ef3a(0x1a7))/0x7+parseInt(_0x12ef3a(0x1ae))/0x8+parseInt(_0x12ef3a(0x1a5))/0x9*(parseInt(_0x12ef3a(0x1aa))/0xa);if(_0x53ff88===_0x165a30)break;else _0x2c07b1['push'](_0x2c07b1['shift']());}catch(_0x107de8){_0x2c07b1['push'](_0x2c07b1['shift']());}}}(a147_0x6777,0x323cd));import a147_0x14eff6 from'node:path';import{copyDirectory}from'../../../utils/copy-directory.js';import{formatElapsed}from'../../../commands/project/create/format-elapsed.js';import{logger}from'../../../utils/logger.js';import{getSubAppReactDemoTemplateDir}from'../../../commands/project/create/project-template-path.js';const templateDir=getSubAppReactDemoTemplateDir();export async function copyProjectTemplate(_0x578e1c){const _0xd5e363=a147_0x5e59,_0x47e542=Date[_0xd5e363(0x1b3)](),_0x255212=a147_0x14eff6[_0xd5e363(0x1b2)](process[_0xd5e363(0x1a9)](),_0x578e1c);try{logger[_0xd5e363(0x1ac)]('copy','开始复制项目模板',{'projectCode':_0x578e1c,'templateDir':templateDir}),await copyDirectory(templateDir,_0x255212);const _0x540ad4=Date[_0xd5e363(0x1b3)]()-_0x47e542;logger['success'](_0xd5e363(0x1a4),'项目模板复制完成',_0x540ad4,{'projectCode':_0x578e1c});}catch(_0x12c17f){const _0x343ba5=Date['now']()-_0x47e542;logger[_0xd5e363(0x1ab)](_0xd5e363(0x1a4),_0xd5e363(0x1a8),{'projectCode':_0x578e1c,'error':_0x12c17f instanceof Error?_0x12c17f[_0xd5e363(0x1a2)]:String(_0x12c17f),'duration':_0x343ba5});throw _0x12c17f;}return formatElapsed(_0x47e542);}
@@ -1 +1 @@
1
- (function(_0x4b8120,_0x44fc9c){const _0x35117a=a148_0x29c0,_0x235e30=_0x4b8120();while(!![]){try{const _0x50f8e9=parseInt(_0x35117a(0x169))/0x1*(parseInt(_0x35117a(0x161))/0x2)+parseInt(_0x35117a(0x16d))/0x3*(-parseInt(_0x35117a(0x15d))/0x4)+parseInt(_0x35117a(0x16c))/0x5*(-parseInt(_0x35117a(0x16b))/0x6)+-parseInt(_0x35117a(0x15b))/0x7+-parseInt(_0x35117a(0x165))/0x8+-parseInt(_0x35117a(0x167))/0x9*(parseInt(_0x35117a(0x166))/0xa)+parseInt(_0x35117a(0x16a))/0xb;if(_0x50f8e9===_0x44fc9c)break;else _0x235e30['push'](_0x235e30['shift']());}catch(_0x1ca032){_0x235e30['push'](_0x235e30['shift']());}}}(a148_0x4255,0xd4ba7));import a148_0x3d7a0b from'node:path';function a148_0x29c0(_0x324b24,_0x5683ed){_0x324b24=_0x324b24-0x159;const _0x42559e=a148_0x4255();let _0x29c0fb=_0x42559e[_0x324b24];return _0x29c0fb;}import{execa}from'execa';import{formatElapsed}from'../../../commands/project/create/format-elapsed.js';import{logger}from'../../../utils/logger.js';import{resolveNpmBin}from'../../../utils/platform.js';export async function formatProjectCode(_0x4f2c8b){const _0x1ad56b=a148_0x29c0,_0x1e1b25=Date[_0x1ad56b(0x159)](),_0x354533=a148_0x3d7a0b[_0x1ad56b(0x16e)](process[_0x1ad56b(0x15a)](),_0x4f2c8b);try{logger[_0x1ad56b(0x162)](_0x1ad56b(0x15c),_0x1ad56b(0x15f),{'projectCode':_0x4f2c8b}),await execa(resolveNpmBin(_0x1ad56b(0x160)),[_0x1ad56b(0x163),'--write','.'],{'cwd':_0x354533});const _0x45ef38=Date[_0x1ad56b(0x159)]()-_0x1e1b25;logger[_0x1ad56b(0x15e)](_0x1ad56b(0x15c),'代码格式化完成',_0x45ef38,{'projectCode':_0x4f2c8b});}catch(_0x50a33c){const _0x4b5700=Date['now']()-_0x1e1b25;logger['error'](_0x1ad56b(0x15c),_0x1ad56b(0x164),{'projectCode':_0x4f2c8b,'error':_0x50a33c instanceof Error?_0x50a33c[_0x1ad56b(0x168)]:String(_0x50a33c),'duration':_0x4b5700});throw _0x50a33c;}return formatElapsed(_0x1e1b25);}function a148_0x4255(){const _0x217943=['31911iwrPuq','resolve','now','cwd','4247166jPzmWD','format','212jEHgfs','success','开始格式化代码','npx','6PrrWSB','info','prettier','代码格式化失败','934208AZxuKr','20JNuylz','649215fHiOTl','message','119204CfLRvH','33686400xQUKRu','6702792pDqbLC','5RYoxvc'];a148_0x4255=function(){return _0x217943;};return a148_0x4255();}
1
+ function a148_0x23df(_0x4aa2b9,_0x162aae){_0x4aa2b9=_0x4aa2b9-0xb0;const _0x37b67a=a148_0x37b6();let _0x23df62=_0x37b67a[_0x4aa2b9];return _0x23df62;}(function(_0x87a488,_0x4056bf){const _0x52af18=a148_0x23df,_0xa237eb=_0x87a488();while(!![]){try{const _0x3b4d94=parseInt(_0x52af18(0xb0))/0x1*(parseInt(_0x52af18(0xb9))/0x2)+-parseInt(_0x52af18(0xc6))/0x3+-parseInt(_0x52af18(0xc5))/0x4*(-parseInt(_0x52af18(0xbd))/0x5)+parseInt(_0x52af18(0xb6))/0x6+-parseInt(_0x52af18(0xc1))/0x7*(-parseInt(_0x52af18(0xb3))/0x8)+parseInt(_0x52af18(0xc7))/0x9+parseInt(_0x52af18(0xb7))/0xa*(-parseInt(_0x52af18(0xc2))/0xb);if(_0x3b4d94===_0x4056bf)break;else _0xa237eb['push'](_0xa237eb['shift']());}catch(_0x5cc02e){_0xa237eb['push'](_0xa237eb['shift']());}}}(a148_0x37b6,0xa3fa5));function a148_0x37b6(){const _0xf5a659=['522332uQllvy','3771780EKTCMY','6522210MQKMIX','526065IlHAJy','resolve','info','856ATeQgc','npx','代码格式化失败','2824224JEEUUq','10BtUJhy','format','2aNgzAt','success','开始格式化代码','message','40PSbgNB','cwd','--write','代码格式化完成','42259PgfzNa','16314859bFfkxN','now','prettier'];a148_0x37b6=function(){return _0xf5a659;};return a148_0x37b6();}import a148_0x350b63 from'node:path';import{execa}from'execa';import{formatElapsed}from'../../../commands/project/create/format-elapsed.js';import{logger}from'../../../utils/logger.js';import{resolveNpmBin}from'../../../utils/platform.js';export async function formatProjectCode(_0x4009e6){const _0x1a95f4=a148_0x23df,_0x79b19e=Date[_0x1a95f4(0xc3)](),_0x5e7876=a148_0x350b63[_0x1a95f4(0xb1)](process[_0x1a95f4(0xbe)](),_0x4009e6);try{logger[_0x1a95f4(0xb2)]('format',_0x1a95f4(0xbb),{'projectCode':_0x4009e6}),await execa(resolveNpmBin(_0x1a95f4(0xb4)),[_0x1a95f4(0xc4),_0x1a95f4(0xbf),'.'],{'cwd':_0x5e7876});const _0x3527b4=Date[_0x1a95f4(0xc3)]()-_0x79b19e;logger[_0x1a95f4(0xba)](_0x1a95f4(0xb8),_0x1a95f4(0xc0),_0x3527b4,{'projectCode':_0x4009e6});}catch(_0x580fde){const _0x2b3cac=Date[_0x1a95f4(0xc3)]()-_0x79b19e;logger['error']('format',_0x1a95f4(0xb5),{'projectCode':_0x4009e6,'error':_0x580fde instanceof Error?_0x580fde[_0x1a95f4(0xbc)]:String(_0x580fde),'duration':_0x2b3cac});throw _0x580fde;}return formatElapsed(_0x79b19e);}
@@ -1 +1 @@
1
- (function(_0x16d576,_0x332e3b){const _0xd5d326=a149_0x5e3f,_0x3cc406=_0x16d576();while(!![]){try{const _0x57fc57=parseInt(_0xd5d326(0x7d))/0x1+parseInt(_0xd5d326(0x84))/0x2+parseInt(_0xd5d326(0x86))/0x3*(-parseInt(_0xd5d326(0x79))/0x4)+parseInt(_0xd5d326(0x8c))/0x5+parseInt(_0xd5d326(0x87))/0x6*(-parseInt(_0xd5d326(0x83))/0x7)+parseInt(_0xd5d326(0x85))/0x8+-parseInt(_0xd5d326(0x8b))/0x9;if(_0x57fc57===_0x332e3b)break;else _0x3cc406['push'](_0x3cc406['shift']());}catch(_0x2394d7){_0x3cc406['push'](_0x3cc406['shift']());}}}(a149_0x5ca8,0x4cae4));function a149_0x5e3f(_0xcb543b,_0x310a52){_0xcb543b=_0xcb543b-0x79;const _0x5ca8ae=a149_0x5ca8();let _0x5e3fa3=_0x5ca8ae[_0xcb543b];return _0x5e3fa3;}import a149_0x4dfb7e from'node:path';import{execa}from'execa';import{formatElapsed}from'../../../commands/project/create/format-elapsed.js';import{logger}from'../../../utils/logger.js';import{resolveNpmBin}from'../../../utils/platform.js';function a149_0x5ca8(){const _0xfdb4ec=['now','依赖安装失败','resolve','info','1211OEgzAw','762082VFGHje','4266552uflSLM','962391hnFfnZ','1518dddGlF','https://registry.npmmirror.com','npm','success','6179895EBAHhn','416075YtBUyv','4MfinWK','error','install','message','367730pWSGZv','cwd'];a149_0x5ca8=function(){return _0xfdb4ec;};return a149_0x5ca8();}export async function installDependencies(_0xe708d5){const _0x3c8d61=a149_0x5e3f,_0x5afa22=Date[_0x3c8d61(0x7f)](),_0x580fa6=a149_0x4dfb7e[_0x3c8d61(0x81)](process[_0x3c8d61(0x7e)](),_0xe708d5);try{logger[_0x3c8d61(0x82)](_0x3c8d61(0x7b),'开始安装依赖',{'projectCode':_0xe708d5,'registry':'https://registry.npmmirror.com'}),await execa(resolveNpmBin(_0x3c8d61(0x89)),[_0x3c8d61(0x7b),'--registry',_0x3c8d61(0x88)],{'cwd':_0x580fa6});const _0x539e58=Date[_0x3c8d61(0x7f)]()-_0x5afa22;logger[_0x3c8d61(0x8a)](_0x3c8d61(0x7b),'依赖安装完成',_0x539e58,{'projectCode':_0xe708d5});}catch(_0x31f920){const _0x1c1da0=Date[_0x3c8d61(0x7f)]()-_0x5afa22;logger[_0x3c8d61(0x7a)](_0x3c8d61(0x7b),_0x3c8d61(0x80),{'projectCode':_0xe708d5,'error':_0x31f920 instanceof Error?_0x31f920[_0x3c8d61(0x7c)]:String(_0x31f920),'duration':_0x1c1da0});throw _0x31f920;}return formatElapsed(_0x5afa22);}
1
+ (function(_0x45801a,_0x2dc86d){const _0x3854ca=a149_0x21c5,_0x1a3eac=_0x45801a();while(!![]){try{const _0x31e006=-parseInt(_0x3854ca(0xe2))/0x1+-parseInt(_0x3854ca(0xea))/0x2*(parseInt(_0x3854ca(0xe3))/0x3)+-parseInt(_0x3854ca(0xf2))/0x4*(parseInt(_0x3854ca(0xf3))/0x5)+-parseInt(_0x3854ca(0xe7))/0x6+parseInt(_0x3854ca(0xef))/0x7+parseInt(_0x3854ca(0xed))/0x8*(parseInt(_0x3854ca(0xe0))/0x9)+parseInt(_0x3854ca(0xec))/0xa;if(_0x31e006===_0x2dc86d)break;else _0x1a3eac['push'](_0x1a3eac['shift']());}catch(_0x574462){_0x1a3eac['push'](_0x1a3eac['shift']());}}}(a149_0x2001,0x7b858));import a149_0x2883e8 from'node:path';function a149_0x21c5(_0x5d6ee2,_0x42288f){_0x5d6ee2=_0x5d6ee2-0xde;const _0x2001cc=a149_0x2001();let _0x21c5ac=_0x2001cc[_0x5d6ee2];return _0x21c5ac;}import{execa}from'execa';import{formatElapsed}from'../../../commands/project/create/format-elapsed.js';import{logger}from'../../../utils/logger.js';import{resolveNpmBin}from'../../../utils/platform.js';function a149_0x2001(){const _0x466a89=['message','7029380BHIPSx','16BLKJQX','error','2350642ylflvM','now','install','20wPrmMY','537265xUQYba','npm','https://registry.npmmirror.com','4100994uGGXmc','依赖安装失败','417405CDEFNd','1410891rhghRs','依赖安装完成','cwd','resolve','114990SOjepR','--registry','info','2rxyCKq'];a149_0x2001=function(){return _0x466a89;};return a149_0x2001();}export async function installDependencies(_0xf2e784){const _0x21f742=a149_0x21c5,_0x519811=Date['now'](),_0x148435=a149_0x2883e8[_0x21f742(0xe6)](process[_0x21f742(0xe5)](),_0xf2e784);try{logger[_0x21f742(0xe9)](_0x21f742(0xf1),'开始安装依赖',{'projectCode':_0xf2e784,'registry':_0x21f742(0xdf)}),await execa(resolveNpmBin(_0x21f742(0xde)),[_0x21f742(0xf1),_0x21f742(0xe8),_0x21f742(0xdf)],{'cwd':_0x148435});const _0x2753cb=Date['now']()-_0x519811;logger['success']('install',_0x21f742(0xe4),_0x2753cb,{'projectCode':_0xf2e784});}catch(_0x2cb814){const _0x4e1323=Date[_0x21f742(0xf0)]()-_0x519811;logger[_0x21f742(0xee)](_0x21f742(0xf1),_0x21f742(0xe1),{'projectCode':_0xf2e784,'error':_0x2cb814 instanceof Error?_0x2cb814[_0x21f742(0xeb)]:String(_0x2cb814),'duration':_0x4e1323});throw _0x2cb814;}return formatElapsed(_0x519811);}
@@ -1 +1 @@
1
- function a150_0x3a62(_0x425368,_0x487558){_0x425368=_0x425368-0x1b7;const _0x18e272=a150_0x18e2();let _0x3a62ca=_0x18e272[_0x425368];return _0x3a62ca;}const a150_0x15dbf2=a150_0x3a62;(function(_0x1770dc,_0xf85967){const _0xcb0418=a150_0x3a62,_0x7ff10e=_0x1770dc();while(!![]){try{const _0x2aee5b=parseInt(_0xcb0418(0x1c9))/0x1+-parseInt(_0xcb0418(0x1cd))/0x2*(parseInt(_0xcb0418(0x1db))/0x3)+parseInt(_0xcb0418(0x1c6))/0x4*(parseInt(_0xcb0418(0x1d0))/0x5)+parseInt(_0xcb0418(0x1c8))/0x6*(parseInt(_0xcb0418(0x1dc))/0x7)+-parseInt(_0xcb0418(0x1d6))/0x8*(-parseInt(_0xcb0418(0x1cc))/0x9)+-parseInt(_0xcb0418(0x1c4))/0xa+-parseInt(_0xcb0418(0x1ca))/0xb;if(_0x2aee5b===_0xf85967)break;else _0x7ff10e['push'](_0x7ff10e['shift']());}catch(_0x3a4c08){_0x7ff10e['push'](_0x7ff10e['shift']());}}}(a150_0x18e2,0x792cb));function a150_0x18e2(){const _0x291d16=['create','string','upgrade','\x20project\x20create\x20<project-name>\x20[--appcode\x20<code>]','Create\x20a\x20new\x20project','Auto-confirm\x20prompts','Project\x20name','name','appcode','nonInteractive','../../commands/project/create/non-interactive.js','str','project','2534920jpwDNX','boolean','137828IUYOHh','trim','6qFWcVm','914075xLRiGA','8752645eLsNwb','App\x20code\x20to\x20bind\x20(skips\x20interactive\x20selection)','9ojQPht','250meWOYf','Skip\x20confirmation\x20prompt','Target\x20environment','10YwNrKd','env','validation','bool','\x20workspace\x20init','cookie','6384272oyMrrm','Upgrade\x20from\x20lovrabet-cli\x20to\x20rabetbase-cli','Usage:\x20','yes','App\x20code\x20to\x20initialize','9717HLuypG','1185590OnDsQU','2026-07','args'];a150_0x18e2=function(){return _0x291d16;};return a150_0x18e2();}import{CliErrors}from'../../errors.js';import{CLI_BIN_NAME}from'../../constant/cli.js';import{initConfig}from'../../commands/project/init.js';import{upgradeApp}from'../../commands/project/upgrade.js';const initFlags=[{'name':a150_0x15dbf2(0x1bf),'type':'string','description':a150_0x15dbf2(0x1da)},{'name':a150_0x15dbf2(0x1d1),'type':'string','description':a150_0x15dbf2(0x1cf)},{'name':'yes','type':a150_0x15dbf2(0x1c5),'description':a150_0x15dbf2(0x1bc),'default':![]}],createFlags=[{'name':a150_0x15dbf2(0x1be),'type':a150_0x15dbf2(0x1b8),'description':a150_0x15dbf2(0x1bd)},{'name':a150_0x15dbf2(0x1d1),'type':a150_0x15dbf2(0x1b8),'description':a150_0x15dbf2(0x1cf)},{'name':a150_0x15dbf2(0x1bf),'type':a150_0x15dbf2(0x1b8),'description':a150_0x15dbf2(0x1cb)}],upgradeFlags=[{'name':a150_0x15dbf2(0x1d9),'type':'boolean','description':a150_0x15dbf2(0x1ce),'default':![]}];export const projectDefinitions=[{'service':a150_0x15dbf2(0x1c3),'command':'init','description':'Deprecated:\x20use\x20workspace\x20init\x20to\x20bind\x20the\x20current\x20directory\x20to\x20an\x20app','risk':'write','requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'hidden':!![],'deprecated':{'replacement':CLI_BIN_NAME+a150_0x15dbf2(0x1d4),'since':a150_0x15dbf2(0x1dd)},'flags':initFlags,async 'execute'(_0x54d462){const _0x56058f=a150_0x15dbf2;return await initConfig({'appcode':_0x54d462['str'](_0x56058f(0x1bf))||undefined,'env':_0x54d462['str'](_0x56058f(0x1d1))||undefined,'autoYes':_0x54d462[_0x56058f(0x1d3)](_0x56058f(0x1d9))}),{'ok':!![]};}},{'service':a150_0x15dbf2(0x1c3),'command':a150_0x15dbf2(0x1b7),'description':a150_0x15dbf2(0x1bb),'risk':'write','requiresAuth':!![],'requiresAppCode':![],'hasFormat':![],'args':[{'name':'project-name','description':'Project\x20code/name\x20(optional,\x20prompts\x20if\x20omitted)','required':![]}],'flags':createFlags,async 'execute'(_0x593eac){const _0x43db77=a150_0x15dbf2,{createApp:_0x14f92c}=await import('../../commands/project/create/main.js'),{createProjectNonInteractive:_0x5cfcaf}=await import(_0x43db77(0x1c1)),_0x15d62d=_0x593eac['str'](_0x43db77(0x1be))[_0x43db77(0x1c7)]()||_0x593eac[_0x43db77(0x1de)][0x0]?.[_0x43db77(0x1c7)](),_0x4a02bd=_0x593eac[_0x43db77(0x1c2)](_0x43db77(0x1d1))||undefined,_0x369f90=_0x593eac[_0x43db77(0x1c2)](_0x43db77(0x1bf))||undefined;if(_0x593eac[_0x43db77(0x1c0)]){if(!_0x15d62d)throw CliErrors[_0x43db77(0x1d2)]('Non-interactive\x20mode\x20requires\x20a\x20project\x20name.',_0x43db77(0x1d8)+CLI_BIN_NAME+_0x43db77(0x1ba));await _0x5cfcaf(_0x15d62d,_0x4a02bd,_0x369f90,_0x593eac[_0x43db77(0x1d5)]);}else await _0x14f92c({'projectCode':_0x15d62d,'appCode':_0x369f90,'env':_0x4a02bd,'cookie':_0x593eac[_0x43db77(0x1d5)]});return{'ok':!![]};}},{'service':'project','command':a150_0x15dbf2(0x1b9),'description':a150_0x15dbf2(0x1d7),'risk':'write','requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':upgradeFlags,async 'execute'(_0x408274){const _0x2dc49d=a150_0x15dbf2;return await upgradeApp(_0x408274[_0x2dc49d(0x1c0)],{'yes':_0x408274[_0x2dc49d(0x1d3)](_0x2dc49d(0x1d9))}),{'ok':!![]};}}];
1
+ const a150_0x57cdad=a150_0x93cc;(function(_0x1a1c2b,_0x33f706){const _0x49604d=a150_0x93cc,_0x51acc0=_0x1a1c2b();while(!![]){try{const _0x4f42bb=parseInt(_0x49604d(0x75))/0x1*(-parseInt(_0x49604d(0x72))/0x2)+-parseInt(_0x49604d(0x8c))/0x3*(parseInt(_0x49604d(0x77))/0x4)+parseInt(_0x49604d(0x82))/0x5*(parseInt(_0x49604d(0x7c))/0x6)+-parseInt(_0x49604d(0x8f))/0x7+-parseInt(_0x49604d(0x92))/0x8*(parseInt(_0x49604d(0x90))/0x9)+-parseInt(_0x49604d(0x87))/0xa+-parseInt(_0x49604d(0x67))/0xb*(-parseInt(_0x49604d(0x8d))/0xc);if(_0x4f42bb===_0x33f706)break;else _0x51acc0['push'](_0x51acc0['shift']());}catch(_0x411751){_0x51acc0['push'](_0x51acc0['shift']());}}}(a150_0x1fc0,0xc69e6));import{CliErrors}from'../../errors.js';import{CLI_BIN_NAME}from'../../constant/cli.js';import{initConfig}from'../../commands/project/init.js';function a150_0x1fc0(){const _0x44f833=['../../commands/project/create/non-interactive.js','upgrade','340JBFzss','boolean','Target\x20environment','Upgrade\x20from\x20lovrabet-cli\x20to\x20rabetbase-cli','string','3975250kjqyQn','create','str','appcode','write','21cAStAb','108StTNVU','yes','2892183EywsJv','207pxVMfK','Create\x20a\x20new\x20project','437704cuYkAL','env','4568069uRxeyK','init','App\x20code\x20to\x20initialize','trim','Project\x20code/name\x20(optional,\x20prompts\x20if\x20omitted)','Usage:\x20','Skip\x20confirmation\x20prompt','project-name','\x20workspace\x20init','../../commands/project/create/main.js','name','130082YuHADu','project','nonInteractive','17cuZBKU','validation','512660zYEHxU','cookie','Non-interactive\x20mode\x20requires\x20a\x20project\x20name.','Project\x20name','2026-07','101292dDDJhy','bool','Auto-confirm\x20prompts','App\x20code\x20to\x20bind\x20(skips\x20interactive\x20selection)'];a150_0x1fc0=function(){return _0x44f833;};return a150_0x1fc0();}function a150_0x93cc(_0x11c6e6,_0x4cd856){_0x11c6e6=_0x11c6e6-0x67;const _0x1fc008=a150_0x1fc0();let _0x93cc37=_0x1fc008[_0x11c6e6];return _0x93cc37;}import{upgradeApp}from'../../commands/project/upgrade.js';const initFlags=[{'name':a150_0x57cdad(0x8a),'type':'string','description':a150_0x57cdad(0x69)},{'name':a150_0x57cdad(0x93),'type':a150_0x57cdad(0x86),'description':a150_0x57cdad(0x84)},{'name':'yes','type':'boolean','description':a150_0x57cdad(0x7e),'default':![]}],createFlags=[{'name':a150_0x57cdad(0x71),'type':a150_0x57cdad(0x86),'description':a150_0x57cdad(0x7a)},{'name':'env','type':'string','description':a150_0x57cdad(0x84)},{'name':'appcode','type':a150_0x57cdad(0x86),'description':a150_0x57cdad(0x7f)}],upgradeFlags=[{'name':a150_0x57cdad(0x8e),'type':a150_0x57cdad(0x83),'description':a150_0x57cdad(0x6d),'default':![]}];export const projectDefinitions=[{'service':a150_0x57cdad(0x73),'command':a150_0x57cdad(0x68),'description':'Deprecated:\x20use\x20workspace\x20init\x20to\x20bind\x20the\x20current\x20directory\x20to\x20an\x20app','risk':a150_0x57cdad(0x8b),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'hidden':!![],'deprecated':{'replacement':CLI_BIN_NAME+a150_0x57cdad(0x6f),'since':a150_0x57cdad(0x7b)},'flags':initFlags,async 'execute'(_0x106c2a){const _0x3f3cff=a150_0x57cdad;return await initConfig({'appcode':_0x106c2a[_0x3f3cff(0x89)](_0x3f3cff(0x8a))||undefined,'env':_0x106c2a['str'](_0x3f3cff(0x93))||undefined,'autoYes':_0x106c2a[_0x3f3cff(0x7d)](_0x3f3cff(0x8e))}),{'ok':!![]};}},{'service':a150_0x57cdad(0x73),'command':a150_0x57cdad(0x88),'description':a150_0x57cdad(0x91),'risk':'write','requiresAuth':!![],'requiresAppCode':![],'hasFormat':![],'args':[{'name':a150_0x57cdad(0x6e),'description':a150_0x57cdad(0x6b),'required':![]}],'flags':createFlags,async 'execute'(_0x58b636){const _0x23c34c=a150_0x57cdad,{createApp:_0x4a8ccf}=await import(_0x23c34c(0x70)),{createProjectNonInteractive:_0x39d6fd}=await import(_0x23c34c(0x80)),_0x305411=_0x58b636[_0x23c34c(0x89)]('name')[_0x23c34c(0x6a)]()||_0x58b636['args'][0x0]?.[_0x23c34c(0x6a)](),_0x3c3f44=_0x58b636[_0x23c34c(0x89)](_0x23c34c(0x93))||undefined,_0xa6b6d8=_0x58b636[_0x23c34c(0x89)](_0x23c34c(0x8a))||undefined;if(_0x58b636[_0x23c34c(0x74)]){if(!_0x305411)throw CliErrors[_0x23c34c(0x76)](_0x23c34c(0x79),_0x23c34c(0x6c)+CLI_BIN_NAME+'\x20project\x20create\x20<project-name>\x20[--appcode\x20<code>]');await _0x39d6fd(_0x305411,_0x3c3f44,_0xa6b6d8,_0x58b636[_0x23c34c(0x78)]);}else await _0x4a8ccf({'projectCode':_0x305411,'appCode':_0xa6b6d8,'env':_0x3c3f44,'cookie':_0x58b636[_0x23c34c(0x78)]});return{'ok':!![]};}},{'service':a150_0x57cdad(0x73),'command':a150_0x57cdad(0x81),'description':a150_0x57cdad(0x85),'risk':a150_0x57cdad(0x8b),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':upgradeFlags,async 'execute'(_0xe30bce){const _0x5a734c=a150_0x57cdad;return await upgradeApp(_0xe30bce[_0x5a734c(0x74)],{'yes':_0xe30bce[_0x5a734c(0x7d)](_0x5a734c(0x8e))}),{'ok':!![]};}}];
@@ -1 +1 @@
1
- (function(_0x2c6ca7,_0x59b8ec){const _0x546d15=a151_0x5a19,_0x5e6fcd=_0x2c6ca7();while(!![]){try{const _0x404b6b=-parseInt(_0x546d15(0x12f))/0x1+parseInt(_0x546d15(0x147))/0x2+-parseInt(_0x546d15(0x135))/0x3+-parseInt(_0x546d15(0x136))/0x4+parseInt(_0x546d15(0x140))/0x5+-parseInt(_0x546d15(0x159))/0x6+parseInt(_0x546d15(0x142))/0x7;if(_0x404b6b===_0x59b8ec)break;else _0x5e6fcd['push'](_0x5e6fcd['shift']());}catch(_0x13b806){_0x5e6fcd['push'](_0x5e6fcd['shift']());}}}(a151_0x5925,0x6e430));import{readFileSync,existsSync,renameSync}from'node:fs';function a151_0x5925(){const _0x5ad315=['✓\x20Successfully\x20initialized\x20.rabetbase.json\x20in\x20current\x20directory','\x20\x20Default:\x20','info','888222KsMKFZ','green','.rabetbase.json\x20already\x20exists\x20in\x20current\x20directory.\x20Nothing\x20to\x20do.','bold','\x20\x20Apps:\x20','初始化项目配置文件成功','2582466ZqJfsv','1224396zJsaFq','\x20workspace\x20init`\x20to\x20start\x20fresh.','join','\x20\x20appcode:\x20','Please\x20enter\x20App\x20Code:','string','Upgrade\x20it\x20to\x20','\x20\x20You\x20can\x20now\x20use\x20commands\x20like\x20\x27','App\x20Code\x20cannot\x20be\x20empty','production','2087080cWzslI','✓\x20Upgraded\x20','13471353ERfrpD','.bak','apps','version','setLogPath','1434840gbGfbk','log','\x20\x20Old\x20file\x20backed\x20up\x20as\x20','utf8','app','trim','toLocaleString','⚠\x20Found\x20legacy\x20configuration\x20file:\x20','\x20api\x20generate\x27\x20and\x20\x27','init','.rabetbase.json','\x20api\x20pull\x27','keys','从旧配置文件升级成功','env','\x20→\x20.rabetbase.json','defaultApp','1.0.0','3315240UEsznc','../..','cyan','Invalid\x20App\x20Code','appcode','parse'];a151_0x5925=function(){return _0x5ad315;};return a151_0x5925();}import{resolve,dirname,basename}from'node:path';import{fileURLToPath}from'node:url';import a151_0x5998c3 from'chalk';import{input,confirm}from'@inquirer/prompts';function a151_0x5a19(_0x7cf4a8,_0x2b4f4f){_0x7cf4a8=_0x7cf4a8-0x12b;const _0x5925ad=a151_0x5925();let _0x5a1941=_0x5925ad[_0x7cf4a8];return _0x5a1941;}import{CLI_BIN_NAME}from'../../constant/cli.js';import{logger}from'../../utils/logger.js';import{readRawConfig,getProjectConfigPath,writeConfigFile,NEW_CONFIG_NAME,LEGACY_CONFIG_NAMES}from'../../context.js';import{validateAppcode}from'../../commands/common/validate.js';import{buildCanonicalProjectConfig}from'../../config/schema.js';export async function initConfig(_0x37ec2f){const _0x38891c=a151_0x5a19,{appcode:_0x39474c,env:_0x46d7bd,autoYes:_0x1dbe72}=_0x37ec2f,_0x374146=process['cwd']();if(getProjectConfigPath())throw new Error(_0x38891c(0x131));let _0x9d196b;for(const _0xa52981 of LEGACY_CONFIG_NAMES){const _0x2460f4=resolve(_0x374146,_0xa52981);if(existsSync(_0x2460f4)){_0x9d196b=_0x2460f4;break;}}if(_0x9d196b){let _0x55a408={};try{_0x55a408=JSON['parse'](readFileSync(_0x9d196b,_0x38891c(0x14a)));}catch{}const _0x1b5e1b=basename(_0x9d196b),_0x4b1662=_0x55a408?.[_0x38891c(0x15d)]||_0x55a408?.[_0x38891c(0x14b)];let _0x2c2da5=_0x1dbe72;!_0x1dbe72&&(console[_0x38891c(0x148)](a151_0x5998c3['yellow'](_0x38891c(0x14e)+a151_0x5998c3[_0x38891c(0x132)](_0x1b5e1b))),_0x4b1662&&console[_0x38891c(0x148)](a151_0x5998c3[_0x38891c(0x15b)](_0x38891c(0x139)+_0x4b1662)),_0x2c2da5=await confirm({'message':_0x38891c(0x13c)+a151_0x5998c3[_0x38891c(0x132)](_0x38891c(0x151))+'?\x20(Old\x20file\x20→\x20*.bak)','default':!![]}));if(!_0x2c2da5){console[_0x38891c(0x148)]('Migration\x20cancelled.\x20Run\x20`'+CLI_BIN_NAME+_0x38891c(0x137));return;}const _0x510611=resolve(_0x374146,NEW_CONFIG_NAME),_0x2f6d1d=getCliVersionFromPkg(),_0x212ee0=readRawConfig(),_0x13d1ba=_0x39474c||(typeof _0x55a408?.[_0x38891c(0x15d)]===_0x38891c(0x13b)?_0x55a408[_0x38891c(0x15d)]:undefined)||(typeof _0x55a408?.[_0x38891c(0x14b)]===_0x38891c(0x13b)?_0x55a408[_0x38891c(0x14b)]:undefined)||await askAppcode(),_0x426783=typeof _0x55a408?.[_0x38891c(0x155)]===_0x38891c(0x13b)?_0x55a408[_0x38891c(0x155)]:typeof _0x212ee0[_0x38891c(0x155)]==='string'?_0x212ee0[_0x38891c(0x155)]:'production',_0x408121=buildCanonicalProjectConfig({..._0x212ee0,..._0x55a408},{'appCodes':[_0x13d1ba],'env':_0x426783,'metadata':{'version':_0x2f6d1d,'migratedAt':new Date()[_0x38891c(0x14d)](),'migratedFrom':_0x9d196b}});writeConfigFile(_0x510611,_0x408121);const _0x32fc8b=_0x9d196b+_0x38891c(0x143);renameSync(_0x9d196b,_0x32fc8b),logger['setLogPath'](_0x374146),logger[_0x38891c(0x12e)]('init',_0x38891c(0x154),{'from':_0x9d196b,'to':_0x510611,'appcode':_0x13d1ba,'env':_0x408121[_0x38891c(0x155)]}),console[_0x38891c(0x148)](a151_0x5998c3[_0x38891c(0x130)](_0x38891c(0x141)+_0x1b5e1b+_0x38891c(0x156))),console[_0x38891c(0x148)](a151_0x5998c3[_0x38891c(0x15b)](_0x38891c(0x133)+Object[_0x38891c(0x153)](_0x408121[_0x38891c(0x144)]||{})[_0x38891c(0x138)](',\x20'))),console[_0x38891c(0x148)](a151_0x5998c3[_0x38891c(0x15b)]('\x20\x20Default:\x20'+_0x408121['defaultApp'])),console['log'](a151_0x5998c3['gray'](_0x38891c(0x149)+_0x1b5e1b+'.bak'));return;}const _0x15c7bc=_0x39474c||await askAppcode(),_0x4062fd=resolve(_0x374146,NEW_CONFIG_NAME),_0x5dd942=getCliVersionFromPkg(),_0x5dad81=readRawConfig(),_0x24660c=typeof _0x5dad81[_0x38891c(0x155)]===_0x38891c(0x13b)?_0x5dad81[_0x38891c(0x155)]:undefined,_0x86c127=buildCanonicalProjectConfig({},{'appCodes':[_0x15c7bc],'env':_0x46d7bd||_0x24660c||_0x38891c(0x13f),'metadata':{'version':_0x5dd942,'createdAt':new Date()[_0x38891c(0x14d)]()}});writeConfigFile(_0x4062fd,_0x86c127),logger[_0x38891c(0x146)](_0x374146),logger['info'](_0x38891c(0x150),_0x38891c(0x134),{'appcode':_0x15c7bc,'env':_0x86c127['env'],'version':_0x86c127[_0x38891c(0x145)],'configPath':_0x4062fd}),console['log'](a151_0x5998c3['green'](_0x38891c(0x12c))),console[_0x38891c(0x148)](a151_0x5998c3['cyan'](_0x38891c(0x133)+Object[_0x38891c(0x153)](_0x86c127[_0x38891c(0x144)]||{})[_0x38891c(0x138)](',\x20'))),console[_0x38891c(0x148)](a151_0x5998c3[_0x38891c(0x15b)](_0x38891c(0x12d)+_0x86c127[_0x38891c(0x157)])),console[_0x38891c(0x148)](_0x38891c(0x13d)+CLI_BIN_NAME+_0x38891c(0x14f)+CLI_BIN_NAME+_0x38891c(0x152));}function askAppcode(){const _0x13104b=a151_0x5a19;return input({'message':_0x13104b(0x13a),'validate':_0x82a9a3=>{const _0x26132f=_0x13104b;if(!_0x82a9a3[_0x26132f(0x14c)]())return _0x26132f(0x13e);const {valid:_0x47b1d4,message:_0x394813}=validateAppcode(_0x82a9a3[_0x26132f(0x14c)]());return _0x47b1d4||_0x394813||_0x26132f(0x15c);}});}function getCliVersionFromPkg(){const _0x193a7c=a151_0x5a19;try{const _0x3e5d74=fileURLToPath(import.meta.url),_0x5e8fe9=resolve(dirname(_0x3e5d74),_0x193a7c(0x15a)),_0x484b45=JSON[_0x193a7c(0x12b)](readFileSync(resolve(_0x5e8fe9,'package.json'),'utf8'));return _0x484b45[_0x193a7c(0x145)]||'1.0.0';}catch{return _0x193a7c(0x158);}}
1
+ (function(_0x512773,_0x2550e2){const _0x464f05=a151_0x2129,_0x2aaf8a=_0x512773();while(!![]){try{const _0x1d3975=-parseInt(_0x464f05(0xce))/0x1+-parseInt(_0x464f05(0xd5))/0x2+-parseInt(_0x464f05(0xcf))/0x3+parseInt(_0x464f05(0x100))/0x4+-parseInt(_0x464f05(0xeb))/0x5*(-parseInt(_0x464f05(0xee))/0x6)+-parseInt(_0x464f05(0xe2))/0x7+parseInt(_0x464f05(0xdc))/0x8*(parseInt(_0x464f05(0xf1))/0x9);if(_0x1d3975===_0x2550e2)break;else _0x2aaf8a['push'](_0x2aaf8a['shift']());}catch(_0x5b6277){_0x2aaf8a['push'](_0x2aaf8a['shift']());}}}(a151_0x3a7c,0xe10dd));import{readFileSync,existsSync,renameSync}from'node:fs';import{resolve,dirname,basename}from'node:path';import{fileURLToPath}from'node:url';import a151_0x3c8dea from'chalk';import{input,confirm}from'@inquirer/prompts';import{CLI_BIN_NAME}from'../../constant/cli.js';import{logger}from'../../utils/logger.js';import{readRawConfig,getProjectConfigPath,writeConfigFile,NEW_CONFIG_NAME,LEGACY_CONFIG_NAMES}from'../../context.js';import{validateAppcode}from'../../commands/common/validate.js';function a151_0x2129(_0x1740fa,_0x58b2e9){_0x1740fa=_0x1740fa-0xcc;const _0x3a7c94=a151_0x3a7c();let _0x212929=_0x3a7c94[_0x1740fa];return _0x212929;}import{buildCanonicalProjectConfig}from'../../config/schema.js';export async function initConfig(_0x8ff281){const _0x13a8f6=a151_0x2129,{appcode:_0x229fba,env:_0x395b86,autoYes:_0x14e1ed}=_0x8ff281,_0x58edb9=process[_0x13a8f6(0xda)]();if(getProjectConfigPath())throw new Error(_0x13a8f6(0xf5));let _0x1f71ed;for(const _0x4be56a of LEGACY_CONFIG_NAMES){const _0x5c4ba2=resolve(_0x58edb9,_0x4be56a);if(existsSync(_0x5c4ba2)){_0x1f71ed=_0x5c4ba2;break;}}if(_0x1f71ed){let _0x158fa7={};try{_0x158fa7=JSON[_0x13a8f6(0xd4)](readFileSync(_0x1f71ed,'utf8'));}catch{}const _0xce0fef=basename(_0x1f71ed),_0x1a7cd3=_0x158fa7?.[_0x13a8f6(0xf4)]||_0x158fa7?.[_0x13a8f6(0xff)];let _0x555484=_0x14e1ed;!_0x14e1ed&&(console['log'](a151_0x3c8dea[_0x13a8f6(0xe0)](_0x13a8f6(0xd8)+a151_0x3c8dea[_0x13a8f6(0xd2)](_0xce0fef))),_0x1a7cd3&&console[_0x13a8f6(0xea)](a151_0x3c8dea[_0x13a8f6(0xfe)](_0x13a8f6(0xf9)+_0x1a7cd3)),_0x555484=await confirm({'message':_0x13a8f6(0xf0)+a151_0x3c8dea['bold'](_0x13a8f6(0xec))+'?\x20(Old\x20file\x20→\x20*.bak)','default':!![]}));if(!_0x555484){console[_0x13a8f6(0xea)](_0x13a8f6(0xfd)+CLI_BIN_NAME+'\x20workspace\x20init`\x20to\x20start\x20fresh.');return;}const _0x28ea5b=resolve(_0x58edb9,NEW_CONFIG_NAME),_0x80eb4=getCliVersionFromPkg(),_0x1b745a=readRawConfig(),_0x4c7d7b=_0x229fba||(typeof _0x158fa7?.['appcode']===_0x13a8f6(0xe8)?_0x158fa7[_0x13a8f6(0xf4)]:undefined)||(typeof _0x158fa7?.['app']==='string'?_0x158fa7['app']:undefined)||await askAppcode(),_0x1243c5=typeof _0x158fa7?.['env']===_0x13a8f6(0xe8)?_0x158fa7[_0x13a8f6(0xf2)]:typeof _0x1b745a['env']===_0x13a8f6(0xe8)?_0x1b745a[_0x13a8f6(0xf2)]:_0x13a8f6(0xfc),_0x3a057f=buildCanonicalProjectConfig({..._0x1b745a,..._0x158fa7},{'appCodes':[_0x4c7d7b],'env':_0x1243c5,'metadata':{'version':_0x80eb4,'migratedAt':new Date()[_0x13a8f6(0xfb)](),'migratedFrom':_0x1f71ed}});writeConfigFile(_0x28ea5b,_0x3a057f);const _0x3875db=_0x1f71ed+_0x13a8f6(0xdb);renameSync(_0x1f71ed,_0x3875db),logger['setLogPath'](_0x58edb9),logger['info'](_0x13a8f6(0xe6),_0x13a8f6(0xd9),{'from':_0x1f71ed,'to':_0x28ea5b,'appcode':_0x4c7d7b,'env':_0x3a057f['env']}),console[_0x13a8f6(0xea)](a151_0x3c8dea[_0x13a8f6(0xcc)](_0x13a8f6(0xf8)+_0xce0fef+_0x13a8f6(0xe1))),console[_0x13a8f6(0xea)](a151_0x3c8dea[_0x13a8f6(0xfe)](_0x13a8f6(0xe7)+Object[_0x13a8f6(0xcd)](_0x3a057f[_0x13a8f6(0xe3)]||{})[_0x13a8f6(0xe5)](',\x20'))),console[_0x13a8f6(0xea)](a151_0x3c8dea['cyan']('\x20\x20Default:\x20'+_0x3a057f['defaultApp'])),console[_0x13a8f6(0xea)](a151_0x3c8dea[_0x13a8f6(0xdf)](_0x13a8f6(0xd0)+_0xce0fef+_0x13a8f6(0xdb)));return;}const _0x2cb899=_0x229fba||await askAppcode(),_0x112f03=resolve(_0x58edb9,NEW_CONFIG_NAME),_0x587c04=getCliVersionFromPkg(),_0x536aff=readRawConfig(),_0x579f72=typeof _0x536aff[_0x13a8f6(0xf2)]===_0x13a8f6(0xe8)?_0x536aff[_0x13a8f6(0xf2)]:undefined,_0x1ce0b9=buildCanonicalProjectConfig({},{'appCodes':[_0x2cb899],'env':_0x395b86||_0x579f72||_0x13a8f6(0xfc),'metadata':{'version':_0x587c04,'createdAt':new Date()['toLocaleString']()}});writeConfigFile(_0x112f03,_0x1ce0b9),logger[_0x13a8f6(0xd1)](_0x58edb9),logger['info'](_0x13a8f6(0xe6),_0x13a8f6(0xd3),{'appcode':_0x2cb899,'env':_0x1ce0b9[_0x13a8f6(0xf2)],'version':_0x1ce0b9[_0x13a8f6(0xde)],'configPath':_0x112f03}),console[_0x13a8f6(0xea)](a151_0x3c8dea[_0x13a8f6(0xcc)]('✓\x20Successfully\x20initialized\x20.rabetbase.json\x20in\x20current\x20directory')),console[_0x13a8f6(0xea)](a151_0x3c8dea['cyan'](_0x13a8f6(0xe7)+Object[_0x13a8f6(0xcd)](_0x1ce0b9[_0x13a8f6(0xe3)]||{})['join'](',\x20'))),console['log'](a151_0x3c8dea[_0x13a8f6(0xfe)]('\x20\x20Default:\x20'+_0x1ce0b9[_0x13a8f6(0xf7)])),console[_0x13a8f6(0xea)](_0x13a8f6(0xe9)+CLI_BIN_NAME+_0x13a8f6(0xd7)+CLI_BIN_NAME+_0x13a8f6(0xed));}function askAppcode(){const _0x20cb24=a151_0x2129;return input({'message':_0x20cb24(0xdd),'validate':_0x3f927e=>{const _0x4a4983=_0x20cb24;if(!_0x3f927e[_0x4a4983(0xf3)]())return _0x4a4983(0xe4);const {valid:_0x3c1a9b,message:_0x5557ea}=validateAppcode(_0x3f927e[_0x4a4983(0xf3)]());return _0x3c1a9b||_0x5557ea||'Invalid\x20App\x20Code';}});}function a151_0x3a7c(){const _0x3a4d41=['../..','toLocaleString','production','Migration\x20cancelled.\x20Run\x20`','cyan','app','5251860XmdgHw','green','keys','710068CkzMMl','1305402dIUKrf','\x20\x20Old\x20file\x20backed\x20up\x20as\x20','setLogPath','bold','初始化项目配置文件成功','parse','2071200mnJcCb','package.json','\x20api\x20generate\x27\x20and\x20\x27','⚠\x20Found\x20legacy\x20configuration\x20file:\x20','从旧配置文件升级成功','cwd','.bak','8PuXceN','Please\x20enter\x20App\x20Code:','version','gray','yellow','\x20→\x20.rabetbase.json','8325373IKPtVs','apps','App\x20Code\x20cannot\x20be\x20empty','join','init','\x20\x20Apps:\x20','string','\x20\x20You\x20can\x20now\x20use\x20commands\x20like\x20\x27','log','5JJMtWR','.rabetbase.json','\x20api\x20pull\x27','4058916MRUDth','1.0.0','Upgrade\x20it\x20to\x20','20722599QkxSxa','env','trim','appcode','.rabetbase.json\x20already\x20exists\x20in\x20current\x20directory.\x20Nothing\x20to\x20do.','utf8','defaultApp','✓\x20Upgraded\x20','\x20\x20appcode:\x20'];a151_0x3a7c=function(){return _0x3a4d41;};return a151_0x3a7c();}function getCliVersionFromPkg(){const _0x696757=a151_0x2129;try{const _0x3141e7=fileURLToPath(import.meta.url),_0x14ce9b=resolve(dirname(_0x3141e7),_0x696757(0xfa)),_0x1c36ca=JSON[_0x696757(0xd4)](readFileSync(resolve(_0x14ce9b,_0x696757(0xd6)),_0x696757(0xf6)));return _0x1c36ca['version']||_0x696757(0xef);}catch{return _0x696757(0xef);}}
@@ -1 +1 @@
1
- const a152_0x2bb5ba=a152_0x32c4;function a152_0x32c4(_0x41be82,_0x5afb04){_0x41be82=_0x41be82-0x160;const _0x38a10b=a152_0x38a1();let _0x32c42b=_0x38a10b[_0x41be82];return _0x32c42b;}(function(_0x1402b5,_0x106a14){const _0x33264b=a152_0x32c4,_0x100f43=_0x1402b5();while(!![]){try{const _0x104d05=-parseInt(_0x33264b(0x1bd))/0x1*(-parseInt(_0x33264b(0x196))/0x2)+-parseInt(_0x33264b(0x189))/0x3*(parseInt(_0x33264b(0x187))/0x4)+-parseInt(_0x33264b(0x1bf))/0x5*(parseInt(_0x33264b(0x1b3))/0x6)+parseInt(_0x33264b(0x193))/0x7*(parseInt(_0x33264b(0x160))/0x8)+-parseInt(_0x33264b(0x1a1))/0x9*(-parseInt(_0x33264b(0x1c3))/0xa)+-parseInt(_0x33264b(0x170))/0xb*(-parseInt(_0x33264b(0x181))/0xc)+parseInt(_0x33264b(0x1ab))/0xd*(parseInt(_0x33264b(0x1aa))/0xe);if(_0x104d05===_0x106a14)break;else _0x100f43['push'](_0x100f43['shift']());}catch(_0x2ee229){_0x100f43['push'](_0x100f43['shift']());}}}(a152_0x38a1,0x7a9c5));import a152_0x2593fe from'chalk';import a152_0x1f161a from'ora';import{existsSync,readFileSync,renameSync,rmSync,statSync,unlinkSync,writeFileSync}from'node:fs';import{resolve}from'node:path';import{CONFIG_NAMES,NEW_CONFIG_NAME,readConfigFile,writeConfigFile}from'../../context.js';import{CORE_IDE_CONFIGS}from'../../utils/ai_config.js';import{NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE,runNpxSkillsAddGlobal,runNpxSkillsRemove}from'../../skills/npx-skills-add.js';import{askConfirm}from'../../commands/menu/shared/inquirer.js';const LEGACY_CONFIG_NAMES=CONFIG_NAMES[a152_0x2bb5ba(0x180)](_0x1686f8=>_0x1686f8!==NEW_CONFIG_NAME);function a152_0x38a1(){const _0x273dea=['Step\x205/7:\x20Remove\x20old\x20skill\x20—\x20','Step\x202/7:\x20.lovrabet/\x20not\x20found,\x20skipped','length','Config\x20migration','step','.claude/skills/lovrabet','@lovrabet/sdk\x20has\x20been\x20updated\x20to\x20latest\x20in\x20package.json.','MCP\x20config:','message','5293178uGIBiD','===\x20Upgrade\x20Analysis\x20===','Step\x203/7:\x20Removing\x20legacy\x20IDE\x20skill\x20files...','Step\x206/7:\x20Install\x20new\x20skill\x20—\x20','parse','lovrabet/rabetbase\x20installed\x20globally','\x20\x20Action:\x20migrate\x20→\x20backup\x20old\x20as\x20.bak','push','\x20\x20\x20\x20\x20\x20\x20','error','\x20\x20Action:\x20delete','package.json','cyan','utf8','removed\x20','not\x20found\x20or\x20already\x20at\x20latest','filter','24ZiSZjY','\x20\x20Current\x20version\x20in\x20','\x20removed','inherit','gray','Step\x204/7:\x20MCP\x20config\x20—\x20','3954428mHnjMk','===\x20Upgrade\x20Summary\x20===','3ALTamM','Config\x20file:','\x20\x20bun\x20install','latest','needsSkillSwap','string','white','\x20from\x20','bold','yes','20006SBIpJn','done','\x20\x20Action:\x20remove\x20entries\x20containing\x20@lovrabet/dataset-mcp-server','62hTsbpG','Step\x203/7:\x20Legacy\x20artifacts\x20—\x20','Step\x201/7:\x20Config\x20migration\x20—\x20','mcpServers','.cursor/rules/lovrabet_rules.mdc','undefined','.bak','Skill\x20swap:','\x20\x20Action:\x20update\x20package.json\x20(you\x20will\x20need\x20to\x20re-run\x20install)','fields','@lovrabet/sdk','18gFEmcL','failed','not\x20found\x20(will\x20create)','Upgrade\x20@lovrabet/sdk','isArray','object','files','Step\x207/7:\x20Upgrading\x20@lovrabet/sdk\x20in\x20package.json...','devDependencies','4612328rxxklr','13DtcjcV','\x20(backup:\x20','Step\x202/7:\x20.lovrabet/\x20directory\x20removed','Clean\x20MCP\x20config','not\x20needed','log','Remove\x20.lovrabet/','[\x22@lovrabet/sdk\x22]:\x20','6MoZOyg','lovrabet/rabetbase','@lovrabet/sdk:','start','no\x20legacy\x20entry','keys','stringify','configMigration','yellow','status','12163nPLvCv','\x20\x20Step\x20','3156125iDhdnm','path','Step\x205/7:\x20Removing\x20old\x20skill...','FAIL','1422610VTHeXQ','skipped','already\x20exists\x20(will\x20merge)','fail','includes','cwd','needed','Upgrade\x20cancelled.','Step\x202/7:\x20.lovrabet/\x20removal\x20failed\x20—\x20','succeed','oldPath','red','isDirectory','join','oldMcpConfig','some','Install\x20new\x20skill','detail','no\x20legacy\x20config\x20found','Proceed\x20with\x20upgrade?','args','skipped\x20(not\x20found\x20or\x20already\x20at\x20latest)','exit\x20','values','Remove\x20legacy\x20artifacts','Step\x207/7:\x20@lovrabet/sdk\x20—\x20','Please\x20re-install\x20dependencies\x20to\x20apply\x20the\x20change:','oldArtifacts','CANCEL','sdkUpgrade','472WovCCN','green','Step\x204/7:\x20Cleaning\x20MCP\x20config...','.lovrabet','info','Legacy\x20artifacts:','hasNewConfig'];a152_0x38a1=function(){return _0x273dea;};return a152_0x38a1();}function collectIdeSkillFiles(_0x240b11){const _0x358da7=a152_0x2bb5ba,_0x2ef1d4=[];for(const _0x8c0e13 of Object[_0x358da7(0x1da)](CORE_IDE_CONFIGS)){if(_0x8c0e13[_0x358da7(0x1a7)])for(const _0x3901cb of _0x8c0e13['files']){_0x2ef1d4[_0x358da7(0x177)](resolve(_0x240b11,_0x3901cb[_0x358da7(0x1c0)]));}}return _0x2ef1d4;}function analyse(_0x42f984){const _0x528f4d=a152_0x2bb5ba;let _0xe697de=null;const _0x36bd87=resolve(_0x42f984,NEW_CONFIG_NAME),_0x3a10fb=existsSync(_0x36bd87);for(const _0x34c5bc of LEGACY_CONFIG_NAMES){const _0xb81ec=resolve(_0x42f984,_0x34c5bc);if(existsSync(_0xb81ec)){const _0x35f338=readConfigFile(_0xb81ec),_0x2b90be=Object[_0x528f4d(0x1b8)](_0x35f338)[_0x528f4d(0x180)](_0x14e018=>typeof _0x35f338[_0x14e018]!==_0x528f4d(0x19b));_0xe697de={'oldPath':_0xb81ec,'hasNewConfig':_0x3a10fb,'fields':_0x2b90be};break;}}const _0x4dc51e=[],_0xd6bff9=resolve(_0x42f984,_0x528f4d(0x163));if(existsSync(_0xd6bff9))_0x4dc51e[_0x528f4d(0x177)](_0xd6bff9);const _0x229c8d=resolve(_0x42f984,_0x528f4d(0x19a));if(existsSync(_0x229c8d))_0x4dc51e[_0x528f4d(0x177)](_0x229c8d);const _0x5130de=resolve(_0x42f984,_0x528f4d(0x16c));if(existsSync(_0x5130de))_0x4dc51e[_0x528f4d(0x177)](_0x5130de);for(const _0x1af2ca of collectIdeSkillFiles(_0x42f984)){if(existsSync(_0x1af2ca))_0x4dc51e[_0x528f4d(0x177)](_0x1af2ca);}let _0x48bf82=null;const _0x39c818=resolve(_0x42f984,'.cursor/mcp.json');if(existsSync(_0x39c818))try{const _0xa6800e=JSON[_0x528f4d(0x174)](readFileSync(_0x39c818,_0x528f4d(0x17d)));if(_0xa6800e?.[_0x528f4d(0x199)]&&typeof _0xa6800e[_0x528f4d(0x199)]===_0x528f4d(0x1a6)){const _0x455266=[];for(const [_0x50e915,_0x4d8306]of Object['entries'](_0xa6800e['mcpServers'])){const _0x135f2a=_0x4d8306;_0x135f2a?.[_0x528f4d(0x1d7)]&&Array['isArray'](_0x135f2a[_0x528f4d(0x1d7)])&&_0x135f2a['args'][_0x528f4d(0x1d2)](_0x427a57=>typeof _0x427a57===_0x528f4d(0x18e)&&_0x427a57['includes']('@lovrabet/dataset-mcp-server'))&&_0x455266[_0x528f4d(0x177)](_0x50e915);}_0x455266[_0x528f4d(0x169)]>0x0&&(_0x48bf82={'path':_0x39c818,'keys':_0x455266});}}catch{}const _0x3e5785=_0x4dc51e['length']>0x0||_0xe697de!==null;let _0x592dfc=null;const _0x2fb2fc=resolve(_0x42f984,_0x528f4d(0x17b));if(existsSync(_0x2fb2fc))try{const _0x3915e9=JSON[_0x528f4d(0x174)](readFileSync(_0x2fb2fc,_0x528f4d(0x17d)));for(const _0x336563 of['dependencies',_0x528f4d(0x1a9)]){const _0x10716d=_0x3915e9?.[_0x336563]?.[_0x528f4d(0x1a0)];if(typeof _0x10716d===_0x528f4d(0x18e)){_0x10716d!==_0x528f4d(0x18c)&&(_0x592dfc={'pkgPath':_0x2fb2fc,'currentVersion':_0x10716d,'field':_0x336563});break;}}}catch{}return{'configMigration':_0xe697de,'oldArtifacts':_0x4dc51e,'oldMcpConfig':_0x48bf82,'needsSkillSwap':_0x3e5785,'sdkUpgrade':_0x592dfc};}function printReport(_0x5d586f){const _0x295278=a152_0x2bb5ba,{configMigration:_0x4410f9,oldArtifacts:_0x182655,oldMcpConfig:_0x27680b,needsSkillSwap:_0x37f8a4}=_0x5d586f;console[_0x295278(0x1b0)](''),console[_0x295278(0x1b0)](a152_0x2593fe[_0x295278(0x191)](_0x295278(0x171))),console['log']('');_0x4410f9?(console['log'](a152_0x2593fe['cyan']('Config\x20file:')+('\x20\x20'+a152_0x2593fe[_0x295278(0x1bb)](_0x4410f9[_0x295278(0x1cd)]))),console['log']('\x20\x20New\x20config\x20(.rabetbase.json):\x20'+(_0x4410f9[_0x295278(0x166)]?a152_0x2593fe[_0x295278(0x161)](_0x295278(0x1c5)):a152_0x2593fe['gray'](_0x295278(0x1a3)))),console[_0x295278(0x1b0)]('\x20\x20Fields\x20to\x20migrate:\x20'+_0x4410f9[_0x295278(0x19f)][_0x295278(0x1d0)](',\x20')),console[_0x295278(0x1b0)](_0x295278(0x176))):console[_0x295278(0x1b0)](a152_0x2593fe['cyan'](_0x295278(0x18a))+'\x20\x20'+a152_0x2593fe['gray'](_0x295278(0x1d5)));console[_0x295278(0x1b0)]('');if(_0x182655[_0x295278(0x169)]>0x0){console[_0x295278(0x1b0)](a152_0x2593fe[_0x295278(0x17c)](_0x295278(0x165)));for(const _0x43048f of _0x182655){console[_0x295278(0x1b0)]('\x20\x20'+a152_0x2593fe[_0x295278(0x1ce)]('FOUND')+'\x20\x20'+_0x43048f);}console[_0x295278(0x1b0)](_0x295278(0x17a));}else console[_0x295278(0x1b0)](a152_0x2593fe['cyan']('Legacy\x20artifacts:')+'\x20\x20'+a152_0x2593fe[_0x295278(0x185)]('none\x20found'));console['log']('');_0x27680b?(console[_0x295278(0x1b0)](a152_0x2593fe[_0x295278(0x17c)]('MCP\x20config:')+('\x20\x20'+a152_0x2593fe[_0x295278(0x1bb)](_0x27680b[_0x295278(0x1c0)])+'\x20→\x20keys:\x20'+_0x27680b[_0x295278(0x1b8)][_0x295278(0x1d0)](',\x20'))),console[_0x295278(0x1b0)](_0x295278(0x195))):console[_0x295278(0x1b0)](a152_0x2593fe[_0x295278(0x17c)](_0x295278(0x16e))+'\x20\x20'+a152_0x2593fe[_0x295278(0x185)](_0x295278(0x1b7)));console[_0x295278(0x1b0)](''),console[_0x295278(0x1b0)](a152_0x2593fe[_0x295278(0x17c)](_0x295278(0x19d))+('\x20\x20'+(_0x37f8a4?a152_0x2593fe[_0x295278(0x1bb)](_0x295278(0x1c9)):a152_0x2593fe['green'](_0x295278(0x1af)))));_0x37f8a4&&console[_0x295278(0x1b0)]('\x20\x20Action:\x20remove\x20old\x20lovrabet/lovrabet-skill,\x20add\x20via\x20`'+NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE+'`');console['log']('');if(_0x5d586f[_0x295278(0x1e0)]){const {currentVersion:_0x2f9fd4,field:_0x5121da,pkgPath:_0x128502}=_0x5d586f[_0x295278(0x1e0)];console[_0x295278(0x1b0)](a152_0x2593fe[_0x295278(0x17c)](_0x295278(0x1b5))+('\x20\x20'+a152_0x2593fe[_0x295278(0x1bb)](_0x128502))),console[_0x295278(0x1b0)](_0x295278(0x182)+_0x5121da+':\x20'+a152_0x2593fe[_0x295278(0x1bb)](_0x2f9fd4)+'\x20→\x20'+a152_0x2593fe[_0x295278(0x161)](_0x295278(0x18c))),console[_0x295278(0x1b0)](_0x295278(0x19e));}else console['log'](a152_0x2593fe['cyan'](_0x295278(0x1b5))+'\x20\x20'+a152_0x2593fe[_0x295278(0x185)](_0x295278(0x17f)));console[_0x295278(0x1b0)]('');}function execConfigMigration(_0x59c909,_0x2cedcb){const _0x573489=a152_0x2bb5ba,{configMigration:_0x358bd0}=_0x59c909;if(!_0x358bd0?.[_0x573489(0x1cd)])return{'step':0x1,'label':'Config\x20migration','ok':!![],'detail':'skipped\x20(no\x20legacy\x20config)'};const _0x86c231=readConfigFile(_0x358bd0[_0x573489(0x1cd)]),_0x141f10=resolve(_0x2cedcb,NEW_CONFIG_NAME),_0xf0af96=_0x358bd0[_0x573489(0x166)]?readConfigFile(_0x141f10):{};for(const [_0x5ae605,_0x141caf]of Object['entries'](_0x86c231)){!(_0x5ae605 in _0xf0af96)&&(_0xf0af96[_0x5ae605]=_0x141caf);}writeConfigFile(_0x141f10,_0xf0af96);const _0x1a0a7e=_0x358bd0[_0x573489(0x1cd)]+_0x573489(0x19c);return renameSync(_0x358bd0[_0x573489(0x1cd)],_0x1a0a7e),{'step':0x1,'label':_0x573489(0x16a),'ok':!![],'detail':_0x358bd0[_0x573489(0x1cd)]+'\x20→\x20'+_0x141f10+_0x573489(0x1ac)+_0x1a0a7e+')'};}function execRemoveOldArtifacts(_0x4a5d3e){const _0x5adaae=a152_0x2bb5ba,_0x132c1e=[];for(const _0x3a825c of _0x4a5d3e){try{if(!existsSync(_0x3a825c))continue;const _0xf54196=tryStat(_0x3a825c);_0xf54196?.[_0x5adaae(0x1cf)]()?rmSync(_0x3a825c,{'recursive':!![],'force':!![]}):unlinkSync(_0x3a825c);}catch(_0x502557){_0x132c1e[_0x5adaae(0x177)](_0x3a825c+':\x20'+_0x502557[_0x5adaae(0x16f)]);}}return{'step':0x3,'label':_0x5adaae(0x1db),'ok':_0x132c1e[_0x5adaae(0x169)]===0x0,'detail':_0x132c1e[_0x5adaae(0x169)]>0x0?_0x4a5d3e[_0x5adaae(0x169)]-_0x132c1e[_0x5adaae(0x169)]+'/'+_0x4a5d3e['length']+'\x20removed\x20('+_0x132c1e[_0x5adaae(0x1d0)](';\x20')+')':_0x4a5d3e[_0x5adaae(0x169)]+_0x5adaae(0x183)};}function execCleanMcp(_0x4f7008){const _0x58656f=a152_0x2bb5ba;if(!_0x4f7008['oldMcpConfig'])return{'step':0x4,'label':_0x58656f(0x1ae),'ok':!![],'detail':_0x58656f(0x1c4)};try{const _0x35eefa=readFileSync(_0x4f7008['oldMcpConfig'][_0x58656f(0x1c0)],_0x58656f(0x17d)),_0x131e79=JSON[_0x58656f(0x174)](_0x35eefa);if(_0x131e79?.[_0x58656f(0x199)]&&typeof _0x131e79['mcpServers']==='object'){const _0x3d15cb=[];for(const [_0x40484a,_0x5111f9]of Object['entries'](_0x131e79['mcpServers'])){_0x5111f9?.['args']&&Array[_0x58656f(0x1a5)](_0x5111f9[_0x58656f(0x1d7)])&&_0x5111f9[_0x58656f(0x1d7)][_0x58656f(0x1d2)](_0x4617d9=>typeof _0x4617d9===_0x58656f(0x18e)&&_0x4617d9[_0x58656f(0x1c7)]('@lovrabet/dataset-mcp-server'))&&_0x3d15cb['push'](_0x40484a);}for(const _0x6fa514 of _0x3d15cb){delete _0x131e79[_0x58656f(0x199)][_0x6fa514];}return _0x3d15cb[_0x58656f(0x169)]>0x0&&writeFileSync(_0x4f7008['oldMcpConfig'][_0x58656f(0x1c0)],JSON[_0x58656f(0x1b9)](_0x131e79,null,0x2)+'\x0a',_0x58656f(0x17d)),{'step':0x4,'label':_0x58656f(0x1ae),'ok':!![],'detail':_0x58656f(0x17e)+_0x3d15cb[_0x58656f(0x1d0)](',\x20')+_0x58656f(0x190)+_0x4f7008[_0x58656f(0x1d1)]['path']};}return{'step':0x4,'label':_0x58656f(0x1ae),'ok':!![],'detail':'no\x20matching\x20entry\x20found'};}catch(_0x523245){return{'step':0x4,'label':_0x58656f(0x1ae),'ok':![],'detail':_0x523245['message']};}}function execSkillsRemove(_0x4f5307,_0x5eea43){const _0x68515c=a152_0x2bb5ba,_0x2a4fec=runNpxSkillsRemove(_0x4f5307,{'stdio':_0x68515c(0x184),'yes':_0x5eea43});return{'step':0x5,'label':'Remove\x20old\x20skill','ok':_0x2a4fec['ok'],'detail':_0x2a4fec['ok']?'lovrabet/lovrabet-skill\x20removed':_0x2a4fec[_0x68515c(0x179)]??_0x68515c(0x1d9)+_0x2a4fec[_0x68515c(0x1bc)]};}function execSkillsAdd(_0xba84ea,_0x3ec245){const _0x1f0add=a152_0x2bb5ba,_0x36bef6=runNpxSkillsAddGlobal(_0xba84ea,_0x1f0add(0x1b4),{'stdio':_0x1f0add(0x184),'yes':_0x3ec245});return{'step':0x6,'label':_0x1f0add(0x1d3),'ok':_0x36bef6['ok'],'detail':_0x36bef6['ok']?_0x1f0add(0x175):_0x36bef6[_0x1f0add(0x179)]??_0x1f0add(0x1d9)+_0x36bef6['status']};}function execUpgradeSdk(_0x22a56a){const _0x299644=a152_0x2bb5ba;if(!_0x22a56a[_0x299644(0x1e0)])return{'step':0x7,'label':_0x299644(0x1a4),'ok':!![],'detail':_0x299644(0x1d8)};const {pkgPath:_0x2b36cb,currentVersion:_0x73548d,field:_0xb6623d}=_0x22a56a['sdkUpgrade'];try{const _0xaff1f8=readFileSync(_0x2b36cb,_0x299644(0x17d)),_0x3fdbb3=JSON[_0x299644(0x174)](_0xaff1f8);return _0x3fdbb3[_0xb6623d][_0x299644(0x1a0)]=_0x299644(0x18c),writeFileSync(_0x2b36cb,JSON[_0x299644(0x1b9)](_0x3fdbb3,null,0x2)+'\x0a',_0x299644(0x17d)),{'step':0x7,'label':_0x299644(0x1a4),'ok':!![],'detail':_0xb6623d+_0x299644(0x1b2)+_0x73548d+'\x20→\x20latest'};}catch(_0xeb5e02){return{'step':0x7,'label':_0x299644(0x1a4),'ok':![],'detail':_0xeb5e02[_0x299644(0x16f)]};}}function tryStat(_0x8dab00){try{return statSync(_0x8dab00);}catch{return undefined;}}function printSummary(_0x14581b){const _0x4b4594=a152_0x2bb5ba;console[_0x4b4594(0x1b0)](''),console[_0x4b4594(0x1b0)](a152_0x2593fe['bold'](_0x4b4594(0x188))),console[_0x4b4594(0x1b0)]('');for(const _0x54252a of _0x14581b){const _0x1eb1bd=_0x54252a['ok']?a152_0x2593fe[_0x4b4594(0x161)]('OK'):a152_0x2593fe[_0x4b4594(0x1ce)](_0x4b4594(0x1c2));console[_0x4b4594(0x1b0)]('\x20\x20'+_0x1eb1bd+_0x4b4594(0x1be)+_0x54252a[_0x4b4594(0x16b)]+':\x20'+_0x54252a['label']);if(_0x54252a['detail'])console[_0x4b4594(0x1b0)](_0x4b4594(0x178)+a152_0x2593fe['gray'](_0x54252a[_0x4b4594(0x1d4)]));}console[_0x4b4594(0x1b0)]('');}export async function upgradeApp(_0xc80edf,_0x369f76){const _0x38631c=a152_0x2bb5ba,_0x1276c9=process[_0x38631c(0x1c8)](),_0x6b348d=analyse(_0x1276c9),_0x10140e=!_0x6b348d[_0x38631c(0x1ba)]&&_0x6b348d[_0x38631c(0x1de)][_0x38631c(0x169)]===0x0&&!_0x6b348d[_0x38631c(0x1d1)]&&!_0x6b348d[_0x38631c(0x18d)]&&!_0x6b348d['sdkUpgrade'];if(_0x10140e){console[_0x38631c(0x1b0)](a152_0x2593fe[_0x38631c(0x161)]('No\x20legacy\x20artifacts\x20found.\x20Your\x20project\x20is\x20already\x20up-to-date.'));return;}printReport(_0x6b348d);const _0x325c87=!!(_0x369f76[_0x38631c(0x192)]||_0x369f76['Y']||_0xc80edf);if(!_0x325c87)try{const _0x527f28=await askConfirm(_0x38631c(0x1d6));if(!_0x527f28){console['log'](a152_0x2593fe[_0x38631c(0x185)](_0x38631c(0x1ca)));return;}}catch(_0x5d5035){if(_0x5d5035?.[_0x38631c(0x16f)]===_0x38631c(0x1df)){console[_0x38631c(0x1b0)](a152_0x2593fe[_0x38631c(0x185)](_0x38631c(0x1ca)));return;}throw _0x5d5035;}const _0x22bc05=[],_0x7ae29a=a152_0x1f161a({'text':'Step\x201/7:\x20Migrating\x20config...','color':_0x38631c(0x17c)})['start'](),_0x23b48c=execConfigMigration(_0x6b348d,_0x1276c9);_0x22bc05[_0x38631c(0x177)](_0x23b48c),_0x7ae29a[_0x23b48c['ok']?_0x38631c(0x1cc):_0x38631c(0x1c6)](_0x38631c(0x198)+(_0x23b48c[_0x38631c(0x1d4)]??(_0x23b48c['ok']?_0x38631c(0x194):_0x38631c(0x1a2))));const _0x61a165=resolve(_0x1276c9,'.lovrabet'),_0x124a45=a152_0x1f161a({'text':'Step\x202/7:\x20Removing\x20.lovrabet/\x20directory...','color':_0x38631c(0x17c)})[_0x38631c(0x1b6)]();if(existsSync(_0x61a165))try{rmSync(_0x61a165,{'recursive':!![],'force':!![]}),_0x124a45[_0x38631c(0x1cc)](_0x38631c(0x1ad)),_0x22bc05[_0x38631c(0x177)]({'step':0x2,'label':_0x38631c(0x1b1),'ok':!![]});}catch(_0x3055bd){_0x124a45[_0x38631c(0x1c6)](_0x38631c(0x1cb)+_0x3055bd['message']),_0x22bc05[_0x38631c(0x177)]({'step':0x2,'label':_0x38631c(0x1b1),'ok':![],'detail':_0x3055bd[_0x38631c(0x16f)]});}else _0x124a45[_0x38631c(0x164)](_0x38631c(0x168)),_0x22bc05[_0x38631c(0x177)]({'step':0x2,'label':_0x38631c(0x1b1),'ok':!![],'detail':_0x38631c(0x1c4)});const _0x13e24e=a152_0x1f161a({'text':_0x38631c(0x172),'color':_0x38631c(0x17c)})[_0x38631c(0x1b6)](),_0x65855f=execRemoveOldArtifacts(_0x6b348d[_0x38631c(0x1de)]);_0x22bc05['push'](_0x65855f),_0x13e24e[_0x65855f['ok']?_0x38631c(0x1cc):_0x38631c(0x1c6)](_0x38631c(0x197)+(_0x65855f[_0x38631c(0x1d4)]??(_0x65855f['ok']?_0x38631c(0x194):_0x38631c(0x1a2))));const _0x25c263=a152_0x1f161a({'text':_0x38631c(0x162),'color':'cyan'})[_0x38631c(0x1b6)](),_0x42ed11=execCleanMcp(_0x6b348d);_0x22bc05[_0x38631c(0x177)](_0x42ed11),_0x25c263[_0x42ed11['ok']?_0x38631c(0x1cc):_0x38631c(0x1c6)](_0x38631c(0x186)+(_0x42ed11[_0x38631c(0x1d4)]??(_0x42ed11['ok']?_0x38631c(0x194):_0x38631c(0x1a2))));const _0x133720=a152_0x1f161a({'text':_0x38631c(0x1c1),'color':'cyan'})[_0x38631c(0x1b6)](),_0x37598e=execSkillsRemove(_0x1276c9,_0x325c87);_0x22bc05['push'](_0x37598e),_0x133720[_0x37598e['ok']?'succeed':'fail'](_0x38631c(0x167)+(_0x37598e[_0x38631c(0x1d4)]??(_0x37598e['ok']?_0x38631c(0x194):'failed')));const _0x26a553=a152_0x1f161a({'text':'Step\x206/7:\x20Installing\x20new\x20skill...','color':_0x38631c(0x17c)})[_0x38631c(0x1b6)](),_0x43f516=execSkillsAdd(_0x1276c9,_0x325c87);_0x22bc05['push'](_0x43f516),_0x26a553[_0x43f516['ok']?_0x38631c(0x1cc):_0x38631c(0x1c6)](_0x38631c(0x173)+(_0x43f516[_0x38631c(0x1d4)]??(_0x43f516['ok']?_0x38631c(0x194):_0x38631c(0x1a2))));const _0x1ad0bd=a152_0x1f161a({'text':_0x38631c(0x1a8),'color':_0x38631c(0x17c)})['start'](),_0x3ab557=execUpgradeSdk(_0x6b348d);_0x22bc05['push'](_0x3ab557),_0x1ad0bd[_0x3ab557['ok']?_0x38631c(0x1cc):_0x38631c(0x1c6)](_0x38631c(0x1dc)+(_0x3ab557[_0x38631c(0x1d4)]??(_0x3ab557['ok']?_0x38631c(0x194):_0x38631c(0x1a2)))),printSummary(_0x22bc05);const _0x1f5801=_0x22bc05['some'](_0x45d370=>!_0x45d370['ok']);_0x1f5801?console[_0x38631c(0x1b0)](a152_0x2593fe[_0x38631c(0x1bb)]('Some\x20steps\x20failed.\x20Check\x20the\x20summary\x20above\x20for\x20details.')):console[_0x38631c(0x1b0)](a152_0x2593fe['green']('Upgrade\x20completed\x20successfully!')),_0x3ab557['ok']&&_0x6b348d[_0x38631c(0x1e0)]&&(console[_0x38631c(0x1b0)](''),console['log'](a152_0x2593fe['bold']['cyan'](_0x38631c(0x16d))),console[_0x38631c(0x1b0)](a152_0x2593fe[_0x38631c(0x17c)](_0x38631c(0x1dd))),console[_0x38631c(0x1b0)](''),console['log'](a152_0x2593fe[_0x38631c(0x18f)]('\x20\x20npm\x20install')),console[_0x38631c(0x1b0)](a152_0x2593fe[_0x38631c(0x18f)]('\x20\x20#\x20or')),console[_0x38631c(0x1b0)](a152_0x2593fe[_0x38631c(0x18f)](_0x38631c(0x18b))),console['log'](''));}
1
+ const a152_0x173eab=a152_0x42db;(function(_0x478d47,_0x4b2b11){const _0x5439c0=a152_0x42db,_0x1bd620=_0x478d47();while(!![]){try{const _0x349c59=-parseInt(_0x5439c0(0x200))/0x1*(parseInt(_0x5439c0(0x224))/0x2)+-parseInt(_0x5439c0(0x23e))/0x3*(-parseInt(_0x5439c0(0x1e0))/0x4)+parseInt(_0x5439c0(0x214))/0x5*(-parseInt(_0x5439c0(0x1fe))/0x6)+parseInt(_0x5439c0(0x215))/0x7+parseInt(_0x5439c0(0x219))/0x8*(-parseInt(_0x5439c0(0x239))/0x9)+parseInt(_0x5439c0(0x1fb))/0xa*(-parseInt(_0x5439c0(0x21a))/0xb)+parseInt(_0x5439c0(0x1e2))/0xc*(parseInt(_0x5439c0(0x21d))/0xd);if(_0x349c59===_0x4b2b11)break;else _0x1bd620['push'](_0x1bd620['shift']());}catch(_0x2729c3){_0x1bd620['push'](_0x1bd620['shift']());}}}(a152_0x4596,0xa79da));import a152_0x55d77d from'chalk';import a152_0x1faa62 from'ora';import{existsSync,readFileSync,renameSync,rmSync,statSync,unlinkSync,writeFileSync}from'node:fs';import{resolve}from'node:path';import{CONFIG_NAMES,NEW_CONFIG_NAME,readConfigFile,writeConfigFile}from'../../context.js';import{CORE_IDE_CONFIGS}from'../../utils/ai_config.js';import{NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE,runNpxSkillsAddGlobal,runNpxSkillsRemove}from'../../skills/npx-skills-add.js';import{askConfirm}from'../../commands/menu/shared/inquirer.js';const LEGACY_CONFIG_NAMES=CONFIG_NAMES[a152_0x173eab(0x202)](_0x1babe3=>_0x1babe3!==NEW_CONFIG_NAME);function collectIdeSkillFiles(_0x446fca){const _0x1722ac=a152_0x173eab,_0x372bdf=[];for(const _0x580888 of Object['values'](CORE_IDE_CONFIGS)){if(_0x580888[_0x1722ac(0x1e4)])for(const _0x57c2d3 of _0x580888['files']){_0x372bdf[_0x1722ac(0x21e)](resolve(_0x446fca,_0x57c2d3[_0x1722ac(0x1ea)]));}}return _0x372bdf;}function analyse(_0x4858fa){const _0x42561a=a152_0x173eab;let _0x49a976=null;const _0x168a0a=resolve(_0x4858fa,NEW_CONFIG_NAME),_0xa95fac=existsSync(_0x168a0a);for(const _0x124acb of LEGACY_CONFIG_NAMES){const _0x111281=resolve(_0x4858fa,_0x124acb);if(existsSync(_0x111281)){const _0x4db9d8=readConfigFile(_0x111281),_0x64df8c=Object[_0x42561a(0x249)](_0x4db9d8)['filter'](_0x568296=>typeof _0x4db9d8[_0x568296]!=='undefined');_0x49a976={'oldPath':_0x111281,'hasNewConfig':_0xa95fac,'fields':_0x64df8c};break;}}const _0x225753=[],_0x32ccbf=resolve(_0x4858fa,_0x42561a(0x255));if(existsSync(_0x32ccbf))_0x225753['push'](_0x32ccbf);const _0x53fd12=resolve(_0x4858fa,_0x42561a(0x20f));if(existsSync(_0x53fd12))_0x225753[_0x42561a(0x21e)](_0x53fd12);const _0x4ed7ed=resolve(_0x4858fa,'.claude/skills/lovrabet');if(existsSync(_0x4ed7ed))_0x225753[_0x42561a(0x21e)](_0x4ed7ed);for(const _0x233704 of collectIdeSkillFiles(_0x4858fa)){if(existsSync(_0x233704))_0x225753[_0x42561a(0x21e)](_0x233704);}let _0x2e9f0c=null;const _0x538727=resolve(_0x4858fa,_0x42561a(0x1ec));if(existsSync(_0x538727))try{const _0x4dbb29=JSON['parse'](readFileSync(_0x538727,'utf8'));if(_0x4dbb29?.[_0x42561a(0x213)]&&typeof _0x4dbb29['mcpServers']==='object'){const _0x4d73d4=[];for(const [_0x8be0bd,_0xab523c]of Object[_0x42561a(0x22d)](_0x4dbb29[_0x42561a(0x213)])){const _0x5de981=_0xab523c;_0x5de981?.['args']&&Array[_0x42561a(0x1d5)](_0x5de981[_0x42561a(0x230)])&&_0x5de981[_0x42561a(0x230)][_0x42561a(0x216)](_0x3833af=>typeof _0x3833af===_0x42561a(0x21f)&&_0x3833af['includes'](_0x42561a(0x209)))&&_0x4d73d4['push'](_0x8be0bd);}_0x4d73d4['length']>0x0&&(_0x2e9f0c={'path':_0x538727,'keys':_0x4d73d4});}}catch{}const _0x58587e=_0x225753[_0x42561a(0x241)]>0x0||_0x49a976!==null;let _0x196ae3=null;const _0x3875f7=resolve(_0x4858fa,_0x42561a(0x23d));if(existsSync(_0x3875f7))try{const _0x30b218=JSON[_0x42561a(0x23a)](readFileSync(_0x3875f7,'utf8'));for(const _0x160ff8 of[_0x42561a(0x22f),_0x42561a(0x20d)]){const _0x4ed981=_0x30b218?.[_0x160ff8]?.[_0x42561a(0x1f6)];if(typeof _0x4ed981===_0x42561a(0x21f)){_0x4ed981!==_0x42561a(0x240)&&(_0x196ae3={'pkgPath':_0x3875f7,'currentVersion':_0x4ed981,'field':_0x160ff8});break;}}}catch{}return{'configMigration':_0x49a976,'oldArtifacts':_0x225753,'oldMcpConfig':_0x2e9f0c,'needsSkillSwap':_0x58587e,'sdkUpgrade':_0x196ae3};}function printReport(_0x1da44b){const _0x30e3e8=a152_0x173eab,{configMigration:_0x104312,oldArtifacts:_0x3ad0e7,oldMcpConfig:_0x181116,needsSkillSwap:_0x120c21}=_0x1da44b;console[_0x30e3e8(0x22c)](''),console['log'](a152_0x55d77d['bold'](_0x30e3e8(0x204))),console['log']('');_0x104312?(console[_0x30e3e8(0x22c)](a152_0x55d77d[_0x30e3e8(0x233)](_0x30e3e8(0x23c))+('\x20\x20'+a152_0x55d77d['yellow'](_0x104312['oldPath']))),console[_0x30e3e8(0x22c)](_0x30e3e8(0x218)+(_0x104312['hasNewConfig']?a152_0x55d77d[_0x30e3e8(0x212)](_0x30e3e8(0x1ef)):a152_0x55d77d[_0x30e3e8(0x1f0)](_0x30e3e8(0x24d)))),console[_0x30e3e8(0x22c)](_0x30e3e8(0x1db)+_0x104312[_0x30e3e8(0x1df)]['join'](',\x20')),console[_0x30e3e8(0x22c)](_0x30e3e8(0x211))):console['log'](a152_0x55d77d['cyan']('Config\x20file:')+'\x20\x20'+a152_0x55d77d[_0x30e3e8(0x1f0)](_0x30e3e8(0x1e9)));console['log']('');if(_0x3ad0e7[_0x30e3e8(0x241)]>0x0){console[_0x30e3e8(0x22c)](a152_0x55d77d['cyan'](_0x30e3e8(0x1e6)));for(const _0x2c3cff of _0x3ad0e7){console[_0x30e3e8(0x22c)]('\x20\x20'+a152_0x55d77d[_0x30e3e8(0x1dc)](_0x30e3e8(0x210))+'\x20\x20'+_0x2c3cff);}console[_0x30e3e8(0x22c)]('\x20\x20Action:\x20delete');}else console[_0x30e3e8(0x22c)](a152_0x55d77d[_0x30e3e8(0x233)](_0x30e3e8(0x1e6))+'\x20\x20'+a152_0x55d77d[_0x30e3e8(0x1f0)](_0x30e3e8(0x234)));console[_0x30e3e8(0x22c)]('');_0x181116?(console[_0x30e3e8(0x22c)](a152_0x55d77d['cyan'](_0x30e3e8(0x1f8))+('\x20\x20'+a152_0x55d77d[_0x30e3e8(0x1ee)](_0x181116['path'])+_0x30e3e8(0x1fd)+_0x181116[_0x30e3e8(0x249)][_0x30e3e8(0x24c)](',\x20'))),console[_0x30e3e8(0x22c)](_0x30e3e8(0x244))):console[_0x30e3e8(0x22c)](a152_0x55d77d[_0x30e3e8(0x233)]('MCP\x20config:')+'\x20\x20'+a152_0x55d77d[_0x30e3e8(0x1f0)](_0x30e3e8(0x207)));console['log'](''),console[_0x30e3e8(0x22c)](a152_0x55d77d[_0x30e3e8(0x233)](_0x30e3e8(0x238))+('\x20\x20'+(_0x120c21?a152_0x55d77d[_0x30e3e8(0x1ee)](_0x30e3e8(0x1eb)):a152_0x55d77d[_0x30e3e8(0x212)](_0x30e3e8(0x1fa)))));_0x120c21&&console['log']('\x20\x20Action:\x20remove\x20old\x20lovrabet/lovrabet-skill,\x20add\x20via\x20`'+NPX_SKILLS_ADD_GLOBAL_COMMAND_LINE+'`');console[_0x30e3e8(0x22c)]('');if(_0x1da44b['sdkUpgrade']){const {currentVersion:_0x55f70e,field:_0x43ebf4,pkgPath:_0xa613cb}=_0x1da44b['sdkUpgrade'];console[_0x30e3e8(0x22c)](a152_0x55d77d[_0x30e3e8(0x233)](_0x30e3e8(0x1d9))+('\x20\x20'+a152_0x55d77d[_0x30e3e8(0x1ee)](_0xa613cb))),console[_0x30e3e8(0x22c)](_0x30e3e8(0x226)+_0x43ebf4+':\x20'+a152_0x55d77d['yellow'](_0x55f70e)+_0x30e3e8(0x245)+a152_0x55d77d['green'](_0x30e3e8(0x240))),console[_0x30e3e8(0x22c)](_0x30e3e8(0x1e1));}else console[_0x30e3e8(0x22c)](a152_0x55d77d[_0x30e3e8(0x233)](_0x30e3e8(0x1d9))+'\x20\x20'+a152_0x55d77d[_0x30e3e8(0x1f0)](_0x30e3e8(0x1fc)));console[_0x30e3e8(0x22c)]('');}function execConfigMigration(_0x50da2e,_0x3fb225){const _0x550e25=a152_0x173eab,{configMigration:_0x19726e}=_0x50da2e;if(!_0x19726e?.[_0x550e25(0x24f)])return{'step':0x1,'label':_0x550e25(0x201),'ok':!![],'detail':_0x550e25(0x24b)};const _0x2d48ca=readConfigFile(_0x19726e[_0x550e25(0x24f)]),_0xcdea95=resolve(_0x3fb225,NEW_CONFIG_NAME),_0xf6d951=_0x19726e['hasNewConfig']?readConfigFile(_0xcdea95):{};for(const [_0x31f742,_0xac121]of Object[_0x550e25(0x22d)](_0x2d48ca)){!(_0x31f742 in _0xf6d951)&&(_0xf6d951[_0x31f742]=_0xac121);}writeConfigFile(_0xcdea95,_0xf6d951);const _0x17c470=_0x19726e[_0x550e25(0x24f)]+_0x550e25(0x20c);return renameSync(_0x19726e[_0x550e25(0x24f)],_0x17c470),{'step':0x1,'label':_0x550e25(0x201),'ok':!![],'detail':_0x19726e[_0x550e25(0x24f)]+'\x20→\x20'+_0xcdea95+'\x20(backup:\x20'+_0x17c470+')'};}function execRemoveOldArtifacts(_0xcdcd7c){const _0x33fa7d=a152_0x173eab,_0x34b2d6=[];for(const _0x33ef5a of _0xcdcd7c){try{if(!existsSync(_0x33ef5a))continue;const _0x533a5a=tryStat(_0x33ef5a);_0x533a5a?.['isDirectory']()?rmSync(_0x33ef5a,{'recursive':!![],'force':!![]}):unlinkSync(_0x33ef5a);}catch(_0x187110){_0x34b2d6[_0x33fa7d(0x21e)](_0x33ef5a+':\x20'+_0x187110[_0x33fa7d(0x1f5)]);}}return{'step':0x3,'label':_0x33fa7d(0x1e3),'ok':_0x34b2d6[_0x33fa7d(0x241)]===0x0,'detail':_0x34b2d6[_0x33fa7d(0x241)]>0x0?_0xcdcd7c['length']-_0x34b2d6[_0x33fa7d(0x241)]+'/'+_0xcdcd7c['length']+_0x33fa7d(0x251)+_0x34b2d6[_0x33fa7d(0x24c)](';\x20')+')':_0xcdcd7c[_0x33fa7d(0x241)]+'\x20removed'};}function execCleanMcp(_0x262258){const _0x3961ea=a152_0x173eab;if(!_0x262258[_0x3961ea(0x24a)])return{'step':0x4,'label':'Clean\x20MCP\x20config','ok':!![],'detail':_0x3961ea(0x236)};try{const _0x3e6f27=readFileSync(_0x262258[_0x3961ea(0x24a)][_0x3961ea(0x1ea)],_0x3961ea(0x225)),_0x181d7c=JSON[_0x3961ea(0x23a)](_0x3e6f27);if(_0x181d7c?.[_0x3961ea(0x213)]&&typeof _0x181d7c[_0x3961ea(0x213)]===_0x3961ea(0x1e5)){const _0xf0a5d8=[];for(const [_0x1c9e64,_0x4a554a]of Object[_0x3961ea(0x22d)](_0x181d7c[_0x3961ea(0x213)])){_0x4a554a?.[_0x3961ea(0x230)]&&Array[_0x3961ea(0x1d5)](_0x4a554a[_0x3961ea(0x230)])&&_0x4a554a[_0x3961ea(0x230)][_0x3961ea(0x216)](_0x4c2e7c=>typeof _0x4c2e7c===_0x3961ea(0x21f)&&_0x4c2e7c[_0x3961ea(0x250)](_0x3961ea(0x209)))&&_0xf0a5d8[_0x3961ea(0x21e)](_0x1c9e64);}for(const _0x525b20 of _0xf0a5d8){delete _0x181d7c[_0x3961ea(0x213)][_0x525b20];}return _0xf0a5d8['length']>0x0&&writeFileSync(_0x262258['oldMcpConfig'][_0x3961ea(0x1ea)],JSON[_0x3961ea(0x1d8)](_0x181d7c,null,0x2)+'\x0a',_0x3961ea(0x225)),{'step':0x4,'label':_0x3961ea(0x231),'ok':!![],'detail':_0x3961ea(0x23b)+_0xf0a5d8[_0x3961ea(0x24c)](',\x20')+'\x20from\x20'+_0x262258[_0x3961ea(0x24a)][_0x3961ea(0x1ea)]};}return{'step':0x4,'label':_0x3961ea(0x231),'ok':!![],'detail':_0x3961ea(0x21c)};}catch(_0x3e8be2){return{'step':0x4,'label':_0x3961ea(0x231),'ok':![],'detail':_0x3e8be2[_0x3961ea(0x1f5)]};}}function a152_0x42db(_0x4f80dd,_0x4891ff){_0x4f80dd=_0x4f80dd-0x1d4;const _0x4596e9=a152_0x4596();let _0x42db4b=_0x4596e9[_0x4f80dd];return _0x42db4b;}function a152_0x4596(){const _0x2ab643=['detail','\x20\x20#\x20or','log','entries','Remove\x20.lovrabet/','dependencies','args','Clean\x20MCP\x20config','Install\x20new\x20skill','cyan','none\x20found','\x20\x20npm\x20install','skipped','failed','Skill\x20swap:','45SelrLh','parse','removed\x20','Config\x20file:','package.json','3CduyKE','Step\x206/7:\x20Installing\x20new\x20skill...','latest','length','needsSkillSwap','Remove\x20old\x20skill','\x20\x20Action:\x20remove\x20entries\x20containing\x20@lovrabet/dataset-mcp-server','\x20→\x20','\x20\x20bun\x20install','succeed','error','keys','oldMcpConfig','skipped\x20(no\x20legacy\x20config)','join','not\x20found\x20(will\x20create)','Step\x203/7:\x20Legacy\x20artifacts\x20—\x20','oldPath','includes','\x20removed\x20(','Step\x207/7:\x20Upgrading\x20@lovrabet/sdk\x20in\x20package.json...','white','skipped\x20(not\x20found\x20or\x20already\x20at\x20latest)','.lovrabet','[\x22@lovrabet/sdk\x22]:\x20','isArray','No\x20legacy\x20artifacts\x20found.\x20Your\x20project\x20is\x20already\x20up-to-date.','Upgrade\x20cancelled.','stringify','@lovrabet/sdk:','Step\x205/7:\x20Remove\x20old\x20skill\x20—\x20','\x20\x20Fields\x20to\x20migrate:\x20','red','start','cwd','fields','3420168zJlgZk','\x20\x20Action:\x20update\x20package.json\x20(you\x20will\x20need\x20to\x20re-run\x20install)','18624SSHZHc','Remove\x20legacy\x20artifacts','files','object','Legacy\x20artifacts:','Step\x202/7:\x20.lovrabet/\x20not\x20found,\x20skipped','Step\x202/7:\x20.lovrabet/\x20directory\x20removed','no\x20legacy\x20config\x20found','path','needed','.cursor/mcp.json','===\x20Upgrade\x20Summary\x20===','yellow','already\x20exists\x20(will\x20merge)','gray','\x20\x20\x20\x20\x20\x20\x20','Step\x204/7:\x20Cleaning\x20MCP\x20config...','sdkUpgrade','lovrabet/lovrabet-skill\x20removed','message','@lovrabet/sdk','Step\x202/7:\x20.lovrabet/\x20removal\x20failed\x20—\x20','MCP\x20config:','lovrabet/rabetbase','not\x20needed','8345780KifdnS','not\x20found\x20or\x20already\x20at\x20latest','\x20→\x20keys:\x20','12AxZizF','Upgrade\x20@lovrabet/sdk','25rvMKxE','Config\x20migration','filter','done','===\x20Upgrade\x20Analysis\x20===','Some\x20steps\x20failed.\x20Check\x20the\x20summary\x20above\x20for\x20details.','bold','no\x20legacy\x20entry','lovrabet/rabetbase\x20installed\x20globally','@lovrabet/dataset-mcp-server','exit\x20','Step\x202/7:\x20Removing\x20.lovrabet/\x20directory...','.bak','devDependencies','Step\x201/7:\x20Config\x20migration\x20—\x20','.cursor/rules/lovrabet_rules.mdc','FOUND','\x20\x20Action:\x20migrate\x20→\x20backup\x20old\x20as\x20.bak','green','mcpServers','45575IpzYMX','9255211JqxUEk','some','inherit','\x20\x20New\x20config\x20(.rabetbase.json):\x20','921408BAXxJw','11qHynrJ','fail','no\x20matching\x20entry\x20found','9113aLktDu','push','string','Step\x205/7:\x20Removing\x20old\x20skill...','status','Step\x201/7:\x20Migrating\x20config...','CANCEL','91994SyHsaL','utf8','\x20\x20Current\x20version\x20in\x20','oldArtifacts','Upgrade\x20completed\x20successfully!','step'];a152_0x4596=function(){return _0x2ab643;};return a152_0x4596();}function execSkillsRemove(_0x1d157e,_0xe7eec4){const _0x1494fb=a152_0x173eab,_0x7d4f7a=runNpxSkillsRemove(_0x1d157e,{'stdio':'inherit','yes':_0xe7eec4});return{'step':0x5,'label':_0x1494fb(0x243),'ok':_0x7d4f7a['ok'],'detail':_0x7d4f7a['ok']?_0x1494fb(0x1f4):_0x7d4f7a[_0x1494fb(0x248)]??_0x1494fb(0x20a)+_0x7d4f7a[_0x1494fb(0x221)]};}function execSkillsAdd(_0x1439da,_0x3a3492){const _0x4a4caf=a152_0x173eab,_0x3d7757=runNpxSkillsAddGlobal(_0x1439da,_0x4a4caf(0x1f9),{'stdio':_0x4a4caf(0x217),'yes':_0x3a3492});return{'step':0x6,'label':_0x4a4caf(0x232),'ok':_0x3d7757['ok'],'detail':_0x3d7757['ok']?_0x4a4caf(0x208):_0x3d7757[_0x4a4caf(0x248)]??_0x4a4caf(0x20a)+_0x3d7757[_0x4a4caf(0x221)]};}function execUpgradeSdk(_0x1c071d){const _0x4b838c=a152_0x173eab;if(!_0x1c071d[_0x4b838c(0x1f3)])return{'step':0x7,'label':_0x4b838c(0x1ff),'ok':!![],'detail':_0x4b838c(0x254)};const {pkgPath:_0x52335e,currentVersion:_0x5a342e,field:_0x494f7d}=_0x1c071d[_0x4b838c(0x1f3)];try{const _0xe50862=readFileSync(_0x52335e,_0x4b838c(0x225)),_0x428e6b=JSON[_0x4b838c(0x23a)](_0xe50862);return _0x428e6b[_0x494f7d][_0x4b838c(0x1f6)]=_0x4b838c(0x240),writeFileSync(_0x52335e,JSON[_0x4b838c(0x1d8)](_0x428e6b,null,0x2)+'\x0a',_0x4b838c(0x225)),{'step':0x7,'label':_0x4b838c(0x1ff),'ok':!![],'detail':_0x494f7d+_0x4b838c(0x1d4)+_0x5a342e+'\x20→\x20latest'};}catch(_0x296cc7){return{'step':0x7,'label':_0x4b838c(0x1ff),'ok':![],'detail':_0x296cc7[_0x4b838c(0x1f5)]};}}function tryStat(_0x5ed558){try{return statSync(_0x5ed558);}catch{return undefined;}}function printSummary(_0xa7fa18){const _0xcc1bb=a152_0x173eab;console[_0xcc1bb(0x22c)](''),console[_0xcc1bb(0x22c)](a152_0x55d77d[_0xcc1bb(0x206)](_0xcc1bb(0x1ed))),console[_0xcc1bb(0x22c)]('');for(const _0x13b844 of _0xa7fa18){const _0x2cc859=_0x13b844['ok']?a152_0x55d77d[_0xcc1bb(0x212)]('OK'):a152_0x55d77d[_0xcc1bb(0x1dc)]('FAIL');console[_0xcc1bb(0x22c)]('\x20\x20'+_0x2cc859+'\x20\x20Step\x20'+_0x13b844[_0xcc1bb(0x229)]+':\x20'+_0x13b844['label']);if(_0x13b844[_0xcc1bb(0x22a)])console[_0xcc1bb(0x22c)](_0xcc1bb(0x1f1)+a152_0x55d77d[_0xcc1bb(0x1f0)](_0x13b844[_0xcc1bb(0x22a)]));}console[_0xcc1bb(0x22c)]('');}export async function upgradeApp(_0x1f081c,_0x5eb9b0){const _0x55771a=a152_0x173eab,_0x48dd20=process[_0x55771a(0x1de)](),_0x212e26=analyse(_0x48dd20),_0x4d4fb1=!_0x212e26['configMigration']&&_0x212e26['oldArtifacts'][_0x55771a(0x241)]===0x0&&!_0x212e26['oldMcpConfig']&&!_0x212e26[_0x55771a(0x242)]&&!_0x212e26[_0x55771a(0x1f3)];if(_0x4d4fb1){console[_0x55771a(0x22c)](a152_0x55d77d[_0x55771a(0x212)](_0x55771a(0x1d6)));return;}printReport(_0x212e26);const _0x95bbba=!!(_0x5eb9b0['yes']||_0x5eb9b0['Y']||_0x1f081c);if(!_0x95bbba)try{const _0x11aebe=await askConfirm('Proceed\x20with\x20upgrade?');if(!_0x11aebe){console[_0x55771a(0x22c)](a152_0x55d77d[_0x55771a(0x1f0)](_0x55771a(0x1d7)));return;}}catch(_0x42dedd){if(_0x42dedd?.[_0x55771a(0x1f5)]===_0x55771a(0x223)){console[_0x55771a(0x22c)](a152_0x55d77d['gray']('Upgrade\x20cancelled.'));return;}throw _0x42dedd;}const _0x694b8=[],_0x2cbab5=a152_0x1faa62({'text':_0x55771a(0x222),'color':_0x55771a(0x233)})[_0x55771a(0x1dd)](),_0x38f269=execConfigMigration(_0x212e26,_0x48dd20);_0x694b8[_0x55771a(0x21e)](_0x38f269),_0x2cbab5[_0x38f269['ok']?_0x55771a(0x247):_0x55771a(0x21b)](_0x55771a(0x20e)+(_0x38f269[_0x55771a(0x22a)]??(_0x38f269['ok']?_0x55771a(0x203):_0x55771a(0x237))));const _0x5e4d5a=resolve(_0x48dd20,'.lovrabet'),_0x256659=a152_0x1faa62({'text':_0x55771a(0x20b),'color':'cyan'})[_0x55771a(0x1dd)]();if(existsSync(_0x5e4d5a))try{rmSync(_0x5e4d5a,{'recursive':!![],'force':!![]}),_0x256659[_0x55771a(0x247)](_0x55771a(0x1e8)),_0x694b8[_0x55771a(0x21e)]({'step':0x2,'label':_0x55771a(0x22e),'ok':!![]});}catch(_0x56464a){_0x256659[_0x55771a(0x21b)](_0x55771a(0x1f7)+_0x56464a['message']),_0x694b8[_0x55771a(0x21e)]({'step':0x2,'label':'Remove\x20.lovrabet/','ok':![],'detail':_0x56464a['message']});}else _0x256659['info'](_0x55771a(0x1e7)),_0x694b8[_0x55771a(0x21e)]({'step':0x2,'label':_0x55771a(0x22e),'ok':!![],'detail':_0x55771a(0x236)});const _0x39a4c2=a152_0x1faa62({'text':'Step\x203/7:\x20Removing\x20legacy\x20IDE\x20skill\x20files...','color':_0x55771a(0x233)})[_0x55771a(0x1dd)](),_0x469f83=execRemoveOldArtifacts(_0x212e26[_0x55771a(0x227)]);_0x694b8[_0x55771a(0x21e)](_0x469f83),_0x39a4c2[_0x469f83['ok']?_0x55771a(0x247):'fail'](_0x55771a(0x24e)+(_0x469f83[_0x55771a(0x22a)]??(_0x469f83['ok']?_0x55771a(0x203):_0x55771a(0x237))));const _0xd4117d=a152_0x1faa62({'text':_0x55771a(0x1f2),'color':'cyan'})[_0x55771a(0x1dd)](),_0x6d4195=execCleanMcp(_0x212e26);_0x694b8['push'](_0x6d4195),_0xd4117d[_0x6d4195['ok']?_0x55771a(0x247):_0x55771a(0x21b)]('Step\x204/7:\x20MCP\x20config\x20—\x20'+(_0x6d4195['detail']??(_0x6d4195['ok']?'done':_0x55771a(0x237))));const _0x1cbe4c=a152_0x1faa62({'text':_0x55771a(0x220),'color':'cyan'})[_0x55771a(0x1dd)](),_0x9ceabc=execSkillsRemove(_0x48dd20,_0x95bbba);_0x694b8[_0x55771a(0x21e)](_0x9ceabc),_0x1cbe4c[_0x9ceabc['ok']?'succeed':_0x55771a(0x21b)](_0x55771a(0x1da)+(_0x9ceabc[_0x55771a(0x22a)]??(_0x9ceabc['ok']?_0x55771a(0x203):_0x55771a(0x237))));const _0xabdb99=a152_0x1faa62({'text':_0x55771a(0x23f),'color':_0x55771a(0x233)})['start'](),_0x58ed94=execSkillsAdd(_0x48dd20,_0x95bbba);_0x694b8[_0x55771a(0x21e)](_0x58ed94),_0xabdb99[_0x58ed94['ok']?_0x55771a(0x247):_0x55771a(0x21b)]('Step\x206/7:\x20Install\x20new\x20skill\x20—\x20'+(_0x58ed94[_0x55771a(0x22a)]??(_0x58ed94['ok']?'done':_0x55771a(0x237))));const _0x4787a3=a152_0x1faa62({'text':_0x55771a(0x252),'color':_0x55771a(0x233)})[_0x55771a(0x1dd)](),_0xdb046d=execUpgradeSdk(_0x212e26);_0x694b8[_0x55771a(0x21e)](_0xdb046d),_0x4787a3[_0xdb046d['ok']?'succeed':_0x55771a(0x21b)]('Step\x207/7:\x20@lovrabet/sdk\x20—\x20'+(_0xdb046d[_0x55771a(0x22a)]??(_0xdb046d['ok']?_0x55771a(0x203):'failed'))),printSummary(_0x694b8);const _0x413bcd=_0x694b8[_0x55771a(0x216)](_0x1443ae=>!_0x1443ae['ok']);_0x413bcd?console[_0x55771a(0x22c)](a152_0x55d77d[_0x55771a(0x1ee)](_0x55771a(0x205))):console[_0x55771a(0x22c)](a152_0x55d77d[_0x55771a(0x212)](_0x55771a(0x228))),_0xdb046d['ok']&&_0x212e26[_0x55771a(0x1f3)]&&(console[_0x55771a(0x22c)](''),console[_0x55771a(0x22c)](a152_0x55d77d[_0x55771a(0x206)][_0x55771a(0x233)]('@lovrabet/sdk\x20has\x20been\x20updated\x20to\x20latest\x20in\x20package.json.')),console[_0x55771a(0x22c)](a152_0x55d77d[_0x55771a(0x233)]('Please\x20re-install\x20dependencies\x20to\x20apply\x20the\x20change:')),console[_0x55771a(0x22c)](''),console[_0x55771a(0x22c)](a152_0x55d77d[_0x55771a(0x253)](_0x55771a(0x235))),console['log'](a152_0x55d77d[_0x55771a(0x253)](_0x55771a(0x22b))),console['log'](a152_0x55d77d[_0x55771a(0x253)](_0x55771a(0x246))),console[_0x55771a(0x22c)](''));}
@@ -1 +1 @@
1
- const a153_0xc0ac36=a153_0xd4e5;(function(_0x3efe38,_0x2cc475){const _0xe5e19d=a153_0xd4e5,_0x2c5ce3=_0x3efe38();while(!![]){try{const _0x1c23b4=-parseInt(_0xe5e19d(0xa6))/0x1*(parseInt(_0xe5e19d(0x9b))/0x2)+-parseInt(_0xe5e19d(0x86))/0x3*(parseInt(_0xe5e19d(0x90))/0x4)+-parseInt(_0xe5e19d(0xa7))/0x5+-parseInt(_0xe5e19d(0xa3))/0x6*(parseInt(_0xe5e19d(0x8b))/0x7)+-parseInt(_0xe5e19d(0xb5))/0x8*(parseInt(_0xe5e19d(0x98))/0x9)+-parseInt(_0xe5e19d(0xac))/0xa+parseInt(_0xe5e19d(0x9c))/0xb;if(_0x1c23b4===_0x2cc475)break;else _0x2c5ce3['push'](_0x2c5ce3['shift']());}catch(_0xebc0f){_0x2c5ce3['push'](_0x2c5ce3['shift']());}}}(a153_0x365a,0x3b3cf));import{apiDefinitions}from'../commands/api/index.js';import{bffDefinitions}from'../commands/bff/index.js';import{sqlDefinitions}from'../commands/sql/index.js';import{datasetDefinitions}from'../commands/dataset/index.js';import{pageDefinitions}from'../commands/page/index.js';import{dataDefinitions}from'../commands/data/index.js';import{dbDefinitions}from'../commands/db/index.js';import{codegenDefinitions}from'../commands/codegen/index.js';import{menuDefinitions}from'../commands/menu/index.js';import{taskDefinitions}from'../commands/task/index.js';import{roleDefinitions}from'../commands/role/index.js';import{permitDefinitions}from'../commands/permit/index.js';import{appDefinitions}from'../commands/app/index.js';import{appConfigDefinitions}from'../commands/app-config/index.js';import{notificationDefinitions}from'../commands/notification/index.js';import{workspaceDefinitions}from'../commands/workspace/index.js';import{configDefinitions}from'../commands/config/index.js';import{doctorDefinition}from'../commands/doctor.js';import{updateDefinition}from'../commands/cli-update.js';import{schemaDefinition}from'../commands/schema.js';import{issueDefinitions}from'../commands/issue/index.js';import{fileDefinitions}from'../commands/file/index.js';import{cliSkillDefinitions}from'../commands/cli-skill/index.js';import{authDefinitions}from'../commands/auth/index.js';import{logsDefinitions}from'../commands/logs/index.js';import{projectDefinitions}from'../commands/project/index.js';import{initDefinitions}from'../commands/init/index.js';function a153_0xd4e5(_0x1b6be9,_0x3cdf1e){_0x1b6be9=_0x1b6be9-0x7e;const _0x365ae1=a153_0x365a();let _0xd4e567=_0x365ae1[_0x1b6be9];return _0xd4e567;}import{runDefinition}from'../commands/run/index.js';export const serviceRegistry=[];const serviceByName=new Map();export const definitions=new Map();export const serviceGroups=new Map();function registerDefinitions(_0x1fd44d){const _0x151016=a153_0xd4e5;for(const _0x412071 of _0x1fd44d){definitions[_0x151016(0xb3)](_0x412071[_0x151016(0x91)]+':'+_0x412071[_0x151016(0x85)],_0x412071);let _0x536f38=serviceGroups[_0x151016(0xa8)](_0x412071[_0x151016(0x91)]);!_0x536f38&&(_0x536f38=[],serviceGroups['set'](_0x412071['service'],_0x536f38)),_0x536f38[_0x151016(0xb9)](_0x412071);}}function a153_0x365a(){const _0x816aab=['\x20\x20[high-risk-write]','install','\x20\x20[write]','run','90LidjMd','create','isSingleCommand','1lkxafL','262390iCQCTt','get','`\x20has\x20been\x20removed.','read','build','4190730bkhPJX','start','skill\x20','`rabetbase\x20skills`\x20has\x20been\x20removed.','wildcardDef','`rabetbase\x20app\x20use`\x20has\x20been\x20removed.','Roles','set','app\x20use','1160oABrnK','Configuration','from','values','push','Notification\x20Configuration','remote','Code\x20Generation','filter','login','show','auth','commands','app','CLI\x20Built-in\x20Skill','Self\x20Update','SQL\x20Queries','command','632157YbMNwz','Diagnostics','Workspace','`rabetbase\x20app\x20remote`\x20has\x20been\x20removed.','Authentication','148526wEovxI','API\x20Development','Async\x20Tasks','Platform\x20Issue','Use\x20`rabetbase\x20app\x20list\x20--remote`\x20instead.','4slQPAB','service','skills','Runtime\x20App\x20Config\x20Management','Project','App\x20Management','Instant\x20API','length','19179IJRvjM','Smart\x20List\x20Pages','has','468454UwONmx','19650411ZqzdWa','BFF\x20Scripts','app\x20remote'];a153_0x365a=function(){return _0x816aab;};return a153_0x365a();}function registerDeclarativeService(_0x55b196,_0x30c4e9,_0x3d3563){const _0x5594a1=a153_0xd4e5;registerDefinitions(_0x30c4e9);_0x3d3563?.[_0x5594a1(0xb0)]&&registerDefinitions([_0x3d3563[_0x5594a1(0xb0)]]);const _0x1b8884=_0x4f5621=>_0x4f5621===_0x5594a1(0xaa)?'':_0x4f5621==='write'?_0x5594a1(0xa1):_0x5594a1(0x9f),_0x442706={'service':_0x30c4e9[0x0][_0x5594a1(0x91)],'label':_0x55b196,'commands':_0x30c4e9[_0x5594a1(0xbd)](_0x53f460=>!_0x53f460['hidden'])['map'](_0x2a446c=>({'command':_0x2a446c[_0x5594a1(0x85)],'description':_0x2a446c['description'],'tag':_0x1b8884(_0x2a446c['risk'])})),'declarative':!![],'defaultCommand':_0x3d3563?.['defaultCommand']??(_0x3d3563?.[_0x5594a1(0xa5)]?_0x30c4e9[0x0]['command']:undefined),'wildcardDef':_0x3d3563?.[_0x5594a1(0xb0)],'isSingleCommand':_0x3d3563?.['isSingleCommand']};serviceRegistry[_0x5594a1(0xb9)](_0x442706),serviceByName[_0x5594a1(0xb3)](_0x442706[_0x5594a1(0x91)],_0x442706);}registerDeclarativeService('Quick\x20Start',initDefinitions,{'defaultCommand':'run','isSingleCommand':!![]}),registerDeclarativeService(a153_0xc0ac36(0x94),projectDefinitions),registerDeclarativeService(a153_0xc0ac36(0x88),workspaceDefinitions),registerDeclarativeService(a153_0xc0ac36(0x95),appDefinitions),registerDeclarativeService(a153_0xc0ac36(0x8a),authDefinitions,{'defaultCommand':a153_0xc0ac36(0xbe)}),registerDeclarativeService('Dataset\x20&\x20Operations',datasetDefinitions),registerDeclarativeService(a153_0xc0ac36(0x99),pageDefinitions),registerDeclarativeService(a153_0xc0ac36(0x8c),apiDefinitions),registerDeclarativeService(a153_0xc0ac36(0x96),dataDefinitions),registerDeclarativeService(a153_0xc0ac36(0x9d),bffDefinitions),registerDeclarativeService(a153_0xc0ac36(0xba),notificationDefinitions),registerDeclarativeService(a153_0xc0ac36(0x84),sqlDefinitions),registerDeclarativeService('Database\x20Connections',dbDefinitions),registerDeclarativeService('Menu',menuDefinitions),registerDeclarativeService(a153_0xc0ac36(0x8d),taskDefinitions),registerDeclarativeService(a153_0xc0ac36(0xb2),roleDefinitions),registerDeclarativeService('Permissions',permitDefinitions),registerDeclarativeService(a153_0xc0ac36(0x93),appConfigDefinitions),registerDeclarativeService(a153_0xc0ac36(0x8e),issueDefinitions),registerDeclarativeService('File',fileDefinitions),registerDeclarativeService(a153_0xc0ac36(0xbc),codegenDefinitions),registerDeclarativeService(a153_0xc0ac36(0xb6),configDefinitions),registerDeclarativeService(a153_0xc0ac36(0x87),[doctorDefinition],{'isSingleCommand':!![]}),registerDeclarativeService('Schema',[schemaDefinition],{'isSingleCommand':!![]}),registerDeclarativeService(a153_0xc0ac36(0x83),[updateDefinition],{'isSingleCommand':!![]}),registerDeclarativeService(a153_0xc0ac36(0x82),cliSkillDefinitions,{'defaultCommand':a153_0xc0ac36(0xa0)}),registerDeclarativeService('Logs',logsDefinitions,{'defaultCommand':a153_0xc0ac36(0x7e)}),registerDeclarativeService('Run\x20Scripts',[runDefinition],{'wildcardDef':runDefinition});{const last=serviceRegistry[serviceRegistry[a153_0xc0ac36(0x97)]-0x1];last[a153_0xc0ac36(0x80)]=[{'command':'<script>','description':'Run\x20any\x20package.json\x20script','tag':''}];}export const deprecatedAliases={'create':{'service':'project','command':a153_0xc0ac36(0xa4)},'start':{'service':'run','command':a153_0xc0ac36(0xad)},'build':{'service':a153_0xc0ac36(0xa2),'command':a153_0xc0ac36(0xab)},'preview':{'service':'run','command':'preview'},'logout':{'service':a153_0xc0ac36(0x7f),'command':'logout'}};const CLI_SKILL_INSTALL_REMOVED_HINT='Use\x20`rabetbase\x20cli-skill\x20install`\x20to\x20refresh\x20the\x20Rabetbase\x20CLI\x20Built-in\x20Skill.\x20To\x20install\x20business\x20Skills,\x20use\x20`lovrabet\x20skill\x20install`.',APP_REMOTE_REMOVED_HINT=a153_0xc0ac36(0x8f),APP_USE_REMOVED_HINT='Use\x20`rabetbase\x20workspace\x20use\x20--app\x20<name>`\x20instead.';export function resolveRemovedCommand(_0x9ad407,_0x5a7930){const _0x5a44ca=a153_0xc0ac36;if(_0x9ad407==='skill'){const _0x206d22=_0x5a7930?_0x5a44ca(0xae)+_0x5a7930:'skill';return{'command':_0x206d22,'message':'`rabetbase\x20'+_0x206d22+_0x5a44ca(0xa9),'hint':CLI_SKILL_INSTALL_REMOVED_HINT};}if(_0x9ad407===_0x5a44ca(0x92))return{'command':_0x5a44ca(0x92),'message':_0x5a44ca(0xaf),'hint':CLI_SKILL_INSTALL_REMOVED_HINT};if(_0x9ad407===_0x5a44ca(0x81)&&_0x5a7930===_0x5a44ca(0xbb))return{'command':_0x5a44ca(0x9e),'message':_0x5a44ca(0x89),'hint':APP_REMOTE_REMOVED_HINT};if(_0x9ad407===_0x5a44ca(0x81)&&_0x5a7930==='use')return{'command':_0x5a44ca(0xb4),'message':_0x5a44ca(0xb1),'hint':APP_USE_REMOVED_HINT};return undefined;}export const deprecatedSubcommands={'bff':{'new':a153_0xc0ac36(0xa4)},'sql':{'new':'create'}};export function resolveDeprecatedSubcommand(_0x1e4482,_0x4bf59d){return deprecatedSubcommands[_0x1e4482]?.[_0x4bf59d];}export function findDefinition(_0x7f3dae,_0x2baa7b){const _0x1d86be=a153_0xc0ac36;return definitions[_0x1d86be(0xa8)](_0x7f3dae+':'+_0x2baa7b);}export function isKnownService(_0x1f97bb){const _0x4cf686=a153_0xc0ac36;return serviceByName[_0x4cf686(0x9a)](_0x1f97bb);}export function isDeclarativeService(_0x4aef76){const _0x35160f=a153_0xc0ac36;return serviceGroups[_0x35160f(0x9a)](_0x4aef76)||serviceByName[_0x35160f(0xa8)](_0x4aef76)?.['wildcardDef']!==undefined;}export function getServiceEntry(_0x4e1beb){const _0x5032f8=a153_0xc0ac36;return serviceByName[_0x5032f8(0xa8)](_0x4e1beb);}export function getLegacyHandler(_0x4e2604,_0x1cb98a){return undefined;}export function getAllDefinitions(){const _0x561e2c=a153_0xc0ac36;return Array[_0x561e2c(0xb7)](definitions[_0x561e2c(0xb8)]());}
1
+ const a153_0x3301c2=a153_0x48aa;(function(_0x1af85a,_0x30fc1a){const _0x2e51cf=a153_0x48aa,_0x39f3b1=_0x1af85a();while(!![]){try{const _0x4b94a7=-parseInt(_0x2e51cf(0xd3))/0x1*(-parseInt(_0x2e51cf(0xba))/0x2)+parseInt(_0x2e51cf(0xc2))/0x3*(-parseInt(_0x2e51cf(0xce))/0x4)+-parseInt(_0x2e51cf(0xcd))/0x5+-parseInt(_0x2e51cf(0xea))/0x6*(parseInt(_0x2e51cf(0xe4))/0x7)+parseInt(_0x2e51cf(0xd8))/0x8*(parseInt(_0x2e51cf(0xd0))/0x9)+parseInt(_0x2e51cf(0xd5))/0xa+-parseInt(_0x2e51cf(0xbf))/0xb*(-parseInt(_0x2e51cf(0xe8))/0xc);if(_0x4b94a7===_0x30fc1a)break;else _0x39f3b1['push'](_0x39f3b1['shift']());}catch(_0x5531ff){_0x39f3b1['push'](_0x39f3b1['shift']());}}}(a153_0x359c,0x328a8));import{apiDefinitions}from'../commands/api/index.js';import{bffDefinitions}from'../commands/bff/index.js';import{sqlDefinitions}from'../commands/sql/index.js';import{datasetDefinitions}from'../commands/dataset/index.js';function a153_0x48aa(_0x253b88,_0x79698b){_0x253b88=_0x253b88-0xa9;const _0x359cb7=a153_0x359c();let _0x48aa56=_0x359cb7[_0x253b88];return _0x48aa56;}import{pageDefinitions}from'../commands/page/index.js';import{dataDefinitions}from'../commands/data/index.js';import{dbDefinitions}from'../commands/db/index.js';import{codegenDefinitions}from'../commands/codegen/index.js';import{menuDefinitions}from'../commands/menu/index.js';import{taskDefinitions}from'../commands/task/index.js';import{roleDefinitions}from'../commands/role/index.js';import{permitDefinitions}from'../commands/permit/index.js';import{appDefinitions}from'../commands/app/index.js';import{appConfigDefinitions}from'../commands/app-config/index.js';import{notificationDefinitions}from'../commands/notification/index.js';import{workspaceDefinitions}from'../commands/workspace/index.js';import{configDefinitions}from'../commands/config/index.js';import{doctorDefinition}from'../commands/doctor.js';import{updateDefinition}from'../commands/cli-update.js';import{schemaDefinition}from'../commands/schema.js';import{issueDefinitions}from'../commands/issue/index.js';import{fileDefinitions}from'../commands/file/index.js';import{cliSkillDefinitions}from'../commands/cli-skill/index.js';import{authDefinitions}from'../commands/auth/index.js';import{logsDefinitions}from'../commands/logs/index.js';import{projectDefinitions}from'../commands/project/index.js';import{initDefinitions}from'../commands/init/index.js';import{runDefinition}from'../commands/run/index.js';export const serviceRegistry=[];const serviceByName=new Map();export const definitions=new Map();export const serviceGroups=new Map();function registerDefinitions(_0xed2f7a){const _0x153ac1=a153_0x48aa;for(const _0x5420f5 of _0xed2f7a){definitions[_0x153ac1(0xbb)](_0x5420f5['service']+':'+_0x5420f5[_0x153ac1(0xb6)],_0x5420f5);let _0x2f358a=serviceGroups[_0x153ac1(0xe5)](_0x5420f5[_0x153ac1(0xda)]);!_0x2f358a&&(_0x2f358a=[],serviceGroups[_0x153ac1(0xbb)](_0x5420f5[_0x153ac1(0xda)],_0x2f358a)),_0x2f358a[_0x153ac1(0xdc)](_0x5420f5);}}function registerDeclarativeService(_0x2532d4,_0x316331,_0x33abac){const _0x3a129d=a153_0x48aa;registerDefinitions(_0x316331);_0x33abac?.['wildcardDef']&&registerDefinitions([_0x33abac['wildcardDef']]);const _0x5af420=_0x1d04b6=>_0x1d04b6==='read'?'':_0x1d04b6===_0x3a129d(0xd6)?'\x20\x20[write]':_0x3a129d(0xe7),_0x1775b9={'service':_0x316331[0x0]['service'],'label':_0x2532d4,'commands':_0x316331['filter'](_0x1f8543=>!_0x1f8543['hidden'])[_0x3a129d(0xe6)](_0x62d72c=>({'command':_0x62d72c[_0x3a129d(0xb6)],'description':_0x62d72c[_0x3a129d(0xdf)],'tag':_0x5af420(_0x62d72c[_0x3a129d(0xde)])})),'declarative':!![],'defaultCommand':_0x33abac?.['defaultCommand']??(_0x33abac?.['isSingleCommand']?_0x316331[0x0]['command']:undefined),'wildcardDef':_0x33abac?.[_0x3a129d(0xc7)],'isSingleCommand':_0x33abac?.['isSingleCommand']};serviceRegistry['push'](_0x1775b9),serviceByName[_0x3a129d(0xbb)](_0x1775b9['service'],_0x1775b9);}registerDeclarativeService(a153_0x3301c2(0xae),initDefinitions,{'defaultCommand':a153_0x3301c2(0xd1),'isSingleCommand':!![]}),registerDeclarativeService(a153_0x3301c2(0xad),projectDefinitions),registerDeclarativeService(a153_0x3301c2(0xb4),workspaceDefinitions),registerDeclarativeService(a153_0x3301c2(0xc8),appDefinitions),registerDeclarativeService('Authentication',authDefinitions,{'defaultCommand':'login'}),registerDeclarativeService('Dataset\x20&\x20Operations',datasetDefinitions),registerDeclarativeService(a153_0x3301c2(0xbe),pageDefinitions),registerDeclarativeService(a153_0x3301c2(0xe0),apiDefinitions),registerDeclarativeService('Instant\x20API',dataDefinitions),registerDeclarativeService(a153_0x3301c2(0xd2),bffDefinitions),registerDeclarativeService('Notification\x20Configuration',notificationDefinitions),registerDeclarativeService(a153_0x3301c2(0xc0),sqlDefinitions),registerDeclarativeService('Database\x20Connections',dbDefinitions),registerDeclarativeService('Menu',menuDefinitions),registerDeclarativeService(a153_0x3301c2(0xbd),taskDefinitions),registerDeclarativeService(a153_0x3301c2(0xb3),roleDefinitions),registerDeclarativeService(a153_0x3301c2(0xc4),permitDefinitions),registerDeclarativeService(a153_0x3301c2(0xc1),appConfigDefinitions),registerDeclarativeService(a153_0x3301c2(0xa9),issueDefinitions),registerDeclarativeService(a153_0x3301c2(0xd7),fileDefinitions),registerDeclarativeService(a153_0x3301c2(0xe3),codegenDefinitions),registerDeclarativeService(a153_0x3301c2(0xd4),configDefinitions),registerDeclarativeService(a153_0x3301c2(0xb0),[doctorDefinition],{'isSingleCommand':!![]}),registerDeclarativeService(a153_0x3301c2(0xb5),[schemaDefinition],{'isSingleCommand':!![]}),registerDeclarativeService(a153_0x3301c2(0xcb),[updateDefinition],{'isSingleCommand':!![]}),registerDeclarativeService(a153_0x3301c2(0xeb),cliSkillDefinitions,{'defaultCommand':'install'}),registerDeclarativeService(a153_0x3301c2(0xc9),logsDefinitions,{'defaultCommand':a153_0x3301c2(0xac)}),registerDeclarativeService('Run\x20Scripts',[runDefinition],{'wildcardDef':runDefinition});{const last=serviceRegistry[serviceRegistry[a153_0x3301c2(0xd9)]-0x1];last[a153_0x3301c2(0xb2)]=[{'command':a153_0x3301c2(0xcf),'description':a153_0x3301c2(0xe2),'tag':''}];}export const deprecatedAliases={'create':{'service':'project','command':a153_0x3301c2(0xb8)},'start':{'service':'run','command':a153_0x3301c2(0xb7)},'build':{'service':a153_0x3301c2(0xd1),'command':a153_0x3301c2(0xdb)},'preview':{'service':'run','command':'preview'},'logout':{'service':a153_0x3301c2(0xcc),'command':'logout'}};const CLI_SKILL_INSTALL_REMOVED_HINT='Use\x20`rabetbase\x20cli-skill\x20install`\x20to\x20refresh\x20the\x20Rabetbase\x20CLI\x20Built-in\x20Skill.\x20To\x20install\x20business\x20Skills,\x20use\x20`lovrabet\x20skill\x20install`.',APP_REMOTE_REMOVED_HINT=a153_0x3301c2(0xaa),APP_USE_REMOVED_HINT=a153_0x3301c2(0xdd);export function resolveRemovedCommand(_0x3765e9,_0x26886e){const _0x31648a=a153_0x3301c2;if(_0x3765e9===_0x31648a(0xc5)){const _0x2aceaf=_0x26886e?_0x31648a(0xaf)+_0x26886e:_0x31648a(0xc5);return{'command':_0x2aceaf,'message':'`rabetbase\x20'+_0x2aceaf+_0x31648a(0xca),'hint':CLI_SKILL_INSTALL_REMOVED_HINT};}if(_0x3765e9==='skills')return{'command':'skills','message':_0x31648a(0xe1),'hint':CLI_SKILL_INSTALL_REMOVED_HINT};if(_0x3765e9===_0x31648a(0xab)&&_0x26886e===_0x31648a(0xc3))return{'command':_0x31648a(0xe9),'message':'`rabetbase\x20app\x20remote`\x20has\x20been\x20removed.','hint':APP_REMOTE_REMOVED_HINT};if(_0x3765e9==='app'&&_0x26886e===_0x31648a(0xc6))return{'command':_0x31648a(0xb9),'message':'`rabetbase\x20app\x20use`\x20has\x20been\x20removed.','hint':APP_USE_REMOVED_HINT};return undefined;}export const deprecatedSubcommands={'bff':{'new':a153_0x3301c2(0xb8)},'sql':{'new':a153_0x3301c2(0xb8)}};export function resolveDeprecatedSubcommand(_0x6a2f40,_0x35ce21){return deprecatedSubcommands[_0x6a2f40]?.[_0x35ce21];}export function findDefinition(_0x5bd027,_0x481719){const _0x46a223=a153_0x3301c2;return definitions[_0x46a223(0xe5)](_0x5bd027+':'+_0x481719);}function a153_0x359c(){const _0x232b2d=['112eoyZuP','get','map','\x20\x20[high-risk-write]','1497756sUFdrq','app\x20remote','122790jTfRsq','CLI\x20Built-in\x20Skill','Platform\x20Issue','Use\x20`rabetbase\x20app\x20list\x20--remote`\x20instead.','app','show','Project','Quick\x20Start','skill\x20','Diagnostics','has','commands','Roles','Workspace','Schema','command','start','create','app\x20use','2SZzFOC','set','values','Async\x20Tasks','Smart\x20List\x20Pages','22QHXfmd','SQL\x20Queries','Runtime\x20App\x20Config\x20Management','76794UaHpib','remote','Permissions','skill','use','wildcardDef','App\x20Management','Logs','`\x20has\x20been\x20removed.','Self\x20Update','auth','1466685xuExeU','36qbICqE','<script>','59679yHCQpi','run','BFF\x20Scripts','381624EIAkUZ','Configuration','1417920rplTcL','write','File','344EMyDIl','length','service','build','push','Use\x20`rabetbase\x20workspace\x20use\x20--app\x20<name>`\x20instead.','risk','description','API\x20Development','`rabetbase\x20skills`\x20has\x20been\x20removed.','Run\x20any\x20package.json\x20script','Code\x20Generation'];a153_0x359c=function(){return _0x232b2d;};return a153_0x359c();}export function isKnownService(_0x29b2f2){const _0xb7cd28=a153_0x3301c2;return serviceByName[_0xb7cd28(0xb1)](_0x29b2f2);}export function isDeclarativeService(_0xbc09f2){const _0x742a05=a153_0x3301c2;return serviceGroups[_0x742a05(0xb1)](_0xbc09f2)||serviceByName[_0x742a05(0xe5)](_0xbc09f2)?.[_0x742a05(0xc7)]!==undefined;}export function getServiceEntry(_0x6efa6f){return serviceByName['get'](_0x6efa6f);}export function getLegacyHandler(_0x54f76b,_0x530bba){return undefined;}export function getAllDefinitions(){const _0x2762da=a153_0x3301c2;return Array['from'](definitions[_0x2762da(0xbc)]());}
@@ -1 +1 @@
1
- const a154_0x1270fe=a154_0x3aba;function a154_0x3aba(_0x152f4d,_0x5d01d4){_0x152f4d=_0x152f4d-0x164;const _0x144c52=a154_0x144c();let _0x3abaa7=_0x144c52[_0x152f4d];return _0x3abaa7;}(function(_0x2f8e8c,_0x3531d1){const _0x1dadd7=a154_0x3aba,_0x313511=_0x2f8e8c();while(!![]){try{const _0x4621c5=-parseInt(_0x1dadd7(0x16a))/0x1+-parseInt(_0x1dadd7(0x176))/0x2+-parseInt(_0x1dadd7(0x16f))/0x3*(-parseInt(_0x1dadd7(0x174))/0x4)+parseInt(_0x1dadd7(0x175))/0x5*(-parseInt(_0x1dadd7(0x180))/0x6)+-parseInt(_0x1dadd7(0x179))/0x7+parseInt(_0x1dadd7(0x171))/0x8+parseInt(_0x1dadd7(0x17f))/0x9;if(_0x4621c5===_0x3531d1)break;else _0x313511['push'](_0x313511['shift']());}catch(_0x18a658){_0x313511['push'](_0x313511['shift']());}}}(a154_0x144c,0x95e50));import{createAppRole}from'../../core/api-client.js';function a154_0x144c(){const _0x4104a5=['role','remark','\x20(id=','Pass\x20--name\x20<roleName>.','appCode','flagMissing','885866tGuTOe','Created\x20role\x20','roleName','Role\x20name\x20cannot\x20exceed\x2064\x20characters.','/smartapi/permit/role/create','806712AlbxUM','CUSTOM','869016kxLnph','trim','name','4DBBJFa','30njMeVx','1107150bpnWHk','write','Create\x20a\x20CUSTOM\x20user\x20group\x20(role)','6483351uLjWbm','str','validation','POST','length','create','29534733lzKfsC','679566pwdxlw'];a154_0x144c=function(){return _0x4104a5;};return a154_0x144c();}import{CliErrors}from'../../errors.js';import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{asDryRunResult}from'../../commands/common/dry-run.js';import{NAME_FLAG,REMARK_FLAG,projectRole}from'../../commands/role/shared.js';const CREATE_PATH=a154_0x1270fe(0x16e);function readName(_0x50b276){const _0x3fb4bb=a154_0x1270fe,_0x52ea2a=_0x50b276[_0x3fb4bb(0x17a)](_0x3fb4bb(0x173))['trim']();if(!_0x52ea2a)throw CliErrors[_0x3fb4bb(0x169)](_0x3fb4bb(0x173),_0x3fb4bb(0x167));if(_0x52ea2a[_0x3fb4bb(0x17d)]>0x40)throw CliErrors[_0x3fb4bb(0x17b)](_0x3fb4bb(0x16d));return _0x52ea2a;}export const roleCreate={'service':a154_0x1270fe(0x164),'command':a154_0x1270fe(0x17e),'description':a154_0x1270fe(0x178),'risk':a154_0x1270fe(0x177),'flags':[NAME_FLAG,REMARK_FLAG,APPCODE_FLAG_OPTIONAL],async 'validate'(_0x3f8c6d){readName(_0x3f8c6d);},async 'dryRun'(_0x846ab2){const _0x55b1e4=a154_0x1270fe,_0x126b7e=readName(_0x846ab2),_0x27ebdc=_0x846ab2[_0x55b1e4(0x17a)]('remark')['trim']()||undefined;return asDryRunResult({'operation':_0x55b1e4(0x17e),'selector':{'appCode':_0x846ab2[_0x55b1e4(0x168)],'roleName':_0x126b7e},'before':null,'after':{'roleName':_0x126b7e,'roleType':_0x55b1e4(0x170),'remark':_0x27ebdc},'dryRun':!![],'backend':{'method':_0x55b1e4(0x17c),'path':CREATE_PATH},'warnings':[]},{'method':_0x55b1e4(0x17c),'url':CREATE_PATH});},async 'execute'(_0x2158fe){const _0x1c30d2=a154_0x1270fe,_0x895488=readName(_0x2158fe),_0x22ef65=_0x2158fe[_0x1c30d2(0x17a)](_0x1c30d2(0x165))[_0x1c30d2(0x172)]()||undefined,_0x44b7d9=await createAppRole({'appCode':_0x2158fe[_0x1c30d2(0x168)],'roleName':_0x895488,..._0x22ef65?{'remark':_0x22ef65}:{}});return{'ok':!![],'data':{'operation':_0x1c30d2(0x17e),'selector':{'appCode':_0x2158fe[_0x1c30d2(0x168)],'roleId':_0x44b7d9['id'],'roleName':_0x895488},'before':null,'after':projectRole(_0x44b7d9),'dryRun':![],'backend':{'method':_0x1c30d2(0x17c),'path':CREATE_PATH},'warnings':[]},'message':_0x1c30d2(0x16b)+_0x44b7d9[_0x1c30d2(0x16c)]+_0x1c30d2(0x166)+_0x44b7d9['id']+')'};}};
1
+ const a154_0x502a88=a154_0x34c9;(function(_0xea5ae0,_0x3447eb){const _0x334e12=a154_0x34c9,_0x4caffb=_0xea5ae0();while(!![]){try{const _0x473e30=parseInt(_0x334e12(0xd2))/0x1+parseInt(_0x334e12(0xce))/0x2+-parseInt(_0x334e12(0xd7))/0x3+-parseInt(_0x334e12(0xdf))/0x4+-parseInt(_0x334e12(0xe2))/0x5+parseInt(_0x334e12(0xd5))/0x6+-parseInt(_0x334e12(0xde))/0x7*(parseInt(_0x334e12(0xe8))/0x8);if(_0x473e30===_0x3447eb)break;else _0x4caffb['push'](_0x4caffb['shift']());}catch(_0x7c5773){_0x4caffb['push'](_0x4caffb['shift']());}}}(a154_0x25ef,0x9edb3));function a154_0x34c9(_0x1f9dcb,_0x301439){_0x1f9dcb=_0x1f9dcb-0xce;const _0x25ef0a=a154_0x25ef();let _0x34c9c4=_0x25ef0a[_0x1f9dcb];return _0x34c9c4;}import{createAppRole}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{asDryRunResult}from'../../commands/common/dry-run.js';import{NAME_FLAG,REMARK_FLAG,projectRole}from'../../commands/role/shared.js';const CREATE_PATH=a154_0x502a88(0xd0);function a154_0x25ef(){const _0x315d5e=['Role\x20name\x20cannot\x20exceed\x2064\x20characters.','/smartapi/permit/role/create','\x20(id=','866475yNAsBV','remark','write','6339534wsfDjp','flagMissing','3618975PePIXY','Created\x20role\x20','validation','str','Create\x20a\x20CUSTOM\x20user\x20group\x20(role)','POST','Pass\x20--name\x20<roleName>.','1806917oEgElc','61324jCrvvh','create','trim','3145530ejBEvz','appCode','CUSTOM','role','name','roleName','8aiwTvg','1673008PQNuAU'];a154_0x25ef=function(){return _0x315d5e;};return a154_0x25ef();}function readName(_0x115ea5){const _0x547824=a154_0x502a88,_0xcdc43b=_0x115ea5[_0x547824(0xda)](_0x547824(0xe6))[_0x547824(0xe1)]();if(!_0xcdc43b)throw CliErrors[_0x547824(0xd6)]('name',_0x547824(0xdd));if(_0xcdc43b['length']>0x40)throw CliErrors[_0x547824(0xd9)](_0x547824(0xcf));return _0xcdc43b;}export const roleCreate={'service':a154_0x502a88(0xe5),'command':a154_0x502a88(0xe0),'description':a154_0x502a88(0xdb),'risk':a154_0x502a88(0xd4),'flags':[NAME_FLAG,REMARK_FLAG,APPCODE_FLAG_OPTIONAL],async 'validate'(_0x132e16){readName(_0x132e16);},async 'dryRun'(_0x1c4749){const _0x417adf=a154_0x502a88,_0x441e2a=readName(_0x1c4749),_0x363b40=_0x1c4749[_0x417adf(0xda)](_0x417adf(0xd3))['trim']()||undefined;return asDryRunResult({'operation':'create','selector':{'appCode':_0x1c4749['appCode'],'roleName':_0x441e2a},'before':null,'after':{'roleName':_0x441e2a,'roleType':_0x417adf(0xe4),'remark':_0x363b40},'dryRun':!![],'backend':{'method':'POST','path':CREATE_PATH},'warnings':[]},{'method':_0x417adf(0xdc),'url':CREATE_PATH});},async 'execute'(_0x292bc8){const _0xba4df=a154_0x502a88,_0x3a0059=readName(_0x292bc8),_0x5ae339=_0x292bc8[_0xba4df(0xda)](_0xba4df(0xd3))[_0xba4df(0xe1)]()||undefined,_0x263404=await createAppRole({'appCode':_0x292bc8['appCode'],'roleName':_0x3a0059,..._0x5ae339?{'remark':_0x5ae339}:{}});return{'ok':!![],'data':{'operation':_0xba4df(0xe0),'selector':{'appCode':_0x292bc8[_0xba4df(0xe3)],'roleId':_0x263404['id'],'roleName':_0x3a0059},'before':null,'after':projectRole(_0x263404),'dryRun':![],'backend':{'method':_0xba4df(0xdc),'path':CREATE_PATH},'warnings':[]},'message':_0xba4df(0xd8)+_0x263404[_0xba4df(0xe7)]+_0xba4df(0xd1)+_0x263404['id']+')'};}};
@@ -1 +1 @@
1
- const a155_0x53809c=a155_0x14ca;(function(_0x160573,_0x140f7c){const _0x58d85e=a155_0x14ca,_0x283a32=_0x160573();while(!![]){try{const _0x1b425e=parseInt(_0x58d85e(0x14f))/0x1+parseInt(_0x58d85e(0x14e))/0x2+-parseInt(_0x58d85e(0x148))/0x3*(-parseInt(_0x58d85e(0x142))/0x4)+parseInt(_0x58d85e(0x156))/0x5*(parseInt(_0x58d85e(0x14a))/0x6)+-parseInt(_0x58d85e(0x144))/0x7+-parseInt(_0x58d85e(0x14d))/0x8*(parseInt(_0x58d85e(0x153))/0x9)+parseInt(_0x58d85e(0x149))/0xa*(parseInt(_0x58d85e(0x14b))/0xb);if(_0x1b425e===_0x140f7c)break;else _0x283a32['push'](_0x283a32['shift']());}catch(_0x1b4a2c){_0x283a32['push'](_0x283a32['shift']());}}}(a155_0x3802,0x68fa0));import{deleteAppRole}from'../../core/api-client.js';import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{asDryRunResult}from'../../commands/common/dry-run.js';function a155_0x14ca(_0x16c79a,_0x4b914c){_0x16c79a=_0x16c79a-0x142;const _0x3802e8=a155_0x3802();let _0x14ca84=_0x3802e8[_0x16c79a];return _0x14ca84;}import{assertCustomRole,getRoleById,projectRole,ROLE_ID_FLAG}from'../../commands/role/shared.js';const DELETE_PATH='/smartapi/permit/role/delete';export const roleDelete={'service':a155_0x53809c(0x147),'command':'delete','description':a155_0x53809c(0x150),'risk':'high-risk-write','flags':[ROLE_ID_FLAG,APPCODE_FLAG_OPTIONAL],async 'dryRun'(_0x3e8f5f){const _0x198d9d=a155_0x53809c,_0xb3ce71=_0x3e8f5f[_0x198d9d(0x146)]('id'),_0x511b36=await getRoleById(_0x3e8f5f[_0x198d9d(0x155)],_0xb3ce71);return assertCustomRole(_0x511b36,_0x198d9d(0x143)),asDryRunResult({'operation':'delete','selector':{'appCode':_0x3e8f5f[_0x198d9d(0x155)],'roleId':_0xb3ce71,'roleName':_0x511b36['roleName']},'before':projectRole(_0x511b36),'after':null,'dryRun':!![],'backend':{'method':_0x198d9d(0x151),'path':DELETE_PATH},'warnings':_0x511b36[_0x198d9d(0x157)]>0x0?[_0x198d9d(0x152)+_0x511b36[_0x198d9d(0x157)]+_0x198d9d(0x154)]:[]},{'method':_0x198d9d(0x151),'url':DELETE_PATH});},async 'execute'(_0x3e607d){const _0x12273b=a155_0x53809c,_0x4811de=_0x3e607d[_0x12273b(0x146)]('id'),_0x40d205=await getRoleById(_0x3e607d[_0x12273b(0x155)],_0x4811de);return assertCustomRole(_0x40d205,_0x12273b(0x143)),await deleteAppRole(_0x4811de),{'ok':!![],'data':{'operation':_0x12273b(0x143),'selector':{'appCode':_0x3e607d[_0x12273b(0x155)],'roleId':_0x4811de,'roleName':_0x40d205['roleName']},'before':projectRole(_0x40d205),'after':null,'dryRun':![],'backend':{'method':'POST','path':DELETE_PATH},'warnings':[]},'message':_0x12273b(0x14c)+_0x40d205[_0x12273b(0x145)]+_0x12273b(0x158)+_0x4811de+')'};}};function a155_0x3802(){const _0x1a4fb9=['6202089ZApJMO','\x20member(s);\x20they\x20will\x20lose\x20this\x20group.','appCode','15NQrXTs','userCount','\x20(id=','48144NUgIxD','delete','155512QpJCyf','roleName','num','role','15ovpsCH','363470uPoAKF','520716NrVJPU','11CoUAtr','Deleted\x20role\x20','8XjAnFK','574918eBVHxr','496977JTBsOD','Delete\x20a\x20CUSTOM\x20role\x20(DEV/ADMIN\x20rejected);\x20requires\x20--yes','POST','Role\x20still\x20has\x20'];a155_0x3802=function(){return _0x1a4fb9;};return a155_0x3802();}
1
+ const a155_0x447026=a155_0x169e;(function(_0x3ca521,_0x346b12){const _0x5d180a=a155_0x169e,_0xe2dfc0=_0x3ca521();while(!![]){try{const _0x3be6fd=-parseInt(_0x5d180a(0x1c6))/0x1*(parseInt(_0x5d180a(0x1c9))/0x2)+-parseInt(_0x5d180a(0x1c2))/0x3+-parseInt(_0x5d180a(0x1bb))/0x4*(-parseInt(_0x5d180a(0x1c5))/0x5)+parseInt(_0x5d180a(0x1b5))/0x6*(parseInt(_0x5d180a(0x1c1))/0x7)+parseInt(_0x5d180a(0x1bc))/0x8*(-parseInt(_0x5d180a(0x1b7))/0x9)+parseInt(_0x5d180a(0x1ca))/0xa+parseInt(_0x5d180a(0x1c3))/0xb;if(_0x3be6fd===_0x346b12)break;else _0xe2dfc0['push'](_0xe2dfc0['shift']());}catch(_0x8bdb78){_0xe2dfc0['push'](_0xe2dfc0['shift']());}}}(a155_0x3a43,0xa4263));function a155_0x169e(_0x330b27,_0x49b0b7){_0x330b27=_0x330b27-0x1b4;const _0x3a4332=a155_0x3a43();let _0x169e29=_0x3a4332[_0x330b27];return _0x169e29;}import{deleteAppRole}from'../../core/api-client.js';import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{asDryRunResult}from'../../commands/common/dry-run.js';import{assertCustomRole,getRoleById,projectRole,ROLE_ID_FLAG}from'../../commands/role/shared.js';const DELETE_PATH=a155_0x447026(0x1bf);export const roleDelete={'service':'role','command':a155_0x447026(0x1be),'description':'Delete\x20a\x20CUSTOM\x20role\x20(DEV/ADMIN\x20rejected);\x20requires\x20--yes','risk':a155_0x447026(0x1c0),'flags':[ROLE_ID_FLAG,APPCODE_FLAG_OPTIONAL],async 'dryRun'(_0x46dd3e){const _0x55e1b1=a155_0x447026,_0x2f2663=_0x46dd3e['num']('id'),_0x375094=await getRoleById(_0x46dd3e[_0x55e1b1(0x1c8)],_0x2f2663);return assertCustomRole(_0x375094,_0x55e1b1(0x1be)),asDryRunResult({'operation':_0x55e1b1(0x1be),'selector':{'appCode':_0x46dd3e[_0x55e1b1(0x1c8)],'roleId':_0x2f2663,'roleName':_0x375094['roleName']},'before':projectRole(_0x375094),'after':null,'dryRun':!![],'backend':{'method':'POST','path':DELETE_PATH},'warnings':_0x375094[_0x55e1b1(0x1b4)]>0x0?[_0x55e1b1(0x1bd)+_0x375094['userCount']+_0x55e1b1(0x1b6)]:[]},{'method':'POST','url':DELETE_PATH});},async 'execute'(_0x5d8d8f){const _0x2a04fd=a155_0x447026,_0x33c959=_0x5d8d8f[_0x2a04fd(0x1c4)]('id'),_0x22e377=await getRoleById(_0x5d8d8f[_0x2a04fd(0x1c8)],_0x33c959);return assertCustomRole(_0x22e377,_0x2a04fd(0x1be)),await deleteAppRole(_0x33c959),{'ok':!![],'data':{'operation':_0x2a04fd(0x1be),'selector':{'appCode':_0x5d8d8f[_0x2a04fd(0x1c8)],'roleId':_0x33c959,'roleName':_0x22e377[_0x2a04fd(0x1ba)]},'before':projectRole(_0x22e377),'after':null,'dryRun':![],'backend':{'method':_0x2a04fd(0x1c7),'path':DELETE_PATH},'warnings':[]},'message':_0x2a04fd(0x1b8)+_0x22e377[_0x2a04fd(0x1ba)]+_0x2a04fd(0x1b9)+_0x33c959+')'};}};function a155_0x3a43(){const _0x213e2d=['\x20member(s);\x20they\x20will\x20lose\x20this\x20group.','2421dXRZAy','Deleted\x20role\x20','\x20(id=','roleName','57788UsXEbb','29504xBGVyh','Role\x20still\x20has\x20','delete','/smartapi/permit/role/delete','high-risk-write','2697884cqzMab','3768765HMEjlf','26172047xwaPEa','num','15vvMegJ','129msmcjo','POST','appCode','17834MRJHxO','4921210DLbrGu','userCount','18KkcuQN'];a155_0x3a43=function(){return _0x213e2d;};return a155_0x3a43();}
@@ -1 +1 @@
1
- const a156_0x5a0e9d=a156_0x43cd;(function(_0x7d4b2e,_0x24f833){const _0x1aa944=a156_0x43cd,_0x247c58=_0x7d4b2e();while(!![]){try{const _0x423d16=parseInt(_0x1aa944(0xdd))/0x1+parseInt(_0x1aa944(0xe0))/0x2*(-parseInt(_0x1aa944(0xd5))/0x3)+parseInt(_0x1aa944(0xde))/0x4*(parseInt(_0x1aa944(0xdb))/0x5)+parseInt(_0x1aa944(0xd6))/0x6+-parseInt(_0x1aa944(0xd8))/0x7+-parseInt(_0x1aa944(0xd9))/0x8+parseInt(_0x1aa944(0xe2))/0x9;if(_0x423d16===_0x24f833)break;else _0x247c58['push'](_0x247c58['shift']());}catch(_0x4bdc3b){_0x247c58['push'](_0x247c58['shift']());}}}(a156_0x2b90,0xe730d));import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function a156_0x43cd(_0x324a60,_0x30d286){_0x324a60=_0x324a60-0xd5;const _0x2b9022=a156_0x2b90();let _0x43cd12=_0x2b9022[_0x324a60];return _0x43cd12;}import{getRoleById,projectRole,ROLE_ID_FLAG}from'../../commands/role/shared.js';export const roleDetail={'service':a156_0x5a0e9d(0xe1),'command':a156_0x5a0e9d(0xdf),'description':a156_0x5a0e9d(0xd7),'risk':'read','flags':[ROLE_ID_FLAG,APPCODE_FLAG_OPTIONAL],async 'execute'(_0x29797e){const _0x98351a=a156_0x5a0e9d,_0x5e5233=_0x29797e[_0x98351a(0xdc)]('id'),_0x28f428=await getRoleById(_0x29797e['appCode'],_0x5e5233);return{'ok':!![],'data':{'role':projectRole(_0x28f428)},'message':_0x98351a(0xda)+_0x28f428['roleName']+'\x20('+_0x28f428['roleType']+')'};}};function a156_0x2b90(){const _0x3e6c96=['1521066eIRhfv','3071496CShHGs','Show\x20a\x20single\x20role\x27s\x20detail','6585411FFYezT','13095096xxTVkW','Role\x20','30ERhRPh','num','643132oxrUjy','178896zGaxdp','detail','4vliNkw','role','28037421EdcqRA'];a156_0x2b90=function(){return _0x3e6c96;};return a156_0x2b90();}
1
+ const a156_0x5be79a=a156_0xc58b;(function(_0x5b4f2a,_0x2f31f9){const _0x13fa7b=a156_0xc58b,_0x38047f=_0x5b4f2a();while(!![]){try{const _0x17e876=parseInt(_0x13fa7b(0x8c))/0x1+-parseInt(_0x13fa7b(0x8e))/0x2+parseInt(_0x13fa7b(0x8d))/0x3+parseInt(_0x13fa7b(0x8f))/0x4+-parseInt(_0x13fa7b(0x90))/0x5*(-parseInt(_0x13fa7b(0x83))/0x6)+-parseInt(_0x13fa7b(0x86))/0x7*(-parseInt(_0x13fa7b(0x84))/0x8)+-parseInt(_0x13fa7b(0x8a))/0x9*(parseInt(_0x13fa7b(0x89))/0xa);if(_0x17e876===_0x2f31f9)break;else _0x38047f['push'](_0x38047f['shift']());}catch(_0x2c79c2){_0x38047f['push'](_0x38047f['shift']());}}}(a156_0x281e,0xd53b2));import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function a156_0xc58b(_0x4fe355,_0x57dd80){_0x4fe355=_0x4fe355-0x82;const _0x281ec9=a156_0x281e();let _0xc58b9c=_0x281ec9[_0x4fe355];return _0xc58b9c;}function a156_0x281e(){const _0x506145=['9cXtAOM','detail','1485563guEOtW','3083604rRlVvj','1565806lvSnhr','806332lvCNMS','50aUdLjc','read','roleName','478938bheFTZ','104Lnpzar','role','62146gvZQmP','Role\x20','Show\x20a\x20single\x20role\x27s\x20detail','19723610qIiBla'];a156_0x281e=function(){return _0x506145;};return a156_0x281e();}import{getRoleById,projectRole,ROLE_ID_FLAG}from'../../commands/role/shared.js';export const roleDetail={'service':a156_0x5be79a(0x85),'command':a156_0x5be79a(0x8b),'description':a156_0x5be79a(0x88),'risk':a156_0x5be79a(0x91),'flags':[ROLE_ID_FLAG,APPCODE_FLAG_OPTIONAL],async 'execute'(_0x407454){const _0x296168=a156_0x5be79a,_0x4b535a=_0x407454['num']('id'),_0x279c75=await getRoleById(_0x407454['appCode'],_0x4b535a);return{'ok':!![],'data':{'role':projectRole(_0x279c75)},'message':_0x296168(0x87)+_0x279c75[_0x296168(0x82)]+'\x20('+_0x279c75['roleType']+')'};}};
@@ -1 +1 @@
1
- (function(_0x5f31dc,_0x462621){const _0xe24d4b=a157_0x46cb,_0x538504=_0x5f31dc();while(!![]){try{const _0x193c95=parseInt(_0xe24d4b(0xef))/0x1+-parseInt(_0xe24d4b(0xee))/0x2*(-parseInt(_0xe24d4b(0xeb))/0x3)+-parseInt(_0xe24d4b(0xe8))/0x4+-parseInt(_0xe24d4b(0xec))/0x5*(parseInt(_0xe24d4b(0xf1))/0x6)+parseInt(_0xe24d4b(0xed))/0x7+-parseInt(_0xe24d4b(0xe9))/0x8*(-parseInt(_0xe24d4b(0xf0))/0x9)+-parseInt(_0xe24d4b(0xea))/0xa;if(_0x193c95===_0x462621)break;else _0x538504['push'](_0x538504['shift']());}catch(_0x2b1fc0){_0x538504['push'](_0x538504['shift']());}}}(a157_0x2299,0x63366));import{roleList}from'../../commands/role/list.js';import{roleDetail}from'../../commands/role/detail.js';import{roleCreate}from'../../commands/role/create.js';import{roleUpdate}from'../../commands/role/update.js';import{roleDelete}from'../../commands/role/delete.js';import{roleUserResolve}from'../../commands/role/user-resolve.js';import{roleUserAdd}from'../../commands/role/user-add.js';import{roleUserRemove}from'../../commands/role/user-remove.js';export const roleDefinitions=[roleList,roleDetail,roleCreate,roleUpdate,roleDelete,roleUserResolve,roleUserAdd,roleUserRemove];function a157_0x46cb(_0x4abbb3,_0x3ec35f){_0x4abbb3=_0x4abbb3-0xe8;const _0x2299f7=a157_0x2299();let _0x46cb86=_0x2299f7[_0x4abbb3];return _0x46cb86;}function a157_0x2299(){const _0x46e8b2=['2dgKUtq','627269yhRtOT','9Orzibf','1274874NjdgtY','290280zMAPaS','497144QKJJKT','7208530BpVqiJ','699186MKzBXf','10omqDtn','4915967bYgigu'];a157_0x2299=function(){return _0x46e8b2;};return a157_0x2299();}
1
+ function a157_0x1496(){const _0x149ef6=['2788auqgxv','20qRpxhW','1245902tSfKdv','304290BziQbG','941wXQwAn','42oLMqXF','8435427lZFcrs','6441550cdpvda','31615qAsvsm','3992WeYcVe','9837wghbSO'];a157_0x1496=function(){return _0x149ef6;};return a157_0x1496();}function a157_0x30a2(_0x197ef0,_0x3212c0){_0x197ef0=_0x197ef0-0x185;const _0x149671=a157_0x1496();let _0x30a267=_0x149671[_0x197ef0];return _0x30a267;}(function(_0x23be9a,_0x2dc95c){const _0x4170e1=a157_0x30a2,_0xd73d35=_0x23be9a();while(!![]){try{const _0x33859c=-parseInt(_0x4170e1(0x18f))/0x1*(parseInt(_0x4170e1(0x18b))/0x2)+parseInt(_0x4170e1(0x18e))/0x3+-parseInt(_0x4170e1(0x18c))/0x4*(parseInt(_0x4170e1(0x188))/0x5)+-parseInt(_0x4170e1(0x185))/0x6*(-parseInt(_0x4170e1(0x18d))/0x7)+-parseInt(_0x4170e1(0x189))/0x8*(-parseInt(_0x4170e1(0x18a))/0x9)+-parseInt(_0x4170e1(0x187))/0xa+parseInt(_0x4170e1(0x186))/0xb;if(_0x33859c===_0x2dc95c)break;else _0xd73d35['push'](_0xd73d35['shift']());}catch(_0x518789){_0xd73d35['push'](_0xd73d35['shift']());}}}(a157_0x1496,0xa4148));import{roleList}from'../../commands/role/list.js';import{roleDetail}from'../../commands/role/detail.js';import{roleCreate}from'../../commands/role/create.js';import{roleUpdate}from'../../commands/role/update.js';import{roleDelete}from'../../commands/role/delete.js';import{roleUserResolve}from'../../commands/role/user-resolve.js';import{roleUserAdd}from'../../commands/role/user-add.js';import{roleUserRemove}from'../../commands/role/user-remove.js';export const roleDefinitions=[roleList,roleDetail,roleCreate,roleUpdate,roleDelete,roleUserResolve,roleUserAdd,roleUserRemove];
@@ -1 +1 @@
1
- function a158_0x1ad2(){const _0x4d089d=['Found\x20','pagesize','Invalid\x20--type\x20\x22','25zkSKqt','678792EPveyn','20hHyPHO','type','Use\x20one\x20of:\x20','num','toUpperCase','appCode','string','42RoRwwN','includes','4292100LMnUEM','Page\x20index\x20(1-based)','1404006cJBqIo','DEV','Filter\x20by\x20role\x20type','number','map','join','48630PrktXA','page','CUSTOM','read','filter','5792DZVpAt','List\x20user\x20groups\x20(roles)\x20for\x20the\x20current\x20app','290xdKdjr','validation','str','--pagesize\x20must\x20be\x20between\x201\x20and\x20100.','4941lUggbH','150931GGAmIn','USER','trim','387093MycGzX'];a158_0x1ad2=function(){return _0x4d089d;};return a158_0x1ad2();}function a158_0x3deb(_0x5cebf9,_0x3d392b){_0x5cebf9=_0x5cebf9-0x176;const _0x1ad20c=a158_0x1ad2();let _0x3deb19=_0x1ad20c[_0x5cebf9];return _0x3deb19;}const a158_0x4076a3=a158_0x3deb;(function(_0x1bfcf6,_0x222520){const _0x26dfbb=a158_0x3deb,_0x42c0c6=_0x1bfcf6();while(!![]){try{const _0x1c53f9=-parseInt(_0x26dfbb(0x19a))/0x1*(parseInt(_0x26dfbb(0x189))/0x2)+-parseInt(_0x26dfbb(0x194))/0x3+parseInt(_0x26dfbb(0x188))/0x4*(parseInt(_0x26dfbb(0x187))/0x5)+parseInt(_0x26dfbb(0x190))/0x6*(parseInt(_0x26dfbb(0x183))/0x7)+parseInt(_0x26dfbb(0x179))/0x8*(-parseInt(_0x26dfbb(0x17f))/0x9)+-parseInt(_0x26dfbb(0x17b))/0xa*(-parseInt(_0x26dfbb(0x180))/0xb)+parseInt(_0x26dfbb(0x192))/0xc;if(_0x1c53f9===_0x222520)break;else _0x42c0c6['push'](_0x42c0c6['shift']());}catch(_0x274baa){_0x42c0c6['push'](_0x42c0c6['shift']());}}}(a158_0x1ad2,0x9c19d));import{listAppRoles}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{projectRole}from'../../commands/role/shared.js';const ROLE_TYPES=['ADMIN',a158_0x4076a3(0x195),a158_0x4076a3(0x181),a158_0x4076a3(0x176)];export const roleList={'service':'role','command':'list','description':a158_0x4076a3(0x17a),'risk':a158_0x4076a3(0x177),'flags':[APPCODE_FLAG_OPTIONAL,{'name':'type','type':a158_0x4076a3(0x18f),'required':![],'description':a158_0x4076a3(0x196),'enum':ROLE_TYPES},{'name':a158_0x4076a3(0x19b),'type':a158_0x4076a3(0x197),'description':a158_0x4076a3(0x193),'default':0x1},{'name':a158_0x4076a3(0x185),'type':a158_0x4076a3(0x197),'description':'Page\x20size\x20(1-100)','default':0x64}],async 'validate'(_0x66759e){const _0x96c529=a158_0x4076a3,_0x276ece=_0x66759e[_0x96c529(0x17d)]('type')['trim']();if(_0x276ece&&!ROLE_TYPES[_0x96c529(0x191)](_0x276ece['toUpperCase']()))throw CliErrors[_0x96c529(0x17c)](_0x96c529(0x186)+_0x276ece+'\x22.',_0x96c529(0x18b)+ROLE_TYPES[_0x96c529(0x199)](',\x20')+'.');const _0x34c74a=_0x66759e[_0x96c529(0x18c)](_0x96c529(0x19b),0x1),_0x131263=_0x66759e[_0x96c529(0x18c)](_0x96c529(0x185),0x64);if(_0x34c74a<0x1)throw CliErrors[_0x96c529(0x17c)]('--page\x20must\x20be\x20greater\x20than\x20or\x20equal\x20to\x201.');if(_0x131263<0x1||_0x131263>0x64)throw CliErrors[_0x96c529(0x17c)](_0x96c529(0x17e));},async 'execute'(_0x38764a){const _0x3d67f1=a158_0x4076a3,_0x503dc5=_0x38764a[_0x3d67f1(0x18c)]('page',0x1)||0x1,_0x1fe4f7=_0x38764a[_0x3d67f1(0x18c)](_0x3d67f1(0x185),0x64)||0x64,_0x12833e=_0x38764a[_0x3d67f1(0x17d)](_0x3d67f1(0x18a))[_0x3d67f1(0x182)]()[_0x3d67f1(0x18d)](),{items:_0x5a0141,paging:_0xd2281}=await listAppRoles(_0x38764a[_0x3d67f1(0x18e)],{'currentPage':_0x503dc5,'pageSize':_0x1fe4f7}),_0x2da4d9=_0x12833e?_0x5a0141[_0x3d67f1(0x178)](_0x3044d8=>_0x3044d8['roleType']===_0x12833e):_0x5a0141,_0x1924bb=_0x2da4d9[_0x3d67f1(0x198)](projectRole);return{'ok':!![],'data':{'roles':_0x1924bb,'paging':_0xd2281},'message':_0x3d67f1(0x184)+_0x1924bb['length']+'\x20role(s)'};}};
1
+ const a158_0xd97405=a158_0x41d0;(function(_0x5aaf32,_0x37d22e){const _0x99f687=a158_0x41d0,_0x184964=_0x5aaf32();while(!![]){try{const _0x4d5e32=parseInt(_0x99f687(0x171))/0x1*(-parseInt(_0x99f687(0x152))/0x2)+-parseInt(_0x99f687(0x167))/0x3+parseInt(_0x99f687(0x170))/0x4*(-parseInt(_0x99f687(0x156))/0x5)+-parseInt(_0x99f687(0x15a))/0x6*(parseInt(_0x99f687(0x150))/0x7)+parseInt(_0x99f687(0x155))/0x8*(-parseInt(_0x99f687(0x173))/0x9)+parseInt(_0x99f687(0x16a))/0xa+parseInt(_0x99f687(0x15b))/0xb;if(_0x4d5e32===_0x37d22e)break;else _0x184964['push'](_0x184964['shift']());}catch(_0x2eed92){_0x184964['push'](_0x184964['shift']());}}}(a158_0x19d7,0x69b46));import{listAppRoles}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';function a158_0x19d7(){const _0x354df0=['Filter\x20by\x20role\x20type','Invalid\x20--type\x20\x22','str','includes','List\x20user\x20groups\x20(roles)\x20for\x20the\x20current\x20app','join','number','validation','2534523IrgbjX','USER','pagesize','3975470UNPGeG','trim','role','appCode','type','roleType','2154108ufudUU','2dHTWKM','list','7767NzjCoa','Found\x20','map','--page\x20must\x20be\x20greater\x20than\x20or\x20equal\x20to\x201.','DEV','\x20role(s)','num','7ySmtLb','Page\x20size\x20(1-100)','95286PIjPlM','Page\x20index\x20(1-based)','--pagesize\x20must\x20be\x20between\x201\x20and\x20100.','2848pgPyYX','5OcTeHD','CUSTOM','ADMIN','page','5096028zvNODO','29377029MiDBKX','toUpperCase','read','filter'];a158_0x19d7=function(){return _0x354df0;};return a158_0x19d7();}import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{projectRole}from'../../commands/role/shared.js';const ROLE_TYPES=[a158_0xd97405(0x158),a158_0xd97405(0x177),a158_0xd97405(0x168),a158_0xd97405(0x157)];function a158_0x41d0(_0x5dfb2b,_0x2312e9){_0x5dfb2b=_0x5dfb2b-0x14e;const _0x19d7c7=a158_0x19d7();let _0x41d0ec=_0x19d7c7[_0x5dfb2b];return _0x41d0ec;}export const roleList={'service':a158_0xd97405(0x16c),'command':a158_0xd97405(0x172),'description':a158_0xd97405(0x163),'risk':a158_0xd97405(0x15d),'flags':[APPCODE_FLAG_OPTIONAL,{'name':a158_0xd97405(0x16e),'type':'string','required':![],'description':a158_0xd97405(0x15f),'enum':ROLE_TYPES},{'name':a158_0xd97405(0x159),'type':a158_0xd97405(0x165),'description':a158_0xd97405(0x153),'default':0x1},{'name':a158_0xd97405(0x169),'type':a158_0xd97405(0x165),'description':a158_0xd97405(0x151),'default':0x64}],async 'validate'(_0x56e96f){const _0x309fc0=a158_0xd97405,_0x4492f2=_0x56e96f[_0x309fc0(0x161)](_0x309fc0(0x16e))[_0x309fc0(0x16b)]();if(_0x4492f2&&!ROLE_TYPES[_0x309fc0(0x162)](_0x4492f2[_0x309fc0(0x15c)]()))throw CliErrors['validation'](_0x309fc0(0x160)+_0x4492f2+'\x22.','Use\x20one\x20of:\x20'+ROLE_TYPES[_0x309fc0(0x164)](',\x20')+'.');const _0x3b6272=_0x56e96f['num']('page',0x1),_0x3215b4=_0x56e96f[_0x309fc0(0x14f)](_0x309fc0(0x169),0x64);if(_0x3b6272<0x1)throw CliErrors['validation'](_0x309fc0(0x176));if(_0x3215b4<0x1||_0x3215b4>0x64)throw CliErrors[_0x309fc0(0x166)](_0x309fc0(0x154));},async 'execute'(_0xab6533){const _0x1e15b1=a158_0xd97405,_0x9abe7d=_0xab6533[_0x1e15b1(0x14f)](_0x1e15b1(0x159),0x1)||0x1,_0x5f4611=_0xab6533[_0x1e15b1(0x14f)](_0x1e15b1(0x169),0x64)||0x64,_0xa05177=_0xab6533[_0x1e15b1(0x161)](_0x1e15b1(0x16e))['trim']()[_0x1e15b1(0x15c)](),{items:_0x13c06e,paging:_0x5da0ab}=await listAppRoles(_0xab6533[_0x1e15b1(0x16d)],{'currentPage':_0x9abe7d,'pageSize':_0x5f4611}),_0x1f3123=_0xa05177?_0x13c06e[_0x1e15b1(0x15e)](_0x96ee38=>_0x96ee38[_0x1e15b1(0x16f)]===_0xa05177):_0x13c06e,_0x21259a=_0x1f3123[_0x1e15b1(0x175)](projectRole);return{'ok':!![],'data':{'roles':_0x21259a,'paging':_0x5da0ab},'message':_0x1e15b1(0x174)+_0x21259a['length']+_0x1e15b1(0x14e)};}};