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

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (204) hide show
  1. package/lib/api/api-doc.js +1 -1
  2. package/lib/api/fetch-model-list.js +1 -1
  3. package/lib/api/generate-api-file.js +1 -1
  4. package/lib/auth/auth-server-ui.js +1 -1
  5. package/lib/auth/auth-server.js +1 -1
  6. package/lib/auth/constant.js +1 -1
  7. package/lib/auth/get-cookie.js +1 -1
  8. package/lib/auth/get-session-user.js +1 -1
  9. package/lib/auth/is-session-valid.js +1 -1
  10. package/lib/auth/login-success-html.js +1 -1
  11. package/lib/auth/logout.js +1 -1
  12. package/lib/cli-flags.js +1 -1
  13. package/lib/cli.js +1 -1
  14. package/lib/commands/api/generate.js +1 -1
  15. package/lib/commands/api/index.js +1 -1
  16. package/lib/commands/api/list.js +1 -1
  17. package/lib/commands/api/pull.js +1 -1
  18. package/lib/commands/api/shared.js +1 -1
  19. package/lib/commands/app/add.js +1 -1
  20. package/lib/commands/app/discover.js +1 -1
  21. package/lib/commands/app/index.js +1 -1
  22. package/lib/commands/app/list.js +1 -1
  23. package/lib/commands/app/remove.js +1 -1
  24. package/lib/commands/app/shared.js +1 -1
  25. package/lib/commands/app/use.js +1 -1
  26. package/lib/commands/auth/index.js +1 -1
  27. package/lib/commands/bff/create.js +1 -1
  28. package/lib/commands/bff/delete.js +1 -1
  29. package/lib/commands/bff/detail.js +1 -1
  30. package/lib/commands/bff/index.js +1 -1
  31. package/lib/commands/bff/list.js +1 -1
  32. package/lib/commands/bff/pull.js +1 -1
  33. package/lib/commands/bff/push.js +1 -1
  34. package/lib/commands/bff/status.js +1 -1
  35. package/lib/commands/cli-update.js +1 -1
  36. package/lib/commands/codegen/index.js +1 -1
  37. package/lib/commands/codegen/sdk.js +1 -1
  38. package/lib/commands/codegen/sql.js +1 -1
  39. package/lib/commands/common/app-selector.js +1 -1
  40. package/lib/commands/common/flags.js +1 -1
  41. package/lib/commands/common/validate.js +1 -1
  42. package/lib/commands/config/get.js +1 -1
  43. package/lib/commands/config/index.js +1 -1
  44. package/lib/commands/config/list.js +1 -1
  45. package/lib/commands/config/set.js +1 -1
  46. package/lib/commands/config/shared.js +1 -1
  47. package/lib/commands/data/filter.js +1 -1
  48. package/lib/commands/data/getOne.js +1 -1
  49. package/lib/commands/data/index.js +1 -1
  50. package/lib/commands/data/shared.js +1 -1
  51. package/lib/commands/dataset/capability.js +1 -1
  52. package/lib/commands/dataset/delete.js +1 -1
  53. package/lib/commands/dataset/detail.js +1 -1
  54. package/lib/commands/dataset/extend-update.js +1 -1
  55. package/lib/commands/dataset/field-update.js +1 -1
  56. package/lib/commands/dataset/index.js +1 -1
  57. package/lib/commands/dataset/list.js +1 -1
  58. package/lib/commands/dataset/operations.js +1 -1
  59. package/lib/commands/dataset/relation-create.js +1 -1
  60. package/lib/commands/dataset/relation-delete.js +1 -1
  61. package/lib/commands/dataset/relation-shared.js +1 -1
  62. package/lib/commands/dataset/relation-update.js +1 -1
  63. package/lib/commands/dataset/relations.js +1 -1
  64. package/lib/commands/dataset/rename.js +1 -1
  65. package/lib/commands/db/analyze-cancel.js +1 -1
  66. package/lib/commands/db/analyze-start.js +1 -1
  67. package/lib/commands/db/analyze-status.js +1 -1
  68. package/lib/commands/db/create.js +1 -1
  69. package/lib/commands/db/delete.js +1 -1
  70. package/lib/commands/db/detail.js +1 -1
  71. package/lib/commands/db/diff.js +1 -1
  72. package/lib/commands/db/index.js +1 -1
  73. package/lib/commands/db/list.js +1 -1
  74. package/lib/commands/db/shared.js +1 -1
  75. package/lib/commands/db/tables.js +1 -1
  76. package/lib/commands/db/test.js +1 -1
  77. package/lib/commands/db/update.js +1 -1
  78. package/lib/commands/doctor.js +1 -1
  79. package/lib/commands/init/index.js +1 -1
  80. package/lib/commands/issue/index.js +1 -1
  81. package/lib/commands/issue/nudge.js +1 -1
  82. package/lib/commands/issue/report.js +1 -1
  83. package/lib/commands/issue/shared.js +1 -1
  84. package/lib/commands/logs/index.js +1 -1
  85. package/lib/commands/menu/index.js +1 -1
  86. package/lib/commands/menu/shared/compare-table.js +1 -1
  87. package/lib/commands/menu/shared/index.js +1 -1
  88. package/lib/commands/menu/shared/inquirer.js +1 -1
  89. package/lib/commands/menu/shared/local-pages.js +1 -1
  90. package/lib/commands/menu/shared/logic.js +1 -1
  91. package/lib/commands/menu/shared/service.js +1 -1
  92. package/lib/commands/menu/shared/sync-core.js +1 -1
  93. package/lib/commands/menu/shared/update-core.js +1 -1
  94. package/lib/commands/menu/shared/valid-url.js +1 -1
  95. package/lib/commands/menu/sync.js +1 -1
  96. package/lib/commands/menu/update.js +1 -1
  97. package/lib/commands/page/generate-start.js +1 -1
  98. package/lib/commands/page/generate-status.js +1 -1
  99. package/lib/commands/page/index.js +1 -1
  100. package/lib/commands/page/pull.js +1 -1
  101. package/lib/commands/page/push.js +1 -1
  102. package/lib/commands/page/relation-audit.js +1 -1
  103. package/lib/commands/page/shared.js +1 -1
  104. package/lib/commands/page/standard-page-status.js +1 -1
  105. package/lib/commands/page/sync.js +1 -1
  106. package/lib/commands/project/create/enhanced-guided-create.js +1 -1
  107. package/lib/commands/project/create/format-elapsed.js +1 -1
  108. package/lib/commands/project/create/main.js +1 -1
  109. package/lib/commands/project/create/non-interactive.js +1 -1
  110. package/lib/commands/project/create/project-template-path.js +1 -1
  111. package/lib/commands/project/create/use-copy-project-template.js +1 -1
  112. package/lib/commands/project/create/use-format-code.js +1 -1
  113. package/lib/commands/project/create/use-install-dependencies.js +1 -1
  114. package/lib/commands/project/index.js +1 -1
  115. package/lib/commands/project/init.js +1 -1
  116. package/lib/commands/project/upgrade.js +1 -1
  117. package/lib/commands/registry.js +1 -1
  118. package/lib/commands/run/index.js +1 -1
  119. package/lib/commands/schema.js +1 -1
  120. package/lib/commands/skill/index.js +1 -1
  121. package/lib/commands/sql/create.js +1 -1
  122. package/lib/commands/sql/delete.js +1 -1
  123. package/lib/commands/sql/detail.js +1 -1
  124. package/lib/commands/sql/exec.js +1 -1
  125. package/lib/commands/sql/index.js +1 -1
  126. package/lib/commands/sql/list.js +1 -1
  127. package/lib/commands/sql/pull.js +1 -1
  128. package/lib/commands/sql/push.js +1 -1
  129. package/lib/commands/sql/save.js +1 -1
  130. package/lib/commands/sql/shared.js +1 -1
  131. package/lib/commands/sql/status.js +1 -1
  132. package/lib/commands/sql/validate.js +1 -1
  133. package/lib/config/schema.js +1 -1
  134. package/lib/constant/cdn.js +1 -1
  135. package/lib/constant/cli.js +1 -1
  136. package/lib/constant/defaults.js +1 -1
  137. package/lib/constant/domain.js +1 -1
  138. package/lib/constant/env.js +1 -1
  139. package/lib/constant/output.js +1 -1
  140. package/lib/constant/paths.js +1 -1
  141. package/lib/constant/risk.js +1 -1
  142. package/lib/context.js +1 -1
  143. package/lib/core/alias-resolver.js +1 -1
  144. package/lib/core/api-client.js +1 -1
  145. package/lib/core/bff/config.js +1 -1
  146. package/lib/core/bff/file-system.js +1 -1
  147. package/lib/core/bff/hash.js +1 -1
  148. package/lib/core/bff/lock.js +1 -1
  149. package/lib/core/bff/utils.js +1 -1
  150. package/lib/core/db-resolver.js +1 -1
  151. package/lib/core/page/file-system.js +1 -1
  152. package/lib/core/page/hash.js +1 -1
  153. package/lib/core/page/lock.js +1 -1
  154. package/lib/core/sql-sync/config.js +1 -1
  155. package/lib/core/sql-sync/file-system.js +1 -1
  156. package/lib/core/sql-sync/hash.js +1 -1
  157. package/lib/core/sql-sync/lock.js +1 -1
  158. package/lib/core/sql-sync/utils.js +1 -1
  159. package/lib/core/sql-validator.js +1 -1
  160. package/lib/errors.js +1 -1
  161. package/lib/framework/build-all-flags.js +1 -1
  162. package/lib/framework/flags.js +1 -1
  163. package/lib/framework/help.js +1 -1
  164. package/lib/framework/index.js +1 -1
  165. package/lib/framework/output.js +1 -1
  166. package/lib/framework/response.js +1 -1
  167. package/lib/framework/runner-alias.js +1 -1
  168. package/lib/framework/runner.js +1 -1
  169. package/lib/framework/schema-export.js +1 -1
  170. package/lib/framework/types.js +1 -1
  171. package/lib/generated/build-info.js +1 -1
  172. package/lib/help.js +1 -1
  173. package/lib/skills/main.js +1 -1
  174. package/lib/skills/npx-skills-add.js +1 -1
  175. package/lib/telemetry/cli-command-trace.js +1 -1
  176. package/lib/telemetry/cli-help-trace.js +1 -1
  177. package/lib/telemetry/ensure-cli-otel-config.js +1 -1
  178. package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
  179. package/lib/telemetry/send-cli-trace-log.js +1 -1
  180. package/lib/telemetry/send-platform-issue-collect-log.js +1 -1
  181. package/lib/utils/ai_config.js +1 -1
  182. package/lib/utils/apply-jq-filter.js +1 -1
  183. package/lib/utils/cdn-config.js +1 -1
  184. package/lib/utils/check-sdk-version.js +1 -1
  185. package/lib/utils/cli-version-check.js +1 -1
  186. package/lib/utils/cli-version-policy.js +1 -1
  187. package/lib/utils/config.js +1 -1
  188. package/lib/utils/copy-directory.js +1 -1
  189. package/lib/utils/entity-with-id.js +1 -1
  190. package/lib/utils/file-utils.js +1 -1
  191. package/lib/utils/guides-cdn.js +1 -1
  192. package/lib/utils/http-client.js +1 -1
  193. package/lib/utils/is-non-interactive.js +1 -1
  194. package/lib/utils/logger.js +1 -1
  195. package/lib/utils/params.js +1 -1
  196. package/lib/utils/platform.js +1 -1
  197. package/lib/utils/rules-cdn.js +1 -1
  198. package/lib/utils/sleep.js +1 -1
  199. package/lib/utils/template-replacer.js +1 -1
  200. package/lib/utils/update-notice.js +1 -1
  201. package/lib/utils/version.js +1 -1
  202. package/lib/utils/with-active-cookie.js +1 -1
  203. package/lib/utils/write-cli-side-channel.js +1 -1
  204. package/package.json +1 -1
