@lovrabet/rabetbase-cli 2.0.4-beta.5 → 2.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/api/api-doc.js +1 -1
- package/lib/api/fetch-model-list.js +1 -1
- package/lib/api/generate-api-file.js +1 -1
- package/lib/auth/auth-server-ui.js +1 -1
- package/lib/auth/auth-server.js +1 -1
- package/lib/auth/constant.js +1 -1
- package/lib/auth/get-cookie.js +1 -1
- package/lib/auth/get-session-user.js +1 -1
- package/lib/auth/is-session-valid.js +1 -1
- package/lib/auth/logout.js +1 -1
- package/lib/cli-flags.js +1 -1
- package/lib/cli.js +1 -1
- package/lib/commands/api/doc.js +1 -1
- package/lib/commands/api/index.js +1 -1
- package/lib/commands/api/list.js +1 -1
- package/lib/commands/api/pull.js +1 -1
- package/lib/commands/api/shared.js +1 -1
- package/lib/commands/app/add.js +1 -1
- package/lib/commands/app/index.js +1 -1
- package/lib/commands/app/list.js +1 -1
- package/lib/commands/app/remote.js +1 -1
- package/lib/commands/app/remove.js +1 -1
- package/lib/commands/app/shared.js +1 -1
- package/lib/commands/app/use.js +1 -1
- package/lib/commands/auth/index.js +1 -1
- package/lib/commands/bff/delete.js +1 -1
- package/lib/commands/bff/detail.js +1 -1
- package/lib/commands/bff/index.js +1 -1
- package/lib/commands/bff/list.js +1 -1
- package/lib/commands/bff/new.js +1 -1
- package/lib/commands/bff/pull.js +1 -1
- package/lib/commands/bff/push.js +1 -1
- package/lib/commands/bff/status.js +1 -1
- package/lib/commands/build.js +1 -1
- package/lib/commands/cli-update.js +1 -1
- package/lib/commands/codegen/index.js +1 -1
- package/lib/commands/codegen/sdk.js +1 -1
- package/lib/commands/codegen/sql.js +1 -1
- package/lib/commands/common/app-selector.js +1 -1
- package/lib/commands/common/flags.js +1 -1
- package/lib/commands/common/validate.js +1 -1
- package/lib/commands/config/get.js +1 -1
- package/lib/commands/config/index.js +1 -1
- package/lib/commands/config/list.js +1 -1
- package/lib/commands/config/set.js +1 -1
- package/lib/commands/config/shared.js +1 -1
- package/lib/commands/dataset/detail.js +1 -1
- package/lib/commands/dataset/index.js +1 -1
- package/lib/commands/dataset/links.js +1 -1
- package/lib/commands/dataset/list.js +1 -1
- package/lib/commands/dataset/operations.js +1 -1
- package/lib/commands/doctor.js +1 -1
- package/lib/commands/init/index.js +1 -1
- package/lib/commands/logs/index.js +1 -1
- package/lib/commands/menu/index.js +1 -1
- package/lib/commands/menu/shared/compare-table.js +1 -1
- package/lib/commands/menu/shared/index.js +1 -1
- package/lib/commands/menu/shared/inquirer.js +1 -1
- package/lib/commands/menu/shared/local-pages.js +1 -1
- package/lib/commands/menu/shared/logic.js +1 -1
- package/lib/commands/menu/shared/service.js +1 -1
- package/lib/commands/menu/shared/sync-core.js +1 -1
- package/lib/commands/menu/shared/update-core.js +1 -1
- package/lib/commands/menu/shared/valid-url.js +1 -1
- package/lib/commands/menu/sync.js +1 -1
- package/lib/commands/menu/update.js +1 -1
- package/lib/commands/preview.js +1 -1
- package/lib/commands/project/index.js +1 -1
- package/lib/commands/project-upgrade.js +1 -1
- package/lib/commands/registry.js +1 -1
- package/lib/commands/run/index.js +1 -1
- package/lib/commands/skill/index.js +1 -1
- package/lib/commands/sql/detail.js +1 -1
- package/lib/commands/sql/exec.js +1 -1
- package/lib/commands/sql/index.js +1 -1
- package/lib/commands/sql/list.js +1 -1
- package/lib/commands/sql/save.js +1 -1
- package/lib/commands/sql/validate.js +1 -1
- package/lib/commands/start.js +1 -1
- package/lib/constant/cli.js +1 -1
- package/lib/constant/domain.js +1 -1
- package/lib/constant/env.js +1 -1
- package/lib/context.js +1 -1
- package/lib/core/alias-resolver.js +1 -1
- package/lib/core/api-client.js +1 -1
- package/lib/core/bff/config.js +1 -1
- package/lib/core/bff/file-system.js +1 -1
- package/lib/core/bff/hash.js +1 -1
- package/lib/core/bff/lock.js +1 -1
- package/lib/core/bff/utils.js +1 -1
- package/lib/core/db-resolver.js +1 -1
- package/lib/core/sql-validator.js +1 -1
- package/lib/create-app/enhanced-guided-create.js +1 -1
- package/lib/create-app/format-elapsed.js +1 -1
- package/lib/create-app/main.js +1 -1
- package/lib/create-app/non-interactive.js +1 -1
- package/lib/create-app/use-copy-project-template.js +1 -1
- package/lib/create-app/use-format-code.js +1 -1
- package/lib/create-app/use-install-dependencies.js +1 -1
- package/lib/errors.js +1 -1
- package/lib/framework/flags.js +1 -1
- package/lib/framework/help.js +1 -1
- package/lib/framework/index.js +1 -1
- package/lib/framework/output.js +1 -1
- package/lib/framework/response.js +1 -1
- package/lib/framework/runner.js +1 -1
- package/lib/framework/types.js +1 -1
- package/lib/generated/build-info.js +1 -1
- package/lib/help.js +1 -1
- package/lib/init/main.js +1 -1
- package/lib/skills/main.js +1 -1
- package/lib/skills/npx-skills-add.js +1 -1
- package/lib/telemetry/cli-command-trace.js +1 -1
- package/lib/telemetry/cli-help-trace.js +1 -1
- package/lib/telemetry/ensure-cli-otel-config.js +1 -1
- package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
- package/lib/telemetry/send-cli-trace-log.js +1 -1
- package/lib/utils/ai_config.js +1 -1
- package/lib/utils/cdn-config.js +1 -1
- package/lib/utils/check-sdk-version.js +1 -1
- package/lib/utils/cli-version-check.js +1 -1
- package/lib/utils/config.js +1 -1
- package/lib/utils/copy-directory.js +1 -1
- package/lib/utils/file-utils.js +1 -1
- package/lib/utils/guides-cdn.js +1 -1
- package/lib/utils/http-client.js +1 -1
- package/lib/utils/is-non-interactive.js +1 -1
- package/lib/utils/logger.js +1 -1
- package/lib/utils/platform.js +1 -1
- package/lib/utils/rules-cdn.js +1 -1
- package/lib/utils/sleep.js +1 -1
- package/lib/utils/template-replacer.js +1 -1
- package/lib/utils/version.js +1 -1
- package/lib/utils/with-active-cookie.js +1 -1
- package/package.json +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x9c407f,_0x431792){const _0x46e6b9=a116_0x252c,_0x3d58af=_0x9c407f();while(!![]){try{const _0x59390b=parseInt(_0x46e6b9(0x86))/0x1+-parseInt(_0x46e6b9(0x94))/0x2*(parseInt(_0x46e6b9(0x85))/0x3)+parseInt(_0x46e6b9(0x8b))/0x4*(-parseInt(_0x46e6b9(0x8d))/0x5)+parseInt(_0x46e6b9(0x90))/0x6*(parseInt(_0x46e6b9(0x8c))/0x7)+-parseInt(_0x46e6b9(0x87))/0x8+-parseInt(_0x46e6b9(0x84))/0x9+-parseInt(_0x46e6b9(0x88))/0xa*(-parseInt(_0x46e6b9(0x93))/0xb);if(_0x59390b===_0x431792)break;else _0x3d58af['push'](_0x3d58af['shift']());}catch(_0x1f06ee){_0x3d58af['push'](_0x3d58af['shift']());}}}(a116_0x13e5,0x52a07));import a116_0x1a0810 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';function a116_0x13e5(){const _0x3a22ad=['475310CunheN','4597760ZyhtXQ','2764590wqfYfx','nickname','userInfo','4PGWqvU','56tVKTkV','1750635AWBvCV','production','daily','478236ChaLaw','username','unknown','22AyCfjG','2xwgKgq','1613745OUlAwg','669855mWJPTr'];a116_0x13e5=function(){return _0x3a22ad;};return a116_0x13e5();}let cliOtelTraceInitialized=![];function a116_0x252c(_0x331a58,_0x465e26){_0x331a58=_0x331a58-0x84;const _0x13e5bc=a116_0x13e5();let _0x252c4e=_0x13e5bc[_0x331a58];return _0x252c4e;}export async function ensureCliOtelTraceConfig(){const _0x16bef6=a116_0x252c,_0x34ea44=await getSessionUserInfo();if(!cliOtelTraceInitialized){const _0x17b49b=_0x34ea44?.['user'];setTraceConfig({'otelLoggerVersion':getOtelLoggerVersion(),'serviceName':NPM_PACKAGE_NAME,'serviceVersion':GIT_COMMIT!==_0x16bef6(0x92)?VERSION+'+'+GIT_COMMIT:VERSION,'serviceEnv':process.env.RABETBASE_ENV??(process.env.RABETBASE_E2E_DAILY==='1'?_0x16bef6(0x8f):_0x16bef6(0x8e)),'username':_0x17b49b?.[_0x16bef6(0x91)]??a116_0x1a0810[_0x16bef6(0x8a)]()[_0x16bef6(0x91)]??'rabetbase-cli',..._0x17b49b&&{'nickname':_0x17b49b[_0x16bef6(0x89)]}}),cliOtelTraceInitialized=!![];}return _0x34ea44;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x5c7ca1,_0x1060d5){const _0x6d3bfa=a117_0x2f06,_0x8592e5=_0x5c7ca1();while(!![]){try{const _0x53d78d=-parseInt(_0x6d3bfa(0x1bb))/0x1+parseInt(_0x6d3bfa(0x1b0))/0x2+parseInt(_0x6d3bfa(0x1bd))/0x3+-parseInt(_0x6d3bfa(0x1b8))/0x4*(-parseInt(_0x6d3bfa(0x1bc))/0x5)+parseInt(_0x6d3bfa(0x1b5))/0x6*(-parseInt(_0x6d3bfa(0x1ba))/0x7)+-parseInt(_0x6d3bfa(0x1b1))/0x8+parseInt(_0x6d3bfa(0x1b4))/0x9;if(_0x53d78d===_0x1060d5)break;else _0x8592e5['push'](_0x8592e5['shift']());}catch(_0x122f32){_0x8592e5['push'](_0x8592e5['shift']());}}}(a117_0x2578,0x82893));import{shutdownTraces}from'@lovrabet/otel-logger';function a117_0x2f06(_0x17a003,_0x139a4e){_0x17a003=_0x17a003-0x1b0;const _0x257847=a117_0x2578();let _0x2f0689=_0x257847[_0x17a003];return _0x2f0689;}let shutdownPromise=null;export async function flushOtelNodeIfUsed(){if(shutdownPromise)return shutdownPromise;return shutdownPromise=((async()=>{try{await shutdownTraces();}catch{}})()),shutdownPromise;}export function registerOtelShutdownOnExit(){const _0xc11828=a117_0x2f06;process[_0xc11828(0x1b9)](_0xc11828(0x1be),()=>{void flushOtelNodeIfUsed();});const _0x498af2=()=>{const _0x2d9c4d=_0xc11828;void flushOtelNodeIfUsed()[_0x2d9c4d(0x1b2)](()=>process[_0x2d9c4d(0x1b3)](0x0));};process[_0xc11828(0x1b9)](_0xc11828(0x1b7),_0x498af2),process[_0xc11828(0x1b9)](_0xc11828(0x1b6),_0x498af2);}function a117_0x2578(){const _0xb2fff=['602700EBsqSt','155fMSNNl','367875HyKZST','beforeExit','1584212deXLNX','2595000BBWYgU','then','exit','7475517NzgBBd','4384242bbStkf','SIGTERM','SIGINT','57692TygDeP','once','7wGlFdI'];a117_0x2578=function(){return _0xb2fff;};return a117_0x2578();}export async function exitWithOtelShutdown(_0x560a37){await flushOtelNodeIfUsed(),process['exit'](_0x560a37);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a118_0x3932a7=a118_0x153f;(function(_0x136a43,_0x4ab27a){const _0x41f46a=a118_0x153f,_0x584559=_0x136a43();while(!![]){try{const _0x52436f=parseInt(_0x41f46a(0x179))/0x1*(-parseInt(_0x41f46a(0x178))/0x2)+-parseInt(_0x41f46a(0x17a))/0x3*(-parseInt(_0x41f46a(0x180))/0x4)+parseInt(_0x41f46a(0x17e))/0x5*(parseInt(_0x41f46a(0x17b))/0x6)+parseInt(_0x41f46a(0x182))/0x7+parseInt(_0x41f46a(0x176))/0x8+-parseInt(_0x41f46a(0x185))/0x9*(parseInt(_0x41f46a(0x17d))/0xa)+-parseInt(_0x41f46a(0x184))/0xb;if(_0x52436f===_0x4ab27a)break;else _0x584559['push'](_0x584559['shift']());}catch(_0x3baea2){_0x584559['push'](_0x584559['shift']());}}}(a118_0x1619,0xa5c1f));function a118_0x1619(){const _0x22839b=['rabetbase-cli','88684EpWvcc','traceparent','5776708hDmaZL','spanName','9074890QfauNb','40257HKQgmN','logData','1057744wzHntA','traceName','10hkNchI','74199xmCZjg','135oFZryI','2508KrbEhW','manual','370KUKYTK','1020ikFvsD'];a118_0x1619=function(){return _0x22839b;};return a118_0x1619();}import{sendTraceLog}from'@lovrabet/otel-logger';import{ensureCliOtelTraceConfig}from'./ensure-cli-otel-config.js';import{getCliVersion}from'../utils/version.js';function a118_0x153f(_0x42113a,_0x31891e){_0x42113a=_0x42113a-0x175;const _0x16191a=a118_0x1619();let _0x153f5c=_0x16191a[_0x42113a];return _0x153f5c;}const DEFAULT_TRACE_NAME=a118_0x3932a7(0x17f);export async function sendCliTraceLog(_0x17901c){const _0x1afa92=a118_0x3932a7;await ensureCliOtelTraceConfig(),sendTraceLog({'traceName':_0x17901c[_0x1afa92(0x177)]??DEFAULT_TRACE_NAME,'version':_0x17901c['version']??getCliVersion(),'spanName':_0x17901c[_0x1afa92(0x183)],'eventType':_0x1afa92(0x17c),'logData':_0x17901c[_0x1afa92(0x175)],..._0x17901c[_0x1afa92(0x181)]&&{'traceparent':_0x17901c[_0x1afa92(0x181)]}});}
|
package/lib/utils/ai_config.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a120_0x2f42ae=a120_0xa277;function a120_0xc8a0(){const _0xcadfc7=['CodeBuddy\x20IDE','cursor','opencode','.cursor','Codex\x20IDE','.opencode/skills/lovrabet/SKILL.md','antigravity','trae','.agent','2622684SaeoYz','Windsurf\x20IDE','Windsurf','SKILL.md.tpl','Cline','.qoder','152rDqnPe','Cline\x20IDE','5PpydRp','OpenCode\x20IDE','Qoder\x20IDE','.codex/skills/lovrabet/SKILL.md','其他\x20(通用模板)','Claude\x20Code','9JuzvyI','153461HVMyQX','Trae\x20IDE','11191410vMtZYf','codex','qoder','.cursorrules','cline','.claude','claude','Codex','Trae','.windsurf','windsurf','.cursor/skills/rabetbase.md','.trae/skills/lovrabet/SKILL.md','agent','.opencode','.agent/skills/lovrabet/SKILL.md','57378ZAlUJM','712319hjaFvX','Antigravity\x20IDE','Qoder','file','1843720xlWGrO','Antigravity','codebuddy','.trae','OpenCode','.windsurf/workflows/rabetbase.md','.claude/skills/lovrabet/SKILL.md','.codebuddy/skills/lovrabet/SKILL.md','1060864TUkWIc'];a120_0xc8a0=function(){return _0xcadfc7;};return a120_0xc8a0();}(function(_0x17c3b8,_0x192aff){const _0x2c7b69=a120_0xa277,_0x56d18e=_0x17c3b8();while(!![]){try{const _0x20d0fa=parseInt(_0x2c7b69(0xaa))/0x1+-parseInt(_0x2c7b69(0x7e))/0x2+-parseInt(_0x2c7b69(0xa9))/0x3+parseInt(_0x2c7b69(0xae))/0x4*(parseInt(_0x2c7b69(0x90))/0x5)+parseInt(_0x2c7b69(0x88))/0x6+-parseInt(_0x2c7b69(0x97))/0x7*(-parseInt(_0x2c7b69(0x8e))/0x8)+parseInt(_0x2c7b69(0x96))/0x9*(-parseInt(_0x2c7b69(0x99))/0xa);if(_0x20d0fa===_0x192aff)break;else _0x56d18e['push'](_0x56d18e['shift']());}catch(_0x5c5949){_0x56d18e['push'](_0x56d18e['shift']());}}}(a120_0xc8a0,0x57739));function a120_0xa277(_0x2ce993,_0x400705){_0x2ce993=_0x2ce993-0x7b;const _0xc8a07d=a120_0xc8a0();let _0xa27798=_0xc8a07d[_0x2ce993];return _0xa27798;}export const CORE_IDE_CONFIGS={'cursor':{'name':'Cursor','description':'Cursor\x20IDE','folders':[a120_0x2f42ae(0x9c),a120_0x2f42ae(0x82)],'files':[{'type':a120_0x2f42ae(0xad),'path':a120_0x2f42ae(0xa4),'template':a120_0x2f42ae(0x8b)}]},'windsurf':{'name':a120_0x2f42ae(0x8a),'description':a120_0x2f42ae(0x89),'folders':[a120_0x2f42ae(0xa2)],'files':[{'type':a120_0x2f42ae(0xad),'path':a120_0x2f42ae(0x7b),'template':a120_0x2f42ae(0x8b)}]},'claude':{'name':'Claude\x20Code','description':a120_0x2f42ae(0x95),'folders':[a120_0x2f42ae(0x9e)],'files':[{'type':a120_0x2f42ae(0xad),'path':a120_0x2f42ae(0x7c),'template':'SKILL.md.tpl'}]},'cline':{'name':a120_0x2f42ae(0x8c),'description':a120_0x2f42ae(0x8f),'folders':['.cline'],'files':[{'type':a120_0x2f42ae(0xad),'path':'.cline/skills/lovrabet/SKILL.md','template':a120_0x2f42ae(0x8b)}]},'codex':{'name':a120_0x2f42ae(0xa0),'description':a120_0x2f42ae(0x83),'folders':['.codex'],'files':[{'type':'file','path':a120_0x2f42ae(0x93),'template':'SKILL.md.tpl'}]},'opencode':{'name':a120_0x2f42ae(0xb2),'description':a120_0x2f42ae(0x91),'folders':[a120_0x2f42ae(0xa7)],'files':[{'type':a120_0x2f42ae(0xad),'path':a120_0x2f42ae(0x84),'template':a120_0x2f42ae(0x8b)}]},'qoder':{'name':a120_0x2f42ae(0xac),'description':a120_0x2f42ae(0x92),'folders':[a120_0x2f42ae(0x8d)],'files':[{'type':a120_0x2f42ae(0xad),'path':'.qoder/rules/rabetbase.md','template':'SKILL.md.tpl'},{'type':'file','path':'.qoder/skills/lovrabet/SKILL.md','template':a120_0x2f42ae(0x8b)}]},'codebuddy':{'name':'CodeBuddy','description':a120_0x2f42ae(0x7f),'folders':['.codebuddy'],'files':[{'type':a120_0x2f42ae(0xad),'path':a120_0x2f42ae(0x7d),'template':a120_0x2f42ae(0x8b)}]},'trae':{'name':a120_0x2f42ae(0xa1),'description':a120_0x2f42ae(0x98),'folders':[a120_0x2f42ae(0xb1)],'files':[{'type':a120_0x2f42ae(0xad),'path':a120_0x2f42ae(0xa5),'template':a120_0x2f42ae(0x8b)}]}};export const IDE_CONFIGS={...CORE_IDE_CONFIGS,'agent':{'name':a120_0x2f42ae(0x94),'description':'通用模板\x20-\x20兜底方案','folders':[a120_0x2f42ae(0x87)],'files':[{'type':a120_0x2f42ae(0xad),'path':a120_0x2f42ae(0xa8),'template':'SKILL.md.tpl'}]},'antigravity':{'name':a120_0x2f42ae(0xaf),'description':a120_0x2f42ae(0xab),'folders':[a120_0x2f42ae(0x87)],'files':[{'type':'file','path':a120_0x2f42ae(0xa8),'template':'SKILL.md.tpl'}]}};export const CORE_IDE_LIST=[a120_0x2f42ae(0x9f),a120_0x2f42ae(0x9d),'codebuddy',a120_0x2f42ae(0x9a),a120_0x2f42ae(0x80),a120_0x2f42ae(0x81),a120_0x2f42ae(0x9b),a120_0x2f42ae(0x86),a120_0x2f42ae(0xa3)];export const IDE_LIST=[a120_0x2f42ae(0x85),a120_0x2f42ae(0x9f),a120_0x2f42ae(0x9d),a120_0x2f42ae(0xb0),a120_0x2f42ae(0x9a),a120_0x2f42ae(0x80),'opencode',a120_0x2f42ae(0x9b),a120_0x2f42ae(0x86),a120_0x2f42ae(0xa3),a120_0x2f42ae(0xa6)];export const ALL_CORE_IDES=[a120_0x2f42ae(0x80),a120_0x2f42ae(0xa3),a120_0x2f42ae(0x9f),'cline','codex',a120_0x2f42ae(0x81),'qoder','codebuddy',a120_0x2f42ae(0x86)];
|
package/lib/utils/cdn-config.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a121_0x5af7(_0x50462a,_0x3edcf4){_0x50462a=_0x50462a-0x1bd;const _0x18a415=a121_0x18a4();let _0x5af7d1=_0x18a415[_0x50462a];return _0x5af7d1;}(function(_0xa806d3,_0x16f633){const _0x219f0d=a121_0x5af7,_0x162f36=_0xa806d3();while(!![]){try{const _0x283495=-parseInt(_0x219f0d(0x1cb))/0x1*(parseInt(_0x219f0d(0x1c9))/0x2)+parseInt(_0x219f0d(0x1c8))/0x3*(parseInt(_0x219f0d(0x1c2))/0x4)+-parseInt(_0x219f0d(0x1bd))/0x5+parseInt(_0x219f0d(0x1c6))/0x6+parseInt(_0x219f0d(0x1c3))/0x7+parseInt(_0x219f0d(0x1c0))/0x8*(-parseInt(_0x219f0d(0x1c1))/0x9)+-parseInt(_0x219f0d(0x1c5))/0xa;if(_0x283495===_0x16f633)break;else _0x162f36['push'](_0x162f36['shift']());}catch(_0x3c4119){_0x162f36['push'](_0x162f36['shift']());}}}(a121_0x18a4,0xa4f33));import{getTemplateBaseUrl}from'./config.js';export async function fetchCdnConfig(){const _0x515eeb=a121_0x5af7;try{const _0x5af5da=getTemplateBaseUrl(),_0x3d1045=_0x5af5da+_0x515eeb(0x1be),_0xf4a6c4=await fetch(_0x3d1045,{'headers':{'Accept':_0x515eeb(0x1c4)}});if(!_0xf4a6c4['ok'])return null;const _0x156f76=await _0xf4a6c4[_0x515eeb(0x1cc)]();if(!_0x156f76['cli']?.[_0x515eeb(0x1cd)]||!_0x156f76[_0x515eeb(0x1c7)]?.[_0x515eeb(0x1bf)]?.['stableVersion'])return null;return _0x156f76;}catch{return null;}}let cachedConfig=null,cacheTime=0x0;const CACHE_TTL=0x5*0x3c*0x3e8;function a121_0x18a4(){const _0x11e793=['json','stableVersion','1037565GksrCw','/config.json','node','8wCnZft','7988121phuxka','478340jtlDTI','6469827gMlMne','application/json','11771370WaCfEc','7455870PxxcpA','sdk','24GFxUXf','87866zmvRPt','now','4jfYIEc'];a121_0x18a4=function(){return _0x11e793;};return a121_0x18a4();}export async function getCdnConfig(){const _0x518900=a121_0x5af7,_0x537fc1=Date[_0x518900(0x1ca)]();if(cachedConfig&&_0x537fc1-cacheTime<CACHE_TTL)return cachedConfig;const _0x3592db=await fetchCdnConfig();return _0x3592db&&(cachedConfig=_0x3592db,cacheTime=_0x537fc1),_0x3592db;}export function clearCdnConfigCache(){cachedConfig=null,cacheTime=0x0;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a122_0x4f59b5=a122_0xbd76;(function(_0x591478,_0x484039){const _0x2c80aa=a122_0xbd76,_0x2ae7aa=_0x591478();while(!![]){try{const _0x16a599=-parseInt(_0x2c80aa(0x1d5))/0x1+parseInt(_0x2c80aa(0x1f8))/0x2+parseInt(_0x2c80aa(0x1dd))/0x3*(-parseInt(_0x2c80aa(0x1ea))/0x4)+parseInt(_0x2c80aa(0x1e3))/0x5*(-parseInt(_0x2c80aa(0x1f6))/0x6)+-parseInt(_0x2c80aa(0x1f2))/0x7*(-parseInt(_0x2c80aa(0x1e1))/0x8)+-parseInt(_0x2c80aa(0x1dc))/0x9+parseInt(_0x2c80aa(0x1e5))/0xa*(parseInt(_0x2c80aa(0x1e9))/0xb);if(_0x16a599===_0x484039)break;else _0x2ae7aa['push'](_0x2ae7aa['shift']());}catch(_0x3add5e){_0x2ae7aa['push'](_0x2ae7aa['shift']());}}}(a122_0x5994,0x37e89));import a122_0x33e866 from'node:fs';function a122_0xbd76(_0x13faf1,_0x56e51c){_0x13faf1=_0x13faf1-0x1d4;const _0x5994c3=a122_0x5994();let _0xbd76d9=_0x5994c3[_0x13faf1];return _0xbd76d9;}import a122_0x3e2884 from'node:path';import a122_0x8b2845 from'semver';function a122_0x5994(){const _0x49e3ef=['all','dependencies','version','473ZTvgqK','8FTwJBa','stableVersion','latest','parse','log','@lovrabet/sdk','\x20\x20\x20Stable\x20version:\x20','npm\x20install\x20','1311478qQjSqS','↪\x20SDK\x20update\x20available','\x1b[33m','node_modules','45366JNsrCI','package.json','823744wBfbiC','readFileSync','425436YQsqqs','sdk','join','devDependencies','1.2.0','some','minVersion','2090691FTZyrA','278877qhNNds','packageName','test','\x20\x20\x20Upgrade\x20command:\x20','8jziemn','utf8','275JZmgPM','coerce','206810BRXSya'];a122_0x5994=function(){return _0x49e3ef;};return a122_0x5994();}import{getCdnConfig}from'./cdn-config.js';const FALLBACK_MIN_SDK_VERSION=a122_0x4f59b5(0x1d9);function isNonNumericVersion(_0x4d4210){const _0x4a47b6=a122_0x4f59b5,_0x2393b5=[/^latest$/i,/^beta$/i,/^alpha$/i,/^canary$/i,/^\*$/,/^x$/];return _0x2393b5[_0x4a47b6(0x1da)](_0x341eb0=>_0x341eb0[_0x4a47b6(0x1df)](_0x4d4210));}function getInstalledVersion(_0x426f30,_0x4c8226){const _0x2f6f4c=a122_0x4f59b5;try{const _0x55f8fe=a122_0x3e2884['join'](_0x426f30,_0x2f6f4c(0x1f5),_0x4c8226,_0x2f6f4c(0x1f7));if(a122_0x33e866['existsSync'](_0x55f8fe)){const _0x249fd2=JSON[_0x2f6f4c(0x1ed)](a122_0x33e866[_0x2f6f4c(0x1d4)](_0x55f8fe,'utf-8'));return _0x249fd2['version']||null;}}catch{}return null;}async function getSdkStableVersion(){const _0x2128b0=a122_0x4f59b5;try{const _0x470062=await getCdnConfig();return _0x470062?.[_0x2128b0(0x1d6)]?.['node']?.[_0x2128b0(0x1eb)]||null;}catch{return null;}}async function getSdkPackageName(){const _0x15944d=a122_0x4f59b5;try{const _0x4fc73a=await getCdnConfig();return _0x4fc73a?.[_0x15944d(0x1d6)]?.['node']?.[_0x15944d(0x1de)]||'@lovrabet/sdk';}catch{return _0x15944d(0x1ef);}}export async function checkSdkVersion(_0x383335){const _0x5a3690=a122_0x4f59b5,_0xbf0c3f=a122_0x3e2884[_0x5a3690(0x1d7)](_0x383335,_0x5a3690(0x1f7)),[_0x3595dd,_0x23550a]=await Promise[_0x5a3690(0x1e6)]([getSdkStableVersion(),getSdkPackageName()]),_0x34a0b5=_0x3595dd||FALLBACK_MIN_SDK_VERSION;if(!a122_0x33e866['existsSync'](_0xbf0c3f))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x34a0b5,'packageName':_0x23550a,'stableVersion':_0x3595dd};try{const _0x48a524=JSON[_0x5a3690(0x1ed)](a122_0x33e866[_0x5a3690(0x1d4)](_0xbf0c3f,_0x5a3690(0x1e2))),_0x3efc0f=_0x48a524[_0x5a3690(0x1e7)]||{},_0x4aba2e=_0x48a524[_0x5a3690(0x1d8)]||{},_0xf0cfb5=_0x3efc0f[_0x23550a]||_0x4aba2e[_0x23550a];if(!_0xf0cfb5)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x34a0b5,'packageName':_0x23550a,'stableVersion':_0x3595dd};let _0x4f06c5=getInstalledVersion(_0x383335,_0x23550a);!_0x4f06c5&&(_0x4f06c5=_0xf0cfb5);if(isNonNumericVersion(_0xf0cfb5))return{'installed':!![],'version':_0x4f06c5,'needsUpgrade':![],'minVersion':_0x34a0b5,'packageName':_0x23550a,'stableVersion':_0x3595dd};const _0x909264=a122_0x8b2845[_0x5a3690(0x1e4)](_0x4f06c5),_0x20df32=a122_0x8b2845[_0x5a3690(0x1e4)](_0x34a0b5),_0x1e1395=_0x909264&&_0x20df32?a122_0x8b2845['lt'](_0x909264,_0x20df32):![];return{'installed':!![],'version':_0x4f06c5,'needsUpgrade':_0x1e1395,'minVersion':_0x34a0b5,'packageName':_0x23550a,'stableVersion':_0x3595dd};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':_0x34a0b5,'packageName':_0x23550a,'stableVersion':_0x3595dd};}}export function checkSdkVersionSync(_0x4298f4){const _0xe14e61=a122_0x4f59b5,_0x386f24=a122_0x3e2884[_0xe14e61(0x1d7)](_0x4298f4,_0xe14e61(0x1f7)),_0x18bdce=_0xe14e61(0x1ef);if(!a122_0x33e866['existsSync'](_0x386f24))return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x18bdce,'stableVersion':null};try{const _0x241fa2=JSON[_0xe14e61(0x1ed)](a122_0x33e866['readFileSync'](_0x386f24,_0xe14e61(0x1e2))),_0x3e192d=_0x241fa2[_0xe14e61(0x1e7)]||{},_0xc2beaa=_0x241fa2[_0xe14e61(0x1d8)]||{},_0x4d6429=_0x3e192d[_0x18bdce]||_0xc2beaa[_0x18bdce];if(!_0x4d6429)return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x18bdce,'stableVersion':null};let _0xd7ddaa=getInstalledVersion(_0x4298f4,_0x18bdce);!_0xd7ddaa&&(_0xd7ddaa=_0x4d6429);if(isNonNumericVersion(_0x4d6429))return{'installed':!![],'version':_0xd7ddaa,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x18bdce,'stableVersion':null};const _0x5c45ce=a122_0x8b2845[_0xe14e61(0x1e4)](_0xd7ddaa),_0x102ef4=_0x5c45ce?a122_0x8b2845['lt'](_0x5c45ce,FALLBACK_MIN_SDK_VERSION):![];return{'installed':!![],'version':_0xd7ddaa,'needsUpgrade':_0x102ef4,'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x18bdce,'stableVersion':null};}catch{return{'installed':![],'version':null,'needsUpgrade':![],'minVersion':FALLBACK_MIN_SDK_VERSION,'packageName':_0x18bdce,'stableVersion':null};}}export function printSdkUpgradeWarning(_0x198d1c){const _0x29a1a9=a122_0x4f59b5;if(!_0x198d1c['needsUpgrade'])return;const _0x31fe14=_0x29a1a9(0x1f4),_0x926696='\x1b[0m',_0x1e783f='\x1b[1m',_0x39b6f8=_0x198d1c['packageName']||_0x29a1a9(0x1ef),_0x113bdd=_0x198d1c['stableVersion']||_0x198d1c[_0x29a1a9(0x1db)],_0x15aee6=_0x29a1a9(0x1f1)+_0x39b6f8+'@'+(_0x113bdd||_0x29a1a9(0x1ec));console[_0x29a1a9(0x1ee)](),console[_0x29a1a9(0x1ee)](''+_0x31fe14+_0x1e783f+_0x29a1a9(0x1f3)+_0x926696),console['log'](_0x31fe14+'\x20\x20\x20Current\x20version:\x20'+_0x39b6f8+'@'+_0x198d1c[_0x29a1a9(0x1e8)]+_0x926696),console[_0x29a1a9(0x1ee)](_0x31fe14+_0x29a1a9(0x1f0)+_0x113bdd+_0x926696),console[_0x29a1a9(0x1ee)](_0x31fe14+_0x29a1a9(0x1e0)+_0x15aee6+_0x926696),console[_0x29a1a9(0x1ee)]();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4a915a,_0x271f1c){const _0x257e53=a123_0x7b4b,_0x4c75e4=_0x4a915a();while(!![]){try{const _0x2cee06=-parseInt(_0x257e53(0x1c4))/0x1*(-parseInt(_0x257e53(0x1bc))/0x2)+-parseInt(_0x257e53(0x1c0))/0x3+parseInt(_0x257e53(0x1bb))/0x4+parseInt(_0x257e53(0x1c3))/0x5*(-parseInt(_0x257e53(0x1ac))/0x6)+parseInt(_0x257e53(0x1b2))/0x7+parseInt(_0x257e53(0x1b4))/0x8+parseInt(_0x257e53(0x1c1))/0x9*(-parseInt(_0x257e53(0x1ad))/0xa);if(_0x2cee06===_0x271f1c)break;else _0x4c75e4['push'](_0x4c75e4['shift']());}catch(_0x12d7a0){_0x4c75e4['push'](_0x4c75e4['shift']());}}}(a123_0x530d,0xd0e2a));import{readFileSync}from'node:fs';import{resolve,dirname}from'node:path';import{fileURLToPath}from'node:url';import a123_0x425f02 from'semver';import{getCdnConfig}from'./cdn-config.js';import{NPM_PACKAGE_NAME}from'../constant/cli.js';function a123_0x7b4b(_0x2fc6bf,_0xc682ef){_0x2fc6bf=_0x2fc6bf-0x1aa;const _0x530df7=a123_0x530d();let _0x7b4b4e=_0x530df7[_0x2fc6bf];return _0x7b4b4e;}function a123_0x530d(){const _0x3e4d37=['84ZPpyzO','1994870MCkdtg','utf-8','npm\x20install\x20-g\x20','log','coerce','4667579hLwjmU','@latest','7744432IUbRFu','cli','\x20\x20\x20Current\x20CLI\x20version:\x20','stableVersion','package.json','\x1b[1m','needsUpgrade','2359524eJZAYT','123122gQxlHP','some','1.0.0','parse','1034676oSfyMP','99ikPysw','\x1b[33m','131755lleBNG','25NqUOOk','../..','\x20\x20\x20Upgrade\x20command:\x20','\x20\x20\x20Stable\x20version:\x20','currentVersion'];a123_0x530d=function(){return _0x3e4d37;};return a123_0x530d();}function getCurrentCliVersion(){const _0x592d74=a123_0x7b4b;try{const _0x1481b3=fileURLToPath(import.meta.url),_0x62cff9=resolve(dirname(_0x1481b3),_0x592d74(0x1c5)),_0x55c969=resolve(_0x62cff9,_0x592d74(0x1b8)),_0x5df3c2=JSON[_0x592d74(0x1bf)](readFileSync(_0x55c969,_0x592d74(0x1ae)));return _0x5df3c2['version']||_0x592d74(0x1be);}catch{return _0x592d74(0x1be);}}function isNonNumericVersion(_0x56f67d){const _0xc2f35d=a123_0x7b4b,_0xca799f=[/^latest$/i,/^beta$/i,/^alpha$/i,/^canary$/i,/^\^/,/^~/,/^>/,/^</,/^\*/,/^x$/];return _0xca799f[_0xc2f35d(0x1bd)](_0x47df21=>_0x47df21['test'](_0x56f67d));}export async function checkCliVersion(){const _0x64f53a=a123_0x7b4b,_0x19fa60=getCurrentCliVersion(),_0x429ae3=await getCdnConfig(),_0x49da87=_0x429ae3?.[_0x64f53a(0x1b5)]?.[_0x64f53a(0x1b7)]||null;let _0x453684=![];if(_0x49da87)try{const _0x6eae81=a123_0x425f02['coerce'](_0x19fa60),_0xe924a9=a123_0x425f02[_0x64f53a(0x1b1)](_0x49da87);_0x6eae81&&_0xe924a9&&(_0x453684=a123_0x425f02['lt'](_0x6eae81,_0xe924a9));}catch{_0x453684=![];}return{'currentVersion':_0x19fa60,'stableVersion':_0x49da87,'needsUpgrade':_0x453684,'isPreRelease':![]};}export function printCliUpgradeWarning(_0x36cb9b){const _0x3d6dea=a123_0x7b4b;if(!_0x36cb9b[_0x3d6dea(0x1ba)])return;const _0x41892b=_0x3d6dea(0x1c2),_0x28665b='\x1b[0m',_0x10e600=_0x3d6dea(0x1b9),_0x2b27ee=_0x3d6dea(0x1af)+NPM_PACKAGE_NAME+_0x3d6dea(0x1b3);console[_0x3d6dea(0x1b0)](),console[_0x3d6dea(0x1b0)](''+_0x41892b+_0x10e600+'↪\x20New\x20version\x20available'+_0x28665b),console[_0x3d6dea(0x1b0)](_0x41892b+_0x3d6dea(0x1b6)+_0x36cb9b[_0x3d6dea(0x1ab)]+_0x28665b),console[_0x3d6dea(0x1b0)](_0x41892b+_0x3d6dea(0x1aa)+_0x36cb9b['stableVersion']+_0x28665b),console[_0x3d6dea(0x1b0)](_0x41892b+_0x3d6dea(0x1c6)+_0x2b27ee+_0x28665b),console['log']();}
|
package/lib/utils/config.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x388c1c,_0x15e503){const _0x4fd4b9=a124_0x3a30,_0x5d801a=_0x388c1c();while(!![]){try{const _0x3a0dee=parseInt(_0x4fd4b9(0x105))/0x1*(-parseInt(_0x4fd4b9(0x104))/0x2)+parseInt(_0x4fd4b9(0xf1))/0x3+parseInt(_0x4fd4b9(0x102))/0x4+-parseInt(_0x4fd4b9(0xf3))/0x5*(parseInt(_0x4fd4b9(0xfc))/0x6)+parseInt(_0x4fd4b9(0xf5))/0x7*(-parseInt(_0x4fd4b9(0xf9))/0x8)+-parseInt(_0x4fd4b9(0x101))/0x9+parseInt(_0x4fd4b9(0xfb))/0xa*(parseInt(_0x4fd4b9(0xed))/0xb);if(_0x3a0dee===_0x15e503)break;else _0x5d801a['push'](_0x5d801a['shift']());}catch(_0x2d01d9){_0x5d801a['push'](_0x5d801a['shift']());}}}(a124_0x444b,0xbfdf7));function a124_0x3a30(_0xf4e7fe,_0xcfd304){_0xf4e7fe=_0xf4e7fe-0xec;const _0x444b57=a124_0x444b();let _0x3a3043=_0x444b57[_0xf4e7fe];return _0x3a3043;}import{initEnv}from'../constant/env.js';import{readRawConfig}from'../context.js';export{getProjectConfigPath,getGlobalConfigPath}from'../context.js';function a124_0x444b(){const _0x25eafd=['6945390VZJNMG','906jgmDrK','defaultApp','https://g.lovrabet.com/dist/lovrabet-skill','trim','filter','2505987ZsvrVS','6219808OqPlno','apiDir','28PzvALN','88103cbjSvT','map','template_base_url','22EEXwBC','keys','string','env','1804998JaFjgV','apps','19730avQMhW','app','2821WmMQvp','object','appcode','values','12944QQOMcB','length'];a124_0x444b=function(){return _0x25eafd;};return a124_0x444b();}export{isInProject}from'../context.js';export function readConfig(_0x50845e){const _0x177695=a124_0x3a30,_0x24166d=readRawConfig(_0x50845e);return _0x24166d[_0x177695(0xf0)]&&typeof _0x24166d['env']===_0x177695(0xef)&&initEnv(_0x24166d[_0x177695(0xf0)]),_0x24166d;}export function getConfigAppCode(){const _0x3df116=a124_0x3a30,_0x5eb44f=readRawConfig();if(_0x5eb44f['apps']&&typeof _0x5eb44f['apps']===_0x3df116(0xf6)){const _0x32b548=_0x5eb44f[_0x3df116(0xfd)];if(_0x32b548&&_0x5eb44f[_0x3df116(0xf2)][_0x32b548]?.['appcode'])return String(_0x5eb44f['apps'][_0x32b548][_0x3df116(0xf7)])['trim']();const _0x378f46=Object[_0x3df116(0xf8)](_0x5eb44f['apps'])[0x0];if(_0x378f46?.[_0x3df116(0xf7)])return String(_0x378f46[_0x3df116(0xf7)])['trim']();}const _0xfd7aef=_0x5eb44f[_0x3df116(0xf7)]||_0x5eb44f[_0x3df116(0xf4)];if(typeof _0xfd7aef!==_0x3df116(0xef)||_0xfd7aef[_0x3df116(0xff)]()==='')return undefined;return _0xfd7aef[_0x3df116(0xff)]();}export function getMultiAppConfigs(){const _0xc0eac7=a124_0x3a30,_0x1d4932=readRawConfig(),_0x4280bb=_0x1d4932[_0xc0eac7(0xf2)];if(!_0x4280bb||typeof _0x4280bb!==_0xc0eac7(0xf6)||Object[_0xc0eac7(0xee)](_0x4280bb)[_0xc0eac7(0xfa)]===0x0)return null;const _0x1e8f37=_0x1d4932[_0xc0eac7(0xfd)];return Object['entries'](_0x4280bb)[_0xc0eac7(0x106)](([_0x482cbe,_0x425319])=>({'name':_0x482cbe,'appcode':_0x425319?.['appcode']||'','isDefault':_0x482cbe===_0x1e8f37,'env':_0x425319?.[_0xc0eac7(0xf0)],'apiDir':_0x425319?.[_0xc0eac7(0x103)],'cookie':_0x425319?.['cookie']||undefined}))[_0xc0eac7(0x100)](_0x3d5557=>_0x3d5557[_0xc0eac7(0xf7)]);}export function getTemplateBaseUrl(){const _0x301c71=a124_0x3a30,_0x2806eb=readRawConfig();if(_0x2806eb[_0x301c71(0xec)]&&typeof _0x2806eb[_0x301c71(0xec)]===_0x301c71(0xef))return _0x2806eb[_0x301c71(0xec)]['replace'](/\/$/,'');return _0x301c71(0xfe);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a125_0x2df1(){const _0x3498ab=['384ThzWbk','22OaHkMX','8NsGrLe','copyFileSync','1134600NSAjIm','name','18rXFqwJ','178549GyAuXV','103531VAysqz','join','9DNtkBj','37450yAOwwt','218775jBlMbf','isDirectory','916528USYPJb','复制目录时出错:','readdirSync','2290VzrACr'];a125_0x2df1=function(){return _0x3498ab;};return a125_0x2df1();}(function(_0x646f68,_0x51aaa3){const _0xe1815c=a125_0x29ed,_0x3398ea=_0x646f68();while(!![]){try{const _0x25f6e1=-parseInt(_0xe1815c(0x1cf))/0x1*(-parseInt(_0xe1815c(0x1c9))/0x2)+-parseInt(_0xe1815c(0x1d3))/0x3+parseInt(_0xe1815c(0x1d9))/0x4*(-parseInt(_0xe1815c(0x1d8))/0x5)+parseInt(_0xe1815c(0x1cd))/0x6*(-parseInt(_0xe1815c(0x1ce))/0x7)+-parseInt(_0xe1815c(0x1d5))/0x8*(parseInt(_0xe1815c(0x1d1))/0x9)+parseInt(_0xe1815c(0x1d2))/0xa*(parseInt(_0xe1815c(0x1da))/0xb)+parseInt(_0xe1815c(0x1cb))/0xc;if(_0x25f6e1===_0x51aaa3)break;else _0x3398ea['push'](_0x3398ea['shift']());}catch(_0x46c2db){_0x3398ea['push'](_0x3398ea['shift']());}}}(a125_0x2df1,0x32d38));import a125_0x52410c from'node:path';function a125_0x29ed(_0x2cf6a5,_0x22cec9){_0x2cf6a5=_0x2cf6a5-0x1c9;const _0x2df149=a125_0x2df1();let _0x29ed42=_0x2df149[_0x2cf6a5];return _0x29ed42;}import a125_0x5d3bc7 from'node:fs';export async function copyDirectory(_0x4c1ffc,_0x5ab8a0){const _0x384b37=a125_0x29ed;try{const _0x1cc87c=a125_0x5d3bc7[_0x384b37(0x1d7)](_0x4c1ffc,{'withFileTypes':!![]});a125_0x5d3bc7['mkdirSync'](_0x5ab8a0,{'recursive':!![]});for(const _0x41a580 of _0x1cc87c){const _0x2c35a0=a125_0x52410c[_0x384b37(0x1d0)](_0x4c1ffc,_0x41a580[_0x384b37(0x1cc)]),_0x62c16d=a125_0x52410c[_0x384b37(0x1d0)](_0x5ab8a0,_0x41a580[_0x384b37(0x1cc)]);_0x41a580[_0x384b37(0x1d4)]()?await copyDirectory(_0x2c35a0,_0x62c16d):a125_0x5d3bc7[_0x384b37(0x1ca)](_0x2c35a0,_0x62c16d);}}catch(_0x56090a){console['error'](_0x384b37(0x1d6),_0x56090a);}}
|
package/lib/utils/file-utils.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4f8ce6,_0x1cfed6){const _0xe6f0c3=a126_0x3adc,_0x59b4f7=_0x4f8ce6();while(!![]){try{const _0x2dbe91=-parseInt(_0xe6f0c3(0x1f5))/0x1*(-parseInt(_0xe6f0c3(0x1f8))/0x2)+parseInt(_0xe6f0c3(0x1ef))/0x3+parseInt(_0xe6f0c3(0x1f1))/0x4*(-parseInt(_0xe6f0c3(0x1ee))/0x5)+-parseInt(_0xe6f0c3(0x1f2))/0x6+parseInt(_0xe6f0c3(0x1f3))/0x7*(parseInt(_0xe6f0c3(0x1fa))/0x8)+parseInt(_0xe6f0c3(0x1f4))/0x9*(-parseInt(_0xe6f0c3(0x1f0))/0xa)+-parseInt(_0xe6f0c3(0x1f9))/0xb*(-parseInt(_0xe6f0c3(0x1f7))/0xc);if(_0x2dbe91===_0x1cfed6)break;else _0x59b4f7['push'](_0x59b4f7['shift']());}catch(_0x26c4ff){_0x59b4f7['push'](_0x59b4f7['shift']());}}}(a126_0x96bd,0x33954));import{existsSync,mkdirSync,copyFileSync,readdirSync,statSync}from'node:fs';import{join}from'node:path';export async function copyDir(_0x4f5760,_0x10766d){const _0x2c36c6=a126_0x3adc,_0x1d0477=statSync(_0x4f5760);if(_0x1d0477[_0x2c36c6(0x1f6)]()){!existsSync(_0x10766d)&&mkdirSync(_0x10766d,{'recursive':!![]});const _0x92229a=readdirSync(_0x4f5760);for(const _0x5e9dab of _0x92229a){await copyDir(join(_0x4f5760,_0x5e9dab),join(_0x10766d,_0x5e9dab));}}else copyFileSync(_0x4f5760,_0x10766d);}function a126_0x3adc(_0x2a434d,_0x257369){_0x2a434d=_0x2a434d-0x1ee;const _0x96bda6=a126_0x96bd();let _0x3adc33=_0x96bda6[_0x2a434d];return _0x3adc33;}export function ensureDir(_0x360fcc){!existsSync(_0x360fcc)&&mkdirSync(_0x360fcc,{'recursive':!![]});}function a126_0x96bd(){const _0x44c7a0=['isDirectory','4296hPVkHm','2ywLMSq','2321TExnBa','410680SSFnoR','3945XInHDu','585936zPrtcj','2313550ICFNKh','708FaKuuy','782568gfzFQx','7KYQyCm','9VrSnjz','390535uiILMq'];a126_0x96bd=function(){return _0x44c7a0;};return a126_0x96bd();}export function pathExists(_0x4f4ee7){return existsSync(_0x4f4ee7);}
|
package/lib/utils/guides-cdn.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a127_0x546266=a127_0x161f;function a127_0x161f(_0x45167e,_0x12dc45){_0x45167e=_0x45167e-0xd1;const _0x2066d3=a127_0x2066();let _0x161f4d=_0x2066d3[_0x45167e];return _0x161f4d;}(function(_0x422004,_0x33583c){const _0x2738c4=a127_0x161f,_0x5129ea=_0x422004();while(!![]){try{const _0x5a98f8=parseInt(_0x2738c4(0xdd))/0x1+parseInt(_0x2738c4(0xe3))/0x2+parseInt(_0x2738c4(0xd3))/0x3*(parseInt(_0x2738c4(0xe4))/0x4)+-parseInt(_0x2738c4(0xed))/0x5+parseInt(_0x2738c4(0xd8))/0x6+-parseInt(_0x2738c4(0xe6))/0x7*(-parseInt(_0x2738c4(0xde))/0x8)+parseInt(_0x2738c4(0xd9))/0x9*(-parseInt(_0x2738c4(0xd7))/0xa);if(_0x5a98f8===_0x33583c)break;else _0x5129ea['push'](_0x5129ea['shift']());}catch(_0x550a03){_0x5129ea['push'](_0x5129ea['shift']());}}}(a127_0x2066,0x294d2));import{mkdirSync,writeFileSync}from'node:fs';import{dirname,join}from'node:path';import{homedir}from'node:os';import{getTemplateBaseUrl}from'./config.js';function getGuidesCdnUrl(){const _0x103524=getTemplateBaseUrl();return _0x103524+'/skills/guides.json';}const CACHE_DIR=join(homedir(),a127_0x546266(0xe7),a127_0x546266(0xe1));export async function fetchGuidesFromCDN(){const _0x35110c=a127_0x546266,_0x52de3f=getGuidesCdnUrl(),_0x330d15=await fetch(_0x52de3f,{'headers':{'Accept':_0x35110c(0xe9)}});if(!_0x330d15['ok'])throw new Error(_0x35110c(0xd4)+_0x330d15[_0x35110c(0xef)]+'\x20'+_0x330d15['statusText']);const _0x15728c=await _0x330d15[_0x35110c(0xe5)]();if(!_0x15728c['guides']||typeof _0x15728c[_0x35110c(0xee)]!==_0x35110c(0xea))throw new Error(_0x35110c(0xf2));return _0x15728c;}export function writeGuidesToProject(_0x4e85db,_0x32bb5e,_0x2b9cf4=a127_0x546266(0xf0),_0x4f03aa){const _0x50cca1=a127_0x546266,_0x57049a=join(_0x32bb5e,_0x2b9cf4);mkdirSync(_0x57049a,{'recursive':!![]});for(const [_0x1e67ae,_0x10f592]of Object[_0x50cca1(0xe2)](_0x4e85db[_0x50cca1(0xee)])){let _0x5284e7=_0x10f592[_0x50cca1(0xdf)];_0x10f592[_0x50cca1(0xe0)]&&(_0x5284e7=appendUpdateTime(_0x5284e7,_0x10f592[_0x50cca1(0xe0)])),writeFileSync(join(_0x57049a,_0x1e67ae+_0x50cca1(0xeb)),_0x5284e7,_0x50cca1(0xda));}}function a127_0x2066(){const _0x1115cf=['application/json','object','.md','push','1033845DQeQKf','guides','status','.lovrabet/skill/guides','trimEnd','CDN\x20返回数据格式错误','join','CDN\x20数据中缺少\x20skillTemplate','title','path','402DgeJCs','CDN\x20请求失败:\x20','\x0a\x0a>更新时间:','skillTemplate','10BINdwx','1741134tCFCFT','3889368szIQZQ','utf-8','length','replace','96639CmLRCM','912584cOTXxS','content','lastUpdated','cache','entries','123672Ytkatd','7324oohhNd','json','7EzfZxe','.lovrabet','extendContent'];a127_0x2066=function(){return _0x1115cf;};return a127_0x2066();}export function appendUpdateTime(_0x382311,_0x58592d){const _0x4f3fc3=a127_0x546266;return _0x382311=_0x382311[_0x4f3fc3(0xdc)](/\n*>更新时间:.*$/m,''),_0x382311[_0x4f3fc3(0xf1)]()+(_0x4f3fc3(0xd5)+_0x58592d);}export function getSkillTemplate(_0x55d33c){const _0x4fd96a=a127_0x546266;return _0x55d33c[_0x4fd96a(0xd6)]?.[_0x4fd96a(0xdf)]||'';}export function appendExtendContents(_0x26a409,_0x2be8db,_0x10d7a6){const _0x16c09b=a127_0x546266,_0x227e96=[];for(const [,_0x498e1a]of Object[_0x16c09b(0xe2)](_0x2be8db[_0x16c09b(0xee)])){_0x498e1a[_0x16c09b(0xe8)]&&_0x227e96[_0x16c09b(0xec)](_0x498e1a[_0x16c09b(0xe8)]['trimEnd']());}if(_0x227e96[_0x16c09b(0xdb)]===0x0)return _0x26a409;return _0x26a409[_0x16c09b(0xf1)]()+'\x0a\x0a'+_0x227e96[_0x16c09b(0xf3)]('\x0a\x0a')+'\x0a';}export function writeSkillFile(_0x35803a,_0xfc981c,_0x2af4ac){const _0x48f3d1=a127_0x546266,_0x5751b9=getSkillTemplate(_0x35803a);if(!_0x5751b9)throw new Error(_0x48f3d1(0xf4));const _0x2c9363=dirname(_0xfc981c);mkdirSync(_0x2c9363,{'recursive':!![]});let _0x2a4e5e=_0x5751b9[_0x48f3d1(0xdc)](/\{\{IDE_NAME\}\}/g,_0x2af4ac);_0x2a4e5e=appendExtendContents(_0x2a4e5e,_0x35803a),_0x35803a[_0x48f3d1(0xd6)][_0x48f3d1(0xe0)]&&(_0x2a4e5e=appendUpdateTime(_0x2a4e5e,_0x35803a['skillTemplate'][_0x48f3d1(0xe0)])),writeFileSync(_0xfc981c,_0x2a4e5e,_0x48f3d1(0xda));}export async function installGuides(_0x55bd6f){const _0x426c4e=a127_0x546266,_0x42edc9=await fetchGuidesFromCDN();return writeGuidesToProject(_0x42edc9,_0x55bd6f),Object['keys'](_0x42edc9[_0x426c4e(0xee)])[_0x426c4e(0xdb)];}export function getGuidesSummary(_0x403a81){const _0x5dcb80=a127_0x546266;return Object[_0x5dcb80(0xe2)](_0x403a81[_0x5dcb80(0xee)])['map'](([_0xb5a5b0,_0x39ae64])=>({'key':_0xb5a5b0,'title':_0x39ae64[_0x5dcb80(0xd1)],'path':_0x39ae64[_0x5dcb80(0xd2)]}));}
|
package/lib/utils/http-client.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x1c8e80,_0x2f2052){const _0x5aafa3=a128_0x5910,_0x3fd384=_0x1c8e80();while(!![]){try{const _0x4f3671=-parseInt(_0x5aafa3(0xd8))/0x1*(parseInt(_0x5aafa3(0xeb))/0x2)+-parseInt(_0x5aafa3(0xd7))/0x3+parseInt(_0x5aafa3(0xd5))/0x4+-parseInt(_0x5aafa3(0xea))/0x5*(parseInt(_0x5aafa3(0xe0))/0x6)+-parseInt(_0x5aafa3(0xd6))/0x7*(-parseInt(_0x5aafa3(0xe4))/0x8)+-parseInt(_0x5aafa3(0xde))/0x9*(parseInt(_0x5aafa3(0xdc))/0xa)+parseInt(_0x5aafa3(0xe6))/0xb*(parseInt(_0x5aafa3(0xe2))/0xc);if(_0x4f3671===_0x2f2052)break;else _0x3fd384['push'](_0x3fd384['shift']());}catch(_0x1f2802){_0x3fd384['push'](_0x3fd384['shift']());}}}(a128_0x4181,0x97880));export async function httpRequest(_0x164de1,_0x3cf06f={}){const _0x28176e=a128_0x5910,{timeout:timeout=0x7530,retries:retries=0x3,retryDelay:retryDelay=0x3e8,headers:headers={}}=_0x3cf06f;let _0x3a5125=null;for(let _0x2cfa61=0x0;_0x2cfa61<=retries;_0x2cfa61++){try{const _0x562d18=new AbortController(),_0x1b05ef=setTimeout(()=>_0x562d18[_0x28176e(0xd4)](),timeout),_0x3cf6fc=await fetch(_0x164de1,{'headers':headers,'signal':_0x562d18['signal']});clearTimeout(_0x1b05ef);let _0x58bedd;const _0x43f54b=_0x3cf6fc[_0x28176e(0xda)]['get']('content-type');return _0x43f54b?.[_0x28176e(0xdb)](_0x28176e(0xec))?_0x58bedd=await _0x3cf6fc[_0x28176e(0xef)]():_0x58bedd=await _0x3cf6fc[_0x28176e(0xed)](),{'ok':_0x3cf6fc['ok'],'status':_0x3cf6fc[_0x28176e(0xd9)],'statusText':_0x3cf6fc[_0x28176e(0xdd)],'data':_0x58bedd,'headers':_0x3cf6fc[_0x28176e(0xda)],'url':_0x3cf6fc['url'],'text':()=>_0x3cf6fc['text']()};}catch(_0x2c64bb){_0x3a5125=_0x2c64bb instanceof Error?_0x2c64bb:new Error(String(_0x2c64bb));if(_0x2cfa61===retries)break;if(shouldRetry(_0x2c64bb)){console[_0x28176e(0xe8)]('*\x20请求失败,'+retryDelay+_0x28176e(0xe5)+(_0x2cfa61+0x1)+_0x28176e(0xe3)),await sleep(retryDelay);continue;}else break;}}throw _0x3a5125||new Error(_0x28176e(0xe9));}function a128_0x4181(){const _0x20494b=['\x20次重试...','176KgYMXZ','ms\x20后进行第\x20','3332626pCFVyL','AbortError','log','Request\x20failed','5065HjBzFN','1828596vuLcgQ','application/json','text','message','json','abort','4548492CJRBHd','365645czydeJ','610104ziYeeK','1lzriVp','status','headers','includes','10xUmIPW','statusText','6062814BsnKJg','name','1050xILuzE','ECONNRESET','12IPJaRf'];a128_0x4181=function(){return _0x20494b;};return a128_0x4181();}function shouldRetry(_0x5ac981){const _0x336284=a128_0x5910;if(_0x5ac981 instanceof Error){if(_0x5ac981[_0x336284(0xdf)]===_0x336284(0xe7))return![];if(_0x5ac981[_0x336284(0xdf)]==='TypeError'&&_0x5ac981[_0x336284(0xee)][_0x336284(0xdb)]('fetch'))return!![];if(_0x5ac981[_0x336284(0xee)]['includes'](_0x336284(0xe1)))return!![];if(_0x5ac981[_0x336284(0xee)][_0x336284(0xdb)]('ENOTFOUND'))return![];}return![];}function a128_0x5910(_0xc712de,_0x1d85fc){_0xc712de=_0xc712de-0xd4;const _0x418183=a128_0x4181();let _0x5910fb=_0x418183[_0xc712de];return _0x5910fb;}function sleep(_0x3b0684){return new Promise(_0x4b3931=>setTimeout(_0x4b3931,_0x3b0684));}export function validateUrl(_0x4a24a6){try{return new URL(_0x4a24a6),!![];}catch{return![];}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x103264,_0x1866d1){const _0x104a0d=a129_0x3b14,_0x15d030=_0x103264();while(!![]){try{const _0x180e19=-parseInt(_0x104a0d(0xb8))/0x1*(parseInt(_0x104a0d(0xc0))/0x2)+-parseInt(_0x104a0d(0xba))/0x3*(parseInt(_0x104a0d(0xc4))/0x4)+-parseInt(_0x104a0d(0xb9))/0x5*(parseInt(_0x104a0d(0xc5))/0x6)+parseInt(_0x104a0d(0xbc))/0x7*(-parseInt(_0x104a0d(0xc1))/0x8)+-parseInt(_0x104a0d(0xbe))/0x9+-parseInt(_0x104a0d(0xbf))/0xa+parseInt(_0x104a0d(0xbd))/0xb*(parseInt(_0x104a0d(0xc3))/0xc);if(_0x180e19===_0x1866d1)break;else _0x15d030['push'](_0x15d030['shift']());}catch(_0x23d452){_0x15d030['push'](_0x15d030['shift']());}}}(a129_0x4495,0x36422));function env(_0x38c1ab){return process.env[`RABETBASE_${_0x38c1ab}`]||process.env[`LOVRABET_${_0x38c1ab}`]||undefined;}function a129_0x4495(){const _0x55b706=['5621xujfXd','220cBnXte','3013398LebDid','460910jevfAK','1014FnWRIj','1120OXvJDX','stdin','727428hweeOu','52CWAgLb','486ZhwfOa','isRaw','stdout','isTTY','461GKcosR','12605KBHInW','13587PoHvJm','true'];a129_0x4495=function(){return _0x55b706;};return a129_0x4495();}export function isNonInteractive(_0x2407ec){const _0x3b861a=a129_0x3b14;return!!(_0x2407ec['nonInteractive']||_0x2407ec['ci']||env('CI')===_0x3b861a(0xbb)||process.env.CI==='true'||!process[_0x3b861a(0xb6)][_0x3b861a(0xb7)]||!isStdinRawModeSupported());}function a129_0x3b14(_0x6b74dc,_0x30cbcf){_0x6b74dc=_0x6b74dc-0xb5;const _0x449585=a129_0x4495();let _0x3b140f=_0x449585[_0x6b74dc];return _0x3b140f;}function isStdinRawModeSupported(){const _0x39d6f7=a129_0x3b14;if(!process[_0x39d6f7(0xc2)][_0x39d6f7(0xb7)])return![];try{const _0x34670e=process[_0x39d6f7(0xc2)][_0x39d6f7(0xb5)];return process[_0x39d6f7(0xc2)]['setRawMode'](!![]),process[_0x39d6f7(0xc2)]['setRawMode'](_0x34670e??![]),!![];}catch{return![];}}
|
package/lib/utils/logger.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a130_0x1aacc3=a130_0x3e6a;(function(_0x53b866,_0xb12cb5){const _0x3423ff=a130_0x3e6a,_0x588181=_0x53b866();while(!![]){try{const _0x39a7f2=parseInt(_0x3423ff(0xa6))/0x1+parseInt(_0x3423ff(0xbe))/0x2+parseInt(_0x3423ff(0xa9))/0x3+parseInt(_0x3423ff(0xbf))/0x4*(-parseInt(_0x3423ff(0xc4))/0x5)+parseInt(_0x3423ff(0xd1))/0x6*(parseInt(_0x3423ff(0xc1))/0x7)+-parseInt(_0x3423ff(0xbb))/0x8*(parseInt(_0x3423ff(0xd3))/0x9)+-parseInt(_0x3423ff(0xa2))/0xa;if(_0x39a7f2===_0xb12cb5)break;else _0x588181['push'](_0x588181['shift']());}catch(_0x4e7510){_0x588181['push'](_0x588181['shift']());}}}(a130_0x4b0a,0xdde1f));import a130_0x77437a from'winston';import a130_0x288603 from'node:fs';function a130_0x4b0a(){const _0x2a028d=['失败:\x20','level','details','Failed\x20to\x20clear\x20logs:','error','mkdirSync','.lovrabet.log','initWinstonLogger','66kNJYSN','currentRawCommand','207jqtbtp','utf8','filter','toISOString','combine','logTask','log','errors','3844900KfOaBA','message','getWinstonInstance','winstonLogger','1017795tQvNum','logFilePath','existsSync','2949846zRVLPJ','yellow','success','map','duration','green','format','red','clear','split','setLogPath','addColors','createLogger','printf','warn','File','writeFileSync','完成:\x20','580192HgNGtd','开始执行:\x20','clearLogs','2124168dLcrpb','3944lsDSHk','now','477974Kumkak','transports','join','4325BwosiL','stringify','unknown','info','timestamp'];a130_0x4b0a=function(){return _0x2a028d;};return a130_0x4b0a();}import a130_0x3ad75f from'node:path';function a130_0x3e6a(_0x25805c,_0x4dfa37){_0x25805c=_0x25805c-0xa2;const _0x4b0a98=a130_0x4b0a();let _0x3e6a1e=_0x4b0a98[_0x25805c];return _0x3e6a1e;}class Logger{[a130_0x1aacc3(0xa5)];[a130_0x1aacc3(0xa7)];['currentRawCommand']='';constructor(){const _0x1c9eff=a130_0x1aacc3;this[_0x1c9eff(0xa7)]='';}['setRawCommand'](_0x4122e9){const _0x251f34=a130_0x1aacc3;this[_0x251f34(0xd2)]=_0x4122e9;}[a130_0x1aacc3(0xd0)](){const _0x366a1b=a130_0x1aacc3,_0x547c42=a130_0x3ad75f['dirname'](this[_0x366a1b(0xa7)]);!a130_0x288603[_0x366a1b(0xa8)](_0x547c42)&&a130_0x288603[_0x366a1b(0xce)](_0x547c42,{'recursive':!![]});const _0x2143e9=a130_0x77437a[_0x366a1b(0xaf)][_0x366a1b(0xd7)](a130_0x77437a['format'][_0x366a1b(0xc8)](),a130_0x77437a[_0x366a1b(0xaf)][_0x366a1b(0xda)]({'stack':!![]}),a130_0x77437a[_0x366a1b(0xaf)][_0x366a1b(0xb6)](_0x12cb87=>{const _0x579579=_0x366a1b,_0x334952={'timestamp':_0x12cb87[_0x579579(0xc8)]||new Date()[_0x579579(0xd6)](),'level':_0x12cb87[_0x579579(0xca)]||_0x579579(0xc7),'command':_0x12cb87['command']||_0x579579(0xc6),'rawCommand':_0x12cb87['rawCommand']||this['currentRawCommand']||undefined,'message':_0x12cb87[_0x579579(0xa3)]||'','duration':_0x12cb87[_0x579579(0xad)]||undefined,'details':_0x12cb87[_0x579579(0xcb)]||undefined};return JSON[_0x579579(0xc5)](_0x334952);}));this[_0x366a1b(0xa5)]=a130_0x77437a[_0x366a1b(0xb5)]({'level':_0x366a1b(0xc7),'format':_0x2143e9,'transports':[new a130_0x77437a[(_0x366a1b(0xc2))][(_0x366a1b(0xb8))]({'filename':this[_0x366a1b(0xa7)],'level':_0x366a1b(0xc7)})],'silent':![]}),a130_0x77437a[_0x366a1b(0xb4)]({'success':_0x366a1b(0xae),'error':_0x366a1b(0xb0),'warn':_0x366a1b(0xaa),'info':'blue'});}[a130_0x1aacc3(0xb3)](_0x5f5b73){const _0x1f077d=a130_0x1aacc3;this[_0x1f077d(0xa7)]=a130_0x3ad75f[_0x1f077d(0xc3)](_0x5f5b73,_0x1f077d(0xcf)),this[_0x1f077d(0xa5)]&&this['winstonLogger'][_0x1f077d(0xb1)](),this[_0x1f077d(0xd0)]();}[a130_0x1aacc3(0xc7)](_0x5be653,_0x512016,_0xdf4f3){const _0x127af8=a130_0x1aacc3;if(!this[_0x127af8(0xa7)]||!this[_0x127af8(0xa5)])return;this[_0x127af8(0xa5)]['info'](_0x512016,{'command':_0x5be653,'details':_0xdf4f3});}[a130_0x1aacc3(0xab)](_0x1c8324,_0xe31757,_0x2ae0b6,_0x28eb7a){const _0x58da5e=a130_0x1aacc3;if(!this[_0x58da5e(0xa7)]||!this[_0x58da5e(0xa5)])return;this['winstonLogger'][_0x58da5e(0xd9)](_0x58da5e(0xc7),_0xe31757,{'level':_0x58da5e(0xab),'command':_0x1c8324,'duration':_0x2ae0b6,'details':_0x28eb7a});}[a130_0x1aacc3(0xcd)](_0x158c07,_0x4876c3,_0x407c17){const _0x4b64f5=a130_0x1aacc3;if(!this['logFilePath']||!this['winstonLogger'])return;this['winstonLogger'][_0x4b64f5(0xcd)](_0x4876c3,{'command':_0x158c07,'details':_0x407c17});}[a130_0x1aacc3(0xb7)](_0x4bf3d4,_0x1fd323,_0x3a0d5f){const _0xc44dc3=a130_0x1aacc3;if(!this[_0xc44dc3(0xa7)]||!this[_0xc44dc3(0xa5)])return;this['winstonLogger'][_0xc44dc3(0xb7)](_0x1fd323,{'command':_0x4bf3d4,'details':_0x3a0d5f});}async[a130_0x1aacc3(0xd8)](_0x5df89e,_0xd75f8b,_0xe1cda4){const _0x8865fe=a130_0x1aacc3,_0x1269d2=Date[_0x8865fe(0xc0)]();this[_0x8865fe(0xc7)](_0x5df89e,_0x8865fe(0xbc)+_0xd75f8b);try{const _0x1b2f3c=await _0xe1cda4(),_0x113249=Date[_0x8865fe(0xc0)]()-_0x1269d2;return this['success'](_0x5df89e,_0x8865fe(0xba)+_0xd75f8b,_0x113249),_0x1b2f3c;}catch(_0x5df8ad){const _0x2d295c=Date[_0x8865fe(0xc0)]()-_0x1269d2;this[_0x8865fe(0xcd)](_0x5df89e,_0x8865fe(0xc9)+_0xd75f8b,{'error':_0x5df8ad instanceof Error?_0x5df8ad[_0x8865fe(0xa3)]:String(_0x5df8ad),'duration':_0x2d295c});throw _0x5df8ad;}}['readLogs'](){const _0x4b98a6=a130_0x1aacc3;try{if(!a130_0x288603[_0x4b98a6(0xa8)](this[_0x4b98a6(0xa7)]))return[];const _0x54632b=a130_0x288603['readFileSync'](this[_0x4b98a6(0xa7)],_0x4b98a6(0xd4));return _0x54632b[_0x4b98a6(0xb2)]('\x0a')[_0x4b98a6(0xd5)](_0x367c4f=>_0x367c4f['trim']())[_0x4b98a6(0xac)](_0x175af5=>JSON['parse'](_0x175af5));}catch(_0x7c9e57){return console[_0x4b98a6(0xb7)]('Failed\x20to\x20read\x20logs:',_0x7c9e57),[];}}[a130_0x1aacc3(0xbd)](){const _0x4f8854=a130_0x1aacc3;try{a130_0x288603[_0x4f8854(0xa8)](this['logFilePath'])&&a130_0x288603[_0x4f8854(0xb9)](this[_0x4f8854(0xa7)],'',_0x4f8854(0xd4));}catch(_0x6a0157){console[_0x4f8854(0xb7)](_0x4f8854(0xcc),_0x6a0157);}}[a130_0x1aacc3(0xa4)](){const _0x1ff3fc=a130_0x1aacc3;return this[_0x1ff3fc(0xa5)];}}export const logger=new Logger();
|
package/lib/utils/platform.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
function a131_0x2f57(_0x27df27,_0x14bf13){_0x27df27=_0x27df27-0xf3;const _0x1c33b6=a131_0x1c33();let _0x2f5763=_0x1c33b6[_0x27df27];return _0x2f5763;}const a131_0x566d0e=a131_0x2f57;function a131_0x1c33(){const _0x305bca=['12164380BbTIdy','36CwUFIQ','68zxwAHx','167MXBExn','16222OaMMaM','13118rcXobw','34910OvZAzZ','732015okAxnp','win32','227931bRPEpo','272463oitiXc','platform','6136NYYUpE','1218koweUP','.cmd'];a131_0x1c33=function(){return _0x305bca;};return a131_0x1c33();}(function(_0x16529b,_0x57f9d4){const _0x33b48d=a131_0x2f57,_0x23c4c0=_0x16529b();while(!![]){try{const _0x89dce8=parseInt(_0x33b48d(0xf7))/0x1*(parseInt(_0x33b48d(0xf8))/0x2)+parseInt(_0x33b48d(0xfe))/0x3*(-parseInt(_0x33b48d(0xf6))/0x4)+-parseInt(_0x33b48d(0xfa))/0x5*(-parseInt(_0x33b48d(0x101))/0x6)+parseInt(_0x33b48d(0xf9))/0x7*(-parseInt(_0x33b48d(0x100))/0x8)+-parseInt(_0x33b48d(0xfb))/0x9+parseInt(_0x33b48d(0xf4))/0xa+-parseInt(_0x33b48d(0xfd))/0xb*(parseInt(_0x33b48d(0xf5))/0xc);if(_0x89dce8===_0x57f9d4)break;else _0x23c4c0['push'](_0x23c4c0['shift']());}catch(_0x3db91f){_0x23c4c0['push'](_0x23c4c0['shift']());}}}(a131_0x1c33,0xd2d14));export const isWindows=process[a131_0x566d0e(0xff)]===a131_0x566d0e(0xfc);export function resolveNpmBin(_0x1419a2){const _0xe07859=a131_0x566d0e;return isWindows?_0x1419a2+_0xe07859(0xf3):_0x1419a2;}
|
package/lib/utils/rules-cdn.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
const a132_0x45fde4=a132_0xa84b;(function(_0x3d7b8f,_0x441635){const _0x1190bf=a132_0xa84b,_0x49d22e=_0x3d7b8f();while(!![]){try{const _0x26a2a5=parseInt(_0x1190bf(0x154))/0x1*(-parseInt(_0x1190bf(0x14f))/0x2)+-parseInt(_0x1190bf(0x157))/0x3*(parseInt(_0x1190bf(0x156))/0x4)+-parseInt(_0x1190bf(0x155))/0x5*(-parseInt(_0x1190bf(0x149))/0x6)+-parseInt(_0x1190bf(0x158))/0x7+-parseInt(_0x1190bf(0x15a))/0x8*(parseInt(_0x1190bf(0x147))/0x9)+-parseInt(_0x1190bf(0x14c))/0xa+parseInt(_0x1190bf(0x15c))/0xb*(parseInt(_0x1190bf(0x150))/0xc);if(_0x26a2a5===_0x441635)break;else _0x49d22e['push'](_0x49d22e['shift']());}catch(_0x5ec3e3){_0x49d22e['push'](_0x49d22e['shift']());}}}(a132_0xdf92,0xdb761));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 _0x383024=a132_0xa84b,_0x387b95=getTemplateBaseUrl();return _0x387b95+_0x383024(0x15b);}const LOCAL_TEMPLATE_PATH=resolve(__dirname,a132_0x45fde4(0x14b));export async function fetchRulesFromCDN(){const _0x41e221=a132_0x45fde4,_0x5d0550=getRulesCdnUrl(),_0x8d943e=await fetch(_0x5d0550,{'headers':{'Accept':'application/json'}});if(!_0x8d943e['ok'])throw new Error(_0x41e221(0x14e)+_0x8d943e['status']+'\x20'+_0x8d943e['statusText']);const _0x578913=await _0x8d943e['json']();if(!_0x578913[_0x41e221(0x146)]||typeof _0x578913[_0x41e221(0x146)]!==_0x41e221(0x148))throw new Error(_0x41e221(0x152));return _0x578913;}export async function getRulesContent(){const _0x22cc72=a132_0x45fde4;try{const _0x258053=await fetchRulesFromCDN();return _0x258053[_0x22cc72(0x146)];}catch{return readLocalTemplate();}}export function readLocalTemplate(){const _0x38f47a=a132_0x45fde4;if(existsSync(LOCAL_TEMPLATE_PATH))return readFileSync(LOCAL_TEMPLATE_PATH,_0x38f47a(0x151));throw new Error(_0x38f47a(0x14d)+LOCAL_TEMPLATE_PATH);}function a132_0xa84b(_0x4fbe19,_0x5f1a71){_0x4fbe19=_0x4fbe19-0x145;const _0xdf92d4=a132_0xdf92();let _0xa84b47=_0xdf92d4[_0x4fbe19];return _0xa84b47;}export async function writeRulesFile(_0x485880){const _0x3eed20=a132_0x45fde4,_0x33553d=await fetchRulesFromCDN()[_0x3eed20(0x145)](()=>null);let _0x20b6c0;_0x33553d?(_0x20b6c0=_0x33553d[_0x3eed20(0x146)],_0x33553d[_0x3eed20(0x153)]&&(_0x20b6c0=appendUpdateTime(_0x20b6c0,_0x33553d['lastUpdated']))):_0x20b6c0=readLocalTemplate();const _0x915173=dirname(_0x485880);!existsSync(_0x915173)&&mkdirSync(_0x915173,{'recursive':!![]}),writeFileSync(_0x485880,_0x20b6c0,_0x3eed20(0x151));}export async function copyRulesToCursor(_0xf3e8ad){const _0x167ac6=a132_0x45fde4,_0x3685ed=join(_0xf3e8ad,_0x167ac6(0x159)),_0xb8a469=join(_0x3685ed,_0x167ac6(0x14a));if(existsSync(_0xb8a469))return![];return await writeRulesFile(_0xb8a469),!![];}function a132_0xdf92(){const _0x9366f2=['1192116NGEqLx','utf-8','CDN\x20返回数据格式错误','lastUpdated','462598hmDWkE','1395gBNomo','164328TrJhWq','9mgLmcd','9191763NiPvJY','.cursor/rules','24LTNtQY','/rules/rules.json','407gwsWvH','agents.md','catch','content','2732139OfwUFs','string','1740aTAtUn','lovrabet_rules.mdc','../../templates/rules/lovrabet_rules.mdc.tpl','480220RjWyev','本地模板文件不存在:\x20','CDN\x20请求失败:\x20','2hBlXPE'];a132_0xdf92=function(){return _0x9366f2;};return a132_0xdf92();}export async function copyRulesToAgentsMd(_0x608044){const _0x2a72fb=a132_0x45fde4,_0x5e6a4b=join(_0x608044,_0x2a72fb(0x15d));if(existsSync(_0x5e6a4b))return![];return await writeRulesFile(_0x5e6a4b),!![];}
|
package/lib/utils/sleep.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export function sleep(
|
|
1
|
+
export function sleep(_0x7a0147){return new Promise(_0x48e13c=>setTimeout(_0x48e13c,_0x7a0147));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a134_0x406c5e=a134_0x25b7;(function(_0x3245d5,_0x3b189f){const _0x19f85f=a134_0x25b7,_0x6694b7=_0x3245d5();while(!![]){try{const _0x483486=-parseInt(_0x19f85f(0xd5))/0x1*(parseInt(_0x19f85f(0xe1))/0x2)+parseInt(_0x19f85f(0xec))/0x3*(parseInt(_0x19f85f(0xf1))/0x4)+parseInt(_0x19f85f(0x103))/0x5*(parseInt(_0x19f85f(0xce))/0x6)+-parseInt(_0x19f85f(0xcb))/0x7*(parseInt(_0x19f85f(0xc2))/0x8)+parseInt(_0x19f85f(0xda))/0x9+parseInt(_0x19f85f(0xc5))/0xa*(-parseInt(_0x19f85f(0xe9))/0xb)+parseInt(_0x19f85f(0xe2))/0xc*(parseInt(_0x19f85f(0xe0))/0xd);if(_0x483486===_0x3b189f)break;else _0x6694b7['push'](_0x6694b7['shift']());}catch(_0x108e04){_0x6694b7['push'](_0x6694b7['shift']());}}}(a134_0x2433,0x8e855));function a134_0x25b7(_0x584244,_0x41d3e1){_0x584244=_0x584244-0xc2;const _0x243307=a134_0x2433();let _0x25b775=_0x243307[_0x584244];return _0x25b775;}import a134_0x513f31 from'node:fs';import a134_0x40ff0f from'node:path';import{logger}from'./logger.js';import{getCliVersion}from'./version.js';const CLI_VERSION=getCliVersion();export class TemplateReplacer{static['toComponentName'](_0x4e8b68){const _0x25090d=a134_0x25b7,_0x4c3e75=_0x4e8b68[_0x25090d(0xde)]('/')[_0x25090d(0xf0)]()||_0x4e8b68;return _0x4c3e75[_0x25090d(0xde)]('-')[_0x25090d(0xc9)](_0x3335e7=>_0x3335e7[_0x25090d(0xf8)](0x0)[_0x25090d(0xdd)]()+_0x3335e7[_0x25090d(0xe3)](0x1)['toLowerCase']())[_0x25090d(0xfe)]('');}static[a134_0x406c5e(0xf7)](_0x268fcc){const _0x267dff=a134_0x406c5e,_0x50e2b6=_0x268fcc[_0x267dff(0xde)]('/')[_0x267dff(0xf0)]()||_0x268fcc;return _0x50e2b6[_0x267dff(0xde)]('-')[_0x267dff(0xc9)](_0xaddc36=>_0xaddc36['charAt'](0x0)[_0x267dff(0xdd)]()+_0xaddc36['slice'](0x1)[_0x267dff(0xed)]())[_0x267dff(0xfe)]('\x20');}static['replaceContent'](_0xb1521e,_0x2eefef,_0x455c59){const _0x351f62=a134_0x406c5e,_0x3abfcf=this[_0x351f62(0xe8)](_0x2eefef),_0x3f3a16=this[_0x351f62(0xf7)](_0x2eefef),_0x1d608e=new Date(),_0x5f3a26=_0x1d608e[_0x351f62(0xd3)](undefined,{'year':_0x351f62(0xea),'month':'2-digit','day':_0x351f62(0xcc),'hour':'2-digit','minute':_0x351f62(0xcc),'second':_0x351f62(0xcc),'hour12':![]})[_0x351f62(0xee)](/\//g,'-'),_0x5724e4=_0x1d608e[_0x351f62(0xd8)](undefined,{'year':_0x351f62(0xea),'month':_0x351f62(0xcc),'day':_0x351f62(0xcc)})[_0x351f62(0xee)](/\//g,'-'),_0x92ecb0=_0x1d608e[_0x351f62(0xc3)](undefined,{'hour12':![]});let _0x458274=_0xb1521e[_0x351f62(0xee)](/\{CliVersion\}/g,CLI_VERSION)[_0x351f62(0xee)](/\{ComponentName\}/g,_0x3abfcf)['replace'](/\{DisplayTitle\}/g,_0x3f3a16)[_0x351f62(0xee)](/\{PageName\}/g,_0x2eefef)['replace'](/\{TemplateName\}/g,_0x455c59)[_0x351f62(0xee)](/\{CreatedAt\}/g,_0x5f3a26)['replace'](/\{CreatedDate\}/g,_0x5724e4)[_0x351f62(0xee)](/\{CreatedTime\}/g,_0x92ecb0);return _0x458274;}static[a134_0x406c5e(0xf9)](_0x3d8037,_0x3c887a,_0x2a7ceb,_0x56736e,_0x4c57d9,_0x9162c5,_0x40c1c8,_0x542742){const _0x6025ff=a134_0x406c5e,_0x318b09=new Date(),_0x6bdb31=_0x318b09[_0x6025ff(0xcf)](),_0x521748=_0x2a7ceb['map'](_0x1c9c7f=>{const _0x1e9746=_0x6025ff,_0x3cf22f=['datasetCode:\x20\x22'+_0x1c9c7f[_0x1e9746(0xff)]+'\x22',_0x1e9746(0xcd)+_0x1c9c7f[_0x1e9746(0xc6)]+'\x22',_0x1e9746(0xc8)+_0x1c9c7f[_0x1e9746(0xf3)]+'\x22'];return _0x1c9c7f[_0x1e9746(0x105)]&&_0x3cf22f[_0x1e9746(0xc7)](_0x1e9746(0xd9)+_0x1c9c7f[_0x1e9746(0x105)]+'\x22'),_0x1e9746(0xf4)+_0x3cf22f[_0x1e9746(0xfe)](',\x20')+_0x1e9746(0xd4);})[_0x6025ff(0xfe)](''),_0x59ff5d=_0x56736e||_0x2a7ceb[0x0]?.['alias']||_0x6025ff(0xfb);let _0x330ed0=_0x3d8037[_0x6025ff(0xee)](/\{AppCode\}/g,_0x3c887a)[_0x6025ff(0xee)](/\{ModelConfigs\}/g,_0x521748)[_0x6025ff(0xee)](/\{ExampleModelName\}/g,_0x59ff5d)[_0x6025ff(0xee)](/\{ApiFileName\}/g,_0x4c57d9||_0x6025ff(0xfc))[_0x6025ff(0xee)](/\{ConfigName\}/g,_0x9162c5||_0x6025ff(0xf6))['replace'](/\{ClientConfigParam\}/g,_0x40c1c8||'')['replace'](/\{VarPrefix\}/g,_0x542742||'LOVRABET')[_0x6025ff(0xee)](/\{CreatedAt\}/g,_0x6bdb31);return _0x330ed0;}static async[a134_0x406c5e(0x104)](_0x4c2a11,_0x585c96,_0x439bef,_0x4dc5d7,_0x4b2c27=!![]){const _0x36d1cc=a134_0x406c5e,_0x3b744a=Date[_0x36d1cc(0xd0)]();try{_0x4b2c27&&logger['info']('template','开始处理模板内容替换',{'templatePath':_0x4c2a11,'targetPath':_0x585c96,'pageName':_0x439bef,'templateName':_0x4dc5d7});await a134_0x513f31[_0x36d1cc(0xc4)][_0x36d1cc(0xdb)](_0x585c96,{'recursive':!![]}),await this[_0x36d1cc(0xeb)](_0x4c2a11,_0x585c96,_0x439bef,_0x4dc5d7);if(_0x4b2c27){const _0x335b48=Date[_0x36d1cc(0xd0)]()-_0x3b744a;logger[_0x36d1cc(0xf2)](_0x36d1cc(0xef),_0x36d1cc(0xfd),_0x335b48,{'pageName':_0x439bef,'templateName':_0x4dc5d7});}}catch(_0x373305){if(_0x4b2c27){const _0xe6f422=Date[_0x36d1cc(0xd0)]()-_0x3b744a;logger[_0x36d1cc(0xdc)](_0x36d1cc(0xef),'模板内容替换失败',{'templatePath':_0x4c2a11,'targetPath':_0x585c96,'pageName':_0x439bef,'templateName':_0x4dc5d7,'error':_0x373305 instanceof Error?_0x373305['message']:String(_0x373305),'duration':_0xe6f422});}throw _0x373305;}}static async[a134_0x406c5e(0xeb)](_0x360181,_0x3546c1,_0x2e6978,_0x241373){const _0x5368ce=a134_0x406c5e,_0x5848ac=await a134_0x513f31[_0x5368ce(0xc4)][_0x5368ce(0xdf)](_0x360181,{'withFileTypes':!![]});for(const _0x245429 of _0x5848ac){const _0x5f3f3e=a134_0x40ff0f[_0x5368ce(0xfe)](_0x360181,_0x245429[_0x5368ce(0xf3)]);let _0x24a673=a134_0x40ff0f[_0x5368ce(0xfe)](_0x3546c1,_0x245429['name']);_0x245429[_0x5368ce(0xf3)]['endsWith']('.tpl')&&(_0x24a673=a134_0x40ff0f['join'](_0x3546c1,_0x245429['name'][_0x5368ce(0xee)](/\.tpl$/,'')));if(_0x245429['isDirectory']())await a134_0x513f31[_0x5368ce(0xc4)][_0x5368ce(0xdb)](_0x24a673,{'recursive':!![]}),await this[_0x5368ce(0xeb)](_0x5f3f3e,_0x24a673,_0x2e6978,_0x241373);else _0x245429[_0x5368ce(0xd2)]()&&await this['processFile'](_0x5f3f3e,_0x24a673,_0x2e6978,_0x241373);}}static async[a134_0x406c5e(0xe4)](_0x12df73,_0x40bb0d,_0x38846e,_0x2a1dc3){const _0x1aec6c=a134_0x406c5e,_0xad35f4=a134_0x40ff0f[_0x1aec6c(0xe5)](_0x12df73)[_0x1aec6c(0xed)]();_0x12df73[_0x1aec6c(0xf5)]('.tpl')&&(_0x40bb0d=_0x40bb0d[_0x1aec6c(0xee)](/\.tpl$/,''));const _0x70310=[_0x1aec6c(0x100),'.ts',_0x1aec6c(0xd7),_0x1aec6c(0xd1),'.json','.md',_0x1aec6c(0x102),_0x1aec6c(0xd6),_0x1aec6c(0xca)];if(_0x70310['includes'](_0xad35f4)||_0x12df73['endsWith'](_0x1aec6c(0xca))){const _0x275818=await a134_0x513f31[_0x1aec6c(0xc4)]['readFile'](_0x12df73,_0x1aec6c(0x101)),_0x3fabf4=this[_0x1aec6c(0xfa)](_0x275818,_0x38846e,_0x2a1dc3);await a134_0x513f31[_0x1aec6c(0xc4)][_0x1aec6c(0xe6)](_0x40bb0d,_0x3fabf4,_0x1aec6c(0x101));}else await a134_0x513f31['promises'][_0x1aec6c(0xe7)](_0x12df73,_0x40bb0d);}}function a134_0x2433(){const _0x1a18e6=['4711817IEscYA','numeric','processDirectory','358419mGBspb','toLowerCase','replace','template','pop','28mDchuG','success','name','\x0a\x20\x20\x20\x20{\x20','endsWith','default','toDisplayTitle','charAt','replaceApiContent','replaceContent','YourModel','api','模板内容替换完成','join','datasetCode','.tsx','utf8','.css','425AIMpDc','processTemplate','alias','16bGJnxc','toLocaleTimeString','promises','20zsRopL','tableName','push','name:\x20\x22','map','.tpl','899108DvGOEl','2-digit','tableName:\x20\x22','28590QvXxSY','toISOString','now','.js','isFile','toLocaleString','\x20},','351268yRdCdz','.scss','.jsx','toLocaleDateString','alias:\x20\x22','902700zONDfX','mkdir','error','toUpperCase','split','readdir','1235dDYZhC','6RXagRB','178044RIEFPy','slice','processFile','extname','writeFile','copyFile','toComponentName'];a134_0x2433=function(){return _0x1a18e6;};return a134_0x2433();}
|
package/lib/utils/version.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x2a4e07,_0x5a5acd){var _0xf48d7c=a135_0x1d05,_0x4ed1ce=_0x2a4e07();while(!![]){try{var _0x5cf79d=-parseInt(_0xf48d7c(0x1f0))/0x1*(-parseInt(_0xf48d7c(0x1ef))/0x2)+-parseInt(_0xf48d7c(0x1e9))/0x3*(-parseInt(_0xf48d7c(0x1f2))/0x4)+parseInt(_0xf48d7c(0x1ed))/0x5+parseInt(_0xf48d7c(0x1ec))/0x6+parseInt(_0xf48d7c(0x1f1))/0x7+parseInt(_0xf48d7c(0x1ee))/0x8+parseInt(_0xf48d7c(0x1eb))/0x9*(-parseInt(_0xf48d7c(0x1ea))/0xa);if(_0x5cf79d===_0x5a5acd)break;else _0x4ed1ce['push'](_0x4ed1ce['shift']());}catch(_0x266f0f){_0x4ed1ce['push'](_0x4ed1ce['shift']());}}}(a135_0x1862,0x93acd));import{VERSION}from'../generated/build-info.js';export function getCliVersion(){return VERSION;}function a135_0x1d05(_0xa2ce90,_0x58dc31){_0xa2ce90=_0xa2ce90-0x1e9;var _0x18629a=a135_0x1862();var _0x1d05c2=_0x18629a[_0xa2ce90];return _0x1d05c2;}function a135_0x1862(){var _0xdcd238=['6007134QSXYmh','5155465xZYMoR','7002712BSmjSc','672fPCfck','2837sMJapc','5633747NSaftb','2335396EprVTN','3mfSvxd','10lsJVFd','41801814wdwpJr'];a135_0x1862=function(){return _0xdcd238;};return a135_0x1862();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x44a467,_0x5426de){var _0x2b4736=a136_0x23a5,_0x106fed=_0x44a467();while(!![]){try{var _0x3c01d0=parseInt(_0x2b4736(0x142))/0x1+-parseInt(_0x2b4736(0x145))/0x2+-parseInt(_0x2b4736(0x147))/0x3+-parseInt(_0x2b4736(0x13f))/0x4+-parseInt(_0x2b4736(0x140))/0x5+-parseInt(_0x2b4736(0x143))/0x6*(-parseInt(_0x2b4736(0x141))/0x7)+parseInt(_0x2b4736(0x144))/0x8*(parseInt(_0x2b4736(0x146))/0x9);if(_0x3c01d0===_0x5426de)break;else _0x106fed['push'](_0x106fed['shift']());}catch(_0x276509){_0x106fed['push'](_0x106fed['shift']());}}}(a136_0x4410,0x7d259));function a136_0x23a5(_0x103934,_0x1242c2){_0x103934=_0x103934-0x13f;var _0x4410d3=a136_0x4410();var _0x23a599=_0x4410d3[_0x103934];return _0x23a599;}import{setActiveCookie,clearActiveCookie}from'../core/api-client.js';function a136_0x4410(){var _0x4a97fc=['120632ykwjir','1519084FTeMLq','441sWKOMH','549966dhVwAj','940680NWNlsj','4794440mjqcNz','3549euAjIM','999066gJBbVe','10788CdJUdk'];a136_0x4410=function(){return _0x4a97fc;};return a136_0x4410();}export async function withActiveCookie(_0x5310f6,_0x9d14a6){setActiveCookie(_0x5310f6);try{return await _0x9d14a6();}finally{clearActiveCookie();}}
|
package/package.json
CHANGED