@lovrabet/rabetbase-cli 2.0.12 → 2.1.1-beta.0

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 (155) hide show
  1. package/README.md +2 -2
  2. package/lib/api/api-doc.js +1 -1
  3. package/lib/api/fetch-model-list.js +1 -1
  4. package/lib/api/generate-api-file.js +1 -1
  5. package/lib/auth/auth-server-ui.js +1 -1
  6. package/lib/auth/auth-server.js +1 -1
  7. package/lib/auth/constant.js +1 -1
  8. package/lib/auth/get-cookie.js +1 -1
  9. package/lib/auth/get-session-user.js +1 -1
  10. package/lib/auth/is-session-valid.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/doc.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.js +1 -1
  23. package/lib/commands/app/remove.js +1 -1
  24. package/lib/commands/app/shared.js +1 -1
  25. package/lib/commands/app/use.js +1 -1
  26. package/lib/commands/auth/index.js +1 -1
  27. package/lib/commands/bff/delete.js +1 -1
  28. package/lib/commands/bff/detail.js +1 -1
  29. package/lib/commands/bff/index.js +1 -1
  30. package/lib/commands/bff/list.js +1 -1
  31. package/lib/commands/bff/new.js +1 -1
  32. package/lib/commands/bff/pull.js +1 -1
  33. package/lib/commands/bff/push.js +1 -1
  34. package/lib/commands/bff/status.js +1 -1
  35. package/lib/commands/cli-update.js +1 -1
  36. package/lib/commands/codegen/index.js +1 -1
  37. package/lib/commands/codegen/sdk.js +1 -1
  38. package/lib/commands/codegen/sql.js +1 -1
  39. package/lib/commands/common/app-selector.js +1 -1
  40. package/lib/commands/common/flags.js +1 -1
  41. package/lib/commands/common/validate.js +1 -1
  42. package/lib/commands/config/get.js +1 -1
  43. package/lib/commands/config/index.js +1 -1
  44. package/lib/commands/config/list.js +1 -1
  45. package/lib/commands/config/set.js +1 -1
  46. package/lib/commands/config/shared.js +1 -1
  47. package/lib/commands/dataset/detail.js +1 -1
  48. package/lib/commands/dataset/index.js +1 -1
  49. package/lib/commands/dataset/links.js +1 -1
  50. package/lib/commands/dataset/list.js +1 -1
  51. package/lib/commands/dataset/operations.js +1 -1
  52. package/lib/commands/db/analyze-cancel.js +1 -0
  53. package/lib/commands/db/analyze-start.js +1 -0
  54. package/lib/commands/db/analyze-status.js +1 -0
  55. package/lib/commands/db/create.js +1 -0
  56. package/lib/commands/db/delete.js +1 -0
  57. package/lib/commands/db/detail.js +1 -0
  58. package/lib/commands/db/diff.js +1 -0
  59. package/lib/commands/db/index.js +1 -0
  60. package/lib/commands/db/list.js +1 -0
  61. package/lib/commands/db/shared.js +1 -0
  62. package/lib/commands/db/tables.js +1 -0
  63. package/lib/commands/db/test.js +1 -0
  64. package/lib/commands/db/update.js +1 -0
  65. package/lib/commands/doctor.js +1 -1
  66. package/lib/commands/init/index.js +1 -1
  67. package/lib/commands/logs/index.js +1 -1
  68. package/lib/commands/menu/index.js +1 -1
  69. package/lib/commands/menu/shared/compare-table.js +1 -1
  70. package/lib/commands/menu/shared/index.js +1 -1
  71. package/lib/commands/menu/shared/inquirer.js +1 -1
  72. package/lib/commands/menu/shared/local-pages.js +1 -1
  73. package/lib/commands/menu/shared/logic.js +1 -1
  74. package/lib/commands/menu/shared/service.js +1 -1
  75. package/lib/commands/menu/shared/sync-core.js +1 -1
  76. package/lib/commands/menu/shared/update-core.js +1 -1
  77. package/lib/commands/menu/shared/valid-url.js +1 -1
  78. package/lib/commands/menu/sync.js +1 -1
  79. package/lib/commands/menu/update.js +1 -1
  80. package/lib/commands/project/create/enhanced-guided-create.js +1 -1
  81. package/lib/commands/project/create/format-elapsed.js +1 -1
  82. package/lib/commands/project/create/main.js +1 -1
  83. package/lib/commands/project/create/non-interactive.js +1 -1
  84. package/lib/commands/project/create/project-template-path.js +1 -1
  85. package/lib/commands/project/create/use-copy-project-template.js +1 -1
  86. package/lib/commands/project/create/use-format-code.js +1 -1
  87. package/lib/commands/project/create/use-install-dependencies.js +1 -1
  88. package/lib/commands/project/index.js +1 -1
  89. package/lib/commands/project/init.js +1 -1
  90. package/lib/commands/project/upgrade.js +1 -1
  91. package/lib/commands/registry.js +1 -1
  92. package/lib/commands/run/index.js +1 -1
  93. package/lib/commands/schema.js +1 -1
  94. package/lib/commands/skill/index.js +1 -1
  95. package/lib/commands/sql/detail.js +1 -1
  96. package/lib/commands/sql/exec.js +1 -1
  97. package/lib/commands/sql/index.js +1 -1
  98. package/lib/commands/sql/list.js +1 -1
  99. package/lib/commands/sql/pull.js +1 -0
  100. package/lib/commands/sql/save.js +1 -1
  101. package/lib/commands/sql/shared.js +1 -0
  102. package/lib/commands/sql/validate.js +1 -1
  103. package/lib/constant/cli.js +1 -1
  104. package/lib/constant/domain.js +1 -1
  105. package/lib/constant/env.js +1 -1
  106. package/lib/constant/paths.js +1 -1
  107. package/lib/context.js +1 -1
  108. package/lib/core/alias-resolver.js +1 -1
  109. package/lib/core/api-client.js +1 -1
  110. package/lib/core/bff/config.js +1 -1
  111. package/lib/core/bff/file-system.js +1 -1
  112. package/lib/core/bff/hash.js +1 -1
  113. package/lib/core/bff/lock.js +1 -1
  114. package/lib/core/bff/utils.js +1 -1
  115. package/lib/core/db-resolver.js +1 -1
  116. package/lib/core/sql-validator.js +1 -1
  117. package/lib/errors.js +1 -1
  118. package/lib/framework/build-all-flags.js +1 -1
  119. package/lib/framework/flags.js +1 -1
  120. package/lib/framework/help.js +1 -1
  121. package/lib/framework/index.js +1 -1
  122. package/lib/framework/output.js +1 -1
  123. package/lib/framework/response.js +1 -1
  124. package/lib/framework/runner.js +1 -1
  125. package/lib/framework/schema-export.js +1 -1
  126. package/lib/framework/types.js +1 -1
  127. package/lib/generated/build-info.js +1 -1
  128. package/lib/help.js +1 -1
  129. package/lib/skills/main.js +1 -1
  130. package/lib/skills/npx-skills-add.js +1 -1
  131. package/lib/telemetry/cli-command-trace.js +1 -1
  132. package/lib/telemetry/cli-help-trace.js +1 -1
  133. package/lib/telemetry/ensure-cli-otel-config.js +1 -1
  134. package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
  135. package/lib/telemetry/send-cli-trace-log.js +1 -1
  136. package/lib/utils/ai_config.js +1 -1
  137. package/lib/utils/apply-jq-filter.js +1 -1
  138. package/lib/utils/cdn-config.js +1 -1
  139. package/lib/utils/check-sdk-version.js +1 -1
  140. package/lib/utils/cli-version-check.js +1 -1
  141. package/lib/utils/config.js +1 -1
  142. package/lib/utils/copy-directory.js +1 -1
  143. package/lib/utils/file-utils.js +1 -1
  144. package/lib/utils/guides-cdn.js +1 -1
  145. package/lib/utils/http-client.js +1 -1
  146. package/lib/utils/is-non-interactive.js +1 -1
  147. package/lib/utils/logger.js +1 -1
  148. package/lib/utils/platform.js +1 -1
  149. package/lib/utils/rules-cdn.js +1 -1
  150. package/lib/utils/sleep.js +1 -1
  151. package/lib/utils/template-replacer.js +1 -1
  152. package/lib/utils/version.js +1 -1
  153. package/lib/utils/with-active-cookie.js +1 -1
  154. package/lib/utils/write-cli-side-channel.js +1 -0
  155. package/package.json +1 -1