@@ -1 +1 @@
1
- function a203_0x268e(_0x45e5a9,_0x49ed11){_0x45e5a9=_0x45e5a9-0x18b;const _0xbabe0e=a203_0xbabe();let _0x268e15=_0xbabe0e[_0x45e5a9];return _0x268e15;}const a203_0x25a627=a203_0x268e;function a203_0xbabe(){const _0x29f69e=['processFile','processDirectory','getMonth','replaceApiContent','645992KXjMIq','.css','.tpl','getSeconds','getMinutes','readFile','error','22428veWSKv','.scss','datasetCode','isFile','getDate','map','replace','getFullYear','\x20},','getHours','LOVRABET','toUpperCase','12lNtMFs','alias','pad','3702FFoGXL','slice','toISOString','.tsx','tableName','now','api','utf8','replaceContent','7GaJgdY','info','tableName:\x20\x22','.ts','alias:\x20\x22','copyFile','pop','模板内容替换完成','1449789VFLywp','includes','padStart','6ypdsZG','formatLocalTimestamp','name','5365rHPMrF','模板内容替换失败','promises','.md','writeFile','endsWith','readdir','toComponentName','name:\x20\x22','toDisplayTitle','datasetCode:\x20\x22','开始处理模板内容替换','success','default','template','\x0a\x20\x20\x20\x20{\x20','3460nKxTAo','processTemplate','split','join','1713816FSHGUb','4570264bSerPz','charAt','100858YUfOrk'];a203_0xbabe=function(){return _0x29f69e;};return a203_0xbabe();}(function(_0x34806b,_0x49b726){const _0x1b7e49=a203_0x268e,_0x193beb=_0x34806b();while(!![]){try{const _0x182c65=parseInt(_0x1b7e49(0x197))/0x1*(-parseInt(_0x1b7e49(0x1b1))/0x2)+parseInt(_0x1b7e49(0x1ae))/0x3+-parseInt(_0x1b7e49(0x1b6))/0x4+parseInt(_0x1b7e49(0x19a))/0x5*(parseInt(_0x1b7e49(0x1cc))/0x6)+-parseInt(_0x1b7e49(0x18c))/0x7*(-parseInt(_0x1b7e49(0x1af))/0x8)+parseInt(_0x1b7e49(0x1bd))/0x9*(-parseInt(_0x1b7e49(0x1aa))/0xa)+parseInt(_0x1b7e49(0x194))/0xb*(parseInt(_0x1b7e49(0x1c9))/0xc);if(_0x182c65===_0x49b726)break;else _0x193beb['push'](_0x193beb['shift']());}catch(_0x1ae1b1){_0x193beb['push'](_0x193beb['shift']());}}}(a203_0xbabe,0x94f2b));import a203_0x489629 from'node:fs';import a203_0x581643 from'node:path';import{logger}from'../utils/logger.js';import{getCliVersion}from'../utils/version.js';const CLI_VERSION=getCliVersion();export class TemplateReplacer{static[a203_0x25a627(0x1cb)](_0x66be6f){const _0x5c63dc=a203_0x25a627;return String(_0x66be6f)[_0x5c63dc(0x196)](0x2,'0');}static['formatLocalTimestamp'](_0x1ddcce){const _0x3505e2=a203_0x25a627,_0x2508b7=_0x1ddcce[_0x3505e2(0x1c4)](),_0x3a0c56=this[_0x3505e2(0x1cb)](_0x1ddcce[_0x3505e2(0x1b4)]()+0x1),_0x35e5f8=this[_0x3505e2(0x1cb)](_0x1ddcce[_0x3505e2(0x1c1)]()),_0x4b793e=this[_0x3505e2(0x1cb)](_0x1ddcce[_0x3505e2(0x1c6)]()),_0x29c296=this[_0x3505e2(0x1cb)](_0x1ddcce[_0x3505e2(0x1ba)]()),_0xddc8c2=this[_0x3505e2(0x1cb)](_0x1ddcce[_0x3505e2(0x1b9)]());return{'createdAt':_0x2508b7+'-'+_0x3a0c56+'-'+_0x35e5f8+'\x20'+_0x4b793e+':'+_0x29c296+':'+_0xddc8c2,'createdDate':_0x2508b7+'-'+_0x3a0c56+'-'+_0x35e5f8,'createdTime':_0x4b793e+':'+_0x29c296+':'+_0xddc8c2};}static[a203_0x25a627(0x1a1)](_0x280204){const _0x1bd373=a203_0x25a627,_0x540273=_0x280204[_0x1bd373(0x1ac)]('/')[_0x1bd373(0x192)]()||_0x280204;return _0x540273[_0x1bd373(0x1ac)]('-')['map'](_0x3c205f=>_0x3c205f['charAt'](0x0)[_0x1bd373(0x1c8)]()+_0x3c205f[_0x1bd373(0x1cd)](0x1)['toLowerCase']())[_0x1bd373(0x1ad)]('');}static[a203_0x25a627(0x1a3)](_0x4daf44){const _0x5e4ab7=a203_0x25a627,_0x3bbc48=_0x4daf44[_0x5e4ab7(0x1ac)]('/')['pop']()||_0x4daf44;return _0x3bbc48[_0x5e4ab7(0x1ac)]('-')[_0x5e4ab7(0x1c2)](_0x57315b=>_0x57315b[_0x5e4ab7(0x1b0)](0x0)[_0x5e4ab7(0x1c8)]()+_0x57315b['slice'](0x1)['toLowerCase']())['join']('\x20');}static[a203_0x25a627(0x18b)](_0x1e57c5,_0x452644,_0x2f611c){const _0x1a0aef=a203_0x25a627,_0x4a68ea=this[_0x1a0aef(0x1a1)](_0x452644),_0x4b5157=this[_0x1a0aef(0x1a3)](_0x452644),{createdAt:_0x2046f1,createdDate:_0x528a3a,createdTime:_0x1deb06}=this[_0x1a0aef(0x198)](new Date());let _0x2ae813=_0x1e57c5['replace'](/\{CliVersion\}/g,CLI_VERSION)[_0x1a0aef(0x1c3)](/\{ComponentName\}/g,_0x4a68ea)['replace'](/\{DisplayTitle\}/g,_0x4b5157)[_0x1a0aef(0x1c3)](/\{PageName\}/g,_0x452644)[_0x1a0aef(0x1c3)](/\{TemplateName\}/g,_0x2f611c)[_0x1a0aef(0x1c3)](/\{CreatedAt\}/g,_0x2046f1)[_0x1a0aef(0x1c3)](/\{CreatedDate\}/g,_0x528a3a)[_0x1a0aef(0x1c3)](/\{CreatedTime\}/g,_0x1deb06);return _0x2ae813;}static[a203_0x25a627(0x1b5)](_0x151548,_0x58e434,_0x23c91a,_0x52b5ed,_0x80847f,_0x558cbd,_0x3a8b41,_0xf02b2d){const _0x51257c=a203_0x25a627,_0x548524=new Date(),_0x506d41=_0x548524[_0x51257c(0x1ce)](),_0x42e817=_0x23c91a[_0x51257c(0x1c2)](_0x628446=>{const _0x4cd79e=_0x51257c,_0xf4383b=[_0x4cd79e(0x1a4)+_0x628446[_0x4cd79e(0x1bf)]+'\x22',_0x4cd79e(0x18e)+_0x628446[_0x4cd79e(0x1d0)]+'\x22',_0x4cd79e(0x1a2)+_0x628446[_0x4cd79e(0x199)]+'\x22'];return _0x628446[_0x4cd79e(0x1ca)]&&_0xf4383b['push'](_0x4cd79e(0x190)+_0x628446[_0x4cd79e(0x1ca)]+'\x22'),_0x4cd79e(0x1a9)+_0xf4383b[_0x4cd79e(0x1ad)](',\x20')+_0x4cd79e(0x1c5);})['join'](''),_0x99aff3=_0x52b5ed||_0x23c91a[0x0]?.[_0x51257c(0x1ca)]||'YourModel';let _0x20c0c2=_0x151548[_0x51257c(0x1c3)](/\{AppCode\}/g,_0x58e434)['replace'](/\{ModelConfigs\}/g,_0x42e817)[_0x51257c(0x1c3)](/\{ExampleModelName\}/g,_0x99aff3)['replace'](/\{ApiFileName\}/g,_0x80847f||_0x51257c(0x1d2))[_0x51257c(0x1c3)](/\{ConfigName\}/g,_0x558cbd||_0x51257c(0x1a7))[_0x51257c(0x1c3)](/\{ClientConfigParam\}/g,_0x3a8b41||'')[_0x51257c(0x1c3)](/\{VarPrefix\}/g,_0xf02b2d||_0x51257c(0x1c7))[_0x51257c(0x1c3)](/\{CreatedAt\}/g,_0x506d41);return _0x20c0c2;}static async[a203_0x25a627(0x1ab)](_0x4d3a83,_0x984d63,_0x50002d,_0x213542,_0x3064de=!![]){const _0x10002d=a203_0x25a627,_0x7092cc=Date[_0x10002d(0x1d1)]();try{_0x3064de&&logger[_0x10002d(0x18d)]('template',_0x10002d(0x1a5),{'templatePath':_0x4d3a83,'targetPath':_0x984d63,'pageName':_0x50002d,'templateName':_0x213542});await a203_0x489629[_0x10002d(0x19c)]['mkdir'](_0x984d63,{'recursive':!![]}),await this[_0x10002d(0x1b3)](_0x4d3a83,_0x984d63,_0x50002d,_0x213542);if(_0x3064de){const _0x163c48=Date[_0x10002d(0x1d1)]()-_0x7092cc;logger[_0x10002d(0x1a6)](_0x10002d(0x1a8),_0x10002d(0x193),_0x163c48,{'pageName':_0x50002d,'templateName':_0x213542});}}catch(_0x38fa19){if(_0x3064de){const _0x1108e4=Date[_0x10002d(0x1d1)]()-_0x7092cc;logger[_0x10002d(0x1bc)]('template',_0x10002d(0x19b),{'templatePath':_0x4d3a83,'targetPath':_0x984d63,'pageName':_0x50002d,'templateName':_0x213542,'error':_0x38fa19 instanceof Error?_0x38fa19['message']:String(_0x38fa19),'duration':_0x1108e4});}throw _0x38fa19;}}static async[a203_0x25a627(0x1b3)](_0xb1dee8,_0x179bdb,_0x10d361,_0x5d48b0){const _0xe739f3=a203_0x25a627,_0x32b184=await a203_0x489629[_0xe739f3(0x19c)][_0xe739f3(0x1a0)](_0xb1dee8,{'withFileTypes':!![]});for(const _0x37b4da of _0x32b184){const _0x5f5c47=a203_0x581643[_0xe739f3(0x1ad)](_0xb1dee8,_0x37b4da[_0xe739f3(0x199)]);let _0x36542b=a203_0x581643[_0xe739f3(0x1ad)](_0x179bdb,_0x37b4da['name']);_0x37b4da[_0xe739f3(0x199)]['endsWith'](_0xe739f3(0x1b8))&&(_0x36542b=a203_0x581643['join'](_0x179bdb,_0x37b4da[_0xe739f3(0x199)][_0xe739f3(0x1c3)](/\.tpl$/,'')));if(_0x37b4da['isDirectory']())await a203_0x489629[_0xe739f3(0x19c)]['mkdir'](_0x36542b,{'recursive':!![]}),await this[_0xe739f3(0x1b3)](_0x5f5c47,_0x36542b,_0x10d361,_0x5d48b0);else _0x37b4da[_0xe739f3(0x1c0)]()&&await this[_0xe739f3(0x1b2)](_0x5f5c47,_0x36542b,_0x10d361,_0x5d48b0);}}static async[a203_0x25a627(0x1b2)](_0x44c466,_0x942542,_0xef5cea,_0x4c8472){const _0x24237c=a203_0x25a627,_0x18ecd2=a203_0x581643['extname'](_0x44c466)['toLowerCase']();_0x44c466[_0x24237c(0x19f)]('.tpl')&&(_0x942542=_0x942542[_0x24237c(0x1c3)](/\.tpl$/,''));const _0x15e401=[_0x24237c(0x1cf),_0x24237c(0x18f),'.jsx','.js','.json',_0x24237c(0x19d),_0x24237c(0x1b7),_0x24237c(0x1be),_0x24237c(0x1b8)];if(_0x15e401[_0x24237c(0x195)](_0x18ecd2)||_0x44c466[_0x24237c(0x19f)](_0x24237c(0x1b8))){const _0x227b19=await a203_0x489629[_0x24237c(0x19c)][_0x24237c(0x1bb)](_0x44c466,_0x24237c(0x1d3)),_0xc27dfc=this[_0x24237c(0x18b)](_0x227b19,_0xef5cea,_0x4c8472);await a203_0x489629[_0x24237c(0x19c)][_0x24237c(0x19e)](_0x942542,_0xc27dfc,_0x24237c(0x1d3));}else await a203_0x489629[_0x24237c(0x19c)][_0x24237c(0x191)](_0x44c466,_0x942542);}}
1
+ function a203_0x3a6c(_0x14dc93,_0x12b27a){_0x14dc93=_0x14dc93-0x126;const _0xa378c1=a203_0xa378();let _0x3a6c7e=_0xa378c1[_0x14dc93];return _0x3a6c7e;}function a203_0xa378(){const _0x1d1fbe=['message','.tpl','2675azCGlA','getFullYear','mkdir','writeFile','charAt','error','.tsx','6523299qaOKcY','name:\x20\x22','YourModel','\x0a\x20\x20\x20\x20{\x20','toDisplayTitle','getHours','datasetCode','toLowerCase','readFile','588254hHFpMe','info','processDirectory','toUpperCase','tableName:\x20\x22','template','utf8','api','name','alias:\x20\x22','1070033DUKyNm','readdir','processTemplate','replaceContent','join','processFile','includes','\x20},','.jsx','tableName','725250fIPGcy','.scss','模板内容替换完成','8651552AkSJma','pad','copyFile','.ts','promises','getDate','121345YJNMBQ','extname','datasetCode:\x20\x22','formatLocalTimestamp','LOVRABET','map','endsWith','1104XGQOep','replace','padStart','114SKDgnD','success','replaceApiContent','default','模板内容替换失败','toComponentName','now','开始处理模板内容替换','push','alias','isFile','split','slice','3SxTrcL','isDirectory','toISOString','.json'];a203_0xa378=function(){return _0x1d1fbe;};return a203_0xa378();}const a203_0x35600b=a203_0x3a6c;(function(_0x49a505,_0x4911a3){const _0x3ff096=a203_0x3a6c,_0x54128f=_0x49a505();while(!![]){try{const _0xb3a3c8=-parseInt(_0x3ff096(0x13d))/0x1+-parseInt(_0x3ff096(0x133))/0x2*(-parseInt(_0x3ff096(0x167))/0x3)+-parseInt(_0x3ff096(0x157))/0x4*(parseInt(_0x3ff096(0x16d))/0x5)+-parseInt(_0x3ff096(0x15a))/0x6*(parseInt(_0x3ff096(0x150))/0x7)+parseInt(_0x3ff096(0x14a))/0x8+parseInt(_0x3ff096(0x12a))/0x9+parseInt(_0x3ff096(0x147))/0xa;if(_0xb3a3c8===_0x4911a3)break;else _0x54128f['push'](_0x54128f['shift']());}catch(_0x40404b){_0x54128f['push'](_0x54128f['shift']());}}}(a203_0xa378,0x98cb9));import a203_0x3ee72f from'node:fs';import a203_0x5b48ec from'node:path';import{logger}from'../utils/logger.js';import{getCliVersion}from'../utils/version.js';const CLI_VERSION=getCliVersion();export class TemplateReplacer{static['pad'](_0x1e90d6){const _0x3913f4=a203_0x3a6c;return String(_0x1e90d6)[_0x3913f4(0x159)](0x2,'0');}static[a203_0x35600b(0x153)](_0x3b4e7b){const _0x24b94b=a203_0x35600b,_0x3eecdd=_0x3b4e7b[_0x24b94b(0x16e)](),_0x100cd2=this[_0x24b94b(0x14b)](_0x3b4e7b['getMonth']()+0x1),_0x944aa3=this['pad'](_0x3b4e7b[_0x24b94b(0x14f)]()),_0x26cb76=this[_0x24b94b(0x14b)](_0x3b4e7b[_0x24b94b(0x12f)]()),_0x514993=this['pad'](_0x3b4e7b['getMinutes']()),_0x192a39=this[_0x24b94b(0x14b)](_0x3b4e7b['getSeconds']());return{'createdAt':_0x3eecdd+'-'+_0x100cd2+'-'+_0x944aa3+'\x20'+_0x26cb76+':'+_0x514993+':'+_0x192a39,'createdDate':_0x3eecdd+'-'+_0x100cd2+'-'+_0x944aa3,'createdTime':_0x26cb76+':'+_0x514993+':'+_0x192a39};}static[a203_0x35600b(0x15f)](_0x3ac3e9){const _0x179f41=a203_0x35600b,_0xafddd3=_0x3ac3e9[_0x179f41(0x165)]('/')['pop']()||_0x3ac3e9;return _0xafddd3[_0x179f41(0x165)]('-')[_0x179f41(0x155)](_0xb51ef6=>_0xb51ef6[_0x179f41(0x127)](0x0)[_0x179f41(0x136)]()+_0xb51ef6[_0x179f41(0x166)](0x1)[_0x179f41(0x131)]())[_0x179f41(0x141)]('');}static[a203_0x35600b(0x12e)](_0x4af181){const _0x20d5c1=a203_0x35600b,_0x2249be=_0x4af181['split']('/')['pop']()||_0x4af181;return _0x2249be[_0x20d5c1(0x165)]('-')[_0x20d5c1(0x155)](_0x8f8a02=>_0x8f8a02[_0x20d5c1(0x127)](0x0)[_0x20d5c1(0x136)]()+_0x8f8a02['slice'](0x1)[_0x20d5c1(0x131)]())[_0x20d5c1(0x141)]('\x20');}static[a203_0x35600b(0x140)](_0x1aba00,_0x16a13e,_0x1e3149){const _0x289963=a203_0x35600b,_0xbb3075=this[_0x289963(0x15f)](_0x16a13e),_0x4d206e=this['toDisplayTitle'](_0x16a13e),{createdAt:_0x210537,createdDate:_0x2721e8,createdTime:_0x82a4d9}=this['formatLocalTimestamp'](new Date());let _0x30565c=_0x1aba00['replace'](/\{CliVersion\}/g,CLI_VERSION)[_0x289963(0x158)](/\{ComponentName\}/g,_0xbb3075)['replace'](/\{DisplayTitle\}/g,_0x4d206e)['replace'](/\{PageName\}/g,_0x16a13e)[_0x289963(0x158)](/\{TemplateName\}/g,_0x1e3149)[_0x289963(0x158)](/\{CreatedAt\}/g,_0x210537)[_0x289963(0x158)](/\{CreatedDate\}/g,_0x2721e8)[_0x289963(0x158)](/\{CreatedTime\}/g,_0x82a4d9);return _0x30565c;}static[a203_0x35600b(0x15c)](_0x2a04aa,_0x833cba,_0x1ea6c1,_0x3d5f18,_0x1b022e,_0x2e0d89,_0x4f280a,_0x30c842){const _0x1ded2a=a203_0x35600b,_0x271872=new Date(),_0x5a8f0c=_0x271872[_0x1ded2a(0x169)](),_0xa152aa=_0x1ea6c1[_0x1ded2a(0x155)](_0xd59134=>{const _0x3ee80b=_0x1ded2a,_0x4e5c69=[_0x3ee80b(0x152)+_0xd59134[_0x3ee80b(0x130)]+'\x22',_0x3ee80b(0x137)+_0xd59134[_0x3ee80b(0x146)]+'\x22',_0x3ee80b(0x12b)+_0xd59134[_0x3ee80b(0x13b)]+'\x22'];return _0xd59134[_0x3ee80b(0x163)]&&_0x4e5c69[_0x3ee80b(0x162)](_0x3ee80b(0x13c)+_0xd59134['alias']+'\x22'),_0x3ee80b(0x12d)+_0x4e5c69[_0x3ee80b(0x141)](',\x20')+_0x3ee80b(0x144);})[_0x1ded2a(0x141)](''),_0x1f9c5f=_0x3d5f18||_0x1ea6c1[0x0]?.[_0x1ded2a(0x163)]||_0x1ded2a(0x12c);let _0x341063=_0x2a04aa['replace'](/\{AppCode\}/g,_0x833cba)[_0x1ded2a(0x158)](/\{ModelConfigs\}/g,_0xa152aa)[_0x1ded2a(0x158)](/\{ExampleModelName\}/g,_0x1f9c5f)[_0x1ded2a(0x158)](/\{ApiFileName\}/g,_0x1b022e||_0x1ded2a(0x13a))[_0x1ded2a(0x158)](/\{ConfigName\}/g,_0x2e0d89||_0x1ded2a(0x15d))[_0x1ded2a(0x158)](/\{ClientConfigParam\}/g,_0x4f280a||'')['replace'](/\{VarPrefix\}/g,_0x30c842||_0x1ded2a(0x154))[_0x1ded2a(0x158)](/\{CreatedAt\}/g,_0x5a8f0c);return _0x341063;}static async[a203_0x35600b(0x13f)](_0x572efa,_0x5cf124,_0x369a39,_0x3932fc,_0x4e6353=!![]){const _0x19b596=a203_0x35600b,_0x529d98=Date[_0x19b596(0x160)]();try{_0x4e6353&&logger[_0x19b596(0x134)](_0x19b596(0x138),_0x19b596(0x161),{'templatePath':_0x572efa,'targetPath':_0x5cf124,'pageName':_0x369a39,'templateName':_0x3932fc});await a203_0x3ee72f[_0x19b596(0x14e)][_0x19b596(0x16f)](_0x5cf124,{'recursive':!![]}),await this['processDirectory'](_0x572efa,_0x5cf124,_0x369a39,_0x3932fc);if(_0x4e6353){const _0x34d7fb=Date['now']()-_0x529d98;logger[_0x19b596(0x15b)](_0x19b596(0x138),_0x19b596(0x149),_0x34d7fb,{'pageName':_0x369a39,'templateName':_0x3932fc});}}catch(_0x16ce79){if(_0x4e6353){const _0x46f782=Date[_0x19b596(0x160)]()-_0x529d98;logger[_0x19b596(0x128)](_0x19b596(0x138),_0x19b596(0x15e),{'templatePath':_0x572efa,'targetPath':_0x5cf124,'pageName':_0x369a39,'templateName':_0x3932fc,'error':_0x16ce79 instanceof Error?_0x16ce79[_0x19b596(0x16b)]:String(_0x16ce79),'duration':_0x46f782});}throw _0x16ce79;}}static async[a203_0x35600b(0x135)](_0x1136f0,_0x173c4f,_0x3b07f2,_0x296625){const _0x5164a7=a203_0x35600b,_0x20bdca=await a203_0x3ee72f['promises'][_0x5164a7(0x13e)](_0x1136f0,{'withFileTypes':!![]});for(const _0x8ca782 of _0x20bdca){const _0x1170fc=a203_0x5b48ec[_0x5164a7(0x141)](_0x1136f0,_0x8ca782['name']);let _0x356da6=a203_0x5b48ec[_0x5164a7(0x141)](_0x173c4f,_0x8ca782[_0x5164a7(0x13b)]);_0x8ca782['name'][_0x5164a7(0x156)](_0x5164a7(0x16c))&&(_0x356da6=a203_0x5b48ec['join'](_0x173c4f,_0x8ca782['name']['replace'](/\.tpl$/,'')));if(_0x8ca782[_0x5164a7(0x168)]())await a203_0x3ee72f[_0x5164a7(0x14e)][_0x5164a7(0x16f)](_0x356da6,{'recursive':!![]}),await this['processDirectory'](_0x1170fc,_0x356da6,_0x3b07f2,_0x296625);else _0x8ca782[_0x5164a7(0x164)]()&&await this['processFile'](_0x1170fc,_0x356da6,_0x3b07f2,_0x296625);}}static async[a203_0x35600b(0x142)](_0x5c5863,_0x330d51,_0x1c688e,_0x2f2398){const _0x3cb878=a203_0x35600b,_0xe7f8e7=a203_0x5b48ec[_0x3cb878(0x151)](_0x5c5863)[_0x3cb878(0x131)]();_0x5c5863[_0x3cb878(0x156)](_0x3cb878(0x16c))&&(_0x330d51=_0x330d51[_0x3cb878(0x158)](/\.tpl$/,''));const _0x71b902=[_0x3cb878(0x129),_0x3cb878(0x14d),_0x3cb878(0x145),'.js',_0x3cb878(0x16a),'.md','.css',_0x3cb878(0x148),_0x3cb878(0x16c)];if(_0x71b902[_0x3cb878(0x143)](_0xe7f8e7)||_0x5c5863[_0x3cb878(0x156)](_0x3cb878(0x16c))){const _0x49ba38=await a203_0x3ee72f[_0x3cb878(0x14e)][_0x3cb878(0x132)](_0x5c5863,_0x3cb878(0x139)),_0x2da06a=this[_0x3cb878(0x140)](_0x49ba38,_0x1c688e,_0x2f2398);await a203_0x3ee72f['promises'][_0x3cb878(0x126)](_0x330d51,_0x2da06a,'utf8');}else await a203_0x3ee72f[_0x3cb878(0x14e)][_0x3cb878(0x14c)](_0x5c5863,_0x330d51);}}
@@ -1 +1 @@
1
- function a204_0x39f6(){const _0x40bcac=['timeout','62pfnMpl','https://registry.npmjs.org/-/package/','38660nJDsQK','filter','true','10HYhLlS','parse','2826WxFOTu','501832nXtbhN','5211696YEOPrq','valid','trim','number','yes','checkedAt','stringify','lastNotifiedVersion','5733637BUEeOq','/dist-tags','latest',',\x20run:\x20','lastNotifiedAt','1653402HsXSSx','23747HYCemj','entries','utf8','map','3291969DYPqYg','.cache','https://www.npmjs.com/package/','rabetbase-cli','json','\x20update'];a204_0x39f6=function(){return _0x40bcac;};return a204_0x39f6();}(function(_0x4ba2f3,_0x1a4955){const _0x83571d=a204_0xcd3b,_0x1ecacd=_0x4ba2f3();while(!![]){try{const _0x4201eb=parseInt(_0x83571d(0x1cc))/0x1*(parseInt(_0x83571d(0x1d7))/0x2)+-parseInt(_0x83571d(0x1d0))/0x3+-parseInt(_0x83571d(0x1be))/0x4+-parseInt(_0x83571d(0x1ba))/0x5*(-parseInt(_0x83571d(0x1cb))/0x6)+parseInt(_0x83571d(0x1c6))/0x7+-parseInt(_0x83571d(0x1bd))/0x8+-parseInt(_0x83571d(0x1bc))/0x9*(-parseInt(_0x83571d(0x1d9))/0xa);if(_0x4201eb===_0x1a4955)break;else _0x1ecacd['push'](_0x1ecacd['shift']());}catch(_0x3c35ac){_0x1ecacd['push'](_0x1ecacd['shift']());}}}(a204_0x39f6,0xd14f2));import{mkdir,readFile,writeFile}from'node:fs/promises';import{homedir}from'node:os';import{dirname,join}from'node:path';import a204_0x2b7152 from'semver';import{CLI_BIN_NAME,NPM_PACKAGE_NAME}from'../constant/cli.js';import{getCliVersion}from'../utils/version.js';function a204_0xcd3b(_0x1850b0,_0x2f8e61){_0x1850b0=_0x1850b0-0x1ba;const _0x39f604=a204_0x39f6();let _0xcd3b07=_0x39f604[_0x1850b0];return _0xcd3b07;}const UPDATE_CHECK_TTL_MS=0xc*0x3c*0x3c*0x3e8,UPDATE_NOTICE_TTL_MS=0x18*0x3c*0x3c*0x3e8;function isUpdateNoticeDisabled(){const _0x495812=a204_0xcd3b,_0x2e614f=process.env.RABETBASE_NO_UPDATE_NOTICE?.['trim']()['toLowerCase']();return _0x2e614f==='1'||_0x2e614f===_0x495812(0x1db)||_0x2e614f===_0x495812(0x1c2);}function cacheRoot(){const _0xaf8f8d=a204_0xcd3b;return process.env.XDG_CACHE_HOME||process.env.LOCALAPPDATA||join(homedir(),_0xaf8f8d(0x1d1));}export function getUpdateNoticeCachePath(){const _0x1262cb=a204_0xcd3b;return join(cacheRoot(),_0x1262cb(0x1d3),'update-check.json');}async function readUpdateNoticeCache(){const _0x349f0c=a204_0xcd3b;try{const _0x49bee9=await readFile(getUpdateNoticeCachePath(),'utf8'),_0x165de1=JSON[_0x349f0c(0x1bb)](_0x49bee9);if(!_0x165de1||typeof _0x165de1!=='object')return{};return _0x165de1;}catch{return{};}}async function writeUpdateNoticeCache(_0x201474){const _0x5ad7bf=a204_0xcd3b;try{const _0x1467e2=getUpdateNoticeCachePath();await mkdir(dirname(_0x1467e2),{'recursive':!![]}),await writeFile(_0x1467e2,JSON[_0x5ad7bf(0x1c4)](_0x201474,null,0x2)+'\x0a',_0x5ad7bf(0x1ce));}catch{}}function isFreshCheck(_0x3d6ee9,_0x2a774f){const _0x21e891=a204_0xcd3b;return typeof _0x3d6ee9[_0x21e891(0x1c3)]===_0x21e891(0x1c1)&&_0x2a774f-_0x3d6ee9[_0x21e891(0x1c3)]<UPDATE_CHECK_TTL_MS;}function isRecentlyNotified(_0x12b91f,_0x5da191,_0x1a0baa){const _0x1416ee=a204_0xcd3b;return _0x12b91f[_0x1416ee(0x1c5)]===_0x5da191&&typeof _0x12b91f[_0x1416ee(0x1ca)]===_0x1416ee(0x1c1)&&_0x1a0baa-_0x12b91f['lastNotifiedAt']<UPDATE_NOTICE_TTL_MS;}async function fetchNpmDistTags(_0x5e31aa=0x5dc){const _0x37c76c=a204_0xcd3b;try{const _0x1b49b5=await fetch(_0x37c76c(0x1d8)+encodeURIComponent(NPM_PACKAGE_NAME)+_0x37c76c(0x1c7),{'signal':AbortSignal[_0x37c76c(0x1d6)](_0x5e31aa)});if(!_0x1b49b5['ok'])return null;const _0x4d37cb=await _0x1b49b5[_0x37c76c(0x1d4)]();if(!_0x4d37cb||typeof _0x4d37cb!=='object')return null;return Object['fromEntries'](Object[_0x37c76c(0x1cd)](_0x4d37cb)[_0x37c76c(0x1da)](([,_0x220600])=>typeof _0x220600==='string'&&_0x220600[_0x37c76c(0x1c0)]()['length']>0x0)[_0x37c76c(0x1cf)](([_0xc90dce,_0x1b7bba])=>[_0xc90dce,String(_0x1b7bba)[_0x37c76c(0x1c0)]()]));}catch{return null;}}export function buildNpmVersionUrl(_0x192941){const _0x2e2613=a204_0xcd3b;return _0x2e2613(0x1d2)+NPM_PACKAGE_NAME+'/v/'+_0x192941;}export async function resolveLatestUpdateNotice(){const _0x3079a4=a204_0xcd3b;if(isUpdateNoticeDisabled())return null;try{const _0x3c1f84=Date['now'](),_0x4e9144=getCliVersion(),_0x47450c=await readUpdateNoticeCache();let _0x4a488e=isFreshCheck(_0x47450c,_0x3c1f84)?_0x47450c[_0x3079a4(0x1c8)]?.[_0x3079a4(0x1c0)]():undefined;if(!_0x4a488e&&!isFreshCheck(_0x47450c,_0x3c1f84)){const _0x597253=await fetchNpmDistTags();_0x4a488e=_0x597253?.[_0x3079a4(0x1c8)]?.[_0x3079a4(0x1c0)](),await writeUpdateNoticeCache({..._0x47450c,'checkedAt':_0x3c1f84,'latest':_0x4a488e,'failed':!_0x4a488e});}if(!_0x4a488e||!a204_0x2b7152[_0x3079a4(0x1bf)](_0x4e9144)||!a204_0x2b7152[_0x3079a4(0x1bf)](_0x4a488e))return null;if(a204_0x2b7152['gte'](_0x4e9144,_0x4a488e))return null;if(isRecentlyNotified(_0x47450c,_0x4a488e,_0x3c1f84))return null;const _0x48e83d=CLI_BIN_NAME+_0x3079a4(0x1d5);return await writeUpdateNoticeCache({..._0x47450c,'checkedAt':isFreshCheck(_0x47450c,_0x3c1f84)?_0x47450c[_0x3079a4(0x1c3)]:_0x3c1f84,'latest':_0x4a488e,'failed':![],'lastNotifiedVersion':_0x4a488e,'lastNotifiedAt':_0x3c1f84}),{'command':_0x48e83d,'current':_0x4e9144,'latest':_0x4a488e,'url':buildNpmVersionUrl(_0x4a488e),'message':CLI_BIN_NAME+'\x20'+_0x4a488e+'\x20available,\x20current\x20'+_0x4e9144+_0x3079a4(0x1c9)+_0x48e83d};}catch{return null;}}
1
+ (function(_0x3a12c,_0x3d3624){const _0x377a66=a204_0x56a7,_0x4c0e5e=_0x3a12c();while(!![]){try{const _0x23cbdc=-parseInt(_0x377a66(0x1bf))/0x1*(parseInt(_0x377a66(0x1d3))/0x2)+-parseInt(_0x377a66(0x1c1))/0x3*(parseInt(_0x377a66(0x1ca))/0x4)+-parseInt(_0x377a66(0x1d5))/0x5+-parseInt(_0x377a66(0x1d8))/0x6+parseInt(_0x377a66(0x1be))/0x7+-parseInt(_0x377a66(0x1d9))/0x8*(-parseInt(_0x377a66(0x1d1))/0x9)+parseInt(_0x377a66(0x1de))/0xa;if(_0x23cbdc===_0x3d3624)break;else _0x4c0e5e['push'](_0x4c0e5e['shift']());}catch(_0x1b1bf2){_0x4c0e5e['push'](_0x4c0e5e['shift']());}}}(a204_0x746f,0x66a49));import{mkdir,readFile,writeFile}from'node:fs/promises';function a204_0x746f(){const _0x49ec76=['stringify','valid','trim','526203AoYAjv','https://registry.npmjs.org/-/package/','2XtdgHr','timeout','152835bvxvUl','number','parse','1557684GSQyqR','104OEiLJt','entries','toLowerCase','length','\x20available,\x20current\x20','4247130QqMdle','fromEntries','lastNotifiedVersion','1336188ORiJgp','550756fHrDEa','string','57153AuRhDm','latest','object','yes','lastNotifiedAt','/v/','utf8','checkedAt','map','24wbpAFu','update-check.json','now','rabetbase-cli'];a204_0x746f=function(){return _0x49ec76;};return a204_0x746f();}import{homedir}from'node:os';import{dirname,join}from'node:path';import a204_0x59ef9a from'semver';import{CLI_BIN_NAME,NPM_PACKAGE_NAME}from'../constant/cli.js';import{getCliVersion}from'../utils/version.js';const UPDATE_CHECK_TTL_MS=0xc*0x3c*0x3c*0x3e8,UPDATE_NOTICE_TTL_MS=0x18*0x3c*0x3c*0x3e8;function isUpdateNoticeDisabled(){const _0x316bee=a204_0x56a7,_0x5a533d=process.env.RABETBASE_NO_UPDATE_NOTICE?.[_0x316bee(0x1d0)]()[_0x316bee(0x1db)]();return _0x5a533d==='1'||_0x5a533d==='true'||_0x5a533d===_0x316bee(0x1c4);}function cacheRoot(){return process.env.XDG_CACHE_HOME||process.env.LOCALAPPDATA||join(homedir(),'.cache');}export function getUpdateNoticeCachePath(){const _0xc0ea62=a204_0x56a7;return join(cacheRoot(),_0xc0ea62(0x1cd),_0xc0ea62(0x1cb));}async function readUpdateNoticeCache(){const _0x150fa6=a204_0x56a7;try{const _0x3ff4f7=await readFile(getUpdateNoticeCachePath(),_0x150fa6(0x1c7)),_0x520244=JSON[_0x150fa6(0x1d7)](_0x3ff4f7);if(!_0x520244||typeof _0x520244!=='object')return{};return _0x520244;}catch{return{};}}function a204_0x56a7(_0xa22a6a,_0x2b7d82){_0xa22a6a=_0xa22a6a-0x1be;const _0x746ff5=a204_0x746f();let _0x56a7b9=_0x746ff5[_0xa22a6a];return _0x56a7b9;}async function writeUpdateNoticeCache(_0x2e9ddc){const _0x5c7dae=a204_0x56a7;try{const _0x4b5a66=getUpdateNoticeCachePath();await mkdir(dirname(_0x4b5a66),{'recursive':!![]}),await writeFile(_0x4b5a66,JSON[_0x5c7dae(0x1ce)](_0x2e9ddc,null,0x2)+'\x0a',_0x5c7dae(0x1c7));}catch{}}function isFreshCheck(_0x52ffc9,_0x3517e7){const _0x1d8956=a204_0x56a7;return typeof _0x52ffc9['checkedAt']==='number'&&_0x3517e7-_0x52ffc9[_0x1d8956(0x1c8)]<UPDATE_CHECK_TTL_MS;}function isRecentlyNotified(_0xbb26f,_0x125564,_0x25be1f){const _0x5c7ee3=a204_0x56a7;return _0xbb26f[_0x5c7ee3(0x1e0)]===_0x125564&&typeof _0xbb26f[_0x5c7ee3(0x1c5)]===_0x5c7ee3(0x1d6)&&_0x25be1f-_0xbb26f[_0x5c7ee3(0x1c5)]<UPDATE_NOTICE_TTL_MS;}async function fetchNpmDistTags(_0x284612=0x5dc){const _0x17f895=a204_0x56a7;try{const _0x40fffe=await fetch(_0x17f895(0x1d2)+encodeURIComponent(NPM_PACKAGE_NAME)+'/dist-tags',{'signal':AbortSignal[_0x17f895(0x1d4)](_0x284612)});if(!_0x40fffe['ok'])return null;const _0x2c7469=await _0x40fffe['json']();if(!_0x2c7469||typeof _0x2c7469!==_0x17f895(0x1c3))return null;return Object[_0x17f895(0x1df)](Object[_0x17f895(0x1da)](_0x2c7469)['filter'](([,_0x5b5628])=>typeof _0x5b5628===_0x17f895(0x1c0)&&_0x5b5628[_0x17f895(0x1d0)]()[_0x17f895(0x1dc)]>0x0)[_0x17f895(0x1c9)](([_0x2ad214,_0x382ce5])=>[_0x2ad214,String(_0x382ce5)[_0x17f895(0x1d0)]()]));}catch{return null;}}export function buildNpmVersionUrl(_0x14acd2){const _0x3742e3=a204_0x56a7;return'https://www.npmjs.com/package/'+NPM_PACKAGE_NAME+_0x3742e3(0x1c6)+_0x14acd2;}export async function resolveLatestUpdateNotice(){const _0x2f7131=a204_0x56a7;if(isUpdateNoticeDisabled())return null;try{const _0x416f2f=Date[_0x2f7131(0x1cc)](),_0x4e1007=getCliVersion(),_0x65ee09=await readUpdateNoticeCache();let _0x5347e0=isFreshCheck(_0x65ee09,_0x416f2f)?_0x65ee09[_0x2f7131(0x1c2)]?.[_0x2f7131(0x1d0)]():undefined;if(!_0x5347e0&&!isFreshCheck(_0x65ee09,_0x416f2f)){const _0x3fbc22=await fetchNpmDistTags();_0x5347e0=_0x3fbc22?.['latest']?.[_0x2f7131(0x1d0)](),await writeUpdateNoticeCache({..._0x65ee09,'checkedAt':_0x416f2f,'latest':_0x5347e0,'failed':!_0x5347e0});}if(!_0x5347e0||!a204_0x59ef9a[_0x2f7131(0x1cf)](_0x4e1007)||!a204_0x59ef9a[_0x2f7131(0x1cf)](_0x5347e0))return null;if(a204_0x59ef9a['gte'](_0x4e1007,_0x5347e0))return null;if(isRecentlyNotified(_0x65ee09,_0x5347e0,_0x416f2f))return null;const _0xbb4000=CLI_BIN_NAME+'\x20update';return await writeUpdateNoticeCache({..._0x65ee09,'checkedAt':isFreshCheck(_0x65ee09,_0x416f2f)?_0x65ee09[_0x2f7131(0x1c8)]:_0x416f2f,'latest':_0x5347e0,'failed':![],'lastNotifiedVersion':_0x5347e0,'lastNotifiedAt':_0x416f2f}),{'command':_0xbb4000,'current':_0x4e1007,'latest':_0x5347e0,'url':buildNpmVersionUrl(_0x5347e0),'message':CLI_BIN_NAME+'\x20'+_0x5347e0+_0x2f7131(0x1dd)+_0x4e1007+',\x20run:\x20'+_0xbb4000};}catch{return null;}}
@@ -1 +1 @@
1
- function a205_0x50cd(){var _0x9818a5=['3JEvdmN','153491YMzTgr','225635EzizDs','827972icJDEW','1406490HgMQKB','22922dKAgDC','119700ksXQLC','80oprQaT','4527639QUhTfU'];a205_0x50cd=function(){return _0x9818a5;};return a205_0x50cd();}(function(_0x4ea57a,_0x4e9cf5){var _0x10b8c4=a205_0x34a9,_0x259319=_0x4ea57a();while(!![]){try{var _0xb60d51=-parseInt(_0x10b8c4(0xa4))/0x1+parseInt(_0x10b8c4(0x9f))/0x2+-parseInt(_0x10b8c4(0xa3))/0x3*(-parseInt(_0x10b8c4(0xa6))/0x4)+-parseInt(_0x10b8c4(0xa5))/0x5+-parseInt(_0x10b8c4(0x9e))/0x6+parseInt(_0x10b8c4(0xa0))/0x7*(-parseInt(_0x10b8c4(0xa1))/0x8)+parseInt(_0x10b8c4(0xa2))/0x9;if(_0xb60d51===_0x4e9cf5)break;else _0x259319['push'](_0x259319['shift']());}catch(_0x4c062f){_0x259319['push'](_0x259319['shift']());}}}(a205_0x50cd,0x1caf4));import{VERSION}from'../generated/build-info.js';function a205_0x34a9(_0x292a80,_0xa494d){_0x292a80=_0x292a80-0x9e;var _0x50cd0b=a205_0x50cd();var _0x34a973=_0x50cd0b[_0x292a80];return _0x34a973;}export function getCliVersion(){return VERSION;}
1
+ function a205_0x22d4(_0x13eaad,_0x3b5782){_0x13eaad=_0x13eaad-0x180;var _0x2cd435=a205_0x2cd4();var _0x22d4da=_0x2cd435[_0x13eaad];return _0x22d4da;}(function(_0x5dce55,_0x45bded){var _0x132c83=a205_0x22d4,_0x25f749=_0x5dce55();while(!![]){try{var _0x599728=-parseInt(_0x132c83(0x183))/0x1+-parseInt(_0x132c83(0x184))/0x2*(parseInt(_0x132c83(0x18a))/0x3)+-parseInt(_0x132c83(0x181))/0x4+parseInt(_0x132c83(0x189))/0x5*(-parseInt(_0x132c83(0x186))/0x6)+parseInt(_0x132c83(0x185))/0x7*(parseInt(_0x132c83(0x188))/0x8)+parseInt(_0x132c83(0x187))/0x9+-parseInt(_0x132c83(0x180))/0xa*(-parseInt(_0x132c83(0x182))/0xb);if(_0x599728===_0x45bded)break;else _0x25f749['push'](_0x25f749['shift']());}catch(_0xf76e7){_0x25f749['push'](_0x25f749['shift']());}}}(a205_0x2cd4,0x233d1));import{VERSION}from'../generated/build-info.js';export function getCliVersion(){return VERSION;}function a205_0x2cd4(){var _0x275084=['266bLBAqQ','12ogAPzu','292941TxTPPw','5896FrzvCk','595610tNqnWs','15vhitew','153370vwHvmp','16336xNeNhp','407vosuNS','85889fpIRBF','62188hyqgSe'];a205_0x2cd4=function(){return _0x275084;};return a205_0x2cd4();}
@@ -1 +1 @@
1
- (function(_0x4735f2,_0xe06067){var _0x31f172=a206_0x1118,_0x5daa7b=_0x4735f2();while(!![]){try{var _0x3d0ce8=parseInt(_0x31f172(0x1de))/0x1+parseInt(_0x31f172(0x1d9))/0x2+-parseInt(_0x31f172(0x1da))/0x3+-parseInt(_0x31f172(0x1d8))/0x4+parseInt(_0x31f172(0x1df))/0x5+-parseInt(_0x31f172(0x1dd))/0x6*(-parseInt(_0x31f172(0x1db))/0x7)+-parseInt(_0x31f172(0x1d7))/0x8*(parseInt(_0x31f172(0x1dc))/0x9);if(_0x3d0ce8===_0xe06067)break;else _0x5daa7b['push'](_0x5daa7b['shift']());}catch(_0x5eee2e){_0x5daa7b['push'](_0x5daa7b['shift']());}}}(a206_0x5386,0x34ff0));function a206_0x5386(){var _0x2b3aa1=['736779euQDUe','52024DFhAcg','1071261lSKPKe','288bVJTms','420982tqdEyP','200100TMgnAA','40SKwgng','236616DmwtxD','598452kNdjWj'];a206_0x5386=function(){return _0x2b3aa1;};return a206_0x5386();}function a206_0x1118(_0x3004d2,_0x265389){_0x3004d2=_0x3004d2-0x1d7;var _0x53869d=a206_0x5386();var _0x1118ba=_0x53869d[_0x3004d2];return _0x1118ba;}import{setActiveCookie,clearActiveCookie}from'../core/api-client.js';export async function withActiveCookie(_0xa53500,_0x49ce4a){setActiveCookie(_0xa53500);try{return await _0x49ce4a();}finally{clearActiveCookie();}}
1
+ (function(_0x3e1c6e,_0x3fb922){var _0x445ca7=a206_0x2727,_0x2381ec=_0x3e1c6e();while(!![]){try{var _0x3c22de=parseInt(_0x445ca7(0xee))/0x1+-parseInt(_0x445ca7(0xf0))/0x2+parseInt(_0x445ca7(0xf4))/0x3+parseInt(_0x445ca7(0xf5))/0x4*(-parseInt(_0x445ca7(0xef))/0x5)+-parseInt(_0x445ca7(0xf3))/0x6*(parseInt(_0x445ca7(0xed))/0x7)+parseInt(_0x445ca7(0xf2))/0x8+parseInt(_0x445ca7(0xf1))/0x9;if(_0x3c22de===_0x3fb922)break;else _0x2381ec['push'](_0x2381ec['shift']());}catch(_0x214d96){_0x2381ec['push'](_0x2381ec['shift']());}}}(a206_0x275c,0x54ce8));function a206_0x2727(_0x2789b2,_0xa06e2f){_0x2789b2=_0x2789b2-0xed;var _0x275c5c=a206_0x275c();var _0x272719=_0x275c5c[_0x2789b2];return _0x272719;}function a206_0x275c(){var _0x355063=['415008KHlieY','2585295kdCRYo','991592rIjFga','361254dkUPOB','952578TsCgly','4YzrxFv','14ivkJNf','297934NScGZa','1756870ZoeuiD'];a206_0x275c=function(){return _0x355063;};return a206_0x275c();}import{setActiveCookie,clearActiveCookie}from'../core/api-client.js';export async function withActiveCookie(_0x33723b,_0x587de7){setActiveCookie(_0x33723b);try{return await _0x587de7();}finally{clearActiveCookie();}}
@@ -1 +1 @@
1
- function a207_0x40a3(_0x445eec,_0x2e232a){_0x445eec=_0x445eec-0x1e3;var _0xb68199=a207_0xb681();var _0x40a37d=_0xb68199[_0x445eec];return _0x40a37d;}(function(_0x4be667,_0x270857){var _0x37724d=a207_0x40a3,_0x28dd9b=_0x4be667();while(!![]){try{var _0x47314e=-parseInt(_0x37724d(0x1ee))/0x1*(parseInt(_0x37724d(0x1eb))/0x2)+parseInt(_0x37724d(0x1ea))/0x3+parseInt(_0x37724d(0x1ed))/0x4*(-parseInt(_0x37724d(0x1e7))/0x5)+parseInt(_0x37724d(0x1ec))/0x6+parseInt(_0x37724d(0x1e8))/0x7+parseInt(_0x37724d(0x1e4))/0x8+-parseInt(_0x37724d(0x1e5))/0x9*(-parseInt(_0x37724d(0x1e9))/0xa);if(_0x47314e===_0x270857)break;else _0x28dd9b['push'](_0x28dd9b['shift']());}catch(_0x36fe17){_0x28dd9b['push'](_0x28dd9b['shift']());}}}(a207_0xb681,0x328a6));export function writeCliSideChannelLine(_0x5dfc90){var _0x2b48f1=a207_0x40a3;process[_0x2b48f1(0x1e6)][_0x2b48f1(0x1e3)](_0x5dfc90+'\x0a');}function a207_0xb681(){var _0x60c141=['492YisXfX','165fYqxXU','write','601976TtwVLn','5682834Utnnii','stderr','14555lYQqXB','278887UaOjpC','10KbTKaG','55293tsHWAo','4014MMfkBf','787662YhOPIJ'];a207_0xb681=function(){return _0x60c141;};return a207_0xb681();}
1
+ function a207_0xb925(_0x31ba9a,_0x2603f6){_0x31ba9a=_0x31ba9a-0xfa;var _0x3305b5=a207_0x3305();var _0xb925b1=_0x3305b5[_0x31ba9a];return _0xb925b1;}function a207_0x3305(){var _0x35b9a9=['9PDjOTT','2110NgYTSj','45727lomdUd','752096AobEEq','258wnKclu','9GnxiuL','3794UVufyX','1294885DOKDuO','5894756flElEY','5119512YWQKZJ','stderr','write','378304fVRBrW'];a207_0x3305=function(){return _0x35b9a9;};return a207_0x3305();}(function(_0x162f66,_0x19a766){var _0xfa7a90=a207_0xb925,_0x318d7f=_0x162f66();while(!![]){try{var _0x48bf61=parseInt(_0xfa7a90(0xfe))/0x1*(-parseInt(_0xfa7a90(0xfc))/0x2)+parseInt(_0xfa7a90(0xfd))/0x3*(parseInt(_0xfa7a90(0xfb))/0x4)+-parseInt(_0xfa7a90(0xff))/0x5+parseInt(_0xfa7a90(0x101))/0x6+parseInt(_0xfa7a90(0x100))/0x7+-parseInt(_0xfa7a90(0x104))/0x8*(parseInt(_0xfa7a90(0x105))/0x9)+-parseInt(_0xfa7a90(0x106))/0xa*(parseInt(_0xfa7a90(0xfa))/0xb);if(_0x48bf61===_0x19a766)break;else _0x318d7f['push'](_0x318d7f['shift']());}catch(_0x4f7ac0){_0x318d7f['push'](_0x318d7f['shift']());}}}(a207_0x3305,0x8f376));export function writeCliSideChannelLine(_0x53e2a3){var _0x423ba8=a207_0xb925;process[_0x423ba8(0x102)][_0x423ba8(0x103)](_0x53e2a3+'\x0a');}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lovrabet/rabetbase-cli",
3
- "version": "2.2.1-beta.1",
3
+ "version": "2.2.1",
4
4
  "license": "SEE LICENSE IN LICENSE",
5
5
  "repository": {
6
6
  "type": "git",