@lovrabet/rabetbase-cli 2.0.7 → 2.0.9

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 (137) hide show
  1. package/lib/api/api-doc.js +1 -1
  2. package/lib/api/fetch-model-list.js +1 -1
  3. package/lib/api/generate-api-file.js +1 -1
  4. package/lib/auth/auth-server-ui.js +1 -1
  5. package/lib/auth/auth-server.js +1 -1
  6. package/lib/auth/constant.js +1 -1
  7. package/lib/auth/get-cookie.js +1 -1
  8. package/lib/auth/get-session-user.js +1 -1
  9. package/lib/auth/is-session-valid.js +1 -1
  10. package/lib/auth/logout.js +1 -1
  11. package/lib/cli-flags.js +1 -1
  12. package/lib/cli.js +1 -1
  13. package/lib/commands/api/doc.js +1 -1
  14. package/lib/commands/api/index.js +1 -1
  15. package/lib/commands/api/list.js +1 -1
  16. package/lib/commands/api/pull.js +1 -1
  17. package/lib/commands/api/shared.js +1 -1
  18. package/lib/commands/app/add.js +1 -1
  19. package/lib/commands/app/index.js +1 -1
  20. package/lib/commands/app/list.js +1 -1
  21. package/lib/commands/app/remote.js +1 -1
  22. package/lib/commands/app/remove.js +1 -1
  23. package/lib/commands/app/shared.js +1 -1
  24. package/lib/commands/app/use.js +1 -1
  25. package/lib/commands/auth/index.js +1 -1
  26. package/lib/commands/bff/delete.js +1 -1
  27. package/lib/commands/bff/detail.js +1 -1
  28. package/lib/commands/bff/index.js +1 -1
  29. package/lib/commands/bff/list.js +1 -1
  30. package/lib/commands/bff/new.js +1 -1
  31. package/lib/commands/bff/pull.js +1 -1
  32. package/lib/commands/bff/push.js +1 -1
  33. package/lib/commands/bff/status.js +1 -1
  34. package/lib/commands/cli-update.js +1 -1
  35. package/lib/commands/codegen/index.js +1 -1
  36. package/lib/commands/codegen/sdk.js +1 -1
  37. package/lib/commands/codegen/sql.js +1 -1
  38. package/lib/commands/common/app-selector.js +1 -1
  39. package/lib/commands/common/flags.js +1 -1
  40. package/lib/commands/common/validate.js +1 -1
  41. package/lib/commands/config/get.js +1 -1
  42. package/lib/commands/config/index.js +1 -1
  43. package/lib/commands/config/list.js +1 -1
  44. package/lib/commands/config/set.js +1 -1
  45. package/lib/commands/config/shared.js +1 -1
  46. package/lib/commands/dataset/detail.js +1 -1
  47. package/lib/commands/dataset/index.js +1 -1
  48. package/lib/commands/dataset/links.js +1 -1
  49. package/lib/commands/dataset/list.js +1 -1
  50. package/lib/commands/dataset/operations.js +1 -1
  51. package/lib/commands/doctor.js +1 -1
  52. package/lib/commands/init/index.js +1 -1
  53. package/lib/commands/logs/index.js +1 -1
  54. package/lib/commands/menu/index.js +1 -1
  55. package/lib/commands/menu/shared/compare-table.js +1 -1
  56. package/lib/commands/menu/shared/index.js +1 -1
  57. package/lib/commands/menu/shared/inquirer.js +1 -1
  58. package/lib/commands/menu/shared/local-pages.js +1 -1
  59. package/lib/commands/menu/shared/logic.js +1 -1
  60. package/lib/commands/menu/shared/service.js +1 -1
  61. package/lib/commands/menu/shared/sync-core.js +1 -1
  62. package/lib/commands/menu/shared/update-core.js +1 -1
  63. package/lib/commands/menu/shared/valid-url.js +1 -1
  64. package/lib/commands/menu/sync.js +1 -1
  65. package/lib/commands/menu/update.js +1 -1
  66. package/lib/commands/project/create/enhanced-guided-create.js +1 -1
  67. package/lib/commands/project/create/format-elapsed.js +1 -1
  68. package/lib/commands/project/create/main.js +1 -1
  69. package/lib/commands/project/create/non-interactive.js +1 -1
  70. package/lib/commands/project/create/project-template-path.js +1 -1
  71. package/lib/commands/project/create/use-copy-project-template.js +1 -1
  72. package/lib/commands/project/create/use-format-code.js +1 -1
  73. package/lib/commands/project/create/use-install-dependencies.js +1 -1
  74. package/lib/commands/project/index.js +1 -1
  75. package/lib/commands/project/init.js +1 -1
  76. package/lib/commands/project/upgrade.js +1 -1
  77. package/lib/commands/registry.js +1 -1
  78. package/lib/commands/run/index.js +1 -1
  79. package/lib/commands/schema.js +1 -0
  80. package/lib/commands/skill/index.js +1 -1
  81. package/lib/commands/sql/detail.js +1 -1
  82. package/lib/commands/sql/exec.js +1 -1
  83. package/lib/commands/sql/index.js +1 -1
  84. package/lib/commands/sql/list.js +1 -1
  85. package/lib/commands/sql/save.js +1 -1
  86. package/lib/commands/sql/validate.js +1 -1
  87. package/lib/constant/cli.js +1 -1
  88. package/lib/constant/domain.js +1 -1
  89. package/lib/constant/env.js +1 -1
  90. package/lib/context.js +1 -1
  91. package/lib/core/alias-resolver.js +1 -1
  92. package/lib/core/api-client.js +1 -1
  93. package/lib/core/bff/config.js +1 -1
  94. package/lib/core/bff/file-system.js +1 -1
  95. package/lib/core/bff/hash.js +1 -1
  96. package/lib/core/bff/lock.js +1 -1
  97. package/lib/core/bff/utils.js +1 -1
  98. package/lib/core/db-resolver.js +1 -1
  99. package/lib/core/sql-validator.js +1 -1
  100. package/lib/errors.js +1 -1
  101. package/lib/framework/build-all-flags.js +1 -0
  102. package/lib/framework/flags.js +1 -1
  103. package/lib/framework/help.js +1 -1
  104. package/lib/framework/index.js +1 -1
  105. package/lib/framework/output.js +1 -1
  106. package/lib/framework/response.js +1 -1
  107. package/lib/framework/runner.js +1 -1
  108. package/lib/framework/schema-export.js +1 -0
  109. package/lib/framework/types.js +1 -1
  110. package/lib/generated/build-info.js +1 -1
  111. package/lib/help.js +1 -1
  112. package/lib/skills/main.js +1 -1
  113. package/lib/skills/npx-skills-add.js +1 -1
  114. package/lib/telemetry/cli-command-trace.js +1 -1
  115. package/lib/telemetry/cli-help-trace.js +1 -1
  116. package/lib/telemetry/ensure-cli-otel-config.js +1 -1
  117. package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
  118. package/lib/telemetry/send-cli-trace-log.js +1 -1
  119. package/lib/utils/ai_config.js +1 -1
  120. package/lib/utils/apply-jq-filter.js +1 -0
  121. package/lib/utils/cdn-config.js +1 -1
  122. package/lib/utils/check-sdk-version.js +1 -1
  123. package/lib/utils/cli-version-check.js +1 -1
  124. package/lib/utils/config.js +1 -1
  125. package/lib/utils/copy-directory.js +1 -1
  126. package/lib/utils/file-utils.js +1 -1
  127. package/lib/utils/guides-cdn.js +1 -1
  128. package/lib/utils/http-client.js +1 -1
  129. package/lib/utils/is-non-interactive.js +1 -1
  130. package/lib/utils/logger.js +1 -1
  131. package/lib/utils/platform.js +1 -1
  132. package/lib/utils/rules-cdn.js +1 -1
  133. package/lib/utils/sleep.js +1 -1
  134. package/lib/utils/template-replacer.js +1 -1
  135. package/lib/utils/version.js +1 -1
  136. package/lib/utils/with-active-cookie.js +1 -1
  137. package/package.json +7 -4