@@ -1 +1 @@
1
- const a76_0x582cc5=a76_0x248b;(function(_0x4991e8,_0x4226e0){const _0x56872c=a76_0x248b,_0x2e995b=_0x4991e8();while(!![]){try{const _0x378c71=-parseInt(_0x56872c(0x161))/0x1+-parseInt(_0x56872c(0x130))/0x2+-parseInt(_0x56872c(0xfe))/0x3+-parseInt(_0x56872c(0x115))/0x4+parseInt(_0x56872c(0x14f))/0x5*(-parseInt(_0x56872c(0x160))/0x6)+parseInt(_0x56872c(0x151))/0x7+parseInt(_0x56872c(0x13b))/0x8;if(_0x378c71===_0x4226e0)break;else _0x2e995b['push'](_0x2e995b['shift']());}catch(_0x5ad07b){_0x2e995b['push'](_0x2e995b['shift']());}}}(a76_0xe49f,0x9ea64));import a76_0x2c3306 from'chalk';import a76_0x2c8cc8 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{runNpxSkillsAddGlobal,runNpxSkillsRemove}from'../../skills/npx-skills-add.js';import{askConfirm}from'../../commands/menu/shared/inquirer.js';function a76_0xe49f(){const _0xdcd5ac=['fields','no\x20legacy\x20config\x20found','needsSkillSwap','done','filter','latest','Upgrade\x20@lovrabet/sdk','path','Step\x205/7:\x20Removing\x20old\x20skill...','Remove\x20old\x20skill','Step\x204/7:\x20Cleaning\x20MCP\x20config...','sdkUpgrade','4989006rBfizn','302775XbIToE','yellow','string','mcpServers','Config\x20migration','bold','files','Step\x202/7:\x20.lovrabet/\x20directory\x20removed','not\x20found\x20or\x20already\x20at\x20latest','status','join','No\x20legacy\x20artifacts\x20found.\x20Your\x20project\x20is\x20already\x20up-to-date.','\x20\x20Step\x20','\x20\x20Action:\x20migrate\x20→\x20backup\x20old\x20as\x20.bak','exit\x20','Step\x202/7:\x20.lovrabet/\x20removal\x20failed\x20—\x20','no\x20matching\x20entry\x20found','Step\x206/7:\x20Install\x20new\x20skill\x20—\x20','\x20\x20\x20\x20\x20\x20\x20','\x20\x20Action:\x20remove\x20entries\x20containing\x20@lovrabet/dataset-mcp-server','no\x20legacy\x20entry','Install\x20new\x20skill','@lovrabet/dataset-mcp-server','detail','configMigration','CANCEL','\x20\x20Action:\x20update\x20package.json\x20(you\x20will\x20need\x20to\x20re-run\x20install)','lovrabet/lovrabet-skill\x20removed','\x20(backup:\x20','.claude/skills/lovrabet','gray','some','succeed','875799ZJbjLi','utf8','\x20\x20Fields\x20to\x20migrate:\x20','fail','not\x20found\x20(will\x20create)','Step\x204/7:\x20MCP\x20config\x20—\x20','@lovrabet/sdk\x20has\x20been\x20updated\x20to\x20latest\x20in\x20package.json.','yes','Step\x207/7:\x20@lovrabet/sdk\x20—\x20','cyan','@lovrabet/sdk:','args','\x20\x20bun\x20install','\x20→\x20latest','needed','\x20\x20npm\x20install','Step\x201/7:\x20Config\x20migration\x20—\x20','package.json','Some\x20steps\x20failed.\x20Check\x20the\x20summary\x20above\x20for\x20details.','isDirectory','already\x20exists\x20(will\x20merge)','Skill\x20swap:','label','4714128vDhzHM','red','===\x20Upgrade\x20Analysis\x20===','Step\x206/7:\x20Installing\x20new\x20skill...','Remove\x20legacy\x20artifacts','push','Step\x203/7:\x20Legacy\x20artifacts\x20—\x20','green','skipped\x20(no\x20legacy\x20config)','MCP\x20config:','\x20from\x20','dependencies','\x20\x20#\x20or','\x20→\x20keys:\x20','stringify','log','Config\x20file:','values','length','isArray','parse','step','includes','failed','.bak','Proceed\x20with\x20upgrade?','devDependencies','1330252LdZBRr','Upgrade\x20cancelled.','Step\x202/7:\x20.lovrabet/\x20not\x20found,\x20skipped','oldPath','keys','entries','Legacy\x20artifacts:','FAIL','Step\x202/7:\x20Removing\x20.lovrabet/\x20directory...','\x20\x20Action:\x20remove\x20old\x20lovrabet/lovrabet-skill,\x20add\x20lovrabet/rabetbase\x20--global','hasNewConfig','25458112qLSmeD','skipped','lovrabet/rabetbase','not\x20needed','removed\x20','inherit','Remove\x20.lovrabet/','\x20→\x20','.lovrabet','.cursor/mcp.json','message','Step\x201/7:\x20Migrating\x20config...','\x20\x20New\x20config\x20(.rabetbase.json):\x20','skipped\x20(not\x20found\x20or\x20already\x20at\x20latest)','white','Clean\x20MCP\x20config','start','\x20removed\x20(','Step\x207/7:\x20Upgrading\x20@lovrabet/sdk\x20in\x20package.json...','object','5vmpBIe','Upgrade\x20completed\x20successfully!','5162017uqATDo','@lovrabet/sdk','oldMcpConfig'];a76_0xe49f=function(){return _0xdcd5ac;};return a76_0xe49f();}const LEGACY_CONFIG_NAMES=CONFIG_NAMES[a76_0x582cc5(0x158)](_0x15a5f5=>_0x15a5f5!==NEW_CONFIG_NAME);function collectIdeSkillFiles(_0x4267b9){const _0x4d58c9=a76_0x582cc5,_0x4b1467=[];for(const _0x282f5c of Object[_0x4d58c9(0x126)](CORE_IDE_CONFIGS)){if(_0x282f5c[_0x4d58c9(0xe3)])for(const _0x4bbb8b of _0x282f5c[_0x4d58c9(0xe3)]){_0x4b1467[_0x4d58c9(0x11a)](resolve(_0x4267b9,_0x4bbb8b[_0x4d58c9(0x15b)]));}}return _0x4b1467;}function analyse(_0x5b53cf){const _0xd26cd5=a76_0x582cc5;let _0x4f5714=null;const _0x1e999d=resolve(_0x5b53cf,NEW_CONFIG_NAME),_0x234778=existsSync(_0x1e999d);for(const _0x138069 of LEGACY_CONFIG_NAMES){const _0x4b1e47=resolve(_0x5b53cf,_0x138069);if(existsSync(_0x4b1e47)){const _0x41c8e5=readConfigFile(_0x4b1e47),_0x12bc3f=Object['keys'](_0x41c8e5)['filter'](_0x4396f0=>typeof _0x41c8e5[_0x4396f0]!=='undefined');_0x4f5714={'oldPath':_0x4b1e47,'hasNewConfig':_0x234778,'fields':_0x12bc3f};break;}}const _0x3dc45d=[],_0x5c22c4=resolve(_0x5b53cf,_0xd26cd5(0x143));if(existsSync(_0x5c22c4))_0x3dc45d[_0xd26cd5(0x11a)](_0x5c22c4);const _0x529888=resolve(_0x5b53cf,'.cursor/rules/lovrabet_rules.mdc');if(existsSync(_0x529888))_0x3dc45d['push'](_0x529888);const _0x443583=resolve(_0x5b53cf,_0xd26cd5(0xfa));if(existsSync(_0x443583))_0x3dc45d[_0xd26cd5(0x11a)](_0x443583);for(const _0x5e3229 of collectIdeSkillFiles(_0x5b53cf)){if(existsSync(_0x5e3229))_0x3dc45d[_0xd26cd5(0x11a)](_0x5e3229);}let _0x3d7f2b=null;const _0x2c3511=resolve(_0x5b53cf,_0xd26cd5(0x144));if(existsSync(_0x2c3511))try{const _0x93f4a3=JSON[_0xd26cd5(0x129)](readFileSync(_0x2c3511,'utf8'));if(_0x93f4a3?.['mcpServers']&&typeof _0x93f4a3[_0xd26cd5(0xe0)]===_0xd26cd5(0x14e)){const _0x1424f3=[];for(const [_0x4a81bd,_0x588879]of Object[_0xd26cd5(0x135)](_0x93f4a3['mcpServers'])){const _0x14d3c7=_0x588879;_0x14d3c7?.['args']&&Array[_0xd26cd5(0x128)](_0x14d3c7['args'])&&_0x14d3c7[_0xd26cd5(0x109)][_0xd26cd5(0xfc)](_0x537c3f=>typeof _0x537c3f===_0xd26cd5(0x163)&&_0x537c3f[_0xd26cd5(0x12b)]('@lovrabet/dataset-mcp-server'))&&_0x1424f3[_0xd26cd5(0x11a)](_0x4a81bd);}_0x1424f3[_0xd26cd5(0x127)]>0x0&&(_0x3d7f2b={'path':_0x2c3511,'keys':_0x1424f3});}}catch{}const _0x461f77=_0x3dc45d['length']>0x0||_0x4f5714!==null;let _0x28ef89=null;const _0x529ee6=resolve(_0x5b53cf,_0xd26cd5(0x10f));if(existsSync(_0x529ee6))try{const _0x21b02d=JSON[_0xd26cd5(0x129)](readFileSync(_0x529ee6,_0xd26cd5(0xff)));for(const _0x580404 of[_0xd26cd5(0x120),_0xd26cd5(0x12f)]){const _0x4867d7=_0x21b02d?.[_0x580404]?.[_0xd26cd5(0x152)];if(typeof _0x4867d7==='string'){_0x4867d7!==_0xd26cd5(0x159)&&(_0x28ef89={'pkgPath':_0x529ee6,'currentVersion':_0x4867d7,'field':_0x580404});break;}}}catch{}return{'configMigration':_0x4f5714,'oldArtifacts':_0x3dc45d,'oldMcpConfig':_0x3d7f2b,'needsSkillSwap':_0x461f77,'sdkUpgrade':_0x28ef89};}function printReport(_0xfd1fd1){const _0x52bd9f=a76_0x582cc5,{configMigration:_0x1624cb,oldArtifacts:_0x320a60,oldMcpConfig:_0x1cced1,needsSkillSwap:_0x46ebc3}=_0xfd1fd1;console[_0x52bd9f(0x124)](''),console[_0x52bd9f(0x124)](a76_0x2c3306[_0x52bd9f(0xe2)](_0x52bd9f(0x117))),console[_0x52bd9f(0x124)]('');_0x1624cb?(console[_0x52bd9f(0x124)](a76_0x2c3306['cyan'](_0x52bd9f(0x125))+('\x20\x20'+a76_0x2c3306[_0x52bd9f(0x162)](_0x1624cb[_0x52bd9f(0x133)]))),console['log'](_0x52bd9f(0x147)+(_0x1624cb[_0x52bd9f(0x13a)]?a76_0x2c3306[_0x52bd9f(0x11c)](_0x52bd9f(0x112)):a76_0x2c3306['gray'](_0x52bd9f(0x102)))),console[_0x52bd9f(0x124)](_0x52bd9f(0x100)+_0x1624cb[_0x52bd9f(0x154)][_0x52bd9f(0xe7)](',\x20')),console[_0x52bd9f(0x124)](_0x52bd9f(0xea))):console[_0x52bd9f(0x124)](a76_0x2c3306[_0x52bd9f(0x107)]('Config\x20file:')+'\x20\x20'+a76_0x2c3306[_0x52bd9f(0xfb)](_0x52bd9f(0x155)));console['log']('');if(_0x320a60[_0x52bd9f(0x127)]>0x0){console['log'](a76_0x2c3306[_0x52bd9f(0x107)](_0x52bd9f(0x136)));for(const _0x2a3b9f of _0x320a60){console['log']('\x20\x20'+a76_0x2c3306['red']('FOUND')+'\x20\x20'+_0x2a3b9f);}console[_0x52bd9f(0x124)]('\x20\x20Action:\x20delete');}else console[_0x52bd9f(0x124)](a76_0x2c3306[_0x52bd9f(0x107)]('Legacy\x20artifacts:')+'\x20\x20'+a76_0x2c3306[_0x52bd9f(0xfb)]('none\x20found'));console[_0x52bd9f(0x124)]('');_0x1cced1?(console[_0x52bd9f(0x124)](a76_0x2c3306[_0x52bd9f(0x107)](_0x52bd9f(0x11e))+('\x20\x20'+a76_0x2c3306['yellow'](_0x1cced1[_0x52bd9f(0x15b)])+_0x52bd9f(0x122)+_0x1cced1[_0x52bd9f(0x134)][_0x52bd9f(0xe7)](',\x20'))),console[_0x52bd9f(0x124)](_0x52bd9f(0xf0))):console['log'](a76_0x2c3306[_0x52bd9f(0x107)]('MCP\x20config:')+'\x20\x20'+a76_0x2c3306[_0x52bd9f(0xfb)](_0x52bd9f(0xf1)));console[_0x52bd9f(0x124)](''),console['log'](a76_0x2c3306[_0x52bd9f(0x107)](_0x52bd9f(0x113))+('\x20\x20'+(_0x46ebc3?a76_0x2c3306[_0x52bd9f(0x162)](_0x52bd9f(0x10c)):a76_0x2c3306[_0x52bd9f(0x11c)](_0x52bd9f(0x13e)))));_0x46ebc3&&console['log'](_0x52bd9f(0x139));console[_0x52bd9f(0x124)]('');if(_0xfd1fd1[_0x52bd9f(0x15f)]){const {currentVersion:_0x33f639,field:_0x72c344,pkgPath:_0x18038e}=_0xfd1fd1[_0x52bd9f(0x15f)];console[_0x52bd9f(0x124)](a76_0x2c3306['cyan'](_0x52bd9f(0x108))+('\x20\x20'+a76_0x2c3306[_0x52bd9f(0x162)](_0x18038e))),console[_0x52bd9f(0x124)]('\x20\x20Current\x20version\x20in\x20'+_0x72c344+':\x20'+a76_0x2c3306['yellow'](_0x33f639)+_0x52bd9f(0x142)+a76_0x2c3306['green']('latest')),console[_0x52bd9f(0x124)](_0x52bd9f(0xf7));}else console[_0x52bd9f(0x124)](a76_0x2c3306['cyan']('@lovrabet/sdk:')+'\x20\x20'+a76_0x2c3306[_0x52bd9f(0xfb)](_0x52bd9f(0xe5)));console[_0x52bd9f(0x124)]('');}function a76_0x248b(_0x2d4bd0,_0x35bfd0){_0x2d4bd0=_0x2d4bd0-0xe0;const _0xe49f37=a76_0xe49f();let _0x248b53=_0xe49f37[_0x2d4bd0];return _0x248b53;}function execConfigMigration(_0x5a5f15,_0x5a04da){const _0x12399c=a76_0x582cc5,{configMigration:_0x8d89f4}=_0x5a5f15;if(!_0x8d89f4?.[_0x12399c(0x133)])return{'step':0x1,'label':_0x12399c(0xe1),'ok':!![],'detail':_0x12399c(0x11d)};const _0x2a4c86=readConfigFile(_0x8d89f4[_0x12399c(0x133)]),_0x4e6c78=resolve(_0x5a04da,NEW_CONFIG_NAME),_0x5d498e=_0x8d89f4[_0x12399c(0x13a)]?readConfigFile(_0x4e6c78):{};for(const [_0x2e6723,_0x5e61cf]of Object[_0x12399c(0x135)](_0x2a4c86)){!(_0x2e6723 in _0x5d498e)&&(_0x5d498e[_0x2e6723]=_0x5e61cf);}writeConfigFile(_0x4e6c78,_0x5d498e);const _0x256710=_0x8d89f4[_0x12399c(0x133)]+_0x12399c(0x12d);return renameSync(_0x8d89f4[_0x12399c(0x133)],_0x256710),{'step':0x1,'label':_0x12399c(0xe1),'ok':!![],'detail':_0x8d89f4[_0x12399c(0x133)]+_0x12399c(0x142)+_0x4e6c78+_0x12399c(0xf9)+_0x256710+')'};}function execRemoveOldArtifacts(_0x518e69){const _0x45a254=a76_0x582cc5,_0x4d25f6=[];for(const _0x44a740 of _0x518e69){try{if(!existsSync(_0x44a740))continue;const _0x156866=tryStat(_0x44a740);_0x156866?.[_0x45a254(0x111)]()?rmSync(_0x44a740,{'recursive':!![],'force':!![]}):unlinkSync(_0x44a740);}catch(_0x145316){_0x4d25f6[_0x45a254(0x11a)](_0x44a740+':\x20'+_0x145316[_0x45a254(0x145)]);}}return{'step':0x3,'label':_0x45a254(0x119),'ok':_0x4d25f6[_0x45a254(0x127)]===0x0,'detail':_0x4d25f6[_0x45a254(0x127)]>0x0?_0x518e69[_0x45a254(0x127)]-_0x4d25f6['length']+'/'+_0x518e69[_0x45a254(0x127)]+_0x45a254(0x14c)+_0x4d25f6[_0x45a254(0xe7)](';\x20')+')':_0x518e69[_0x45a254(0x127)]+'\x20removed'};}function execCleanMcp(_0x371b9a){const _0x10c674=a76_0x582cc5;if(!_0x371b9a[_0x10c674(0x153)])return{'step':0x4,'label':_0x10c674(0x14a),'ok':!![],'detail':_0x10c674(0x13c)};try{const _0x4ee38c=readFileSync(_0x371b9a[_0x10c674(0x153)][_0x10c674(0x15b)],_0x10c674(0xff)),_0x5beb3a=JSON[_0x10c674(0x129)](_0x4ee38c);if(_0x5beb3a?.['mcpServers']&&typeof _0x5beb3a[_0x10c674(0xe0)]===_0x10c674(0x14e)){const _0x36b804=[];for(const [_0x208be3,_0x12d185]of Object[_0x10c674(0x135)](_0x5beb3a[_0x10c674(0xe0)])){_0x12d185?.[_0x10c674(0x109)]&&Array[_0x10c674(0x128)](_0x12d185[_0x10c674(0x109)])&&_0x12d185[_0x10c674(0x109)]['some'](_0x125763=>typeof _0x125763==='string'&&_0x125763[_0x10c674(0x12b)](_0x10c674(0xf3)))&&_0x36b804['push'](_0x208be3);}for(const _0x34dba5 of _0x36b804){delete _0x5beb3a[_0x10c674(0xe0)][_0x34dba5];}return _0x36b804[_0x10c674(0x127)]>0x0&&writeFileSync(_0x371b9a[_0x10c674(0x153)][_0x10c674(0x15b)],JSON[_0x10c674(0x123)](_0x5beb3a,null,0x2)+'\x0a',_0x10c674(0xff)),{'step':0x4,'label':_0x10c674(0x14a),'ok':!![],'detail':_0x10c674(0x13f)+_0x36b804[_0x10c674(0xe7)](',\x20')+_0x10c674(0x11f)+_0x371b9a[_0x10c674(0x153)][_0x10c674(0x15b)]};}return{'step':0x4,'label':'Clean\x20MCP\x20config','ok':!![],'detail':_0x10c674(0xed)};}catch(_0x5d2f4e){return{'step':0x4,'label':_0x10c674(0x14a),'ok':![],'detail':_0x5d2f4e['message']};}}function execSkillsRemove(_0x3924bd,_0x4d89d6){const _0x73a2c1=a76_0x582cc5,_0x49e7b7=runNpxSkillsRemove(_0x3924bd,{'stdio':_0x73a2c1(0x140),'yes':_0x4d89d6});return{'step':0x5,'label':_0x73a2c1(0x15d),'ok':_0x49e7b7['ok'],'detail':_0x49e7b7['ok']?_0x73a2c1(0xf8):_0x49e7b7['error']??_0x73a2c1(0xeb)+_0x49e7b7[_0x73a2c1(0xe6)]};}function execSkillsAdd(_0x2a34d0,_0x2b52a2){const _0x2a496c=a76_0x582cc5,_0x465e0d=runNpxSkillsAddGlobal(_0x2a34d0,_0x2a496c(0x13d),{'stdio':_0x2a496c(0x140),'yes':_0x2b52a2});return{'step':0x6,'label':_0x2a496c(0xf2),'ok':_0x465e0d['ok'],'detail':_0x465e0d['ok']?'lovrabet/rabetbase\x20installed\x20globally':_0x465e0d['error']??_0x2a496c(0xeb)+_0x465e0d[_0x2a496c(0xe6)]};}function execUpgradeSdk(_0x350902){const _0x87a895=a76_0x582cc5;if(!_0x350902[_0x87a895(0x15f)])return{'step':0x7,'label':_0x87a895(0x15a),'ok':!![],'detail':_0x87a895(0x148)};const {pkgPath:_0x2f2032,currentVersion:_0x3a66db,field:_0x157141}=_0x350902[_0x87a895(0x15f)];try{const _0x38c50b=readFileSync(_0x2f2032,_0x87a895(0xff)),_0x45e23b=JSON['parse'](_0x38c50b);return _0x45e23b[_0x157141]['@lovrabet/sdk']=_0x87a895(0x159),writeFileSync(_0x2f2032,JSON[_0x87a895(0x123)](_0x45e23b,null,0x2)+'\x0a','utf8'),{'step':0x7,'label':_0x87a895(0x15a),'ok':!![],'detail':_0x157141+'[\x22@lovrabet/sdk\x22]:\x20'+_0x3a66db+_0x87a895(0x10b)};}catch(_0x5c70c0){return{'step':0x7,'label':_0x87a895(0x15a),'ok':![],'detail':_0x5c70c0[_0x87a895(0x145)]};}}function tryStat(_0x31b2e0){try{return statSync(_0x31b2e0);}catch{return undefined;}}function printSummary(_0x1ff093){const _0x15e364=a76_0x582cc5;console['log'](''),console[_0x15e364(0x124)](a76_0x2c3306[_0x15e364(0xe2)]('===\x20Upgrade\x20Summary\x20===')),console[_0x15e364(0x124)]('');for(const _0x9e7db0 of _0x1ff093){const _0x3cea0c=_0x9e7db0['ok']?a76_0x2c3306[_0x15e364(0x11c)]('OK'):a76_0x2c3306[_0x15e364(0x116)](_0x15e364(0x137));console['log']('\x20\x20'+_0x3cea0c+_0x15e364(0xe9)+_0x9e7db0[_0x15e364(0x12a)]+':\x20'+_0x9e7db0[_0x15e364(0x114)]);if(_0x9e7db0['detail'])console[_0x15e364(0x124)](_0x15e364(0xef)+a76_0x2c3306[_0x15e364(0xfb)](_0x9e7db0[_0x15e364(0xf4)]));}console[_0x15e364(0x124)]('');}export async function upgradeApp(_0x5d5631,_0x2001f7){const _0x2e7614=a76_0x582cc5,_0x1ccc12=process['cwd'](),_0x469271=analyse(_0x1ccc12),_0x4f1e02=!_0x469271[_0x2e7614(0xf5)]&&_0x469271['oldArtifacts'][_0x2e7614(0x127)]===0x0&&!_0x469271[_0x2e7614(0x153)]&&!_0x469271[_0x2e7614(0x156)]&&!_0x469271[_0x2e7614(0x15f)];if(_0x4f1e02){console[_0x2e7614(0x124)](a76_0x2c3306[_0x2e7614(0x11c)](_0x2e7614(0xe8)));return;}printReport(_0x469271);const _0x5b85ff=!!(_0x2001f7[_0x2e7614(0x105)]||_0x2001f7['Y']||_0x5d5631);if(!_0x5b85ff)try{const _0x37d9a1=await askConfirm(_0x2e7614(0x12e));if(!_0x37d9a1){console[_0x2e7614(0x124)](a76_0x2c3306[_0x2e7614(0xfb)](_0x2e7614(0x131)));return;}}catch(_0x521459){if(_0x521459?.['message']===_0x2e7614(0xf6)){console[_0x2e7614(0x124)](a76_0x2c3306[_0x2e7614(0xfb)]('Upgrade\x20cancelled.'));return;}throw _0x521459;}const _0x203971=[],_0x363bad=a76_0x2c8cc8({'text':_0x2e7614(0x146),'color':_0x2e7614(0x107)})[_0x2e7614(0x14b)](),_0x4a7bd6=execConfigMigration(_0x469271,_0x1ccc12);_0x203971[_0x2e7614(0x11a)](_0x4a7bd6),_0x363bad[_0x4a7bd6['ok']?_0x2e7614(0xfd):'fail'](_0x2e7614(0x10e)+(_0x4a7bd6['detail']??(_0x4a7bd6['ok']?_0x2e7614(0x157):_0x2e7614(0x12c))));const _0x8e8164=resolve(_0x1ccc12,_0x2e7614(0x143)),_0x27e044=a76_0x2c8cc8({'text':_0x2e7614(0x138),'color':'cyan'})[_0x2e7614(0x14b)]();if(existsSync(_0x8e8164))try{rmSync(_0x8e8164,{'recursive':!![],'force':!![]}),_0x27e044['succeed'](_0x2e7614(0xe4)),_0x203971[_0x2e7614(0x11a)]({'step':0x2,'label':_0x2e7614(0x141),'ok':!![]});}catch(_0x4126d9){_0x27e044[_0x2e7614(0x101)](_0x2e7614(0xec)+_0x4126d9[_0x2e7614(0x145)]),_0x203971[_0x2e7614(0x11a)]({'step':0x2,'label':_0x2e7614(0x141),'ok':![],'detail':_0x4126d9[_0x2e7614(0x145)]});}else _0x27e044['info'](_0x2e7614(0x132)),_0x203971[_0x2e7614(0x11a)]({'step':0x2,'label':_0x2e7614(0x141),'ok':!![],'detail':'skipped'});const _0xd69da2=a76_0x2c8cc8({'text':'Step\x203/7:\x20Removing\x20legacy\x20IDE\x20skill\x20files...','color':_0x2e7614(0x107)})[_0x2e7614(0x14b)](),_0x24ee12=execRemoveOldArtifacts(_0x469271['oldArtifacts']);_0x203971['push'](_0x24ee12),_0xd69da2[_0x24ee12['ok']?_0x2e7614(0xfd):_0x2e7614(0x101)](_0x2e7614(0x11b)+(_0x24ee12[_0x2e7614(0xf4)]??(_0x24ee12['ok']?_0x2e7614(0x157):'failed')));const _0x50bf61=a76_0x2c8cc8({'text':_0x2e7614(0x15e),'color':_0x2e7614(0x107)})[_0x2e7614(0x14b)](),_0x1332f5=execCleanMcp(_0x469271);_0x203971[_0x2e7614(0x11a)](_0x1332f5),_0x50bf61[_0x1332f5['ok']?'succeed':_0x2e7614(0x101)](_0x2e7614(0x103)+(_0x1332f5['detail']??(_0x1332f5['ok']?_0x2e7614(0x157):_0x2e7614(0x12c))));const _0x15350a=a76_0x2c8cc8({'text':_0x2e7614(0x15c),'color':_0x2e7614(0x107)})[_0x2e7614(0x14b)](),_0x3b6389=execSkillsRemove(_0x1ccc12,_0x5b85ff);_0x203971[_0x2e7614(0x11a)](_0x3b6389),_0x15350a[_0x3b6389['ok']?_0x2e7614(0xfd):_0x2e7614(0x101)]('Step\x205/7:\x20Remove\x20old\x20skill\x20—\x20'+(_0x3b6389[_0x2e7614(0xf4)]??(_0x3b6389['ok']?_0x2e7614(0x157):_0x2e7614(0x12c))));const _0x34daf7=a76_0x2c8cc8({'text':_0x2e7614(0x118),'color':_0x2e7614(0x107)})[_0x2e7614(0x14b)](),_0x15315c=execSkillsAdd(_0x1ccc12,_0x5b85ff);_0x203971[_0x2e7614(0x11a)](_0x15315c),_0x34daf7[_0x15315c['ok']?'succeed':_0x2e7614(0x101)](_0x2e7614(0xee)+(_0x15315c['detail']??(_0x15315c['ok']?'done':_0x2e7614(0x12c))));const _0x2a44a0=a76_0x2c8cc8({'text':_0x2e7614(0x14d),'color':_0x2e7614(0x107)})[_0x2e7614(0x14b)](),_0x4a25e6=execUpgradeSdk(_0x469271);_0x203971[_0x2e7614(0x11a)](_0x4a25e6),_0x2a44a0[_0x4a25e6['ok']?_0x2e7614(0xfd):_0x2e7614(0x101)](_0x2e7614(0x106)+(_0x4a25e6['detail']??(_0x4a25e6['ok']?_0x2e7614(0x157):_0x2e7614(0x12c)))),printSummary(_0x203971);const _0x333047=_0x203971[_0x2e7614(0xfc)](_0x22adda=>!_0x22adda['ok']);_0x333047?console[_0x2e7614(0x124)](a76_0x2c3306[_0x2e7614(0x162)](_0x2e7614(0x110))):console[_0x2e7614(0x124)](a76_0x2c3306[_0x2e7614(0x11c)](_0x2e7614(0x150))),_0x4a25e6['ok']&&_0x469271[_0x2e7614(0x15f)]&&(console[_0x2e7614(0x124)](''),console[_0x2e7614(0x124)](a76_0x2c3306[_0x2e7614(0xe2)][_0x2e7614(0x107)](_0x2e7614(0x104))),console['log'](a76_0x2c3306['cyan']('Please\x20re-install\x20dependencies\x20to\x20apply\x20the\x20change:')),console['log'](''),console[_0x2e7614(0x124)](a76_0x2c3306[_0x2e7614(0x149)](_0x2e7614(0x10d))),console['log'](a76_0x2c3306[_0x2e7614(0x149)](_0x2e7614(0x121))),console['log'](a76_0x2c3306[_0x2e7614(0x149)](_0x2e7614(0x10a))),console[_0x2e7614(0x124)](''));}
1
+ const a89_0x405555=a89_0x4afc;function a89_0xb673(){const _0x5814bc=['@lovrabet/sdk','done','oldArtifacts','needed','.claude/skills/lovrabet','object','configMigration','.cursor/mcp.json','3692433cbqHpA','sdkUpgrade','isArray','Step\x202/7:\x20Removing\x20.lovrabet/\x20directory...','.cursor/rules/lovrabet_rules.mdc','\x20→\x20','Step\x206/7:\x20Install\x20new\x20skill\x20—\x20','bold','103812fIDQzs','Install\x20new\x20skill','Step\x202/7:\x20.lovrabet/\x20not\x20found,\x20skipped','hasNewConfig','no\x20legacy\x20entry','@lovrabet/sdk\x20has\x20been\x20updated\x20to\x20latest\x20in\x20package.json.','\x20\x20#\x20or','Step\x207/7:\x20Upgrading\x20@lovrabet/sdk\x20in\x20package.json...','needsSkillSwap','log','Remove\x20.lovrabet/','54GawUXy','\x20\x20Action:\x20update\x20package.json\x20(you\x20will\x20need\x20to\x20re-run\x20install)','no\x20matching\x20entry\x20found','succeed','args','@lovrabet/dataset-mcp-server','Upgrade\x20@lovrabet/sdk','1138694ZFXbai','info','none\x20found','removed\x20','Legacy\x20artifacts:','2srIHHZ','filter','start','\x20removed','yellow','mcpServers','step','inherit','some','Clean\x20MCP\x20config','49EGRVOW','===\x20Upgrade\x20Analysis\x20===','package.json','oldMcpConfig','Config\x20file:','oldPath','no\x20legacy\x20config\x20found','dependencies','skipped\x20(not\x20found\x20or\x20already\x20at\x20latest)','length','devDependencies','string','failed','.lovrabet','status','red','Step\x202/7:\x20.lovrabet/\x20directory\x20removed','\x20\x20New\x20config\x20(.rabetbase.json):\x20','Skill\x20swap:','skipped','Step\x203/7:\x20Removing\x20legacy\x20IDE\x20skill\x20files...','lovrabet/rabetbase\x20installed\x20globally','953415WpoYrm','message','115730psgUoh','files','stringify','1352048lMmshz','===\x20Upgrade\x20Summary\x20===','white','FAIL','Step\x201/7:\x20Config\x20migration\x20—\x20','\x20\x20Action:\x20remove\x20entries\x20containing\x20@lovrabet/dataset-mcp-server','No\x20legacy\x20artifacts\x20found.\x20Your\x20project\x20is\x20already\x20up-to-date.','3679HnuxZg','fail','parse','FOUND','\x20from\x20','\x20→\x20latest','Some\x20steps\x20failed.\x20Check\x20the\x20summary\x20above\x20for\x20details.','cyan','20aYxuBV','error','detail','Remove\x20legacy\x20artifacts','Step\x202/7:\x20.lovrabet/\x20removal\x20failed\x20—\x20','\x20\x20Action:\x20remove\x20old\x20lovrabet/lovrabet-skill,\x20add\x20lovrabet/rabetbase\x20--global','undefined','label','913kNsQWK','\x20→\x20keys:\x20','not\x20found\x20(will\x20create)','green','Remove\x20old\x20skill','values','isDirectory','Upgrade\x20cancelled.','\x20\x20Current\x20version\x20in\x20','join','includes','gray','path','\x20\x20Step\x20','\x20\x20Fields\x20to\x20migrate:\x20','push','Config\x20migration','71562VOTGMo','already\x20exists\x20(will\x20merge)','Proceed\x20with\x20upgrade?','.bak','exit\x20','Step\x201/7:\x20Migrating\x20config...','lovrabet/lovrabet-skill\x20removed','fields','latest','MCP\x20config:','@lovrabet/sdk:','keys','Step\x205/7:\x20Remove\x20old\x20skill\x20—\x20','Step\x204/7:\x20MCP\x20config\x20—\x20','utf8','Step\x204/7:\x20Cleaning\x20MCP\x20config...'];a89_0xb673=function(){return _0x5814bc;};return a89_0xb673();}(function(_0x377f55,_0x5e2a4b){const _0x3362ae=a89_0x4afc,_0x76ca88=_0x377f55();while(!![]){try{const _0x12b30=-parseInt(_0x3362ae(0x116))/0x1+-parseInt(_0x3362ae(0x11b))/0x2*(-parseInt(_0x3362ae(0xfc))/0x3)+-parseInt(_0x3362ae(0xcb))/0x4*(-parseInt(_0x3362ae(0xb7))/0x5)+-parseInt(_0x3362ae(0xe4))/0x6*(-parseInt(_0x3362ae(0x125))/0x7)+parseInt(_0x3362ae(0xbc))/0x8*(parseInt(_0x3362ae(0x10f))/0x9)+-parseInt(_0x3362ae(0xb9))/0xa*(-parseInt(_0x3362ae(0xd3))/0xb)+parseInt(_0x3362ae(0x104))/0xc*(-parseInt(_0x3362ae(0xc3))/0xd);if(_0x12b30===_0x5e2a4b)break;else _0x76ca88['push'](_0x76ca88['shift']());}catch(_0x31f7b2){_0x76ca88['push'](_0x76ca88['shift']());}}}(a89_0xb673,0xa0017));import a89_0x14aceb from'chalk';import a89_0x3b7c78 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{runNpxSkillsAddGlobal,runNpxSkillsRemove}from'../../skills/npx-skills-add.js';import{askConfirm}from'../../commands/menu/shared/inquirer.js';const LEGACY_CONFIG_NAMES=CONFIG_NAMES[a89_0x405555(0x11c)](_0x4e892f=>_0x4e892f!==NEW_CONFIG_NAME);function collectIdeSkillFiles(_0x1f50e8){const _0x52d0fb=a89_0x405555,_0x5b5c0f=[];for(const _0x14ffa9 of Object[_0x52d0fb(0xd8)](CORE_IDE_CONFIGS)){if(_0x14ffa9[_0x52d0fb(0xba)])for(const _0x2cb299 of _0x14ffa9[_0x52d0fb(0xba)]){_0x5b5c0f[_0x52d0fb(0xe2)](resolve(_0x1f50e8,_0x2cb299[_0x52d0fb(0xdf)]));}}return _0x5b5c0f;}function analyse(_0x2bbfd0){const _0x70df11=a89_0x405555;let _0x4d93a0=null;const _0x3247f6=resolve(_0x2bbfd0,NEW_CONFIG_NAME),_0x2135f1=existsSync(_0x3247f6);for(const _0x240697 of LEGACY_CONFIG_NAMES){const _0x15ff63=resolve(_0x2bbfd0,_0x240697);if(existsSync(_0x15ff63)){const _0xdea422=readConfigFile(_0x15ff63),_0x607dd3=Object[_0x70df11(0xef)](_0xdea422)[_0x70df11(0x11c)](_0x245281=>typeof _0xdea422[_0x245281]!==_0x70df11(0xd1));_0x4d93a0={'oldPath':_0x15ff63,'hasNewConfig':_0x2135f1,'fields':_0x607dd3};break;}}const _0x237767=[],_0x21f5b0=resolve(_0x2bbfd0,_0x70df11(0xae));if(existsSync(_0x21f5b0))_0x237767['push'](_0x21f5b0);const _0x64e658=resolve(_0x2bbfd0,_0x70df11(0x100));if(existsSync(_0x64e658))_0x237767[_0x70df11(0xe2)](_0x64e658);const _0x123fbf=resolve(_0x2bbfd0,_0x70df11(0xf8));if(existsSync(_0x123fbf))_0x237767['push'](_0x123fbf);for(const _0xdec108 of collectIdeSkillFiles(_0x2bbfd0)){if(existsSync(_0xdec108))_0x237767[_0x70df11(0xe2)](_0xdec108);}let _0x27156c=null;const _0x44cd67=resolve(_0x2bbfd0,_0x70df11(0xfb));if(existsSync(_0x44cd67))try{const _0xaa44e1=JSON[_0x70df11(0xc5)](readFileSync(_0x44cd67,_0x70df11(0xf2)));if(_0xaa44e1?.[_0x70df11(0x120)]&&typeof _0xaa44e1['mcpServers']===_0x70df11(0xf9)){const _0x502378=[];for(const [_0x7a0444,_0x41c697]of Object['entries'](_0xaa44e1['mcpServers'])){const _0x57b225=_0x41c697;_0x57b225?.['args']&&Array[_0x70df11(0xfe)](_0x57b225[_0x70df11(0x113)])&&_0x57b225[_0x70df11(0x113)][_0x70df11(0x123)](_0x4ae155=>typeof _0x4ae155===_0x70df11(0xac)&&_0x4ae155[_0x70df11(0xdd)](_0x70df11(0x114)))&&_0x502378[_0x70df11(0xe2)](_0x7a0444);}_0x502378[_0x70df11(0xaa)]>0x0&&(_0x27156c={'path':_0x44cd67,'keys':_0x502378});}}catch{}const _0x2155ee=_0x237767[_0x70df11(0xaa)]>0x0||_0x4d93a0!==null;let _0x3a2502=null;const _0x4e6609=resolve(_0x2bbfd0,_0x70df11(0x127));if(existsSync(_0x4e6609))try{const _0x2e44cb=JSON['parse'](readFileSync(_0x4e6609,_0x70df11(0xf2)));for(const _0x5a34c0 of[_0x70df11(0xa8),_0x70df11(0xab)]){const _0x2a3757=_0x2e44cb?.[_0x5a34c0]?.[_0x70df11(0xf4)];if(typeof _0x2a3757==='string'){_0x2a3757!==_0x70df11(0xec)&&(_0x3a2502={'pkgPath':_0x4e6609,'currentVersion':_0x2a3757,'field':_0x5a34c0});break;}}}catch{}return{'configMigration':_0x4d93a0,'oldArtifacts':_0x237767,'oldMcpConfig':_0x27156c,'needsSkillSwap':_0x2155ee,'sdkUpgrade':_0x3a2502};}function printReport(_0x3a9fa9){const _0x5e1680=a89_0x405555,{configMigration:_0x3c2391,oldArtifacts:_0x9b0013,oldMcpConfig:_0x5cb16a,needsSkillSwap:_0x410b83}=_0x3a9fa9;console[_0x5e1680(0x10d)](''),console[_0x5e1680(0x10d)](a89_0x14aceb[_0x5e1680(0x103)](_0x5e1680(0x126))),console[_0x5e1680(0x10d)]('');_0x3c2391?(console[_0x5e1680(0x10d)](a89_0x14aceb[_0x5e1680(0xca)](_0x5e1680(0x129))+('\x20\x20'+a89_0x14aceb[_0x5e1680(0x11f)](_0x3c2391[_0x5e1680(0x12a)]))),console[_0x5e1680(0x10d)](_0x5e1680(0xb2)+(_0x3c2391[_0x5e1680(0x107)]?a89_0x14aceb[_0x5e1680(0xd6)](_0x5e1680(0xe5)):a89_0x14aceb[_0x5e1680(0xde)](_0x5e1680(0xd5)))),console[_0x5e1680(0x10d)](_0x5e1680(0xe1)+_0x3c2391[_0x5e1680(0xeb)]['join'](',\x20')),console[_0x5e1680(0x10d)]('\x20\x20Action:\x20migrate\x20→\x20backup\x20old\x20as\x20.bak')):console[_0x5e1680(0x10d)](a89_0x14aceb[_0x5e1680(0xca)](_0x5e1680(0x129))+'\x20\x20'+a89_0x14aceb['gray'](_0x5e1680(0xa7)));console['log']('');if(_0x9b0013[_0x5e1680(0xaa)]>0x0){console[_0x5e1680(0x10d)](a89_0x14aceb['cyan'](_0x5e1680(0x11a)));for(const _0x2dfee7 of _0x9b0013){console[_0x5e1680(0x10d)]('\x20\x20'+a89_0x14aceb[_0x5e1680(0xb0)](_0x5e1680(0xc6))+'\x20\x20'+_0x2dfee7);}console['log']('\x20\x20Action:\x20delete');}else console['log'](a89_0x14aceb[_0x5e1680(0xca)](_0x5e1680(0x11a))+'\x20\x20'+a89_0x14aceb[_0x5e1680(0xde)](_0x5e1680(0x118)));console['log']('');_0x5cb16a?(console[_0x5e1680(0x10d)](a89_0x14aceb[_0x5e1680(0xca)](_0x5e1680(0xed))+('\x20\x20'+a89_0x14aceb[_0x5e1680(0x11f)](_0x5cb16a[_0x5e1680(0xdf)])+_0x5e1680(0xd4)+_0x5cb16a[_0x5e1680(0xef)][_0x5e1680(0xdc)](',\x20'))),console[_0x5e1680(0x10d)](_0x5e1680(0xc1))):console[_0x5e1680(0x10d)](a89_0x14aceb[_0x5e1680(0xca)]('MCP\x20config:')+'\x20\x20'+a89_0x14aceb[_0x5e1680(0xde)](_0x5e1680(0x108)));console[_0x5e1680(0x10d)](''),console[_0x5e1680(0x10d)](a89_0x14aceb[_0x5e1680(0xca)](_0x5e1680(0xb3))+('\x20\x20'+(_0x410b83?a89_0x14aceb[_0x5e1680(0x11f)](_0x5e1680(0xf7)):a89_0x14aceb[_0x5e1680(0xd6)]('not\x20needed'))));_0x410b83&&console['log'](_0x5e1680(0xd0));console[_0x5e1680(0x10d)]('');if(_0x3a9fa9[_0x5e1680(0xfd)]){const {currentVersion:_0x296686,field:_0x2de348,pkgPath:_0x590a92}=_0x3a9fa9[_0x5e1680(0xfd)];console[_0x5e1680(0x10d)](a89_0x14aceb[_0x5e1680(0xca)](_0x5e1680(0xee))+('\x20\x20'+a89_0x14aceb[_0x5e1680(0x11f)](_0x590a92))),console['log'](_0x5e1680(0xdb)+_0x2de348+':\x20'+a89_0x14aceb[_0x5e1680(0x11f)](_0x296686)+_0x5e1680(0x101)+a89_0x14aceb[_0x5e1680(0xd6)](_0x5e1680(0xec))),console[_0x5e1680(0x10d)](_0x5e1680(0x110));}else console[_0x5e1680(0x10d)](a89_0x14aceb[_0x5e1680(0xca)](_0x5e1680(0xee))+'\x20\x20'+a89_0x14aceb[_0x5e1680(0xde)]('not\x20found\x20or\x20already\x20at\x20latest'));console['log']('');}function a89_0x4afc(_0x4236f8,_0x562614){_0x4236f8=_0x4236f8-0xa7;const _0xb67303=a89_0xb673();let _0x4afc36=_0xb67303[_0x4236f8];return _0x4afc36;}function execConfigMigration(_0x5f45a4,_0x4b9c79){const _0x22c6b0=a89_0x405555,{configMigration:_0x2b79e2}=_0x5f45a4;if(!_0x2b79e2?.['oldPath'])return{'step':0x1,'label':_0x22c6b0(0xe3),'ok':!![],'detail':'skipped\x20(no\x20legacy\x20config)'};const _0xee121e=readConfigFile(_0x2b79e2[_0x22c6b0(0x12a)]),_0x196dd5=resolve(_0x4b9c79,NEW_CONFIG_NAME),_0x460c86=_0x2b79e2['hasNewConfig']?readConfigFile(_0x196dd5):{};for(const [_0x59d76a,_0x5d3115]of Object['entries'](_0xee121e)){!(_0x59d76a in _0x460c86)&&(_0x460c86[_0x59d76a]=_0x5d3115);}writeConfigFile(_0x196dd5,_0x460c86);const _0x397112=_0x2b79e2[_0x22c6b0(0x12a)]+_0x22c6b0(0xe7);return renameSync(_0x2b79e2[_0x22c6b0(0x12a)],_0x397112),{'step':0x1,'label':_0x22c6b0(0xe3),'ok':!![],'detail':_0x2b79e2['oldPath']+_0x22c6b0(0x101)+_0x196dd5+'\x20(backup:\x20'+_0x397112+')'};}function execRemoveOldArtifacts(_0x29e78e){const _0x4cdd80=a89_0x405555,_0x4d7c62=[];for(const _0x3129c6 of _0x29e78e){try{if(!existsSync(_0x3129c6))continue;const _0x21da36=tryStat(_0x3129c6);_0x21da36?.[_0x4cdd80(0xd9)]()?rmSync(_0x3129c6,{'recursive':!![],'force':!![]}):unlinkSync(_0x3129c6);}catch(_0x415e41){_0x4d7c62[_0x4cdd80(0xe2)](_0x3129c6+':\x20'+_0x415e41[_0x4cdd80(0xb8)]);}}return{'step':0x3,'label':_0x4cdd80(0xce),'ok':_0x4d7c62['length']===0x0,'detail':_0x4d7c62[_0x4cdd80(0xaa)]>0x0?_0x29e78e['length']-_0x4d7c62['length']+'/'+_0x29e78e[_0x4cdd80(0xaa)]+'\x20removed\x20('+_0x4d7c62[_0x4cdd80(0xdc)](';\x20')+')':_0x29e78e['length']+_0x4cdd80(0x11e)};}function execCleanMcp(_0x154987){const _0x4b5a4f=a89_0x405555;if(!_0x154987['oldMcpConfig'])return{'step':0x4,'label':_0x4b5a4f(0x124),'ok':!![],'detail':_0x4b5a4f(0xb4)};try{const _0x51713d=readFileSync(_0x154987[_0x4b5a4f(0x128)]['path'],_0x4b5a4f(0xf2)),_0x267491=JSON[_0x4b5a4f(0xc5)](_0x51713d);if(_0x267491?.[_0x4b5a4f(0x120)]&&typeof _0x267491[_0x4b5a4f(0x120)]===_0x4b5a4f(0xf9)){const _0x5cdb9f=[];for(const [_0x22e24d,_0x5c9e7d]of Object['entries'](_0x267491[_0x4b5a4f(0x120)])){_0x5c9e7d?.['args']&&Array[_0x4b5a4f(0xfe)](_0x5c9e7d[_0x4b5a4f(0x113)])&&_0x5c9e7d[_0x4b5a4f(0x113)][_0x4b5a4f(0x123)](_0xe03d03=>typeof _0xe03d03===_0x4b5a4f(0xac)&&_0xe03d03['includes'](_0x4b5a4f(0x114)))&&_0x5cdb9f['push'](_0x22e24d);}for(const _0x6d533f of _0x5cdb9f){delete _0x267491[_0x4b5a4f(0x120)][_0x6d533f];}return _0x5cdb9f['length']>0x0&&writeFileSync(_0x154987['oldMcpConfig'][_0x4b5a4f(0xdf)],JSON[_0x4b5a4f(0xbb)](_0x267491,null,0x2)+'\x0a',_0x4b5a4f(0xf2)),{'step':0x4,'label':_0x4b5a4f(0x124),'ok':!![],'detail':_0x4b5a4f(0x119)+_0x5cdb9f[_0x4b5a4f(0xdc)](',\x20')+_0x4b5a4f(0xc7)+_0x154987[_0x4b5a4f(0x128)][_0x4b5a4f(0xdf)]};}return{'step':0x4,'label':_0x4b5a4f(0x124),'ok':!![],'detail':_0x4b5a4f(0x111)};}catch(_0x438bf2){return{'step':0x4,'label':_0x4b5a4f(0x124),'ok':![],'detail':_0x438bf2[_0x4b5a4f(0xb8)]};}}function execSkillsRemove(_0x1593e4,_0x1b430e){const _0x485c6b=a89_0x405555,_0x1c9243=runNpxSkillsRemove(_0x1593e4,{'stdio':_0x485c6b(0x122),'yes':_0x1b430e});return{'step':0x5,'label':_0x485c6b(0xd7),'ok':_0x1c9243['ok'],'detail':_0x1c9243['ok']?_0x485c6b(0xea):_0x1c9243[_0x485c6b(0xcc)]??'exit\x20'+_0x1c9243[_0x485c6b(0xaf)]};}function execSkillsAdd(_0x3d7082,_0x39b03b){const _0x54d418=a89_0x405555,_0x4805dd=runNpxSkillsAddGlobal(_0x3d7082,'lovrabet/rabetbase',{'stdio':_0x54d418(0x122),'yes':_0x39b03b});return{'step':0x6,'label':_0x54d418(0x105),'ok':_0x4805dd['ok'],'detail':_0x4805dd['ok']?_0x54d418(0xb6):_0x4805dd[_0x54d418(0xcc)]??_0x54d418(0xe8)+_0x4805dd[_0x54d418(0xaf)]};}function execUpgradeSdk(_0x452acf){const _0x30f3ff=a89_0x405555;if(!_0x452acf[_0x30f3ff(0xfd)])return{'step':0x7,'label':_0x30f3ff(0x115),'ok':!![],'detail':_0x30f3ff(0xa9)};const {pkgPath:_0x5495e6,currentVersion:_0x3d19d3,field:_0x2e5be6}=_0x452acf[_0x30f3ff(0xfd)];try{const _0xdbf00f=readFileSync(_0x5495e6,_0x30f3ff(0xf2)),_0x4b489b=JSON[_0x30f3ff(0xc5)](_0xdbf00f);return _0x4b489b[_0x2e5be6][_0x30f3ff(0xf4)]=_0x30f3ff(0xec),writeFileSync(_0x5495e6,JSON[_0x30f3ff(0xbb)](_0x4b489b,null,0x2)+'\x0a','utf8'),{'step':0x7,'label':_0x30f3ff(0x115),'ok':!![],'detail':_0x2e5be6+'[\x22@lovrabet/sdk\x22]:\x20'+_0x3d19d3+_0x30f3ff(0xc8)};}catch(_0x41250e){return{'step':0x7,'label':_0x30f3ff(0x115),'ok':![],'detail':_0x41250e[_0x30f3ff(0xb8)]};}}function tryStat(_0x4f4dda){try{return statSync(_0x4f4dda);}catch{return undefined;}}function printSummary(_0x1b26e6){const _0x1ab3f7=a89_0x405555;console[_0x1ab3f7(0x10d)](''),console['log'](a89_0x14aceb[_0x1ab3f7(0x103)](_0x1ab3f7(0xbd))),console[_0x1ab3f7(0x10d)]('');for(const _0x44bb94 of _0x1b26e6){const _0x303758=_0x44bb94['ok']?a89_0x14aceb['green']('OK'):a89_0x14aceb[_0x1ab3f7(0xb0)](_0x1ab3f7(0xbf));console['log']('\x20\x20'+_0x303758+_0x1ab3f7(0xe0)+_0x44bb94[_0x1ab3f7(0x121)]+':\x20'+_0x44bb94[_0x1ab3f7(0xd2)]);if(_0x44bb94[_0x1ab3f7(0xcd)])console[_0x1ab3f7(0x10d)]('\x20\x20\x20\x20\x20\x20\x20'+a89_0x14aceb[_0x1ab3f7(0xde)](_0x44bb94[_0x1ab3f7(0xcd)]));}console['log']('');}export async function upgradeApp(_0x117384,_0x26c17d){const _0xa64231=a89_0x405555,_0x36c5b8=process['cwd'](),_0xccfb0f=analyse(_0x36c5b8),_0x2644b9=!_0xccfb0f[_0xa64231(0xfa)]&&_0xccfb0f[_0xa64231(0xf6)][_0xa64231(0xaa)]===0x0&&!_0xccfb0f[_0xa64231(0x128)]&&!_0xccfb0f[_0xa64231(0x10c)]&&!_0xccfb0f[_0xa64231(0xfd)];if(_0x2644b9){console[_0xa64231(0x10d)](a89_0x14aceb[_0xa64231(0xd6)](_0xa64231(0xc2)));return;}printReport(_0xccfb0f);const _0x3d39b8=!!(_0x26c17d['yes']||_0x26c17d['Y']||_0x117384);if(!_0x3d39b8)try{const _0x170b21=await askConfirm(_0xa64231(0xe6));if(!_0x170b21){console['log'](a89_0x14aceb[_0xa64231(0xde)](_0xa64231(0xda)));return;}}catch(_0x1ecff1){if(_0x1ecff1?.['message']==='CANCEL'){console[_0xa64231(0x10d)](a89_0x14aceb[_0xa64231(0xde)](_0xa64231(0xda)));return;}throw _0x1ecff1;}const _0x6be507=[],_0x3f3302=a89_0x3b7c78({'text':_0xa64231(0xe9),'color':_0xa64231(0xca)})['start'](),_0x16cc4d=execConfigMigration(_0xccfb0f,_0x36c5b8);_0x6be507[_0xa64231(0xe2)](_0x16cc4d),_0x3f3302[_0x16cc4d['ok']?_0xa64231(0x112):_0xa64231(0xc4)](_0xa64231(0xc0)+(_0x16cc4d[_0xa64231(0xcd)]??(_0x16cc4d['ok']?_0xa64231(0xf5):_0xa64231(0xad))));const _0x20e3a4=resolve(_0x36c5b8,_0xa64231(0xae)),_0x266b6c=a89_0x3b7c78({'text':_0xa64231(0xff),'color':_0xa64231(0xca)})[_0xa64231(0x11d)]();if(existsSync(_0x20e3a4))try{rmSync(_0x20e3a4,{'recursive':!![],'force':!![]}),_0x266b6c[_0xa64231(0x112)](_0xa64231(0xb1)),_0x6be507[_0xa64231(0xe2)]({'step':0x2,'label':_0xa64231(0x10e),'ok':!![]});}catch(_0x5c8f02){_0x266b6c[_0xa64231(0xc4)](_0xa64231(0xcf)+_0x5c8f02['message']),_0x6be507[_0xa64231(0xe2)]({'step':0x2,'label':'Remove\x20.lovrabet/','ok':![],'detail':_0x5c8f02[_0xa64231(0xb8)]});}else _0x266b6c[_0xa64231(0x117)](_0xa64231(0x106)),_0x6be507[_0xa64231(0xe2)]({'step':0x2,'label':'Remove\x20.lovrabet/','ok':!![],'detail':_0xa64231(0xb4)});const _0x53176a=a89_0x3b7c78({'text':_0xa64231(0xb5),'color':_0xa64231(0xca)})[_0xa64231(0x11d)](),_0x30c2a9=execRemoveOldArtifacts(_0xccfb0f['oldArtifacts']);_0x6be507[_0xa64231(0xe2)](_0x30c2a9),_0x53176a[_0x30c2a9['ok']?_0xa64231(0x112):_0xa64231(0xc4)]('Step\x203/7:\x20Legacy\x20artifacts\x20—\x20'+(_0x30c2a9[_0xa64231(0xcd)]??(_0x30c2a9['ok']?_0xa64231(0xf5):'failed')));const _0x3eee4d=a89_0x3b7c78({'text':_0xa64231(0xf3),'color':'cyan'})[_0xa64231(0x11d)](),_0x223000=execCleanMcp(_0xccfb0f);_0x6be507['push'](_0x223000),_0x3eee4d[_0x223000['ok']?_0xa64231(0x112):_0xa64231(0xc4)](_0xa64231(0xf1)+(_0x223000[_0xa64231(0xcd)]??(_0x223000['ok']?_0xa64231(0xf5):_0xa64231(0xad))));const _0x460ecd=a89_0x3b7c78({'text':'Step\x205/7:\x20Removing\x20old\x20skill...','color':_0xa64231(0xca)})[_0xa64231(0x11d)](),_0x3dd8f9=execSkillsRemove(_0x36c5b8,_0x3d39b8);_0x6be507[_0xa64231(0xe2)](_0x3dd8f9),_0x460ecd[_0x3dd8f9['ok']?'succeed':_0xa64231(0xc4)](_0xa64231(0xf0)+(_0x3dd8f9[_0xa64231(0xcd)]??(_0x3dd8f9['ok']?'done':'failed')));const _0x3d3e2f=a89_0x3b7c78({'text':'Step\x206/7:\x20Installing\x20new\x20skill...','color':_0xa64231(0xca)})['start'](),_0x11b12f=execSkillsAdd(_0x36c5b8,_0x3d39b8);_0x6be507[_0xa64231(0xe2)](_0x11b12f),_0x3d3e2f[_0x11b12f['ok']?_0xa64231(0x112):_0xa64231(0xc4)](_0xa64231(0x102)+(_0x11b12f[_0xa64231(0xcd)]??(_0x11b12f['ok']?'done':_0xa64231(0xad))));const _0x249685=a89_0x3b7c78({'text':_0xa64231(0x10b),'color':'cyan'})['start'](),_0x1ce3f2=execUpgradeSdk(_0xccfb0f);_0x6be507[_0xa64231(0xe2)](_0x1ce3f2),_0x249685[_0x1ce3f2['ok']?_0xa64231(0x112):_0xa64231(0xc4)]('Step\x207/7:\x20@lovrabet/sdk\x20—\x20'+(_0x1ce3f2['detail']??(_0x1ce3f2['ok']?_0xa64231(0xf5):_0xa64231(0xad)))),printSummary(_0x6be507);const _0x394f2b=_0x6be507[_0xa64231(0x123)](_0x53bd40=>!_0x53bd40['ok']);_0x394f2b?console[_0xa64231(0x10d)](a89_0x14aceb['yellow'](_0xa64231(0xc9))):console['log'](a89_0x14aceb[_0xa64231(0xd6)]('Upgrade\x20completed\x20successfully!')),_0x1ce3f2['ok']&&_0xccfb0f['sdkUpgrade']&&(console[_0xa64231(0x10d)](''),console['log'](a89_0x14aceb[_0xa64231(0x103)][_0xa64231(0xca)](_0xa64231(0x109))),console['log'](a89_0x14aceb[_0xa64231(0xca)]('Please\x20re-install\x20dependencies\x20to\x20apply\x20the\x20change:')),console['log'](''),console[_0xa64231(0x10d)](a89_0x14aceb[_0xa64231(0xbe)]('\x20\x20npm\x20install')),console[_0xa64231(0x10d)](a89_0x14aceb[_0xa64231(0xbe)](_0xa64231(0x10a))),console[_0xa64231(0x10d)](a89_0x14aceb['white']('\x20\x20bun\x20install')),console[_0xa64231(0x10d)](''));}
@@ -1 +1 @@
1
- const a77_0x4fb64a=a77_0x1e6f;(function(_0x31341e,_0x482299){const _0x2b47d2=a77_0x1e6f,_0x3cf758=_0x31341e();while(!![]){try{const _0x224deb=parseInt(_0x2b47d2(0x117))/0x1*(-parseInt(_0x2b47d2(0x12a))/0x2)+-parseInt(_0x2b47d2(0x11d))/0x3*(parseInt(_0x2b47d2(0x104))/0x4)+parseInt(_0x2b47d2(0x103))/0x5+-parseInt(_0x2b47d2(0x129))/0x6+-parseInt(_0x2b47d2(0x11a))/0x7+parseInt(_0x2b47d2(0x10d))/0x8+-parseInt(_0x2b47d2(0x106))/0x9*(-parseInt(_0x2b47d2(0x108))/0xa);if(_0x224deb===_0x482299)break;else _0x3cf758['push'](_0x3cf758['shift']());}catch(_0x514aa1){_0x3cf758['push'](_0x3cf758['shift']());}}}(a77_0x1d82,0xc5037));import{apiDefinitions}from'../commands/api/index.js';import{bffDefinitions}from'../commands/bff/index.js';import{sqlDefinitions}from'../commands/sql/index.js';function a77_0x1e6f(_0x5c7703,_0x343d66){_0x5c7703=_0x5c7703-0xfc;const _0x1d82e3=a77_0x1d82();let _0x1e6f3c=_0x1d82e3[_0x5c7703];return _0x1e6f3c;}import{datasetDefinitions}from'../commands/dataset/index.js';import{codegenDefinitions}from'../commands/codegen/index.js';import{menuDefinitions}from'../commands/menu/index.js';import{appDefinitions}from'../commands/app/index.js';import{configDefinitions}from'../commands/config/index.js';import{doctorDefinition}from'../commands/doctor.js';import{updateDefinition}from'../commands/cli-update.js';function a77_0x1d82(){const _0xe4e33d=['values','risk','build','Self\x20Update','\x20\x20[write]','run','has','get','Project','2QNNWCR','start','Dataset\x20&\x20Operations','9468935uKkfAp','Diagnostics','App\x20Management','3561qKullm','from','Configuration','skill','description','auth','login','preview','push','set','logout','command','5815356GggfyM','378624jBkjQm','service','Run\x20any\x20package.json\x20script','commands','Run\x20Scripts','length','show','Code\x20Generation','Authentication','3867030cKBHyR','356YWpPXk','install','59013zQflhm','API','3780ngVNLR','wildcardDef','isSingleCommand','read','defaultCommand','2889704YNrQlR'];a77_0x1d82=function(){return _0xe4e33d;};return a77_0x1d82();}import{schemaDefinition}from'../commands/schema.js';import{authDefinitions}from'../commands/auth/index.js';import{logsDefinitions}from'../commands/logs/index.js';import{skillDefinitions}from'../commands/skill/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(_0x4bbaef){const _0x2da1a1=a77_0x1e6f;for(const _0x543ed3 of _0x4bbaef){definitions['set'](_0x543ed3[_0x2da1a1(0x12b)]+':'+_0x543ed3[_0x2da1a1(0x128)],_0x543ed3);let _0x4389dc=serviceGroups[_0x2da1a1(0x115)](_0x543ed3['service']);!_0x4389dc&&(_0x4389dc=[],serviceGroups[_0x2da1a1(0x126)](_0x543ed3[_0x2da1a1(0x12b)],_0x4389dc)),_0x4389dc[_0x2da1a1(0x125)](_0x543ed3);}}function registerDeclarativeService(_0x1a1698,_0x573156,_0xfdb99e){const _0x3d26a0=a77_0x1e6f;registerDefinitions(_0x573156);_0xfdb99e?.[_0x3d26a0(0x109)]&&registerDefinitions([_0xfdb99e[_0x3d26a0(0x109)]]);const _0x3241ae=_0x1cc364=>_0x1cc364===_0x3d26a0(0x10b)?'':_0x1cc364==='write'?_0x3d26a0(0x112):'\x20\x20[high-risk-write]',_0x3baf10={'service':_0x573156[0x0]['service'],'label':_0x1a1698,'commands':_0x573156['map'](_0x215c03=>({'command':_0x215c03[_0x3d26a0(0x128)],'description':_0x215c03[_0x3d26a0(0x121)],'tag':_0x3241ae(_0x215c03[_0x3d26a0(0x10f)])})),'declarative':!![],'defaultCommand':_0xfdb99e?.[_0x3d26a0(0x10c)]??(_0xfdb99e?.[_0x3d26a0(0x10a)]?_0x573156[0x0]['command']:undefined),'wildcardDef':_0xfdb99e?.[_0x3d26a0(0x109)],'isSingleCommand':_0xfdb99e?.['isSingleCommand']};serviceRegistry['push'](_0x3baf10),serviceByName[_0x3d26a0(0x126)](_0x3baf10[_0x3d26a0(0x12b)],_0x3baf10);}registerDeclarativeService('Quick\x20Start',initDefinitions,{'defaultCommand':'run','isSingleCommand':!![]}),registerDeclarativeService(a77_0x4fb64a(0x116),projectDefinitions),registerDeclarativeService(a77_0x4fb64a(0x11c),appDefinitions),registerDeclarativeService(a77_0x4fb64a(0xfe),[runDefinition],{'wildcardDef':runDefinition});{const last=serviceRegistry[serviceRegistry[a77_0x4fb64a(0xff)]-0x1];last[a77_0x4fb64a(0xfd)]=[{'command':'<script>','description':a77_0x4fb64a(0xfc),'tag':''}];}registerDeclarativeService(a77_0x4fb64a(0x102),authDefinitions,{'defaultCommand':a77_0x4fb64a(0x123)}),registerDeclarativeService(a77_0x4fb64a(0x111),[updateDefinition],{'isSingleCommand':!![]}),registerDeclarativeService(a77_0x4fb64a(0x11b),[doctorDefinition],{'isSingleCommand':!![]}),registerDeclarativeService('Schema',[schemaDefinition],{'isSingleCommand':!![]}),registerDeclarativeService(a77_0x4fb64a(0x11f),configDefinitions),registerDeclarativeService(a77_0x4fb64a(0x107),apiDefinitions),registerDeclarativeService('Menu',menuDefinitions),registerDeclarativeService(a77_0x4fb64a(0x119),datasetDefinitions),registerDeclarativeService('BFF\x20Scripts',bffDefinitions),registerDeclarativeService('SQL\x20Queries',sqlDefinitions),registerDeclarativeService(a77_0x4fb64a(0x101),codegenDefinitions),registerDeclarativeService('Skills',skillDefinitions),registerDeclarativeService('Logs',logsDefinitions,{'defaultCommand':a77_0x4fb64a(0x100)});export const deprecatedAliases={'create':{'service':'project','command':'create'},'start':{'service':a77_0x4fb64a(0x113),'command':a77_0x4fb64a(0x118)},'build':{'service':'run','command':a77_0x4fb64a(0x110)},'preview':{'service':a77_0x4fb64a(0x113),'command':a77_0x4fb64a(0x124)},'logout':{'service':a77_0x4fb64a(0x122),'command':a77_0x4fb64a(0x127)},'skills':{'service':a77_0x4fb64a(0x120),'command':a77_0x4fb64a(0x105)}};export function findDefinition(_0x2de947,_0x16c48f){const _0x472ab7=a77_0x4fb64a;return definitions[_0x472ab7(0x115)](_0x2de947+':'+_0x16c48f);}export function isKnownService(_0xd2a64b){const _0x45f513=a77_0x4fb64a;return serviceByName[_0x45f513(0x114)](_0xd2a64b);}export function isDeclarativeService(_0x2372da){const _0x5bd2cb=a77_0x4fb64a;return serviceGroups[_0x5bd2cb(0x114)](_0x2372da)||serviceByName[_0x5bd2cb(0x115)](_0x2372da)?.[_0x5bd2cb(0x109)]!==undefined;}export function getServiceEntry(_0xce5765){const _0x3a01d9=a77_0x4fb64a;return serviceByName[_0x3a01d9(0x115)](_0xce5765);}export function getLegacyHandler(_0x15ab22,_0x448ef9){return undefined;}export function getAllDefinitions(){const _0x4006b5=a77_0x4fb64a;return Array[_0x4006b5(0x11e)](definitions[_0x4006b5(0x10e)]());}
1
+ const a90_0x4b1ab2=a90_0x35b4;(function(_0x4d9a82,_0x264ee2){const _0x5d20af=a90_0x35b4,_0x1cc8a4=_0x4d9a82();while(!![]){try{const _0xc6f197=parseInt(_0x5d20af(0x1d3))/0x1+-parseInt(_0x5d20af(0x1d1))/0x2*(-parseInt(_0x5d20af(0x1de))/0x3)+parseInt(_0x5d20af(0x1cf))/0x4*(parseInt(_0x5d20af(0x1d4))/0x5)+-parseInt(_0x5d20af(0x1c7))/0x6*(parseInt(_0x5d20af(0x1ca))/0x7)+-parseInt(_0x5d20af(0x1e5))/0x8+-parseInt(_0x5d20af(0x1ec))/0x9+parseInt(_0x5d20af(0x1d9))/0xa;if(_0xc6f197===_0x264ee2)break;else _0x1cc8a4['push'](_0x1cc8a4['shift']());}catch(_0x573fc1){_0x1cc8a4['push'](_0x1cc8a4['shift']());}}}(a90_0x3734,0x8bd71));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{dbDefinitions}from'../commands/db/index.js';function a90_0x3734(){const _0x527799=['logout','Configuration','\x20\x20[high-risk-write]','5238162dYojhG','command','Skills','defaultCommand','Menu','length','login','Run\x20any\x20package.json\x20script','project','show','map','preview','Project','isSingleCommand','commands','4271742LHuQrk','start','run','7ykpOPx','API','skill','values','Authentication','1913636GSRQhB','push','7114oItwLC','wildcardDef','31673UpyrXD','10HVNWzZ','Diagnostics','Logs','install','BFF\x20Scripts','7800780RLoLmT','has','description','build','Database\x20Connections','381NIcPwc','get','create','Self\x20Update','Schema','SQL\x20Queries','service','2828384HknlqL','write','set','Quick\x20Start'];a90_0x3734=function(){return _0x527799;};return a90_0x3734();}import{codegenDefinitions}from'../commands/codegen/index.js';import{menuDefinitions}from'../commands/menu/index.js';import{appDefinitions}from'../commands/app/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{authDefinitions}from'../commands/auth/index.js';import{logsDefinitions}from'../commands/logs/index.js';import{skillDefinitions}from'../commands/skill/index.js';import{projectDefinitions}from'../commands/project/index.js';import{initDefinitions}from'../commands/init/index.js';import{runDefinition}from'../commands/run/index.js';function a90_0x35b4(_0x3b81bb,_0x10e6ee){_0x3b81bb=_0x3b81bb-0x1c7;const _0x373454=a90_0x3734();let _0x35b478=_0x373454[_0x3b81bb];return _0x35b478;}export const serviceRegistry=[];const serviceByName=new Map();export const definitions=new Map();export const serviceGroups=new Map();function registerDefinitions(_0x59964f){const _0x1d1858=a90_0x35b4;for(const _0x155129 of _0x59964f){definitions[_0x1d1858(0x1e7)](_0x155129[_0x1d1858(0x1e4)]+':'+_0x155129[_0x1d1858(0x1ed)],_0x155129);let _0xdf4eca=serviceGroups[_0x1d1858(0x1df)](_0x155129[_0x1d1858(0x1e4)]);!_0xdf4eca&&(_0xdf4eca=[],serviceGroups[_0x1d1858(0x1e7)](_0x155129[_0x1d1858(0x1e4)],_0xdf4eca)),_0xdf4eca[_0x1d1858(0x1d0)](_0x155129);}}function registerDeclarativeService(_0x406915,_0x21fc46,_0x3535e3){const _0x8f190f=a90_0x35b4;registerDefinitions(_0x21fc46);_0x3535e3?.[_0x8f190f(0x1d2)]&&registerDefinitions([_0x3535e3[_0x8f190f(0x1d2)]]);const _0x25015c=_0x14580a=>_0x14580a==='read'?'':_0x14580a===_0x8f190f(0x1e6)?'\x20\x20[write]':_0x8f190f(0x1eb),_0xf9e56={'service':_0x21fc46[0x0][_0x8f190f(0x1e4)],'label':_0x406915,'commands':_0x21fc46[_0x8f190f(0x1f6)](_0x5b86bc=>({'command':_0x5b86bc['command'],'description':_0x5b86bc[_0x8f190f(0x1db)],'tag':_0x25015c(_0x5b86bc['risk'])})),'declarative':!![],'defaultCommand':_0x3535e3?.[_0x8f190f(0x1ef)]??(_0x3535e3?.[_0x8f190f(0x1f9)]?_0x21fc46[0x0]['command']:undefined),'wildcardDef':_0x3535e3?.['wildcardDef'],'isSingleCommand':_0x3535e3?.[_0x8f190f(0x1f9)]};serviceRegistry[_0x8f190f(0x1d0)](_0xf9e56),serviceByName[_0x8f190f(0x1e7)](_0xf9e56[_0x8f190f(0x1e4)],_0xf9e56);}registerDeclarativeService(a90_0x4b1ab2(0x1e8),initDefinitions,{'defaultCommand':a90_0x4b1ab2(0x1c9),'isSingleCommand':!![]}),registerDeclarativeService(a90_0x4b1ab2(0x1f8),projectDefinitions),registerDeclarativeService('App\x20Management',appDefinitions),registerDeclarativeService('Run\x20Scripts',[runDefinition],{'wildcardDef':runDefinition});{const last=serviceRegistry[serviceRegistry[a90_0x4b1ab2(0x1f1)]-0x1];last[a90_0x4b1ab2(0x1fa)]=[{'command':'<script>','description':a90_0x4b1ab2(0x1f3),'tag':''}];}registerDeclarativeService(a90_0x4b1ab2(0x1ce),authDefinitions,{'defaultCommand':a90_0x4b1ab2(0x1f2)}),registerDeclarativeService(a90_0x4b1ab2(0x1e1),[updateDefinition],{'isSingleCommand':!![]}),registerDeclarativeService(a90_0x4b1ab2(0x1d5),[doctorDefinition],{'isSingleCommand':!![]}),registerDeclarativeService(a90_0x4b1ab2(0x1e2),[schemaDefinition],{'isSingleCommand':!![]}),registerDeclarativeService(a90_0x4b1ab2(0x1ea),configDefinitions),registerDeclarativeService(a90_0x4b1ab2(0x1cb),apiDefinitions),registerDeclarativeService(a90_0x4b1ab2(0x1f0),menuDefinitions),registerDeclarativeService(a90_0x4b1ab2(0x1dd),dbDefinitions),registerDeclarativeService('Dataset\x20&\x20Operations',datasetDefinitions),registerDeclarativeService(a90_0x4b1ab2(0x1d8),bffDefinitions),registerDeclarativeService(a90_0x4b1ab2(0x1e3),sqlDefinitions),registerDeclarativeService('Code\x20Generation',codegenDefinitions),registerDeclarativeService(a90_0x4b1ab2(0x1ee),skillDefinitions),registerDeclarativeService(a90_0x4b1ab2(0x1d6),logsDefinitions,{'defaultCommand':a90_0x4b1ab2(0x1f5)});export const deprecatedAliases={'create':{'service':a90_0x4b1ab2(0x1f4),'command':a90_0x4b1ab2(0x1e0)},'start':{'service':a90_0x4b1ab2(0x1c9),'command':a90_0x4b1ab2(0x1c8)},'build':{'service':a90_0x4b1ab2(0x1c9),'command':a90_0x4b1ab2(0x1dc)},'preview':{'service':'run','command':a90_0x4b1ab2(0x1f7)},'logout':{'service':'auth','command':a90_0x4b1ab2(0x1e9)},'skills':{'service':a90_0x4b1ab2(0x1cc),'command':a90_0x4b1ab2(0x1d7)}};export function findDefinition(_0x56594c,_0x41947d){const _0x31b47b=a90_0x4b1ab2;return definitions[_0x31b47b(0x1df)](_0x56594c+':'+_0x41947d);}export function isKnownService(_0x32ce03){const _0x156a0c=a90_0x4b1ab2;return serviceByName[_0x156a0c(0x1da)](_0x32ce03);}export function isDeclarativeService(_0x436bae){const _0x59b70b=a90_0x4b1ab2;return serviceGroups[_0x59b70b(0x1da)](_0x436bae)||serviceByName[_0x59b70b(0x1df)](_0x436bae)?.[_0x59b70b(0x1d2)]!==undefined;}export function getServiceEntry(_0x268eef){const _0x467e9b=a90_0x4b1ab2;return serviceByName[_0x467e9b(0x1df)](_0x268eef);}export function getLegacyHandler(_0x45ef7b,_0x50ec9b){return undefined;}export function getAllDefinitions(){const _0x141e89=a90_0x4b1ab2;return Array['from'](definitions[_0x141e89(0x1cd)]());}
@@ -1 +1 @@
1
- const a78_0x349383=a78_0x7633;(function(_0x519947,_0x5470ee){const _0x5a143e=a78_0x7633,_0x36f805=_0x519947();while(!![]){try{const _0x315d72=parseInt(_0x5a143e(0xbf))/0x1+-parseInt(_0x5a143e(0x9d))/0x2*(parseInt(_0x5a143e(0xb9))/0x3)+parseInt(_0x5a143e(0xa9))/0x4+parseInt(_0x5a143e(0x99))/0x5+parseInt(_0x5a143e(0x87))/0x6*(parseInt(_0x5a143e(0xa1))/0x7)+parseInt(_0x5a143e(0x92))/0x8+-parseInt(_0x5a143e(0x8f))/0x9*(parseInt(_0x5a143e(0x8b))/0xa);if(_0x315d72===_0x5470ee)break;else _0x36f805['push'](_0x36f805['shift']());}catch(_0x286cbd){_0x36f805['push'](_0x36f805['shift']());}}}(a78_0x28e8,0xae432));import{readFileSync,existsSync}from'node:fs';import{CLI_BIN_NAME}from'../../constant/cli.js';import{resolve,delimiter,join}from'node:path';import{spawn}from'node:child_process';import{CliErrors}from'../../errors.js';import{checkSdkVersion,printSdkUpgradeWarning}from'../../utils/check-sdk-version.js';import{checkCliVersion,printCliUpgradeWarning}from'../../utils/cli-version-check.js';const VERSION_CHECK_SCRIPTS=new Set([a78_0x349383(0xa8),a78_0x349383(0x95)]);function readPackageScripts(_0x5323b6){const _0x1f894c=a78_0x349383,_0x8b65c7=resolve(_0x5323b6,_0x1f894c(0xb5));if(!existsSync(_0x8b65c7))return null;try{const _0x43f0bc=JSON[_0x1f894c(0xab)](readFileSync(_0x8b65c7,_0x1f894c(0x86)));return _0x43f0bc['scripts']??{};}catch{return null;}}function a78_0x28e8(){const _0x314462=['npm','length','4271133SSZxFg','vite\x20build\x20--watch\x20exited\x20with\x20code\x20','\x20exited\x20with\x20code\x20','close','log','\x20\x20AVAILABLE\x20SCRIPTS\x20\x20(current\x20project)','323868asCzwI','Script\x20\x22','needsUpgrade','\x20\x20EXAMPLES','.bin','max','slice','\x20run\x20preview\x20--watch\x20\x20\x20#\x20parallel\x20build\x20--watch\x20+\x20preview','utf-8','54RerhWt','join','pnpm-lock.yaml','Available:\x20','130mJwhUW','\x20run\x20','watch','\x20\x20\x20\x20','956673IUGSSl','vite\x20preview\x20exited\x20with\x20code\x20','yarn.lock','1361616ZCgsws','has','error','dev','--watch','bun.lock','padEnd','2789380xzQqmN','entries','\x20run\x20build','keys','2YZivUS','read','\x20run\x20preview','node_modules','943957KSdyuP','boolean','validation','yarn','bool','push','all','start','5014980fmXRnl','cwd','parse','\x20run\x20<script>\x0a','inherit','\x22\x20not\x20found\x20in\x20package.json.','bun','args','pnpm','map','Run\x20a\x20package.json\x20script','run','package.json','vite'];a78_0x28e8=function(){return _0x314462;};return a78_0x28e8();}function detectPackageManager(_0x48c857){const _0x4d7ce2=a78_0x349383;if(existsSync(resolve(_0x48c857,'bun.lockb'))||existsSync(resolve(_0x48c857,_0x4d7ce2(0x97))))return _0x4d7ce2(0xaf);if(existsSync(resolve(_0x48c857,_0x4d7ce2(0x89))))return _0x4d7ce2(0xb1);if(existsSync(resolve(_0x48c857,_0x4d7ce2(0x91))))return _0x4d7ce2(0xa4);return _0x4d7ce2(0xb7);}function a78_0x7633(_0x4ecd09,_0x118116){_0x4ecd09=_0x4ecd09-0x84;const _0x28e8f8=a78_0x28e8();let _0x763335=_0x28e8f8[_0x4ecd09];return _0x763335;}async function versionCheck(_0x35bb03){const _0x47eff4=a78_0x349383,_0x20f73c=await checkCliVersion();if(_0x20f73c['needsUpgrade'])printCliUpgradeWarning(_0x20f73c);const _0x5edbdb=await checkSdkVersion(_0x35bb03);if(_0x5edbdb[_0x47eff4(0xc1)])printSdkUpgradeWarning(_0x5edbdb);}function spawnScript(_0x1fad0f,_0x2e8e3e,_0x42f566,_0xfd9e47){return new Promise((_0x329de1,_0x30c75f)=>{const _0x1056b3=a78_0x7633,_0x3a01f9=['run',_0x2e8e3e,..._0x42f566],_0x5e86f4=spawn(_0x1fad0f,_0x3a01f9,{'cwd':_0xfd9e47,'stdio':_0x1056b3(0xad),'shell':!![],'env':{...process.env,'PATH':''+join(_0xfd9e47,'node_modules',_0x1056b3(0xc3))+delimiter+process.env.PATH}});_0x5e86f4['on']('close',_0xcd8c9a=>{const _0x9046f0=_0x1056b3;if(_0xcd8c9a===0x0||_0xcd8c9a===null)_0x329de1();else _0x30c75f(new Error(_0x1fad0f+'\x20run\x20'+_0x2e8e3e+_0x9046f0(0xbb)+_0xcd8c9a));}),_0x5e86f4['on'](_0x1056b3(0x94),_0x30c75f);});}function spawnViteBuildWatch(_0x4f3cf7){return new Promise((_0x59df11,_0x3244ea)=>{const _0x2405bf=a78_0x7633,_0x5c0686=spawn(_0x2405bf(0xb6),['build',_0x2405bf(0x96)],{'cwd':_0x4f3cf7,'stdio':_0x2405bf(0xad),'shell':!![],'env':{...process.env,'PATH':''+join(_0x4f3cf7,_0x2405bf(0xa0),'.bin')+delimiter+process.env.PATH}});_0x5c0686['on'](_0x2405bf(0xbc),_0x2d40d6=>{const _0x3997c0=_0x2405bf;if(_0x2d40d6===0x0||_0x2d40d6===null)_0x59df11();else _0x3244ea(new Error(_0x3997c0(0xba)+_0x2d40d6));}),_0x5c0686['on'](_0x2405bf(0x94),_0x3244ea);});}function spawnVitePreview(_0x5efd5e){return new Promise((_0x2bccaf,_0x5dbbe1)=>{const _0x55eb51=a78_0x7633,_0x475322=spawn('vite',['preview'],{'cwd':_0x5efd5e,'stdio':_0x55eb51(0xad),'shell':!![],'env':{...process.env,'PATH':''+join(_0x5efd5e,_0x55eb51(0xa0),_0x55eb51(0xc3))+delimiter+process.env.PATH}});_0x475322['on']('close',_0x516b7c=>{const _0x1c5c5e=_0x55eb51;if(_0x516b7c===0x0||_0x516b7c===null)_0x2bccaf();else _0x5dbbe1(new Error(_0x1c5c5e(0x90)+_0x516b7c));}),_0x475322['on'](_0x55eb51(0x94),_0x5dbbe1);});}const runFlags=[{'name':a78_0x349383(0x8d),'type':a78_0x349383(0xa2),'description':'Enable\x20watch\x20mode\x20for\x20preview','default':![]}];export const runDefinition={'service':a78_0x349383(0xb4),'command':a78_0x349383(0xb4),'description':a78_0x349383(0xb3),'risk':a78_0x349383(0x9e),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'args':[{'name':'script','description':'Script\x20name\x20defined\x20in\x20package.json','required':![]}],'flags':runFlags,'helpExtra':()=>{const _0x39e84b=a78_0x349383,_0x55d52b=readPackageScripts(process['cwd']()),_0x1592a6=[];if(_0x55d52b&&Object[_0x39e84b(0x9c)](_0x55d52b)[_0x39e84b(0xb8)]>0x0){const _0xa8df5a=Object['keys'](_0x55d52b),_0x1124ee=Math[_0x39e84b(0xc4)](..._0xa8df5a[_0x39e84b(0xb2)](_0x1118de=>_0x1118de[_0x39e84b(0xb8)]));_0x1592a6[_0x39e84b(0xa6)](_0x39e84b(0xbe));for(const [_0x199585,_0x378330]of Object[_0x39e84b(0x9a)](_0x55d52b)){_0x1592a6[_0x39e84b(0xa6)](_0x39e84b(0x8e)+CLI_BIN_NAME+_0x39e84b(0x8c)+_0x199585['padEnd'](_0x1124ee+0x2)+'#\x20'+_0x378330);}}else _0x1592a6[_0x39e84b(0xa6)](_0x39e84b(0xc2)),_0x1592a6['push'](_0x39e84b(0x8e)+CLI_BIN_NAME+'\x20run\x20start'),_0x1592a6['push'](_0x39e84b(0x8e)+CLI_BIN_NAME+_0x39e84b(0x9b)),_0x1592a6['push'](_0x39e84b(0x8e)+CLI_BIN_NAME+_0x39e84b(0x9f)),_0x1592a6[_0x39e84b(0xa6)](_0x39e84b(0x8e)+CLI_BIN_NAME+_0x39e84b(0x85));return _0x1592a6['join']('\x0a');},async 'execute'(_0x2af62e){const _0x4997a1=a78_0x349383,_0x42db94=process[_0x4997a1(0xaa)](),_0x5dd002=_0x2af62e[_0x4997a1(0xb0)][0x0],_0x5314cc=_0x2af62e['args'][_0x4997a1(0x84)](0x1),_0xfb583a=readPackageScripts(_0x42db94);if(!_0xfb583a)throw CliErrors[_0x4997a1(0xa3)]('No\x20package.json\x20found\x20in\x20current\x20directory.');if(!_0x5dd002){const _0x356eb1=Object[_0x4997a1(0x9c)](_0xfb583a);if(_0x356eb1[_0x4997a1(0xb8)]===0x0)console[_0x4997a1(0xbd)]('No\x20scripts\x20defined\x20in\x20package.json.');else{console[_0x4997a1(0xbd)]('\x0a\x20\x20Available\x20scripts:\x0a');const _0x12dd6d=Math[_0x4997a1(0xc4)](..._0x356eb1[_0x4997a1(0xb2)](_0x492183=>_0x492183[_0x4997a1(0xb8)]));for(const [_0x277970,_0x42b4e9]of Object['entries'](_0xfb583a)){console[_0x4997a1(0xbd)]('\x20\x20\x20\x20'+_0x277970[_0x4997a1(0x98)](_0x12dd6d+0x2)+_0x42b4e9);}console[_0x4997a1(0xbd)]('\x0a\x20\x20Usage:\x20'+CLI_BIN_NAME+_0x4997a1(0xac));}return{'ok':!![]};}if(!_0xfb583a[_0x5dd002])throw CliErrors[_0x4997a1(0xa3)](_0x4997a1(0xc0)+_0x5dd002+_0x4997a1(0xae),_0x4997a1(0x8a)+(Object[_0x4997a1(0x9c)](_0xfb583a)[_0x4997a1(0x88)](',\x20')||'(none)'));const _0x355a6a=detectPackageManager(_0x42db94);VERSION_CHECK_SCRIPTS[_0x4997a1(0x93)](_0x5dd002)&&await versionCheck(_0x42db94);if(_0x5dd002==='preview'&&_0x2af62e[_0x4997a1(0xa5)](_0x4997a1(0x8d)))return await Promise[_0x4997a1(0xa7)]([spawnViteBuildWatch(_0x42db94),spawnVitePreview(_0x42db94)]),{'ok':!![]};return await spawnScript(_0x355a6a,_0x5dd002,_0x5314cc,_0x42db94),{'ok':!![]};}};
1
+ const a91_0xa1cd89=a91_0x2fe5;(function(_0x3ba1d7,_0x33ebc1){const _0x22e7ba=a91_0x2fe5,_0x850661=_0x3ba1d7();while(!![]){try{const _0x24df20=parseInt(_0x22e7ba(0x1a6))/0x1+-parseInt(_0x22e7ba(0x1b2))/0x2+parseInt(_0x22e7ba(0x1b1))/0x3+-parseInt(_0x22e7ba(0x193))/0x4+parseInt(_0x22e7ba(0x19b))/0x5*(-parseInt(_0x22e7ba(0x1a4))/0x6)+parseInt(_0x22e7ba(0x1b0))/0x7*(parseInt(_0x22e7ba(0x1c2))/0x8)+parseInt(_0x22e7ba(0x1a9))/0x9;if(_0x24df20===_0x33ebc1)break;else _0x850661['push'](_0x850661['shift']());}catch(_0x5a0a99){_0x850661['push'](_0x850661['shift']());}}}(a91_0x5168,0x70d0b));import{readFileSync,existsSync}from'node:fs';import{CLI_BIN_NAME}from'../../constant/cli.js';import{resolve,delimiter,join}from'node:path';import{spawn}from'node:child_process';import{CliErrors}from'../../errors.js';import{checkSdkVersion,printSdkUpgradeWarning}from'../../utils/check-sdk-version.js';function a91_0x5168(){const _0x5a3b4b=['\x22\x20not\x20found\x20in\x20package.json.','Script\x20\x22','inherit','\x20\x20AVAILABLE\x20SCRIPTS\x20\x20(current\x20project)','padEnd','error','push','vite\x20build\x20--watch\x20exited\x20with\x20code\x20','cwd','40OpBODe','utf-8','Script\x20name\x20defined\x20in\x20package.json','run','\x20\x20\x20\x20','\x20run\x20start','needsUpgrade','Available:\x20','\x20run\x20<script>\x0a','yarn','\x20\x20EXAMPLES','No\x20scripts\x20defined\x20in\x20package.json.','scripts','yarn.lock','\x20run\x20preview\x20--watch\x20\x20\x20#\x20parallel\x20build\x20--watch\x20+\x20preview','script','bun.lock','1167500KIjXkd','npm','\x20run\x20build','start','vite','read','.bin','args','19455SKfbab','node_modules','\x0a\x20\x20Available\x20scripts:\x0a','\x20run\x20','has','keys','boolean','entries','(none)','1266REdzNI','pnpm-lock.yaml','722698NfnDIu','close','validation','4390272RVIfuS','vite\x20preview\x20exited\x20with\x20code\x20','bun','build','bool','join','log','938581zTSmXO','324441RjCGwM','828202kfKkDm','\x20exited\x20with\x20code\x20','watch','length','all','parse','map'];a91_0x5168=function(){return _0x5a3b4b;};return a91_0x5168();}import{checkCliVersion,printCliUpgradeWarning}from'../../utils/cli-version-check.js';const VERSION_CHECK_SCRIPTS=new Set([a91_0xa1cd89(0x196),'dev']);function readPackageScripts(_0x3359fa){const _0x15b6b4=a91_0xa1cd89,_0x1925d6=resolve(_0x3359fa,'package.json');if(!existsSync(_0x1925d6))return null;try{const _0x58cd33=JSON[_0x15b6b4(0x1b7)](readFileSync(_0x1925d6,_0x15b6b4(0x1c3)));return _0x58cd33[_0x15b6b4(0x1ce)]??{};}catch{return null;}}function detectPackageManager(_0x482a77){const _0x17b352=a91_0xa1cd89;if(existsSync(resolve(_0x482a77,'bun.lockb'))||existsSync(resolve(_0x482a77,_0x17b352(0x192))))return _0x17b352(0x1ab);if(existsSync(resolve(_0x482a77,_0x17b352(0x1a5))))return'pnpm';if(existsSync(resolve(_0x482a77,_0x17b352(0x1cf))))return _0x17b352(0x1cb);return _0x17b352(0x194);}async function versionCheck(_0x397b97){const _0x578700=a91_0xa1cd89,_0x1a6024=await checkCliVersion();if(_0x1a6024['needsUpgrade'])printCliUpgradeWarning(_0x1a6024);const _0x9f4067=await checkSdkVersion(_0x397b97);if(_0x9f4067[_0x578700(0x1c8)])printSdkUpgradeWarning(_0x9f4067);}function spawnScript(_0xb44cca,_0x4bc794,_0x578524,_0xe60223){return new Promise((_0x292a28,_0xc83dc)=>{const _0x481f58=a91_0x2fe5,_0x596d6f=[_0x481f58(0x1c5),_0x4bc794,..._0x578524],_0x2ae2da=spawn(_0xb44cca,_0x596d6f,{'cwd':_0xe60223,'stdio':_0x481f58(0x1bb),'shell':!![],'env':{...process.env,'PATH':''+join(_0xe60223,_0x481f58(0x19c),'.bin')+delimiter+process.env.PATH}});_0x2ae2da['on'](_0x481f58(0x1a7),_0x142521=>{const _0x43ecf4=_0x481f58;if(_0x142521===0x0||_0x142521===null)_0x292a28();else _0xc83dc(new Error(_0xb44cca+_0x43ecf4(0x19e)+_0x4bc794+_0x43ecf4(0x1b3)+_0x142521));}),_0x2ae2da['on'](_0x481f58(0x1be),_0xc83dc);});}function a91_0x2fe5(_0x1b876f,_0x469c74){_0x1b876f=_0x1b876f-0x191;const _0x516858=a91_0x5168();let _0x2fe59c=_0x516858[_0x1b876f];return _0x2fe59c;}function spawnViteBuildWatch(_0x411b2e){return new Promise((_0x3e556b,_0x15b5ed)=>{const _0x3b3575=a91_0x2fe5,_0x1c753f=spawn(_0x3b3575(0x197),[_0x3b3575(0x1ac),'--watch'],{'cwd':_0x411b2e,'stdio':_0x3b3575(0x1bb),'shell':!![],'env':{...process.env,'PATH':''+join(_0x411b2e,_0x3b3575(0x19c),_0x3b3575(0x199))+delimiter+process.env.PATH}});_0x1c753f['on']('close',_0xd459dd=>{const _0x44263d=_0x3b3575;if(_0xd459dd===0x0||_0xd459dd===null)_0x3e556b();else _0x15b5ed(new Error(_0x44263d(0x1c0)+_0xd459dd));}),_0x1c753f['on'](_0x3b3575(0x1be),_0x15b5ed);});}function spawnVitePreview(_0x1e1c05){return new Promise((_0x37f737,_0x5b7d2d)=>{const _0xd4877f=a91_0x2fe5,_0x20dd6c=spawn(_0xd4877f(0x197),['preview'],{'cwd':_0x1e1c05,'stdio':_0xd4877f(0x1bb),'shell':!![],'env':{...process.env,'PATH':''+join(_0x1e1c05,_0xd4877f(0x19c),_0xd4877f(0x199))+delimiter+process.env.PATH}});_0x20dd6c['on']('close',_0x5ddc07=>{const _0x5d2346=_0xd4877f;if(_0x5ddc07===0x0||_0x5ddc07===null)_0x37f737();else _0x5b7d2d(new Error(_0x5d2346(0x1aa)+_0x5ddc07));}),_0x20dd6c['on'](_0xd4877f(0x1be),_0x5b7d2d);});}const runFlags=[{'name':a91_0xa1cd89(0x1b4),'type':a91_0xa1cd89(0x1a1),'description':'Enable\x20watch\x20mode\x20for\x20preview','default':![]}];export const runDefinition={'service':'run','command':a91_0xa1cd89(0x1c5),'description':'Run\x20a\x20package.json\x20script','risk':a91_0xa1cd89(0x198),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'args':[{'name':a91_0xa1cd89(0x191),'description':a91_0xa1cd89(0x1c4),'required':![]}],'flags':runFlags,'helpExtra':()=>{const _0x3f0723=a91_0xa1cd89,_0x52c50d=readPackageScripts(process[_0x3f0723(0x1c1)]()),_0x57295e=[];if(_0x52c50d&&Object[_0x3f0723(0x1a0)](_0x52c50d)[_0x3f0723(0x1b5)]>0x0){const _0x2eefae=Object[_0x3f0723(0x1a0)](_0x52c50d),_0x3d93b6=Math['max'](..._0x2eefae[_0x3f0723(0x1b8)](_0x122c2a=>_0x122c2a[_0x3f0723(0x1b5)]));_0x57295e[_0x3f0723(0x1bf)](_0x3f0723(0x1bc));for(const [_0x15885d,_0x1e9ec2]of Object[_0x3f0723(0x1a2)](_0x52c50d)){_0x57295e['push'](_0x3f0723(0x1c6)+CLI_BIN_NAME+_0x3f0723(0x19e)+_0x15885d[_0x3f0723(0x1bd)](_0x3d93b6+0x2)+'#\x20'+_0x1e9ec2);}}else _0x57295e[_0x3f0723(0x1bf)](_0x3f0723(0x1cc)),_0x57295e[_0x3f0723(0x1bf)](_0x3f0723(0x1c6)+CLI_BIN_NAME+_0x3f0723(0x1c7)),_0x57295e['push'](_0x3f0723(0x1c6)+CLI_BIN_NAME+_0x3f0723(0x195)),_0x57295e['push'](_0x3f0723(0x1c6)+CLI_BIN_NAME+'\x20run\x20preview'),_0x57295e['push'](_0x3f0723(0x1c6)+CLI_BIN_NAME+_0x3f0723(0x1d0));return _0x57295e[_0x3f0723(0x1ae)]('\x0a');},async 'execute'(_0x590f49){const _0xa62464=a91_0xa1cd89,_0x35dff6=process[_0xa62464(0x1c1)](),_0xcc7dc8=_0x590f49['args'][0x0],_0x1584cf=_0x590f49[_0xa62464(0x19a)]['slice'](0x1),_0x3fef4a=readPackageScripts(_0x35dff6);if(!_0x3fef4a)throw CliErrors[_0xa62464(0x1a8)]('No\x20package.json\x20found\x20in\x20current\x20directory.');if(!_0xcc7dc8){const _0xd3811d=Object[_0xa62464(0x1a0)](_0x3fef4a);if(_0xd3811d[_0xa62464(0x1b5)]===0x0)console[_0xa62464(0x1af)](_0xa62464(0x1cd));else{console[_0xa62464(0x1af)](_0xa62464(0x19d));const _0x1c2fc6=Math['max'](..._0xd3811d[_0xa62464(0x1b8)](_0x5847c8=>_0x5847c8[_0xa62464(0x1b5)]));for(const [_0x249604,_0x2ba7fa]of Object[_0xa62464(0x1a2)](_0x3fef4a)){console['log']('\x20\x20\x20\x20'+_0x249604[_0xa62464(0x1bd)](_0x1c2fc6+0x2)+_0x2ba7fa);}console[_0xa62464(0x1af)]('\x0a\x20\x20Usage:\x20'+CLI_BIN_NAME+_0xa62464(0x1ca));}return{'ok':!![]};}if(!_0x3fef4a[_0xcc7dc8])throw CliErrors[_0xa62464(0x1a8)](_0xa62464(0x1ba)+_0xcc7dc8+_0xa62464(0x1b9),_0xa62464(0x1c9)+(Object[_0xa62464(0x1a0)](_0x3fef4a)[_0xa62464(0x1ae)](',\x20')||_0xa62464(0x1a3)));const _0x20c07=detectPackageManager(_0x35dff6);VERSION_CHECK_SCRIPTS[_0xa62464(0x19f)](_0xcc7dc8)&&await versionCheck(_0x35dff6);if(_0xcc7dc8==='preview'&&_0x590f49[_0xa62464(0x1ad)](_0xa62464(0x1b4)))return await Promise[_0xa62464(0x1b6)]([spawnViteBuildWatch(_0x35dff6),spawnVitePreview(_0x35dff6)]),{'ok':!![]};return await spawnScript(_0x20c07,_0xcc7dc8,_0x1584cf,_0x35dff6),{'ok':!![]};}};
@@ -1 +1 @@
1
- const a79_0x4294d7=a79_0x7050;function a79_0x7050(_0x19165e,_0x3fd62c){_0x19165e=_0x19165e-0x13f;const _0x28ce88=a79_0x28ce();let _0x705092=_0x28ce88[_0x19165e];return _0x705092;}(function(_0x3458b2,_0x42e800){const _0x5456ea=a79_0x7050,_0x3d4da5=_0x3458b2();while(!![]){try{const _0x1f4198=parseInt(_0x5456ea(0x14a))/0x1+parseInt(_0x5456ea(0x141))/0x2+-parseInt(_0x5456ea(0x149))/0x3+-parseInt(_0x5456ea(0x142))/0x4+parseInt(_0x5456ea(0x143))/0x5+-parseInt(_0x5456ea(0x14b))/0x6*(parseInt(_0x5456ea(0x145))/0x7)+-parseInt(_0x5456ea(0x146))/0x8;if(_0x1f4198===_0x42e800)break;else _0x3d4da5['push'](_0x3d4da5['shift']());}catch(_0x4adcfa){_0x3d4da5['push'](_0x3d4da5['shift']());}}}(a79_0x28ce,0xb4a23));import{buildSchemaPayload}from'../framework/schema-export.js';function a79_0x28ce(){const _0x2da674=['read','850773tRmfJX','1134025FntYBx','30nMUSab','export','schema','1573984NSKdns','1923084LBNpfz','3699590zdCmiZ','Export\x20machine-readable\x20command\x20schema\x20(JSON)','1529801IDMlor','511864jIKJya','json'];a79_0x28ce=function(){return _0x2da674;};return a79_0x28ce();}async function execute(_0x492b5e){const _0x2b9e98=await buildSchemaPayload();return{'ok':!![],'data':_0x2b9e98};}export const schemaDefinition={'service':a79_0x4294d7(0x140),'command':a79_0x4294d7(0x13f),'description':a79_0x4294d7(0x144),'risk':a79_0x4294d7(0x148),'requiresAuth':![],'requiresAppCode':![],'hasFormat':!![],'defaultOutputFormat':a79_0x4294d7(0x147),'flags':[],'execute':execute};
1
+ function a92_0x39f6(_0x38cc16,_0x5dd1cc){_0x38cc16=_0x38cc16-0xfc;const _0x2dbee6=a92_0x2dbe();let _0x39f6c5=_0x2dbee6[_0x38cc16];return _0x39f6c5;}function a92_0x2dbe(){const _0x340c33=['14018TvjuQL','39942amAvjk','read','Export\x20machine-readable\x20command\x20schema\x20(JSON)','schema','4033854QUAjtI','24515vpKuVJ','654789lfDWCI','309594nXmCQq','378eqEEKy','896008ZZrjzM','180TWsNxd'];a92_0x2dbe=function(){return _0x340c33;};return a92_0x2dbe();}const a92_0x515f5e=a92_0x39f6;(function(_0x14af31,_0x100cff){const _0x3a186b=a92_0x39f6,_0x248b8a=_0x14af31();while(!![]){try{const _0x31e0b6=-parseInt(_0x3a186b(0x103))/0x1+parseInt(_0x3a186b(0xfc))/0x2+parseInt(_0x3a186b(0x104))/0x3+-parseInt(_0x3a186b(0x107))/0x4*(-parseInt(_0x3a186b(0x102))/0x5)+parseInt(_0x3a186b(0xfd))/0x6*(parseInt(_0x3a186b(0x105))/0x7)+parseInt(_0x3a186b(0x106))/0x8+parseInt(_0x3a186b(0x101))/0x9;if(_0x31e0b6===_0x100cff)break;else _0x248b8a['push'](_0x248b8a['shift']());}catch(_0x762b47){_0x248b8a['push'](_0x248b8a['shift']());}}}(a92_0x2dbe,0x9171a));import{buildSchemaPayload}from'../framework/schema-export.js';async function execute(_0x3096a9){const _0x10b882=await buildSchemaPayload();return{'ok':!![],'data':_0x10b882};}export const schemaDefinition={'service':a92_0x515f5e(0x100),'command':'export','description':a92_0x515f5e(0xff),'risk':a92_0x515f5e(0xfe),'requiresAuth':![],'requiresAppCode':![],'hasFormat':!![],'defaultOutputFormat':'json','flags':[],'execute':execute};
@@ -1 +1 @@
1
- function a80_0x4e22(){const _0x33dd00=['pipe','skipped','执行安装技能包命令(委托给\x20npx\x20skills\x20--global)','write','log','\x20skill\x20installed','cwd','install','10mJZLpd','../../skills/npx-skills-add.js','288294JTEOhG','Check\x20network\x20connectivity\x20and\x20try\x20again.','nonInteractive','2795320fBPMoR','558bTcoZz','setLogPath','634130wrIQnW','info','27MNsCOT','npx\x20skills\x20add\x20failed:\x20','Skipped\x20npx\x20(RABETBASE_SKIP_NPX_SKILLS=1);\x20assuming\x20skill\x20is\x20already\x20present.','error','41010NLjARx','338074gBbfzZ','inherit','apiError','24bggqFl','skill-install','149680VlzevT','Install\x20developer\x20skill\x20package','8636dhLTMD','lovrabet/rabetbase'];a80_0x4e22=function(){return _0x33dd00;};return a80_0x4e22();}const a80_0x31104e=a80_0x1699;(function(_0x386bd4,_0x44fbfa){const _0x2a019c=a80_0x1699,_0x27296f=_0x386bd4();while(!![]){try{const _0x3d7118=parseInt(_0x2a019c(0x1e7))/0x1+parseInt(_0x2a019c(0x1e2))/0x2+-parseInt(_0x2a019c(0x1dd))/0x3*(parseInt(_0x2a019c(0x1e9))/0x4)+parseInt(_0x2a019c(0x1d3))/0x5*(parseInt(_0x2a019c(0x1d5))/0x6)+parseInt(_0x2a019c(0x1db))/0x7*(parseInt(_0x2a019c(0x1e5))/0x8)+parseInt(_0x2a019c(0x1d9))/0x9*(-parseInt(_0x2a019c(0x1e1))/0xa)+-parseInt(_0x2a019c(0x1d8))/0xb;if(_0x3d7118===_0x44fbfa)break;else _0x27296f['push'](_0x27296f['shift']());}catch(_0x170013){_0x27296f['push'](_0x27296f['shift']());}}}(a80_0x4e22,0x26c34));import{CliErrors}from'../../errors.js';function a80_0x1699(_0x216eb5,_0x5db106){_0x216eb5=_0x216eb5-0x1cd;const _0x4e22ec=a80_0x4e22();let _0x169902=_0x4e22ec[_0x216eb5];return _0x169902;}import{CLI_BIN_NAME}from'../../constant/cli.js';import{logger}from'../../utils/logger.js';export const skillDefinitions=[{'service':'skill','command':a80_0x31104e(0x1d2),'description':a80_0x31104e(0x1e8),'risk':a80_0x31104e(0x1ce),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x5ba5e4){const _0xdbaca7=a80_0x31104e;logger[_0xdbaca7(0x1da)](process[_0xdbaca7(0x1d1)]()),logger[_0xdbaca7(0x1dc)](_0xdbaca7(0x1e6),_0xdbaca7(0x1cd));const {runNpxSkillsAddGlobal:_0x10ac2e}=await import(_0xdbaca7(0x1d4)),_0x4bf4dd=_0x5ba5e4[_0xdbaca7(0x1d7)]?_0xdbaca7(0x1eb):_0xdbaca7(0x1e3);console[_0xdbaca7(0x1cf)]('Installing\x20official\x20skill\x20via\x20npx\x20(npx\x20-y\x20skills\x20add\x20lovrabet/rabetbase\x20--global)...');const _0x2d3376=_0x10ac2e(process['cwd'](),_0xdbaca7(0x1ea),{'stdio':_0x4bf4dd});if(_0x2d3376[_0xdbaca7(0x1ec)])console[_0xdbaca7(0x1cf)](_0xdbaca7(0x1df));else{if(_0x2d3376['ok'])console[_0xdbaca7(0x1cf)](CLI_BIN_NAME+_0xdbaca7(0x1d0));else throw CliErrors[_0xdbaca7(0x1e4)](_0xdbaca7(0x1de)+(_0x2d3376[_0xdbaca7(0x1e0)]||'unknown'),_0xdbaca7(0x1d6));}return{'ok':!![]};}}];
1
+ function a93_0x4c75(_0x572d6d,_0xb54fd8){_0x572d6d=_0x572d6d-0x10d;const _0x35d8b2=a93_0x35d8();let _0x4c75ef=_0x35d8b2[_0x572d6d];return _0x4c75ef;}const a93_0x301098=a93_0x4c75;(function(_0x4714ed,_0x2a969b){const _0x3e8c66=a93_0x4c75,_0x35a87b=_0x4714ed();while(!![]){try{const _0x50ecd8=parseInt(_0x3e8c66(0x11c))/0x1*(-parseInt(_0x3e8c66(0x119))/0x2)+parseInt(_0x3e8c66(0x115))/0x3*(-parseInt(_0x3e8c66(0x126))/0x4)+-parseInt(_0x3e8c66(0x117))/0x5*(parseInt(_0x3e8c66(0x10e))/0x6)+parseInt(_0x3e8c66(0x123))/0x7*(-parseInt(_0x3e8c66(0x111))/0x8)+parseInt(_0x3e8c66(0x122))/0x9*(parseInt(_0x3e8c66(0x10f))/0xa)+parseInt(_0x3e8c66(0x11a))/0xb+parseInt(_0x3e8c66(0x11e))/0xc;if(_0x50ecd8===_0x2a969b)break;else _0x35a87b['push'](_0x35a87b['shift']());}catch(_0x56ca32){_0x35a87b['push'](_0x35a87b['shift']());}}}(a93_0x35d8,0xb49ed));import{CliErrors}from'../../errors.js';import{CLI_BIN_NAME}from'../../constant/cli.js';function a93_0x35d8(){const _0x177c0c=['unknown','19724184tYQYUU','lovrabet/rabetbase','Skipped\x20npx\x20(RABETBASE_SKIP_NPX_SKILLS=1);\x20assuming\x20skill\x20is\x20already\x20present.','Install\x20developer\x20skill\x20package','737946YnsyZp','2996lupjvd','skill','Check\x20network\x20connectivity\x20and\x20try\x20again.','3412kXNFth','\x20skill\x20installed','log','5579448LgHuWB','30LvPevA','install','17904FqkLEB','cwd','error','pipe','9WHMGee','skill-install','5uqdtQn','skipped','6bfSecX','13260731nsfnCn','../../skills/npx-skills-add.js','155011zBirUx'];a93_0x35d8=function(){return _0x177c0c;};return a93_0x35d8();}import{logger}from'../../utils/logger.js';export const skillDefinitions=[{'service':a93_0x301098(0x124),'command':a93_0x301098(0x110),'description':a93_0x301098(0x121),'risk':'write','requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x49c5c9){const _0x2d2a97=a93_0x301098;logger['setLogPath'](process[_0x2d2a97(0x112)]()),logger['info'](_0x2d2a97(0x116),'执行安装技能包命令(委托给\x20npx\x20skills\x20--global)');const {runNpxSkillsAddGlobal:_0x5cd1a3}=await import(_0x2d2a97(0x11b)),_0x255eb5=_0x49c5c9['nonInteractive']?_0x2d2a97(0x114):'inherit';console[_0x2d2a97(0x10d)]('Installing\x20official\x20skill\x20via\x20npx\x20(npx\x20-y\x20skills\x20add\x20lovrabet/rabetbase\x20--global)...');const _0x553810=_0x5cd1a3(process['cwd'](),_0x2d2a97(0x11f),{'stdio':_0x255eb5});if(_0x553810[_0x2d2a97(0x118)])console[_0x2d2a97(0x10d)](_0x2d2a97(0x120));else{if(_0x553810['ok'])console[_0x2d2a97(0x10d)](CLI_BIN_NAME+_0x2d2a97(0x127));else throw CliErrors['apiError']('npx\x20skills\x20add\x20failed:\x20'+(_0x553810[_0x2d2a97(0x113)]||_0x2d2a97(0x11d)),_0x2d2a97(0x125));}return{'ok':!![]};}}];
@@ -1 +1 @@
1
- const a81_0x1a940a=a81_0x1f12;(function(_0x4102b6,_0x471c7f){const _0x16debb=a81_0x1f12,_0x34f8c0=_0x4102b6();while(!![]){try{const _0x516537=-parseInt(_0x16debb(0x7c))/0x1*(parseInt(_0x16debb(0x65))/0x2)+-parseInt(_0x16debb(0x6d))/0x3+-parseInt(_0x16debb(0x7a))/0x4+-parseInt(_0x16debb(0x6b))/0x5*(parseInt(_0x16debb(0x71))/0x6)+-parseInt(_0x16debb(0x72))/0x7*(parseInt(_0x16debb(0x66))/0x8)+-parseInt(_0x16debb(0x68))/0x9*(-parseInt(_0x16debb(0x77))/0xa)+-parseInt(_0x16debb(0x73))/0xb*(-parseInt(_0x16debb(0x76))/0xc);if(_0x516537===_0x471c7f)break;else _0x34f8c0['push'](_0x34f8c0['shift']());}catch(_0x3c7c27){_0x34f8c0['push'](_0x34f8c0['shift']());}}}(a81_0x362d,0xb9557));function a81_0x362d(){const _0x1f606d=['1896kOZNMF','130hqzOMR','appCode','sqlName','2240072LxkKTp','str','610424dLLMxu','2naxghd','785904UQOjQE','dbId','790461sBWzqS','read','sqlCode','930QYBCWH','Return\x20full\x20raw\x20SQL\x20query\x20object','3085362Xwvfit','verbose','sql','Get\x20custom\x20SQL\x20query\x20details\x20by\x20sqlCode','40422acsAnX','91eoaxyu','302599VgvDNV','bool','detail'];a81_0x362d=function(){return _0x1f606d;};return a81_0x362d();}import{getSqlQueryInfo}from'../../core/api-client.js';import{getDbName}from'../../core/db-resolver.js';import{SQLCODE_FLAG}from'../../commands/common/flags.js';function a81_0x1f12(_0x122dff,_0x318015){_0x122dff=_0x122dff-0x65;const _0x362d66=a81_0x362d();let _0x1f12c3=_0x362d66[_0x122dff];return _0x1f12c3;}export const sqlDetail={'service':a81_0x1a940a(0x6f),'command':a81_0x1a940a(0x75),'description':a81_0x1a940a(0x70),'risk':a81_0x1a940a(0x69),'flags':[SQLCODE_FLAG,{'name':a81_0x1a940a(0x6e),'type':'boolean','description':a81_0x1a940a(0x6c)}],async 'execute'(_0x52eb2d){const _0x1873fd=a81_0x1a940a,_0x58a117=await getSqlQueryInfo(_0x52eb2d[_0x1873fd(0x78)],_0x52eb2d[_0x1873fd(0x7b)]('sqlcode')),_0x54f203=_0x52eb2d[_0x1873fd(0x74)](_0x1873fd(0x6e));if(_0x54f203)return{'ok':!![],'data':_0x58a117};const _0xe2587=_0x58a117[_0x1873fd(0x67)]?await getDbName(_0x52eb2d[_0x1873fd(0x78)],_0x58a117['dbId']):undefined;return{'ok':!![],'data':{'sqlCode':_0x58a117[_0x1873fd(0x6a)],'sqlName':_0x58a117[_0x1873fd(0x79)],'db':_0xe2587?_0xe2587+'\x20('+_0x58a117[_0x1873fd(0x67)]+')':_0x58a117['dbId']??'','description':_0x58a117['description']??'','sqlContent':_0x58a117['sqlContent']??''}};}};
1
+ function a94_0x26bd(_0x936f7f,_0x3d9de8){_0x936f7f=_0x936f7f-0x1e1;const _0x227846=a94_0x2278();let _0x26bd48=_0x227846[_0x936f7f];return _0x26bd48;}const a94_0x1da972=a94_0x26bd;(function(_0x176ca8,_0x1f3f4b){const _0x1b43f1=a94_0x26bd,_0xab966=_0x176ca8();while(!![]){try{const _0x49676d=-parseInt(_0x1b43f1(0x1ec))/0x1*(parseInt(_0x1b43f1(0x1e9))/0x2)+parseInt(_0x1b43f1(0x1f1))/0x3+parseInt(_0x1b43f1(0x1f2))/0x4*(parseInt(_0x1b43f1(0x1f4))/0x5)+-parseInt(_0x1b43f1(0x1e7))/0x6*(parseInt(_0x1b43f1(0x1f5))/0x7)+parseInt(_0x1b43f1(0x1e3))/0x8+-parseInt(_0x1b43f1(0x1e5))/0x9*(-parseInt(_0x1b43f1(0x1e6))/0xa)+parseInt(_0x1b43f1(0x1f7))/0xb;if(_0x49676d===_0x1f3f4b)break;else _0xab966['push'](_0xab966['shift']());}catch(_0x4e36ee){_0xab966['push'](_0xab966['shift']());}}}(a94_0x2278,0xd135b));import{getSqlQueryInfo}from'../../core/api-client.js';import{getDbName}from'../../core/db-resolver.js';import{SQLCODE_FLAG}from'../../commands/common/flags.js';function a94_0x2278(){const _0x1d7dac=['read','bool','659BOYGOA','sqlName','boolean','verbose','str','2514162XPJSaS','1916hugNvs','Get\x20custom\x20SQL\x20query\x20details\x20by\x20sqlCode','1115KfUYAq','202916LptLeW','dbId','135432TbRfda','sqlContent','appCode','sql','5881304uyoBFe','description','5783634LBiQHJ','10YJUxvs','66JwHqII','sqlCode','3518KHyWMo'];a94_0x2278=function(){return _0x1d7dac;};return a94_0x2278();}export const sqlDetail={'service':a94_0x1da972(0x1e2),'command':'detail','description':a94_0x1da972(0x1f3),'risk':a94_0x1da972(0x1ea),'flags':[SQLCODE_FLAG,{'name':a94_0x1da972(0x1ef),'type':a94_0x1da972(0x1ee),'description':'Return\x20full\x20raw\x20SQL\x20query\x20object'}],async 'execute'(_0x1f441b){const _0x4bcd95=a94_0x1da972,_0x43eb54=await getSqlQueryInfo(_0x1f441b[_0x4bcd95(0x1e1)],_0x1f441b[_0x4bcd95(0x1f0)]('sqlcode')),_0x22328d=_0x1f441b[_0x4bcd95(0x1eb)]('verbose');if(_0x22328d)return{'ok':!![],'data':_0x43eb54};const _0x396ba1=_0x43eb54['dbId']?await getDbName(_0x1f441b[_0x4bcd95(0x1e1)],_0x43eb54[_0x4bcd95(0x1f6)]):undefined;return{'ok':!![],'data':{'sqlCode':_0x43eb54[_0x4bcd95(0x1e8)],'sqlName':_0x43eb54[_0x4bcd95(0x1ed)],'db':_0x396ba1?_0x396ba1+'\x20('+_0x43eb54[_0x4bcd95(0x1f6)]+')':_0x43eb54['dbId']??'','description':_0x43eb54[_0x4bcd95(0x1e4)]??'','sqlContent':_0x43eb54[_0x4bcd95(0x1f8)]??''}};}};
@@ -1 +1 @@
1
- const a82_0x1f848a=a82_0x3b3b;(function(_0xabb2d5,_0x7af4a5){const _0x5a7fdf=a82_0x3b3b,_0x368927=_0xabb2d5();while(!![]){try{const _0x1d65bb=parseInt(_0x5a7fdf(0x138))/0x1*(-parseInt(_0x5a7fdf(0x13b))/0x2)+-parseInt(_0x5a7fdf(0x134))/0x3+parseInt(_0x5a7fdf(0x139))/0x4+parseInt(_0x5a7fdf(0x137))/0x5*(-parseInt(_0x5a7fdf(0x130))/0x6)+-parseInt(_0x5a7fdf(0x133))/0x7*(parseInt(_0x5a7fdf(0x136))/0x8)+parseInt(_0x5a7fdf(0x131))/0x9+parseInt(_0x5a7fdf(0x12d))/0xa;if(_0x1d65bb===_0x7af4a5)break;else _0x368927['push'](_0x368927['shift']());}catch(_0x33510b){_0x368927['push'](_0x368927['shift']());}}}(a82_0x4ddc,0xc644a));function a82_0x3b3b(_0x4e6ca4,_0x1a6f30){_0x4e6ca4=_0x4e6ca4-0x126;const _0x4ddcb8=a82_0x4ddc();let _0x3b3bd0=_0x4ddcb8[_0x4e6ca4];return _0x3b3bd0;}function a82_0x4ddc(){const _0x383d30=['100270euCdHx','41AwUpik','3898760AWRJTr','\x20row(s)\x20in\x20','40410zstYZo','sqlcode','execError','parse','execResult','Invalid\x20JSON\x20for\x20--params:\x20','sql','length','execSuccess','str','string','now','validation','read','params','23277340qwKWoT','exec','SQL\x20execution\x20failed','138ZSbFey','7240176HGGmTH','isArray','1883YZCQkb','4660452xpyWcY','appCode','13432AhqiPo'];a82_0x4ddc=function(){return _0x383d30;};return a82_0x4ddc();}import{executeSql}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{SQLCODE_FLAG}from'../../commands/common/flags.js';export const sqlExec={'service':a82_0x1f848a(0x141),'command':a82_0x1f848a(0x12e),'description':'Execute\x20a\x20custom\x20SQL\x20query\x20by\x20sqlCode','risk':a82_0x1f848a(0x12b),'flags':[SQLCODE_FLAG,{'name':a82_0x1f848a(0x12c),'type':a82_0x1f848a(0x128),'description':'SQL\x20parameters\x20as\x20JSON\x20string\x20(e.g.\x20\x27{\x22key\x22:\x22value\x22}\x27)'}],async 'execute'(_0x346370){const _0x217af1=a82_0x1f848a;let _0x573f66;const _0xf07960=_0x346370[_0x217af1(0x127)](_0x217af1(0x12c));if(_0xf07960)try{_0x573f66=JSON[_0x217af1(0x13e)](_0xf07960);}catch{throw CliErrors[_0x217af1(0x12a)](_0x217af1(0x140)+_0xf07960);}const _0x185e11=Date[_0x217af1(0x129)](),_0x26e283=await executeSql(_0x346370[_0x217af1(0x135)],_0x346370[_0x217af1(0x127)](_0x217af1(0x13c)),_0x573f66),_0xc1ae4b=Date[_0x217af1(0x129)]()-_0x185e11,_0x38f99b=_0x26e283?.[_0x217af1(0x13f)]??_0x26e283,_0xe2d4b7=_0x26e283?.[_0x217af1(0x126)]??!![];if(!_0xe2d4b7)return{'ok':![],'data':{'error':_0x26e283?.[_0x217af1(0x13d)]||_0x217af1(0x12f),'elapsed':_0xc1ae4b},'message':_0x217af1(0x12f)};const _0x3ec59f=Array[_0x217af1(0x132)](_0x38f99b)?_0x38f99b:[];return{'ok':!![],'data':{'rows':_0x3ec59f,'rowCount':_0x3ec59f[_0x217af1(0x142)],'elapsed':_0xc1ae4b},'message':'Returned\x20'+_0x3ec59f[_0x217af1(0x142)]+_0x217af1(0x13a)+_0xc1ae4b+'ms'};}};
1
+ function a95_0x1104(){const _0x30e98a=['\x20row(s)\x20in\x20','12323707fMfXat','4111390gLiiqu','validation','str','params','sqlcode','execResult','9cRkILZ','SQL\x20parameters\x20as\x20JSON\x20string\x20(e.g.\x20\x27{\x22key\x22:\x22value\x22}\x27)','1853675RJryoJ','66XiJpxE','read','Returned\x20','3725634sfPcAk','14184WJxrIO','now','execSuccess','1472360YCUocG','1TNkJLb','Execute\x20a\x20custom\x20SQL\x20query\x20by\x20sqlCode','length','SQL\x20execution\x20failed','1897rqBkpq','exec','Invalid\x20JSON\x20for\x20--params:\x20','string','118004LUWwiW','isArray'];a95_0x1104=function(){return _0x30e98a;};return a95_0x1104();}const a95_0x3fc7f5=a95_0x258d;(function(_0x478fd4,_0x32c3ed){const _0xcfb78b=a95_0x258d,_0x3e37b=_0x478fd4();while(!![]){try{const _0xd863c8=-parseInt(_0xcfb78b(0xa0))/0x1*(-parseInt(_0xcfb78b(0x9f))/0x2)+parseInt(_0xcfb78b(0xb5))/0x3*(parseInt(_0xcfb78b(0xa8))/0x4)+-parseInt(_0xcfb78b(0xb4))/0x5+parseInt(_0xcfb78b(0x9b))/0x6+-parseInt(_0xcfb78b(0xa4))/0x7*(parseInt(_0xcfb78b(0x9c))/0x8)+parseInt(_0xcfb78b(0xb2))/0x9*(parseInt(_0xcfb78b(0xac))/0xa)+-parseInt(_0xcfb78b(0xab))/0xb;if(_0xd863c8===_0x32c3ed)break;else _0x3e37b['push'](_0x3e37b['shift']());}catch(_0x5d6aad){_0x3e37b['push'](_0x3e37b['shift']());}}}(a95_0x1104,0x6cd1d));import{executeSql}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{SQLCODE_FLAG}from'../../commands/common/flags.js';function a95_0x258d(_0x121351,_0x215f20){_0x121351=_0x121351-0x99;const _0x110418=a95_0x1104();let _0x258d0a=_0x110418[_0x121351];return _0x258d0a;}export const sqlExec={'service':'sql','command':a95_0x3fc7f5(0xa5),'description':a95_0x3fc7f5(0xa1),'risk':a95_0x3fc7f5(0x99),'flags':[SQLCODE_FLAG,{'name':'params','type':a95_0x3fc7f5(0xa7),'description':a95_0x3fc7f5(0xb3)}],async 'execute'(_0x2bab28){const _0x5701b2=a95_0x3fc7f5;let _0x4417c2;const _0xed554d=_0x2bab28[_0x5701b2(0xae)](_0x5701b2(0xaf));if(_0xed554d)try{_0x4417c2=JSON['parse'](_0xed554d);}catch{throw CliErrors[_0x5701b2(0xad)](_0x5701b2(0xa6)+_0xed554d);}const _0x245f38=Date[_0x5701b2(0x9d)](),_0xaa5d8=await executeSql(_0x2bab28['appCode'],_0x2bab28['str'](_0x5701b2(0xb0)),_0x4417c2),_0x2574d3=Date['now']()-_0x245f38,_0x21af17=_0xaa5d8?.[_0x5701b2(0xb1)]??_0xaa5d8,_0x3f6a81=_0xaa5d8?.[_0x5701b2(0x9e)]??!![];if(!_0x3f6a81)return{'ok':![],'data':{'error':_0xaa5d8?.['execError']||_0x5701b2(0xa3),'elapsed':_0x2574d3},'message':_0x5701b2(0xa3)};const _0x2ec914=Array[_0x5701b2(0xa9)](_0x21af17)?_0x21af17:[];return{'ok':!![],'data':{'rows':_0x2ec914,'rowCount':_0x2ec914[_0x5701b2(0xa2)],'elapsed':_0x2574d3},'message':_0x5701b2(0x9a)+_0x2ec914[_0x5701b2(0xa2)]+_0x5701b2(0xaa)+_0x2574d3+'ms'};}};
@@ -1 +1 @@
1
- (function(_0x595028,_0x394fbf){const _0x1ffe94=a83_0x2c70,_0x2310e9=_0x595028();while(!![]){try{const _0x357430=-parseInt(_0x1ffe94(0x99))/0x1*(-parseInt(_0x1ffe94(0x9c))/0x2)+parseInt(_0x1ffe94(0x97))/0x3+-parseInt(_0x1ffe94(0x9d))/0x4+parseInt(_0x1ffe94(0x9f))/0x5*(-parseInt(_0x1ffe94(0x9b))/0x6)+-parseInt(_0x1ffe94(0x9e))/0x7+-parseInt(_0x1ffe94(0x98))/0x8*(parseInt(_0x1ffe94(0x96))/0x9)+-parseInt(_0x1ffe94(0x9a))/0xa*(-parseInt(_0x1ffe94(0xa0))/0xb);if(_0x357430===_0x394fbf)break;else _0x2310e9['push'](_0x2310e9['shift']());}catch(_0x399e24){_0x2310e9['push'](_0x2310e9['shift']());}}}(a83_0x259b,0xa053f));import{sqlList}from'../../commands/sql/list.js';import{sqlDetail}from'../../commands/sql/detail.js';function a83_0x259b(){const _0x14e30c=['44axegRZ','2310516OaSjiH','1394499LuHcni','32SlrpUG','40088KMfFmU','4945850YDnNCL','732DHnsxR','58yoxzIE','3247676cPEBXY','1176007WTFpyx','38615ytrphW'];a83_0x259b=function(){return _0x14e30c;};return a83_0x259b();}import{sqlValidate}from'../../commands/sql/validate.js';function a83_0x2c70(_0x1a47c0,_0x1c9192){_0x1a47c0=_0x1a47c0-0x96;const _0x259b54=a83_0x259b();let _0x2c70c1=_0x259b54[_0x1a47c0];return _0x2c70c1;}import{sqlSave}from'../../commands/sql/save.js';import{sqlExec}from'../../commands/sql/exec.js';export const sqlDefinitions=[sqlList,sqlDetail,sqlValidate,sqlSave,sqlExec];
1
+ (function(_0x1966ed,_0x27fa14){const _0x15cbdb=a96_0xb6b5,_0x433caf=_0x1966ed();while(!![]){try{const _0x26a9ee=-parseInt(_0x15cbdb(0xc0))/0x1+parseInt(_0x15cbdb(0xbf))/0x2+-parseInt(_0x15cbdb(0xc5))/0x3+parseInt(_0x15cbdb(0xc4))/0x4*(parseInt(_0x15cbdb(0xc1))/0x5)+parseInt(_0x15cbdb(0xc6))/0x6+-parseInt(_0x15cbdb(0xc2))/0x7+parseInt(_0x15cbdb(0xc3))/0x8;if(_0x26a9ee===_0x27fa14)break;else _0x433caf['push'](_0x433caf['shift']());}catch(_0x5b2474){_0x433caf['push'](_0x433caf['shift']());}}}(a96_0x45c8,0x9d313));import{sqlList}from'../../commands/sql/list.js';import{sqlDetail}from'../../commands/sql/detail.js';import{sqlValidate}from'../../commands/sql/validate.js';import{sqlSave}from'../../commands/sql/save.js';import{sqlExec}from'../../commands/sql/exec.js';function a96_0xb6b5(_0x41d2b3,_0x2f89ff){_0x41d2b3=_0x41d2b3-0xbf;const _0x45c88a=a96_0x45c8();let _0xb6b508=_0x45c88a[_0x41d2b3];return _0xb6b508;}import{sqlPull}from'../../commands/sql/pull.js';export const sqlDefinitions=[sqlList,sqlDetail,sqlValidate,sqlSave,sqlExec,sqlPull];function a96_0x45c8(){const _0x17900e=['1792406ULgQzV','573674NAhCeW','195ZdWJti','7997234zLdnhz','2285952niTwer','115084tQNbvu','938220sYwgrl','2212314KXkUog'];a96_0x45c8=function(){return _0x17900e;};return a96_0x45c8();}
@@ -1 +1 @@
1
- const a84_0x5a281a=a84_0x1226;(function(_0x188f75,_0x5e814f){const _0x494d9b=a84_0x1226,_0x55676c=_0x188f75();while(!![]){try{const _0x4e4328=parseInt(_0x494d9b(0xdb))/0x1+parseInt(_0x494d9b(0xd3))/0x2*(parseInt(_0x494d9b(0xcc))/0x3)+parseInt(_0x494d9b(0xdd))/0x4+parseInt(_0x494d9b(0xe3))/0x5+-parseInt(_0x494d9b(0xd4))/0x6+parseInt(_0x494d9b(0xe0))/0x7+-parseInt(_0x494d9b(0xcf))/0x8;if(_0x4e4328===_0x5e814f)break;else _0x55676c['push'](_0x55676c['shift']());}catch(_0x3e27c8){_0x55676c['push'](_0x55676c['shift']());}}}(a84_0x4b73,0xc100e));import{listSqlQueries}from'../../core/api-client.js';import{getDbName}from'../../core/db-resolver.js';import{SQLCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function a84_0x1226(_0x1be0d3,_0x1b1a04){_0x1be0d3=_0x1be0d3-0xcb;const _0x4b73d8=a84_0x4b73();let _0x1226c6=_0x4b73d8[_0x1be0d3];return _0x1226c6;}function a84_0x4b73(){const _0x2213b6=['totalCount','verbose','577560rkVtuI','boolean','all','12268160zJcyeN','appCode','name','str','6mJMxpt','5683866ONyvGl','read','length','Page\x20size','list','sqlcode','sqlCode','191293WWzrZG','page','379220BbRoOm','pagesize','List\x20custom\x20SQL\x20queries','8917832ylmjyM','number','num','5668695WDCEes','sql','Filter\x20by\x20SQL\x20name','paging','description','map','bool','Return\x20full\x20SQL\x20query\x20objects\x20including\x20parameters\x20and\x20SQL\x20content','\x20SQL\x20queries\x20(total:\x20','tableData','dbId'];a84_0x4b73=function(){return _0x2213b6;};return a84_0x4b73();}export const sqlList={'service':a84_0x5a281a(0xe4),'command':a84_0x5a281a(0xd8),'description':a84_0x5a281a(0xdf),'risk':a84_0x5a281a(0xd5),'flags':[SQLCODE_FLAG_OPTIONAL,{'name':a84_0x5a281a(0xd1),'type':'string','description':a84_0x5a281a(0xe5)},{'name':a84_0x5a281a(0xdc),'type':a84_0x5a281a(0xe1),'description':'Page\x20number','default':0x1},{'name':a84_0x5a281a(0xde),'type':'number','description':a84_0x5a281a(0xd7)},{'name':'verbose','type':a84_0x5a281a(0xcd),'description':a84_0x5a281a(0xea)}],async 'execute'(_0x4adbdf){const _0x2cf8ad=a84_0x5a281a,_0x385bf5=await listSqlQueries(_0x4adbdf[_0x2cf8ad(0xd0)],{'sqlCode':_0x4adbdf[_0x2cf8ad(0xd2)](_0x2cf8ad(0xd9))||undefined,'sqlName':_0x4adbdf[_0x2cf8ad(0xd2)]('name')||undefined,'currentPage':_0x4adbdf[_0x2cf8ad(0xe2)](_0x2cf8ad(0xdc)),'pageSize':_0x4adbdf['num'](_0x2cf8ad(0xde),0x32)}),_0x589be1=_0x4adbdf[_0x2cf8ad(0xe9)](_0x2cf8ad(0xcb)),_0x2c694d=_0x385bf5[_0x2cf8ad(0xec)]??[],_0x4269eb=_0x385bf5[_0x2cf8ad(0xe6)]?.[_0x2cf8ad(0xee)]??_0x2c694d[_0x2cf8ad(0xd6)];let _0x2263dd;return _0x589be1?_0x2263dd=_0x2c694d:_0x2263dd=await Promise[_0x2cf8ad(0xce)](_0x2c694d[_0x2cf8ad(0xe8)](async _0x592d4d=>{const _0x335370=_0x2cf8ad,_0x39c31f=_0x592d4d[_0x335370(0xed)]?await getDbName(_0x4adbdf[_0x335370(0xd0)],_0x592d4d[_0x335370(0xed)]):undefined;return{'sqlCode':_0x592d4d[_0x335370(0xda)],'sqlName':_0x592d4d['sqlName'],'description':_0x592d4d[_0x335370(0xe7)]??'','db':_0x39c31f?_0x39c31f+'\x20('+_0x592d4d[_0x335370(0xed)]+')':_0x592d4d[_0x335370(0xed)]??''};})),{'ok':!![],'data':_0x2263dd,'message':_0x2c694d[_0x2cf8ad(0xd6)]===0x0?'No\x20custom\x20SQL\x20queries\x20found.':'Found\x20'+_0x2c694d[_0x2cf8ad(0xd6)]+_0x2cf8ad(0xeb)+_0x4269eb+').'};}};
1
+ function a97_0x1c03(_0x5d72ac,_0x4b1f5c){_0x5d72ac=_0x5d72ac-0x100;const _0x48a05d=a97_0x48a0();let _0x1c0387=_0x48a05d[_0x5d72ac];return _0x1c0387;}const a97_0x809ae6=a97_0x1c03;function a97_0x48a0(){const _0xfc7666=['read','list','all','3342402uVAzBK','108yCpflx','365018IXynoC','Found\x20','appCode','sqlcode','pagesize','map','length','\x20SQL\x20queries\x20(total:\x20','bool','Page\x20number','page','235470cNqHhu','List\x20custom\x20SQL\x20queries','Page\x20size','name','str','num','260748geTWsK','boolean','dbId','216uJeTMX','number','totalCount','sqlCode','string','310891eCOfAq','7erjGbO','4951296HgbfEJ','4012045BlyBkV','No\x20custom\x20SQL\x20queries\x20found.'];a97_0x48a0=function(){return _0xfc7666;};return a97_0x48a0();}(function(_0x282b4c,_0x1e70e4){const _0x42efa3=a97_0x1c03,_0x1dd8dc=_0x282b4c();while(!![]){try{const _0xb88571=parseInt(_0x42efa3(0x102))/0x1*(-parseInt(_0x42efa3(0x10b))/0x2)+parseInt(_0x42efa3(0x103))/0x3+parseInt(_0x42efa3(0x11c))/0x4+parseInt(_0x42efa3(0x104))/0x5+parseInt(_0x42efa3(0x109))/0x6+parseInt(_0x42efa3(0x101))/0x7*(-parseInt(_0x42efa3(0x11f))/0x8)+parseInt(_0x42efa3(0x10a))/0x9*(parseInt(_0x42efa3(0x116))/0xa);if(_0xb88571===_0x1e70e4)break;else _0x1dd8dc['push'](_0x1dd8dc['shift']());}catch(_0x1b710f){_0x1dd8dc['push'](_0x1dd8dc['shift']());}}}(a97_0x48a0,0xd7131));import{listSqlQueries}from'../../core/api-client.js';import{getDbName}from'../../core/db-resolver.js';import{SQLCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';export const sqlList={'service':'sql','command':a97_0x809ae6(0x107),'description':a97_0x809ae6(0x117),'risk':a97_0x809ae6(0x106),'flags':[SQLCODE_FLAG_OPTIONAL,{'name':a97_0x809ae6(0x119),'type':a97_0x809ae6(0x100),'description':'Filter\x20by\x20SQL\x20name'},{'name':a97_0x809ae6(0x115),'type':a97_0x809ae6(0x120),'description':a97_0x809ae6(0x114),'default':0x1},{'name':a97_0x809ae6(0x10f),'type':a97_0x809ae6(0x120),'description':a97_0x809ae6(0x118)},{'name':'verbose','type':a97_0x809ae6(0x11d),'description':'Return\x20full\x20SQL\x20query\x20objects\x20including\x20parameters\x20and\x20SQL\x20content'}],async 'execute'(_0x358662){const _0x1b4e12=a97_0x809ae6,_0x2c0505=await listSqlQueries(_0x358662[_0x1b4e12(0x10d)],{'sqlCode':_0x358662['str'](_0x1b4e12(0x10e))||undefined,'sqlName':_0x358662[_0x1b4e12(0x11a)]('name')||undefined,'currentPage':_0x358662[_0x1b4e12(0x11b)](_0x1b4e12(0x115)),'pageSize':_0x358662[_0x1b4e12(0x11b)](_0x1b4e12(0x10f),0x32)}),_0x325da7=_0x358662[_0x1b4e12(0x113)]('verbose'),_0x2aaa12=_0x2c0505['tableData']??[],_0x17b433=_0x2c0505['paging']?.[_0x1b4e12(0x121)]??_0x2aaa12['length'];let _0x27ab18;return _0x325da7?_0x27ab18=_0x2aaa12:_0x27ab18=await Promise[_0x1b4e12(0x108)](_0x2aaa12[_0x1b4e12(0x110)](async _0x46bfe9=>{const _0x173248=_0x1b4e12;let _0x621853;try{_0x621853=_0x46bfe9[_0x173248(0x11e)]?await getDbName(_0x358662['appCode'],_0x46bfe9[_0x173248(0x11e)]):undefined;}catch{}return{'sqlCode':_0x46bfe9[_0x173248(0x122)],'sqlName':_0x46bfe9['sqlName'],'description':_0x46bfe9['description']??'','db':_0x621853?_0x621853+'\x20('+_0x46bfe9['dbId']+')':_0x46bfe9['dbId']??''};})),{'ok':!![],'data':_0x27ab18,'message':_0x2aaa12[_0x1b4e12(0x111)]===0x0?_0x1b4e12(0x105):_0x1b4e12(0x10c)+_0x2aaa12[_0x1b4e12(0x111)]+_0x1b4e12(0x112)+_0x17b433+').'};}};
@@ -0,0 +1 @@
1
+ const a98_0x1e53eb=a98_0x2fe6;(function(_0x2767bf,_0x5a1003){const _0x455bb8=a98_0x2fe6,_0x5125df=_0x2767bf();while(!![]){try{const _0x2f5bbf=parseInt(_0x455bb8(0x94))/0x1*(parseInt(_0x455bb8(0x77))/0x2)+parseInt(_0x455bb8(0xa4))/0x3*(-parseInt(_0x455bb8(0x75))/0x4)+parseInt(_0x455bb8(0x81))/0x5+parseInt(_0x455bb8(0x98))/0x6+-parseInt(_0x455bb8(0x74))/0x7*(-parseInt(_0x455bb8(0x80))/0x8)+parseInt(_0x455bb8(0x79))/0x9+-parseInt(_0x455bb8(0xa3))/0xa;if(_0x2f5bbf===_0x5a1003)break;else _0x5125df['push'](_0x5125df['shift']());}catch(_0x12c344){_0x5125df['push'](_0x5125df['shift']());}}}(a98_0x103c,0x567af));import{createInterface}from'node:readline';import{readFile,writeFile}from'node:fs/promises';function a98_0x103c(){const _0x205480=['stdin','totalCount','3126582WzPSkM','stderr','Force\x20pull\x20will\x20overwrite\x20local\x20SQL\x20that\x20differs\x20from\x20remote.\x20Continue?\x20[y/N]\x20','push','yes','No\x20remote\x20SQL\x20queries\x20matched.','sqlcode','str','Filter\x20by\x20SQL\x20display\x20name\x20(API\x20filter)','sqlContent','tableData','6973380hndsid','3OffxfT','length','unchanged','local\x20differs\x20from\x20remote\x20(use\x20--force\x20to\x20overwrite)','bool','\x20SQL\x20file(s)\x20under\x20','530726srqFNY','2388972MbAUQE','\x20written,\x20','81850TQAajM','name','2637306pQhVoY','pull','\x20error(s)).','message','boolean','utf8','sqlCode','48JviVPA','57200dhYEMy','includes','skipped','string','toLowerCase','cancelled','conflict','Would\x20pull\x20','close','local\x20differs\x20from\x20remote','Pull\x20failed:\x20could\x20not\x20load\x20SQL\x20content\x20(','force','nonInteractive','Pull\x20complete:\x20','would_pull','POST','question','sqlName','appCode','9mptLka','/smartapi/custom/queryUserCustomSqlList'];a98_0x103c=function(){return _0x205480;};return a98_0x103c();}import{join}from'node:path';import{getSqlQueryInfo,listSqlQueries}from'../../core/api-client.js';import{ensureParentDirectory,fileExists}from'../../core/bff/file-system.js';import{findProjectRootDirectory}from'../../context.js';import{assignSqlFileNames,buildPulledSqlFileContent,resolveSqlLocalDir}from'../../commands/sql/shared.js';import{CliErrors}from'../../errors.js';import{SQLCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function a98_0x2fe6(_0x19e590,_0x57c9d1){_0x19e590=_0x19e590-0x73;const _0x103c0e=a98_0x103c();let _0x2fe6da=_0x103c0e[_0x19e590];return _0x2fe6da;}const PAGE_SIZE=0x64;async function fetchAllSqlQueries(_0x3fcce9,_0x46b035){const _0x1cdd27=a98_0x2fe6,_0x43930c=[];let _0x130cd3=0x1;while(!![]){const _0x501cec=await listSqlQueries(_0x3fcce9,{'currentPage':_0x130cd3,'pageSize':PAGE_SIZE,'sqlCode':_0x46b035[_0x1cdd27(0x7f)],'sqlName':_0x46b035[_0x1cdd27(0x92)]}),_0x474a9c=_0x501cec[_0x1cdd27(0xa2)]??[];_0x43930c['push'](..._0x474a9c);if(_0x474a9c[_0x1cdd27(0xa5)]===0x0)break;const _0x10619c=_0x501cec['paging']?.[_0x1cdd27(0x97)];if(_0x10619c!=null?_0x43930c['length']>=_0x10619c:_0x474a9c['length']<PAGE_SIZE)break;_0x130cd3++;}return _0x43930c;}async function ensureSqlContent(_0x12f517,_0x96f4c7){const _0x4e076e=a98_0x2fe6;if(_0x96f4c7[_0x4e076e(0xa1)]!=null&&String(_0x96f4c7[_0x4e076e(0xa1)])['length']>0x0)return _0x96f4c7;return getSqlQueryInfo(_0x12f517,_0x96f4c7['sqlCode']);}export const sqlPull={'service':'sql','command':a98_0x1e53eb(0x7a),'description':'Pull\x20remote\x20custom\x20SQL\x20queries\x20into\x20.rabetbase/sql/','risk':'write','flags':[SQLCODE_FLAG_OPTIONAL,{'name':'name','type':a98_0x1e53eb(0x84),'description':a98_0x1e53eb(0xa0)},{'name':a98_0x1e53eb(0x8c),'type':a98_0x1e53eb(0x7d),'description':'Overwrite\x20local\x20files\x20that\x20differ\x20from\x20remote'}],async 'dryRun'(_0x384bc4){const _0x3b3abb=a98_0x1e53eb,_0x25a3bd=findProjectRootDirectory(),_0x30f01d=resolveSqlLocalDir(_0x25a3bd),_0x2fd59f=_0x384bc4[_0x3b3abb(0x9f)](_0x3b3abb(0x9e))||undefined,_0x476bbf=_0x384bc4[_0x3b3abb(0x9f)](_0x3b3abb(0x78))||undefined,_0x160f29=await fetchAllSqlQueries(_0x384bc4[_0x3b3abb(0x93)],{'sqlCode':_0x2fd59f,'sqlName':_0x476bbf}),_0x1b2d74=[],_0x57d1ea=[];for(const _0x869770 of _0x160f29){try{_0x1b2d74[_0x3b3abb(0x9b)](await ensureSqlContent(_0x384bc4[_0x3b3abb(0x93)],_0x869770));}catch(_0x1f0072){_0x57d1ea[_0x3b3abb(0x9b)]({'sqlCode':_0x869770[_0x3b3abb(0x7f)],'error':_0x1f0072 instanceof Error?_0x1f0072['message']:String(_0x1f0072)});}}const _0x17ecd8=assignSqlFileNames(_0x1b2d74),_0x88113c=[];for(const [_0x48700d,_0x2f07e7]of _0x17ecd8){const _0x50daf2=join(_0x30f01d,_0x48700d),_0x197be4=buildPulledSqlFileContent(_0x2f07e7);let _0x26e0d2=_0x3b3abb(0x8f),_0x37217d;if(await fileExists(_0x50daf2)){const _0x2a0b1a=await readFile(_0x50daf2,_0x3b3abb(0x7e));_0x2a0b1a===_0x197be4?(_0x26e0d2=_0x3b3abb(0x83),_0x37217d=_0x3b3abb(0xa6)):(_0x26e0d2=_0x3b3abb(0x87),_0x37217d=_0x3b3abb(0xa7));}_0x88113c['push']({'sqlCode':_0x2f07e7[_0x3b3abb(0x7f)],'sqlName':_0x2f07e7['sqlName'],'filePath':_0x50daf2,'status':_0x26e0d2,'reason':_0x37217d});}return{'method':_0x3b3abb(0x90),'url':_0x3b3abb(0x95),'body':{'appCode':_0x384bc4[_0x3b3abb(0x93)],'sqlCode':_0x2fd59f??null,'sqlName':_0x476bbf??null,'loadErrors':_0x57d1ea,'files':_0x88113c},'description':_0x3b3abb(0x88)+_0x88113c[_0x3b3abb(0xa5)]+_0x3b3abb(0x73)+_0x30f01d};},async 'execute'(_0x170821){const _0x1a9520=a98_0x1e53eb,_0x256b51=findProjectRootDirectory(),_0x2f26c5=resolveSqlLocalDir(_0x256b51),_0x1a71cd=_0x170821[_0x1a9520(0x9f)]('sqlcode')||undefined,_0x33dc87=_0x170821[_0x1a9520(0x9f)]('name')||undefined,_0x52a7d3=_0x170821[_0x1a9520(0xa8)](_0x1a9520(0x8c)),_0x590b83=await fetchAllSqlQueries(_0x170821['appCode'],{'sqlCode':_0x1a71cd,'sqlName':_0x33dc87});if(_0x590b83[_0x1a9520(0xa5)]===0x0)return{'ok':!![],'data':{'pulled':[],'skipped':[],'failed':[]},'message':_0x1a9520(0x9d)};const _0x4e07e4=[],_0x4ef0c2=[];for(const _0x1e2f9f of _0x590b83){try{_0x4e07e4[_0x1a9520(0x9b)](await ensureSqlContent(_0x170821[_0x1a9520(0x93)],_0x1e2f9f));}catch(_0x1a6690){_0x4ef0c2['push']({'sqlCode':_0x1e2f9f[_0x1a9520(0x7f)],'error':_0x1a6690 instanceof Error?_0x1a6690[_0x1a9520(0x7c)]:String(_0x1a6690)});}}if(_0x4e07e4[_0x1a9520(0xa5)]===0x0)return{'ok':![],'data':{'pulled':[],'skipped':[],'failed':_0x4ef0c2},'message':_0x1a9520(0x8b)+_0x4ef0c2[_0x1a9520(0xa5)]+_0x1a9520(0x7b)};const _0x6ae284=assignSqlFileNames(_0x4e07e4);if(_0x52a7d3&&!_0x170821[_0x1a9520(0x8d)]){let _0x4c14e4=![];for(const [_0x595b8b,_0x5a43ca]of _0x6ae284){const _0x3e4055=join(_0x2f26c5,_0x595b8b),_0x35d6c8=buildPulledSqlFileContent(_0x5a43ca);if(await fileExists(_0x3e4055)){const _0x4266f2=await readFile(_0x3e4055,_0x1a9520(0x7e));if(_0x4266f2!==_0x35d6c8){_0x4c14e4=!![];break;}}}if(_0x4c14e4){const _0x489d21=await confirmForce();if(!_0x489d21)throw CliErrors[_0x1a9520(0x86)]('Force\x20pull\x20cancelled.');}}const _0x1ced77=[],_0x26eb8b=[];for(const [_0x50e9d3,_0x283837]of _0x6ae284){const _0x2b6b3e=join(_0x2f26c5,_0x50e9d3),_0x4228a6=buildPulledSqlFileContent(_0x283837);try{if(await fileExists(_0x2b6b3e)){const _0x53fcac=await readFile(_0x2b6b3e,_0x1a9520(0x7e));if(_0x53fcac===_0x4228a6){_0x26eb8b[_0x1a9520(0x9b)]({'sqlCode':_0x283837[_0x1a9520(0x7f)],'reason':_0x1a9520(0xa6)});continue;}if(!_0x52a7d3){_0x26eb8b[_0x1a9520(0x9b)]({'sqlCode':_0x283837['sqlCode'],'reason':_0x1a9520(0x8a)});continue;}}await ensureParentDirectory(_0x2b6b3e),await writeFile(_0x2b6b3e,_0x4228a6,_0x1a9520(0x7e)),_0x1ced77[_0x1a9520(0x9b)]({'sqlCode':_0x283837[_0x1a9520(0x7f)],'filePath':_0x2b6b3e});}catch(_0x492f3d){_0x4ef0c2[_0x1a9520(0x9b)]({'sqlCode':_0x283837[_0x1a9520(0x7f)],'error':_0x492f3d instanceof Error?_0x492f3d[_0x1a9520(0x7c)]:String(_0x492f3d)});}}const _0x5c894c=_0x4ef0c2[_0x1a9520(0xa5)]===0x0;return{'ok':_0x5c894c,'data':{'pulled':_0x1ced77,'skipped':_0x26eb8b,'failed':_0x4ef0c2},'message':_0x1a9520(0x8e)+_0x1ced77[_0x1a9520(0xa5)]+_0x1a9520(0x76)+_0x26eb8b[_0x1a9520(0xa5)]+'\x20skipped,\x20'+_0x4ef0c2[_0x1a9520(0xa5)]+'\x20failed'};}};async function confirmForce(){const _0x13c003=a98_0x1e53eb,_0x58a906=createInterface({'input':process[_0x13c003(0x96)],'output':process[_0x13c003(0x99)]}),_0x1da952=await new Promise(_0x263b94=>{const _0x352d36=_0x13c003;_0x58a906[_0x352d36(0x91)](_0x352d36(0x9a),_0x263b94);});return _0x58a906[_0x13c003(0x89)](),['y',_0x13c003(0x9c)][_0x13c003(0x82)](_0x1da952['trim']()[_0x13c003(0x85)]());}
@@ -1 +1 @@
1
- const a85_0x48c8be=a85_0xbba2;(function(_0x10009e,_0x516a3e){const _0x5829c2=a85_0xbba2,_0x28e64f=_0x10009e();while(!![]){try{const _0x452c22=-parseInt(_0x5829c2(0x198))/0x1*(parseInt(_0x5829c2(0x1a4))/0x2)+parseInt(_0x5829c2(0x18a))/0x3+-parseInt(_0x5829c2(0x1b2))/0x4+parseInt(_0x5829c2(0x1b0))/0x5+-parseInt(_0x5829c2(0x1a5))/0x6*(parseInt(_0x5829c2(0x1a2))/0x7)+-parseInt(_0x5829c2(0x18f))/0x8+-parseInt(_0x5829c2(0x189))/0x9*(-parseInt(_0x5829c2(0x1a9))/0xa);if(_0x452c22===_0x516a3e)break;else _0x28e64f['push'](_0x28e64f['shift']());}catch(_0x7bd7cf){_0x28e64f['push'](_0x28e64f['shift']());}}}(a85_0x4811,0x2ec5d));function a85_0x4811(){const _0x533d81=['sqlcode','Path\x20to\x20the\x20SQL\x20file','95855kGcsff','dbId','821040axcgjS','type','action','\x20|\x20Params:\x20','string','SQL\x20query\x20description','sqlType','join','SQL\x20query\x20display\x20name','valid','Save\x20or\x20update\x20a\x20custom\x20SQL\x20query\x20(validates\x20before\x20saving)','1305aHFnig','158037YJpWsk','none','\x20chars)','str','\x20|\x20Tables:\x20','338728sOPdYT','dbName','Conflict\x20detected','Created','sqlCode','POST','Target\x20database\x20—\x20accepts\x20a\x20numeric\x20ID\x20or\x20database\x20name\x20(e.g.\x20ecommerce_db)','/api/node-toolbox/sql/save','appCode','92275mplcxj','file','N/A','save','tables','validation','utf-8','message','Updated','SQL\x20validation\x20failed:\x20','91taOQdM','sqlname','6hmCXGc','172296swkTGP','\x20successfully','sql','parameters','70170ZdxoAO','cwd','blocked','Type:\x20','write'];a85_0x4811=function(){return _0x533d81;};return a85_0x4811();}import{readFileSync,existsSync}from'node:fs';import{resolve}from'node:path';import{saveSqlQuery}from'../../core/api-client.js';import{resolveOneDb}from'../../core/db-resolver.js';import{validateSql}from'../../core/sql-validator.js';import{CliErrors}from'../../errors.js';function a85_0xbba2(_0x1f105e,_0xe29520){_0x1f105e=_0x1f105e-0x185;const _0x481116=a85_0x4811();let _0xbba24b=_0x481116[_0x1f105e];return _0xbba24b;}import{SQLCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';export const sqlSave={'service':a85_0x48c8be(0x1a7),'command':a85_0x48c8be(0x19b),'description':a85_0x48c8be(0x188),'risk':a85_0x48c8be(0x1ad),'flags':[{'name':a85_0x48c8be(0x199),'type':a85_0x48c8be(0x1b6),'required':!![],'description':a85_0x48c8be(0x1af)},SQLCODE_FLAG_OPTIONAL,{'name':a85_0x48c8be(0x1a3),'type':'string','description':a85_0x48c8be(0x186)},{'name':'db','type':a85_0x48c8be(0x1b6),'description':a85_0x48c8be(0x195)},{'name':'description','type':a85_0x48c8be(0x1b6),'description':a85_0x48c8be(0x1b7)}],async 'validate'(_0x13cb19){const _0x1c433b=a85_0x48c8be,_0x4e01d3=resolve(process[_0x1c433b(0x1aa)](),_0x13cb19[_0x1c433b(0x18d)](_0x1c433b(0x199)));if(!existsSync(_0x4e01d3))throw CliErrors[_0x1c433b(0x19d)]('File\x20not\x20found:\x20'+_0x4e01d3);const _0xc307e8=readFileSync(_0x4e01d3,'utf-8'),_0x3c79cc=validateSql(_0xc307e8);if(!_0x3c79cc[_0x1c433b(0x187)])throw CliErrors[_0x1c433b(0x19d)](_0x1c433b(0x1a1)+_0x3c79cc['message']);},async 'dryRun'(_0x44c2ce){const _0x4dfd93=a85_0x48c8be,_0x5bda32=resolve(process[_0x4dfd93(0x1aa)](),_0x44c2ce[_0x4dfd93(0x18d)]('file')),_0x596735=readFileSync(_0x5bda32,_0x4dfd93(0x19e)),_0x42550e=validateSql(_0x596735),_0x2ef34b=_0x44c2ce[_0x4dfd93(0x18d)]('db')||undefined,{db:_0x16197f,error:_0x546e4a}=await resolveOneDb(_0x44c2ce['appCode'],_0x2ef34b);return{'method':_0x4dfd93(0x194),'url':_0x4dfd93(0x196),'body':{'appCode':_0x44c2ce['appCode'],'sqlContent':'('+_0x596735['length']+_0x4dfd93(0x18c),'sqlCode':_0x44c2ce[_0x4dfd93(0x18d)](_0x4dfd93(0x1ae))||undefined,'sqlName':_0x44c2ce[_0x4dfd93(0x18d)](_0x4dfd93(0x1a3))||undefined,'db':_0x16197f?_0x16197f[_0x4dfd93(0x190)]+'\x20('+_0x16197f[_0x4dfd93(0x1b1)]+')':_0x546e4a},'description':['Save\x20SQL\x20query\x20from\x20'+_0x44c2ce[_0x4dfd93(0x18d)](_0x4dfd93(0x199)),'Validation:\x20'+_0x42550e[_0x4dfd93(0x19f)],_0x4dfd93(0x1ac)+_0x42550e[_0x4dfd93(0x1b8)][_0x4dfd93(0x1b3)]+_0x4dfd93(0x18e)+(_0x42550e[_0x4dfd93(0x19c)][_0x4dfd93(0x185)](',\x20')||_0x4dfd93(0x19a))+_0x4dfd93(0x1b5)+(_0x42550e[_0x4dfd93(0x1a8)]['join'](',\x20')||_0x4dfd93(0x18b))][_0x4dfd93(0x185)]('\x0a')};},async 'execute'(_0x5152c7){const _0x3c4cb6=a85_0x48c8be,_0x58dfad=resolve(process['cwd'](),_0x5152c7[_0x3c4cb6(0x18d)](_0x3c4cb6(0x199))),_0x118460=readFileSync(_0x58dfad,'utf-8'),_0x1902f5=_0x5152c7[_0x3c4cb6(0x18d)]('db')||undefined,{db:_0x4c7016,error:_0x369009}=await resolveOneDb(_0x5152c7[_0x3c4cb6(0x197)],_0x1902f5);if(_0x369009)throw CliErrors[_0x3c4cb6(0x19d)](_0x369009);const _0x101b6a=await saveSqlQuery({'appCode':_0x5152c7['appCode'],'sqlContent':_0x118460,'sqlCode':_0x5152c7[_0x3c4cb6(0x18d)]('sqlcode')||undefined,'sqlName':_0x5152c7[_0x3c4cb6(0x18d)]('sqlname')||undefined,'dbId':_0x4c7016[_0x3c4cb6(0x1b1)],'description':_0x5152c7[_0x3c4cb6(0x18d)]('description')||undefined});if(_0x101b6a[_0x3c4cb6(0x1ab)])return{'ok':![],'data':_0x101b6a,'message':_0x101b6a['message']||_0x3c4cb6(0x191)};return{'ok':!![],'data':{'sqlCode':_0x101b6a[_0x3c4cb6(0x193)],'sqlName':_0x101b6a['sqlName'],'action':_0x101b6a[_0x3c4cb6(0x1b4)]},'message':(_0x101b6a[_0x3c4cb6(0x1b4)]==='created'?_0x3c4cb6(0x192):_0x3c4cb6(0x1a0))+_0x3c4cb6(0x1a6)+(_0x101b6a[_0x3c4cb6(0x193)]?'\x20('+_0x101b6a['sqlCode']+')':'')};}};
1
+ const a99_0x217d19=a99_0x190a;(function(_0x58ed87,_0x31348a){const _0x388edb=a99_0x190a,_0x5ac41f=_0x58ed87();while(!![]){try{const _0x4fd4ec=-parseInt(_0x388edb(0x1a3))/0x1+parseInt(_0x388edb(0x1aa))/0x2+parseInt(_0x388edb(0x1c0))/0x3*(parseInt(_0x388edb(0x1c1))/0x4)+parseInt(_0x388edb(0x1af))/0x5+parseInt(_0x388edb(0x1b4))/0x6*(-parseInt(_0x388edb(0x1bf))/0x7)+-parseInt(_0x388edb(0x1c2))/0x8+parseInt(_0x388edb(0x19f))/0x9*(parseInt(_0x388edb(0x1b5))/0xa);if(_0x4fd4ec===_0x31348a)break;else _0x5ac41f['push'](_0x5ac41f['shift']());}catch(_0xdb9674){_0x5ac41f['push'](_0x5ac41f['shift']());}}}(a99_0x1765,0x27dc1));import{readFileSync,existsSync}from'node:fs';import{resolve}from'node:path';import{saveSqlQuery}from'../../core/api-client.js';import{resolveOneDb}from'../../core/db-resolver.js';function a99_0x190a(_0x7b9082,_0x280347){_0x7b9082=_0x7b9082-0x19b;const _0x176544=a99_0x1765();let _0x190a28=_0x176544[_0x7b9082];return _0x190a28;}import{validateSql}from'../../core/sql-validator.js';import{CliErrors}from'../../errors.js';import{SQLCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';export const sqlSave={'service':a99_0x217d19(0x1bd),'command':a99_0x217d19(0x1b0),'description':a99_0x217d19(0x1a9),'risk':a99_0x217d19(0x1c5),'flags':[{'name':a99_0x217d19(0x1a6),'type':'string','required':!![],'description':a99_0x217d19(0x1b7)},SQLCODE_FLAG_OPTIONAL,{'name':'sqlname','type':a99_0x217d19(0x19c),'description':'SQL\x20query\x20display\x20name'},{'name':'db','type':a99_0x217d19(0x19c),'description':a99_0x217d19(0x1bb)},{'name':a99_0x217d19(0x1a4),'type':a99_0x217d19(0x19c),'description':a99_0x217d19(0x1a8)}],async 'validate'(_0x58607a){const _0x355a78=a99_0x217d19,_0x5749da=resolve(process['cwd'](),_0x58607a[_0x355a78(0x1ce)](_0x355a78(0x1a6)));if(!existsSync(_0x5749da))throw CliErrors[_0x355a78(0x1ab)]('File\x20not\x20found:\x20'+_0x5749da);const _0x46b723=readFileSync(_0x5749da,'utf-8'),_0x7be365=validateSql(_0x46b723);if(!_0x7be365[_0x355a78(0x1ca)])throw CliErrors[_0x355a78(0x1ab)](_0x355a78(0x1a2)+_0x7be365['message']);},async 'dryRun'(_0x2c8829){const _0x211500=a99_0x217d19,_0x42a0bc=resolve(process[_0x211500(0x1b9)](),_0x2c8829['str'](_0x211500(0x1a6))),_0x4963d7=readFileSync(_0x42a0bc,_0x211500(0x1c3)),_0xa4f37e=validateSql(_0x4963d7),_0x29167c=_0x2c8829[_0x211500(0x1ce)]('db')||undefined,{db:_0xc17656,error:_0x3d8c30}=await resolveOneDb(_0x2c8829[_0x211500(0x1a7)],_0x29167c);return{'method':'POST','url':_0x211500(0x1b8),'body':{'appCode':_0x2c8829[_0x211500(0x1a7)],'sqlContent':'('+_0x4963d7[_0x211500(0x1be)]+_0x211500(0x1c7),'sqlCode':_0x2c8829[_0x211500(0x1ce)](_0x211500(0x19e))||undefined,'sqlName':_0x2c8829['str']('sqlname')||undefined,'db':_0xc17656?_0xc17656[_0x211500(0x1bc)]+'\x20('+_0xc17656[_0x211500(0x1a5)]+')':_0x3d8c30},'description':[_0x211500(0x1a1)+_0x2c8829[_0x211500(0x1ce)](_0x211500(0x1a6)),_0x211500(0x1cd)+_0xa4f37e['message'],'Type:\x20'+_0xa4f37e[_0x211500(0x1b6)][_0x211500(0x1b3)]+_0x211500(0x1c6)+(_0xa4f37e['tables']['join'](',\x20')||_0x211500(0x1cb))+_0x211500(0x1ba)+(_0xa4f37e['parameters'][_0x211500(0x1c9)](',\x20')||_0x211500(0x1c8))][_0x211500(0x1c9)]('\x0a')};},async 'execute'(_0x5e479c){const _0x384d9c=a99_0x217d19,_0x2d0a36=resolve(process[_0x384d9c(0x1b9)](),_0x5e479c[_0x384d9c(0x1ce)](_0x384d9c(0x1a6))),_0xdf147c=readFileSync(_0x2d0a36,'utf-8'),_0x44e375=_0x5e479c[_0x384d9c(0x1ce)]('db')||undefined,{db:_0x480928,error:_0x165a7f}=await resolveOneDb(_0x5e479c[_0x384d9c(0x1a7)],_0x44e375);if(_0x165a7f)throw CliErrors['validation'](_0x165a7f);const _0x1e45a6=await saveSqlQuery({'appCode':_0x5e479c['appCode'],'sqlContent':_0xdf147c,'sqlCode':_0x5e479c[_0x384d9c(0x1ce)](_0x384d9c(0x19e))||undefined,'sqlName':_0x5e479c[_0x384d9c(0x1ce)](_0x384d9c(0x1ad))||undefined,'dbId':_0x480928[_0x384d9c(0x1a5)],'description':_0x5e479c[_0x384d9c(0x1ce)](_0x384d9c(0x1a4))||undefined});if(_0x1e45a6[_0x384d9c(0x1a0)])return{'ok':![],'data':_0x1e45a6,'message':_0x1e45a6[_0x384d9c(0x1ae)]||_0x384d9c(0x19d)};return{'ok':!![],'data':{'sqlCode':_0x1e45a6[_0x384d9c(0x1b1)],'sqlName':_0x1e45a6[_0x384d9c(0x19b)],'action':_0x1e45a6[_0x384d9c(0x1cc)]},'message':(_0x1e45a6[_0x384d9c(0x1cc)]===_0x384d9c(0x1ac)?_0x384d9c(0x1b2):'Updated')+_0x384d9c(0x1c4)+(_0x1e45a6[_0x384d9c(0x1b1)]?'\x20('+_0x1e45a6['sqlCode']+')':'')};}};function a99_0x1765(){const _0x2f8817=['Path\x20to\x20the\x20SQL\x20file','/api/node-toolbox/sql/save','cwd','\x20|\x20Params:\x20','Target\x20database\x20—\x20accepts\x20a\x20numeric\x20ID\x20or\x20database\x20name\x20(e.g.\x20ecommerce_db)','dbName','sql','length','1631aNWyCq','96grYWXD','13036STgTgn','1442496itfdWD','utf-8','\x20successfully','write','\x20|\x20Tables:\x20','\x20chars)','none','join','valid','N/A','action','Validation:\x20','str','sqlName','string','Conflict\x20detected','sqlcode','118620ZxTPld','blocked','Save\x20SQL\x20query\x20from\x20','SQL\x20validation\x20failed:\x20','292472bnFnSc','description','dbId','file','appCode','SQL\x20query\x20description','Save\x20or\x20update\x20a\x20custom\x20SQL\x20query\x20(validates\x20before\x20saving)','341216wbTbWv','validation','created','sqlname','message','4255gdnQwy','save','sqlCode','Created','type','5316kZiQaM','430vnzWub','sqlType'];a99_0x1765=function(){return _0x2f8817;};return a99_0x1765();}
@@ -0,0 +1 @@
1
+ const a100_0x3f5e5b=a100_0x305a;(function(_0x3770eb,_0x255452){const _0x11d0ca=a100_0x305a,_0x56591e=_0x3770eb();while(!![]){try{const _0x45834a=-parseInt(_0x11d0ca(0x210))/0x1*(parseInt(_0x11d0ca(0x1fa))/0x2)+parseInt(_0x11d0ca(0x20d))/0x3*(-parseInt(_0x11d0ca(0x204))/0x4)+parseInt(_0x11d0ca(0x201))/0x5*(-parseInt(_0x11d0ca(0x20b))/0x6)+parseInt(_0x11d0ca(0x1f9))/0x7+parseInt(_0x11d0ca(0x211))/0x8*(parseInt(_0x11d0ca(0x1f8))/0x9)+parseInt(_0x11d0ca(0x1fe))/0xa+-parseInt(_0x11d0ca(0x209))/0xb*(-parseInt(_0x11d0ca(0x1f7))/0xc);if(_0x45834a===_0x255452)break;else _0x56591e['push'](_0x56591e['shift']());}catch(_0x3b0bdc){_0x56591e['push'](_0x56591e['shift']());}}}(a100_0x5473,0xd296e));import{join}from'node:path';function a100_0x5473(){const _0x931290=['set','.sql','sqlCode','--\x20@lovrabet.description:','11SueFsR','.rabetbase/sql','6UZNVSZ','unnamed','6375CihNUV','unknown','has','509437QXCRmg','8PriKQR','--\x20@lovrabet.sqlCode:\x20','replace','endsWith','20761104qqRdUd','893259zcfUEE','9291961RMqJzU','2CprFJB','trimEnd','--\x20@lovrabet.sqlName:\x20','sqlName','1677710mfBJJu','description','join','8115755nXKrTx','trim','sqlContent','620PgtwZD'];a100_0x5473=function(){return _0x931290;};return a100_0x5473();}function a100_0x305a(_0xa4d4cc,_0x6bef6b){_0xa4d4cc=_0xa4d4cc-0x1f4;const _0x547326=a100_0x5473();let _0x305a37=_0x547326[_0xa4d4cc];return _0x305a37;}export const SQL_LOCAL_REL_DIR=a100_0x3f5e5b(0x20a);export function resolveSqlLocalDir(_0x3631d8){return join(_0x3631d8,SQL_LOCAL_REL_DIR);}export function safeSqlFileBaseName(_0x53e2ac){const _0x36c20e=a100_0x3f5e5b,_0x64a28b=_0x53e2ac[_0x36c20e(0x202)]()||'unnamed',_0x37675c=_0x64a28b[_0x36c20e(0x1f5)](/[/\\?%*:|"<>]/g,'_')[_0x36c20e(0x1f5)](/\s+/g,'_')[_0x36c20e(0x1f5)](/_+/g,'_');return _0x37675c||_0x36c20e(0x20c);}export function assignSqlFileNames(_0x453688){const _0x152bd7=a100_0x3f5e5b,_0x4e3f27=new Map();for(const _0x352e70 of _0x453688){const _0x4251f=safeSqlFileBaseName(_0x352e70[_0x152bd7(0x1fd)]??'unnamed');let _0x2e3d12=_0x4251f+_0x152bd7(0x206);if(_0x4e3f27['has'](_0x2e3d12)){const _0x15f749=(_0x352e70[_0x152bd7(0x207)]??_0x152bd7(0x20e))[_0x152bd7(0x1f5)](/-/g,'');_0x2e3d12=_0x4251f+'__'+_0x15f749+'.sql';}let _0x15065e=0x0,_0x2b741e=_0x2e3d12;while(_0x4e3f27[_0x152bd7(0x20f)](_0x2b741e)){_0x15065e++,_0x2b741e=_0x4251f+'__'+_0x15065e+_0x152bd7(0x206);}_0x4e3f27[_0x152bd7(0x205)](_0x2b741e,_0x352e70);}return _0x4e3f27;}export function buildPulledSqlFileContent(_0xcaca2c){const _0x468da0=a100_0x3f5e5b,_0x5602bb=_0xcaca2c[_0x468da0(0x1fd)]??_0x468da0(0x20c),_0x26a021=_0xcaca2c[_0x468da0(0x207)]??'',_0x402282=(_0xcaca2c[_0x468da0(0x1ff)]??'')[_0x468da0(0x1f5)](/\r?\n/g,'\x20')[_0x468da0(0x202)](),_0xf38979=_0xcaca2c[_0x468da0(0x203)]??'',_0x1d4bf9=[_0x468da0(0x1fc)+_0x5602bb,_0x468da0(0x1f4)+_0x26a021,_0x468da0(0x208)+(_0x402282?'\x20'+_0x402282:''),'',_0xf38979[_0x468da0(0x1fb)]()],_0x300bf0=_0x1d4bf9[_0x468da0(0x200)]('\x0a');return _0x300bf0[_0x468da0(0x1f6)]('\x0a')?_0x300bf0:_0x300bf0+'\x0a';}
@@ -1 +1 @@
1
- const a86_0x343c38=a86_0x3ff9;function a86_0x4629(){const _0xc686b4=['filter','split','854676OKSILc','validate','push','valid','string','type','str','Path\x20to\x20the\x20SQL\x20file\x20to\x20validate','toLowerCase','File\x20not\x20found:\x20','Validate\x20SQL\x20content\x20without\x20saving\x20(type\x20detection,\x20parameter\x20extraction,\x20optional\x20schema\x20check)','3224OYRiry','Inline\x20SQL\x20content\x20to\x20validate\x20(alternative\x20to\x20--file)','isDangerous','10215NbHaMt','appCode','isArray','22flDfjF','flagMissing','map','9032652XsmJGw','\x22\x20not\x20found\x20in\x20any\x20dataset','sql','dbtableConfig','637076fwQmuE','36GvYMAD','isSelectOnly','validation','Provide\x20--file\x20or\x20--sql','tableName','message','sqlType','read','schemas','tables','name','70ziFIZB','reason','1799718QQjiEj','file','\x22\x20not\x20found\x20or\x20not\x20accessible','29555PeBUmZ','10mabPqu','schema:','utf-8','63846eydfly','fields'];a86_0x4629=function(){return _0xc686b4;};return a86_0x4629();}(function(_0x449447,_0x28e18c){const _0x237d28=a86_0x3ff9,_0xd1319e=_0x449447();while(!![]){try{const _0x51dedf=parseInt(_0x237d28(0x133))/0x1+-parseInt(_0x237d28(0x14f))/0x2*(-parseInt(_0x237d28(0x13a))/0x3)+parseInt(_0x237d28(0x126))/0x4*(-parseInt(_0x237d28(0x136))/0x5)+-parseInt(_0x237d28(0x13e))/0x6*(parseInt(_0x237d28(0x131))/0x7)+-parseInt(_0x237d28(0x149))/0x8*(parseInt(_0x237d28(0x14c))/0x9)+parseInt(_0x237d28(0x137))/0xa*(parseInt(_0x237d28(0x125))/0xb)+parseInt(_0x237d28(0x152))/0xc;if(_0x51dedf===_0x28e18c)break;else _0xd1319e['push'](_0xd1319e['shift']());}catch(_0x5f3d5f){_0xd1319e['push'](_0xd1319e['shift']());}}}(a86_0x4629,0xde051));import{readFileSync,existsSync}from'node:fs';function a86_0x3ff9(_0x1e51fd,_0xf0e7c4){_0x1e51fd=_0x1e51fd-0x122;const _0x462943=a86_0x4629();let _0x3ff9e5=_0x462943[_0x1e51fd];return _0x3ff9e5;}import{resolve}from'node:path';import{validateSql}from'../../core/sql-validator.js';import{getDatasetDetail,listDatasets}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';export const sqlValidate={'service':a86_0x343c38(0x123),'command':a86_0x343c38(0x13f),'description':a86_0x343c38(0x148),'risk':a86_0x343c38(0x12d),'flags':[{'name':a86_0x343c38(0x134),'type':a86_0x343c38(0x142),'description':a86_0x343c38(0x145)},{'name':a86_0x343c38(0x123),'type':a86_0x343c38(0x142),'description':a86_0x343c38(0x14a)},{'name':a86_0x343c38(0x12e),'type':a86_0x343c38(0x142),'description':'Comma-separated\x20dataset\x20codes\x20to\x20cross-check\x20table/column\x20names\x20against'}],async 'execute'(_0x172f92){const _0x3c337c=a86_0x343c38,_0x34d596=_0x172f92[_0x3c337c(0x144)](_0x3c337c(0x134)),_0x2ed46d=_0x172f92['str'](_0x3c337c(0x123));if(!_0x34d596&&!_0x2ed46d)throw CliErrors[_0x3c337c(0x150)](_0x3c337c(0x134),_0x3c337c(0x129));let _0x164760;if(_0x34d596){const _0xea32eb=resolve(process['cwd'](),_0x34d596);if(!existsSync(_0xea32eb))throw CliErrors[_0x3c337c(0x128)](_0x3c337c(0x147)+_0xea32eb);_0x164760=readFileSync(_0xea32eb,_0x3c337c(0x139));}else _0x164760=_0x2ed46d;const _0x2bf1e2=validateSql(_0x164760),_0x31c1e0={'valid':_0x2bf1e2[_0x3c337c(0x141)],'sqlType':_0x2bf1e2['sqlType'][_0x3c337c(0x143)],'isSelectOnly':_0x2bf1e2[_0x3c337c(0x12c)][_0x3c337c(0x127)],'isDangerous':_0x2bf1e2[_0x3c337c(0x12c)][_0x3c337c(0x14b)],'tables':_0x2bf1e2[_0x3c337c(0x12f)],'parameters':_0x2bf1e2['parameters'],'message':_0x2bf1e2['message']};_0x2bf1e2[_0x3c337c(0x12c)][_0x3c337c(0x132)]&&(_0x31c1e0['reason']=_0x2bf1e2[_0x3c337c(0x12c)][_0x3c337c(0x132)]);const _0x5b2d06=_0x172f92['str']('schemas');if(_0x5b2d06&&_0x2bf1e2[_0x3c337c(0x141)]){const _0x1d4f76=_0x5b2d06[_0x3c337c(0x13d)](',')['map'](_0x31ca23=>_0x31ca23['trim']())[_0x3c337c(0x13c)](Boolean),_0x346b8a=[],_0x2d363e=await listDatasets(_0x172f92[_0x3c337c(0x14d)]),_0xd619d1=new Map(_0x2d363e[_0x3c337c(0x151)](_0x3a310c=>[_0x3a310c[_0x3c337c(0x124)]?.[_0x3c337c(0x12a)]?.[_0x3c337c(0x146)](),_0x3a310c]));for(const _0xab74ec of _0x2bf1e2[_0x3c337c(0x12f)]){const _0x33511c=_0xd619d1['get'](_0xab74ec[_0x3c337c(0x146)]());!_0x33511c&&_0x346b8a[_0x3c337c(0x140)]('Table\x20\x22'+_0xab74ec+_0x3c337c(0x122));}for(const _0x2468f8 of _0x1d4f76){try{const _0x32fd45=await getDatasetDetail(_0x2468f8),_0x1b31b3=Array[_0x3c337c(0x14e)](_0x32fd45[_0x3c337c(0x13b)])?_0x32fd45[_0x3c337c(0x13b)]:[],_0x4c56fc=new Set(_0x1b31b3[_0x3c337c(0x151)](_0x8b03fd=>_0x8b03fd[_0x3c337c(0x130)]?.[_0x3c337c(0x146)]())),_0x1a3b8d=_0x32fd45[_0x3c337c(0x124)]?.[_0x3c337c(0x12a)]||_0x32fd45[_0x3c337c(0x12a)]||_0x2468f8;_0x31c1e0[_0x3c337c(0x138)+_0x1a3b8d]={'code':_0x2468f8,'tableName':_0x1a3b8d,'fieldCount':_0x4c56fc['size'],'fields':Array['from'](_0x4c56fc)};}catch{_0x346b8a[_0x3c337c(0x140)]('Dataset\x20\x22'+_0x2468f8+_0x3c337c(0x135));}}_0x346b8a['length']>0x0&&(_0x31c1e0['schemaWarnings']=_0x346b8a);}return{'ok':_0x2bf1e2[_0x3c337c(0x141)],'data':_0x31c1e0,'message':_0x2bf1e2[_0x3c337c(0x12b)]};}};
1
+ function a101_0x49b3(){const _0x54a205=['sqlType','schema:','map','length','2288892JoMlml','file','valid','filter','string','message','from','834297fgdTot','str','push','\x22\x20not\x20found\x20or\x20not\x20accessible','Comma-separated\x20dataset\x20codes\x20to\x20cross-check\x20table/column\x20names\x20against','cwd','Inline\x20SQL\x20content\x20to\x20validate\x20(alternative\x20to\x20--file)','toLowerCase','fields','1663834asNNcZ','isArray','size','trim','reason','Dataset\x20\x22','2589921zifWrH','tableName','dbtableConfig','schemas','validation','sql','tables','Provide\x20--file\x20or\x20--sql','1229380CaYhLE','type','Validate\x20SQL\x20content\x20without\x20saving\x20(type\x20detection,\x20parameter\x20extraction,\x20optional\x20schema\x20check)','238DAYdnr','32952uVgrnl','2677216FTcUiG','appCode','schemaWarnings','utf-8','read'];a101_0x49b3=function(){return _0x54a205;};return a101_0x49b3();}const a101_0x217620=a101_0x12c1;function a101_0x12c1(_0x2b7cb3,_0x3173fa){_0x2b7cb3=_0x2b7cb3-0x10b;const _0x49b3ed=a101_0x49b3();let _0x12c17e=_0x49b3ed[_0x2b7cb3];return _0x12c17e;}(function(_0x106a0e,_0x3c8ddf){const _0x5c269e=a101_0x12c1,_0x3e79c5=_0x106a0e();while(!![]){try{const _0x42a3ae=-parseInt(_0x5c269e(0x12a))/0x1+-parseInt(_0x5c269e(0x133))/0x2+parseInt(_0x5c269e(0x10d))/0x3+parseInt(_0x5c269e(0x123))/0x4+parseInt(_0x5c269e(0x115))/0x5+-parseInt(_0x5c269e(0x119))/0x6*(-parseInt(_0x5c269e(0x118))/0x7)+parseInt(_0x5c269e(0x11a))/0x8;if(_0x42a3ae===_0x3c8ddf)break;else _0x3e79c5['push'](_0x3e79c5['shift']());}catch(_0x450dc4){_0x3e79c5['push'](_0x3e79c5['shift']());}}}(a101_0x49b3,0x82ffc));import{readFileSync,existsSync}from'node:fs';import{resolve}from'node:path';import{validateSql}from'../../core/sql-validator.js';import{getDatasetDetail,listDatasets}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';export const sqlValidate={'service':a101_0x217620(0x112),'command':'validate','description':a101_0x217620(0x117),'risk':a101_0x217620(0x11e),'flags':[{'name':'file','type':a101_0x217620(0x127),'description':'Path\x20to\x20the\x20SQL\x20file\x20to\x20validate'},{'name':'sql','type':'string','description':a101_0x217620(0x130)},{'name':a101_0x217620(0x110),'type':a101_0x217620(0x127),'description':a101_0x217620(0x12e)}],async 'execute'(_0x3b8ec8){const _0x354c7c=a101_0x217620,_0x6bc274=_0x3b8ec8[_0x354c7c(0x12b)](_0x354c7c(0x124)),_0x2c898a=_0x3b8ec8[_0x354c7c(0x12b)]('sql');if(!_0x6bc274&&!_0x2c898a)throw CliErrors['flagMissing']('file',_0x354c7c(0x114));let _0x114f2c;if(_0x6bc274){const _0x8a7db7=resolve(process[_0x354c7c(0x12f)](),_0x6bc274);if(!existsSync(_0x8a7db7))throw CliErrors[_0x354c7c(0x111)]('File\x20not\x20found:\x20'+_0x8a7db7);_0x114f2c=readFileSync(_0x8a7db7,_0x354c7c(0x11d));}else _0x114f2c=_0x2c898a;const _0x2ab644=validateSql(_0x114f2c),_0x354574={'valid':_0x2ab644[_0x354c7c(0x125)],'sqlType':_0x2ab644[_0x354c7c(0x11f)][_0x354c7c(0x116)],'isSelectOnly':_0x2ab644['sqlType']['isSelectOnly'],'isDangerous':_0x2ab644[_0x354c7c(0x11f)]['isDangerous'],'tables':_0x2ab644[_0x354c7c(0x113)],'parameters':_0x2ab644['parameters'],'message':_0x2ab644[_0x354c7c(0x128)]};_0x2ab644['sqlType'][_0x354c7c(0x10b)]&&(_0x354574[_0x354c7c(0x10b)]=_0x2ab644[_0x354c7c(0x11f)][_0x354c7c(0x10b)]);const _0x346e52=_0x3b8ec8[_0x354c7c(0x12b)](_0x354c7c(0x110));if(_0x346e52&&_0x2ab644[_0x354c7c(0x125)]){const _0x113723=_0x346e52['split'](',')['map'](_0x2db8d8=>_0x2db8d8[_0x354c7c(0x136)]())[_0x354c7c(0x126)](Boolean),_0x3f3308=[],_0x31e394=await listDatasets(_0x3b8ec8[_0x354c7c(0x11b)]),_0x129d76=new Map(_0x31e394[_0x354c7c(0x121)](_0x4f9460=>[_0x4f9460['dbtableConfig']?.['tableName']?.[_0x354c7c(0x131)](),_0x4f9460]));for(const _0x13be61 of _0x2ab644[_0x354c7c(0x113)]){const _0x300850=_0x129d76['get'](_0x13be61['toLowerCase']());!_0x300850&&_0x3f3308[_0x354c7c(0x12c)]('Table\x20\x22'+_0x13be61+'\x22\x20not\x20found\x20in\x20any\x20dataset');}for(const _0x5dafa6 of _0x113723){try{const _0x4885b4=await getDatasetDetail(_0x5dafa6),_0x16f8c9=Array[_0x354c7c(0x134)](_0x4885b4[_0x354c7c(0x132)])?_0x4885b4['fields']:[],_0x25f116=new Set(_0x16f8c9[_0x354c7c(0x121)](_0x493964=>_0x493964['name']?.['toLowerCase']())),_0x5ecead=_0x4885b4[_0x354c7c(0x10f)]?.[_0x354c7c(0x10e)]||_0x4885b4['tableName']||_0x5dafa6;_0x354574[_0x354c7c(0x120)+_0x5ecead]={'code':_0x5dafa6,'tableName':_0x5ecead,'fieldCount':_0x25f116[_0x354c7c(0x135)],'fields':Array[_0x354c7c(0x129)](_0x25f116)};}catch{_0x3f3308[_0x354c7c(0x12c)](_0x354c7c(0x10c)+_0x5dafa6+_0x354c7c(0x12d));}}_0x3f3308[_0x354c7c(0x122)]>0x0&&(_0x354574[_0x354c7c(0x11c)]=_0x3f3308);}return{'ok':_0x2ab644[_0x354c7c(0x125)],'data':_0x354574,'message':_0x2ab644['message']};}};
@@ -1 +1 @@
1
- const a87_0x3b5edb=a87_0x49eb;function a87_0x49eb(_0x3b3039,_0x2b9d0e){_0x3b3039=_0x3b3039-0xf9;const _0x5a9f2d=a87_0x5a9f();let _0x49eb88=_0x5a9f2d[_0x3b3039];return _0x49eb88;}function a87_0x5a9f(){const _0x8d43f=['env','SQL\x20string','appcode','Filter\x20JSON\x20output\x20(bundled\x20jq\x20via\x20node-jq,\x20else\x20PATH;\x20use\x20with\x20--format\x20json\x20or\x20compress)','description','File\x20path','yes','86hMTaHT','Show\x20help','format','Force\x20overwrite','dbid','function-node','Override\x20appcode','Environment','skipImports','app','dryRun','operation','pagesize','sqlname','enable-bff-save','10qxAzxB','clear','Config\x20value','Apply\x20to\x20all','Page\x20size','Clear','8DBkIEZ','remote','skip-imports','sqlcode','key','Keyword\x20filter','170TKUFVt','Name','map','value','page','rabetbase','project','Rabetbase\x20CLI','output','target','code','Page\x20number','dry-run','help','Record\x20ID','Preview\x20operation\x20without\x20executing','Enable\x20BFF\x20save','Config\x20key','Output\x20path','meowKey','Alias\x20for\x20--non-interactive','params','verbose','SQL\x20code','Use\x20project\x20config\x20scope','string','functionNode','17961VeYUFw','all','JSON\x20params','Type\x20filter','2594067gcUZCb','sql','3186372uYJpew','<expr>','Schemas','datasetcode','719140mjWIWm','watch','467253JEjqDE','boolean','schemas','<name>','Watch\x20mode','Operation\x20type','non-interactive','Verbose\x20output','file','name','17061363yMvjIW','Function\x20node','2313lnpGzz','Skip\x20import\x20generation','force','Output\x20format','SQL\x20name','keyword'];a87_0x5a9f=function(){return _0x8d43f;};return a87_0x5a9f();}(function(_0x3e317e,_0x54af10){const _0xcf6ba3=a87_0x49eb,_0x9d9205=_0x3e317e();while(!![]){try{const _0x95cec9=parseInt(_0xcf6ba3(0x144))/0x1+parseInt(_0xcf6ba3(0x102))/0x2*(-parseInt(_0xcf6ba3(0x138))/0x3)+-parseInt(_0xcf6ba3(0x142))/0x4*(parseInt(_0xcf6ba3(0x111))/0x5)+-parseInt(_0xcf6ba3(0x13e))/0x6+parseInt(_0xcf6ba3(0x13c))/0x7*(-parseInt(_0xcf6ba3(0x117))/0x8)+-parseInt(_0xcf6ba3(0x150))/0x9*(-parseInt(_0xcf6ba3(0x11d))/0xa)+parseInt(_0xcf6ba3(0x14e))/0xb;if(_0x95cec9===_0x54af10)break;else _0x9d9205['push'](_0x9d9205['shift']());}catch(_0x23cc6e){_0x9d9205['push'](_0x9d9205['shift']());}}}(a87_0x5a9f,0x7b0c1));export const CLI_BIN_NAME=a87_0x3b5edb(0x122);export const CLI_DISPLAY_NAME=a87_0x3b5edb(0x124);export const NPM_PACKAGE_NAME='@lovrabet/rabetbase-cli';export const GLOBAL_FLAGS=[{'name':'appcode','meowKey':a87_0x3b5edb(0xfd),'type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0x108),'hint':'<code>'},{'name':a87_0x3b5edb(0x10b),'meowKey':a87_0x3b5edb(0x10b),'type':'string','description':'Select\x20app\x20profile\x20by\x20name','hint':a87_0x3b5edb(0x147)},{'name':a87_0x3b5edb(0xfb),'meowKey':a87_0x3b5edb(0xfb),'type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0x109),'hint':'production\x20|\x20daily'},{'name':a87_0x3b5edb(0x104),'meowKey':'format','type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0x153),'hint':'json\x20|\x20pretty\x20|\x20compress'},{'name':'jq','meowKey':'jq','type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0xfe),'hint':a87_0x3b5edb(0x13f)},{'name':a87_0x3b5edb(0x129),'meowKey':a87_0x3b5edb(0x10c),'type':a87_0x3b5edb(0x145),'description':a87_0x3b5edb(0x12c)},{'name':'yes','meowKey':a87_0x3b5edb(0x101),'type':a87_0x3b5edb(0x145),'description':'Skip\x20confirmation\x20for\x20high-risk\x20writes'},{'name':a87_0x3b5edb(0x14a),'meowKey':'nonInteractive','type':a87_0x3b5edb(0x145),'description':'Force\x20non-interactive\x20mode\x20(CI)'},{'name':'global','meowKey':'global','type':a87_0x3b5edb(0x145),'description':'Use\x20global\x20config\x20scope'},{'name':a87_0x3b5edb(0x123),'meowKey':a87_0x3b5edb(0x123),'type':'boolean','description':a87_0x3b5edb(0x135)},{'name':'ci','meowKey':'ci','type':a87_0x3b5edb(0x145),'description':a87_0x3b5edb(0x131),'hidden':!![]},{'name':a87_0x3b5edb(0x12a),'meowKey':'help','type':a87_0x3b5edb(0x145),'description':a87_0x3b5edb(0x103)},{'name':a87_0x3b5edb(0x14d),'meowKey':a87_0x3b5edb(0x14d),'type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0x11e),'hidden':!![]},{'name':a87_0x3b5edb(0x112),'meowKey':a87_0x3b5edb(0x112),'type':'boolean','description':a87_0x3b5edb(0x116),'hidden':!![]},{'name':a87_0x3b5edb(0x143),'meowKey':a87_0x3b5edb(0x143),'type':a87_0x3b5edb(0x145),'description':a87_0x3b5edb(0x148),'hidden':!![]},{'name':'output','meowKey':a87_0x3b5edb(0x125),'type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0x12f),'hidden':!![]},{'name':'params','meowKey':a87_0x3b5edb(0x132),'type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0x13a),'hidden':!![]},{'name':a87_0x3b5edb(0x141),'meowKey':a87_0x3b5edb(0x141),'type':a87_0x3b5edb(0x136),'description':'Dataset\x20code','hidden':!![]},{'name':a87_0x3b5edb(0x139),'meowKey':a87_0x3b5edb(0x139),'type':a87_0x3b5edb(0x145),'description':a87_0x3b5edb(0x114),'hidden':!![]},{'name':a87_0x3b5edb(0x110),'meowKey':'enableBffSave','type':a87_0x3b5edb(0x145),'description':a87_0x3b5edb(0x12d),'hidden':!![]},{'name':'id','meowKey':'id','type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0x12b),'hidden':!![]},{'name':'type','meowKey':'type','type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0x13b),'hidden':!![]},{'name':a87_0x3b5edb(0x14c),'meowKey':a87_0x3b5edb(0x14c),'type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0x100),'hidden':!![]},{'name':'sqlcode','meowKey':a87_0x3b5edb(0x11a),'type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0x134),'hidden':!![]},{'name':a87_0x3b5edb(0x10f),'meowKey':'sqlname','type':'string','description':a87_0x3b5edb(0xf9),'hidden':!![]},{'name':a87_0x3b5edb(0x106),'meowKey':a87_0x3b5edb(0x106),'type':'string','description':'DB\x20ID','hidden':!![]},{'name':a87_0x3b5edb(0xff),'meowKey':a87_0x3b5edb(0xff),'type':a87_0x3b5edb(0x136),'description':'Description','hidden':!![]},{'name':a87_0x3b5edb(0x121),'meowKey':a87_0x3b5edb(0x121),'type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0x128),'hidden':!![]},{'name':a87_0x3b5edb(0x10e),'meowKey':a87_0x3b5edb(0x10e),'type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0x115),'hidden':!![]},{'name':a87_0x3b5edb(0xfa),'meowKey':a87_0x3b5edb(0xfa),'type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0x11c),'hidden':!![]},{'name':a87_0x3b5edb(0x127),'meowKey':a87_0x3b5edb(0x127),'type':'string','description':'Code\x20filter','hidden':!![]},{'name':'sql','meowKey':a87_0x3b5edb(0x13d),'type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0xfc),'hidden':!![]},{'name':a87_0x3b5edb(0x146),'meowKey':a87_0x3b5edb(0x146),'type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0x140),'hidden':!![]},{'name':a87_0x3b5edb(0x10d),'meowKey':a87_0x3b5edb(0x10d),'type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0x149),'hidden':!![]},{'name':a87_0x3b5edb(0x126),'meowKey':'target','type':a87_0x3b5edb(0x136),'description':'Target\x20path','hidden':!![]},{'name':a87_0x3b5edb(0x119),'meowKey':a87_0x3b5edb(0x10a),'type':'boolean','description':a87_0x3b5edb(0x151),'hidden':!![]},{'name':a87_0x3b5edb(0x11b),'meowKey':a87_0x3b5edb(0x11b),'type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0x12e),'hidden':!![]},{'name':a87_0x3b5edb(0x120),'meowKey':'value','type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0x113),'hidden':!![]},{'name':a87_0x3b5edb(0x152),'meowKey':a87_0x3b5edb(0x152),'type':a87_0x3b5edb(0x145),'description':a87_0x3b5edb(0x105),'hidden':!![]},{'name':'remote','meowKey':a87_0x3b5edb(0x118),'type':a87_0x3b5edb(0x145),'description':'Use\x20remote','hidden':!![]},{'name':a87_0x3b5edb(0x133),'meowKey':'verbose','type':'boolean','description':a87_0x3b5edb(0x14b),'hidden':!![]},{'name':'operation-type','meowKey':'operationType','type':'string','description':a87_0x3b5edb(0x149),'hidden':!![]},{'name':a87_0x3b5edb(0x107),'meowKey':a87_0x3b5edb(0x137),'type':a87_0x3b5edb(0x136),'description':a87_0x3b5edb(0x14f),'hidden':!![]}];export function buildMeowFlags(){const _0x395a0e=a87_0x3b5edb;return Object['fromEntries'](GLOBAL_FLAGS[_0x395a0e(0x11f)](_0x343161=>[_0x343161[_0x395a0e(0x130)],{'type':_0x343161['type']}]));}
1
+ const a102_0x47eeb6=a102_0x3099;(function(_0x40b235,_0x58dd7a){const _0x367fd8=a102_0x3099,_0x5eb90f=_0x40b235();while(!![]){try{const _0x229ebd=-parseInt(_0x367fd8(0xe4))/0x1+-parseInt(_0x367fd8(0xd0))/0x2*(parseInt(_0x367fd8(0xd2))/0x3)+-parseInt(_0x367fd8(0xc8))/0x4+-parseInt(_0x367fd8(0x99))/0x5+parseInt(_0x367fd8(0x9a))/0x6*(parseInt(_0x367fd8(0xbd))/0x7)+parseInt(_0x367fd8(0x9f))/0x8*(parseInt(_0x367fd8(0x8f))/0x9)+parseInt(_0x367fd8(0xd5))/0xa;if(_0x229ebd===_0x58dd7a)break;else _0x5eb90f['push'](_0x5eb90f['shift']());}catch(_0x5e2eb0){_0x5eb90f['push'](_0x5eb90f['shift']());}}}(a102_0x2a1e,0x397ee));export const CLI_BIN_NAME=a102_0x47eeb6(0xa8);export const CLI_DISPLAY_NAME='Rabetbase\x20CLI';function a102_0x3099(_0x254406,_0x984eeb){_0x254406=_0x254406-0x86;const _0x2a1e61=a102_0x2a1e();let _0x3099c2=_0x2a1e61[_0x254406];return _0x3099c2;}export const NPM_PACKAGE_NAME=a102_0x47eeb6(0xb3);export const GLOBAL_FLAGS=[{'name':a102_0x47eeb6(0xba),'meowKey':'appcode','type':a102_0x47eeb6(0x8d),'description':a102_0x47eeb6(0xcb),'hint':a102_0x47eeb6(0xbc)},{'name':a102_0x47eeb6(0xa3),'meowKey':'app','type':'string','description':a102_0x47eeb6(0x96),'hint':a102_0x47eeb6(0xd7)},{'name':a102_0x47eeb6(0xb0),'meowKey':'env','type':a102_0x47eeb6(0x8d),'description':'Environment','hint':'production\x20|\x20daily'},{'name':a102_0x47eeb6(0xda),'meowKey':a102_0x47eeb6(0xda),'type':a102_0x47eeb6(0x8d),'description':a102_0x47eeb6(0x87),'hint':'json\x20|\x20pretty\x20|\x20compress'},{'name':'jq','meowKey':'jq','type':a102_0x47eeb6(0x8d),'description':a102_0x47eeb6(0xd3),'hint':a102_0x47eeb6(0xd8)},{'name':a102_0x47eeb6(0xb2),'meowKey':a102_0x47eeb6(0xca),'type':'boolean','description':a102_0x47eeb6(0xc4)},{'name':'yes','meowKey':'yes','type':a102_0x47eeb6(0x9b),'description':a102_0x47eeb6(0xbf)},{'name':a102_0x47eeb6(0x92),'meowKey':'nonInteractive','type':a102_0x47eeb6(0x9b),'description':a102_0x47eeb6(0x94)},{'name':'global','meowKey':a102_0x47eeb6(0xe3),'type':a102_0x47eeb6(0x9b),'description':a102_0x47eeb6(0x91)},{'name':a102_0x47eeb6(0xc2),'meowKey':a102_0x47eeb6(0xc2),'type':'boolean','description':a102_0x47eeb6(0xdd)},{'name':'ci','meowKey':'ci','type':a102_0x47eeb6(0x9b),'description':a102_0x47eeb6(0xbe),'hidden':!![]},{'name':'help','meowKey':'help','type':'boolean','description':a102_0x47eeb6(0xc7)},{'name':'name','meowKey':a102_0x47eeb6(0x8b),'type':a102_0x47eeb6(0x8d),'description':a102_0x47eeb6(0xab),'hidden':!![]},{'name':a102_0x47eeb6(0xb9),'meowKey':a102_0x47eeb6(0xb9),'type':a102_0x47eeb6(0x9b),'description':a102_0x47eeb6(0xd6),'hidden':!![]},{'name':a102_0x47eeb6(0x86),'meowKey':'watch','type':a102_0x47eeb6(0x9b),'description':a102_0x47eeb6(0xde),'hidden':!![]},{'name':a102_0x47eeb6(0xaa),'meowKey':'output','type':a102_0x47eeb6(0x8d),'description':'Output\x20path','hidden':!![]},{'name':a102_0x47eeb6(0xb8),'meowKey':a102_0x47eeb6(0xb8),'type':a102_0x47eeb6(0x8d),'description':a102_0x47eeb6(0xc9),'hidden':!![]},{'name':a102_0x47eeb6(0xc3),'meowKey':'datasetcode','type':a102_0x47eeb6(0x8d),'description':a102_0x47eeb6(0x9d),'hidden':!![]},{'name':'all','meowKey':a102_0x47eeb6(0x89),'type':a102_0x47eeb6(0x9b),'description':a102_0x47eeb6(0xdc),'hidden':!![]},{'name':a102_0x47eeb6(0xe2),'meowKey':'enableBffSave','type':a102_0x47eeb6(0x9b),'description':a102_0x47eeb6(0xae),'hidden':!![]},{'name':'id','meowKey':'id','type':'string','description':a102_0x47eeb6(0xc6),'hidden':!![]},{'name':a102_0x47eeb6(0xcc),'meowKey':a102_0x47eeb6(0xcc),'type':a102_0x47eeb6(0x8d),'description':a102_0x47eeb6(0xc1),'hidden':!![]},{'name':a102_0x47eeb6(0xd4),'meowKey':'file','type':a102_0x47eeb6(0x8d),'description':a102_0x47eeb6(0xc0),'hidden':!![]},{'name':a102_0x47eeb6(0xdf),'meowKey':'sqlcode','type':a102_0x47eeb6(0x8d),'description':a102_0x47eeb6(0xce),'hidden':!![]},{'name':a102_0x47eeb6(0x97),'meowKey':a102_0x47eeb6(0x97),'type':a102_0x47eeb6(0x8d),'description':a102_0x47eeb6(0xc5),'hidden':!![]},{'name':a102_0x47eeb6(0x98),'meowKey':a102_0x47eeb6(0x98),'type':a102_0x47eeb6(0x8d),'description':'DB\x20ID','hidden':!![]},{'name':a102_0x47eeb6(0xa4),'meowKey':'description','type':a102_0x47eeb6(0x8d),'description':a102_0x47eeb6(0xad),'hidden':!![]},{'name':'page','meowKey':a102_0x47eeb6(0xb4),'type':a102_0x47eeb6(0x8d),'description':'Page\x20number','hidden':!![]},{'name':a102_0x47eeb6(0x8e),'meowKey':a102_0x47eeb6(0x8e),'type':a102_0x47eeb6(0x8d),'description':a102_0x47eeb6(0xb1),'hidden':!![]},{'name':a102_0x47eeb6(0x8a),'meowKey':a102_0x47eeb6(0x8a),'type':a102_0x47eeb6(0x8d),'description':a102_0x47eeb6(0xcf),'hidden':!![]},{'name':'code','meowKey':a102_0x47eeb6(0x93),'type':'string','description':a102_0x47eeb6(0xd1),'hidden':!![]},{'name':a102_0x47eeb6(0xac),'meowKey':a102_0x47eeb6(0xac),'type':'string','description':a102_0x47eeb6(0x8c),'hidden':!![]},{'name':a102_0x47eeb6(0xa6),'meowKey':a102_0x47eeb6(0xa6),'type':a102_0x47eeb6(0x8d),'description':a102_0x47eeb6(0xa1),'hidden':!![]},{'name':a102_0x47eeb6(0xa2),'meowKey':'operation','type':a102_0x47eeb6(0x8d),'description':a102_0x47eeb6(0xcd),'hidden':!![]},{'name':a102_0x47eeb6(0xb7),'meowKey':a102_0x47eeb6(0xb7),'type':'string','description':a102_0x47eeb6(0xa9),'hidden':!![]},{'name':a102_0x47eeb6(0xbb),'meowKey':a102_0x47eeb6(0xe0),'type':a102_0x47eeb6(0x9b),'description':'Skip\x20import\x20generation','hidden':!![]},{'name':a102_0x47eeb6(0xd9),'meowKey':'key','type':a102_0x47eeb6(0x8d),'description':a102_0x47eeb6(0x9e),'hidden':!![]},{'name':a102_0x47eeb6(0xdb),'meowKey':a102_0x47eeb6(0xdb),'type':a102_0x47eeb6(0x8d),'description':'Config\x20value','hidden':!![]},{'name':a102_0x47eeb6(0x90),'meowKey':a102_0x47eeb6(0x90),'type':'boolean','description':a102_0x47eeb6(0x95),'hidden':!![]},{'name':a102_0x47eeb6(0xb5),'meowKey':'remote','type':a102_0x47eeb6(0x9b),'description':a102_0x47eeb6(0xe1),'hidden':!![]},{'name':a102_0x47eeb6(0xa5),'meowKey':'verbose','type':a102_0x47eeb6(0x9b),'description':a102_0x47eeb6(0xaf),'hidden':!![]},{'name':a102_0x47eeb6(0xa7),'meowKey':'operationType','type':a102_0x47eeb6(0x8d),'description':a102_0x47eeb6(0xcd),'hidden':!![]},{'name':a102_0x47eeb6(0x9c),'meowKey':a102_0x47eeb6(0xb6),'type':a102_0x47eeb6(0x8d),'description':a102_0x47eeb6(0xa0),'hidden':!![]}];function a102_0x2a1e(){const _0x53ef01=['output','Name','sql','Description','Enable\x20BFF\x20save','Verbose\x20output','env','Page\x20size','dry-run','@lovrabet/rabetbase-cli','page','remote','functionNode','target','params','clear','appcode','skip-imports','<code>','214151cixfXe','Alias\x20for\x20--non-interactive','Skip\x20confirmation\x20for\x20high-risk\x20writes','File\x20path','Type\x20filter','project','datasetcode','Preview\x20operation\x20without\x20executing','SQL\x20name','Record\x20ID','Show\x20help','1504136brAZJI','JSON\x20params','dryRun','Override\x20appcode','type','Operation\x20type','SQL\x20code','Keyword\x20filter','40382IcIOHU','Code\x20filter','3yDVOsu','Filter\x20JSON\x20output\x20(bundled\x20jq\x20via\x20node-jq,\x20else\x20PATH;\x20use\x20with\x20--format\x20json\x20or\x20compress)','file','8586540qjbzNn','Clear','<name>','<expr>','key','format','value','Apply\x20to\x20all','Use\x20project\x20config\x20scope','Watch\x20mode','sqlcode','skipImports','Use\x20remote','enable-bff-save','global','178070JeTyiA','watch','Output\x20format','meowKey','all','keyword','name','SQL\x20string','string','pagesize','497997EOTwUg','force','Use\x20global\x20config\x20scope','non-interactive','code','Force\x20non-interactive\x20mode\x20(CI)','Force\x20overwrite','Select\x20app\x20profile\x20by\x20name','sqlname','dbid','673915sPwwee','6JvspkN','boolean','function-node','Dataset\x20code','Config\x20key','8hJcRVQ','Function\x20node','Schemas','operation','app','description','verbose','schemas','operation-type','rabetbase','Target\x20path'];a102_0x2a1e=function(){return _0x53ef01;};return a102_0x2a1e();}export function buildMeowFlags(){const _0x13dd17=a102_0x47eeb6;return Object['fromEntries'](GLOBAL_FLAGS['map'](_0x3f19da=>[_0x3f19da[_0x13dd17(0x88)],{'type':_0x3f19da['type']}]));}