@@ -1 +1 @@
1
- (function(_0x42ad1a,_0x5b91ae){const _0x4906d4=a112_0xb242,_0xf2d13=_0x42ad1a();while(!![]){try{const _0x41d77d=parseInt(_0x4906d4(0xf6))/0x1*(parseInt(_0x4906d4(0xee))/0x2)+parseInt(_0x4906d4(0x103))/0x3*(-parseInt(_0x4906d4(0xfe))/0x4)+-parseInt(_0x4906d4(0xf9))/0x5*(parseInt(_0x4906d4(0xf2))/0x6)+parseInt(_0x4906d4(0x104))/0x7*(-parseInt(_0x4906d4(0xf7))/0x8)+parseInt(_0x4906d4(0xfc))/0x9*(-parseInt(_0x4906d4(0xfd))/0xa)+parseInt(_0x4906d4(0x102))/0xb+parseInt(_0x4906d4(0xfa))/0xc;if(_0x41d77d===_0x5b91ae)break;else _0xf2d13['push'](_0xf2d13['shift']());}catch(_0x11c16b){_0xf2d13['push'](_0xf2d13['shift']());}}}(a112_0x5afe,0x5db71));import{sendCliTraceLog}from'./send-cli-trace-log.js';import{getCliVersion}from'../utils/version.js';const SENSITIVE_PATTERNS=[/cookie/i,/token/i,/password/i,/passwd/i,/secret/i,/auth/i,/session/i,/credential/i];function a112_0xb242(_0x442667,_0x2eb5b7){_0x442667=_0x442667-0xed;const _0x5afe4e=a112_0x5afe();let _0xb24252=_0x5afe4e[_0x442667];return _0xb24252;}function isSensitiveKey(_0x15d4c0){const _0xf6cfde=a112_0xb242;return SENSITIVE_PATTERNS[_0xf6cfde(0xf5)](_0x4e988f=>_0x4e988f[_0xf6cfde(0x100)](_0x15d4c0));}function a112_0x5afe(){const _0x145ee6=['7htAEos','durationMs','2DMRiGE','[REDACTED]','flags','stringify','12JMOzbt','command','entries','some','116079ZMEwbc','5309976zQaQtv','service','1304645tRlbHA','27610344WUFlZk','error','7461eTysUa','5870KZMHFs','4VcfFpa','rabetbase.command','test','message','4141599CbgolK','2212095xkzkay'];a112_0x5afe=function(){return _0x145ee6;};return a112_0x5afe();}function sanitizeFlags(_0x3806da){const _0xbfa4e0=a112_0xb242,_0x59b260={};for(const [_0x3bba97,_0xcb2b27]of Object[_0xbfa4e0(0xf4)](_0x3806da)){isSensitiveKey(_0x3bba97)?_0x59b260[_0x3bba97]=_0xcb2b27!=null&&_0xcb2b27!==''?_0xbfa4e0(0xef):_0xcb2b27:_0x59b260[_0x3bba97]=_0xcb2b27;}return _0x59b260;}export async function reportCommandTrace(_0x5ad145){const _0x2ec2b5=a112_0xb242;try{const _0x2b2e7f=sanitizeFlags(_0x5ad145[_0x2ec2b5(0xf0)]);await sendCliTraceLog({'spanName':_0x2ec2b5(0xff),'logData':{'command.cli_version':getCliVersion(),'command.service':_0x5ad145[_0x2ec2b5(0xf8)],'command.name':_0x5ad145[_0x2ec2b5(0xf3)],'command.flags':JSON[_0x2ec2b5(0xf1)](_0x2b2e7f),..._0x5ad145[_0x2ec2b5(0xed)]!=null?{'command.duration_ms':_0x5ad145[_0x2ec2b5(0xed)]}:{},..._0x5ad145['error']?{'command.error':_0x5ad145[_0x2ec2b5(0xfb)]instanceof Error?_0x5ad145['error'][_0x2ec2b5(0x101)]:String(_0x5ad145[_0x2ec2b5(0xfb)])}:{}}});}catch{}}
1
+ (function(_0x2e5229,_0x342b4b){const _0x4354e2=a115_0x4516,_0x1edf99=_0x2e5229();while(!![]){try{const _0x54975a=-parseInt(_0x4354e2(0xaf))/0x1+parseInt(_0x4354e2(0xbd))/0x2+parseInt(_0x4354e2(0xb8))/0x3*(parseInt(_0x4354e2(0xbf))/0x4)+parseInt(_0x4354e2(0xbc))/0x5*(parseInt(_0x4354e2(0xb1))/0x6)+-parseInt(_0x4354e2(0xb0))/0x7+parseInt(_0x4354e2(0xb5))/0x8+parseInt(_0x4354e2(0xb7))/0x9*(-parseInt(_0x4354e2(0xbe))/0xa);if(_0x54975a===_0x342b4b)break;else _0x1edf99['push'](_0x1edf99['shift']());}catch(_0x5b5b29){_0x1edf99['push'](_0x1edf99['shift']());}}}(a115_0x8773,0x1941c));import{sendCliTraceLog}from'../telemetry/send-cli-trace-log.js';import{getCliVersion}from'../utils/version.js';const SENSITIVE_PATTERNS=[/cookie/i,/token/i,/password/i,/passwd/i,/secret/i,/auth/i,/session/i,/credential/i];function a115_0x8773(){const _0x264e9a=['25718DIOgcZ','981726TFyhGg','error','some','entries','855304wmiwRz','durationMs','1566sxSjbD','1359IMKfuT','test','message','flags','5ZkVvuJ','353274pisokh','22130rllRDg','1092RhOUaL','rabetbase.command','78652jQEkxb'];a115_0x8773=function(){return _0x264e9a;};return a115_0x8773();}function isSensitiveKey(_0x3dc878){const _0xafbc63=a115_0x4516;return SENSITIVE_PATTERNS[_0xafbc63(0xb3)](_0x95a4a7=>_0x95a4a7[_0xafbc63(0xb9)](_0x3dc878));}function a115_0x4516(_0x5bd6db,_0x43b70b){_0x5bd6db=_0x5bd6db-0xae;const _0x877394=a115_0x8773();let _0x45164e=_0x877394[_0x5bd6db];return _0x45164e;}function sanitizeFlags(_0x170478){const _0x5b7403=a115_0x4516,_0x3b668b={};for(const [_0x41dff4,_0x54cba0]of Object[_0x5b7403(0xb4)](_0x170478)){isSensitiveKey(_0x41dff4)?_0x3b668b[_0x41dff4]=_0x54cba0!=null&&_0x54cba0!==''?'[REDACTED]':_0x54cba0:_0x3b668b[_0x41dff4]=_0x54cba0;}return _0x3b668b;}export async function reportCommandTrace(_0x52ee6e){const _0x338451=a115_0x4516;try{const _0x5f06a4=sanitizeFlags(_0x52ee6e[_0x338451(0xbb)]);await sendCliTraceLog({'spanName':_0x338451(0xae),'logData':{'command.cli_version':getCliVersion(),'command.service':_0x52ee6e['service'],'command.name':_0x52ee6e['command'],'command.flags':JSON['stringify'](_0x5f06a4),..._0x52ee6e[_0x338451(0xb6)]!=null?{'command.duration_ms':_0x52ee6e[_0x338451(0xb6)]}:{},..._0x52ee6e[_0x338451(0xb2)]?{'command.error':_0x52ee6e[_0x338451(0xb2)]instanceof Error?_0x52ee6e[_0x338451(0xb2)][_0x338451(0xba)]:String(_0x52ee6e[_0x338451(0xb2)])}:{}}});}catch{}}
@@ -1 +1 @@
1
- function a113_0x1970(){var _0x2fe3cd=['2107006hVqkOy','5lWMSkW','Failed\x20to\x20report\x20CLI\x20help\x20trace:','18IJBWQe','39067eijeEA','3723290lNnEnU','cli.help','2378490UxrjFv','1470915gdufRJ','280qUdkSj','541333WWWTVG','service','2oVhGrS','3546196sRAqwk'];a113_0x1970=function(){return _0x2fe3cd;};return a113_0x1970();}(function(_0x4c564a,_0x5a75f9){var _0x5e052f=a113_0x58bd,_0x1bcd80=_0x4c564a();while(!![]){try{var _0x37252a=-parseInt(_0x5e052f(0x1e6))/0x1*(-parseInt(_0x5e052f(0x1e8))/0x2)+parseInt(_0x5e052f(0x1e4))/0x3+parseInt(_0x5e052f(0x1e9))/0x4*(-parseInt(_0x5e052f(0x1eb))/0x5)+-parseInt(_0x5e052f(0x1e3))/0x6+parseInt(_0x5e052f(0x1e0))/0x7*(-parseInt(_0x5e052f(0x1e5))/0x8)+parseInt(_0x5e052f(0x1ed))/0x9*(parseInt(_0x5e052f(0x1e1))/0xa)+parseInt(_0x5e052f(0x1ea))/0xb;if(_0x37252a===_0x5a75f9)break;else _0x1bcd80['push'](_0x1bcd80['shift']());}catch(_0x1af230){_0x1bcd80['push'](_0x1bcd80['shift']());}}}(a113_0x1970,0x77847));function a113_0x58bd(_0x7504cf,_0x21319b){_0x7504cf=_0x7504cf-0x1e0;var _0x1970eb=a113_0x1970();var _0x58bd82=_0x1970eb[_0x7504cf];return _0x58bd82;}import{sendCliTraceLog}from'./send-cli-trace-log.js';export async function reportCliHelpTrace(_0x1961c5,_0x14409e){var _0x5c8863=a113_0x58bd;try{await sendCliTraceLog({'spanName':_0x5c8863(0x1e2),'logData':{'rabetbase.help.kind':_0x1961c5,..._0x14409e?.[_0x5c8863(0x1e7)]&&{'rabetbase.help.service':_0x14409e[_0x5c8863(0x1e7)]}}});}catch(_0x359b5b){console['error'](_0x5c8863(0x1ec),_0x359b5b);}}
1
+ function a116_0x2d98(_0x1b2154,_0x21bb18){_0x1b2154=_0x1b2154-0x77;var _0x15ebc3=a116_0x15eb();var _0x2d98b4=_0x15ebc3[_0x1b2154];return _0x2d98b4;}(function(_0x17cf93,_0x4d7c8f){var _0x1cc412=a116_0x2d98,_0x347609=_0x17cf93();while(!![]){try{var _0x2556e0=-parseInt(_0x1cc412(0x7f))/0x1+parseInt(_0x1cc412(0x82))/0x2*(parseInt(_0x1cc412(0x7c))/0x3)+-parseInt(_0x1cc412(0x84))/0x4*(parseInt(_0x1cc412(0x77))/0x5)+-parseInt(_0x1cc412(0x83))/0x6+-parseInt(_0x1cc412(0x7b))/0x7+-parseInt(_0x1cc412(0x7a))/0x8+parseInt(_0x1cc412(0x78))/0x9*(parseInt(_0x1cc412(0x81))/0xa);if(_0x2556e0===_0x4d7c8f)break;else _0x347609['push'](_0x347609['shift']());}catch(_0x3a87c4){_0x347609['push'](_0x347609['shift']());}}}(a116_0x15eb,0x55a1f));import{sendCliTraceLog}from'../telemetry/send-cli-trace-log.js';function a116_0x15eb(){var _0x304471=['58570qGwXIT','Failed\x20to\x20report\x20CLI\x20help\x20trace:','90ngPsxa','902bGVShe','4060284FluZzR','212iSdGxr','30295NjeGMI','1754901oMPViM','service','5134216oCAYVK','2573053UulyuY','4401WZSbOU','cli.help','error'];a116_0x15eb=function(){return _0x304471;};return a116_0x15eb();}export async function reportCliHelpTrace(_0x3a63db,_0x59795c){var _0x1d7c68=a116_0x2d98;try{await sendCliTraceLog({'spanName':_0x1d7c68(0x7d),'logData':{'rabetbase.help.kind':_0x3a63db,..._0x59795c?.[_0x1d7c68(0x79)]&&{'rabetbase.help.service':_0x59795c[_0x1d7c68(0x79)]}}});}catch(_0x8760){console[_0x1d7c68(0x7e)](_0x1d7c68(0x80),_0x8760);}}
@@ -1 +1 @@
1
- (function(_0x3d7d8b,_0x5455f1){const _0x120537=a114_0x520c,_0x5df2a9=_0x3d7d8b();while(!![]){try{const _0x5bf72b=-parseInt(_0x120537(0x1fd))/0x1*(parseInt(_0x120537(0x1fc))/0x2)+-parseInt(_0x120537(0x1f8))/0x3+-parseInt(_0x120537(0x1fb))/0x4*(parseInt(_0x120537(0x1f2))/0x5)+-parseInt(_0x120537(0x203))/0x6*(-parseInt(_0x120537(0x1ff))/0x7)+-parseInt(_0x120537(0x1fa))/0x8+-parseInt(_0x120537(0x1f5))/0x9+parseInt(_0x120537(0x202))/0xa*(parseInt(_0x120537(0x200))/0xb);if(_0x5bf72b===_0x5455f1)break;else _0x5df2a9['push'](_0x5df2a9['shift']());}catch(_0x40ded5){_0x5df2a9['push'](_0x5df2a9['shift']());}}}(a114_0x4cda,0x4e5c8));import a114_0x528ff7 from'node:os';import{VERSION,GIT_COMMIT}from'../generated/build-info.js';import{getSessionUserInfo}from'../auth/get-session-user.js';import{setTraceConfig,getOtelLoggerVersion}from'@lovrabet/otel-logger';function a114_0x520c(_0x52ca0e,_0xf54c83){_0x52ca0e=_0x52ca0e-0x1f2;const _0x4cdaa4=a114_0x4cda();let _0x520c49=_0x4cdaa4[_0x52ca0e];return _0x520c49;}import{NPM_PACKAGE_NAME}from'../constant/cli.js';let cliOtelTraceInitialized=![];export async function ensureCliOtelTraceConfig(){const _0x2df437=a114_0x520c,_0x555b9b=await getSessionUserInfo();if(!cliOtelTraceInitialized){const _0x1d71bf=_0x555b9b?.[_0x2df437(0x1f6)];setTraceConfig({'otelLoggerVersion':getOtelLoggerVersion(),'serviceName':NPM_PACKAGE_NAME,'serviceVersion':GIT_COMMIT!==_0x2df437(0x201)?VERSION+'+'+GIT_COMMIT:VERSION,'serviceEnv':process.env.RABETBASE_ENV??(process.env.RABETBASE_E2E_DAILY==='1'?_0x2df437(0x1f4):_0x2df437(0x1f7)),'username':_0x1d71bf?.['username']??a114_0x528ff7[_0x2df437(0x1f9)]()[_0x2df437(0x1fe)]??_0x2df437(0x1f3),..._0x1d71bf&&{'nickname':_0x1d71bf['nickname']}}),cliOtelTraceInitialized=!![];}return _0x555b9b;}function a114_0x4cda(){const _0x4731c6=['username','1225SkKuUN','34364ehIZwl','unknown','4430noOotR','19698LaWdKF','2118335OCjVbH','rabetbase-cli','daily','998118cEuYgF','user','production','488076PEiDiA','userInfo','2899752QLofoZ','4NXlAqi','1274CaSRvO','907wXtiMs'];a114_0x4cda=function(){return _0x4731c6;};return a114_0x4cda();}
1
+ function a117_0x5c52(){const _0x3f10b4=['rabetbase-cli','daily','352LhtSRV','username','2327260fpiTIV','502090PKWmLq','2002861WpKipv','9vdrPal','6riZJWD','904okMkBO','1815774rTkUqI','nickname','369ixNlqf','258380fcDOBe','426828OgqZHc'];a117_0x5c52=function(){return _0x3f10b4;};return a117_0x5c52();}(function(_0x2eee8d,_0x3a12f2){const _0x2d72c6=a117_0x35a1,_0x4a100a=_0x2eee8d();while(!![]){try{const _0x170eaf=parseInt(_0x2d72c6(0x84))/0x1+-parseInt(_0x2d72c6(0x81))/0x2+-parseInt(_0x2d72c6(0x7e))/0x3*(parseInt(_0x2d72c6(0x85))/0x4)+-parseInt(_0x2d72c6(0x7b))/0x5+-parseInt(_0x2d72c6(0x7f))/0x6*(-parseInt(_0x2d72c6(0x7d))/0x7)+-parseInt(_0x2d72c6(0x80))/0x8*(-parseInt(_0x2d72c6(0x83))/0x9)+parseInt(_0x2d72c6(0x7c))/0xa*(parseInt(_0x2d72c6(0x79))/0xb);if(_0x170eaf===_0x3a12f2)break;else _0x4a100a['push'](_0x4a100a['shift']());}catch(_0x29cb0b){_0x4a100a['push'](_0x4a100a['shift']());}}}(a117_0x5c52,0x70e1c));function a117_0x35a1(_0x6b6f0d,_0x1a73e9){_0x6b6f0d=_0x6b6f0d-0x79;const _0x5c5262=a117_0x5c52();let _0x35a168=_0x5c5262[_0x6b6f0d];return _0x35a168;}import a117_0x26a18f from'node:os';import{VERSION,GIT_COMMIT}from'../generated/build-info.js';import{getSessionUserInfo}from'../auth/get-session-user.js';import{setTraceConfig,getOtelLoggerVersion}from'@lovrabet/otel-logger';import{NPM_PACKAGE_NAME}from'../constant/cli.js';let cliOtelTraceInitialized=![];export async function ensureCliOtelTraceConfig(){const _0x15a627=a117_0x35a1,_0x23e84b=await getSessionUserInfo();if(!cliOtelTraceInitialized){const _0x505afe=_0x23e84b?.['user'];setTraceConfig({'otelLoggerVersion':getOtelLoggerVersion(),'serviceName':NPM_PACKAGE_NAME,'serviceVersion':GIT_COMMIT!=='unknown'?VERSION+'+'+GIT_COMMIT:VERSION,'serviceEnv':process.env.RABETBASE_ENV??(process.env.RABETBASE_E2E_DAILY==='1'?_0x15a627(0x87):'production'),'username':_0x505afe?.['username']??a117_0x26a18f['userInfo']()[_0x15a627(0x7a)]??_0x15a627(0x86),..._0x505afe&&{'nickname':_0x505afe[_0x15a627(0x82)]}}),cliOtelTraceInitialized=!![];}return _0x23e84b;}
@@ -1 +1 @@
1
- function a115_0x37f4(){const _0x4246b8=['SIGINT','872220qaIBuG','1231129MwLOHH','96XDFZio','129326wyxLja','213017lRBfYd','18ivLwAa','3609135ETUFZA','4567904AhNsQE','31601890cWGONd','SIGTERM','9ithRGJ','then','exit'];a115_0x37f4=function(){return _0x4246b8;};return a115_0x37f4();}(function(_0x47d1d7,_0x3f1471){const _0x5c3ee7=a115_0x5d74,_0x12c3f3=_0x47d1d7();while(!![]){try{const _0x18384c=-parseInt(_0x5c3ee7(0x190))/0x1+parseInt(_0x5c3ee7(0x192))/0x2*(parseInt(_0x5c3ee7(0x194))/0x3)+-parseInt(_0x5c3ee7(0x196))/0x4+-parseInt(_0x5c3ee7(0x195))/0x5+-parseInt(_0x5c3ee7(0x18f))/0x6+-parseInt(_0x5c3ee7(0x193))/0x7*(-parseInt(_0x5c3ee7(0x191))/0x8)+parseInt(_0x5c3ee7(0x199))/0x9*(parseInt(_0x5c3ee7(0x197))/0xa);if(_0x18384c===_0x3f1471)break;else _0x12c3f3['push'](_0x12c3f3['shift']());}catch(_0x817328){_0x12c3f3['push'](_0x12c3f3['shift']());}}}(a115_0x37f4,0xa450d));import{shutdownTraces}from'@lovrabet/otel-logger';let shutdownPromise=null;function a115_0x5d74(_0x2f359c,_0x2a656c){_0x2f359c=_0x2f359c-0x18e;const _0x37f487=a115_0x37f4();let _0x5d74e1=_0x37f487[_0x2f359c];return _0x5d74e1;}export async function flushOtelNodeIfUsed(){if(shutdownPromise)return shutdownPromise;return shutdownPromise=((async()=>{try{await shutdownTraces();}catch{}})()),shutdownPromise;}export function registerOtelShutdownOnExit(){const _0x59761e=a115_0x5d74;process['once']('beforeExit',()=>{void flushOtelNodeIfUsed();});const _0x711574=()=>{const _0x161613=a115_0x5d74;void flushOtelNodeIfUsed()[_0x161613(0x19a)](()=>process[_0x161613(0x19b)](0x0));};process['once'](_0x59761e(0x18e),_0x711574),process['once'](_0x59761e(0x198),_0x711574);}export async function exitWithOtelShutdown(_0x529f64){const _0x599a6a=a115_0x5d74;await flushOtelNodeIfUsed(),process[_0x599a6a(0x19b)](_0x529f64);}
1
+ (function(_0x3fb63c,_0x29451a){const _0x5e100a=a118_0x3618,_0x4c40e5=_0x3fb63c();while(!![]){try{const _0x48cfe5=-parseInt(_0x5e100a(0xf2))/0x1*(-parseInt(_0x5e100a(0xf5))/0x2)+-parseInt(_0x5e100a(0xe9))/0x3+parseInt(_0x5e100a(0xe6))/0x4*(-parseInt(_0x5e100a(0xf4))/0x5)+-parseInt(_0x5e100a(0xf1))/0x6+parseInt(_0x5e100a(0xee))/0x7*(-parseInt(_0x5e100a(0xec))/0x8)+parseInt(_0x5e100a(0xf0))/0x9+parseInt(_0x5e100a(0xe8))/0xa*(parseInt(_0x5e100a(0xed))/0xb);if(_0x48cfe5===_0x29451a)break;else _0x4c40e5['push'](_0x4c40e5['shift']());}catch(_0x53ef06){_0x4c40e5['push'](_0x4c40e5['shift']());}}}(a118_0xe806,0xc2e64));import{shutdownTraces}from'@lovrabet/otel-logger';let shutdownPromise=null;function a118_0x3618(_0x32daca,_0x50f6f1){_0x32daca=_0x32daca-0xe6;const _0xe8064c=a118_0xe806();let _0x3618d2=_0xe8064c[_0x32daca];return _0x3618d2;}export async function flushOtelNodeIfUsed(){if(shutdownPromise)return shutdownPromise;return shutdownPromise=((async()=>{try{await shutdownTraces();}catch{}})()),shutdownPromise;}export function registerOtelShutdownOnExit(){const _0x56933e=a118_0x3618;process[_0x56933e(0xef)](_0x56933e(0xeb),()=>{void flushOtelNodeIfUsed();});const _0x13860e=()=>{const _0x8a813e=_0x56933e;void flushOtelNodeIfUsed()[_0x8a813e(0xf3)](()=>process[_0x8a813e(0xe7)](0x0));};process[_0x56933e(0xef)](_0x56933e(0xea),_0x13860e),process['once']('SIGTERM',_0x13860e);}function a118_0xe806(){const _0x1caa51=['12RZzezj','exit','925820qkwRDM','3987828SJtXEl','SIGINT','beforeExit','56OoxiXB','385UTQvaj','1121533GfZXuL','once','12994758tkYKVV','8343240CtbjkV','1FMDxor','then','2568470OmBIMV','2993014cgWYLO'];a118_0xe806=function(){return _0x1caa51;};return a118_0xe806();}export async function exitWithOtelShutdown(_0x509fb2){await flushOtelNodeIfUsed(),process['exit'](_0x509fb2);}
@@ -1 +1 @@
1
- const a116_0x4eb77e=a116_0x4c64;(function(_0x1a4705,_0x2b8fd4){const _0x425b53=a116_0x4c64,_0x4eb6b=_0x1a4705();while(!![]){try{const _0x1bcc12=-parseInt(_0x425b53(0x1e0))/0x1*(-parseInt(_0x425b53(0x1e3))/0x2)+parseInt(_0x425b53(0x1de))/0x3*(-parseInt(_0x425b53(0x1d6))/0x4)+parseInt(_0x425b53(0x1d3))/0x5+-parseInt(_0x425b53(0x1db))/0x6+-parseInt(_0x425b53(0x1e2))/0x7*(parseInt(_0x425b53(0x1e1))/0x8)+parseInt(_0x425b53(0x1d7))/0x9*(parseInt(_0x425b53(0x1df))/0xa)+-parseInt(_0x425b53(0x1d8))/0xb*(-parseInt(_0x425b53(0x1d5))/0xc);if(_0x1bcc12===_0x2b8fd4)break;else _0x4eb6b['push'](_0x4eb6b['shift']());}catch(_0x1b1dd4){_0x4eb6b['push'](_0x4eb6b['shift']());}}}(a116_0x19c9,0x5bed2));function a116_0x4c64(_0x12c7f5,_0x18118f){_0x12c7f5=_0x12c7f5-0x1d2;const _0x19c925=a116_0x19c9();let _0x4c64f1=_0x19c925[_0x12c7f5];return _0x4c64f1;}import{sendTraceLog}from'@lovrabet/otel-logger';function a116_0x19c9(){const _0x524cfb=['936804txbdRC','18LhLIta','64526OLsohP','traceparent','traceName','225714CrunjN','logData','rabetbase-cli','6PwovQC','1600360bqIHXj','410819Jfciww','5636872VcASuI','7wWLQYr','2lUPohs','version','3636085DPhRCl','manual','264HbNShb'];a116_0x19c9=function(){return _0x524cfb;};return a116_0x19c9();}import{ensureCliOtelTraceConfig}from'./ensure-cli-otel-config.js';import{getCliVersion}from'../utils/version.js';const DEFAULT_TRACE_NAME=a116_0x4eb77e(0x1dd);export async function sendCliTraceLog(_0xc35dae){const _0x171603=a116_0x4eb77e;await ensureCliOtelTraceConfig(),sendTraceLog({'traceName':_0xc35dae[_0x171603(0x1da)]??DEFAULT_TRACE_NAME,'version':_0xc35dae[_0x171603(0x1d2)]??getCliVersion(),'spanName':_0xc35dae['spanName'],'eventType':_0x171603(0x1d4),'logData':_0xc35dae[_0x171603(0x1dc)],..._0xc35dae[_0x171603(0x1d9)]&&{'traceparent':_0xc35dae[_0x171603(0x1d9)]}});}
1
+ (function(_0x288cd5,_0x529381){const _0x52f5a4=a119_0x1646,_0x17f21a=_0x288cd5();while(!![]){try{const _0x232b2f=parseInt(_0x52f5a4(0xbc))/0x1*(-parseInt(_0x52f5a4(0xb7))/0x2)+parseInt(_0x52f5a4(0xb5))/0x3+-parseInt(_0x52f5a4(0xb6))/0x4*(parseInt(_0x52f5a4(0xbd))/0x5)+parseInt(_0x52f5a4(0xb8))/0x6*(parseInt(_0x52f5a4(0xba))/0x7)+parseInt(_0x52f5a4(0xb4))/0x8*(-parseInt(_0x52f5a4(0xb2))/0x9)+-parseInt(_0x52f5a4(0xb1))/0xa+parseInt(_0x52f5a4(0xb3))/0xb;if(_0x232b2f===_0x529381)break;else _0x17f21a['push'](_0x17f21a['shift']());}catch(_0xb0276c){_0x17f21a['push'](_0x17f21a['shift']());}}}(a119_0x389f,0x8fec3));function a119_0x1646(_0x83d64c,_0xe3710f){_0x83d64c=_0x83d64c-0xb1;const _0x389ffa=a119_0x389f();let _0x16461e=_0x389ffa[_0x83d64c];return _0x16461e;}import{sendTraceLog}from'@lovrabet/otel-logger';import{ensureCliOtelTraceConfig}from'../telemetry/ensure-cli-otel-config.js';import{getCliVersion}from'../utils/version.js';const DEFAULT_TRACE_NAME='rabetbase-cli';function a119_0x389f(){const _0x4df22b=['10pBbcIm','manual','1264970LGKVIY','231507KqxOou','21775424jbctfI','232ZSMBLN','2111331ioLEfF','1972552XCEGPa','2287524OOUEjD','48qLAYrg','traceparent','795067ZdzxKJ','spanName','1OGDmKD'];a119_0x389f=function(){return _0x4df22b;};return a119_0x389f();}export async function sendCliTraceLog(_0x2e111c){const _0x1a1a44=a119_0x1646;await ensureCliOtelTraceConfig(),sendTraceLog({'traceName':_0x2e111c['traceName']??DEFAULT_TRACE_NAME,'version':_0x2e111c['version']??getCliVersion(),'spanName':_0x2e111c[_0x1a1a44(0xbb)],'eventType':_0x1a1a44(0xbe),'logData':_0x2e111c['logData'],..._0x2e111c[_0x1a1a44(0xb9)]&&{'traceparent':_0x2e111c[_0x1a1a44(0xb9)]}});}
@@ -1 +1 @@
1
- const a118_0x2ee717=a118_0x4ee2;function a118_0x4ee2(_0x3e6368,_0x54d644){_0x3e6368=_0x3e6368-0xa5;const _0x1d078d=a118_0x1d07();let _0x4ee216=_0x1d078d[_0x3e6368];return _0x4ee216;}(function(_0x4d2ae4,_0x4add62){const _0x4ac435=a118_0x4ee2,_0x5546b2=_0x4d2ae4();while(!![]){try{const _0x107eec=parseInt(_0x4ac435(0xcc))/0x1+-parseInt(_0x4ac435(0xce))/0x2+parseInt(_0x4ac435(0xbd))/0x3+parseInt(_0x4ac435(0xd1))/0x4*(-parseInt(_0x4ac435(0xcd))/0x5)+-parseInt(_0x4ac435(0xd3))/0x6+-parseInt(_0x4ac435(0xc2))/0x7*(-parseInt(_0x4ac435(0xc9))/0x8)+parseInt(_0x4ac435(0xc1))/0x9;if(_0x107eec===_0x4add62)break;else _0x5546b2['push'](_0x5546b2['shift']());}catch(_0x24ecff){_0x5546b2['push'](_0x5546b2['shift']());}}}(a118_0x1d07,0xccbd6));export const CORE_IDE_CONFIGS={'cursor':{'name':a118_0x2ee717(0xb8),'description':a118_0x2ee717(0xdc),'folders':[a118_0x2ee717(0xd9),a118_0x2ee717(0xbc)],'files':[{'type':a118_0x2ee717(0xa8),'path':'.cursor/skills/rabetbase.md','template':'SKILL.md.tpl'}]},'windsurf':{'name':'Windsurf','description':a118_0x2ee717(0xab),'folders':[a118_0x2ee717(0xd4)],'files':[{'type':'file','path':a118_0x2ee717(0xaa),'template':a118_0x2ee717(0xb0)}]},'claude':{'name':'Claude\x20Code','description':a118_0x2ee717(0xb3),'folders':[a118_0x2ee717(0xbb)],'files':[{'type':'file','path':'.claude/skills/lovrabet/SKILL.md','template':a118_0x2ee717(0xb0)}]},'cline':{'name':a118_0x2ee717(0xca),'description':a118_0x2ee717(0xbf),'folders':[a118_0x2ee717(0xdb)],'files':[{'type':a118_0x2ee717(0xa8),'path':a118_0x2ee717(0xd6),'template':'SKILL.md.tpl'}]},'codex':{'name':a118_0x2ee717(0xc3),'description':a118_0x2ee717(0xa9),'folders':[a118_0x2ee717(0xb6)],'files':[{'type':a118_0x2ee717(0xa8),'path':a118_0x2ee717(0xb5),'template':a118_0x2ee717(0xb0)}]},'opencode':{'name':a118_0x2ee717(0xa7),'description':a118_0x2ee717(0xd8),'folders':['.opencode'],'files':[{'type':a118_0x2ee717(0xa8),'path':'.opencode/skills/lovrabet/SKILL.md','template':a118_0x2ee717(0xb0)}]},'qoder':{'name':a118_0x2ee717(0xaf),'description':a118_0x2ee717(0xb2),'folders':[a118_0x2ee717(0xc6)],'files':[{'type':a118_0x2ee717(0xa8),'path':a118_0x2ee717(0xb7),'template':a118_0x2ee717(0xb0)},{'type':'file','path':'.qoder/skills/lovrabet/SKILL.md','template':a118_0x2ee717(0xb0)}]},'codebuddy':{'name':a118_0x2ee717(0xda),'description':a118_0x2ee717(0xc8),'folders':[a118_0x2ee717(0xd2)],'files':[{'type':a118_0x2ee717(0xa8),'path':'.codebuddy/skills/lovrabet/SKILL.md','template':a118_0x2ee717(0xb0)}]},'trae':{'name':a118_0x2ee717(0xba),'description':'Trae\x20IDE','folders':[a118_0x2ee717(0xc5)],'files':[{'type':a118_0x2ee717(0xa8),'path':a118_0x2ee717(0xc4),'template':'SKILL.md.tpl'}]}};export const IDE_CONFIGS={...CORE_IDE_CONFIGS,'agent':{'name':a118_0x2ee717(0xae),'description':a118_0x2ee717(0xac),'folders':[a118_0x2ee717(0xcb)],'files':[{'type':a118_0x2ee717(0xa8),'path':a118_0x2ee717(0xb4),'template':a118_0x2ee717(0xb0)}]},'antigravity':{'name':a118_0x2ee717(0xd0),'description':a118_0x2ee717(0xd7),'folders':[a118_0x2ee717(0xcb)],'files':[{'type':a118_0x2ee717(0xa8),'path':'.agent/skills/lovrabet/SKILL.md','template':'SKILL.md.tpl'}]}};function a118_0x1d07(){const _0x4d2e1b=['3885tHXylf','Codex','.trae/skills/lovrabet/SKILL.md','.trae','.qoder','codex','CodeBuddy\x20IDE','8408xHTMnx','Cline','.agent','294824BCfSHn','460RPXHby','630912IXAwjP','windsurf','Antigravity','18188jnqbFa','.codebuddy','3483462ocIfVr','.windsurf','codebuddy','.cline/skills/lovrabet/SKILL.md','Antigravity\x20IDE','OpenCode\x20IDE','.cursorrules','CodeBuddy','.cline','Cursor\x20IDE','claude','qoder','OpenCode','file','Codex\x20IDE','.windsurf/workflows/rabetbase.md','Windsurf\x20IDE','通用模板\x20-\x20兜底方案','cursor','其他\x20(通用模板)','Qoder','SKILL.md.tpl','trae','Qoder\x20IDE','Claude\x20Code','.agent/skills/lovrabet/SKILL.md','.codex/skills/lovrabet/SKILL.md','.codex','.qoder/rules/rabetbase.md','Cursor','antigravity','Trae','.claude','.cursor','3451521CiLUgi','opencode','Cline\x20IDE','cline','1119015SSBClW'];a118_0x1d07=function(){return _0x4d2e1b;};return a118_0x1d07();}export const CORE_IDE_LIST=['claude',a118_0x2ee717(0xc0),'codebuddy','codex',a118_0x2ee717(0xad),a118_0x2ee717(0xbe),a118_0x2ee717(0xa6),'trae',a118_0x2ee717(0xcf)];export const IDE_LIST=[a118_0x2ee717(0xb9),'claude','cline','codebuddy',a118_0x2ee717(0xc7),a118_0x2ee717(0xad),'opencode','qoder',a118_0x2ee717(0xb1),a118_0x2ee717(0xcf),'agent'];export const ALL_CORE_IDES=[a118_0x2ee717(0xad),a118_0x2ee717(0xcf),a118_0x2ee717(0xa5),a118_0x2ee717(0xc0),a118_0x2ee717(0xc7),a118_0x2ee717(0xbe),a118_0x2ee717(0xa6),a118_0x2ee717(0xd5),a118_0x2ee717(0xb1)];
1
+ function a121_0x2177(){const _0x4674b1=['qoder','Antigravity\x20IDE','trae','windsurf','3010AQtqUJ','.qoder','.codebuddy','OpenCode\x20IDE','cursor','.opencode/skills/lovrabet/SKILL.md','.cursor','3160701YFFGMI','.claude','5931784wIrDWA','.claude/skills/lovrabet/SKILL.md','claude','.codex','322BbRBJl','209RXaJFN','Cursor','SKILL.md.tpl','5376105CHxobR','CodeBuddy','Qoder\x20IDE','.qoder/rules/rabetbase.md','5030iNLRXs','Cline\x20IDE','Claude\x20Code','Trae','93774YVgIFv','13682xJzWLH','.trae/skills/lovrabet/SKILL.md','codex','.codebuddy/skills/lovrabet/SKILL.md','agent','.windsurf','.cursor/skills/rabetbase.md','.cline/skills/lovrabet/SKILL.md','Cursor\x20IDE','cline','Codex','.agent/skills/lovrabet/SKILL.md','Windsurf\x20IDE','codebuddy','antigravity','其他\x20(通用模板)','opencode','.cline','Antigravity','1004chfhGe','OpenCode','Qoder','file','.opencode','Trae\x20IDE','87cODJJa','通用模板\x20-\x20兜底方案','Codex\x20IDE','.agent','.windsurf/workflows/rabetbase.md'];a121_0x2177=function(){return _0x4674b1;};return a121_0x2177();}const a121_0x298dfa=a121_0x597a;function a121_0x597a(_0x3460e1,_0xc58da5){_0x3460e1=_0x3460e1-0x187;const _0x217752=a121_0x2177();let _0x597a93=_0x217752[_0x3460e1];return _0x597a93;}(function(_0x42563f,_0x3f32d0){const _0x279c46=a121_0x597a,_0x10c993=_0x42563f();while(!![]){try{const _0x9560e2=-parseInt(_0x279c46(0x1ba))/0x1*(-parseInt(_0x279c46(0x1a1))/0x2)+-parseInt(_0x279c46(0x18e))/0x3+parseInt(_0x279c46(0x1b4))/0x4*(parseInt(_0x279c46(0x187))/0x5)+parseInt(_0x279c46(0x1a0))/0x6*(parseInt(_0x279c46(0x194))/0x7)+parseInt(_0x279c46(0x190))/0x8+-parseInt(_0x279c46(0x198))/0x9+parseInt(_0x279c46(0x19c))/0xa*(parseInt(_0x279c46(0x195))/0xb);if(_0x9560e2===_0x3f32d0)break;else _0x10c993['push'](_0x10c993['shift']());}catch(_0x50e389){_0x10c993['push'](_0x10c993['shift']());}}}(a121_0x2177,0x8a049));export const CORE_IDE_CONFIGS={'cursor':{'name':a121_0x298dfa(0x196),'description':a121_0x298dfa(0x1a9),'folders':['.cursorrules',a121_0x298dfa(0x18d)],'files':[{'type':a121_0x298dfa(0x1b7),'path':a121_0x298dfa(0x1a7),'template':a121_0x298dfa(0x197)}]},'windsurf':{'name':'Windsurf','description':a121_0x298dfa(0x1ad),'folders':[a121_0x298dfa(0x1a6)],'files':[{'type':'file','path':a121_0x298dfa(0x1be),'template':a121_0x298dfa(0x197)}]},'claude':{'name':a121_0x298dfa(0x19e),'description':'Claude\x20Code','folders':[a121_0x298dfa(0x18f)],'files':[{'type':a121_0x298dfa(0x1b7),'path':a121_0x298dfa(0x191),'template':'SKILL.md.tpl'}]},'cline':{'name':'Cline','description':a121_0x298dfa(0x19d),'folders':[a121_0x298dfa(0x1b2)],'files':[{'type':'file','path':a121_0x298dfa(0x1a8),'template':'SKILL.md.tpl'}]},'codex':{'name':a121_0x298dfa(0x1ab),'description':a121_0x298dfa(0x1bc),'folders':[a121_0x298dfa(0x193)],'files':[{'type':a121_0x298dfa(0x1b7),'path':'.codex/skills/lovrabet/SKILL.md','template':a121_0x298dfa(0x197)}]},'opencode':{'name':a121_0x298dfa(0x1b5),'description':a121_0x298dfa(0x18a),'folders':[a121_0x298dfa(0x1b8)],'files':[{'type':a121_0x298dfa(0x1b7),'path':a121_0x298dfa(0x18c),'template':a121_0x298dfa(0x197)}]},'qoder':{'name':a121_0x298dfa(0x1b6),'description':a121_0x298dfa(0x19a),'folders':[a121_0x298dfa(0x188)],'files':[{'type':a121_0x298dfa(0x1b7),'path':a121_0x298dfa(0x19b),'template':a121_0x298dfa(0x197)},{'type':a121_0x298dfa(0x1b7),'path':'.qoder/skills/lovrabet/SKILL.md','template':'SKILL.md.tpl'}]},'codebuddy':{'name':a121_0x298dfa(0x199),'description':'CodeBuddy\x20IDE','folders':[a121_0x298dfa(0x189)],'files':[{'type':a121_0x298dfa(0x1b7),'path':a121_0x298dfa(0x1a4),'template':a121_0x298dfa(0x197)}]},'trae':{'name':a121_0x298dfa(0x19f),'description':a121_0x298dfa(0x1b9),'folders':['.trae'],'files':[{'type':a121_0x298dfa(0x1b7),'path':a121_0x298dfa(0x1a2),'template':a121_0x298dfa(0x197)}]}};export const IDE_CONFIGS={...CORE_IDE_CONFIGS,'agent':{'name':a121_0x298dfa(0x1b0),'description':a121_0x298dfa(0x1bb),'folders':[a121_0x298dfa(0x1bd)],'files':[{'type':a121_0x298dfa(0x1b7),'path':a121_0x298dfa(0x1ac),'template':a121_0x298dfa(0x197)}]},'antigravity':{'name':a121_0x298dfa(0x1b3),'description':a121_0x298dfa(0x1c0),'folders':[a121_0x298dfa(0x1bd)],'files':[{'type':a121_0x298dfa(0x1b7),'path':'.agent/skills/lovrabet/SKILL.md','template':a121_0x298dfa(0x197)}]}};export const CORE_IDE_LIST=['claude','cline',a121_0x298dfa(0x1ae),'codex',a121_0x298dfa(0x18b),'opencode',a121_0x298dfa(0x1bf),a121_0x298dfa(0x1c1),'windsurf'];export const IDE_LIST=[a121_0x298dfa(0x1af),a121_0x298dfa(0x192),a121_0x298dfa(0x1aa),a121_0x298dfa(0x1ae),a121_0x298dfa(0x1a3),a121_0x298dfa(0x18b),'opencode',a121_0x298dfa(0x1bf),a121_0x298dfa(0x1c1),a121_0x298dfa(0x1c2),a121_0x298dfa(0x1a5)];export const ALL_CORE_IDES=[a121_0x298dfa(0x18b),a121_0x298dfa(0x1c2),a121_0x298dfa(0x192),a121_0x298dfa(0x1aa),a121_0x298dfa(0x1a3),a121_0x298dfa(0x1b1),'qoder',a121_0x298dfa(0x1ae),'trae'];
@@ -0,0 +1 @@
1
+ function a122_0x3fe6(_0x37d601,_0x4d54dd){_0x37d601=_0x37d601-0x82;const _0x58fbb2=a122_0x58fb();let _0x3fe631=_0x58fbb2[_0x37d601];return _0x3fe631;}(function(_0x3cd59e,_0xce2d48){const _0x3af97f=a122_0x3fe6,_0x473575=_0x3cd59e();while(!![]){try{const _0x27d83f=parseInt(_0x3af97f(0x99))/0x1*(-parseInt(_0x3af97f(0x87))/0x2)+-parseInt(_0x3af97f(0x89))/0x3+parseInt(_0x3af97f(0x86))/0x4+-parseInt(_0x3af97f(0x84))/0x5*(parseInt(_0x3af97f(0x8b))/0x6)+-parseInt(_0x3af97f(0x8f))/0x7+-parseInt(_0x3af97f(0x8c))/0x8+parseInt(_0x3af97f(0x8e))/0x9;if(_0x27d83f===_0xce2d48)break;else _0x473575['push'](_0x473575['shift']());}catch(_0x1c034c){_0x473575['push'](_0x473575['shift']());}}}(a122_0x58fb,0xac5e6));import{execFileSync}from'node:child_process';import{existsSync}from'node:fs';import{createRequire}from'node:module';import a122_0x4d9ca4 from'node:path';import{CliErrors}from'../errors.js';const MAX_BUFFER=0x32*0x400*0x400;function a122_0x58fb(){const _0x3320e2=['6412640CRzGFO','utf8','29188278LjFnHK','2688567ViPyoN','resolve','jq.exe','stderr','node-jq/package.json','test','toString','trim','validation','pipe','1GZQLvy','platform','jq:\x20','join','win32','dirname','257520qDsIAE','--jq\x20needs\x20a\x20jq\x20binary.\x20Bundled\x20path\x20(from\x20node-jq)\x20was\x20not\x20found\x20and\x20`jq`\x20is\x20not\x20on\x20PATH.\x20Reinstall\x20dependencies\x20(allow\x20install\x20scripts),\x20set\x20JQ_PATH\x20to\x20a\x20jq\x20executable,\x20or\x20install\x20jq:\x20https://jqlang.org/','1775720TOibfN','1325234uVghGZ','code','2934780NcIZMa','ENOENT','18VjztlH'];a122_0x58fb=function(){return _0x3320e2;};return a122_0x58fb();}function resolveJqBinary(){const _0x149234=a122_0x3fe6;try{const _0x95df20=createRequire(import.meta.url),_0x282d97=a122_0x4d9ca4[_0x149234(0x83)](_0x95df20[_0x149234(0x90)](_0x149234(0x93))),_0x4beaf9=a122_0x4d9ca4['join'](_0x282d97,'bin'),_0x1db2d3=process[_0x149234(0x9a)]===_0x149234(0x82)?_0x149234(0x91):'jq',_0x593cd1=a122_0x4d9ca4[_0x149234(0x9c)](_0x4beaf9,_0x1db2d3);if(existsSync(_0x593cd1))return _0x593cd1;}catch{}return'jq';}export function applyJqFilter(_0xe86c5b,_0x563d5d){const _0xf32f6f=a122_0x3fe6,_0x16778b=resolveJqBinary();try{return execFileSync(_0x16778b,[_0x563d5d],{'input':_0xe86c5b,'encoding':_0xf32f6f(0x8d),'maxBuffer':MAX_BUFFER,'stdio':[_0xf32f6f(0x98),_0xf32f6f(0x98),'pipe']});}catch(_0x46f5bc){const _0x1964ef=_0x46f5bc;if(_0x1964ef[_0xf32f6f(0x88)]===_0xf32f6f(0x8a))throw CliErrors[_0xf32f6f(0x97)](_0xf32f6f(0x85),'e.g.\x20brew\x20install\x20jq\x20—\x20or\x20npm\x20install\x20with\x20scripts\x20enabled\x20so\x20node-jq\x20can\x20download\x20jq');const _0x3bae85=_0x1964ef[_0xf32f6f(0x92)]?.[_0xf32f6f(0x95)]?.()[_0xf32f6f(0x96)]()??'',_0xbb777f=(_0x1964ef['message']??String(_0x46f5bc))[_0xf32f6f(0x96)](),_0x1a79f9=_0x3bae85||_0xbb777f,_0x5e3e5b=/^\s*jq:/i[_0xf32f6f(0x94)](_0x1a79f9)?_0x1a79f9:_0xf32f6f(0x9b)+_0x1a79f9;throw CliErrors[_0xf32f6f(0x97)](_0x5e3e5b);}}
@@ -1 +1 @@
1
- (function(_0x1a1cbe,_0x4f757e){const _0x15a994=a119_0x4af3,_0x42f1f6=_0x1a1cbe();while(!![]){try{const _0x59798b=parseInt(_0x15a994(0x1d2))/0x1+parseInt(_0x15a994(0x1c3))/0x2+-parseInt(_0x15a994(0x1c6))/0x3*(-parseInt(_0x15a994(0x1cd))/0x4)+parseInt(_0x15a994(0x1cb))/0x5+-parseInt(_0x15a994(0x1c8))/0x6+parseInt(_0x15a994(0x1c4))/0x7+parseInt(_0x15a994(0x1d1))/0x8*(-parseInt(_0x15a994(0x1ca))/0x9);if(_0x59798b===_0x4f757e)break;else _0x42f1f6['push'](_0x42f1f6['shift']());}catch(_0x2677d2){_0x42f1f6['push'](_0x42f1f6['shift']());}}}(a119_0x2c84,0x86e79));function a119_0x2c84(){const _0x55eae4=['5594157OODWjI','4483445FBwgji','now','116fyjazA','sdk','cli','application/json','40rupUMO','959969muyWEV','810994XkZNsG','7678475JMjnTR','node','63237mGyFiO','stableVersion','1859622awFZdI','/config.json'];a119_0x2c84=function(){return _0x55eae4;};return a119_0x2c84();}import{getTemplateBaseUrl}from'./config.js';export async function fetchCdnConfig(){const _0x21493b=a119_0x4af3;try{const _0x26a0cf=getTemplateBaseUrl(),_0x3d3c3f=_0x26a0cf+_0x21493b(0x1c9),_0x5a848d=await fetch(_0x3d3c3f,{'headers':{'Accept':_0x21493b(0x1d0)}});if(!_0x5a848d['ok'])return null;const _0xc046ea=await _0x5a848d['json']();if(!_0xc046ea[_0x21493b(0x1cf)]?.[_0x21493b(0x1c7)]||!_0xc046ea[_0x21493b(0x1ce)]?.[_0x21493b(0x1c5)]?.[_0x21493b(0x1c7)])return null;return _0xc046ea;}catch{return null;}}function a119_0x4af3(_0x1b3f10,_0x3e264d){_0x1b3f10=_0x1b3f10-0x1c3;const _0x2c84a7=a119_0x2c84();let _0x4af327=_0x2c84a7[_0x1b3f10];return _0x4af327;}let cachedConfig=null,cacheTime=0x0;const CACHE_TTL=0x5*0x3c*0x3e8;export async function getCdnConfig(){const _0xf9c01d=a119_0x4af3,_0x271661=Date[_0xf9c01d(0x1cc)]();if(cachedConfig&&_0x271661-cacheTime<CACHE_TTL)return cachedConfig;const _0x596f55=await fetchCdnConfig();return _0x596f55&&(cachedConfig=_0x596f55,cacheTime=_0x271661),_0x596f55;}export function clearCdnConfigCache(){cachedConfig=null,cacheTime=0x0;}
1
+ (function(_0x429d65,_0x2c5514){const _0x289750=a123_0x5520,_0x37853d=_0x429d65();while(!![]){try{const _0x2fe888=-parseInt(_0x289750(0xc6))/0x1*(-parseInt(_0x289750(0xcf))/0x2)+parseInt(_0x289750(0xc7))/0x3+-parseInt(_0x289750(0xca))/0x4*(-parseInt(_0x289750(0xcc))/0x5)+parseInt(_0x289750(0xce))/0x6+-parseInt(_0x289750(0xc9))/0x7+parseInt(_0x289750(0xcd))/0x8*(parseInt(_0x289750(0xc5))/0x9)+-parseInt(_0x289750(0xd0))/0xa;if(_0x2fe888===_0x2c5514)break;else _0x37853d['push'](_0x37853d['shift']());}catch(_0x49fb1a){_0x37853d['push'](_0x37853d['shift']());}}}(a123_0x3e10,0x749e4));import{getTemplateBaseUrl}from'../utils/config.js';function a123_0x3e10(){const _0x4c3066=['14174ZqiwJu','20831610lqlGMe','/config.json','node','stableVersion','sdk','490545prflQe','61LdLYWJ','711180VHIDvE','now','1197567MlsiBJ','592856IDgQOR','json','20CAZpfL','80cecVsY','5547822XDVtqd'];a123_0x3e10=function(){return _0x4c3066;};return a123_0x3e10();}function a123_0x5520(_0x301fb3,_0x5c9beb){_0x301fb3=_0x301fb3-0xc1;const _0x3e10ac=a123_0x3e10();let _0x55203=_0x3e10ac[_0x301fb3];return _0x55203;}export async function fetchCdnConfig(){const _0x535347=a123_0x5520;try{const _0x57e66e=getTemplateBaseUrl(),_0x3ab046=_0x57e66e+_0x535347(0xc1),_0x200a2b=await fetch(_0x3ab046,{'headers':{'Accept':'application/json'}});if(!_0x200a2b['ok'])return null;const _0x2ee0be=await _0x200a2b[_0x535347(0xcb)]();if(!_0x2ee0be['cli']?.['stableVersion']||!_0x2ee0be[_0x535347(0xc4)]?.[_0x535347(0xc2)]?.[_0x535347(0xc3)])return null;return _0x2ee0be;}catch{return null;}}let cachedConfig=null,cacheTime=0x0;const CACHE_TTL=0x5*0x3c*0x3e8;export async function getCdnConfig(){const _0x4df73d=a123_0x5520,_0x2209da=Date[_0x4df73d(0xc8)]();if(cachedConfig&&_0x2209da-cacheTime<CACHE_TTL)return cachedConfig;const _0x45e7f8=await fetchCdnConfig();return _0x45e7f8&&(cachedConfig=_0x45e7f8,cacheTime=_0x2209da),_0x45e7f8;}export function clearCdnConfigCache(){cachedConfig=null,cacheTime=0x0;}
@@ -1 +1 @@
1
- function a120_0x43fe(_0xa5841e,_0x4fae75){_0xa5841e=_0xa5841e-0xb7;const _0x4d6443=a120_0x4d64();let _0x43fe75=_0x4d6443[_0xa5841e];return _0x43fe75;}const a120_0xbf2119=a120_0x43fe;(function(_0x4c26f2,_0x4328e3){const _0x147878=a120_0x43fe,_0x3474a8=_0x4c26f2();while(!![]){try{const _0x5c823d=-parseInt(_0x147878(0xd0))/0x1*(-parseInt(_0x147878(0xca))/0x2)+-parseInt(_0x147878(0xc6))/0x3+-parseInt(_0x147878(0xd8))/0x4*(parseInt(_0x147878(0xcc))/0x5)+-parseInt(_0x147878(0xbe))/0x6*(parseInt(_0x147878(0xc1))/0x7)+parseInt(_0x147878(0xcd))/0x8*(parseInt(_0x147878(0xc7))/0x9)+-parseInt(_0x147878(0xcb))/0xa*(parseInt(_0x147878(0xbc))/0xb)+parseInt(_0x147878(0xd3))/0xc;if(_0x5c823d===_0x4328e3)break;else _0x3474a8['push'](_0x3474a8['shift']());}catch(_0x5abac2){_0x3474a8['push'](_0x3474a8['shift']());}}}(a120_0x4d64,0x98278));import a120_0x4e47ee from'node:fs';import a120_0xae3625 from'node:path';import a120_0x446a1a from'semver';import{getCdnConfig}from'./cdn-config.js';const FALLBACK_MIN_SDK_VERSION=a120_0xbf2119(0xbd);function isNonNumericVersion(_0x55dc68){const _0x6a9132=a120_0xbf2119,_0x442d2b=[/^latest$/i,/^beta$/i,/^alpha$/i,/^canary$/i,/^\*$/,/^x$/];return _0x442d2b['some'](_0x21f4ab=>_0x21f4ab[_0x6a9132(0xd4)](_0x55dc68));}function getInstalledVersion(_0x49e443,_0x21d706){const _0x27732d=a120_0xbf2119;try{const _0x14e8aa=a120_0xae3625[_0x27732d(0xda)](_0x49e443,_0x27732d(0xcf),_0x21d706,'package.json');if(a120_0x4e47ee[_0x27732d(0xd1)](_0x14e8aa)){const _0x5c7e2d=JSON[_0x27732d(0xd5)](a120_0x4e47ee[_0x27732d(0xbf)](_0x14e8aa,'utf-8'));return _0x5c7e2d[_0x27732d(0xc4)]||null;}}catch{}return null;}async function getSdkStableVersion(){const _0x4ef49b=a120_0xbf2119;try{const _0x2534e4=await getCdnConfig();return _0x2534e4?.[_0x4ef49b(0xc2)]?.['node']?.[_0x4ef49b(0xc9)]||null;}catch{return null;}}async function getSdkPackageName(){const _0x21d754=a120_0xbf2119;try{const _0x5913f3=await getCdnConfig();return _0x5913f3?.[_0x21d754(0xc2)]?.['node']?.[_0x21d754(0xd6)]||'@lovrabet/sdk';}catch{return _0x21d754(0xdb);}}export async function checkSdkVersion(_0x4fd3b4){const _0x7836a=a120_0xbf2119,_0x4af0fc=a120_0xae3625['join'](_0x4fd3b4,_0x7836a(0xbb)),[_0x3a62b1,_0x4ff2ca]=await Promise[_0x7836a(0xb9)]([getSdkStableVersion(),getSdkPackageName()]),_0x2f6ed4=_0x3a62b1||FALLBACK_MIN_SDK_VERSION;if(!a120_0x4e47ee[_0x7836a(0xd1)](_0x4af0fc))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x2f6ed4,'packageName':_0x4ff2ca,'stableVersion':_0x3a62b1};try{const _0x13b5df=JSON[_0x7836a(0xd5)](a120_0x4e47ee[_0x7836a(0xbf)](_0x4af0fc,_0x7836a(0xb8))),_0x27cd71=_0x13b5df[_0x7836a(0xc5)]||{},_0x255307=_0x13b5df[_0x7836a(0xc3)]||{},_0x4c60ed=_0x27cd71[_0x4ff2ca]||_0x255307[_0x4ff2ca];if(!_0x4c60ed)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x2f6ed4,'packageName':_0x4ff2ca,'stableVersion':_0x3a62b1};let _0x20c37e=getInstalledVersion(_0x4fd3b4,_0x4ff2ca);!_0x20c37e&&(_0x20c37e=_0x4c60ed);if(isNonNumericVersion(_0x4c60ed))return{'installed':!![],'version':_0x20c37e,'needsUpgrade':![],'minVersion':_0x2f6ed4,'packageName':_0x4ff2ca,'stableVersion':_0x3a62b1};const _0x99992c=a120_0x446a1a[_0x7836a(0xd9)](_0x20c37e),_0x31bf54=a120_0x446a1a['coerce'](_0x2f6ed4),_0x474676=_0x99992c&&_0x31bf54?a120_0x446a1a['lt'](_0x99992c,_0x31bf54):![];return{'installed':!![],'version':_0x20c37e,'needsUpgrade':_0x474676,'minVersion':_0x2f6ed4,'packageName':_0x4ff2ca,'stableVersion':_0x3a62b1};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x2f6ed4,'packageName':_0x4ff2ca,'stableVersion':_0x3a62b1};}}export function checkSdkVersionSync(_0x10b1ac){const _0x3b08db=a120_0xbf2119,_0x4055d0=a120_0xae3625['join'](_0x10b1ac,_0x3b08db(0xbb)),_0x25f8ba=_0x3b08db(0xdb);if(!a120_0x4e47ee[_0x3b08db(0xd1)](_0x4055d0))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x25f8ba,'stableVersion':null};try{const _0x492124=JSON[_0x3b08db(0xd5)](a120_0x4e47ee[_0x3b08db(0xbf)](_0x4055d0,_0x3b08db(0xb8))),_0x26df44=_0x492124[_0x3b08db(0xc5)]||{},_0x35e2ed=_0x492124[_0x3b08db(0xc3)]||{},_0xae46bf=_0x26df44[_0x25f8ba]||_0x35e2ed[_0x25f8ba];if(!_0xae46bf)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x25f8ba,'stableVersion':null};let _0x571601=getInstalledVersion(_0x10b1ac,_0x25f8ba);!_0x571601&&(_0x571601=_0xae46bf);if(isNonNumericVersion(_0xae46bf))return{'installed':!![],'version':_0x571601,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x25f8ba,'stableVersion':null};const _0x5586e0=a120_0x446a1a['coerce'](_0x571601),_0x441294=_0x5586e0?a120_0x446a1a['lt'](_0x5586e0,FALLBACK_MIN_SDK_VERSION):![];return{'installed':!![],'version':_0x571601,'needsUpgrade':_0x441294,'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x25f8ba,'stableVersion':null};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x25f8ba,'stableVersion':null};}}function a120_0x4d64(){const _0x1a86a4=['node_modules','31chXSbt','existsSync','↪\x20SDK\x20update\x20available','30125616VjsgeT','test','parse','packageName','\x20\x20\x20Stable\x20version:\x20','174012bdUdDb','coerce','join','@lovrabet/sdk','\x20\x20\x20Upgrade\x20command:\x20','utf8','all','npm\x20install\x20','package.json','820699juztzF','1.2.0','48CwQnwu','readFileSync','latest','473074EmbUnP','sdk','devDependencies','version','dependencies','3374949wwGYTY','160299MwoACT','log','stableVersion','1086KzRvjo','50YOWpgX','5kMtISK','80WXoqDk','\x1b[0m'];a120_0x4d64=function(){return _0x1a86a4;};return a120_0x4d64();}export function printSdkUpgradeWarning(_0x34def8){const _0x5d3c0e=a120_0xbf2119;if(!_0x34def8['needsUpgrade'])return;const _0x577575='\x1b[33m',_0x33840d=_0x5d3c0e(0xce),_0x4f221d='\x1b[1m',_0x16b19c=_0x34def8[_0x5d3c0e(0xd6)]||_0x5d3c0e(0xdb),_0x1d83e3=_0x34def8[_0x5d3c0e(0xc9)]||_0x34def8['minVersion'],_0x59d219=_0x5d3c0e(0xba)+_0x16b19c+'@'+(_0x1d83e3||_0x5d3c0e(0xc0));console['log'](),console[_0x5d3c0e(0xc8)](''+_0x577575+_0x4f221d+_0x5d3c0e(0xd2)+_0x33840d),console[_0x5d3c0e(0xc8)](_0x577575+'\x20\x20\x20Current\x20version:\x20'+_0x16b19c+'@'+_0x34def8['version']+_0x33840d),console[_0x5d3c0e(0xc8)](_0x577575+_0x5d3c0e(0xd7)+_0x1d83e3+_0x33840d),console[_0x5d3c0e(0xc8)](_0x577575+_0x5d3c0e(0xb7)+_0x59d219+_0x33840d),console[_0x5d3c0e(0xc8)]();}
1
+ const a124_0x2e3c3b=a124_0x2f42;(function(_0x2c089d,_0x52a6c0){const _0x2e96f4=a124_0x2f42,_0xc861ee=_0x2c089d();while(!![]){try{const _0x28f84e=-parseInt(_0x2e96f4(0x1dc))/0x1*(parseInt(_0x2e96f4(0x1d6))/0x2)+parseInt(_0x2e96f4(0x1da))/0x3+-parseInt(_0x2e96f4(0x1ce))/0x4+-parseInt(_0x2e96f4(0x1f0))/0x5*(parseInt(_0x2e96f4(0x1df))/0x6)+-parseInt(_0x2e96f4(0x1db))/0x7+-parseInt(_0x2e96f4(0x1e4))/0x8+parseInt(_0x2e96f4(0x1de))/0x9*(parseInt(_0x2e96f4(0x1e1))/0xa);if(_0x28f84e===_0x52a6c0)break;else _0xc861ee['push'](_0xc861ee['shift']());}catch(_0xc98e57){_0xc861ee['push'](_0xc861ee['shift']());}}}(a124_0x5d3d,0x9970f));import a124_0x5dd442 from'node:fs';import a124_0x2a689c from'node:path';import a124_0x13c573 from'semver';import{getCdnConfig}from'../utils/cdn-config.js';const FALLBACK_MIN_SDK_VERSION=a124_0x2e3c3b(0x1d4);function a124_0x2f42(_0xf033f2,_0x41fd86){_0xf033f2=_0xf033f2-0x1ce;const _0x5d3dbc=a124_0x5d3d();let _0x2f42dd=_0x5d3dbc[_0xf033f2];return _0x2f42dd;}function isNonNumericVersion(_0x4cd4c1){const _0xebd032=a124_0x2e3c3b,_0x107d80=[/^latest$/i,/^beta$/i,/^alpha$/i,/^canary$/i,/^\*$/,/^x$/];return _0x107d80['some'](_0x30be61=>_0x30be61[_0xebd032(0x1dd)](_0x4cd4c1));}function getInstalledVersion(_0x3eb1d4,_0x1a5d60){const _0x3f24b9=a124_0x2e3c3b;try{const _0x121c13=a124_0x2a689c[_0x3f24b9(0x1d7)](_0x3eb1d4,'node_modules',_0x1a5d60,'package.json');if(a124_0x5dd442[_0x3f24b9(0x1eb)](_0x121c13)){const _0x8c09a8=JSON[_0x3f24b9(0x1e8)](a124_0x5dd442[_0x3f24b9(0x1d1)](_0x121c13,'utf-8'));return _0x8c09a8['version']||null;}}catch{}return null;}async function getSdkStableVersion(){const _0x3b82fb=a124_0x2e3c3b;try{const _0x555fc0=await getCdnConfig();return _0x555fc0?.[_0x3b82fb(0x1d5)]?.['node']?.['stableVersion']||null;}catch{return null;}}async function getSdkPackageName(){const _0x30dcab=a124_0x2e3c3b;try{const _0x339e03=await getCdnConfig();return _0x339e03?.[_0x30dcab(0x1d5)]?.[_0x30dcab(0x1e6)]?.[_0x30dcab(0x1d9)]||'@lovrabet/sdk';}catch{return'@lovrabet/sdk';}}export async function checkSdkVersion(_0x49b459){const _0xab517c=a124_0x2e3c3b,_0x4481b8=a124_0x2a689c[_0xab517c(0x1d7)](_0x49b459,'package.json'),[_0x5c8ca9,_0x216f8b]=await Promise['all']([getSdkStableVersion(),getSdkPackageName()]),_0x5d0a94=_0x5c8ca9||FALLBACK_MIN_SDK_VERSION;if(!a124_0x5dd442[_0xab517c(0x1eb)](_0x4481b8))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x5d0a94,'packageName':_0x216f8b,'stableVersion':_0x5c8ca9};try{const _0x3a32f9=JSON[_0xab517c(0x1e8)](a124_0x5dd442[_0xab517c(0x1d1)](_0x4481b8,'utf8')),_0x17fb97=_0x3a32f9[_0xab517c(0x1e9)]||{},_0xa7bacb=_0x3a32f9['devDependencies']||{},_0x2267ce=_0x17fb97[_0x216f8b]||_0xa7bacb[_0x216f8b];if(!_0x2267ce)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x5d0a94,'packageName':_0x216f8b,'stableVersion':_0x5c8ca9};let _0xca99d2=getInstalledVersion(_0x49b459,_0x216f8b);!_0xca99d2&&(_0xca99d2=_0x2267ce);if(isNonNumericVersion(_0x2267ce))return{'installed':!![],'version':_0xca99d2,'needsUpgrade':![],'minVersion':_0x5d0a94,'packageName':_0x216f8b,'stableVersion':_0x5c8ca9};const _0x7b540b=a124_0x13c573[_0xab517c(0x1d0)](_0xca99d2),_0x29680d=a124_0x13c573['coerce'](_0x5d0a94),_0x228d2a=_0x7b540b&&_0x29680d?a124_0x13c573['lt'](_0x7b540b,_0x29680d):![];return{'installed':!![],'version':_0xca99d2,'needsUpgrade':_0x228d2a,'minVersion':_0x5d0a94,'packageName':_0x216f8b,'stableVersion':_0x5c8ca9};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x5d0a94,'packageName':_0x216f8b,'stableVersion':_0x5c8ca9};}}export function checkSdkVersionSync(_0x4f6588){const _0x345517=a124_0x2e3c3b,_0x2818e9=a124_0x2a689c[_0x345517(0x1d7)](_0x4f6588,_0x345517(0x1cf)),_0x4dccd0=_0x345517(0x1ed);if(!a124_0x5dd442[_0x345517(0x1eb)](_0x2818e9))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x4dccd0,'stableVersion':null};try{const _0x25bef0=JSON[_0x345517(0x1e8)](a124_0x5dd442['readFileSync'](_0x2818e9,_0x345517(0x1d8))),_0x346f5e=_0x25bef0[_0x345517(0x1e9)]||{},_0x26d026=_0x25bef0[_0x345517(0x1d2)]||{},_0x284adb=_0x346f5e[_0x4dccd0]||_0x26d026[_0x4dccd0];if(!_0x284adb)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x4dccd0,'stableVersion':null};let _0x28231c=getInstalledVersion(_0x4f6588,_0x4dccd0);!_0x28231c&&(_0x28231c=_0x284adb);if(isNonNumericVersion(_0x284adb))return{'installed':!![],'version':_0x28231c,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x4dccd0,'stableVersion':null};const _0x598b9a=a124_0x13c573[_0x345517(0x1d0)](_0x28231c),_0x1b5d25=_0x598b9a?a124_0x13c573['lt'](_0x598b9a,FALLBACK_MIN_SDK_VERSION):![];return{'installed':!![],'version':_0x28231c,'needsUpgrade':_0x1b5d25,'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x4dccd0,'stableVersion':null};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x4dccd0,'stableVersion':null};}}export function printSdkUpgradeWarning(_0x447552){const _0x1c9891=a124_0x2e3c3b;if(!_0x447552['needsUpgrade'])return;const _0x5a9d94=_0x1c9891(0x1d3),_0x17c333=_0x1c9891(0x1ee),_0xcddc27=_0x1c9891(0x1e3),_0x558b44=_0x447552[_0x1c9891(0x1d9)]||'@lovrabet/sdk',_0x10c7f9=_0x447552[_0x1c9891(0x1ea)]||_0x447552[_0x1c9891(0x1e7)],_0xf9dac4=_0x1c9891(0x1ef)+_0x558b44+'@'+(_0x10c7f9||'latest');console['log'](),console[_0x1c9891(0x1e2)](''+_0x5a9d94+_0xcddc27+_0x1c9891(0x1ec)+_0x17c333),console[_0x1c9891(0x1e2)](_0x5a9d94+'\x20\x20\x20Current\x20version:\x20'+_0x558b44+'@'+_0x447552['version']+_0x17c333),console[_0x1c9891(0x1e2)](_0x5a9d94+_0x1c9891(0x1e0)+_0x10c7f9+_0x17c333),console['log'](_0x5a9d94+_0x1c9891(0x1e5)+_0xf9dac4+_0x17c333),console['log']();}function a124_0x5d3d(){const _0x3a5b78=['\x1b[1m','4641288UZXkVT','\x20\x20\x20Upgrade\x20command:\x20','node','minVersion','parse','dependencies','stableVersion','existsSync','↪\x20SDK\x20update\x20available','@lovrabet/sdk','\x1b[0m','npm\x20install\x20','10pnoYze','1693432nASxBX','package.json','coerce','readFileSync','devDependencies','\x1b[33m','1.2.0','sdk','10888jMBlNm','join','utf8','packageName','37932TBphOE','7331737ErBvdD','187BjyvLn','test','9jXlrpk','1259214ZBYyrt','\x20\x20\x20Stable\x20version:\x20','41045270yhcFOK','log'];a124_0x5d3d=function(){return _0x3a5b78;};return a124_0x5d3d();}
@@ -1 +1 @@
1
- (function(_0x28f7d7,_0x1c658e){const _0x29e80d=a121_0x4361,_0x17196a=_0x28f7d7();while(!![]){try{const _0x81ecc1=parseInt(_0x29e80d(0x179))/0x1+parseInt(_0x29e80d(0x16f))/0x2+-parseInt(_0x29e80d(0x17f))/0x3*(parseInt(_0x29e80d(0x176))/0x4)+parseInt(_0x29e80d(0x17e))/0x5*(parseInt(_0x29e80d(0x174))/0x6)+-parseInt(_0x29e80d(0x187))/0x7*(parseInt(_0x29e80d(0x16e))/0x8)+parseInt(_0x29e80d(0x17d))/0x9*(parseInt(_0x29e80d(0x17c))/0xa)+parseInt(_0x29e80d(0x180))/0xb;if(_0x81ecc1===_0x1c658e)break;else _0x17196a['push'](_0x17196a['shift']());}catch(_0x460764){_0x17196a['push'](_0x17196a['shift']());}}}(a121_0x12ca,0xb581f));import{readFileSync}from'node:fs';function a121_0x4361(_0x4471e8,_0xfb1f6d){_0x4471e8=_0x4471e8-0x16c;const _0x12ca46=a121_0x12ca();let _0x436163=_0x12ca46[_0x4471e8];return _0x436163;}import{resolve,dirname}from'node:path';import{fileURLToPath}from'node:url';import a121_0x5c33a1 from'semver';import{getCdnConfig}from'./cdn-config.js';import{NPM_PACKAGE_NAME}from'../constant/cli.js';function getCurrentCliVersion(){const _0x550da3=a121_0x4361;try{const _0x3d29c3=fileURLToPath(import.meta.url),_0x4625dd=resolve(dirname(_0x3d29c3),_0x550da3(0x173)),_0x2ee065=resolve(_0x4625dd,'package.json'),_0x147375=JSON['parse'](readFileSync(_0x2ee065,_0x550da3(0x172)));return _0x147375[_0x550da3(0x178)]||_0x550da3(0x177);}catch{return _0x550da3(0x177);}}function a121_0x12ca(){const _0x497b6a=['177kfqfiO','1112441kNsudD','coerce','↪\x20New\x20version\x20available','currentVersion','\x20\x20\x20Current\x20CLI\x20version:\x20','cli','\x1b[1m','8498MIyxIy','\x20\x20\x20Upgrade\x20command:\x20','npm\x20install\x20-g\x20','some','5112EwAaMY','1122444oAStHw','log','stableVersion','utf-8','../..','76542zXZcFL','\x20\x20\x20Stable\x20version:\x20','6528HuozCz','1.0.0','version','336466wCSxim','@latest','needsUpgrade','10iDypCJ','3368583iAEEBr','95UgilMb'];a121_0x12ca=function(){return _0x497b6a;};return a121_0x12ca();}function isNonNumericVersion(_0x445707){const _0x2b5ef5=a121_0x4361,_0x145f06=[/^latest$/i,/^beta$/i,/^alpha$/i,/^canary$/i,/^\^/,/^~/,/^>/,/^</,/^\*/,/^x$/];return _0x145f06[_0x2b5ef5(0x16d)](_0x41e73b=>_0x41e73b['test'](_0x445707));}export async function checkCliVersion(){const _0x39eec2=a121_0x4361,_0x4c3241=getCurrentCliVersion(),_0x4bb41b=await getCdnConfig(),_0x4610c7=_0x4bb41b?.[_0x39eec2(0x185)]?.[_0x39eec2(0x171)]||null;let _0x2363d9=![];if(_0x4610c7)try{const _0x3f5eb0=a121_0x5c33a1[_0x39eec2(0x181)](_0x4c3241),_0x1ad758=a121_0x5c33a1[_0x39eec2(0x181)](_0x4610c7);_0x3f5eb0&&_0x1ad758&&(_0x2363d9=a121_0x5c33a1['lt'](_0x3f5eb0,_0x1ad758));}catch{_0x2363d9=![];}return{'currentVersion':_0x4c3241,'stableVersion':_0x4610c7,'needsUpgrade':_0x2363d9,'isPreRelease':![]};}export function printCliUpgradeWarning(_0x42ce94){const _0x15dfc1=a121_0x4361;if(!_0x42ce94[_0x15dfc1(0x17b)])return;const _0x2043c7='\x1b[33m',_0x267213='\x1b[0m',_0x21fe21=_0x15dfc1(0x186),_0xfddc4=_0x15dfc1(0x16c)+NPM_PACKAGE_NAME+_0x15dfc1(0x17a);console[_0x15dfc1(0x170)](),console['log'](''+_0x2043c7+_0x21fe21+_0x15dfc1(0x182)+_0x267213),console['log'](_0x2043c7+_0x15dfc1(0x184)+_0x42ce94[_0x15dfc1(0x183)]+_0x267213),console['log'](_0x2043c7+_0x15dfc1(0x175)+_0x42ce94[_0x15dfc1(0x171)]+_0x267213),console['log'](_0x2043c7+_0x15dfc1(0x188)+_0xfddc4+_0x267213),console['log']();}
1
+ (function(_0x5ca064,_0x58c15e){const _0x3ec4fd=a125_0x42ea,_0x25e5dc=_0x5ca064();while(!![]){try{const _0x5b959f=-parseInt(_0x3ec4fd(0x208))/0x1*(parseInt(_0x3ec4fd(0x1ff))/0x2)+-parseInt(_0x3ec4fd(0x206))/0x3+-parseInt(_0x3ec4fd(0x1f6))/0x4*(-parseInt(_0x3ec4fd(0x201))/0x5)+parseInt(_0x3ec4fd(0x207))/0x6*(parseInt(_0x3ec4fd(0x1f2))/0x7)+-parseInt(_0x3ec4fd(0x1f8))/0x8+-parseInt(_0x3ec4fd(0x1fb))/0x9+-parseInt(_0x3ec4fd(0x209))/0xa*(-parseInt(_0x3ec4fd(0x203))/0xb);if(_0x5b959f===_0x58c15e)break;else _0x25e5dc['push'](_0x25e5dc['shift']());}catch(_0x37a3e8){_0x25e5dc['push'](_0x25e5dc['shift']());}}}(a125_0x2875,0x5c203));import{readFileSync}from'node:fs';import{resolve,dirname}from'node:path';import{fileURLToPath}from'node:url';function a125_0x42ea(_0x239942,_0x28ecc3){_0x239942=_0x239942-0x1f1;const _0x287535=a125_0x2875();let _0x42eaab=_0x287535[_0x239942];return _0x42eaab;}function a125_0x2875(){const _0x1dca42=['1.0.0','285859jKqdTZ','\x20\x20\x20Current\x20CLI\x20version:\x20','coerce','some','4tztNua','utf-8','4622088YgQbUe','\x20\x20\x20Stable\x20version:\x20','package.json','6051591URExqi','stableVersion','@latest','../..','12458oYeyRQ','currentVersion','1799915kCkCsF','log','2339942JWiSbE','\x20\x20\x20Upgrade\x20command:\x20','\x1b[33m','1528500IWnOsK','30fXkSke','89XzePIc','100CzIZCm','\x1b[1m','needsUpgrade'];a125_0x2875=function(){return _0x1dca42;};return a125_0x2875();}import a125_0x5a4fcf from'semver';import{getCdnConfig}from'../utils/cdn-config.js';import{NPM_PACKAGE_NAME}from'../constant/cli.js';function getCurrentCliVersion(){const _0x3ba446=a125_0x42ea;try{const _0x21bc25=fileURLToPath(import.meta.url),_0x18f0a4=resolve(dirname(_0x21bc25),_0x3ba446(0x1fe)),_0x34c12e=resolve(_0x18f0a4,_0x3ba446(0x1fa)),_0x3b2996=JSON['parse'](readFileSync(_0x34c12e,_0x3ba446(0x1f7)));return _0x3b2996['version']||'1.0.0';}catch{return _0x3ba446(0x1f1);}}function isNonNumericVersion(_0x49c0bf){const _0x64e786=a125_0x42ea,_0xd6ca93=[/^latest$/i,/^beta$/i,/^alpha$/i,/^canary$/i,/^\^/,/^~/,/^>/,/^</,/^\*/,/^x$/];return _0xd6ca93[_0x64e786(0x1f5)](_0x1008fb=>_0x1008fb['test'](_0x49c0bf));}export async function checkCliVersion(){const _0x4943df=a125_0x42ea,_0x23e211=getCurrentCliVersion(),_0xc0e07a=await getCdnConfig(),_0x8c7b5f=_0xc0e07a?.['cli']?.[_0x4943df(0x1fc)]||null;let _0xf80d50=![];if(_0x8c7b5f)try{const _0x3a4d02=a125_0x5a4fcf[_0x4943df(0x1f4)](_0x23e211),_0x3a28cb=a125_0x5a4fcf[_0x4943df(0x1f4)](_0x8c7b5f);_0x3a4d02&&_0x3a28cb&&(_0xf80d50=a125_0x5a4fcf['lt'](_0x3a4d02,_0x3a28cb));}catch{_0xf80d50=![];}return{'currentVersion':_0x23e211,'stableVersion':_0x8c7b5f,'needsUpgrade':_0xf80d50,'isPreRelease':![]};}export function printCliUpgradeWarning(_0x35d789){const _0x3c5151=a125_0x42ea;if(!_0x35d789[_0x3c5151(0x20b)])return;const _0x12dc04=_0x3c5151(0x205),_0x5c837d='\x1b[0m',_0x2001c6=_0x3c5151(0x20a),_0x84d8f7='npm\x20install\x20-g\x20'+NPM_PACKAGE_NAME+_0x3c5151(0x1fd);console[_0x3c5151(0x202)](),console['log'](''+_0x12dc04+_0x2001c6+'↪\x20New\x20version\x20available'+_0x5c837d),console[_0x3c5151(0x202)](_0x12dc04+_0x3c5151(0x1f3)+_0x35d789[_0x3c5151(0x200)]+_0x5c837d),console[_0x3c5151(0x202)](_0x12dc04+_0x3c5151(0x1f9)+_0x35d789[_0x3c5151(0x1fc)]+_0x5c837d),console[_0x3c5151(0x202)](_0x12dc04+_0x3c5151(0x204)+_0x84d8f7+_0x5c837d),console[_0x3c5151(0x202)]();}
@@ -1 +1 @@
1
- (function(_0x835266,_0x5774f1){const _0x451f5f=a122_0x3f6f,_0x3a0e31=_0x835266();while(!![]){try{const _0xdd98c6=parseInt(_0x451f5f(0x1a7))/0x1*(parseInt(_0x451f5f(0x1a5))/0x2)+-parseInt(_0x451f5f(0x1a3))/0x3+-parseInt(_0x451f5f(0x1ac))/0x4*(-parseInt(_0x451f5f(0x19e))/0x5)+-parseInt(_0x451f5f(0x194))/0x6+-parseInt(_0x451f5f(0x1a4))/0x7*(parseInt(_0x451f5f(0x1a8))/0x8)+-parseInt(_0x451f5f(0x19d))/0x9*(-parseInt(_0x451f5f(0x196))/0xa)+-parseInt(_0x451f5f(0x1a1))/0xb;if(_0xdd98c6===_0x5774f1)break;else _0x3a0e31['push'](_0x3a0e31['shift']());}catch(_0x4fbe2a){_0x3a0e31['push'](_0x3a0e31['shift']());}}}(a122_0x1a94,0xb3816));import{initEnv}from'../constant/env.js';function a122_0x1a94(){const _0x3e8847=['45IYlbbw','265gaZeho','app','apiDir','1545654UAYtBb','replace','1229376vSlZEm','52493raYbyH','6408kHzJiB','appcode','251XAtqcC','512YNJdnB','defaultApp','string','keys','55228sIUsmR','entries','env','object','6287064xRobji','cookie','2554730Pzntig','apps','trim','map','https://g.lovrabet.com/dist/lovrabet-skill','values','template_base_url'];a122_0x1a94=function(){return _0x3e8847;};return a122_0x1a94();}import{readRawConfig}from'../context.js';export{getProjectConfigPath,getGlobalConfigPath}from'../context.js';function a122_0x3f6f(_0x29969f,_0x1c7429){_0x29969f=_0x29969f-0x194;const _0x1a94d1=a122_0x1a94();let _0x3f6f44=_0x1a94d1[_0x29969f];return _0x3f6f44;}export{isInProject}from'../context.js';export function readConfig(_0x4ac76c){const _0x57cb7f=a122_0x3f6f,_0x12f017=readRawConfig(_0x4ac76c);return _0x12f017['env']&&typeof _0x12f017[_0x57cb7f(0x1ae)]==='string'&&initEnv(_0x12f017[_0x57cb7f(0x1ae)]),_0x12f017;}export function getConfigAppCode(){const _0x5ce275=a122_0x3f6f,_0x223866=readRawConfig();if(_0x223866[_0x5ce275(0x197)]&&typeof _0x223866[_0x5ce275(0x197)]===_0x5ce275(0x1af)){const _0x72d582=_0x223866[_0x5ce275(0x1a9)];if(_0x72d582&&_0x223866[_0x5ce275(0x197)][_0x72d582]?.[_0x5ce275(0x1a6)])return String(_0x223866[_0x5ce275(0x197)][_0x72d582]['appcode'])[_0x5ce275(0x198)]();const _0x51cc9b=Object[_0x5ce275(0x19b)](_0x223866[_0x5ce275(0x197)])[0x0];if(_0x51cc9b?.['appcode'])return String(_0x51cc9b['appcode'])[_0x5ce275(0x198)]();}const _0x72cc87=_0x223866[_0x5ce275(0x1a6)]||_0x223866[_0x5ce275(0x19f)];if(typeof _0x72cc87!==_0x5ce275(0x1aa)||_0x72cc87[_0x5ce275(0x198)]()==='')return undefined;return _0x72cc87[_0x5ce275(0x198)]();}export function getMultiAppConfigs(){const _0x53793f=a122_0x3f6f,_0x5a7a4a=readRawConfig(),_0x2f9f5f=_0x5a7a4a[_0x53793f(0x197)];if(!_0x2f9f5f||typeof _0x2f9f5f!==_0x53793f(0x1af)||Object[_0x53793f(0x1ab)](_0x2f9f5f)['length']===0x0)return null;const _0x2ca972=_0x5a7a4a['defaultApp'];return Object[_0x53793f(0x1ad)](_0x2f9f5f)[_0x53793f(0x199)](([_0x415b61,_0x2f23cb])=>({'name':_0x415b61,'appcode':_0x2f23cb?.[_0x53793f(0x1a6)]||'','isDefault':_0x415b61===_0x2ca972,'env':_0x2f23cb?.[_0x53793f(0x1ae)],'apiDir':_0x2f23cb?.[_0x53793f(0x1a0)],'cookie':_0x2f23cb?.[_0x53793f(0x195)]||undefined}))['filter'](_0x402e4f=>_0x402e4f[_0x53793f(0x1a6)]);}export function getTemplateBaseUrl(){const _0x2ad64d=a122_0x3f6f,_0x456dcf=readRawConfig();if(_0x456dcf['template_base_url']&&typeof _0x456dcf[_0x2ad64d(0x19c)]==='string')return _0x456dcf['template_base_url'][_0x2ad64d(0x1a2)](/\/$/,'');return _0x2ad64d(0x19a);}
1
+ (function(_0x50c549,_0x173ce0){const _0x1a5974=a126_0x4f47,_0x1f43c1=_0x50c549();while(!![]){try{const _0x14fa74=-parseInt(_0x1a5974(0x80))/0x1*(-parseInt(_0x1a5974(0x8e))/0x2)+parseInt(_0x1a5974(0x83))/0x3*(parseInt(_0x1a5974(0x88))/0x4)+parseInt(_0x1a5974(0x82))/0x5+parseInt(_0x1a5974(0x7b))/0x6+parseInt(_0x1a5974(0x7e))/0x7+parseInt(_0x1a5974(0x7f))/0x8*(-parseInt(_0x1a5974(0x79))/0x9)+-parseInt(_0x1a5974(0x86))/0xa*(parseInt(_0x1a5974(0x8b))/0xb);if(_0x14fa74===_0x173ce0)break;else _0x1f43c1['push'](_0x1f43c1['shift']());}catch(_0x1e18a6){_0x1f43c1['push'](_0x1f43c1['shift']());}}}(a126_0x2e6c,0x28bdb));import{initEnv}from'../constant/env.js';function a126_0x4f47(_0x35ae3a,_0x1a28bd){_0x35ae3a=_0x35ae3a-0x74;const _0x2e6cd3=a126_0x2e6c();let _0x4f47f9=_0x2e6cd3[_0x35ae3a];return _0x4f47f9;}function a126_0x2e6c(){const _0x5a5bee=['cookie','72TmWhAm','object','1178406XwtsWD','app','length','561113YtwBTD','195544RmZlRp','84496ZElmpq','apiDir','591400HNBYOR','57LpsFgK','entries','defaultApp','761760oKwlmJ','values','7460XXYXrn','appcode','keys','22wNQtja','filter','string','2zABiFw','trim','template_base_url','https://g.lovrabet.com/dist/lovrabet-skill','apps','env','replace'];a126_0x2e6c=function(){return _0x5a5bee;};return a126_0x2e6c();}import{readRawConfig}from'../context.js';export{getProjectConfigPath,getGlobalConfigPath}from'../context.js';export{isInProject}from'../context.js';export function readConfig(_0x2c1ac5){const _0x1b0a98=a126_0x4f47,_0x2395a4=readRawConfig(_0x2c1ac5);return _0x2395a4[_0x1b0a98(0x76)]&&typeof _0x2395a4[_0x1b0a98(0x76)]===_0x1b0a98(0x8d)&&initEnv(_0x2395a4[_0x1b0a98(0x76)]),_0x2395a4;}export function getConfigAppCode(){const _0x267e62=a126_0x4f47,_0x2dac4a=readRawConfig();if(_0x2dac4a[_0x267e62(0x75)]&&typeof _0x2dac4a['apps']===_0x267e62(0x7a)){const _0x81e231=_0x2dac4a[_0x267e62(0x85)];if(_0x81e231&&_0x2dac4a[_0x267e62(0x75)][_0x81e231]?.['appcode'])return String(_0x2dac4a[_0x267e62(0x75)][_0x81e231][_0x267e62(0x89)])[_0x267e62(0x8f)]();const _0x488f99=Object[_0x267e62(0x87)](_0x2dac4a['apps'])[0x0];if(_0x488f99?.[_0x267e62(0x89)])return String(_0x488f99[_0x267e62(0x89)])[_0x267e62(0x8f)]();}const _0x8c79fb=_0x2dac4a[_0x267e62(0x89)]||_0x2dac4a[_0x267e62(0x7c)];if(typeof _0x8c79fb!==_0x267e62(0x8d)||_0x8c79fb['trim']()==='')return undefined;return _0x8c79fb['trim']();}export function getMultiAppConfigs(){const _0x479968=a126_0x4f47,_0x3762ea=readRawConfig(),_0x3d34d2=_0x3762ea['apps'];if(!_0x3d34d2||typeof _0x3d34d2!==_0x479968(0x7a)||Object[_0x479968(0x8a)](_0x3d34d2)[_0x479968(0x7d)]===0x0)return null;const _0x380fcc=_0x3762ea['defaultApp'];return Object[_0x479968(0x84)](_0x3d34d2)['map'](([_0x579771,_0x3d8d46])=>({'name':_0x579771,'appcode':_0x3d8d46?.[_0x479968(0x89)]||'','isDefault':_0x579771===_0x380fcc,'env':_0x3d8d46?.[_0x479968(0x76)],'apiDir':_0x3d8d46?.[_0x479968(0x81)],'cookie':_0x3d8d46?.[_0x479968(0x78)]||undefined}))[_0x479968(0x8c)](_0x24ba73=>_0x24ba73[_0x479968(0x89)]);}export function getTemplateBaseUrl(){const _0x371a77=a126_0x4f47,_0x5f3a58=readRawConfig();if(_0x5f3a58[_0x371a77(0x90)]&&typeof _0x5f3a58['template_base_url']==='string')return _0x5f3a58[_0x371a77(0x90)][_0x371a77(0x77)](/\/$/,'');return _0x371a77(0x74);}
@@ -1 +1 @@
1
- function a123_0x2bca(){const _0x3ad02a=['readdirSync','13665KXbEuo','name','复制目录时出错:','284568GOKFYt','2559375pQKxDK','error','isDirectory','1719ouJVLZ','copyFileSync','mkdirSync','415689VFGwyq','join','628KNxSvx','552974MPXPwY','8688VaUaSf','767430lEWmRt'];a123_0x2bca=function(){return _0x3ad02a;};return a123_0x2bca();}(function(_0xb949bf,_0x269893){const _0x835317=a123_0x3435,_0x111b31=_0xb949bf();while(!![]){try{const _0x5320fc=parseInt(_0x835317(0x1d1))/0x1+parseInt(_0x835317(0x1ca))/0x2+parseInt(_0x835317(0x1c7))/0x3+-parseInt(_0x835317(0x1c9))/0x4*(parseInt(_0x835317(0x1ce))/0x5)+parseInt(_0x835317(0x1cc))/0x6+-parseInt(_0x835317(0x1d2))/0x7+parseInt(_0x835317(0x1cb))/0x8*(parseInt(_0x835317(0x1c4))/0x9);if(_0x5320fc===_0x269893)break;else _0x111b31['push'](_0x111b31['shift']());}catch(_0x280bf1){_0x111b31['push'](_0x111b31['shift']());}}}(a123_0x2bca,0x3aa73));function a123_0x3435(_0x5c0357,_0x4898c2){_0x5c0357=_0x5c0357-0x1c2;const _0x2bca21=a123_0x2bca();let _0x34355a=_0x2bca21[_0x5c0357];return _0x34355a;}import a123_0xf1082a from'node:path';import a123_0xb63ffe from'node:fs';export async function copyDirectory(_0x383a35,_0x298d10){const _0x707386=a123_0x3435;try{const _0x1aee46=a123_0xb63ffe[_0x707386(0x1cd)](_0x383a35,{'withFileTypes':!![]});a123_0xb63ffe[_0x707386(0x1c6)](_0x298d10,{'recursive':!![]});for(const _0x58a9f5 of _0x1aee46){const _0x7a6fdb=a123_0xf1082a[_0x707386(0x1c8)](_0x383a35,_0x58a9f5[_0x707386(0x1cf)]),_0x28df15=a123_0xf1082a['join'](_0x298d10,_0x58a9f5[_0x707386(0x1cf)]);_0x58a9f5[_0x707386(0x1c3)]()?await copyDirectory(_0x7a6fdb,_0x28df15):a123_0xb63ffe[_0x707386(0x1c5)](_0x7a6fdb,_0x28df15);}}catch(_0x529897){console[_0x707386(0x1c2)](_0x707386(0x1d0),_0x529897);}}
1
+ (function(_0xfcd789,_0x1a023d){const _0xcc3ca7=a127_0x4f33,_0xda3cc2=_0xfcd789();while(!![]){try{const _0x55301d=parseInt(_0xcc3ca7(0x8e))/0x1*(-parseInt(_0xcc3ca7(0x95))/0x2)+-parseInt(_0xcc3ca7(0x92))/0x3+-parseInt(_0xcc3ca7(0x99))/0x4+parseInt(_0xcc3ca7(0x93))/0x5*(-parseInt(_0xcc3ca7(0x8d))/0x6)+-parseInt(_0xcc3ca7(0x97))/0x7*(parseInt(_0xcc3ca7(0x8b))/0x8)+parseInt(_0xcc3ca7(0x8c))/0x9*(-parseInt(_0xcc3ca7(0x96))/0xa)+parseInt(_0xcc3ca7(0x98))/0xb;if(_0x55301d===_0x1a023d)break;else _0xda3cc2['push'](_0xda3cc2['shift']());}catch(_0x24a0b7){_0xda3cc2['push'](_0xda3cc2['shift']());}}}(a127_0x1c4f,0xdfc3d));import a127_0x1f8056 from'node:path';function a127_0x1c4f(){const _0x1307d9=['344560uWsMsm','copyFileSync','4kdBKBR','7224800kbbnNX','225645iSriOF','74304659sPFNXD','4385876gTMWmt','name','isDirectory','296NbdWyR','18zFWDlo','24APgrkY','515133GjdMOi','readdirSync','join','复制目录时出错:','2395170qFieyX'];a127_0x1c4f=function(){return _0x1307d9;};return a127_0x1c4f();}import a127_0x2487c3 from'node:fs';function a127_0x4f33(_0xe5713f,_0xdcb6cc){_0xe5713f=_0xe5713f-0x8b;const _0x1c4f76=a127_0x1c4f();let _0x4f3366=_0x1c4f76[_0xe5713f];return _0x4f3366;}export async function copyDirectory(_0x2b480e,_0x1e112d){const _0x3d09a6=a127_0x4f33;try{const _0xbc0db6=a127_0x2487c3[_0x3d09a6(0x8f)](_0x2b480e,{'withFileTypes':!![]});a127_0x2487c3['mkdirSync'](_0x1e112d,{'recursive':!![]});for(const _0xeae5ef of _0xbc0db6){const _0x2d4e6a=a127_0x1f8056[_0x3d09a6(0x90)](_0x2b480e,_0xeae5ef['name']),_0x2fabe3=a127_0x1f8056[_0x3d09a6(0x90)](_0x1e112d,_0xeae5ef[_0x3d09a6(0x9a)]);_0xeae5ef[_0x3d09a6(0x9b)]()?await copyDirectory(_0x2d4e6a,_0x2fabe3):a127_0x2487c3[_0x3d09a6(0x94)](_0x2d4e6a,_0x2fabe3);}}catch(_0x897770){console['error'](_0x3d09a6(0x91),_0x897770);}}
@@ -1 +1 @@
1
- function a124_0x1caf(_0x57c313,_0x1573aa){_0x57c313=_0x57c313-0xbf;const _0x5ae951=a124_0x5ae9();let _0x1caf94=_0x5ae951[_0x57c313];return _0x1caf94;}(function(_0x34ea16,_0x55047a){const _0x2bed64=a124_0x1caf,_0x422ef2=_0x34ea16();while(!![]){try{const _0xd5f90=parseInt(_0x2bed64(0xca))/0x1+parseInt(_0x2bed64(0xc0))/0x2+parseInt(_0x2bed64(0xc8))/0x3+parseInt(_0x2bed64(0xc3))/0x4*(-parseInt(_0x2bed64(0xc7))/0x5)+parseInt(_0x2bed64(0xc2))/0x6*(-parseInt(_0x2bed64(0xc6))/0x7)+parseInt(_0x2bed64(0xc5))/0x8*(-parseInt(_0x2bed64(0xbf))/0x9)+parseInt(_0x2bed64(0xc9))/0xa*(-parseInt(_0x2bed64(0xc4))/0xb);if(_0xd5f90===_0x55047a)break;else _0x422ef2['push'](_0x422ef2['shift']());}catch(_0x8ea5ce){_0x422ef2['push'](_0x422ef2['shift']());}}}(a124_0x5ae9,0xaaa72));import{existsSync,mkdirSync,copyFileSync,readdirSync,statSync}from'node:fs';import{join}from'node:path';function a124_0x5ae9(){const _0x2562fb=['417230Woyybb','1146593bXmvvk','10269bliKOs','1748834DjBwDX','isDirectory','6EJRAYJ','501924CUMHsw','209VDkyRS','72jTULaT','7977186tBOPvE','5ISjwZY','2238207dEzsMH'];a124_0x5ae9=function(){return _0x2562fb;};return a124_0x5ae9();}export async function copyDir(_0x16901f,_0x405a23){const _0x84b8ad=a124_0x1caf,_0x48fdf2=statSync(_0x16901f);if(_0x48fdf2[_0x84b8ad(0xc1)]()){!existsSync(_0x405a23)&&mkdirSync(_0x405a23,{'recursive':!![]});const _0x52cc97=readdirSync(_0x16901f);for(const _0x337b9e of _0x52cc97){await copyDir(join(_0x16901f,_0x337b9e),join(_0x405a23,_0x337b9e));}}else copyFileSync(_0x16901f,_0x405a23);}export function ensureDir(_0x1d391d){!existsSync(_0x1d391d)&&mkdirSync(_0x1d391d,{'recursive':!![]});}export function pathExists(_0x5e35cb){return existsSync(_0x5e35cb);}
1
+ (function(_0xffa258,_0x4b1850){const _0x16a6e8=a128_0x3a36,_0x3909cd=_0xffa258();while(!![]){try{const _0x36f30b=parseInt(_0x16a6e8(0x178))/0x1+-parseInt(_0x16a6e8(0x179))/0x2*(parseInt(_0x16a6e8(0x174))/0x3)+parseInt(_0x16a6e8(0x173))/0x4*(-parseInt(_0x16a6e8(0x170))/0x5)+parseInt(_0x16a6e8(0x171))/0x6+parseInt(_0x16a6e8(0x176))/0x7*(-parseInt(_0x16a6e8(0x172))/0x8)+-parseInt(_0x16a6e8(0x177))/0x9+parseInt(_0x16a6e8(0x175))/0xa;if(_0x36f30b===_0x4b1850)break;else _0x3909cd['push'](_0x3909cd['shift']());}catch(_0x4bb667){_0x3909cd['push'](_0x3909cd['shift']());}}}(a128_0x2fa1,0x1cc02));function a128_0x3a36(_0x555632,_0x304d80){_0x555632=_0x555632-0x16f;const _0x2fa167=a128_0x2fa1();let _0x3a367a=_0x2fa167[_0x555632];return _0x3a367a;}function a128_0x2fa1(){const _0x3d5bb1=['2960eEVInl','539496vLIMMt','408376idQqUb','1584AoFOLS','6OPfodl','4124020AmhaeE','7yAOPWp','1564677zyfEoI','209330RytswZ','134554zlMmpF','isDirectory'];a128_0x2fa1=function(){return _0x3d5bb1;};return a128_0x2fa1();}import{existsSync,mkdirSync,copyFileSync,readdirSync,statSync}from'node:fs';import{join}from'node:path';export async function copyDir(_0x177c49,_0x4f86af){const _0x4c71f4=a128_0x3a36,_0x26735b=statSync(_0x177c49);if(_0x26735b[_0x4c71f4(0x16f)]()){!existsSync(_0x4f86af)&&mkdirSync(_0x4f86af,{'recursive':!![]});const _0x117d60=readdirSync(_0x177c49);for(const _0x3f5ed3 of _0x117d60){await copyDir(join(_0x177c49,_0x3f5ed3),join(_0x4f86af,_0x3f5ed3));}}else copyFileSync(_0x177c49,_0x4f86af);}export function ensureDir(_0x25b5f2){!existsSync(_0x25b5f2)&&mkdirSync(_0x25b5f2,{'recursive':!![]});}export function pathExists(_0x752782){return existsSync(_0x752782);}
@@ -1 +1 @@
1
- const a125_0x5f8407=a125_0x208a;(function(_0x346435,_0x1ea359){const _0x319954=a125_0x208a,_0x568560=_0x346435();while(!![]){try{const _0x1b049e=parseInt(_0x319954(0x10e))/0x1*(parseInt(_0x319954(0x102))/0x2)+parseInt(_0x319954(0x115))/0x3*(parseInt(_0x319954(0x120))/0x4)+parseInt(_0x319954(0x10d))/0x5*(parseInt(_0x319954(0x10a))/0x6)+-parseInt(_0x319954(0x11a))/0x7+parseInt(_0x319954(0x103))/0x8+-parseInt(_0x319954(0x124))/0x9*(parseInt(_0x319954(0x122))/0xa)+-parseInt(_0x319954(0x109))/0xb*(parseInt(_0x319954(0x126))/0xc);if(_0x1b049e===_0x1ea359)break;else _0x568560['push'](_0x568560['shift']());}catch(_0x10f5af){_0x568560['push'](_0x568560['shift']());}}}(a125_0x36c8,0x2e1e2));import{mkdirSync,writeFileSync}from'node:fs';import{dirname,join}from'node:path';import{homedir}from'node:os';function a125_0x208a(_0x5d26e8,_0x28d8a0){_0x5d26e8=_0x5d26e8-0x102;const _0x36c80b=a125_0x36c8();let _0x208a21=_0x36c80b[_0x5d26e8];return _0x208a21;}import{getTemplateBaseUrl}from'./config.js';function getGuidesCdnUrl(){const _0x3f591e=a125_0x208a,_0x1559ab=getTemplateBaseUrl();return _0x1559ab+_0x3f591e(0x116);}const CACHE_DIR=join(homedir(),'.lovrabet',a125_0x5f8407(0x10b));export async function fetchGuidesFromCDN(){const _0x55bc66=a125_0x5f8407,_0x566e7b=getGuidesCdnUrl(),_0x43f587=await fetch(_0x566e7b,{'headers':{'Accept':'application/json'}});if(!_0x43f587['ok'])throw new Error(_0x55bc66(0x106)+_0x43f587[_0x55bc66(0x104)]+'\x20'+_0x43f587[_0x55bc66(0x11c)]);const _0x3b7647=await _0x43f587[_0x55bc66(0x105)]();if(!_0x3b7647[_0x55bc66(0x125)]||typeof _0x3b7647['guides']!==_0x55bc66(0x119))throw new Error(_0x55bc66(0x110));return _0x3b7647;}export function writeGuidesToProject(_0x45f2ce,_0x14b9d9,_0x2a5b76=a125_0x5f8407(0x121),_0x3f9b10){const _0x2d1699=a125_0x5f8407,_0x226d68=join(_0x14b9d9,_0x2a5b76);mkdirSync(_0x226d68,{'recursive':!![]});for(const [_0x49ce1f,_0x401ae8]of Object[_0x2d1699(0x108)](_0x45f2ce[_0x2d1699(0x125)])){let _0x3b6b23=_0x401ae8[_0x2d1699(0x11e)];_0x401ae8[_0x2d1699(0x10c)]&&(_0x3b6b23=appendUpdateTime(_0x3b6b23,_0x401ae8['lastUpdated'])),writeFileSync(join(_0x226d68,_0x49ce1f+_0x2d1699(0x11b)),_0x3b6b23,_0x2d1699(0x117));}}export function appendUpdateTime(_0x4b9067,_0x186c3f){const _0x325a7f=a125_0x5f8407;return _0x4b9067=_0x4b9067[_0x325a7f(0x114)](/\n*>更新时间:.*$/m,''),_0x4b9067['trimEnd']()+('\x0a\x0a>更新时间:'+_0x186c3f);}export function getSkillTemplate(_0x259f8f){const _0x161150=a125_0x5f8407;return _0x259f8f[_0x161150(0x123)]?.[_0x161150(0x11e)]||'';}export function appendExtendContents(_0x4a1224,_0x6afdb6,_0x212631){const _0x2e0b5f=a125_0x5f8407,_0x564129=[];for(const [,_0x1b2189]of Object[_0x2e0b5f(0x108)](_0x6afdb6[_0x2e0b5f(0x125)])){_0x1b2189[_0x2e0b5f(0x112)]&&_0x564129[_0x2e0b5f(0x111)](_0x1b2189[_0x2e0b5f(0x112)][_0x2e0b5f(0x118)]());}if(_0x564129[_0x2e0b5f(0x11f)]===0x0)return _0x4a1224;return _0x4a1224[_0x2e0b5f(0x118)]()+'\x0a\x0a'+_0x564129['join']('\x0a\x0a')+'\x0a';}export function writeSkillFile(_0x16c3ce,_0x3cb72b,_0x512c9d){const _0xe85514=a125_0x5f8407,_0x2b008d=getSkillTemplate(_0x16c3ce);if(!_0x2b008d)throw new Error(_0xe85514(0x11d));const _0xd04c20=dirname(_0x3cb72b);mkdirSync(_0xd04c20,{'recursive':!![]});let _0x2536bf=_0x2b008d[_0xe85514(0x114)](/\{\{IDE_NAME\}\}/g,_0x512c9d);_0x2536bf=appendExtendContents(_0x2536bf,_0x16c3ce),_0x16c3ce[_0xe85514(0x123)][_0xe85514(0x10c)]&&(_0x2536bf=appendUpdateTime(_0x2536bf,_0x16c3ce['skillTemplate'][_0xe85514(0x10c)])),writeFileSync(_0x3cb72b,_0x2536bf,_0xe85514(0x117));}export async function installGuides(_0x27311c){const _0x38e969=a125_0x5f8407,_0x3d40b6=await fetchGuidesFromCDN();return writeGuidesToProject(_0x3d40b6,_0x27311c),Object[_0x38e969(0x113)](_0x3d40b6[_0x38e969(0x125)])[_0x38e969(0x11f)];}function a125_0x36c8(){const _0x10f545=['5nQVmcE','8864AjpOfZ','path','CDN\x20返回数据格式错误','push','extendContent','keys','replace','47163oBRSMC','/skills/guides.json','utf-8','trimEnd','object','1012256ZfESGl','.md','statusText','CDN\x20数据中缺少\x20skillTemplate','content','length','4yocLTD','.lovrabet/skill/guides','20JuYfMh','skillTemplate','478809ZCNGPi','guides','18996mAfFQc','76lCTeGv','2582088XGPEYW','status','json','CDN\x20请求失败:\x20','map','entries','3531EwKJOu','1636422fGNTQN','cache','lastUpdated'];a125_0x36c8=function(){return _0x10f545;};return a125_0x36c8();}export function getGuidesSummary(_0x576213){const _0x2855ac=a125_0x5f8407;return Object[_0x2855ac(0x108)](_0x576213['guides'])[_0x2855ac(0x107)](([_0x41dde0,_0x113fa0])=>({'key':_0x41dde0,'title':_0x113fa0['title'],'path':_0x113fa0[_0x2855ac(0x10f)]}));}
1
+ const a129_0x1bfd6a=a129_0x2e6f;(function(_0x309624,_0x17be81){const _0x335a4a=a129_0x2e6f,_0x28736c=_0x309624();while(!![]){try{const _0x3e09e9=-parseInt(_0x335a4a(0x1a7))/0x1+-parseInt(_0x335a4a(0x19f))/0x2*(-parseInt(_0x335a4a(0x1a6))/0x3)+parseInt(_0x335a4a(0x197))/0x4+-parseInt(_0x335a4a(0x1ad))/0x5*(-parseInt(_0x335a4a(0x1a2))/0x6)+parseInt(_0x335a4a(0x19b))/0x7+-parseInt(_0x335a4a(0x1aa))/0x8*(parseInt(_0x335a4a(0x1a1))/0x9)+parseInt(_0x335a4a(0x1a9))/0xa;if(_0x3e09e9===_0x17be81)break;else _0x28736c['push'](_0x28736c['shift']());}catch(_0x4f76b4){_0x28736c['push'](_0x28736c['shift']());}}}(a129_0x5b9b,0x9835c));import{mkdirSync,writeFileSync}from'node:fs';function a129_0x2e6f(_0x49d767,_0xfe2bbe){_0x49d767=_0x49d767-0x193;const _0x5b9b86=a129_0x5b9b();let _0x2e6f5d=_0x5b9b86[_0x49d767];return _0x2e6f5d;}import{dirname,join}from'node:path';import{homedir}from'node:os';import{getTemplateBaseUrl}from'../utils/config.js';function getGuidesCdnUrl(){const _0x138886=a129_0x2e6f,_0x5a8be6=getTemplateBaseUrl();return _0x5a8be6+_0x138886(0x1a0);}const CACHE_DIR=join(homedir(),a129_0x1bfd6a(0x19e),a129_0x1bfd6a(0x1b1));export async function fetchGuidesFromCDN(){const _0x1c4f70=a129_0x1bfd6a,_0x127853=getGuidesCdnUrl(),_0x5e7ee7=await fetch(_0x127853,{'headers':{'Accept':_0x1c4f70(0x196)}});if(!_0x5e7ee7['ok'])throw new Error(_0x1c4f70(0x1a8)+_0x5e7ee7['status']+'\x20'+_0x5e7ee7['statusText']);const _0x40798e=await _0x5e7ee7['json']();if(!_0x40798e[_0x1c4f70(0x1af)]||typeof _0x40798e[_0x1c4f70(0x1af)]!=='object')throw new Error('CDN\x20返回数据格式错误');return _0x40798e;}export function writeGuidesToProject(_0x1fd16,_0x3d702d,_0x986ef0=a129_0x1bfd6a(0x195),_0x169d22){const _0x22b16c=a129_0x1bfd6a,_0x108554=join(_0x3d702d,_0x986ef0);mkdirSync(_0x108554,{'recursive':!![]});for(const [_0x3d3d36,_0x342a83]of Object['entries'](_0x1fd16[_0x22b16c(0x1af)])){let _0x50f2da=_0x342a83['content'];_0x342a83[_0x22b16c(0x1ae)]&&(_0x50f2da=appendUpdateTime(_0x50f2da,_0x342a83['lastUpdated'])),writeFileSync(join(_0x108554,_0x3d3d36+_0x22b16c(0x199)),_0x50f2da,_0x22b16c(0x1a4));}}export function appendUpdateTime(_0x26ab17,_0x380034){const _0x44f03d=a129_0x1bfd6a;return _0x26ab17=_0x26ab17[_0x44f03d(0x1ac)](/\n*>更新时间:.*$/m,''),_0x26ab17[_0x44f03d(0x19c)]()+(_0x44f03d(0x1b0)+_0x380034);}export function getSkillTemplate(_0x431b68){const _0x57ac87=a129_0x1bfd6a;return _0x431b68[_0x57ac87(0x1a5)]?.['content']||'';}export function appendExtendContents(_0x1b525b,_0x463ebc,_0x3737e5){const _0x2a5053=a129_0x1bfd6a,_0x289df8=[];for(const [,_0x36ce24]of Object['entries'](_0x463ebc[_0x2a5053(0x1af)])){_0x36ce24[_0x2a5053(0x198)]&&_0x289df8[_0x2a5053(0x1ab)](_0x36ce24[_0x2a5053(0x198)]['trimEnd']());}if(_0x289df8[_0x2a5053(0x19d)]===0x0)return _0x1b525b;return _0x1b525b[_0x2a5053(0x19c)]()+'\x0a\x0a'+_0x289df8['join']('\x0a\x0a')+'\x0a';}function a129_0x5b9b(){const _0x59897a=['replace','4080UjYZTF','lastUpdated','guides','\x0a\x0a>更新时间:','cache','title','path','entries','.lovrabet/skill/guides','application/json','1456900AFSiwu','extendContent','.md','map','3716748iJeYLQ','trimEnd','length','.lovrabet','144062mgyhZX','/skills/guides.json','237159KgQzBC','66pBjZtE','CDN\x20数据中缺少\x20skillTemplate','utf-8','skillTemplate','3AilklW','1090080rBKoSc','CDN\x20请求失败:\x20','11326010XZzhwL','120PqRwvz','push'];a129_0x5b9b=function(){return _0x59897a;};return a129_0x5b9b();}export function writeSkillFile(_0x4fb256,_0x5bc9fc,_0x48e637){const _0x37ca71=a129_0x1bfd6a,_0xcf9a16=getSkillTemplate(_0x4fb256);if(!_0xcf9a16)throw new Error(_0x37ca71(0x1a3));const _0x46d8bf=dirname(_0x5bc9fc);mkdirSync(_0x46d8bf,{'recursive':!![]});let _0x2c59c6=_0xcf9a16[_0x37ca71(0x1ac)](/\{\{IDE_NAME\}\}/g,_0x48e637);_0x2c59c6=appendExtendContents(_0x2c59c6,_0x4fb256),_0x4fb256['skillTemplate']['lastUpdated']&&(_0x2c59c6=appendUpdateTime(_0x2c59c6,_0x4fb256[_0x37ca71(0x1a5)]['lastUpdated'])),writeFileSync(_0x5bc9fc,_0x2c59c6,'utf-8');}export async function installGuides(_0x5a3f1b){const _0x336f03=a129_0x1bfd6a,_0x2104da=await fetchGuidesFromCDN();return writeGuidesToProject(_0x2104da,_0x5a3f1b),Object['keys'](_0x2104da[_0x336f03(0x1af)])['length'];}export function getGuidesSummary(_0x5d67ad){const _0x2c15fa=a129_0x1bfd6a;return Object[_0x2c15fa(0x194)](_0x5d67ad[_0x2c15fa(0x1af)])[_0x2c15fa(0x19a)](([_0x185202,_0x387814])=>({'key':_0x185202,'title':_0x387814[_0x2c15fa(0x1b2)],'path':_0x387814[_0x2c15fa(0x193)]}));}
@@ -1 +1 @@
1
- (function(_0x1006bd,_0x573f9d){const _0x5efa85=a126_0x654c,_0x320f8e=_0x1006bd();while(!![]){try{const _0x52c881=-parseInt(_0x5efa85(0x147))/0x1+-parseInt(_0x5efa85(0x14e))/0x2+-parseInt(_0x5efa85(0x15b))/0x3+-parseInt(_0x5efa85(0x159))/0x4+parseInt(_0x5efa85(0x153))/0x5+-parseInt(_0x5efa85(0x152))/0x6+-parseInt(_0x5efa85(0x15a))/0x7*(-parseInt(_0x5efa85(0x15d))/0x8);if(_0x52c881===_0x573f9d)break;else _0x320f8e['push'](_0x320f8e['shift']());}catch(_0x53bd5f){_0x320f8e['push'](_0x320f8e['shift']());}}}(a126_0x23a9,0xe9944));export async function httpRequest(_0x2fef9f,_0x19cc7d={}){const _0x1d425a=a126_0x654c,{timeout:timeout=0x7530,retries:retries=0x3,retryDelay:retryDelay=0x3e8,headers:headers={}}=_0x19cc7d;let _0x894258=null;for(let _0x315aeb=0x0;_0x315aeb<=retries;_0x315aeb++){try{const _0x456ba9=new AbortController(),_0x48d8b5=setTimeout(()=>_0x456ba9['abort'](),timeout),_0x288836=await fetch(_0x2fef9f,{'headers':headers,'signal':_0x456ba9[_0x1d425a(0x150)]});clearTimeout(_0x48d8b5);let _0xf7bab;const _0x4e0668=_0x288836[_0x1d425a(0x143)][_0x1d425a(0x157)](_0x1d425a(0x15e));return _0x4e0668?.[_0x1d425a(0x146)](_0x1d425a(0x155))?_0xf7bab=await _0x288836[_0x1d425a(0x14a)]():_0xf7bab=await _0x288836['text'](),{'ok':_0x288836['ok'],'status':_0x288836[_0x1d425a(0x158)],'statusText':_0x288836[_0x1d425a(0x14c)],'data':_0xf7bab,'headers':_0x288836[_0x1d425a(0x143)],'url':_0x288836[_0x1d425a(0x148)],'text':()=>_0x288836[_0x1d425a(0x149)]()};}catch(_0x38497e){_0x894258=_0x38497e instanceof Error?_0x38497e:new Error(String(_0x38497e));if(_0x315aeb===retries)break;if(shouldRetry(_0x38497e)){console[_0x1d425a(0x14f)](_0x1d425a(0x15c)+retryDelay+_0x1d425a(0x156)+(_0x315aeb+0x1)+_0x1d425a(0x14d)),await sleep(retryDelay);continue;}else break;}}throw _0x894258||new Error('Request\x20failed');}function a126_0x23a9(){const _0x408582=['1820370SNJPjR','message','application/json','ms\x20后进行第\x20','get','status','7156900xTIfDK','35WjSKCY','371220UhkoEa','*\x20请求失败,','9864632FDDPaR','content-type','name','headers','TypeError','ENOTFOUND','includes','517783oOJZFT','url','text','json','fetch','statusText','\x20次重试...','3103652zVoKRI','log','signal','AbortError','9540930gHgMPs'];a126_0x23a9=function(){return _0x408582;};return a126_0x23a9();}function shouldRetry(_0x4e0251){const _0x52833d=a126_0x654c;if(_0x4e0251 instanceof Error){if(_0x4e0251[_0x52833d(0x15f)]===_0x52833d(0x151))return![];if(_0x4e0251[_0x52833d(0x15f)]===_0x52833d(0x144)&&_0x4e0251[_0x52833d(0x154)][_0x52833d(0x146)](_0x52833d(0x14b)))return!![];if(_0x4e0251[_0x52833d(0x154)][_0x52833d(0x146)]('ECONNRESET'))return!![];if(_0x4e0251[_0x52833d(0x154)][_0x52833d(0x146)](_0x52833d(0x145)))return![];}return![];}function a126_0x654c(_0xc8b5c,_0x292b1a){_0xc8b5c=_0xc8b5c-0x143;const _0x23a9a8=a126_0x23a9();let _0x654c7f=_0x23a9a8[_0xc8b5c];return _0x654c7f;}function sleep(_0x35c62c){return new Promise(_0x5c945b=>setTimeout(_0x5c945b,_0x35c62c));}export function validateUrl(_0x56eeb9){try{return new URL(_0x56eeb9),!![];}catch{return![];}}
1
+ function a130_0x2f03(_0x564787,_0x174852){_0x564787=_0x564787-0xfb;const _0x27a6c1=a130_0x27a6();let _0x2f03dd=_0x27a6c1[_0x564787];return _0x2f03dd;}function a130_0x27a6(){const _0xa29663=['url','text','*\x20请求失败,','message','7802118cjTvla','9fbOJSR','1067965RrUpDb','includes','ms\x20后进行第\x20','name','ECONNRESET','945249bUbMwA','log','get','application/json','2649570rIyQKz','33415420yeEgcy','10073032uIqUdo','898GhBstF','Request\x20failed','json','AbortError','abort','6063Rvgeak','headers','4EYpLYg','fetch','ENOTFOUND','\x20次重试...'];a130_0x27a6=function(){return _0xa29663;};return a130_0x27a6();}(function(_0x3dd149,_0x2b078a){const _0x290604=a130_0x2f03,_0x194471=_0x3dd149();while(!![]){try{const _0x8a431a=parseInt(_0x290604(0x103))/0x1+-parseInt(_0x290604(0x10a))/0x2*(parseInt(_0x290604(0x10f))/0x3)+-parseInt(_0x290604(0x111))/0x4*(-parseInt(_0x290604(0xfe))/0x5)+-parseInt(_0x290604(0xfc))/0x6+-parseInt(_0x290604(0x107))/0x7+parseInt(_0x290604(0x109))/0x8*(-parseInt(_0x290604(0xfd))/0x9)+parseInt(_0x290604(0x108))/0xa;if(_0x8a431a===_0x2b078a)break;else _0x194471['push'](_0x194471['shift']());}catch(_0x5aa03d){_0x194471['push'](_0x194471['shift']());}}}(a130_0x27a6,0x9fe73));export async function httpRequest(_0x41c095,_0x286a46={}){const _0x123324=a130_0x2f03,{timeout:timeout=0x7530,retries:retries=0x3,retryDelay:retryDelay=0x3e8,headers:headers={}}=_0x286a46;let _0x4a2709=null;for(let _0x833a57=0x0;_0x833a57<=retries;_0x833a57++){try{const _0x37d6ea=new AbortController(),_0x6b71b2=setTimeout(()=>_0x37d6ea[_0x123324(0x10e)](),timeout),_0x4412a1=await fetch(_0x41c095,{'headers':headers,'signal':_0x37d6ea['signal']});clearTimeout(_0x6b71b2);let _0x4523ec;const _0x179f0f=_0x4412a1['headers'][_0x123324(0x105)]('content-type');return _0x179f0f?.['includes'](_0x123324(0x106))?_0x4523ec=await _0x4412a1[_0x123324(0x10c)]():_0x4523ec=await _0x4412a1['text'](),{'ok':_0x4412a1['ok'],'status':_0x4412a1['status'],'statusText':_0x4412a1['statusText'],'data':_0x4523ec,'headers':_0x4412a1[_0x123324(0x110)],'url':_0x4412a1[_0x123324(0x115)],'text':()=>_0x4412a1[_0x123324(0x116)]()};}catch(_0x37afb8){_0x4a2709=_0x37afb8 instanceof Error?_0x37afb8:new Error(String(_0x37afb8));if(_0x833a57===retries)break;if(shouldRetry(_0x37afb8)){console[_0x123324(0x104)](_0x123324(0x117)+retryDelay+_0x123324(0x100)+(_0x833a57+0x1)+_0x123324(0x114)),await sleep(retryDelay);continue;}else break;}}throw _0x4a2709||new Error(_0x123324(0x10b));}function shouldRetry(_0x5e84f6){const _0x430f45=a130_0x2f03;if(_0x5e84f6 instanceof Error){if(_0x5e84f6[_0x430f45(0x101)]===_0x430f45(0x10d))return![];if(_0x5e84f6[_0x430f45(0x101)]==='TypeError'&&_0x5e84f6[_0x430f45(0xfb)][_0x430f45(0xff)](_0x430f45(0x112)))return!![];if(_0x5e84f6['message'][_0x430f45(0xff)](_0x430f45(0x102)))return!![];if(_0x5e84f6[_0x430f45(0xfb)]['includes'](_0x430f45(0x113)))return![];}return![];}function sleep(_0x3f19b4){return new Promise(_0x192f64=>setTimeout(_0x192f64,_0x3f19b4));}export function validateUrl(_0x21b8b8){try{return new URL(_0x21b8b8),!![];}catch{return![];}}
@@ -1 +1 @@
1
- (function(_0x9a2df4,_0x560548){const _0x4934f9=a127_0xc47d,_0x3bd283=_0x9a2df4();while(!![]){try{const _0x226019=parseInt(_0x4934f9(0x1a5))/0x1*(parseInt(_0x4934f9(0x1a3))/0x2)+parseInt(_0x4934f9(0x1a1))/0x3+-parseInt(_0x4934f9(0x19f))/0x4+-parseInt(_0x4934f9(0x1a4))/0x5+-parseInt(_0x4934f9(0x1aa))/0x6*(parseInt(_0x4934f9(0x1af))/0x7)+parseInt(_0x4934f9(0x1a2))/0x8*(-parseInt(_0x4934f9(0x1a8))/0x9)+-parseInt(_0x4934f9(0x1ad))/0xa*(-parseInt(_0x4934f9(0x1a6))/0xb);if(_0x226019===_0x560548)break;else _0x3bd283['push'](_0x3bd283['shift']());}catch(_0x51d7e9){_0x3bd283['push'](_0x3bd283['shift']());}}}(a127_0x5414,0x51319));function a127_0xc47d(_0x5e63c0,_0x231ceb){_0x5e63c0=_0x5e63c0-0x19f;const _0x5414df=a127_0x5414();let _0xc47d92=_0x5414df[_0x5e63c0];return _0xc47d92;}function env(_0x12ce88){return process.env[`RABETBASE_${_0x12ce88}`]||process.env[`LOVRABET_${_0x12ce88}`]||undefined;}function a127_0x5414(){const _0xca7b31=['94fXWxOY','2737025nfiLUw','3369STGLnX','8729875heBlcS','stdout','81nHmxdm','stdin','6RKnZcN','nonInteractive','true','20WqdeMZ','setRawMode','1001749NbcdzA','isRaw','2096756xFNYCs','isTTY','488028ejDXct','320888vXfSXQ'];a127_0x5414=function(){return _0xca7b31;};return a127_0x5414();}export function isNonInteractive(_0x51cedb){const _0x11e827=a127_0xc47d;return!!(_0x51cedb[_0x11e827(0x1ab)]||_0x51cedb['ci']||env('CI')===_0x11e827(0x1ac)||process.env.CI==='true'||!process[_0x11e827(0x1a7)][_0x11e827(0x1a0)]||!isStdinRawModeSupported());}function isStdinRawModeSupported(){const _0x126bd9=a127_0xc47d;if(!process[_0x126bd9(0x1a9)][_0x126bd9(0x1a0)])return![];try{const _0x30153c=process[_0x126bd9(0x1a9)][_0x126bd9(0x1b0)];return process[_0x126bd9(0x1a9)][_0x126bd9(0x1ae)](!![]),process[_0x126bd9(0x1a9)]['setRawMode'](_0x30153c??![]),!![];}catch{return![];}}
1
+ (function(_0xa1aed7,_0x4f3777){const _0x575f07=a131_0x9aa4,_0x3b144d=_0xa1aed7();while(!![]){try{const _0x1e8489=parseInt(_0x575f07(0xb4))/0x1*(parseInt(_0x575f07(0xab))/0x2)+parseInt(_0x575f07(0xa7))/0x3*(parseInt(_0x575f07(0xa5))/0x4)+parseInt(_0x575f07(0xb6))/0x5*(-parseInt(_0x575f07(0xb0))/0x6)+parseInt(_0x575f07(0xb7))/0x7*(-parseInt(_0x575f07(0xb5))/0x8)+-parseInt(_0x575f07(0xac))/0x9+-parseInt(_0x575f07(0xae))/0xa+parseInt(_0x575f07(0xa8))/0xb*(parseInt(_0x575f07(0xaf))/0xc);if(_0x1e8489===_0x4f3777)break;else _0x3b144d['push'](_0x3b144d['shift']());}catch(_0x1ba46c){_0x3b144d['push'](_0x3b144d['shift']());}}}(a131_0x1ab9,0x70ba1));function env(_0x2e744b){return process.env[`RABETBASE_${_0x2e744b}`]||process.env[`LOVRABET_${_0x2e744b}`]||undefined;}function a131_0x9aa4(_0x257a54,_0x5566d5){_0x257a54=_0x257a54-0xa5;const _0x1ab938=a131_0x1ab9();let _0x9aa45a=_0x1ab938[_0x257a54];return _0x9aa45a;}function a131_0x1ab9(){const _0x1eb520=['1878030AQrUMl','2895361jqnjJc','176YzCzgJ','nonInteractive','10506qJbKra','37213hDezWH','setRawMode','stdin','10zJplyG','161784eabMpC','stdout','4204620oYdICS','5736yEWFGl','12aPhmsv','isTTY','isRaw','true','58768WTAspW','8ewnwJD'];a131_0x1ab9=function(){return _0x1eb520;};return a131_0x1ab9();}export function isNonInteractive(_0x1a4fb9){const _0x55920a=a131_0x9aa4;return!!(_0x1a4fb9[_0x55920a(0xa6)]||_0x1a4fb9['ci']||env('CI')===_0x55920a(0xb3)||process.env.CI==='true'||!process[_0x55920a(0xad)][_0x55920a(0xb1)]||!isStdinRawModeSupported());}function isStdinRawModeSupported(){const _0x53d843=a131_0x9aa4;if(!process['stdin'][_0x53d843(0xb1)])return![];try{const _0x126190=process[_0x53d843(0xaa)][_0x53d843(0xb2)];return process[_0x53d843(0xaa)]['setRawMode'](!![]),process[_0x53d843(0xaa)][_0x53d843(0xa9)](_0x126190??![]),!![];}catch{return![];}}
@@ -1 +1 @@
1
- const a128_0x40c987=a128_0x48a6;(function(_0x12ffea,_0x26a007){const _0x3f514e=a128_0x48a6,_0x3b9867=_0x12ffea();while(!![]){try{const _0x42b730=parseInt(_0x3f514e(0x9a))/0x1+parseInt(_0x3f514e(0xb6))/0x2+parseInt(_0x3f514e(0xad))/0x3+-parseInt(_0x3f514e(0xb3))/0x4+parseInt(_0x3f514e(0xb1))/0x5*(parseInt(_0x3f514e(0x95))/0x6)+-parseInt(_0x3f514e(0xbb))/0x7*(-parseInt(_0x3f514e(0xa4))/0x8)+-parseInt(_0x3f514e(0xac))/0x9;if(_0x42b730===_0x26a007)break;else _0x3b9867['push'](_0x3b9867['shift']());}catch(_0xf1ff80){_0x3b9867['push'](_0x3b9867['shift']());}}}(a128_0x2b20,0x74003));import a128_0x542c10 from'winston';import a128_0x781118 from'node:fs';import a128_0x1c397e from'node:path';function a128_0x2b20(){const _0x41e7ef=['errors','1310456XCRnHP','combine','clearLogs','605124cuHRnf','printf','warn','setLogPath','message','7lrdDDV','existsSync','winstonLogger','filter','timestamp','info','blue','Failed\x20to\x20read\x20logs:','toISOString','red','success','currentRawCommand','204xbmGIA','initWinstonLogger','level','完成:\x20','transports','816091HFtdRK','format','dirname','addColors','logFilePath','error','utf8','logTask','trim','green','2990424cMvSxX','Failed\x20to\x20clear\x20logs:','yellow','stringify','clear','writeFileSync','command','createLogger','14012901EnZDqq','368058jacfZX','parse','rawCommand','now','109500CzePLX'];a128_0x2b20=function(){return _0x41e7ef;};return a128_0x2b20();}class Logger{[a128_0x40c987(0xbd)];['logFilePath'];['currentRawCommand']='';constructor(){this['logFilePath']='';}['setRawCommand'](_0x211587){this['currentRawCommand']=_0x211587;}['initWinstonLogger'](){const _0x4e9f98=a128_0x40c987,_0x1c3851=a128_0x1c397e[_0x4e9f98(0x9c)](this[_0x4e9f98(0x9e)]);!a128_0x781118['existsSync'](_0x1c3851)&&a128_0x781118['mkdirSync'](_0x1c3851,{'recursive':!![]});const _0x40c632=a128_0x542c10[_0x4e9f98(0x9b)][_0x4e9f98(0xb4)](a128_0x542c10['format'][_0x4e9f98(0x8d)](),a128_0x542c10[_0x4e9f98(0x9b)][_0x4e9f98(0xb2)]({'stack':!![]}),a128_0x542c10[_0x4e9f98(0x9b)][_0x4e9f98(0xb7)](_0x49098e=>{const _0x23972b=_0x4e9f98,_0x3031db={'timestamp':_0x49098e[_0x23972b(0x8d)]||new Date()[_0x23972b(0x91)](),'level':_0x49098e[_0x23972b(0x97)]||_0x23972b(0x8e),'command':_0x49098e[_0x23972b(0xaa)]||'unknown','rawCommand':_0x49098e[_0x23972b(0xaf)]||this[_0x23972b(0x94)]||undefined,'message':_0x49098e[_0x23972b(0xba)]||'','duration':_0x49098e['duration']||undefined,'details':_0x49098e['details']||undefined};return JSON[_0x23972b(0xa7)](_0x3031db);}));this[_0x4e9f98(0xbd)]=a128_0x542c10[_0x4e9f98(0xab)]({'level':_0x4e9f98(0x8e),'format':_0x40c632,'transports':[new a128_0x542c10[(_0x4e9f98(0x99))]['File']({'filename':this[_0x4e9f98(0x9e)],'level':_0x4e9f98(0x8e)})],'silent':![]}),a128_0x542c10[_0x4e9f98(0x9d)]({'success':_0x4e9f98(0xa3),'error':_0x4e9f98(0x92),'warn':_0x4e9f98(0xa6),'info':_0x4e9f98(0x8f)});}[a128_0x40c987(0xb9)](_0x2ae8f4){const _0x5107fd=a128_0x40c987;this[_0x5107fd(0x9e)]=a128_0x1c397e['join'](_0x2ae8f4,'.lovrabet.log'),this[_0x5107fd(0xbd)]&&this[_0x5107fd(0xbd)][_0x5107fd(0xa8)](),this[_0x5107fd(0x96)]();}[a128_0x40c987(0x8e)](_0x357b6e,_0x3b4590,_0x3ddb59){const _0x10ba73=a128_0x40c987;if(!this['logFilePath']||!this[_0x10ba73(0xbd)])return;this[_0x10ba73(0xbd)]['info'](_0x3b4590,{'command':_0x357b6e,'details':_0x3ddb59});}[a128_0x40c987(0x93)](_0x5c2250,_0xd3e503,_0x4e70fb,_0xb53820){const _0x4aa22b=a128_0x40c987;if(!this[_0x4aa22b(0x9e)]||!this[_0x4aa22b(0xbd)])return;this[_0x4aa22b(0xbd)]['log'](_0x4aa22b(0x8e),_0xd3e503,{'level':'success','command':_0x5c2250,'duration':_0x4e70fb,'details':_0xb53820});}['error'](_0x5817dc,_0x28aa91,_0x2960da){const _0x1590a4=a128_0x40c987;if(!this[_0x1590a4(0x9e)]||!this[_0x1590a4(0xbd)])return;this['winstonLogger']['error'](_0x28aa91,{'command':_0x5817dc,'details':_0x2960da});}[a128_0x40c987(0xb8)](_0x265509,_0x324017,_0x2a0d6d){const _0x433421=a128_0x40c987;if(!this[_0x433421(0x9e)]||!this['winstonLogger'])return;this[_0x433421(0xbd)][_0x433421(0xb8)](_0x324017,{'command':_0x265509,'details':_0x2a0d6d});}async[a128_0x40c987(0xa1)](_0x247c48,_0x2e4435,_0x36d0b4){const _0x20ddc8=a128_0x40c987,_0x15653b=Date[_0x20ddc8(0xb0)]();this[_0x20ddc8(0x8e)](_0x247c48,'开始执行:\x20'+_0x2e4435);try{const _0x3c9d54=await _0x36d0b4(),_0x2ea450=Date['now']()-_0x15653b;return this[_0x20ddc8(0x93)](_0x247c48,_0x20ddc8(0x98)+_0x2e4435,_0x2ea450),_0x3c9d54;}catch(_0x10755e){const _0x386b64=Date['now']()-_0x15653b;this[_0x20ddc8(0x9f)](_0x247c48,'失败:\x20'+_0x2e4435,{'error':_0x10755e instanceof Error?_0x10755e['message']:String(_0x10755e),'duration':_0x386b64});throw _0x10755e;}}['readLogs'](){const _0x1b82ac=a128_0x40c987;try{if(!a128_0x781118[_0x1b82ac(0xbc)](this['logFilePath']))return[];const _0x47b7e8=a128_0x781118['readFileSync'](this[_0x1b82ac(0x9e)],_0x1b82ac(0xa0));return _0x47b7e8['split']('\x0a')[_0x1b82ac(0xbe)](_0x4e1d1c=>_0x4e1d1c[_0x1b82ac(0xa2)]())['map'](_0x564d62=>JSON[_0x1b82ac(0xae)](_0x564d62));}catch(_0x2add6f){return console[_0x1b82ac(0xb8)](_0x1b82ac(0x90),_0x2add6f),[];}}[a128_0x40c987(0xb5)](){const _0x3aa6c0=a128_0x40c987;try{a128_0x781118[_0x3aa6c0(0xbc)](this[_0x3aa6c0(0x9e)])&&a128_0x781118[_0x3aa6c0(0xa9)](this[_0x3aa6c0(0x9e)],'',_0x3aa6c0(0xa0));}catch(_0x32e1b5){console[_0x3aa6c0(0xb8)](_0x3aa6c0(0xa5),_0x32e1b5);}}['getWinstonInstance'](){const _0x50a47e=a128_0x40c987;return this[_0x50a47e(0xbd)];}}function a128_0x48a6(_0x8a03,_0x55181f){_0x8a03=_0x8a03-0x8d;const _0x2b2018=a128_0x2b20();let _0x48a646=_0x2b2018[_0x8a03];return _0x48a646;}export const logger=new Logger();
1
+ const a132_0x84c3ba=a132_0x2b76;(function(_0x281b66,_0x3a7f65){const _0x2bc651=a132_0x2b76,_0xfb6854=_0x281b66();while(!![]){try{const _0x7f317a=parseInt(_0x2bc651(0x15c))/0x1+-parseInt(_0x2bc651(0x163))/0x2*(-parseInt(_0x2bc651(0x156))/0x3)+parseInt(_0x2bc651(0x17d))/0x4+-parseInt(_0x2bc651(0x15a))/0x5+parseInt(_0x2bc651(0x160))/0x6+parseInt(_0x2bc651(0x158))/0x7+-parseInt(_0x2bc651(0x17e))/0x8;if(_0x7f317a===_0x3a7f65)break;else _0xfb6854['push'](_0xfb6854['shift']());}catch(_0x232ff1){_0xfb6854['push'](_0xfb6854['shift']());}}}(a132_0x3c9e,0x4c37a));function a132_0x3c9e(){const _0x7a2070=['addColors','writeFileSync','log','command','details','完成:\x20','8628WCOUaf','map','1509599SYVsuf','timestamp','71495GOpQrT','getWinstonInstance','440870MNcUfD','level','setRawCommand','existsSync','1025604QDVTaQ','utf8','parse','106TSXdfl','失败:\x20','mkdirSync','initWinstonLogger','rawCommand','toISOString','error','printf','info','blue','transports','winstonLogger','Failed\x20to\x20clear\x20logs:','clearLogs','errors','.lovrabet.log','format','clear','message','success','stringify','warn','now','readFileSync','red','green','495404EvARzX','6218040enqLnR','logFilePath','Failed\x20to\x20read\x20logs:','currentRawCommand','dirname','logTask','split','combine'];a132_0x3c9e=function(){return _0x7a2070;};return a132_0x3c9e();}import a132_0x2018c2 from'winston';function a132_0x2b76(_0x1b6824,_0x509855){_0x1b6824=_0x1b6824-0x155;const _0x3c9e0d=a132_0x3c9e();let _0x2b76c8=_0x3c9e0d[_0x1b6824];return _0x2b76c8;}import a132_0x5dd394 from'node:fs';import a132_0x3d0ca7 from'node:path';class Logger{[a132_0x84c3ba(0x16e)];[a132_0x84c3ba(0x17f)];['currentRawCommand']='';constructor(){const _0xb97426=a132_0x84c3ba;this[_0xb97426(0x17f)]='';}[a132_0x84c3ba(0x15e)](_0x58f6cc){const _0x630a17=a132_0x84c3ba;this[_0x630a17(0x181)]=_0x58f6cc;}[a132_0x84c3ba(0x166)](){const _0x33c43e=a132_0x84c3ba,_0x3fecfc=a132_0x3d0ca7[_0x33c43e(0x182)](this[_0x33c43e(0x17f)]);!a132_0x5dd394[_0x33c43e(0x15f)](_0x3fecfc)&&a132_0x5dd394[_0x33c43e(0x165)](_0x3fecfc,{'recursive':!![]});const _0x454db0=a132_0x2018c2['format'][_0x33c43e(0x185)](a132_0x2018c2[_0x33c43e(0x173)][_0x33c43e(0x159)](),a132_0x2018c2['format'][_0x33c43e(0x171)]({'stack':!![]}),a132_0x2018c2[_0x33c43e(0x173)][_0x33c43e(0x16a)](_0x4de3c0=>{const _0x4a1080=_0x33c43e,_0x5179e0={'timestamp':_0x4de3c0['timestamp']||new Date()[_0x4a1080(0x168)](),'level':_0x4de3c0[_0x4a1080(0x15d)]||'info','command':_0x4de3c0[_0x4a1080(0x189)]||'unknown','rawCommand':_0x4de3c0[_0x4a1080(0x167)]||this[_0x4a1080(0x181)]||undefined,'message':_0x4de3c0[_0x4a1080(0x175)]||'','duration':_0x4de3c0['duration']||undefined,'details':_0x4de3c0[_0x4a1080(0x18a)]||undefined};return JSON[_0x4a1080(0x177)](_0x5179e0);}));this[_0x33c43e(0x16e)]=a132_0x2018c2['createLogger']({'level':_0x33c43e(0x16b),'format':_0x454db0,'transports':[new a132_0x2018c2[(_0x33c43e(0x16d))]['File']({'filename':this[_0x33c43e(0x17f)],'level':'info'})],'silent':![]}),a132_0x2018c2[_0x33c43e(0x186)]({'success':_0x33c43e(0x17c),'error':_0x33c43e(0x17b),'warn':'yellow','info':_0x33c43e(0x16c)});}['setLogPath'](_0x28296a){const _0x1ef9f7=a132_0x84c3ba;this[_0x1ef9f7(0x17f)]=a132_0x3d0ca7['join'](_0x28296a,_0x1ef9f7(0x172)),this[_0x1ef9f7(0x16e)]&&this[_0x1ef9f7(0x16e)][_0x1ef9f7(0x174)](),this[_0x1ef9f7(0x166)]();}[a132_0x84c3ba(0x16b)](_0x12821a,_0xeb051a,_0x2cce85){const _0x7ee822=a132_0x84c3ba;if(!this[_0x7ee822(0x17f)]||!this['winstonLogger'])return;this[_0x7ee822(0x16e)][_0x7ee822(0x16b)](_0xeb051a,{'command':_0x12821a,'details':_0x2cce85});}['success'](_0xf3f5c4,_0x2e996c,_0x3ad1f5,_0x176f4d){const _0x78dbf0=a132_0x84c3ba;if(!this['logFilePath']||!this[_0x78dbf0(0x16e)])return;this['winstonLogger'][_0x78dbf0(0x188)](_0x78dbf0(0x16b),_0x2e996c,{'level':_0x78dbf0(0x176),'command':_0xf3f5c4,'duration':_0x3ad1f5,'details':_0x176f4d});}['error'](_0x4110cf,_0x11ac4a,_0x4316ed){const _0x27d1ff=a132_0x84c3ba;if(!this[_0x27d1ff(0x17f)]||!this[_0x27d1ff(0x16e)])return;this[_0x27d1ff(0x16e)][_0x27d1ff(0x169)](_0x11ac4a,{'command':_0x4110cf,'details':_0x4316ed});}[a132_0x84c3ba(0x178)](_0x28f65c,_0x2327fc,_0x1c045a){const _0x303fb7=a132_0x84c3ba;if(!this[_0x303fb7(0x17f)]||!this['winstonLogger'])return;this[_0x303fb7(0x16e)]['warn'](_0x2327fc,{'command':_0x28f65c,'details':_0x1c045a});}async[a132_0x84c3ba(0x183)](_0x37255a,_0x471850,_0x256baf){const _0x2ee199=a132_0x84c3ba,_0x9f9b47=Date['now']();this[_0x2ee199(0x16b)](_0x37255a,'开始执行:\x20'+_0x471850);try{const _0x154e99=await _0x256baf(),_0xf01c69=Date[_0x2ee199(0x179)]()-_0x9f9b47;return this[_0x2ee199(0x176)](_0x37255a,_0x2ee199(0x155)+_0x471850,_0xf01c69),_0x154e99;}catch(_0xe3cee8){const _0x58732c=Date['now']()-_0x9f9b47;this[_0x2ee199(0x169)](_0x37255a,_0x2ee199(0x164)+_0x471850,{'error':_0xe3cee8 instanceof Error?_0xe3cee8[_0x2ee199(0x175)]:String(_0xe3cee8),'duration':_0x58732c});throw _0xe3cee8;}}['readLogs'](){const _0x19bf66=a132_0x84c3ba;try{if(!a132_0x5dd394[_0x19bf66(0x15f)](this[_0x19bf66(0x17f)]))return[];const _0x153825=a132_0x5dd394[_0x19bf66(0x17a)](this[_0x19bf66(0x17f)],'utf8');return _0x153825[_0x19bf66(0x184)]('\x0a')['filter'](_0x3b9156=>_0x3b9156['trim']())[_0x19bf66(0x157)](_0x11fe25=>JSON[_0x19bf66(0x162)](_0x11fe25));}catch(_0x5dbaab){return console['warn'](_0x19bf66(0x180),_0x5dbaab),[];}}[a132_0x84c3ba(0x170)](){const _0x1c2a70=a132_0x84c3ba;try{a132_0x5dd394[_0x1c2a70(0x15f)](this[_0x1c2a70(0x17f)])&&a132_0x5dd394[_0x1c2a70(0x187)](this[_0x1c2a70(0x17f)],'',_0x1c2a70(0x161));}catch(_0x13905a){console[_0x1c2a70(0x178)](_0x1c2a70(0x16f),_0x13905a);}}[a132_0x84c3ba(0x15b)](){const _0x3e4b8a=a132_0x84c3ba;return this[_0x3e4b8a(0x16e)];}}export const logger=new Logger();
@@ -1 +1 @@
1
- const a129_0x120c85=a129_0x2ef2;function a129_0x2ef2(_0xf07c92,_0x35f673){_0xf07c92=_0xf07c92-0x1b3;const _0x398545=a129_0x3985();let _0x2ef2cb=_0x398545[_0xf07c92];return _0x2ef2cb;}(function(_0x211449,_0x3b9f2c){const _0x5a4cb1=a129_0x2ef2,_0x90abf6=_0x211449();while(!![]){try{const _0x212305=parseInt(_0x5a4cb1(0x1b3))/0x1*(-parseInt(_0x5a4cb1(0x1b4))/0x2)+-parseInt(_0x5a4cb1(0x1b7))/0x3*(-parseInt(_0x5a4cb1(0x1b8))/0x4)+-parseInt(_0x5a4cb1(0x1b5))/0x5+-parseInt(_0x5a4cb1(0x1ba))/0x6+-parseInt(_0x5a4cb1(0x1b6))/0x7*(-parseInt(_0x5a4cb1(0x1b9))/0x8)+-parseInt(_0x5a4cb1(0x1be))/0x9+parseInt(_0x5a4cb1(0x1bc))/0xa;if(_0x212305===_0x3b9f2c)break;else _0x90abf6['push'](_0x90abf6['shift']());}catch(_0x29b51b){_0x90abf6['push'](_0x90abf6['shift']());}}}(a129_0x3985,0x851fb));export const isWindows=process['platform']===a129_0x120c85(0x1bd);export function resolveNpmBin(_0x49dcb9){const _0x381add=a129_0x120c85;return isWindows?_0x49dcb9+_0x381add(0x1bb):_0x49dcb9;}function a129_0x3985(){const _0x32a8af=['4173UQGNWK','1844qmKQCx','58472BLQjws','2238384nKgiZA','.cmd','19384050asHhqt','win32','6130638XsmLCv','1MRKMsz','1954642ShVzHa','708425nfepUC','133FEefnN'];a129_0x3985=function(){return _0x32a8af;};return a129_0x3985();}
1
+ const a133_0x210f4d=a133_0x30c4;function a133_0x273d(){const _0x1741c8=['18080BXMaCC','1169340OVnteU','win32','709376CfAGUG','5PdUFjj','15JSjbTW','1040174PVCPen','.cmd','8108408XSCSbi','6350323NnguLW','platform','729cKmBaM','8tBzPek','1633584nJTkvB'];a133_0x273d=function(){return _0x1741c8;};return a133_0x273d();}(function(_0x2eab0a,_0x3bb146){const _0x52bfb7=a133_0x30c4,_0x3765cf=_0x2eab0a();while(!![]){try{const _0x2ff7aa=-parseInt(_0x52bfb7(0xbb))/0x1+parseInt(_0x52bfb7(0xbe))/0x2+parseInt(_0x52bfb7(0xbd))/0x3*(parseInt(_0x52bfb7(0xb9))/0x4)+parseInt(_0x52bfb7(0xbc))/0x5*(-parseInt(_0x52bfb7(0xc5))/0x6)+-parseInt(_0x52bfb7(0xc1))/0x7*(parseInt(_0x52bfb7(0xc4))/0x8)+parseInt(_0x52bfb7(0xc3))/0x9*(parseInt(_0x52bfb7(0xb8))/0xa)+parseInt(_0x52bfb7(0xc0))/0xb;if(_0x2ff7aa===_0x3bb146)break;else _0x3765cf['push'](_0x3765cf['shift']());}catch(_0x4a8815){_0x3765cf['push'](_0x3765cf['shift']());}}}(a133_0x273d,0xee67d));export const isWindows=process[a133_0x210f4d(0xc2)]===a133_0x210f4d(0xba);function a133_0x30c4(_0x3f815b,_0x17e73a){_0x3f815b=_0x3f815b-0xb8;const _0x273d20=a133_0x273d();let _0x30c4fe=_0x273d20[_0x3f815b];return _0x30c4fe;}export function resolveNpmBin(_0x93d51e){const _0xe6f2d0=a133_0x210f4d;return isWindows?_0x93d51e+_0xe6f2d0(0xbf):_0x93d51e;}
@@ -1 +1 @@
1
- function a130_0x1c37(_0x3d8eda,_0x25b848){_0x3d8eda=_0x3d8eda-0x1cc;const _0xe67abf=a130_0xe67a();let _0x1c370b=_0xe67abf[_0x3d8eda];return _0x1c370b;}const a130_0x13d191=a130_0x1c37;(function(_0x3c659f,_0x1cd929){const _0x24f526=a130_0x1c37,_0xdde557=_0x3c659f();while(!![]){try{const _0x552654=parseInt(_0x24f526(0x1e3))/0x1*(parseInt(_0x24f526(0x1d1))/0x2)+parseInt(_0x24f526(0x1d6))/0x3*(parseInt(_0x24f526(0x1d8))/0x4)+-parseInt(_0x24f526(0x1d9))/0x5*(parseInt(_0x24f526(0x1dc))/0x6)+-parseInt(_0x24f526(0x1de))/0x7+-parseInt(_0x24f526(0x1e5))/0x8+parseInt(_0x24f526(0x1cd))/0x9*(-parseInt(_0x24f526(0x1e4))/0xa)+parseInt(_0x24f526(0x1d2))/0xb*(parseInt(_0x24f526(0x1d7))/0xc);if(_0x552654===_0x1cd929)break;else _0xdde557['push'](_0xdde557['shift']());}catch(_0x37a6d3){_0xdde557['push'](_0xdde557['shift']());}}}(a130_0xe67a,0x37dbf));import{existsSync,mkdirSync,readFileSync,writeFileSync}from'node:fs';import{dirname,join,resolve}from'node:path';import{fileURLToPath}from'node:url';import{getTemplateBaseUrl}from'./config.js';import{appendUpdateTime}from'./guides-cdn.js';const __filename=fileURLToPath(import.meta.url),__dirname=dirname(__filename);function getRulesCdnUrl(){const _0x4a9a22=a130_0x1c37,_0x194dc4=getTemplateBaseUrl();return _0x194dc4+_0x4a9a22(0x1df);}const LOCAL_TEMPLATE_PATH=resolve(__dirname,a130_0x13d191(0x1e0));export async function fetchRulesFromCDN(){const _0x21b6ac=a130_0x13d191,_0x2374e6=getRulesCdnUrl(),_0x57d2f2=await fetch(_0x2374e6,{'headers':{'Accept':_0x21b6ac(0x1cf)}});if(!_0x57d2f2['ok'])throw new Error(_0x21b6ac(0x1ce)+_0x57d2f2[_0x21b6ac(0x1d3)]+'\x20'+_0x57d2f2['statusText']);const _0x48e245=await _0x57d2f2[_0x21b6ac(0x1cc)]();if(!_0x48e245[_0x21b6ac(0x1d0)]||typeof _0x48e245[_0x21b6ac(0x1d0)]!==_0x21b6ac(0x1d5))throw new Error(_0x21b6ac(0x1d4));return _0x48e245;}export async function getRulesContent(){const _0x44cb74=a130_0x13d191;try{const _0x508e0e=await fetchRulesFromCDN();return _0x508e0e[_0x44cb74(0x1d0)];}catch{return readLocalTemplate();}}export function readLocalTemplate(){const _0x1eec81=a130_0x13d191;if(existsSync(LOCAL_TEMPLATE_PATH))return readFileSync(LOCAL_TEMPLATE_PATH,_0x1eec81(0x1e2));throw new Error('本地模板文件不存在:\x20'+LOCAL_TEMPLATE_PATH);}function a130_0xe67a(){const _0x46150b=['utf-8','16Lfdhmw','2819480HZqlIx','3318712GMKrIe','json','9XiDCqE','CDN\x20请求失败:\x20','application/json','content','54110pFXpRr','4909982HpQtAl','status','CDN\x20返回数据格式错误','string','69DSRylV','24qpIQIt','60444qFReMg','2235505BRDtDu','lastUpdated','agents.md','6FjcUMl','catch','2103290FvIESM','/rules/rules.json','../../templates/rules/lovrabet_rules.mdc.tpl','.cursor/rules'];a130_0xe67a=function(){return _0x46150b;};return a130_0xe67a();}export async function writeRulesFile(_0x464245){const _0xa3064b=a130_0x13d191,_0x4eab5a=await fetchRulesFromCDN()[_0xa3064b(0x1dd)](()=>null);let _0x1bb40a;_0x4eab5a?(_0x1bb40a=_0x4eab5a[_0xa3064b(0x1d0)],_0x4eab5a['lastUpdated']&&(_0x1bb40a=appendUpdateTime(_0x1bb40a,_0x4eab5a[_0xa3064b(0x1da)]))):_0x1bb40a=readLocalTemplate();const _0x607509=dirname(_0x464245);!existsSync(_0x607509)&&mkdirSync(_0x607509,{'recursive':!![]}),writeFileSync(_0x464245,_0x1bb40a,_0xa3064b(0x1e2));}export async function copyRulesToCursor(_0x229cb7){const _0x48f749=a130_0x13d191,_0x5a467d=join(_0x229cb7,_0x48f749(0x1e1)),_0x2ace9d=join(_0x5a467d,'lovrabet_rules.mdc');if(existsSync(_0x2ace9d))return![];return await writeRulesFile(_0x2ace9d),!![];}export async function copyRulesToAgentsMd(_0x4ac75e){const _0x570f89=a130_0x13d191,_0x37c744=join(_0x4ac75e,_0x570f89(0x1db));if(existsSync(_0x37c744))return![];return await writeRulesFile(_0x37c744),!![];}
1
+ const a134_0x372d1a=a134_0xb10c;(function(_0x517405,_0x560254){const _0x5a1cb2=a134_0xb10c,_0xfb5a18=_0x517405();while(!![]){try{const _0x2eeb67=parseInt(_0x5a1cb2(0x1bb))/0x1*(-parseInt(_0x5a1cb2(0x1bf))/0x2)+-parseInt(_0x5a1cb2(0x1af))/0x3*(-parseInt(_0x5a1cb2(0x1ab))/0x4)+-parseInt(_0x5a1cb2(0x1ba))/0x5+-parseInt(_0x5a1cb2(0x1bd))/0x6*(parseInt(_0x5a1cb2(0x1c1))/0x7)+-parseInt(_0x5a1cb2(0x1be))/0x8*(-parseInt(_0x5a1cb2(0x1b2))/0x9)+parseInt(_0x5a1cb2(0x1bc))/0xa+parseInt(_0x5a1cb2(0x1b7))/0xb*(parseInt(_0x5a1cb2(0x1b1))/0xc);if(_0x2eeb67===_0x560254)break;else _0xfb5a18['push'](_0xfb5a18['shift']());}catch(_0x13dafb){_0xfb5a18['push'](_0xfb5a18['shift']());}}}(a134_0x5bae,0x7f14e));function a134_0xb10c(_0x2925e1,_0x391fc1){_0x2925e1=_0x2925e1-0x1a7;const _0x5bae84=a134_0x5bae();let _0xb10c66=_0x5bae84[_0x2925e1];return _0xb10c66;}import{existsSync,mkdirSync,readFileSync,writeFileSync}from'node:fs';import{dirname,join,resolve}from'node:path';import{fileURLToPath}from'node:url';import{getTemplateBaseUrl}from'../utils/config.js';import{appendUpdateTime}from'../utils/guides-cdn.js';const __filename=fileURLToPath(import.meta.url),__dirname=dirname(__filename);function getRulesCdnUrl(){const _0x889b60=a134_0xb10c,_0x20d1f1=getTemplateBaseUrl();return _0x20d1f1+_0x889b60(0x1b5);}const LOCAL_TEMPLATE_PATH=resolve(__dirname,a134_0x372d1a(0x1b4));export async function fetchRulesFromCDN(){const _0x29ace6=a134_0x372d1a,_0xc9c9c4=getRulesCdnUrl(),_0x2b69cc=await fetch(_0xc9c9c4,{'headers':{'Accept':_0x29ace6(0x1a8)}});if(!_0x2b69cc['ok'])throw new Error(_0x29ace6(0x1ad)+_0x2b69cc[_0x29ace6(0x1c0)]+'\x20'+_0x2b69cc[_0x29ace6(0x1ae)]);const _0x106114=await _0x2b69cc[_0x29ace6(0x1c2)]();if(!_0x106114[_0x29ace6(0x1aa)]||typeof _0x106114[_0x29ace6(0x1aa)]!==_0x29ace6(0x1ac))throw new Error(_0x29ace6(0x1a9));return _0x106114;}export async function getRulesContent(){const _0x33666c=a134_0x372d1a;try{const _0x8f6d=await fetchRulesFromCDN();return _0x8f6d[_0x33666c(0x1aa)];}catch{return readLocalTemplate();}}function a134_0x5bae(){const _0x708645=['215495xlTGEk','1dSQtNL','1480440fUboNS','347838tLvmHj','839912BSqCCZ','1226830OYPdiT','status','35UkzKYP','json','utf-8','agents.md','application/json','CDN\x20返回数据格式错误','content','14132gWdsCg','string','CDN\x20请求失败:\x20','statusText','393sywESa','catch','12NtIrVx','45DTYaKz','lovrabet_rules.mdc','../../templates/rules/lovrabet_rules.mdc.tpl','/rules/rules.json','lastUpdated','3642023iYxwMa','.cursor/rules','本地模板文件不存在:\x20'];a134_0x5bae=function(){return _0x708645;};return a134_0x5bae();}export function readLocalTemplate(){const _0x58d240=a134_0x372d1a;if(existsSync(LOCAL_TEMPLATE_PATH))return readFileSync(LOCAL_TEMPLATE_PATH,_0x58d240(0x1c3));throw new Error(_0x58d240(0x1b9)+LOCAL_TEMPLATE_PATH);}export async function writeRulesFile(_0x3d7ff1){const _0x245cdd=a134_0x372d1a,_0x2aa048=await fetchRulesFromCDN()[_0x245cdd(0x1b0)](()=>null);let _0x30ce32;_0x2aa048?(_0x30ce32=_0x2aa048[_0x245cdd(0x1aa)],_0x2aa048[_0x245cdd(0x1b6)]&&(_0x30ce32=appendUpdateTime(_0x30ce32,_0x2aa048[_0x245cdd(0x1b6)]))):_0x30ce32=readLocalTemplate();const _0x206690=dirname(_0x3d7ff1);!existsSync(_0x206690)&&mkdirSync(_0x206690,{'recursive':!![]}),writeFileSync(_0x3d7ff1,_0x30ce32,_0x245cdd(0x1c3));}export async function copyRulesToCursor(_0x41ba00){const _0x26e5c5=a134_0x372d1a,_0x2a57bc=join(_0x41ba00,_0x26e5c5(0x1b8)),_0x4e822d=join(_0x2a57bc,_0x26e5c5(0x1b3));if(existsSync(_0x4e822d))return![];return await writeRulesFile(_0x4e822d),!![];}export async function copyRulesToAgentsMd(_0x53c52f){const _0x23ef9a=a134_0x372d1a,_0x1b0a51=join(_0x53c52f,_0x23ef9a(0x1a7));if(existsSync(_0x1b0a51))return![];return await writeRulesFile(_0x1b0a51),!![];}
@@ -1 +1 @@
1
- export function sleep(_0x30b7b6){return new Promise(_0x257ca6=>setTimeout(_0x257ca6,_0x30b7b6));}
1
+ export function sleep(_0x4b935a){return new Promise(_0x2f4c63=>setTimeout(_0x2f4c63,_0x4b935a));}
@@ -1 +1 @@
1
- const a132_0x3d4cf4=a132_0x5c53;(function(_0x2a37b2,_0x495c26){const _0x34e0d4=a132_0x5c53,_0x413e3d=_0x2a37b2();while(!![]){try{const _0x1ae413=-parseInt(_0x34e0d4(0x94))/0x1*(-parseInt(_0x34e0d4(0x68))/0x2)+parseInt(_0x34e0d4(0xa6))/0x3+-parseInt(_0x34e0d4(0x8d))/0x4+parseInt(_0x34e0d4(0x67))/0x5+-parseInt(_0x34e0d4(0x91))/0x6*(-parseInt(_0x34e0d4(0xa1))/0x7)+parseInt(_0x34e0d4(0x90))/0x8*(-parseInt(_0x34e0d4(0x7e))/0x9)+parseInt(_0x34e0d4(0x81))/0xa*(-parseInt(_0x34e0d4(0x86))/0xb);if(_0x1ae413===_0x495c26)break;else _0x413e3d['push'](_0x413e3d['shift']());}catch(_0x31861b){_0x413e3d['push'](_0x413e3d['shift']());}}}(a132_0x1a65,0x56522));import a132_0x545e31 from'node:fs';import a132_0x7bbee5 from'node:path';function a132_0x5c53(_0x3e3b59,_0x26e266){_0x3e3b59=_0x3e3b59-0x66;const _0x1a650c=a132_0x1a65();let _0x5c53c2=_0x1a650c[_0x3e3b59];return _0x5c53c2;}import{logger}from'./logger.js';import{getCliVersion}from'./version.js';const CLI_VERSION=getCliVersion();export class TemplateReplacer{static[a132_0x3d4cf4(0x95)](_0x141144){const _0x2be606=a132_0x3d4cf4,_0x172242=_0x141144['split']('/')[_0x2be606(0x80)]()||_0x141144;return _0x172242[_0x2be606(0x89)]('-')[_0x2be606(0x84)](_0x573f0f=>_0x573f0f[_0x2be606(0x74)](0x0)[_0x2be606(0x7d)]()+_0x573f0f[_0x2be606(0x88)](0x1)[_0x2be606(0x83)]())[_0x2be606(0x8b)]('');}static['toDisplayTitle'](_0x41031f){const _0x3afd0e=a132_0x3d4cf4,_0x3edb07=_0x41031f['split']('/')['pop']()||_0x41031f;return _0x3edb07[_0x3afd0e(0x89)]('-')['map'](_0x3b74d3=>_0x3b74d3[_0x3afd0e(0x74)](0x0)['toUpperCase']()+_0x3b74d3[_0x3afd0e(0x88)](0x1)[_0x3afd0e(0x83)]())['join']('\x20');}static[a132_0x3d4cf4(0x6f)](_0x20812d,_0x1f3111,_0x548405){const _0x584b3e=a132_0x3d4cf4,_0x194038=this[_0x584b3e(0x95)](_0x1f3111),_0x4d124b=this['toDisplayTitle'](_0x1f3111),_0x267149=new Date(),_0x2e1149=_0x267149[_0x584b3e(0x79)](undefined,{'year':_0x584b3e(0xa7),'month':_0x584b3e(0x8c),'day':_0x584b3e(0x8c),'hour':'2-digit','minute':_0x584b3e(0x8c),'second':'2-digit','hour12':![]})[_0x584b3e(0x70)](/\//g,'-'),_0x2409fe=_0x267149[_0x584b3e(0x66)](undefined,{'year':_0x584b3e(0xa7),'month':'2-digit','day':'2-digit'})[_0x584b3e(0x70)](/\//g,'-'),_0x1ea8ed=_0x267149[_0x584b3e(0x75)](undefined,{'hour12':![]});let _0x2a84e7=_0x20812d[_0x584b3e(0x70)](/\{CliVersion\}/g,CLI_VERSION)['replace'](/\{ComponentName\}/g,_0x194038)[_0x584b3e(0x70)](/\{DisplayTitle\}/g,_0x4d124b)[_0x584b3e(0x70)](/\{PageName\}/g,_0x1f3111)[_0x584b3e(0x70)](/\{TemplateName\}/g,_0x548405)[_0x584b3e(0x70)](/\{CreatedAt\}/g,_0x2e1149)['replace'](/\{CreatedDate\}/g,_0x2409fe)[_0x584b3e(0x70)](/\{CreatedTime\}/g,_0x1ea8ed);return _0x2a84e7;}static[a132_0x3d4cf4(0x69)](_0x19f5b2,_0x50a57c,_0x91e5a6,_0x44238c,_0x57566e,_0xdb6960,_0x5d9762,_0x7b9a44){const _0x278bae=a132_0x3d4cf4,_0x1e2c88=new Date(),_0x7d99ce=_0x1e2c88[_0x278bae(0xa8)](),_0x12348e=_0x91e5a6[_0x278bae(0x84)](_0x78c509=>{const _0x110b1b=_0x278bae,_0x579793=[_0x110b1b(0x7c)+_0x78c509['datasetCode']+'\x22','tableName:\x20\x22'+_0x78c509[_0x110b1b(0x82)]+'\x22',_0x110b1b(0x6d)+_0x78c509[_0x110b1b(0x92)]+'\x22'];return _0x78c509['alias']&&_0x579793[_0x110b1b(0x7f)]('alias:\x20\x22'+_0x78c509[_0x110b1b(0x9c)]+'\x22'),_0x110b1b(0x99)+_0x579793[_0x110b1b(0x8b)](',\x20')+_0x110b1b(0x6e);})[_0x278bae(0x8b)](''),_0x405a32=_0x44238c||_0x91e5a6[0x0]?.['alias']||_0x278bae(0x8a);let _0x484d23=_0x19f5b2[_0x278bae(0x70)](/\{AppCode\}/g,_0x50a57c)['replace'](/\{ModelConfigs\}/g,_0x12348e)[_0x278bae(0x70)](/\{ExampleModelName\}/g,_0x405a32)[_0x278bae(0x70)](/\{ApiFileName\}/g,_0x57566e||_0x278bae(0x98))[_0x278bae(0x70)](/\{ConfigName\}/g,_0xdb6960||_0x278bae(0x72))['replace'](/\{ClientConfigParam\}/g,_0x5d9762||'')[_0x278bae(0x70)](/\{VarPrefix\}/g,_0x7b9a44||_0x278bae(0x9a))[_0x278bae(0x70)](/\{CreatedAt\}/g,_0x7d99ce);return _0x484d23;}static async['processTemplate'](_0x1b9ac7,_0xf8b44c,_0x2c03ce,_0x2a2378,_0x17c745=!![]){const _0x57bb93=a132_0x3d4cf4,_0x9ee78=Date['now']();try{_0x17c745&&logger[_0x57bb93(0x7b)](_0x57bb93(0xa0),_0x57bb93(0x8f),{'templatePath':_0x1b9ac7,'targetPath':_0xf8b44c,'pageName':_0x2c03ce,'templateName':_0x2a2378});await a132_0x545e31[_0x57bb93(0x77)][_0x57bb93(0x76)](_0xf8b44c,{'recursive':!![]}),await this[_0x57bb93(0x85)](_0x1b9ac7,_0xf8b44c,_0x2c03ce,_0x2a2378);if(_0x17c745){const _0xd664f4=Date[_0x57bb93(0x78)]()-_0x9ee78;logger['success'](_0x57bb93(0xa0),_0x57bb93(0x97),_0xd664f4,{'pageName':_0x2c03ce,'templateName':_0x2a2378});}}catch(_0x7df323){if(_0x17c745){const _0x427635=Date[_0x57bb93(0x78)]()-_0x9ee78;logger[_0x57bb93(0x71)](_0x57bb93(0xa0),_0x57bb93(0xa5),{'templatePath':_0x1b9ac7,'targetPath':_0xf8b44c,'pageName':_0x2c03ce,'templateName':_0x2a2378,'error':_0x7df323 instanceof Error?_0x7df323[_0x57bb93(0x93)]:String(_0x7df323),'duration':_0x427635});}throw _0x7df323;}}static async[a132_0x3d4cf4(0x85)](_0x24d753,_0x195181,_0x40ccaa,_0x37b0dd){const _0x1deec3=a132_0x3d4cf4,_0x3a5338=await a132_0x545e31[_0x1deec3(0x77)]['readdir'](_0x24d753,{'withFileTypes':!![]});for(const _0x435e2b of _0x3a5338){const _0x45bfb3=a132_0x7bbee5['join'](_0x24d753,_0x435e2b['name']);let _0x30c367=a132_0x7bbee5['join'](_0x195181,_0x435e2b['name']);_0x435e2b[_0x1deec3(0x92)][_0x1deec3(0x96)](_0x1deec3(0x6c))&&(_0x30c367=a132_0x7bbee5[_0x1deec3(0x8b)](_0x195181,_0x435e2b['name'][_0x1deec3(0x70)](/\.tpl$/,'')));if(_0x435e2b[_0x1deec3(0x6a)]())await a132_0x545e31[_0x1deec3(0x77)][_0x1deec3(0x76)](_0x30c367,{'recursive':!![]}),await this[_0x1deec3(0x85)](_0x45bfb3,_0x30c367,_0x40ccaa,_0x37b0dd);else _0x435e2b[_0x1deec3(0xa3)]()&&await this[_0x1deec3(0x8e)](_0x45bfb3,_0x30c367,_0x40ccaa,_0x37b0dd);}}static async['processFile'](_0x215c56,_0x270c69,_0x154b66,_0x4e8bb1){const _0x5b1125=a132_0x3d4cf4,_0x3f7938=a132_0x7bbee5[_0x5b1125(0x9e)](_0x215c56)['toLowerCase']();_0x215c56[_0x5b1125(0x96)](_0x5b1125(0x6c))&&(_0x270c69=_0x270c69[_0x5b1125(0x70)](/\.tpl$/,''));const _0x3d56b3=[_0x5b1125(0xa2),_0x5b1125(0xa4),'.jsx',_0x5b1125(0x9f),'.json',_0x5b1125(0x9d),_0x5b1125(0x6b),_0x5b1125(0x7a),_0x5b1125(0x6c)];if(_0x3d56b3['includes'](_0x3f7938)||_0x215c56[_0x5b1125(0x96)](_0x5b1125(0x6c))){const _0x323d92=await a132_0x545e31['promises'][_0x5b1125(0x73)](_0x215c56,'utf8'),_0x57b830=this[_0x5b1125(0x6f)](_0x323d92,_0x154b66,_0x4e8bb1);await a132_0x545e31[_0x5b1125(0x77)][_0x5b1125(0x87)](_0x270c69,_0x57b830,'utf8');}else await a132_0x545e31['promises'][_0x5b1125(0x9b)](_0x215c56,_0x270c69);}}function a132_0x1a65(){const _0x591dbe=['replaceApiContent','isDirectory','.css','.tpl','name:\x20\x22','\x20},','replaceContent','replace','error','default','readFile','charAt','toLocaleTimeString','mkdir','promises','now','toLocaleString','.scss','info','datasetCode:\x20\x22','toUpperCase','422037YBkTUR','push','pop','446570SOPiWz','tableName','toLowerCase','map','processDirectory','187iJJOEQ','writeFile','slice','split','YourModel','join','2-digit','326660XvXBXE','processFile','开始处理模板内容替换','16jdDAjl','182424GsBcBd','name','message','20pYrSXO','toComponentName','endsWith','模板内容替换完成','api','\x0a\x20\x20\x20\x20{\x20','LOVRABET','copyFile','alias','.md','extname','.js','template','161YKpHBu','.tsx','isFile','.ts','模板内容替换失败','26433HUOwil','numeric','toISOString','toLocaleDateString','1048435SyGudq','37040xbpFJN'];a132_0x1a65=function(){return _0x591dbe;};return a132_0x1a65();}
1
+ function a136_0x22b1(){const _0x3c93a4=['toLocaleString','YourModel','alias:\x20\x22','numeric','LOVRABET','117CaVqeR','.js','开始处理模板内容替换','info','success','831aTomCj','push','toLocaleTimeString','tableName:\x20\x22','replace','tableName','\x20},','copyFile','15oRLpGy','.css','datasetCode','name','.jsx','223240tQjKbo','replaceContent','2-digit','\x0a\x20\x20\x20\x20{\x20','promises','template','processDirectory','alias','1306876ENmdjD','1828wTUtBc','pop','.ts','map','toDisplayTitle','mkdir','endsWith','toLocaleDateString','extname','processFile','3246648UTqbhn','模板内容替换失败','toUpperCase','2354401ErllAf','.json','toLowerCase','.tpl','slice','isDirectory','name:\x20\x22','datasetCode:\x20\x22','charAt','message','join','split','default','now','toComponentName','336523WJOfOR','.scss','api','includes','toISOString','readdir','599065NwiKiU','utf8','error','120rJUbYg'];a136_0x22b1=function(){return _0x3c93a4;};return a136_0x22b1();}const a136_0x2c01b0=a136_0x4447;function a136_0x4447(_0x5f458f,_0x193490){_0x5f458f=_0x5f458f-0x1ef;const _0x22b124=a136_0x22b1();let _0x44477d=_0x22b124[_0x5f458f];return _0x44477d;}(function(_0x3b8211,_0x1e3047){const _0x59bbce=a136_0x4447,_0x2fd455=_0x3b8211();while(!![]){try{const _0x5a1698=-parseInt(_0x59bbce(0x212))/0x1+parseInt(_0x59bbce(0x1f0))/0x2*(-parseInt(_0x59bbce(0x220))/0x3)+-parseInt(_0x59bbce(0x1ef))/0x4+-parseInt(_0x59bbce(0x228))/0x5*(-parseInt(_0x59bbce(0x1fa))/0x6)+-parseInt(_0x59bbce(0x1fd))/0x7+-parseInt(_0x59bbce(0x22d))/0x8*(-parseInt(_0x59bbce(0x21b))/0x9)+-parseInt(_0x59bbce(0x215))/0xa*(-parseInt(_0x59bbce(0x20c))/0xb);if(_0x5a1698===_0x1e3047)break;else _0x2fd455['push'](_0x2fd455['shift']());}catch(_0xa21144){_0x2fd455['push'](_0x2fd455['shift']());}}}(a136_0x22b1,0xcc90c));import a136_0x3090cc from'node:fs';import a136_0x5c5273 from'node:path';import{logger}from'../utils/logger.js';import{getCliVersion}from'../utils/version.js';const CLI_VERSION=getCliVersion();export class TemplateReplacer{static[a136_0x2c01b0(0x20b)](_0x16fe11){const _0x43c430=a136_0x2c01b0,_0x55fb96=_0x16fe11[_0x43c430(0x208)]('/')[_0x43c430(0x1f1)]()||_0x16fe11;return _0x55fb96[_0x43c430(0x208)]('-')[_0x43c430(0x1f3)](_0xc283b8=>_0xc283b8[_0x43c430(0x205)](0x0)[_0x43c430(0x1fc)]()+_0xc283b8[_0x43c430(0x201)](0x1)['toLowerCase']())['join']('');}static[a136_0x2c01b0(0x1f4)](_0x2a45d4){const _0x2d3e7=a136_0x2c01b0,_0x1dec25=_0x2a45d4[_0x2d3e7(0x208)]('/')[_0x2d3e7(0x1f1)]()||_0x2a45d4;return _0x1dec25['split']('-')[_0x2d3e7(0x1f3)](_0x3b33d4=>_0x3b33d4[_0x2d3e7(0x205)](0x0)[_0x2d3e7(0x1fc)]()+_0x3b33d4[_0x2d3e7(0x201)](0x1)['toLowerCase']())[_0x2d3e7(0x207)]('\x20');}static[a136_0x2c01b0(0x22e)](_0x1a566b,_0xf178c4,_0x20fb27){const _0x17d8b6=a136_0x2c01b0,_0x4e2a96=this[_0x17d8b6(0x20b)](_0xf178c4),_0xf3863c=this[_0x17d8b6(0x1f4)](_0xf178c4),_0x2a108a=new Date(),_0x13a27c=_0x2a108a[_0x17d8b6(0x216)](undefined,{'year':_0x17d8b6(0x219),'month':'2-digit','day':'2-digit','hour':_0x17d8b6(0x22f),'minute':_0x17d8b6(0x22f),'second':'2-digit','hour12':![]})[_0x17d8b6(0x224)](/\//g,'-'),_0x14360e=_0x2a108a[_0x17d8b6(0x1f7)](undefined,{'year':_0x17d8b6(0x219),'month':_0x17d8b6(0x22f),'day':_0x17d8b6(0x22f)})[_0x17d8b6(0x224)](/\//g,'-'),_0x2c156a=_0x2a108a[_0x17d8b6(0x222)](undefined,{'hour12':![]});let _0x28fe16=_0x1a566b[_0x17d8b6(0x224)](/\{CliVersion\}/g,CLI_VERSION)['replace'](/\{ComponentName\}/g,_0x4e2a96)['replace'](/\{DisplayTitle\}/g,_0xf3863c)[_0x17d8b6(0x224)](/\{PageName\}/g,_0xf178c4)[_0x17d8b6(0x224)](/\{TemplateName\}/g,_0x20fb27)['replace'](/\{CreatedAt\}/g,_0x13a27c)[_0x17d8b6(0x224)](/\{CreatedDate\}/g,_0x14360e)['replace'](/\{CreatedTime\}/g,_0x2c156a);return _0x28fe16;}static['replaceApiContent'](_0x1f54f2,_0x583106,_0x1fafde,_0x36e3a1,_0x47b175,_0x12b144,_0x83bf11,_0x2fc76a){const _0x263f39=a136_0x2c01b0,_0x338ea1=new Date(),_0x2a865f=_0x338ea1[_0x263f39(0x210)](),_0x418b8d=_0x1fafde[_0x263f39(0x1f3)](_0x46a9b6=>{const _0x55a822=_0x263f39,_0x4507ee=[_0x55a822(0x204)+_0x46a9b6[_0x55a822(0x22a)]+'\x22',_0x55a822(0x223)+_0x46a9b6[_0x55a822(0x225)]+'\x22',_0x55a822(0x203)+_0x46a9b6['name']+'\x22'];return _0x46a9b6[_0x55a822(0x234)]&&_0x4507ee[_0x55a822(0x221)](_0x55a822(0x218)+_0x46a9b6['alias']+'\x22'),_0x55a822(0x230)+_0x4507ee[_0x55a822(0x207)](',\x20')+_0x55a822(0x226);})[_0x263f39(0x207)](''),_0x10de03=_0x36e3a1||_0x1fafde[0x0]?.[_0x263f39(0x234)]||_0x263f39(0x217);let _0x806036=_0x1f54f2[_0x263f39(0x224)](/\{AppCode\}/g,_0x583106)['replace'](/\{ModelConfigs\}/g,_0x418b8d)[_0x263f39(0x224)](/\{ExampleModelName\}/g,_0x10de03)[_0x263f39(0x224)](/\{ApiFileName\}/g,_0x47b175||_0x263f39(0x20e))[_0x263f39(0x224)](/\{ConfigName\}/g,_0x12b144||_0x263f39(0x209))[_0x263f39(0x224)](/\{ClientConfigParam\}/g,_0x83bf11||'')['replace'](/\{VarPrefix\}/g,_0x2fc76a||_0x263f39(0x21a))[_0x263f39(0x224)](/\{CreatedAt\}/g,_0x2a865f);return _0x806036;}static async['processTemplate'](_0x5aeb35,_0x2b0fb8,_0x42ebb7,_0x3a4efd,_0x1c7639=!![]){const _0x11618a=a136_0x2c01b0,_0x55ae84=Date[_0x11618a(0x20a)]();try{_0x1c7639&&logger[_0x11618a(0x21e)](_0x11618a(0x232),_0x11618a(0x21d),{'templatePath':_0x5aeb35,'targetPath':_0x2b0fb8,'pageName':_0x42ebb7,'templateName':_0x3a4efd});await a136_0x3090cc[_0x11618a(0x231)][_0x11618a(0x1f5)](_0x2b0fb8,{'recursive':!![]}),await this[_0x11618a(0x233)](_0x5aeb35,_0x2b0fb8,_0x42ebb7,_0x3a4efd);if(_0x1c7639){const _0x47a645=Date['now']()-_0x55ae84;logger[_0x11618a(0x21f)](_0x11618a(0x232),'模板内容替换完成',_0x47a645,{'pageName':_0x42ebb7,'templateName':_0x3a4efd});}}catch(_0x67e7c3){if(_0x1c7639){const _0x4dc0a5=Date[_0x11618a(0x20a)]()-_0x55ae84;logger[_0x11618a(0x214)](_0x11618a(0x232),_0x11618a(0x1fb),{'templatePath':_0x5aeb35,'targetPath':_0x2b0fb8,'pageName':_0x42ebb7,'templateName':_0x3a4efd,'error':_0x67e7c3 instanceof Error?_0x67e7c3[_0x11618a(0x206)]:String(_0x67e7c3),'duration':_0x4dc0a5});}throw _0x67e7c3;}}static async['processDirectory'](_0x40c101,_0x3b6ca9,_0x1a7c95,_0x49343e){const _0x3a342d=a136_0x2c01b0,_0x3cc816=await a136_0x3090cc[_0x3a342d(0x231)][_0x3a342d(0x211)](_0x40c101,{'withFileTypes':!![]});for(const _0x53eb3c of _0x3cc816){const _0x545944=a136_0x5c5273[_0x3a342d(0x207)](_0x40c101,_0x53eb3c[_0x3a342d(0x22b)]);let _0x1062f7=a136_0x5c5273['join'](_0x3b6ca9,_0x53eb3c[_0x3a342d(0x22b)]);_0x53eb3c[_0x3a342d(0x22b)]['endsWith'](_0x3a342d(0x200))&&(_0x1062f7=a136_0x5c5273[_0x3a342d(0x207)](_0x3b6ca9,_0x53eb3c[_0x3a342d(0x22b)][_0x3a342d(0x224)](/\.tpl$/,'')));if(_0x53eb3c[_0x3a342d(0x202)]())await a136_0x3090cc[_0x3a342d(0x231)]['mkdir'](_0x1062f7,{'recursive':!![]}),await this[_0x3a342d(0x233)](_0x545944,_0x1062f7,_0x1a7c95,_0x49343e);else _0x53eb3c['isFile']()&&await this[_0x3a342d(0x1f9)](_0x545944,_0x1062f7,_0x1a7c95,_0x49343e);}}static async['processFile'](_0x34315f,_0x2ee89f,_0x5e0fc4,_0x45e240){const _0x2b7ec1=a136_0x2c01b0,_0x12240b=a136_0x5c5273[_0x2b7ec1(0x1f8)](_0x34315f)[_0x2b7ec1(0x1ff)]();_0x34315f[_0x2b7ec1(0x1f6)](_0x2b7ec1(0x200))&&(_0x2ee89f=_0x2ee89f[_0x2b7ec1(0x224)](/\.tpl$/,''));const _0xce5d4a=['.tsx',_0x2b7ec1(0x1f2),_0x2b7ec1(0x22c),_0x2b7ec1(0x21c),_0x2b7ec1(0x1fe),'.md',_0x2b7ec1(0x229),_0x2b7ec1(0x20d),'.tpl'];if(_0xce5d4a[_0x2b7ec1(0x20f)](_0x12240b)||_0x34315f['endsWith'](_0x2b7ec1(0x200))){const _0x1bbe9e=await a136_0x3090cc[_0x2b7ec1(0x231)]['readFile'](_0x34315f,_0x2b7ec1(0x213)),_0x5dcb32=this['replaceContent'](_0x1bbe9e,_0x5e0fc4,_0x45e240);await a136_0x3090cc[_0x2b7ec1(0x231)]['writeFile'](_0x2ee89f,_0x5dcb32,_0x2b7ec1(0x213));}else await a136_0x3090cc[_0x2b7ec1(0x231)][_0x2b7ec1(0x227)](_0x34315f,_0x2ee89f);}}