@lovrabet/lovrabet-cli 2.3.10-beta.3 → 2.3.11-beta.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.
- package/lib/cli.js +1 -1
- package/lib/commands/api-doc/index.js +1 -1
- package/lib/commands/app/cache.js +1 -1
- package/lib/commands/app/definitions.js +1 -1
- package/lib/commands/app/eligibility.js +1 -1
- package/lib/commands/app/mock-loader.js +1 -1
- package/lib/commands/app/remote-source.js +1 -1
- package/lib/commands/app/shared.js +1 -1
- package/lib/commands/app-config/get.js +1 -1
- package/lib/commands/app-config/index.js +1 -1
- package/lib/commands/approval/index.js +1 -1
- package/lib/commands/artifact/index.js +1 -1
- package/lib/commands/auth/device.js +1 -1
- package/lib/commands/auth/index.js +1 -1
- package/lib/commands/auth/prompt.js +1 -1
- package/lib/commands/bff/detail.js +1 -1
- package/lib/commands/bff/exec.js +1 -1
- package/lib/commands/bff/index.js +1 -1
- package/lib/commands/cli-skill/index.js +1 -1
- package/lib/commands/common/config-policy.js +1 -1
- package/lib/commands/common/constraints.js +1 -1
- package/lib/commands/common/flags.js +1 -1
- package/lib/commands/common/local-file.js +1 -1
- package/lib/commands/config/definitions.js +1 -1
- package/lib/commands/config/init.js +1 -1
- package/lib/commands/config/shared.js +1 -1
- package/lib/commands/data/import-excel.js +1 -1
- package/lib/commands/data/index.js +1 -1
- package/lib/commands/dataset/detail.js +1 -1
- package/lib/commands/dataset/index.js +1 -1
- package/lib/commands/dataset/list.js +1 -1
- package/lib/commands/dataset/sdk-doc.js +1 -1
- package/lib/commands/doctor.js +1 -1
- package/lib/commands/file/index.js +1 -1
- package/lib/commands/init.js +1 -1
- package/lib/commands/issue/context.js +1 -1
- package/lib/commands/issue/index.js +1 -1
- package/lib/commands/issue/report.js +1 -1
- package/lib/commands/kb/index.js +1 -1
- package/lib/commands/logs/index.js +1 -1
- package/lib/commands/notification/config-list.js +1 -1
- package/lib/commands/notification/index.js +1 -1
- package/lib/commands/notification/shared.js +1 -1
- package/lib/commands/ocr/index.js +1 -1
- package/lib/commands/permit/dataset-get.js +1 -1
- package/lib/commands/permit/dataset-set.js +1 -1
- package/lib/commands/permit/index.js +1 -1
- package/lib/commands/permit/page-get.js +1 -1
- package/lib/commands/permit/page-set.js +1 -1
- package/lib/commands/permit/role-menus-set.js +1 -1
- package/lib/commands/permit/role-menus.js +1 -1
- package/lib/commands/permit/shared.js +1 -1
- package/lib/commands/personal-bff/index.js +1 -1
- package/lib/commands/registry.js +1 -1
- package/lib/commands/role/create.js +1 -1
- package/lib/commands/role/delete.js +1 -1
- package/lib/commands/role/detail.js +1 -1
- package/lib/commands/role/index.js +1 -1
- package/lib/commands/role/list.js +1 -1
- package/lib/commands/role/shared.js +1 -1
- package/lib/commands/role/update.js +1 -1
- package/lib/commands/role/user-add.js +1 -1
- package/lib/commands/role/user-remove.js +1 -1
- package/lib/commands/schedule/index.js +1 -1
- package/lib/commands/schema.js +1 -1
- package/lib/commands/service/dynamic.js +1 -1
- package/lib/commands/service/function-name-adapter.js +1 -1
- package/lib/commands/service/index.js +1 -1
- package/lib/commands/service/registry.js +1 -1
- package/lib/commands/skill/commands/create.js +1 -1
- package/lib/commands/skill/commands/diagram.js +1 -1
- package/lib/commands/skill/commands/install.js +1 -1
- package/lib/commands/skill/commands/list.js +1 -1
- package/lib/commands/skill/commands/push.js +1 -1
- package/lib/commands/skill/commands/validate.js +1 -1
- package/lib/commands/skill/diagram.js +1 -1
- package/lib/commands/skill/flags.js +1 -1
- package/lib/commands/skill/index.js +1 -1
- package/lib/commands/skill/manifest-helpers.js +1 -1
- package/lib/commands/skill/push-execute.js +1 -1
- package/lib/commands/skill/push-flow-helpers.js +1 -1
- package/lib/commands/skill/push-retarget.js +1 -1
- package/lib/commands/skill/scopes.js +1 -1
- package/lib/commands/skill/summary.js +1 -1
- package/lib/commands/skill/templates.js +1 -1
- package/lib/commands/skill/validate.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/update.js +1 -1
- package/lib/commands/user-account/bind.js +1 -1
- package/lib/commands/user-account/index.js +1 -1
- package/lib/commands/workspace/index.js +1 -1
- package/lib/config/domain-config.js +1 -1
- package/lib/config/schema.js +1 -1
- package/lib/constant/app.js +1 -1
- package/lib/constant/auth-mode.js +1 -1
- package/lib/constant/cli.js +1 -1
- package/lib/constant/defaults.js +1 -1
- package/lib/constant/distribution.js +1 -1
- package/lib/constant/domain.js +1 -1
- package/lib/constant/env.js +1 -1
- package/lib/constant/output.js +1 -1
- package/lib/constant/product.js +1 -1
- package/lib/constant/region.js +1 -1
- package/lib/constant/risk.js +1 -1
- package/lib/constant/url.js +1 -1
- package/lib/context.js +1 -1
- package/lib/core/api-client.js +1 -1
- package/lib/core/db-resolver.js +1 -1
- package/lib/core/kb-management-client.js +1 -1
- package/lib/core/kb-sdk-errors.js +1 -1
- package/lib/core/kb-search-client.js +1 -1
- package/lib/core/sdk-client.js +1 -1
- package/lib/errors.js +1 -1
- package/lib/framework/access-error.js +1 -1
- package/lib/framework/build-all-flags.js +1 -1
- package/lib/framework/dryrun.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/preparse.js +1 -1
- package/lib/framework/rate-limit.js +1 -1
- package/lib/framework/raw-flags.js +1 -1
- package/lib/framework/response.js +1 -1
- package/lib/framework/runner-confirmation.js +1 -1
- package/lib/framework/runner-error.js +1 -1
- package/lib/framework/runner.js +1 -1
- package/lib/framework/schema-export.js +1 -1
- package/lib/framework/service-order.js +1 -1
- package/lib/framework/types.js +1 -1
- package/lib/generated/build-info.d.ts +4 -4
- package/lib/generated/build-info.js +1 -1
- package/lib/generated/official-routing.js +1 -1
- package/lib/generated/routing-contract.js +1 -1
- package/lib/help.js +1 -1
- package/lib/postinstall.js +1 -1
- package/lib/runtime/confirmation.js +1 -1
- package/lib/runtime/event.js +1 -1
- package/lib/runtime/index.js +1 -1
- package/lib/runtime/queue.js +1 -1
- package/lib/runtime/resolve.js +1 -1
- package/lib/services/dataset-import/auto-id-runner.js +1 -1
- package/lib/services/dataset-import/excel-reader.js +1 -1
- package/lib/services/dataset-import/image-bytes.js +1 -1
- package/lib/services/dataset-import/image-ooxml.js +1 -1
- package/lib/services/dataset-import/image-runner.js +1 -1
- package/lib/services/dataset-import/metadata.js +1 -1
- package/lib/services/dataset-import/preview.js +1 -1
- package/lib/services/dataset-import/runner.js +1 -1
- package/lib/skills/builtin-skill.js +1 -1
- package/lib/skills/npx-skills-add.js +1 -1
- package/lib/skills/runtime-skill-sync/constants.js +1 -1
- package/lib/skills/runtime-skill-sync/fs-utils.js +1 -1
- package/lib/skills/runtime-skill-sync/hashing.js +1 -1
- package/lib/skills/runtime-skill-sync/install-target.js +1 -1
- package/lib/skills/runtime-skill-sync/links.js +1 -1
- package/lib/skills/runtime-skill-sync/list-local.js +1 -1
- package/lib/skills/runtime-skill-sync/local-files.js +1 -1
- package/lib/skills/runtime-skill-sync/materialize.js +1 -1
- package/lib/skills/runtime-skill-sync/metadata.js +1 -1
- package/lib/skills/runtime-skill-sync/paths.js +1 -1
- package/lib/skills/runtime-skill-sync/push.js +1 -1
- package/lib/skills/runtime-skill-sync/scopes.js +1 -1
- package/lib/skills/runtime-skill-sync/zip-codec.js +1 -1
- package/lib/skills/runtime-skill-sync/zip-package.js +1 -1
- package/lib/skills/runtime-skill-sync.js +1 -1
- package/lib/skills/skill-presence.js +1 -1
- package/lib/utils/access-key-redaction.js +1 -1
- package/lib/utils/apply-jq-filter.js +1 -1
- package/lib/utils/cli-version-check.js +1 -1
- package/lib/utils/cli-version-policy.js +1 -1
- package/lib/utils/logger.js +1 -1
- package/lib/utils/lossless-json.js +1 -1
- package/lib/utils/params.js +1 -1
- package/lib/utils/positive-safe-integer.js +1 -1
- package/lib/utils/redaction.js +1 -1
- package/lib/utils/runtime-user-id.js +1 -1
- package/lib/utils/update-notice.js +1 -1
- package/lib/utils/version.js +1 -1
- package/lib/utils/write-cli-side-channel.js +1 -1
- package/package.json +1 -1
- package/skills/lovrabet/SKILL.md +3 -3
- package/skills/lovrabet/references/lovrabet-schedule-workflow.md +50 -1
- package/skills/lovrabet.manifest.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
const a68_0x400846=a68_0x5c15;(function(_0x3e31da,_0x3cefac){const _0x24588a=a68_0x5c15,_0xd52922=_0x3e31da();while(!![]){try{const _0x5551b2=-parseInt(_0x24588a(0x1d5))/0x1*(parseInt(_0x24588a(0x1cd))/0x2)+-parseInt(_0x24588a(0x1a7))/0x3+-parseInt(_0x24588a(0x1bc))/0x4*(-parseInt(_0x24588a(0x1bf))/0x5)+-parseInt(_0x24588a(0x1f2))/0x6*(-parseInt(_0x24588a(0x1a2))/0x7)+parseInt(_0x24588a(0x1ca))/0x8*(parseInt(_0x24588a(0x1b2))/0x9)+-parseInt(_0x24588a(0x1f7))/0xa*(parseInt(_0x24588a(0x1e4))/0xb)+-parseInt(_0x24588a(0x1d6))/0xc*(-parseInt(_0x24588a(0x1df))/0xd);if(_0x5551b2===_0x3cefac)break;else _0xd52922['push'](_0xd52922['shift']());}catch(_0x1376ae){_0xd52922['push'](_0xd52922['shift']());}}}(a68_0x2d65,0x71100));import{createHash}from'node:crypto';import{existsSync,mkdirSync,readFileSync,renameSync,unlinkSync,writeFileSync}from'node:fs';import{homedir}from'node:os';import{dirname,resolve}from'node:path';import{normalizeServiceTreeManifest,validateServiceTreeManifest}from'@lovrabet/cli-framework';import{PRODUCT_CONFIG}from'../../constant/product.js';import{CliErrors}from'../../errors.js';import{adaptServiceTreeManifestForLegacyFramework}from'../../commands/service/function-name-adapter.js';export const SERVICE_REGISTRY_SCHEMA_VERSION=0x1;export const SERVICE_REGISTRY_FILE_NAME=a68_0x400846(0x1d3);export function getServiceRegistryPath(_0x1e1fba={}){const _0x5b4455=a68_0x400846;return resolve(_0x1e1fba['homeDir']??homedir(),PRODUCT_CONFIG[_0x5b4455(0x1ea)],SERVICE_REGISTRY_FILE_NAME);}export function emptyServiceRegistry(){return{'schemaVersion':SERVICE_REGISTRY_SCHEMA_VERSION,'services':[]};}export function readServiceRegistry(_0x3e0568={}){const _0x16595c=a68_0x400846,_0x5aa676=getServiceRegistryPath(_0x3e0568);if(!existsSync(_0x5aa676))return emptyServiceRegistry();try{const _0x52794a=readFileSync(_0x5aa676,_0x16595c(0x1c6));if(!_0x52794a['trim']())return emptyServiceRegistry();const _0x251a02=JSON[_0x16595c(0x1d8)](_0x52794a);if(_0x251a02[_0x16595c(0x1c7)]!==SERVICE_REGISTRY_SCHEMA_VERSION)throw CliErrors[_0x16595c(0x1fc)](_0x16595c(0x1db)+String(_0x251a02['schemaVersion']),_0x16595c(0x1e3)+_0x5aa676+'.');if(!Array[_0x16595c(0x1b9)](_0x251a02[_0x16595c(0x1af)]))return emptyServiceRegistry();return{'schemaVersion':SERVICE_REGISTRY_SCHEMA_VERSION,'updatedAt':_0x251a02['updatedAt'],'services':_0x251a02[_0x16595c(0x1af)]};}catch(_0x334abf){if(_0x334abf instanceof Error&&_0x334abf[_0x16595c(0x1fa)]===_0x16595c(0x1f6))throw _0x334abf;throw CliErrors[_0x16595c(0x1fc)](_0x16595c(0x1b8)+_0x5aa676,_0x16595c(0x1ab));}}export function writeServiceRegistry(_0x24047c,_0x2c2adc={}){const _0x3ea80f=a68_0x400846,_0x4c3393=getServiceRegistryPath(_0x2c2adc),_0x1f8c71=dirname(_0x4c3393);!existsSync(_0x1f8c71)&&mkdirSync(_0x1f8c71,{'recursive':!![]});const _0xd8a074=_0x4c3393+_0x3ea80f(0x1da);try{writeFileSync(_0xd8a074,JSON[_0x3ea80f(0x1e8)](_0x24047c,null,0x2)+'\x0a',{'encoding':_0x3ea80f(0x1c6),'mode':0x180}),renameSync(_0xd8a074,_0x4c3393);}catch(_0x5471f2){try{unlinkSync(_0xd8a074);}catch{}if(_0x5471f2?.[_0x3ea80f(0x1b6)]===_0x3ea80f(0x1c2))throw CliErrors[_0x3ea80f(0x1fc)](_0x3ea80f(0x1d2)+_0x4c3393);throw _0x5471f2;}return _0x4c3393;}export function loadServiceManifestFromFile(_0x416f98){const _0x35e2cd=a68_0x400846,_0x115631=resolve(_0x416f98);if(!existsSync(_0x115631))throw CliErrors[_0x35e2cd(0x1fc)](_0x35e2cd(0x1cf)+_0x416f98);let _0xcc1da;const _0x5ee894=readFileSync(_0x115631,_0x35e2cd(0x1c6));try{_0xcc1da=JSON[_0x35e2cd(0x1d8)](_0x5ee894);}catch{throw CliErrors[_0x35e2cd(0x1fc)](_0x35e2cd(0x1ac)+_0x416f98,'Fix\x20the\x20JSON\x20syntax\x20and\x20run\x20service\x20validate\x20again.');}const _0x4d3c2b=sha256(_0x5ee894),_0x519cf9=extractLoadedServiceManifests(_0xcc1da,_0x4d3c2b),_0x43d106=aggregateValidationReports(_0x519cf9),_0xe3907e=_0x519cf9[0x0];return{'filePath':_0x115631,'hash':_0x4d3c2b,'kind':isServiceRegistryLike(_0xcc1da)?_0x35e2cd(0x1b5):_0x35e2cd(0x1f0),'manifest':_0xe3907e?.[_0x35e2cd(0x1f0)]??_0xcc1da,'report':_0x43d106,'normalizedManifest':_0x519cf9[_0x35e2cd(0x1d7)]===0x1?_0xe3907e?.[_0x35e2cd(0x1e1)]:undefined,'manifests':_0x519cf9};}export function importServiceManifest(_0x3a52a8,_0xe044c7={}){const _0x1df1d3=a68_0x400846,_0x1af307=loadServiceManifestFromFile(_0x3a52a8);if(!_0x1af307[_0x1df1d3(0x1f3)]['ok'])throw CliErrors[_0x1df1d3(0x1fc)](formatValidationFailure(_0x1af307[_0x1df1d3(0x1f3)]),_0x1df1d3(0x1f4));if(_0x1af307['manifests'][_0x1df1d3(0x1d7)]===0x0)throw CliErrors[_0x1df1d3(0x1fc)](_0x1df1d3(0x1f5),_0x1df1d3(0x1dd));const _0x18c5bc=readServiceRegistry(_0xe044c7),_0x4a4bad=(_0xe044c7['now']??(()=>new Date()))()[_0x1df1d3(0x1a1)](),_0x4f4eb6=[];let _0x347f60=0x0,_0x2289e0=0x0;for(const _0x347bd9 of _0x1af307[_0x1df1d3(0x1e6)]){if(!_0x347bd9['normalizedManifest'])continue;const _0x55235c=_0x347bd9[_0x1df1d3(0x1e1)]['service'][_0x1df1d3(0x1b6)],_0x3ddda4={'serviceCode':_0x55235c,'version':_0x347bd9[_0x1df1d3(0x1e1)]['version'],'importedAt':_0x4a4bad,'source':{'type':_0x1df1d3(0x1b3),'path':_0x1af307[_0x1df1d3(0x1f1)],'hash':_0x347bd9[_0x1df1d3(0x1ed)]},'manifest':_0x347bd9[_0x1df1d3(0x1f0)],'normalizedManifest':_0x347bd9[_0x1df1d3(0x1e1)]},_0x478268=_0x18c5bc[_0x1df1d3(0x1af)][_0x1df1d3(0x19e)](_0x53353d=>_0x53353d[_0x1df1d3(0x1aa)]===_0x55235c);_0x478268>=0x0?(_0x18c5bc['services'][_0x478268]=_0x3ddda4,_0x2289e0++):(_0x18c5bc[_0x1df1d3(0x1af)][_0x1df1d3(0x1a4)](_0x3ddda4),_0x347f60++),_0x4f4eb6['push'](_0x3ddda4);}_0x18c5bc[_0x1df1d3(0x1af)][_0x1df1d3(0x1ba)]((_0x4b4644,_0x634881)=>_0x4b4644[_0x1df1d3(0x1aa)][_0x1df1d3(0x1bd)](_0x634881['serviceCode'])),_0x18c5bc['updatedAt']=_0x4a4bad;const _0x4d91e6=writeServiceRegistry(_0x18c5bc,_0xe044c7);return{'registryPath':_0x4d91e6,'entry':_0x4f4eb6[0x0],'replaced':_0x4f4eb6['length']===0x1?_0x2289e0===0x1:_0x2289e0>0x0,'entries':_0x4f4eb6,'imported':_0x347f60,'updated':_0x2289e0,'serviceCount':_0x18c5bc[_0x1df1d3(0x1af)]['length']};}export function exportServiceManifest(_0x590054,_0x120671,_0x416a85={}){const _0x5bdef2=a68_0x400846,_0x2cc57e=getServiceRegistryPath(_0x416a85),_0x14b750=getLocalServiceEntry(_0x590054,_0x416a85);if(!_0x14b750)throw CliErrors[_0x5bdef2(0x1fc)](_0x5bdef2(0x1bb)+_0x590054,_0x5bdef2(0x1c3));const _0x224303=resolve(_0x120671),_0x5c23d4=dirname(_0x224303);return!existsSync(_0x5c23d4)&&mkdirSync(_0x5c23d4,{'recursive':!![]}),writeFileSync(_0x224303,JSON[_0x5bdef2(0x1e8)](_0x14b750[_0x5bdef2(0x1f0)],null,0x2)+'\x0a',{'encoding':_0x5bdef2(0x1c6),'mode':0x180}),{'registryPath':_0x2cc57e,'filePath':_0x224303,'entry':_0x14b750};}export function removeServiceManifest(_0x34d24f,_0x21524b={}){const _0x2fd4fe=a68_0x400846,_0x4f1fca=readServiceRegistry(_0x21524b),_0x5a718f=_0x34d24f[_0x2fd4fe(0x1dc)](),_0x2c165f=_0x4f1fca[_0x2fd4fe(0x1af)][_0x2fd4fe(0x19e)](_0x41d511=>_0x41d511[_0x2fd4fe(0x1aa)]===_0x5a718f);if(_0x2c165f<0x0)throw CliErrors[_0x2fd4fe(0x1fc)](_0x2fd4fe(0x1bb)+_0x5a718f,'Run\x20lovrabet\x20service\x20list\x20to\x20see\x20imported\x20services.');const [_0x3de329]=_0x4f1fca[_0x2fd4fe(0x1af)][_0x2fd4fe(0x1cb)](_0x2c165f,0x1),_0x362009=(_0x21524b[_0x2fd4fe(0x1cc)]??(()=>new Date()))()['toISOString']();_0x4f1fca[_0x2fd4fe(0x1ad)]=_0x362009;const _0x3b5bb7=writeServiceRegistry(_0x4f1fca,_0x21524b);return{'registryPath':_0x3b5bb7,'entry':_0x3de329,'serviceCount':_0x4f1fca[_0x2fd4fe(0x1af)][_0x2fd4fe(0x1d7)]};}export function listLocalServices(_0x3a0935={}){return readServiceRegistry(_0x3a0935)['services'];}export function getLocalServiceEntry(_0x29a6f3,_0xbfe113={}){const _0x2d5893=a68_0x400846;return readServiceRegistry(_0xbfe113)[_0x2d5893(0x1af)][_0x2d5893(0x1a3)](_0x7e35a=>_0x7e35a['serviceCode']===_0x29a6f3[_0x2d5893(0x1dc)]());}export function listLocalServiceTrees(_0x588b96={}){const _0x20704e=a68_0x400846;return readServiceRegistry(_0x588b96)[_0x20704e(0x1af)][_0x20704e(0x1ec)](_0xdd86b3=>_0xdd86b3[_0x20704e(0x1e1)]);}export function inspectServiceRegistry(_0x286c69={}){const _0x176823=a68_0x400846,_0x6e087=getServiceRegistryPath(_0x286c69);if(!existsSync(_0x6e087))return emptyServiceRegistryInspection(_0x6e087,_0x176823(0x1c1),![]);try{const _0x73a3a9=readFileSync(_0x6e087,_0x176823(0x1c6));if(!_0x73a3a9['trim']())return emptyServiceRegistryInspection(_0x6e087,_0x176823(0x1a5),!![]);const _0x2919b5=JSON[_0x176823(0x1d8)](_0x73a3a9);if(_0x2919b5[_0x176823(0x1c7)]!==SERVICE_REGISTRY_SCHEMA_VERSION)return{...emptyServiceRegistryInspection(_0x6e087,_0x176823(0x1a9),!![]),'schemaVersion':_0x2919b5[_0x176823(0x1c7)],'message':_0x176823(0x1e9)+String(_0x2919b5[_0x176823(0x1c7)])};if(!Array['isArray'](_0x2919b5[_0x176823(0x1af)]))return{...emptyServiceRegistryInspection(_0x6e087,_0x176823(0x1a9),!![]),'schemaVersion':SERVICE_REGISTRY_SCHEMA_VERSION,'updatedAt':_0x2919b5[_0x176823(0x1ad)],'message':_0x176823(0x1e5)};const _0x25713f=_0x2919b5[_0x176823(0x1af)]['map'](summarizeLocalServiceEntry);return{'registryPath':_0x6e087,'exists':!![],'status':'ok','schemaVersion':SERVICE_REGISTRY_SCHEMA_VERSION,'updatedAt':_0x2919b5[_0x176823(0x1ad)],'serviceCount':_0x25713f[_0x176823(0x1d7)],'commandCount':_0x25713f[_0x176823(0x1ae)]((_0x5b5d1d,_0x55e8bf)=>_0x5b5d1d+_0x55e8bf[_0x176823(0x1fd)],0x0),'services':_0x25713f};}catch(_0xb98f6d){return{...emptyServiceRegistryInspection(_0x6e087,_0x176823(0x1a9),!![]),'message':_0xb98f6d instanceof Error?_0xb98f6d[_0x176823(0x1c4)]:String(_0xb98f6d)};}}export function formatValidationFailure(_0x44c9d2){const _0x57e2e0=a68_0x400846,_0x202afd=_0x44c9d2[_0x57e2e0(0x1f8)][_0x57e2e0(0x1ec)](_0x5f39a8=>_0x5f39a8['path']+':\x20'+_0x5f39a8[_0x57e2e0(0x1c4)]);return'Service\x20manifest\x20validation\x20failed:\x0a'+_0x202afd[_0x57e2e0(0x1b4)]('\x0a');}function extractLoadedServiceManifests(_0x432e9c,_0x1e2875){const _0x38e21c=a68_0x400846;if(!isServiceRegistryLike(_0x432e9c)){const _0x2a02da=_0x432e9c,{manifest:_0x3deb75,errors:_0x2ee769}=adaptServiceTreeManifestForLegacyFramework(_0x2a02da),_0x5cabff=validateServiceTreeManifest(_0x3deb75),_0x519e81=mergeValidationErrors(_0x5cabff,_0x2ee769);return[{'manifest':_0x2a02da,'report':_0x519e81,'normalizedManifest':_0x519e81['ok']?normalizeServiceTreeManifest(_0x3deb75):undefined,'sourceHash':_0x1e2875}];}return _0x432e9c['services'][_0x38e21c(0x1ec)]((_0x553f45,_0x2e9e45)=>{const _0x117374=_0x38e21c,_0x3e16d1=isObjectRecord(_0x553f45)?_0x553f45['manifest']:undefined,{manifest:_0x5f0d18,errors:_0x2c5a71}=adaptServiceTreeManifestForLegacyFramework(_0x3e16d1),_0x2935d0=validateServiceTreeManifest(_0x5f0d18),_0x42e303=mergeValidationErrors(_0x2935d0,_0x2c5a71),_0xf1e3da=isObjectRecord(_0x553f45)&&typeof _0x553f45[_0x117374(0x1aa)]===_0x117374(0x1b7)?_0x553f45[_0x117374(0x1aa)]:undefined;return{'manifest':_0x3e16d1,'report':_0x42e303,'normalizedManifest':_0x42e303['ok']?normalizeServiceTreeManifest(_0x5f0d18):undefined,'sourceHash':sha256(JSON[_0x117374(0x1e8)](_0x3e16d1,null,0x2)+'\x0a'),'registryIndex':_0x2e9e45,'registryServiceCode':_0xf1e3da};});}function mergeValidationErrors(_0x1f5528,_0x44b2d4){const _0x4e9bd5=a68_0x400846,_0x1eb4ba=_0x1f5528[_0x4e9bd5(0x1f8)]['map'](_0xeea019=>_0xeea019[_0x4e9bd5(0x1c4)]===_0x4e9bd5(0x1a6)?{..._0xeea019,'message':_0x4e9bd5(0x1a0)}:_0xeea019),_0x24e746=[..._0x44b2d4,..._0x1eb4ba];return{'ok':_0x24e746['length']===0x0,'errors':_0x24e746,'warnings':_0x1f5528[_0x4e9bd5(0x1c8)]};}function aggregateValidationReports(_0x4be5){const _0x174824=a68_0x400846,_0x1e860d=_0x4be5[_0x174824(0x1eb)](_0x4edbf8=>_0x4edbf8['registryIndex']===undefined?_0x4edbf8[_0x174824(0x1f3)][_0x174824(0x1f8)]:_0x4edbf8['report']['errors'][_0x174824(0x1ec)](_0x5743da=>({..._0x5743da,'path':prefixRegistryIssuePath(_0x4edbf8[_0x174824(0x1d0)],_0x5743da[_0x174824(0x1e0)])}))),_0x2d169d=_0x4be5[_0x174824(0x1eb)](_0x38e69d=>_0x38e69d[_0x174824(0x1d0)]===undefined?_0x38e69d[_0x174824(0x1f3)][_0x174824(0x1c8)]:_0x38e69d[_0x174824(0x1f3)][_0x174824(0x1c8)][_0x174824(0x1ec)](_0x29b0ba=>({..._0x29b0ba,'path':prefixRegistryIssuePath(_0x38e69d[_0x174824(0x1d0)],_0x29b0ba[_0x174824(0x1e0)])})));return{'ok':_0x1e860d[_0x174824(0x1d7)]===0x0,'errors':_0x1e860d,'warnings':_0x2d169d};}function prefixRegistryIssuePath(_0x2986bc,_0x480c8d){const _0x183b67=a68_0x400846;if(_0x480c8d==='$')return _0x183b67(0x1d4)+_0x2986bc+_0x183b67(0x1d9);if(_0x480c8d[_0x183b67(0x1f9)]('$.'))return _0x183b67(0x1d4)+_0x2986bc+'].manifest'+_0x480c8d[_0x183b67(0x1c5)](0x1);if(_0x480c8d['startsWith']('$['))return'$.services['+_0x2986bc+_0x183b67(0x1d9)+_0x480c8d[_0x183b67(0x1c5)](0x1);return _0x183b67(0x1d4)+_0x2986bc+_0x183b67(0x1fb)+_0x480c8d;}function isServiceRegistryLike(_0xf6038){const _0xad8795=a68_0x400846;return isObjectRecord(_0xf6038)&&_0xf6038[_0xad8795(0x1c7)]===SERVICE_REGISTRY_SCHEMA_VERSION&&Array[_0xad8795(0x1b9)](_0xf6038[_0xad8795(0x1af)]);}function a68_0x5c15(_0x32fa23,_0x550af9){_0x32fa23=_0x32fa23-0x19e;const _0x2d654d=a68_0x2d65();let _0x5c15b5=_0x2d654d[_0x32fa23];return _0x5c15b5;}function isObjectRecord(_0x3330e3){const _0x4714c6=a68_0x400846;return Boolean(_0x3330e3)&&typeof _0x3330e3==='object'&&!Array[_0x4714c6(0x1b9)](_0x3330e3);}function emptyServiceRegistryInspection(_0xca5a9f,_0x392bba,_0x385639){return{'registryPath':_0xca5a9f,'exists':_0x385639,'status':_0x392bba,'serviceCount':0x0,'commandCount':0x0,'services':[]};}function summarizeLocalServiceEntry(_0x294746){const _0x2dce30=a68_0x400846,_0x380013=_0x294746['normalizedManifest'],_0x1e088d=_0x380013[_0x2dce30(0x1d1)][_0x2dce30(0x1ec)](_0x32c2a1=>({'path':_0x32c2a1[_0x2dce30(0x1c0)],'description':_0x32c2a1[_0x2dce30(0x1e2)],'risk':_0x32c2a1[_0x2dce30(0x1b0)],'targetKind':_0x32c2a1['target'][_0x2dce30(0x1ef)],'targetCommand':_0x32c2a1[_0x2dce30(0x19f)][_0x2dce30(0x1e7)]}));return{'serviceCode':_0x294746['serviceCode'],'name':_0x380013[_0x2dce30(0x1b1)][_0x2dce30(0x1fa)],'description':_0x380013[_0x2dce30(0x1b1)][_0x2dce30(0x1e2)],'version':_0x294746[_0x2dce30(0x1a8)],'importedAt':_0x294746['importedAt'],'source':_0x294746[_0x2dce30(0x1ce)],'commandCount':_0x1e088d[_0x2dce30(0x1d7)],'commands':_0x1e088d};}function a68_0x2d65(){const _0x57624b=['risk','service','18otfrYU','file','join','registry','code','string','Invalid\x20service\x20registry\x20JSON:\x20','isArray','sort','Local\x20service\x20not\x20found:\x20','25476uwgiAg','localeCompare','digest','155lkVVKs','cliPath','missing','ENOENT','Run\x20lovrabet\x20service\x20list\x20to\x20see\x20imported\x20services.','message','slice','utf8','schemaVersion','warnings','hex','491192DrhZPn','splice','now','44658LhptfU','source','Service\x20manifest\x20file\x20not\x20found:\x20','registryIndex','commands','Cannot\x20write\x20service\x20registry:\x20','service.json','$.services[','17IwGrDW','51432IynKny','length','parse','].manifest','.tmp','Unsupported\x20service\x20registry\x20schemaVersion:\x20','trim','Add\x20at\x20least\x20one\x20service\x20manifest,\x20then\x20run\x20service\x20import\x20again.','sha256','1846waBXZX','path','normalizedManifest','description','Remove\x20or\x20migrate\x20','11ONLddb','services\x20must\x20be\x20an\x20array','manifests','command','stringify','Unsupported\x20schemaVersion:\x20','homeDirName','flatMap','map','sourceHash','update','kind','manifest','filePath','4860kVuksZ','report','Fix\x20the\x20service\x20manifest\x20and\x20run\x20service\x20validate\x20again.','Service\x20registry\x20has\x20no\x20services\x20to\x20import.','CliError','3073690JpWBLy','errors','startsWith','name','].manifest.','validation','commandCount','findIndex','target','bff\x20target\x20requires\x20functionName.','toISOString','6356tSyxtg','find','push','empty','bff\x20target\x20requires\x20bffCode,\x20bffId,\x20or\x20scriptName.','1542789hyRWOH','version','invalid','serviceCode','Fix\x20the\x20JSON\x20file\x20or\x20move\x20it\x20aside\x20and\x20import\x20services\x20again.','Invalid\x20service\x20manifest\x20JSON:\x20','updatedAt','reduce','services'];a68_0x2d65=function(){return _0x57624b;};return a68_0x2d65();}function sha256(_0x20e58f){const _0x185235=a68_0x400846;return createHash(_0x185235(0x1de))[_0x185235(0x1ee)](_0x20e58f)[_0x185235(0x1be)](_0x185235(0x1c9));}
|
|
1
|
+
function a68_0x10cf(_0x52ee91,_0x530808){_0x52ee91=_0x52ee91-0x179;const _0x4a2eea=a68_0x4a2e();let _0x10cfb3=_0x4a2eea[_0x52ee91];return _0x10cfb3;}const a68_0x43e5ac=a68_0x10cf;(function(_0x3dd7f0,_0x227191){const _0x3b80b3=a68_0x10cf,_0x58bc15=_0x3dd7f0();while(!![]){try{const _0x51b46e=parseInt(_0x3b80b3(0x1a0))/0x1+parseInt(_0x3b80b3(0x1d0))/0x2+-parseInt(_0x3b80b3(0x1b6))/0x3*(parseInt(_0x3b80b3(0x1c9))/0x4)+parseInt(_0x3b80b3(0x1cc))/0x5*(parseInt(_0x3b80b3(0x188))/0x6)+parseInt(_0x3b80b3(0x1b3))/0x7*(parseInt(_0x3b80b3(0x190))/0x8)+-parseInt(_0x3b80b3(0x1a5))/0x9+-parseInt(_0x3b80b3(0x17d))/0xa;if(_0x51b46e===_0x227191)break;else _0x58bc15['push'](_0x58bc15['shift']());}catch(_0x5ed286){_0x58bc15['push'](_0x58bc15['shift']());}}}(a68_0x4a2e,0xd83b6));import{createHash}from'node:crypto';import{existsSync,mkdirSync,readFileSync,renameSync,unlinkSync,writeFileSync}from'node:fs';import{homedir}from'node:os';import{dirname,resolve}from'node:path';import{normalizeServiceTreeManifest,validateServiceTreeManifest}from'@lovrabet/cli-framework';import{PRODUCT_CONFIG}from'../../constant/product.js';import{CliErrors}from'../../errors.js';import{adaptServiceTreeManifestForLegacyFramework}from'../../commands/service/function-name-adapter.js';export const SERVICE_REGISTRY_SCHEMA_VERSION=0x1;export const SERVICE_REGISTRY_FILE_NAME=a68_0x43e5ac(0x1c5);export function getServiceRegistryPath(_0x14d60e={}){const _0x43e76b=a68_0x43e5ac;return resolve(_0x14d60e[_0x43e76b(0x1af)]??homedir(),PRODUCT_CONFIG[_0x43e76b(0x1b8)],SERVICE_REGISTRY_FILE_NAME);}export function emptyServiceRegistry(){return{'schemaVersion':SERVICE_REGISTRY_SCHEMA_VERSION,'services':[]};}export function readServiceRegistry(_0x412d3c={}){const _0x433303=a68_0x43e5ac,_0x37ef5c=getServiceRegistryPath(_0x412d3c);if(!existsSync(_0x37ef5c))return emptyServiceRegistry();try{const _0x16789f=readFileSync(_0x37ef5c,_0x433303(0x19e));if(!_0x16789f[_0x433303(0x1b9)]())return emptyServiceRegistry();const _0x58a4c4=JSON[_0x433303(0x181)](_0x16789f);if(_0x58a4c4['schemaVersion']!==SERVICE_REGISTRY_SCHEMA_VERSION)throw CliErrors[_0x433303(0x1ac)]('Unsupported\x20service\x20registry\x20schemaVersion:\x20'+String(_0x58a4c4['schemaVersion']),_0x433303(0x187)+_0x37ef5c+'.');if(!Array[_0x433303(0x1a2)](_0x58a4c4[_0x433303(0x1a9)]))return emptyServiceRegistry();return{'schemaVersion':SERVICE_REGISTRY_SCHEMA_VERSION,'updatedAt':_0x58a4c4[_0x433303(0x183)],'services':_0x58a4c4[_0x433303(0x1a9)]};}catch(_0x38f6d0){if(_0x38f6d0 instanceof Error&&_0x38f6d0[_0x433303(0x185)]===_0x433303(0x1cb))throw _0x38f6d0;throw CliErrors[_0x433303(0x1ac)](_0x433303(0x182)+_0x37ef5c,'Fix\x20the\x20JSON\x20file\x20or\x20move\x20it\x20aside\x20and\x20import\x20services\x20again.');}}export function writeServiceRegistry(_0x40b628,_0xb04849={}){const _0x553990=a68_0x43e5ac,_0x459c80=getServiceRegistryPath(_0xb04849),_0x339b90=dirname(_0x459c80);!existsSync(_0x339b90)&&mkdirSync(_0x339b90,{'recursive':!![]});const _0x26ca83=_0x459c80+_0x553990(0x1bd);try{writeFileSync(_0x26ca83,JSON[_0x553990(0x1a6)](_0x40b628,null,0x2)+'\x0a',{'encoding':_0x553990(0x19e),'mode':0x180}),renameSync(_0x26ca83,_0x459c80);}catch(_0x1534e8){try{unlinkSync(_0x26ca83);}catch{}if(_0x1534e8?.[_0x553990(0x1b4)]===_0x553990(0x19c))throw CliErrors['validation'](_0x553990(0x1a8)+_0x459c80);throw _0x1534e8;}return _0x459c80;}export function loadServiceManifestFromFile(_0xcb4054){const _0x31ee8e=a68_0x43e5ac,_0xc0b04=resolve(_0xcb4054);if(!existsSync(_0xc0b04))throw CliErrors[_0x31ee8e(0x1ac)](_0x31ee8e(0x19f)+_0xcb4054);let _0xceba5d;const _0x4ba2a3=readFileSync(_0xc0b04,_0x31ee8e(0x19e));try{_0xceba5d=JSON[_0x31ee8e(0x181)](_0x4ba2a3);}catch{throw CliErrors[_0x31ee8e(0x1ac)](_0x31ee8e(0x189)+_0xcb4054,_0x31ee8e(0x199));}const _0x316f73=sha256(_0x4ba2a3),_0x2bf3ed=extractLoadedServiceManifests(_0xceba5d,_0x316f73),_0x1ff05c=aggregateValidationReports(_0x2bf3ed),_0x4cfba9=_0x2bf3ed[0x0];return{'filePath':_0xc0b04,'hash':_0x316f73,'kind':isServiceRegistryLike(_0xceba5d)?_0x31ee8e(0x1c8):_0x31ee8e(0x197),'manifest':_0x4cfba9?.[_0x31ee8e(0x197)]??_0xceba5d,'report':_0x1ff05c,'normalizedManifest':_0x2bf3ed[_0x31ee8e(0x1b0)]===0x1?_0x4cfba9?.[_0x31ee8e(0x1ae)]:undefined,'manifests':_0x2bf3ed};}export function importServiceManifest(_0x53da2e,_0x12b60c={}){const _0x2470ce=a68_0x43e5ac,_0x4f90e0=loadServiceManifestFromFile(_0x53da2e);if(!_0x4f90e0['report']['ok'])throw CliErrors[_0x2470ce(0x1ac)](formatValidationFailure(_0x4f90e0[_0x2470ce(0x1c4)]),_0x2470ce(0x18e));if(_0x4f90e0[_0x2470ce(0x18a)]['length']===0x0)throw CliErrors[_0x2470ce(0x1ac)](_0x2470ce(0x19d),_0x2470ce(0x1bc));const _0x3c6dd7=readServiceRegistry(_0x12b60c),_0x362b4a=(_0x12b60c['now']??(()=>new Date()))()[_0x2470ce(0x1ca)](),_0x168fe6=[];let _0x2b1861=0x0,_0x54a85f=0x0;for(const _0x459999 of _0x4f90e0['manifests']){if(!_0x459999[_0x2470ce(0x1ae)])continue;const _0x2fa86b=_0x459999[_0x2470ce(0x1ae)][_0x2470ce(0x1aa)][_0x2470ce(0x1b4)],_0x56b0fb={'serviceCode':_0x2fa86b,'version':_0x459999[_0x2470ce(0x1ae)][_0x2470ce(0x1c3)],'importedAt':_0x362b4a,'source':{'type':'file','path':_0x4f90e0[_0x2470ce(0x191)],'hash':_0x459999[_0x2470ce(0x179)]},'manifest':_0x459999['manifest'],'normalizedManifest':_0x459999[_0x2470ce(0x1ae)]},_0x1bcabb=_0x3c6dd7[_0x2470ce(0x1a9)][_0x2470ce(0x180)](_0x2a3fa9=>_0x2a3fa9['serviceCode']===_0x2fa86b);_0x1bcabb>=0x0?(_0x3c6dd7[_0x2470ce(0x1a9)][_0x1bcabb]=_0x56b0fb,_0x54a85f++):(_0x3c6dd7[_0x2470ce(0x1a9)][_0x2470ce(0x17f)](_0x56b0fb),_0x2b1861++),_0x168fe6[_0x2470ce(0x17f)](_0x56b0fb);}_0x3c6dd7[_0x2470ce(0x1a9)][_0x2470ce(0x1a1)]((_0x4b661e,_0x35e36e)=>_0x4b661e[_0x2470ce(0x195)]['localeCompare'](_0x35e36e['serviceCode'])),_0x3c6dd7['updatedAt']=_0x362b4a;const _0x33a773=writeServiceRegistry(_0x3c6dd7,_0x12b60c);return{'registryPath':_0x33a773,'entry':_0x168fe6[0x0],'replaced':_0x168fe6[_0x2470ce(0x1b0)]===0x1?_0x54a85f===0x1:_0x54a85f>0x0,'entries':_0x168fe6,'imported':_0x2b1861,'updated':_0x54a85f,'serviceCount':_0x3c6dd7[_0x2470ce(0x1a9)]['length']};}export function exportServiceManifest(_0x276d37,_0x452293,_0x4736c8={}){const _0x169043=a68_0x43e5ac,_0x4094d6=getServiceRegistryPath(_0x4736c8),_0x5cf7b9=getLocalServiceEntry(_0x276d37,_0x4736c8);if(!_0x5cf7b9)throw CliErrors[_0x169043(0x1ac)](_0x169043(0x184)+_0x276d37,_0x169043(0x1bb));const _0x2bb6a2=resolve(_0x452293),_0x15070c=dirname(_0x2bb6a2);return!existsSync(_0x15070c)&&mkdirSync(_0x15070c,{'recursive':!![]}),writeFileSync(_0x2bb6a2,JSON['stringify'](_0x5cf7b9[_0x169043(0x197)],null,0x2)+'\x0a',{'encoding':_0x169043(0x19e),'mode':0x180}),{'registryPath':_0x4094d6,'filePath':_0x2bb6a2,'entry':_0x5cf7b9};}export function removeServiceManifest(_0x4f7bf9,_0x2b08df={}){const _0x4d61fa=a68_0x43e5ac,_0x330b35=readServiceRegistry(_0x2b08df),_0xab235f=_0x4f7bf9[_0x4d61fa(0x1b9)](),_0x54b837=_0x330b35['services'][_0x4d61fa(0x180)](_0x17422b=>_0x17422b[_0x4d61fa(0x195)]===_0xab235f);if(_0x54b837<0x0)throw CliErrors[_0x4d61fa(0x1ac)](_0x4d61fa(0x184)+_0xab235f,_0x4d61fa(0x1bb));const [_0x5acebe]=_0x330b35[_0x4d61fa(0x1a9)][_0x4d61fa(0x17c)](_0x54b837,0x1),_0x3ed79c=(_0x2b08df[_0x4d61fa(0x19b)]??(()=>new Date()))()[_0x4d61fa(0x1ca)]();_0x330b35[_0x4d61fa(0x183)]=_0x3ed79c;const _0x3932b9=writeServiceRegistry(_0x330b35,_0x2b08df);return{'registryPath':_0x3932b9,'entry':_0x5acebe,'serviceCount':_0x330b35[_0x4d61fa(0x1a9)]['length']};}export function listLocalServices(_0x487173={}){const _0x324ef7=a68_0x43e5ac;return readServiceRegistry(_0x487173)[_0x324ef7(0x1a9)];}export function getLocalServiceEntry(_0xa8ee4a,_0x4d0ef7={}){const _0x36b5c1=a68_0x43e5ac;return readServiceRegistry(_0x4d0ef7)['services'][_0x36b5c1(0x1c6)](_0x2ba1=>_0x2ba1[_0x36b5c1(0x195)]===_0xa8ee4a[_0x36b5c1(0x1b9)]());}export function listLocalServiceTrees(_0x26962a={}){const _0x4573b5=a68_0x43e5ac;return readServiceRegistry(_0x26962a)[_0x4573b5(0x1a9)][_0x4573b5(0x1ba)](_0x51d044=>_0x51d044['normalizedManifest']);}export function inspectServiceRegistry(_0x4f6c30={}){const _0x556a97=a68_0x43e5ac,_0x1c2956=getServiceRegistryPath(_0x4f6c30);if(!existsSync(_0x1c2956))return emptyServiceRegistryInspection(_0x1c2956,_0x556a97(0x193),![]);try{const _0x1c1837=readFileSync(_0x1c2956,_0x556a97(0x19e));if(!_0x1c1837[_0x556a97(0x1b9)]())return emptyServiceRegistryInspection(_0x1c2956,_0x556a97(0x1b5),!![]);const _0xce1c61=JSON['parse'](_0x1c1837);if(_0xce1c61[_0x556a97(0x1b7)]!==SERVICE_REGISTRY_SCHEMA_VERSION)return{...emptyServiceRegistryInspection(_0x1c2956,_0x556a97(0x18b),!![]),'schemaVersion':_0xce1c61[_0x556a97(0x1b7)],'message':_0x556a97(0x1c7)+String(_0xce1c61['schemaVersion'])};if(!Array[_0x556a97(0x1a2)](_0xce1c61['services']))return{...emptyServiceRegistryInspection(_0x1c2956,_0x556a97(0x18b),!![]),'schemaVersion':SERVICE_REGISTRY_SCHEMA_VERSION,'updatedAt':_0xce1c61[_0x556a97(0x183)],'message':'services\x20must\x20be\x20an\x20array'};const _0x431a7f=_0xce1c61['services'][_0x556a97(0x1ba)](summarizeLocalServiceEntry);return{'registryPath':_0x1c2956,'exists':!![],'status':'ok','schemaVersion':SERVICE_REGISTRY_SCHEMA_VERSION,'updatedAt':_0xce1c61['updatedAt'],'serviceCount':_0x431a7f[_0x556a97(0x1b0)],'commandCount':_0x431a7f[_0x556a97(0x198)]((_0x335450,_0x8b745e)=>_0x335450+_0x8b745e[_0x556a97(0x18f)],0x0),'services':_0x431a7f};}catch(_0x356674){return{...emptyServiceRegistryInspection(_0x1c2956,_0x556a97(0x18b),!![]),'message':_0x356674 instanceof Error?_0x356674['message']:String(_0x356674)};}}export function formatValidationFailure(_0x44a6be){const _0x5240f2=a68_0x43e5ac,_0xa2c5b6=_0x44a6be[_0x5240f2(0x19a)][_0x5240f2(0x1ba)](_0x2e4295=>_0x2e4295[_0x5240f2(0x192)]+':\x20'+_0x2e4295[_0x5240f2(0x1b1)]);return _0x5240f2(0x1be)+_0xa2c5b6['join']('\x0a');}function extractLoadedServiceManifests(_0x4ca4ea,_0x3209a0){const _0x3742bc=a68_0x43e5ac;if(!isServiceRegistryLike(_0x4ca4ea)){const _0x5f423a=_0x4ca4ea,{manifest:_0x4dad0e,errors:_0x5caafc}=adaptServiceTreeManifestForLegacyFramework(_0x5f423a),_0x521b9a=validateServiceTreeManifest(_0x4dad0e),_0x4be40b=mergeValidationErrors(_0x521b9a,_0x5caafc);return[{'manifest':_0x5f423a,'report':_0x4be40b,'normalizedManifest':_0x4be40b['ok']?normalizeServiceTreeManifest(_0x4dad0e):undefined,'sourceHash':_0x3209a0}];}return _0x4ca4ea[_0x3742bc(0x1a9)]['map']((_0x5d9022,_0x2de295)=>{const _0x101f02=_0x3742bc,_0x51fb16=isObjectRecord(_0x5d9022)?_0x5d9022[_0x101f02(0x197)]:undefined,{manifest:_0x2fe76e,errors:_0x2b0c6e}=adaptServiceTreeManifestForLegacyFramework(_0x51fb16),_0x17eaad=validateServiceTreeManifest(_0x2fe76e),_0x1a59e9=mergeValidationErrors(_0x17eaad,_0x2b0c6e),_0x5792be=isObjectRecord(_0x5d9022)&&typeof _0x5d9022['serviceCode']===_0x101f02(0x17b)?_0x5d9022[_0x101f02(0x195)]:undefined;return{'manifest':_0x51fb16,'report':_0x1a59e9,'normalizedManifest':_0x1a59e9['ok']?normalizeServiceTreeManifest(_0x2fe76e):undefined,'sourceHash':sha256(JSON[_0x101f02(0x1a6)](_0x51fb16,null,0x2)+'\x0a'),'registryIndex':_0x2de295,'registryServiceCode':_0x5792be};});}function mergeValidationErrors(_0x549da5,_0x25899f){const _0x437249=a68_0x43e5ac,_0x527952=_0x549da5['errors'][_0x437249(0x1ba)](_0x1158f9=>_0x1158f9[_0x437249(0x1b1)]===_0x437249(0x186)?{..._0x1158f9,'message':_0x437249(0x1c0)}:_0x1158f9),_0x3499f7=[..._0x25899f,..._0x527952];return{'ok':_0x3499f7['length']===0x0,'errors':_0x3499f7,'warnings':_0x549da5[_0x437249(0x1a7)]};}function aggregateValidationReports(_0x3556d3){const _0x1c205b=a68_0x43e5ac,_0x482964=_0x3556d3[_0x1c205b(0x17e)](_0x3edab3=>_0x3edab3['registryIndex']===undefined?_0x3edab3[_0x1c205b(0x1c4)][_0x1c205b(0x19a)]:_0x3edab3['report'][_0x1c205b(0x19a)][_0x1c205b(0x1ba)](_0x15bffc=>({..._0x15bffc,'path':prefixRegistryIssuePath(_0x3edab3[_0x1c205b(0x1b2)],_0x15bffc[_0x1c205b(0x192)])}))),_0x507151=_0x3556d3[_0x1c205b(0x17e)](_0x2cf93d=>_0x2cf93d[_0x1c205b(0x1b2)]===undefined?_0x2cf93d[_0x1c205b(0x1c4)]['warnings']:_0x2cf93d[_0x1c205b(0x1c4)][_0x1c205b(0x1a7)][_0x1c205b(0x1ba)](_0x50d74c=>({..._0x50d74c,'path':prefixRegistryIssuePath(_0x2cf93d[_0x1c205b(0x1b2)],_0x50d74c['path'])})));return{'ok':_0x482964[_0x1c205b(0x1b0)]===0x0,'errors':_0x482964,'warnings':_0x507151};}function prefixRegistryIssuePath(_0x4e1773,_0x4d376e){const _0x16a244=a68_0x43e5ac;if(_0x4d376e==='$')return _0x16a244(0x1a3)+_0x4e1773+_0x16a244(0x18c);if(_0x4d376e[_0x16a244(0x1cf)]('$.'))return'$.services['+_0x4e1773+_0x16a244(0x18c)+_0x4d376e['slice'](0x1);if(_0x4d376e[_0x16a244(0x1cf)]('$['))return'$.services['+_0x4e1773+_0x16a244(0x18c)+_0x4d376e[_0x16a244(0x1ad)](0x1);return _0x16a244(0x1a3)+_0x4e1773+_0x16a244(0x1ce)+_0x4d376e;}function isServiceRegistryLike(_0x4bff0c){const _0x1370cf=a68_0x43e5ac;return isObjectRecord(_0x4bff0c)&&_0x4bff0c[_0x1370cf(0x1b7)]===SERVICE_REGISTRY_SCHEMA_VERSION&&Array[_0x1370cf(0x1a2)](_0x4bff0c[_0x1370cf(0x1a9)]);}function isObjectRecord(_0x4ed704){const _0x21a04f=a68_0x43e5ac;return Boolean(_0x4ed704)&&typeof _0x4ed704===_0x21a04f(0x1c1)&&!Array['isArray'](_0x4ed704);}function emptyServiceRegistryInspection(_0x1ce757,_0x3b385b,_0x3c9906){return{'registryPath':_0x1ce757,'exists':_0x3c9906,'status':_0x3b385b,'serviceCount':0x0,'commandCount':0x0,'services':[]};}function a68_0x4a2e(){const _0x294b32=['missing','description','serviceCode','update','manifest','reduce','Fix\x20the\x20JSON\x20syntax\x20and\x20run\x20service\x20validate\x20again.','errors','now','ENOENT','Service\x20registry\x20has\x20no\x20services\x20to\x20import.','utf8','Service\x20manifest\x20file\x20not\x20found:\x20','844522dcVsxu','sort','isArray','$.services[','command','10377279KzaklR','stringify','warnings','Cannot\x20write\x20service\x20registry:\x20','services','service','source','validation','slice','normalizedManifest','homeDir','length','message','registryIndex','2282jGxODp','code','empty','205278MVfzmI','schemaVersion','homeDirName','trim','map','Run\x20lovrabet\x20service\x20list\x20to\x20see\x20imported\x20services.','Add\x20at\x20least\x20one\x20service\x20manifest,\x20then\x20run\x20service\x20import\x20again.','.tmp','Service\x20manifest\x20validation\x20failed:\x0a','importedAt','bff\x20target\x20requires\x20functionName.','object','commands','version','report','service.json','find','Unsupported\x20schemaVersion:\x20','registry','48gHrGjS','toISOString','CliError','6461245XlPfkx','cliPath','].manifest.','startsWith','1944308jCuPhu','sourceHash','sha256','string','splice','3397240kZSsbQ','flatMap','push','findIndex','parse','Invalid\x20service\x20registry\x20JSON:\x20','updatedAt','Local\x20service\x20not\x20found:\x20','name','bff\x20target\x20requires\x20bffCode,\x20bffId,\x20or\x20scriptName.','Remove\x20or\x20migrate\x20','6RBZKCc','Invalid\x20service\x20manifest\x20JSON:\x20','manifests','invalid','].manifest','hex','Fix\x20the\x20service\x20manifest\x20and\x20run\x20service\x20validate\x20again.','commandCount','2224YGtenn','filePath','path'];a68_0x4a2e=function(){return _0x294b32;};return a68_0x4a2e();}function summarizeLocalServiceEntry(_0x46db18){const _0xb821e5=a68_0x43e5ac,_0xe5597b=_0x46db18[_0xb821e5(0x1ae)],_0xe76981=_0xe5597b[_0xb821e5(0x1c2)][_0xb821e5(0x1ba)](_0x2070b9=>({'path':_0x2070b9[_0xb821e5(0x1cd)],'description':_0x2070b9['description'],'risk':_0x2070b9['risk'],'targetKind':_0x2070b9['target']['kind'],'targetCommand':_0x2070b9['target'][_0xb821e5(0x1a4)]}));return{'serviceCode':_0x46db18[_0xb821e5(0x195)],'name':_0xe5597b[_0xb821e5(0x1aa)][_0xb821e5(0x185)],'description':_0xe5597b[_0xb821e5(0x1aa)][_0xb821e5(0x194)],'version':_0x46db18['version'],'importedAt':_0x46db18[_0xb821e5(0x1bf)],'source':_0x46db18[_0xb821e5(0x1ab)],'commandCount':_0xe76981['length'],'commands':_0xe76981};}function sha256(_0x108c98){const _0x576913=a68_0x43e5ac;return createHash(_0x576913(0x17a))[_0x576913(0x196)](_0x108c98)['digest'](_0x576913(0x18d));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a69_0x326355=a69_0x4595;(function(_0x3309ad,_0x32f9f2){const _0xbb41fb=a69_0x4595,_0x5336a0=_0x3309ad();while(!![]){try{const _0x3a327d=-parseInt(_0xbb41fb(0x91))/0x1*(-parseInt(_0xbb41fb(0x95))/0x2)+-parseInt(_0xbb41fb(0x88))/0x3+-parseInt(_0xbb41fb(0x92))/0x4*(-parseInt(_0xbb41fb(0x99))/0x5)+-parseInt(_0xbb41fb(0x8d))/0x6+-parseInt(_0xbb41fb(0x81))/0x7*(parseInt(_0xbb41fb(0x9f))/0x8)+parseInt(_0xbb41fb(0x8f))/0x9*(parseInt(_0xbb41fb(0x98))/0xa)+parseInt(_0xbb41fb(0x82))/0xb*(parseInt(_0xbb41fb(0xa1))/0xc);if(_0x3a327d===_0x32f9f2)break;else _0x5336a0['push'](_0x5336a0['shift']());}catch(_0x403da0){_0x5336a0['push'](_0x5336a0['shift']());}}}(a69_0x1097,0x6e6bf));import{existsSync,lstatSync,mkdirSync,writeFileSync}from'node:fs';import{dirname,resolve}from'node:path';import{CliErrors}from'../../../errors.js';import{writeCliSideChannelLine}from'../../../utils/write-cli-side-channel.js';import{CREATE_NAME_FLAG,FORCE_FLAG,TARGET_FLAG,TYPE_FLAG}from'../flags.js';import{DEFAULT_SKILL_TARGET,renderSkillTemplate}from'../templates.js';function a69_0x1097(){const _0x5748af=['str','151400ouiUcO','20jRLmOp','isSymbolicLink','Create\x20a\x20local\x20self-contained\x20runtime\x20Skill\x20draft','bool','type','force','5552akSqFa','Skill\x20path\x20already\x20exists\x20and\x20is\x20not\x20a\x20writable\x20directory:\x20','24XXzGRU','Omitting\x20--type\x20is\x20deprecated;\x20defaulting\x20to\x20write\x20for\x20compatibility.\x20Pass\x20--type\x20read\x20or\x20--type\x20write\x20explicitly.','map','WRITE','validation','7875zptKhv','4342459ExtrjF','Pass\x20--force\x20to\x20overwrite\x20generated\x20template\x20files.','name','skillDir','rendered','isDirectory','2252658SUOQlR','skillName','trim','path','target','1085754uBsKMf','content','342hjSpxT','files','17104kgMpwN','406632GYsBTh','utf8','skill','46SCEfxA','Skill\x20directory\x20already\x20exists:\x20'];a69_0x1097=function(){return _0x5748af;};return a69_0x1097();}export const createCommand={'service':a69_0x326355(0x94),'command':'create','description':a69_0x326355(0x9b),'risk':'read','requiresAuth':![],'requiresAppCode':![],'flags':[CREATE_NAME_FLAG,TYPE_FLAG,TARGET_FLAG,FORCE_FLAG],async 'dryRun'(_0x5018a0){const _0x59bd67=a69_0x326355,_0x39f30c=buildSkillCreatePlan(_0x5018a0[_0x59bd67(0x97)](_0x59bd67(0x84)),_0x5018a0[_0x59bd67(0x97)]('type'),_0x5018a0[_0x59bd67(0x97)]('target'));return{'method':_0x59bd67(0x7f),'url':_0x39f30c[_0x59bd67(0x85)],'body':{'skillName':_0x39f30c[_0x59bd67(0x86)][_0x59bd67(0x89)],'type':_0x39f30c[_0x59bd67(0x86)]['type'],'selfContained':!![],'files':_0x39f30c[_0x59bd67(0x86)]['files'][_0x59bd67(0x7e)](_0x21ff3b=>_0x21ff3b[_0x59bd67(0x8b)])},'description':'Create\x20a\x20local\x20runtime\x20Skill\x20draft\x20without\x20uploading\x20or\x20publishing\x20it.'};},async 'execute'(_0x203891){const _0x37d614=a69_0x326355,_0x152d73=buildSkillCreatePlan(_0x203891[_0x37d614(0x97)]('name'),_0x203891[_0x37d614(0x97)](_0x37d614(0x9d)),_0x203891[_0x37d614(0x97)](_0x37d614(0x8c)));return writeSkillDraft(_0x152d73,_0x203891[_0x37d614(0x9c)](_0x37d614(0x9e))),{'ok':!![],'data':{'skillName':_0x152d73['rendered'][_0x37d614(0x89)],'type':_0x152d73[_0x37d614(0x86)][_0x37d614(0x9d)],'dir':_0x152d73['skillDir'],'files':_0x152d73[_0x37d614(0x86)][_0x37d614(0x90)]['map'](_0x3e19f3=>_0x3e19f3[_0x37d614(0x8b)])},'message':'Created\x20local\x20Skill\x20draft\x20'+_0x152d73[_0x37d614(0x86)][_0x37d614(0x89)]};}};function buildSkillCreatePlan(_0x3f15da,_0x5cafc8,_0x2cd6b9){const _0x510c81=a69_0x326355,_0x14f576=_0x5cafc8[_0x510c81(0x8a)](),_0x3acc3b=renderSkillTemplate({'skillName':_0x3f15da,'type':_0x14f576});!_0x14f576&&writeCliSideChannelLine(_0x510c81(0x7d));const _0x3eec63=resolve(normalizeSkillTarget(_0x2cd6b9));return{'rendered':_0x3acc3b,'targetRoot':_0x3eec63,'skillDir':resolve(_0x3eec63,_0x3acc3b[_0x510c81(0x89)])};}function a69_0x4595(_0x43874c,_0xc014c4){_0x43874c=_0x43874c-0x7d;const _0x109729=a69_0x1097();let _0x459541=_0x109729[_0x43874c];return _0x459541;}function normalizeSkillTarget(_0xd19662){const _0x527943=a69_0x326355;return(_0xd19662||DEFAULT_SKILL_TARGET)[_0x527943(0x8a)]()||DEFAULT_SKILL_TARGET;}function writeSkillDraft(_0x135711,_0x3ccf5c){const _0x21ee9c=a69_0x326355;if(existsSync(_0x135711[_0x21ee9c(0x85)])){const _0x389433=lstatSync(_0x135711['skillDir']);if(!_0x389433[_0x21ee9c(0x87)]()||_0x389433[_0x21ee9c(0x9a)]())throw CliErrors[_0x21ee9c(0x80)](_0x21ee9c(0xa0)+_0x135711['skillDir']);if(!_0x3ccf5c)throw CliErrors[_0x21ee9c(0x80)](_0x21ee9c(0x96)+_0x135711[_0x21ee9c(0x85)],_0x21ee9c(0x83));}for(const _0x38acee of _0x135711[_0x21ee9c(0x86)][_0x21ee9c(0x90)]){const _0x21aa09=resolve(_0x135711[_0x21ee9c(0x85)],_0x38acee['path']),_0x37efd8=dirname(_0x21aa09);mkdirSync(_0x37efd8,{'recursive':!![]});if(existsSync(_0x21aa09)&&lstatSync(_0x21aa09)[_0x21ee9c(0x9a)]())throw CliErrors[_0x21ee9c(0x80)]('Refusing\x20to\x20overwrite\x20symlink:\x20'+_0x21aa09);writeFileSync(_0x21aa09,_0x38acee[_0x21ee9c(0x8e)],_0x21ee9c(0x93));}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a70_0x289aa1=a70_0x154f;(function(_0x2120f1,_0x38be05){const _0x2b2b0b=a70_0x154f,_0x357996=_0x2120f1();while(!![]){try{const _0x54d3ef=-parseInt(_0x2b2b0b(0xb9))/0x1*(-parseInt(_0x2b2b0b(0xd7))/0x2)+-parseInt(_0x2b2b0b(0xda))/0x3+-parseInt(_0x2b2b0b(0xdd))/0x4+-parseInt(_0x2b2b0b(0xdc))/0x5*(-parseInt(_0x2b2b0b(0xe0))/0x6)+-parseInt(_0x2b2b0b(0xc7))/0x7+-parseInt(_0x2b2b0b(0xbb))/0x8*(-parseInt(_0x2b2b0b(0xe2))/0x9)+parseInt(_0x2b2b0b(0xc9))/0xa;if(_0x54d3ef===_0x38be05)break;else _0x357996['push'](_0x357996['shift']());}catch(_0x5cf78b){_0x357996['push'](_0x357996['shift']());}}}(a70_0x40a1,0xca28a));import{getRuntimeSkillVersionDiagram,putRuntimeSkillVersionDiagram,validateRuntimeSkillVersionDiagram}from'../../../core/api-client.js';import{CliErrors}from'../../../errors.js';import{readRequiredSkillDiagram}from'../diagram.js';function a70_0x154f(_0x4281be,_0x5cd943){_0x4281be=_0x4281be-0xb7;const _0x40a1e5=a70_0x40a1();let _0x154f8a=_0x40a1e5[_0x4281be];return _0x154f8a;}import{DIAGRAM_FILE_FLAG,DIAGRAM_SCOPE_FLAG,DIAGRAM_SKILL_CODE_FLAG,DIAGRAM_VERSION_FLAG,EXPECTED_DIAGRAM_REVISION_FLAG,SOURCE_FINGERPRINT_FLAG}from'../flags.js';const TARGET_FLAGS=[DIAGRAM_SKILL_CODE_FLAG,DIAGRAM_VERSION_FLAG,DIAGRAM_SCOPE_FLAG],WRITE_FLAGS=[...TARGET_FLAGS,SOURCE_FINGERPRINT_FLAG,EXPECTED_DIAGRAM_REVISION_FLAG,DIAGRAM_FILE_FLAG];function readDiagramTarget(_0x24a7ad){const _0x128016=a70_0x154f,_0x3b995b=_0x24a7ad[_0x128016(0xc1)]('skill-code')[_0x128016(0xe5)](),_0x1bb158=_0x24a7ad[_0x128016(0xc1)](_0x128016(0xe4))[_0x128016(0xe5)](),_0x434b53=_0x24a7ad[_0x128016(0xc1)](_0x128016(0xcf));if(!_0x3b995b||!_0x1bb158||_0x434b53!==_0x128016(0xd5)&&_0x434b53!==_0x128016(0xdf))throw CliErrors[_0x128016(0xbe)]('--skill-code,\x20--version,\x20and\x20--scope\x20personal|company\x20are\x20required.');return{'skillCode':_0x3b995b,'version':_0x1bb158,'scope':_0x434b53};}function a70_0x40a1(){const _0x13765b=['diagram-show','Skill\x20diagram\x20for\x20','213MgTxGN','Show\x20the\x20current\x20Mermaid\x20diagram\x20for\x20one\x20exact\x20Skill\x20version','24DwWisB','skillCode','read','validation','--expected-diagram-revision\x20must\x20be\x20a\x20non-negative\x20integer.',';\x20next\x20write\x20expects\x20revision\x20','str','diagram-validate','Found\x20Skill\x20diagram\x20for\x20','diagram-push','appCode','test','8909229eBIriC','expected-diagram-revision','25091660FthCNm','Validate\x20a\x20Mermaid\x20diagram\x20replacement\x20for\x20one\x20exact\x20Skill\x20version','skill','action','expectedDiagramRevision','--source-fingerprint\x20must\x20be\x20lowercase\x20sha256:<64\x20hex\x20characters>.','scope','Created','diagram-file','\x20is\x20unchanged.','source-fingerprint','unchanged','personal','Create\x20or\x20replace\x20a\x20Mermaid\x20diagram\x20for\x20a\x20specific\x20Skill\x20version','3530CFJHYw','num','isInteger','3398169zadAYl','write','1025785zjynKc','5536872oHjNzw','Creates\x20or\x20replaces\x20a\x20Mermaid\x20diagram\x20for\x20an\x20exact\x20Skill\x20version.\x20The\x20write\x20is\x20rejected\x20if\x20the\x20server\x20version\x20has\x20changed.\x20The\x20confirmation\x20UI\x20does\x20not\x20show\x20the\x20diagram\x20body.','company','24zPecdn','\x20Skill\x20diagram\x20for\x20','2735973zCMSRv',';\x20first\x20write\x20expects\x20revision\x20','version','trim'];a70_0x40a1=function(){return _0x13765b;};return a70_0x40a1();}async function readDiagramWriteInput(_0xe8e40){const _0x92707f=a70_0x154f,_0x5cdf08=_0xe8e40[_0x92707f(0xd8)](_0x92707f(0xc8)),_0x13a3a2=_0xe8e40[_0x92707f(0xc1)](_0x92707f(0xd3))[_0x92707f(0xe5)]();if(!Number[_0x92707f(0xd9)](_0x5cdf08)||_0x5cdf08<0x0)throw CliErrors[_0x92707f(0xbe)](_0x92707f(0xbf));if(!/^sha256:[0-9a-f]{64}$/[_0x92707f(0xc6)](_0x13a3a2))throw CliErrors['validation'](_0x92707f(0xce));return{'expectedDiagramRevision':_0x5cdf08,'sourceFingerprint':_0x13a3a2,'diagram':await readRequiredSkillDiagram(_0xe8e40['str'](_0x92707f(0xd1)))};}export const diagramValidateCommand={'service':a70_0x289aa1(0xcb),'command':a70_0x289aa1(0xc2),'description':a70_0x289aa1(0xca),'risk':a70_0x289aa1(0xbd),'flags':WRITE_FLAGS,async 'execute'(_0x915f2d){const _0x43361c=a70_0x289aa1,_0x2869da=readDiagramTarget(_0x915f2d),_0x55f236=await validateRuntimeSkillVersionDiagram(_0x915f2d[_0x43361c(0xc5)],_0x2869da[_0x43361c(0xbc)],_0x2869da[_0x43361c(0xe4)],_0x2869da[_0x43361c(0xcf)],await readDiagramWriteInput(_0x915f2d));return{'ok':!![],'data':_0x55f236,'message':'Skill\x20diagram\x20validation\x20passed\x20for\x20'+_0x2869da[_0x43361c(0xbc)]+'@'+_0x2869da[_0x43361c(0xe4)]+'.'};}};export const diagramPushCommand={'service':a70_0x289aa1(0xcb),'command':a70_0x289aa1(0xc4),'description':a70_0x289aa1(0xd6),'risk':a70_0x289aa1(0xdb),'confirmationDescription':a70_0x289aa1(0xde),'flags':WRITE_FLAGS,async 'execute'(_0x5185b2){const _0x475439=a70_0x289aa1,_0x198d1d=readDiagramTarget(_0x5185b2),_0x20a016=await putRuntimeSkillVersionDiagram(_0x5185b2[_0x475439(0xc5)],_0x198d1d[_0x475439(0xbc)],_0x198d1d[_0x475439(0xe4)],_0x198d1d[_0x475439(0xcf)],await readDiagramWriteInput(_0x5185b2));return{'ok':!![],'data':_0x20a016,'message':_0x20a016[_0x475439(0xcc)]===_0x475439(0xd4)?_0x475439(0xb8)+_0x198d1d[_0x475439(0xbc)]+'@'+_0x198d1d[_0x475439(0xe4)]+_0x475439(0xd2):(_0x20a016[_0x475439(0xcc)]==='created'?_0x475439(0xd0):'Updated')+_0x475439(0xe1)+_0x198d1d[_0x475439(0xbc)]+'@'+_0x198d1d[_0x475439(0xe4)]+'.'};}};export const diagramShowCommand={'service':a70_0x289aa1(0xcb),'command':a70_0x289aa1(0xb7),'description':a70_0x289aa1(0xba),'risk':a70_0x289aa1(0xbd),'flags':TARGET_FLAGS,async 'execute'(_0x61a9a3){const _0x3e2a7d=a70_0x289aa1,_0x3d37a2=readDiagramTarget(_0x61a9a3),_0x404f29=await getRuntimeSkillVersionDiagram(_0x61a9a3[_0x3e2a7d(0xc5)],_0x3d37a2[_0x3e2a7d(0xbc)],_0x3d37a2[_0x3e2a7d(0xe4)],_0x3d37a2[_0x3e2a7d(0xcf)]);return{'ok':!![],'data':_0x404f29,'message':_0x404f29['found']?_0x3e2a7d(0xc3)+_0x3d37a2[_0x3e2a7d(0xbc)]+'@'+_0x3d37a2['version']+_0x3e2a7d(0xc0)+_0x404f29[_0x3e2a7d(0xcd)]+'.':'No\x20Skill\x20diagram\x20is\x20stored\x20for\x20'+_0x3d37a2[_0x3e2a7d(0xbc)]+'@'+_0x3d37a2[_0x3e2a7d(0xe4)]+_0x3e2a7d(0xe3)+_0x404f29['expectedDiagramRevision']+'.'};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a71_0x23ae33=a71_0x123b;function a71_0xc005(){const _0x4b69f1=['accessKey','reduce','Business\x20Skill\x20installation\x20requires\x20authentication.\x20Run\x20`lovrabet\x20auth\x20login`,\x20or\x20use\x20`lovrabet\x20cli-skill\x20install`\x20for\x20CLI\x20Built-in\x20Skill\x20setup.','2644767kIdlsR','1955ttRHVq','action','trim','skillCode','created','version','skill','envName','project','scope','2820XmBpsL','2190600RbkGkW','Install\x20current-app\x20business\x20Skills\x20into\x20user-level\x20Agent\x20skill\x20directories','global','company','code','skipped','from','str','\x20personal\x20and\x20','appCode','read','bool','personal','../../../core/api-client.js','4264yPSlmB','map','242TjXsBC','675402QtdRPG','84UQOZuK','skillRoots','min','install','length','updated','16533bzSWpN','\x20company\x20Skill(s).','filter','all','unchanged','27251oJBiAM','2884rhOUmV','includes'];a71_0xc005=function(){return _0x4b69f1;};return a71_0xc005();}(function(_0x2bc533,_0x2ebccc){const _0x4fe387=a71_0x123b,_0x31b416=_0x2bc533();while(!![]){try{const _0x13cb53=-parseInt(_0x4fe387(0x11d))/0x1*(parseInt(_0x4fe387(0x12b))/0x2)+-parseInt(_0x4fe387(0x11e))/0x3+-parseInt(_0x4fe387(0x11b))/0x4*(-parseInt(_0x4fe387(0x131))/0x5)+parseInt(_0x4fe387(0x11f))/0x6*(parseInt(_0x4fe387(0x12a))/0x7)+-parseInt(_0x4fe387(0x13c))/0x8+parseInt(_0x4fe387(0x130))/0x9+-parseInt(_0x4fe387(0x13b))/0xa*(-parseInt(_0x4fe387(0x125))/0xb);if(_0x13cb53===_0x2ebccc)break;else _0x31b416['push'](_0x31b416['shift']());}catch(_0x22d8b5){_0x31b416['push'](_0x31b416['shift']());}}}(a71_0xc005,0x53466));import{CliErrors}from'../../../errors.js';import{CODE_FLAG,FORCE_FLAG,PROJECT_TARGET_FLAG,SCOPE_FLAG}from'../flags.js';import{normalizeSyncScopes}from'../scopes.js';import{summarizeRuntimeSkill}from'../summary.js';function a71_0x123b(_0x23461e,_0x2030d6){_0x23461e=_0x23461e-0x113;const _0xc00505=a71_0xc005();let _0x123b32=_0xc00505[_0x23461e];return _0x123b32;}const PACKAGE_DOWNLOAD_CONCURRENCY=0x4;export const installCommand={'service':a71_0x23ae33(0x137),'command':a71_0x23ae33(0x122),'description':a71_0x23ae33(0x13d),'risk':a71_0x23ae33(0x117),'requiresAuth':!![],'requiresAppCode':!![],'hasFormat':![],'flags':[CODE_FLAG,SCOPE_FLAG,FORCE_FLAG,PROJECT_TARGET_FLAG],async 'execute'(_0x4b1df8){return syncRuntimeSkills(_0x4b1df8);}};async function syncRuntimeSkills(_0x51f929){const _0x2b427b=a71_0x23ae33,{downloadRuntimeSkillPackage:_0x5ddafc,listRuntimeSkills:_0x5081cf}=await import(_0x2b427b(0x11a)),{linkEffectiveRuntimeSkills:_0x3340cc,materializeRuntimeSkill:_0x1a6839,pruneStaleRuntimeSkillCache:_0x62360f,pruneStaleRuntimeSkillLinks:_0xf3f77f,resolveRuntimeSkillInstallTarget:_0x44c2b1,reuseMaterializedRuntimeSkill:_0x1ae433}=await import('../../../skills/runtime-skill-sync.js'),_0x120b96=_0x51f929[_0x2b427b(0x114)](_0x2b427b(0x140)),_0x365626=normalizeSyncScopes(_0x51f929[_0x2b427b(0x114)](_0x2b427b(0x13a))),_0x17f7df=_0x51f929[_0x2b427b(0x138)]??'production',_0x4c5c62=_0x51f929[_0x2b427b(0x12d)],_0x3264ff=_0x51f929[_0x2b427b(0x118)]('force');if(!_0x4c5c62)throw CliErrors['authRequired'](_0x2b427b(0x12f));const _0x30c45d=_0x44c2b1(_0x51f929[_0x2b427b(0x116)],_0x51f929['bool'](_0x2b427b(0x139))?_0x2b427b(0x139):_0x2b427b(0x13e)),_0x820bf3=_0x44c2b1(_0x51f929[_0x2b427b(0x116)],_0x30c45d[_0x2b427b(0x13a)]==='project'?_0x2b427b(0x13e):_0x2b427b(0x139)),_0x3814a8=await _0x5081cf({'appCode':_0x51f929[_0x2b427b(0x116)],'scope':_0x365626[_0x2b427b(0x123)]===0x1?_0x365626[0x0]:_0x2b427b(0x128),'code':_0x120b96[_0x2b427b(0x133)]()||undefined,'installableOnly':!![]}),_0x51f56f=_0x365626[_0x2b427b(0x12c)](_0x2b427b(0x119))?_0x3814a8[_0x2b427b(0x119)]:[],_0x5c0834=_0x365626[_0x2b427b(0x12c)]('company')?_0x3814a8[_0x2b427b(0x13f)]:[],_0x551a97=new Set([..._0x51f56f[_0x2b427b(0x11c)](_0x2fc4d6=>_0x2fc4d6[_0x2b427b(0x134)]?.[_0x2b427b(0x133)]())['filter'](_0x1bdb3d=>Boolean(_0x1bdb3d)),..._0x5c0834[_0x2b427b(0x11c)](_0x30c34f=>_0x30c34f[_0x2b427b(0x134)]?.['trim']())[_0x2b427b(0x127)](_0x53c16b=>Boolean(_0x53c16b))]),_0x2e4c73=_0x120b96[_0x2b427b(0x133)]()?[_0x120b96['trim']()]:undefined,_0x4d2276=_0x365626[_0x2b427b(0x123)]===0x2&&_0x365626['includes'](_0x2b427b(0x119))&&_0x365626['includes']('company'),_0x5816f2=_0x4d2276?_0xf3f77f(_0x30c45d,_0x551a97,_0x2e4c73):[],_0x3eaead=_0x62360f({'env':_0x17f7df,'accessKey':_0x4c5c62,'appCode':_0x51f929[_0x2b427b(0x116)],'activeSkillCodes':_0x551a97,'pruneSkillCodes':_0x2e4c73,'scopes':_0x365626,'protectedLinkRoots':_0x820bf3[_0x2b427b(0x120)]}),_0x374f81=[..._0x51f56f[_0x2b427b(0x11c)](_0x341ffb=>({'skill':_0x341ffb,'scope':'personal'})),..._0x5c0834[_0x2b427b(0x11c)](_0x3040aa=>({'skill':_0x3040aa,'scope':_0x2b427b(0x13f)}))],_0xd7539=await mapConcurrent(_0x374f81,PACKAGE_DOWNLOAD_CONCURRENCY,async({skill:_0x1e8474,scope:_0x4b8b82})=>{const _0x5c3e94=_0x2b427b,_0x2dd0cd=_0x1ae433(_0x1e8474,_0x4b8b82,{'env':_0x17f7df,'accessKey':_0x4c5c62,'appCode':_0x51f929[_0x5c3e94(0x116)]});if(_0x2dd0cd)return _0x2dd0cd;return _0x1a6839(_0x1e8474,_0x4b8b82,{'env':_0x17f7df,'accessKey':_0x4c5c62,'appCode':_0x51f929[_0x5c3e94(0x116)],'force':_0x3264ff,'packageBytes':await downloadSkillPackage(_0x1e8474,_0x4b8b82,_0x51f929[_0x5c3e94(0x116)],_0x5ddafc)});}),_0x59b590=_0x3340cc(_0xd7539,_0x30c45d),_0xfbb7dc=countLinkActions(_0x59b590);return{'ok':!![],'data':{'appCode':_0x51f929['appCode'],..._0x30c45d[_0x2b427b(0x13a)]===_0x2b427b(0x139)?{'installTarget':{'scope':_0x30c45d[_0x2b427b(0x13a)],'skillRoots':[..._0x30c45d[_0x2b427b(0x120)]]}}:{},'personal':_0x51f56f[_0x2b427b(0x123)],'company':_0x5c0834[_0x2b427b(0x123)],'materialized':_0xd7539[_0x2b427b(0x123)],'links':{'total':_0x59b590[_0x2b427b(0x123)],'created':_0xfbb7dc[_0x2b427b(0x135)]??0x0,'updated':_0xfbb7dc[_0x2b427b(0x124)]??0x0,'unchanged':_0xfbb7dc[_0x2b427b(0x129)]??0x0,'skipped':0x0,'conflicted':0x0},'pruned':{'links':_0x5816f2[_0x2b427b(0x127)](_0xf121e4=>_0xf121e4[_0x2b427b(0x132)]==='removed')['length'],'cacheDirs':_0x3eaead[_0x2b427b(0x127)](_0xa1a623=>_0xa1a623[_0x2b427b(0x132)]==='removed')['length'],'skipped':[..._0x5816f2,..._0x3eaead][_0x2b427b(0x127)](_0x36aecc=>_0x36aecc[_0x2b427b(0x132)]===_0x2b427b(0x141))[_0x2b427b(0x123)]},'skills':{'personal':_0x51f56f['map'](summarizeRuntimeSkill),'company':_0x5c0834['map'](summarizeRuntimeSkill)}},'message':'Installed\x20'+_0x51f56f[_0x2b427b(0x123)]+_0x2b427b(0x115)+_0x5c0834['length']+_0x2b427b(0x126)};}async function mapConcurrent(_0x2fc6f1,_0x587f12,_0x3423a1){const _0x3a5ea0=a71_0x23ae33,_0x3ebe54=new Array(_0x2fc6f1[_0x3a5ea0(0x123)]);let _0x5ec43e=0x0;const _0x570b59=Array[_0x3a5ea0(0x113)]({'length':Math[_0x3a5ea0(0x121)](_0x587f12,_0x2fc6f1[_0x3a5ea0(0x123)])},async()=>{const _0x4d68a7=_0x3a5ea0;while(_0x5ec43e<_0x2fc6f1[_0x4d68a7(0x123)]){const _0x5ed3b9=_0x5ec43e;_0x5ec43e+=0x1,_0x3ebe54[_0x5ed3b9]=await _0x3423a1(_0x2fc6f1[_0x5ed3b9]);}});return await Promise['all'](_0x570b59),_0x3ebe54;}async function downloadSkillPackage(_0x5efe20,_0x372371,_0x320627,_0x59d9dd){const _0x2a614d=a71_0x23ae33,_0x4a1a72=_0x5efe20[_0x2a614d(0x136)]?.[_0x2a614d(0x133)]();return _0x4a1a72?_0x59d9dd(_0x372371,_0x5efe20['skillCode'],_0x320627,_0x4a1a72):_0x59d9dd(_0x372371,_0x5efe20[_0x2a614d(0x134)],_0x320627);}function countLinkActions(_0x19a5a9){const _0x7f9f9b=a71_0x23ae33;return _0x19a5a9[_0x7f9f9b(0x12e)]((_0x5255c7,_0x18a92d)=>{const _0x2e11a1=_0x7f9f9b;return _0x5255c7[_0x18a92d[_0x2e11a1(0x132)]]=(_0x5255c7[_0x18a92d['action']]??0x0)+0x1,_0x5255c7;},{});}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a72_0x4aa8b2=a72_0x5816;(function(_0x1b0d1f,_0x3b3412){const _0x484ee8=a72_0x5816,_0x29e1aa=_0x1b0d1f();while(!![]){try{const _0xacf085=parseInt(_0x484ee8(0x1d7))/0x1+parseInt(_0x484ee8(0x1de))/0x2+parseInt(_0x484ee8(0x1e4))/0x3*(parseInt(_0x484ee8(0x1e8))/0x4)+-parseInt(_0x484ee8(0x1e1))/0x5*(-parseInt(_0x484ee8(0x1e7))/0x6)+parseInt(_0x484ee8(0x1da))/0x7*(-parseInt(_0x484ee8(0x1d9))/0x8)+parseInt(_0x484ee8(0x1d8))/0x9+-parseInt(_0x484ee8(0x1dd))/0xa;if(_0xacf085===_0x3b3412)break;else _0x29e1aa['push'](_0x29e1aa['shift']());}catch(_0x5de4b7){_0x29e1aa['push'](_0x29e1aa['shift']());}}}(a72_0x1256,0x5011a));import{CliErrors}from'../../../errors.js';import{CODE_FLAG,LIST_SCOPE_FLAG,LOCAL_FLAG,PROJECT_TARGET_FLAG}from'../flags.js';import{listScopeToRemoteScope,listScopeToRuntimeScopes,normalizeListScope,shouldListScope}from'../scopes.js';function a72_0x5816(_0x3244ee,_0x459047){_0x3244ee=_0x3244ee-0x1d4;const _0x12560a=a72_0x1256();let _0x5816e7=_0x12560a[_0x3244ee];return _0x5816e7;}import{summarizeLocalRuntimeSkill,summarizeRuntimeSkill}from'../summary.js';export const listCommand={'service':a72_0x4aa8b2(0x1f4),'command':a72_0x4aa8b2(0x1d5),'description':a72_0x4aa8b2(0x1e6),'risk':a72_0x4aa8b2(0x1df),'flags':[CODE_FLAG,LIST_SCOPE_FLAG,LOCAL_FLAG,PROJECT_TARGET_FLAG],async 'execute'(_0x112020){const _0x3185f5=a72_0x4aa8b2,_0x4cee95=_0x112020['str']('code'),_0x3e4354=normalizeListScope(_0x112020[_0x3185f5(0x1ea)](_0x3185f5(0x1d6)));if(_0x112020['bool']('local')){const _0x12502c=_0x112020[_0x3185f5(0x1ef)];if(!_0x12502c)throw CliErrors[_0x3185f5(0x1e9)]();const {listLocalRuntimeSkills:_0x1bc7d4,resolveRuntimeSkillInstallTarget:_0xb6fb52}=await import('../../../skills/runtime-skill-sync.js'),_0x1d40fc=_0xb6fb52(_0x112020[_0x3185f5(0x1f1)],_0x112020[_0x3185f5(0x1f2)](_0x3185f5(0x1ee))?_0x3185f5(0x1ee):_0x3185f5(0x1d4)),_0x310971=_0x1bc7d4({'env':_0x112020['envName']??_0x3185f5(0x1e2),'accessKey':_0x12502c,'appCode':_0x112020[_0x3185f5(0x1f1)],'scopes':listScopeToRuntimeScopes(_0x3e4354),'code':_0x4cee95[_0x3185f5(0x1e0)]()||undefined},_0x1d40fc),_0x30e235=groupLocalRuntimeSkills(_0x310971);return{'ok':!![],'data':{'appCode':_0x112020[_0x3185f5(0x1f1)],'source':_0x3185f5(0x1f0),..._0x1d40fc['scope']===_0x3185f5(0x1ee)?{'installScope':_0x1d40fc[_0x3185f5(0x1d6)]}:{},'scope':_0x3e4354,'total':_0x310971['length'],'personal':_0x30e235[_0x3185f5(0x1ed)][_0x3185f5(0x1db)],'company':_0x30e235[_0x3185f5(0x1f3)]['length'],'items':_0x310971['map'](summarizeLocalRuntimeSkill),'skills':{'personal':_0x30e235[_0x3185f5(0x1ed)][_0x3185f5(0x1e3)](summarizeLocalRuntimeSkill),'company':_0x30e235[_0x3185f5(0x1f3)]['map'](summarizeLocalRuntimeSkill)}},'message':_0x3185f5(0x1ec)+_0x310971[_0x3185f5(0x1db)]+_0x3185f5(0x1eb)};}const {listRuntimeSkills:_0x379fa2}=await import(_0x3185f5(0x1f5)),_0x377d9d=await _0x379fa2({'appCode':_0x112020[_0x3185f5(0x1f1)],'scope':listScopeToRemoteScope(_0x3e4354),'code':_0x4cee95[_0x3185f5(0x1e0)]()||undefined}),_0x5a3e8b=shouldListScope(_0x3e4354,_0x3185f5(0x1ed))?_0x377d9d['personal']??[]:[],_0xd1af55=shouldListScope(_0x3e4354,_0x3185f5(0x1f3))?_0x377d9d[_0x3185f5(0x1f3)]??[]:[],_0x1e4fc0=[..._0x5a3e8b,..._0xd1af55];return{'ok':!![],'data':{'appCode':_0x112020[_0x3185f5(0x1f1)],'source':_0x3185f5(0x1e5),'scope':_0x3e4354,'total':_0x1e4fc0['length'],'personal':_0x5a3e8b['length'],'company':_0xd1af55[_0x3185f5(0x1db)],'items':_0x1e4fc0[_0x3185f5(0x1e3)](summarizeRuntimeSkill),'skills':{'personal':_0x5a3e8b[_0x3185f5(0x1e3)](summarizeRuntimeSkill),'company':_0xd1af55[_0x3185f5(0x1e3)](summarizeRuntimeSkill)}},'message':_0x3185f5(0x1ec)+_0x1e4fc0[_0x3185f5(0x1db)]+'\x20remote\x20Skill(s).'};}};function a72_0x1256(){const _0x4aa3f3=['Listed\x20','personal','project','accessKey','local','appCode','bool','company','skill','../../../core/api-client.js','global','list','scope','38519hSbmbt','711855GOlkdP','8yBYBlZ','2337755RbxXSM','length','filter','8381110nwWJQX','705654njLmxO','read','trim','2210945NYvgFI','production','map','881112YWhpNc','remote','List\x20runtime\x20Skills\x20from\x20remote\x20or\x20CLI-managed\x20local\x20cache','6OtYFZP','8YPXlcH','authRequired','str','\x20local\x20Skill(s).'];a72_0x1256=function(){return _0x4aa3f3;};return a72_0x1256();}function groupLocalRuntimeSkills(_0x3e6204){const _0x1e6da9=a72_0x4aa8b2;return{'personal':_0x3e6204[_0x1e6da9(0x1dc)](_0x4ebb6f=>_0x4ebb6f[_0x1e6da9(0x1d6)]===_0x1e6da9(0x1ed)),'company':_0x3e6204['filter'](_0x16517d=>_0x16517d['scope']===_0x1e6da9(0x1f3)),'builtin':_0x3e6204['filter'](_0x558072=>_0x558072[_0x1e6da9(0x1d6)]==='builtin')};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a73_0x5f0c96=a73_0x58bc;(function(_0x384e0b,_0x4b8d87){const _0x57fbb9=a73_0x58bc,_0x32b428=_0x384e0b();while(!![]){try{const _0x1515c8=parseInt(_0x57fbb9(0x192))/0x1*(parseInt(_0x57fbb9(0x18b))/0x2)+-parseInt(_0x57fbb9(0x191))/0x3*(parseInt(_0x57fbb9(0x18e))/0x4)+parseInt(_0x57fbb9(0x187))/0x5+parseInt(_0x57fbb9(0x18f))/0x6+-parseInt(_0x57fbb9(0x185))/0x7+parseInt(_0x57fbb9(0x18d))/0x8+-parseInt(_0x57fbb9(0x189))/0x9*(parseInt(_0x57fbb9(0x18a))/0xa);if(_0x1515c8===_0x4b8d87)break;else _0x32b428['push'](_0x32b428['shift']());}catch(_0x4293af){_0x32b428['push'](_0x32b428['shift']());}}}(a73_0x8d99,0xca572));import{CONFIRM_WARNINGS_FLAG,DIAGRAM_FILE_FLAG,DIR_FLAG,PUSH_SCOPE_FLAG}from'../flags.js';function a73_0x58bc(_0x23097b,_0xde60e1){_0x23097b=_0x23097b-0x185;const _0x8d99b0=a73_0x8d99();let _0x58bc80=_0x8d99b0[_0x23097b];return _0x58bc80;}import{skillPushDryRun,skillPushExecute}from'../push-execute.js';export const pushCommand={'service':a73_0x5f0c96(0x186),'command':a73_0x5f0c96(0x190),'description':'Push\x20a\x20local\x20Skill\x20directory\x20to\x20personal\x20scope,\x20or\x20submit\x20a\x20company-scope\x20version\x20for\x20review','risk':a73_0x5f0c96(0x188),'confirmationDescription':a73_0x5f0c96(0x18c),'flags':[DIR_FLAG,DIAGRAM_FILE_FLAG,PUSH_SCOPE_FLAG,CONFIRM_WARNINGS_FLAG],'dryRun':skillPushDryRun,'execute':skillPushExecute};function a73_0x8d99(){const _0x5056ef=['11252630JiiCYU','322AKYulr','Reads\x20local\x20Skill\x20content:\x20personal\x20scope\x20is\x20saved\x20immediately;\x20company\x20scope\x20submits\x20a\x20new\x20version\x20for\x20review.\x20The\x20confirmation\x20UI\x20does\x20not\x20show\x20the\x20directory\x20path\x20or\x20Skill\x20body.','12841632wswKnc','4655876wnKtWU','755874PhCpuU','push','3bDFboR','9598udWLEi','7493115PkMTkU','skill','4560010Tzthyw','write','9oBIsmu'];a73_0x8d99=function(){return _0x5056ef;};return a73_0x8d99();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a74_0xe6c930=a74_0x30fe;(function(_0x17b02c,_0x487455){const _0x1c362a=a74_0x30fe,_0x3c8715=_0x17b02c();while(!![]){try{const _0x5df19b=-parseInt(_0x1c362a(0x10d))/0x1*(-parseInt(_0x1c362a(0x10c))/0x2)+-parseInt(_0x1c362a(0x106))/0x3+-parseInt(_0x1c362a(0x107))/0x4+parseInt(_0x1c362a(0x10b))/0x5*(-parseInt(_0x1c362a(0x102))/0x6)+parseInt(_0x1c362a(0x101))/0x7+parseInt(_0x1c362a(0x108))/0x8*(parseInt(_0x1c362a(0x10a))/0x9)+parseInt(_0x1c362a(0x103))/0xa*(parseInt(_0x1c362a(0x110))/0xb);if(_0x5df19b===_0x487455)break;else _0x3c8715['push'](_0x3c8715['shift']());}catch(_0x2cfef5){_0x3c8715['push'](_0x3c8715['shift']());}}}(a74_0x1262,0xf1723));import{DIR_FLAG,STRICT_FLAG}from'../flags.js';function a74_0x1262(){const _0xcf617=['8LUOwzp','skill','15911442iqDgSJ','10CwHvBY','22GBskIU','47562CxMATi','type','Skill\x20validation\x20passed.','1751365mPecFE','Validate\x20a\x20local\x20Skill\x20directory\x20as\x20a\x20self-contained\x20delivery\x20package','dir','strict','read','str','warnings','bool','6688381OOXNLI','1776702VQBtKh','50TIPAQU','errors','validate','3542148iAhSFR','5123060utUbyM'];a74_0x1262=function(){return _0xcf617;};return a74_0x1262();}import{throwIfSkillValidationFailed,validateSkillDirectory}from'../validate.js';function a74_0x30fe(_0x17149a,_0x22cb7f){_0x17149a=_0x17149a-0xfb;const _0x1262fb=a74_0x1262();let _0x30fe55=_0x1262fb[_0x17149a];return _0x30fe55;}export const validateCommand={'service':a74_0xe6c930(0x109),'command':a74_0xe6c930(0x105),'description':a74_0xe6c930(0x111),'risk':a74_0xe6c930(0xfd),'requiresAuth':![],'requiresAppCode':![],'flags':[DIR_FLAG,STRICT_FLAG],async 'execute'(_0x19fd03){const _0x2bc316=a74_0xe6c930,_0x3a5f6c=_0x19fd03[_0x2bc316(0x100)](_0x2bc316(0xfc)),_0x3318cb=validateSkillDirectory(_0x19fd03[_0x2bc316(0xfe)]('dir'),{'strict':_0x3a5f6c});return throwIfSkillValidationFailed(_0x3318cb,_0x3a5f6c),{'ok':!![],'data':{'dir':_0x3318cb[_0x2bc316(0xfb)],'type':_0x3318cb[_0x2bc316(0x10e)],'errors':_0x3318cb[_0x2bc316(0x104)],'warnings':_0x3318cb[_0x2bc316(0xff)]},'message':_0x2bc316(0x10f)};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a75_0xb08d(_0x3e2c90,_0x4b0610){_0x3e2c90=_0x3e2c90-0x17c;const _0x42acac=a75_0x42ac();let _0xb08d9d=_0x42acac[_0x3e2c90];return _0xb08d9d;}(function(_0x59d1f5,_0x1a8898){const _0x10f01a=a75_0xb08d,_0x259275=_0x59d1f5();while(!![]){try{const _0x56acc1=parseInt(_0x10f01a(0x17e))/0x1*(-parseInt(_0x10f01a(0x18a))/0x2)+parseInt(_0x10f01a(0x18b))/0x3*(parseInt(_0x10f01a(0x189))/0x4)+-parseInt(_0x10f01a(0x192))/0x5+parseInt(_0x10f01a(0x17c))/0x6*(-parseInt(_0x10f01a(0x193))/0x7)+parseInt(_0x10f01a(0x18e))/0x8*(parseInt(_0x10f01a(0x18c))/0x9)+parseInt(_0x10f01a(0x18f))/0xa+parseInt(_0x10f01a(0x190))/0xb;if(_0x56acc1===_0x1a8898)break;else _0x259275['push'](_0x259275['shift']());}catch(_0x314ac9){_0x259275['push'](_0x259275['shift']());}}}(a75_0x42ac,0xd5147));import{existsSync,readFileSync,realpathSync,statSync}from'node:fs';import{resolve}from'node:path';import{JSDOM}from'jsdom';import{CliErrors}from'../../errors.js';function a75_0x42ac(){const _0x13a8a8=['1120659GURssH','6235767NPGfmZ','validation','8MtdIbB','10555690ryckba','18070932XYDCnZ','diagram','7395195jhZPvv','7Udubht','4394874kIpOfv','window','107LeLHye','Unable\x20to\x20read\x20Mermaid\x20flowchart\x20from\x20standard\x20input.','Fix\x20the\x20Mermaid\x20syntax\x20reported\x20by\x20your\x20editor\x20or\x20preview\x20tool,\x20then\x20retry\x20with\x20the\x20same\x20file.','Mermaid\x20flowchart\x20file\x20not\x20found:\x20','isFile','replace','Mermaid\x20syntax\x20validation\x20failed.','utf8','trim','document','Generate\x20a\x20Mermaid\x20flowchart\x20and\x20pass\x20--diagram-file\x20<path>,\x20or\x20use\x20--diagram-file\x20-\x20for\x20standard\x20input.','8rdyPIm','19702yqzffk'];a75_0x42ac=function(){return _0x13a8a8;};return a75_0x42ac();}let mermaidApiPromise;export async function readRequiredSkillDiagram(_0x13de2b){const _0x504e2d=a75_0xb08d;return(await readRequiredSkillDiagramInput(_0x13de2b))[_0x504e2d(0x191)];}export async function readRequiredSkillDiagramInput(_0x5c76e2){const _0x436ae9=a75_0xb08d,_0x338a1b=_0x5c76e2[_0x436ae9(0x186)]();if(!_0x338a1b)throw CliErrors['validation']('--diagram-file\x20is\x20required\x20when\x20publishing\x20a\x20Skill\x20version.',_0x436ae9(0x188));let _0x1ec706,_0x5095c7;if(_0x338a1b==='-')try{_0x1ec706=readFileSync(0x0,_0x436ae9(0x185));}catch{throw CliErrors[_0x436ae9(0x18d)](_0x436ae9(0x17f));}else{const _0x13c844=resolve(_0x338a1b);if(!existsSync(_0x13c844))throw CliErrors[_0x436ae9(0x18d)](_0x436ae9(0x181)+_0x13c844);if(!statSync(_0x13c844)[_0x436ae9(0x182)]())throw CliErrors['validation']('Mermaid\x20flowchart\x20path\x20is\x20not\x20a\x20regular\x20file:\x20'+_0x13c844);_0x5095c7=realpathSync(_0x13c844),_0x1ec706=readFileSync(_0x5095c7,'utf8');}return{'diagram':{'schemaVersion':0x1,'mermaid':await validateAndCanonicalizeMermaid(_0x1ec706)},'sourceFilePath':_0x5095c7};}export async function validateAndCanonicalizeMermaid(_0x284ef4){const _0xe520bb=a75_0xb08d,_0x3fa506=_0x284ef4[_0xe520bb(0x183)](/\r\n/g,'\x0a')[_0xe520bb(0x183)](/\r/g,'\x0a')['replace'](/\n+$/,'')+'\x0a';try{const _0x529d2c=await loadMermaidApi();await _0x529d2c['parse'](_0x3fa506);}catch{throw diagramValidationError();}return _0x3fa506;}function loadMermaidApi(){return mermaidApiPromise??=((async()=>{const _0xf3b7a0=a75_0xb08d;if(!(_0xf3b7a0(0x17d)in globalThis)||!(_0xf3b7a0(0x187)in globalThis)){const _0x3f626a=new JSDOM('');Object['defineProperties'](globalThis,{'window':{'configurable':!![],'value':_0x3f626a[_0xf3b7a0(0x17d)]},'document':{'configurable':!![],'value':_0x3f626a[_0xf3b7a0(0x17d)][_0xf3b7a0(0x187)]}});}return(await import('mermaid'))['default'];})()),mermaidApiPromise;}function diagramValidationError(){const _0x173906=a75_0xb08d;return CliErrors[_0x173906(0x18d)](_0x173906(0x184),_0x173906(0x180));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a76_0x525cfa=a76_0x1214;function a76_0x1214(_0x4075ff,_0x117601){_0x4075ff=_0x4075ff-0x1a8;const _0x25a5a2=a76_0x25a5();let _0x12147a=_0x25a5a2[_0x4075ff];return _0x12147a;}(function(_0x3496e4,_0x425821){const _0x4a213a=a76_0x1214,_0x3485ed=_0x3496e4();while(!![]){try{const _0x328ccf=parseInt(_0x4a213a(0x1be))/0x1*(parseInt(_0x4a213a(0x1d0))/0x2)+-parseInt(_0x4a213a(0x1b3))/0x3+-parseInt(_0x4a213a(0x1c4))/0x4+-parseInt(_0x4a213a(0x1bd))/0x5+parseInt(_0x4a213a(0x1c1))/0x6*(parseInt(_0x4a213a(0x1c5))/0x7)+-parseInt(_0x4a213a(0x1af))/0x8*(parseInt(_0x4a213a(0x1b2))/0x9)+-parseInt(_0x4a213a(0x1b8))/0xa*(-parseInt(_0x4a213a(0x1cf))/0xb);if(_0x328ccf===_0x425821)break;else _0x3485ed['push'](_0x3485ed['shift']());}catch(_0x233e2f){_0x3485ed['push'](_0x3485ed['shift']());}}}(a76_0x25a5,0xcafaa));import{DEFAULT_SKILL_TARGET,SKILL_NAME_PATTERN,SKILL_TYPES}from'./templates.js';export const CODE_FLAG={'name':a76_0x525cfa(0x1d3),'type':a76_0x525cfa(0x1d4),'description':a76_0x525cfa(0x1c7)};export const SCOPE_FLAG={'name':a76_0x525cfa(0x1ce),'type':a76_0x525cfa(0x1d4),'description':a76_0x525cfa(0x1d1),'enum':[a76_0x525cfa(0x1a8),a76_0x525cfa(0x1b7),'company']};export const PUSH_SCOPE_FLAG={'name':'scope','type':'string','description':a76_0x525cfa(0x1b0),'default':a76_0x525cfa(0x1b7),'enum':['personal',a76_0x525cfa(0x1cd)]};export const LIST_SCOPE_FLAG={'name':a76_0x525cfa(0x1ce),'type':a76_0x525cfa(0x1d4),'description':'Skill\x20list\x20scope:\x20all,\x20personal,\x20or\x20company','enum':[a76_0x525cfa(0x1a8),'personal',a76_0x525cfa(0x1cd)]};export const LOCAL_FLAG={'name':a76_0x525cfa(0x1c8),'type':a76_0x525cfa(0x1b5),'description':'Read\x20CLI-managed\x20local\x20Skill\x20cache\x20and\x20links\x20instead\x20of\x20remote\x20lists'};function a76_0x25a5(){const _0x20df4e=['number','code','string','all','UTF-8\x20Mermaid\x20flowchart\x20file;\x20the\x20selected\x20file\x20is\x20excluded\x20from\x20the\x20Skill\x20package;\x20use\x20-\x20for\x20stdin','Exact\x20Skill\x20scope:\x20personal\x20or\x20company','name','expected-diagram-revision','Exact\x20Skill\x20version\x20whose\x20diagram\x20is\x20being\x20managed','project','60488dwadIz','Skill\x20push\x20target\x20scope:\x20personal\x20saves\x20immediately,\x20company\x20submits\x20a\x20new\x20version\x20for\x20review','Expected\x20current\x20diagram\x20revision;\x20use\x200\x20for\x20the\x20first\x20diagram','189JwpciI','2383872tzwAuy','skill-code','boolean','Skill\x20name\x20using\x20lowercase\x20letters,\x20numbers,\x20and\x20hyphens','personal','270aLESVr','source-fingerprint','a\x20lowercase\x20sha256:<64\x20hex\x20characters>\x20fingerprint','Overwrite\x20generated\x20or\x20CLI-managed\x20Skill\x20files\x20when\x20the\x20target\x20already\x20exists','target','1448320fgIbkm','772147LAgBCe','Exact\x20Skill\x20code\x20whose\x20version\x20diagram\x20is\x20being\x20managed','strict','5866206qshwWs','dir','lowercase\x20letters,\x20numbers,\x20and\x20single\x20hyphens','4691296VarCFl','7rXlBYz','confirm-warnings','Only\x20target\x20a\x20specific\x20runtime\x20Skill\x20code','local','Confirm\x20reviewed\x20personal\x20or\x20company\x20Skill\x20publish\x20warnings','Use\x20the\x20current\x20project\x27s\x20.agents/skills\x20instead\x20of\x20user-level\x20Agent\x20Skill\x20directories','version','force','company','scope','610071rRnVji','2cSekXC','Skill\x20sync\x20scope:\x20all\x20(personal/company),\x20personal,\x20or\x20company'];a76_0x25a5=function(){return _0x20df4e;};return a76_0x25a5();}export const DIR_FLAG={'name':a76_0x525cfa(0x1c2),'type':a76_0x525cfa(0x1d4),'required':!![],'description':'Local\x20Skill\x20directory\x20containing\x20SKILL.md'};export const DIAGRAM_FILE_FLAG={'name':'diagram-file','type':a76_0x525cfa(0x1d4),'required':!![],'description':a76_0x525cfa(0x1a9)};export const DIAGRAM_SKILL_CODE_FLAG={'name':a76_0x525cfa(0x1b4),'type':a76_0x525cfa(0x1d4),'required':!![],'description':a76_0x525cfa(0x1bf)};export const DIAGRAM_VERSION_FLAG={'name':a76_0x525cfa(0x1cb),'type':'string','required':!![],'description':a76_0x525cfa(0x1ad)};export const DIAGRAM_SCOPE_FLAG={'name':a76_0x525cfa(0x1ce),'type':'string','required':!![],'enum':[a76_0x525cfa(0x1b7),'company'],'description':a76_0x525cfa(0x1aa)};export const SOURCE_FINGERPRINT_FLAG={'name':a76_0x525cfa(0x1b9),'type':'string','required':!![],'description':'Server-reported\x20SkillVersion\x20source\x20fingerprint','pattern':{'regex':/^sha256:[0-9a-f]{64}$/,'description':a76_0x525cfa(0x1ba)}};export const EXPECTED_DIAGRAM_REVISION_FLAG={'name':a76_0x525cfa(0x1ac),'type':a76_0x525cfa(0x1d2),'required':!![],'description':a76_0x525cfa(0x1b1)};export const CREATE_NAME_FLAG={'name':a76_0x525cfa(0x1ab),'type':'string','required':!![],'description':a76_0x525cfa(0x1b6),'pattern':{'regex':SKILL_NAME_PATTERN,'description':a76_0x525cfa(0x1c3)}};export const TYPE_FLAG={'name':'type','type':a76_0x525cfa(0x1d4),'description':'Skill\x20template\x20type:\x20pass\x20read\x20or\x20write\x20explicitly\x20(omission\x20is\x20deprecated)','enum':[...SKILL_TYPES]};export const TARGET_FLAG={'name':a76_0x525cfa(0x1bc),'type':'string','description':'Directory\x20that\x20will\x20contain\x20the\x20generated\x20Skill\x20directory','default':DEFAULT_SKILL_TARGET};export const FORCE_FLAG={'name':a76_0x525cfa(0x1cc),'type':a76_0x525cfa(0x1b5),'description':a76_0x525cfa(0x1bb)};export const PROJECT_TARGET_FLAG={'name':a76_0x525cfa(0x1ae),'type':'boolean','description':a76_0x525cfa(0x1ca)};export const CONFIRM_WARNINGS_FLAG={'name':a76_0x525cfa(0x1c6),'type':a76_0x525cfa(0x1b5),'description':a76_0x525cfa(0x1c9)};export const STRICT_FLAG={'name':a76_0x525cfa(0x1c0),'type':a76_0x525cfa(0x1b5),'description':'Compatibility\x20flag;\x20no\x20extra\x20checks\x20are\x20enabled'};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x44492c,_0x48bcff){const _0x3802b8=a77_0x37e6,_0x3436e5=_0x44492c();while(!![]){try{const _0x40a15e=-parseInt(_0x3802b8(0x121))/0x1*(-parseInt(_0x3802b8(0x123))/0x2)+parseInt(_0x3802b8(0x11f))/0x3*(-parseInt(_0x3802b8(0x127))/0x4)+-parseInt(_0x3802b8(0x126))/0x5*(parseInt(_0x3802b8(0x11d))/0x6)+-parseInt(_0x3802b8(0x128))/0x7+parseInt(_0x3802b8(0x124))/0x8+parseInt(_0x3802b8(0x125))/0x9*(-parseInt(_0x3802b8(0x120))/0xa)+parseInt(_0x3802b8(0x11e))/0xb*(parseInt(_0x3802b8(0x122))/0xc);if(_0x40a15e===_0x48bcff)break;else _0x3436e5['push'](_0x3436e5['shift']());}catch(_0x2ec51b){_0x3436e5['push'](_0x3436e5['shift']());}}}(a77_0x111c,0xa99fd));import{createCommand}from'./commands/create.js';import{diagramPushCommand,diagramShowCommand,diagramValidateCommand}from'./commands/diagram.js';import{installCommand}from'./commands/install.js';function a77_0x37e6(_0x4acd1d,_0x9485a1){_0x4acd1d=_0x4acd1d-0x11d;const _0x111cb1=a77_0x111c();let _0x37e673=_0x111cb1[_0x4acd1d];return _0x37e673;}import{listCommand}from'./commands/list.js';import{pushCommand}from'./commands/push.js';function a77_0x111c(){const _0x47f9ab=['2gAvZHo','4179216hFZScH','1830429OTLmzY','2475CNiGlo','12224aYRaVS','3258297mNvEXn','15888JlluHy','7403WJeiKn','453PMMEhD','50ViqiDb','642097VHbVtz','49656BRKBzL'];a77_0x111c=function(){return _0x47f9ab;};return a77_0x111c();}import{validateCommand}from'./commands/validate.js';export const skillDefinitions=[installCommand,createCommand,validateCommand,listCommand,pushCommand,diagramValidateCommand,diagramPushCommand,diagramShowCommand];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x2518fb,_0x553b97){var _0x373ba5=a78_0x38b2,_0x59ffab=_0x2518fb();while(!![]){try{var _0x4022c4=-parseInt(_0x373ba5(0x140))/0x1+parseInt(_0x373ba5(0x138))/0x2+parseInt(_0x373ba5(0x141))/0x3+parseInt(_0x373ba5(0x136))/0x4+-parseInt(_0x373ba5(0x13a))/0x5+parseInt(_0x373ba5(0x142))/0x6*(-parseInt(_0x373ba5(0x13c))/0x7)+-parseInt(_0x373ba5(0x13f))/0x8;if(_0x4022c4===_0x553b97)break;else _0x59ffab['push'](_0x59ffab['shift']());}catch(_0x302f0d){_0x59ffab['push'](_0x59ffab['shift']());}}}(a78_0x5787,0x542ff));function a78_0x38b2(_0x132086,_0x2f8a2d){_0x132086=_0x132086-0x136;var _0x57871a=a78_0x5787();var _0x38b2f8=_0x57871a[_0x132086];return _0x38b2f8;}export function isPackageBackedManifest(_0x568747){var _0x2d61d2=a78_0x38b2;return!!_0x568747&&typeof _0x568747===_0x2d61d2(0x139)&&!Array[_0x2d61d2(0x143)](_0x568747)&&typeof _0x568747['ossPath']===_0x2d61d2(0x144)&&_0x568747[_0x2d61d2(0x13d)][_0x2d61d2(0x137)]>0x0&&Array[_0x2d61d2(0x143)](_0x568747['files']);}function a78_0x5787(){var _0x4dcec2=['string','2069908PMhlXC','length','1151038xnnFix','object','1774600ILlLHX','files','129262IWYrHr','ossPath','path','5781104XgNGaY','54008QxoUkW','1205601AXuMtF','6TBvztx','isArray'];a78_0x5787=function(){return _0x4dcec2;};return a78_0x5787();}export function isMultiFileManifest(_0x5d2bcf){var _0x282c35=a78_0x38b2;return!!_0x5d2bcf&&typeof _0x5d2bcf===_0x282c35(0x139)&&!Array[_0x282c35(0x143)](_0x5d2bcf)&&Array[_0x282c35(0x143)](_0x5d2bcf[_0x282c35(0x13b)])&&_0x5d2bcf['files']['some'](_0xeb9de9=>_0xeb9de9[_0x282c35(0x13e)]!=='SKILL.md');}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(_0x5160fc,_0x4be47b){const _0x11a079=a79_0x4757,_0x77508=_0x5160fc();while(!![]){try{const _0x2f9bf3=parseInt(_0x11a079(0x1d6))/0x1*(parseInt(_0x11a079(0x1dd))/0x2)+-parseInt(_0x11a079(0x1f5))/0x3+-parseInt(_0x11a079(0x1e4))/0x4*(parseInt(_0x11a079(0x1fa))/0x5)+-parseInt(_0x11a079(0x1f2))/0x6*(parseInt(_0x11a079(0x1fb))/0x7)+-parseInt(_0x11a079(0x1f9))/0x8+-parseInt(_0x11a079(0x1ec))/0x9+parseInt(_0x11a079(0x208))/0xa;if(_0x2f9bf3===_0x4be47b)break;else _0x77508['push'](_0x77508['shift']());}catch(_0x486cb8){_0x77508['push'](_0x77508['shift']());}}}(a79_0x70bb,0x392c3));import{CliErrors}from'../../errors.js';import{isMultiFileManifest,isPackageBackedManifest}from'./manifest-helpers.js';import{remotePersonalReadOptions,remoteMissingCompanyReadOptions,remoteMissingPersonalReadOptions}from'./push-flow-helpers.js';import{allowRetargetArgs,buildRetargetWarning,remoteFirstMetadataOptions,resolvePushScope,runRemoteContentPreflight,throwIfBuiltinPushTarget,throwIfUnconfirmedPublishWarnings,throwIfPublishValidationFailed}from'./push-flow-helpers.js';import{withRetargetExistingMetadata}from'./push-retarget.js';import{summarizeRuntimeSkill}from'./summary.js';function a79_0x70bb(){const _0x5115f1=['POST','resolvedVersion','appCode','input','156193nnroXL','unknown','authRequired','../../core/api-client.js','existing','\x20is\x20already\x20published\x20and\x20content\x20is\x20identical','scope','4sfWCyJ','Company','diagram-file','NAMESPACE_ONLY','\x20has\x20scope=\x22','bool','/publish/validate','8RUYhGN','accessKey','\x20Skill\x20','skillCode','valid','PRIVATE','frontmatterDisplayName','files','3717702pPSLuC','\x20version\x20','confirmWarnings','publishInput','personal','remoteForPreflight','3330kjYclD','appcode','/api/cli/v1/skills/','538653YiOyaM','\x20for\x20review','Created\x20personal\x20Skill\x20','savedSkill','2576248ncAlwF','487300MIJYbA','742QXSJHU','Updated\x20personal\x20Skill\x20','Submitted\x20company\x20Skill\x20','dir','validation','errors','../../skills/runtime-skill-sync.js','Only\x20personal\x20Skills\x20can\x20be\x20pushed;\x20remote\x20Skill\x20','version','payload','status','str','submitted','10902030mjyTbS','company','resolvedSlug','warnings','diagramValidated'];a79_0x70bb=function(){return _0x5115f1;};return a79_0x70bb();}import{readRequiredSkillDiagramInput}from'./diagram.js';import{throwIfSkillValidationFailed,validateSkillDirectory}from'./validate.js';function a79_0x4757(_0x2cc2b4,_0xfc3314){_0x2cc2b4=_0x2cc2b4-0x1ce;const _0x70bbe=a79_0x70bb();let _0x475778=_0x70bbe[_0x2cc2b4];return _0x475778;}export async function skillPushDryRun(_0x348593){const _0x39f122=a79_0x4757,{getRuntimeSkillByCode:_0x31ce5e,validateRuntimeSkillPublish:_0x183afe}=await import(_0x39f122(0x1d9)),{readPushDirectory:_0x42022c,resolvePushDirectoryIdentity:_0x3af09e}=await import(_0x39f122(0x201));if(!_0x348593[_0x39f122(0x1e5)])throw CliErrors['authRequired']();const _0x2761bb=resolvePushScope(_0x348593),_0x1253ca=validateSkillDirectory(_0x348593[_0x39f122(0x206)](_0x39f122(0x1fe)));throwIfSkillValidationFailed(_0x1253ca);const {diagram:_0x9a5832,sourceFilePath:_0xdb973f}=await readRequiredSkillDiagramInput(_0x348593[_0x39f122(0x206)](_0x39f122(0x1df))),_0x592a6f=diagramPackageExclusion(_0xdb973f),_0x4cca17=_0x3af09e(_0x1253ca[_0x39f122(0x1fe)],_0x348593[_0x39f122(0x1d4)],remoteFirstMetadataOptions()),_0x36f7fd=await _0x31ce5e(_0x348593[_0x39f122(0x1d4)],_0x4cca17[_0x39f122(0x1e7)]);throwIfBuiltinPushTarget(_0x36f7fd);if(_0x2761bb===_0x39f122(0x1ce)){const _0x1b2d52=_0x42022c(_0x1253ca[_0x39f122(0x1fe)],_0x348593[_0x39f122(0x1d4)],{...remoteMissingCompanyReadOptions(),..._0x592a6f}),_0x7bb93d=await _0x183afe(_0x348593[_0x39f122(0x1d4)],withDiagram(_0x1b2d52[_0x39f122(0x1d5)],_0x9a5832),{'visibility':'NAMESPACE_ONLY'});return{'method':_0x39f122(0x1d2),'url':_0x39f122(0x1f4)+_0x348593['appCode']+_0x39f122(0x1e3),'body':{'skillCode':_0x1b2d52[_0x39f122(0x1e7)],'visibility':_0x39f122(0x1e0),'valid':_0x7bb93d['valid'],'errors':_0x7bb93d[_0x39f122(0x200)],'warnings':_0x7bb93d[_0x39f122(0x1d0)],'resolvedSlug':_0x7bb93d[_0x39f122(0x1cf)],'resolvedVersion':_0x7bb93d[_0x39f122(0x1d3)],'diagramValidated':_0x7bb93d[_0x39f122(0x1d1)]},'description':'Validate\x20a\x20company\x20Skill\x20push\x20package\x20without\x20creating\x20a\x20version\x20or\x20review\x20task.'};}if(_0x36f7fd&&_0x36f7fd['scope']!==_0x39f122(0x1f0))throw CliErrors[_0x39f122(0x1ff)](_0x39f122(0x202)+_0x4cca17[_0x39f122(0x1e7)]+_0x39f122(0x1e1)+(_0x36f7fd[_0x39f122(0x1dc)]??_0x39f122(0x1d7))+'\x22.');const _0x312cc6=_0x42022c(_0x1253ca[_0x39f122(0x1fe)],_0x348593[_0x39f122(0x1d4)],{..._0x36f7fd?remotePersonalReadOptions(!![]):remoteMissingPersonalReadOptions(),..._0x592a6f}),_0x2b98e8=await _0x183afe(_0x348593['appCode'],withDiagram(_0x312cc6['input'],_0x9a5832),{'visibility':'PRIVATE'});return{'method':'POST','url':_0x39f122(0x1f4)+_0x348593[_0x39f122(0x1d4)]+_0x39f122(0x1e3),'body':{'skillCode':_0x312cc6['skillCode'],'visibility':_0x39f122(0x1e9),'valid':_0x2b98e8[_0x39f122(0x1e8)],'errors':_0x2b98e8[_0x39f122(0x200)],'warnings':_0x2b98e8[_0x39f122(0x1d0)],'resolvedSlug':_0x2b98e8[_0x39f122(0x1cf)],'resolvedVersion':_0x2b98e8['resolvedVersion'],'diagramValidated':_0x2b98e8[_0x39f122(0x1d1)]},'description':'Validate\x20a\x20personal\x20Skill\x20push\x20package\x20without\x20creating\x20or\x20updating\x20a\x20remote\x20Skill.'};}export async function skillPushExecute(_0x33d465){const _0x40047e=a79_0x4757,{createPersonalRuntimeSkill:_0x4c3852,downloadRuntimeSkillPackage:_0x74d4ad,getRuntimeSkillByCode:_0xbe0852,publishCompanyRuntimeSkill:_0x3e123b,updatePersonalRuntimeSkill:_0x3b4674,validateRuntimeSkillPublish:_0x2225fe}=await import(_0x40047e(0x1d9)),{verifyRuntimeSkillPackage:_0x30f77c,verifyRuntimeSkillBundle:_0x3e880c,readPushDirectory:_0x1502f0,refreshPushDirectoryMetadataFromRemote:_0x57a663,recordPushedRuntimeSkill:_0x1b9225,resolvePushDirectoryIdentity:_0x19c490}=await import('../../skills/runtime-skill-sync.js');if(!_0x33d465[_0x40047e(0x1e5)])throw CliErrors[_0x40047e(0x1d8)]();const _0x53e018=resolvePushScope(_0x33d465),_0x28373c=_0x33d465[_0x40047e(0x1e2)]('confirm-warnings')||_0x33d465[_0x40047e(0x1e2)](_0x40047e(0x1ee)),_0x527920=validateSkillDirectory(_0x33d465[_0x40047e(0x206)](_0x40047e(0x1fe)));throwIfSkillValidationFailed(_0x527920);const {diagram:_0x5a6e43,sourceFilePath:_0x18352e}=await readRequiredSkillDiagramInput(_0x33d465[_0x40047e(0x206)](_0x40047e(0x1df))),_0x4e8c3f=diagramPackageExclusion(_0x18352e),_0x1e39f1=_0x527920[_0x40047e(0x1fe)];let _0x5677c9;if(_0x53e018==='company'){const _0x1a230e=_0x19c490(_0x1e39f1,_0x33d465[_0x40047e(0x1d4)],remoteFirstMetadataOptions()),_0x4a8b59=await _0xbe0852(_0x33d465['appCode'],_0x1a230e['skillCode']);throwIfBuiltinPushTarget(_0x4a8b59);if(_0x4a8b59)_0x57a663(_0x1e39f1,_0x4a8b59,_0x33d465[_0x40047e(0x1d4)]);const _0x467214=_0x1502f0(_0x1e39f1,_0x33d465[_0x40047e(0x1d4)],{..._0x4a8b59?{'targetScope':_0x40047e(0x1ce),'ignoreInvalidMetadata':!![]}:remoteMissingCompanyReadOptions(),..._0x4e8c3f});_0x5677c9={'scope':_0x40047e(0x1ce),'payload':_0x467214,'publishInput':withDiagram(_0x467214['input'],_0x5a6e43),'remoteForPreflight':_0x4a8b59,'warnings':[]};}else{const _0x45fdfa=_0x33d465[_0x40047e(0x206)](_0x40047e(0x1f3))['trim'](),_0x5a1d6d=Boolean(_0x45fdfa),_0x3500c6=allowRetargetArgs(_0x5a1d6d),_0x4ec2d1=_0x19c490(_0x1e39f1,_0x33d465[_0x40047e(0x1d4)],{...remoteFirstMetadataOptions(),..._0x3500c6[0x0]}),_0x2cfd09=await _0xbe0852(_0x33d465[_0x40047e(0x1d4)],_0x4ec2d1[_0x40047e(0x1e7)]);throwIfBuiltinPushTarget(_0x2cfd09);if(_0x2cfd09){if(_0x2cfd09[_0x40047e(0x1dc)]!==_0x40047e(0x1f0)){if(_0x5a1d6d)throw CliErrors[_0x40047e(0x1ff)](_0x40047e(0x202)+_0x4ec2d1['skillCode']+'\x20has\x20scope=\x22'+(_0x2cfd09[_0x40047e(0x1dc)]??_0x40047e(0x1d7))+'\x22.');_0x57a663(_0x1e39f1,_0x2cfd09,_0x33d465['appCode']);}else!_0x5a1d6d&&_0x57a663(_0x1e39f1,_0x2cfd09,_0x33d465[_0x40047e(0x1d4)]);}const _0x4dc87d=_0x1502f0(_0x1e39f1,_0x33d465['appCode'],{..._0x2cfd09?remotePersonalReadOptions(_0x5a1d6d,_0x3500c6[0x0]):remoteMissingPersonalReadOptions(_0x3500c6[0x0]),..._0x4e8c3f}),_0x4b1f59=_0x2cfd09?.[_0x40047e(0x1dc)]===_0x40047e(0x1f0)&&_0x2cfd09[_0x40047e(0x1e7)]===_0x4dc87d[_0x40047e(0x1e7)]?_0x2cfd09:undefined,_0x22c513=_0x5a1d6d&&_0x4b1f59?withRetargetExistingMetadata(_0x4dc87d['input'],_0x4b1f59,{'preferInputSkillName':Boolean(_0x4dc87d[_0x40047e(0x1ea)])}):_0x4dc87d[_0x40047e(0x1d5)],_0x447aea=_0x5a1d6d?buildRetargetWarning(_0x4ec2d1['metadata'],_0x33d465[_0x40047e(0x1d4)]):[];_0x5677c9={'scope':_0x40047e(0x1f0),'payload':_0x4dc87d,'publishInput':withDiagram(_0x22c513,_0x5a6e43),'remoteForPreflight':_0x4b1f59,'existing':_0x4b1f59,'warnings':[..._0x527920[_0x40047e(0x1d0)],..._0x447aea]};}const _0x1c3b61=await runRemoteContentPreflight({'scope':_0x5677c9[_0x40047e(0x1dc)],'remote':_0x5677c9[_0x40047e(0x1f1)],'publishInput':_0x5677c9['publishInput'],'skillCode':_0x5677c9[_0x40047e(0x204)][_0x40047e(0x1e7)],'appCode':_0x33d465[_0x40047e(0x1d4)],'downloadRuntimeSkillPackage':_0x74d4ad,'verifyRuntimeSkillBundle':_0x3e880c});if(_0x1c3b61[_0x40047e(0x205)]==='identical')return _0x5677c9[_0x40047e(0x1dc)]===_0x40047e(0x1ce)?_0x1b9225(_0x1e39f1,_0x1c3b61[_0x40047e(0x1f8)],_0x33d465['appCode'],{'scope':_0x40047e(0x1ce)}):_0x1b9225(_0x1e39f1,_0x1c3b61[_0x40047e(0x1f8)],_0x33d465[_0x40047e(0x1d4)]),{'ok':!![],'data':{...summarizeRuntimeSkill(_0x1c3b61[_0x40047e(0x1f8)]),'scope':_0x5677c9[_0x40047e(0x1dc)],..._0x5677c9[_0x40047e(0x1dc)]===_0x40047e(0x1f0)?{'warnings':_0x5677c9['warnings']}:{},'alreadyPublished':!![],'contentIdentical':!![],'diagramSubmitted':![]},'message':scopeLabel(_0x5677c9[_0x40047e(0x1dc)])+_0x40047e(0x1e6)+_0x5677c9['payload']['skillCode']+_0x40047e(0x1db)};if(_0x5677c9['scope']===_0x40047e(0x1ce)){const _0x2f59c2=await _0x2225fe(_0x33d465[_0x40047e(0x1d4)],_0x5677c9[_0x40047e(0x1ef)],{'visibility':_0x40047e(0x1e0)});throwIfPublishValidationFailed(_0x40047e(0x1ce),_0x5677c9['payload']['skillCode'],_0x2f59c2),throwIfUnconfirmedPublishWarnings(_0x40047e(0x1ce),_0x5677c9[_0x40047e(0x204)][_0x40047e(0x1e7)],_0x2f59c2[_0x40047e(0x1d0)],_0x28373c);const _0x1a8cd0=await _0x3e123b(_0x33d465[_0x40047e(0x1d4)],_0x5677c9[_0x40047e(0x1ef)],{'confirmWarnings':_0x28373c});return _0x1b9225(_0x1e39f1,{..._0x1a8cd0,'files':_0x5677c9['publishInput'][_0x40047e(0x1eb)]},_0x33d465[_0x40047e(0x1d4)],{'scope':'company'}),{'ok':!![],'data':{...summarizeRuntimeSkill(_0x1a8cd0),'scope':_0x40047e(0x1ce),'reviewState':_0x40047e(0x207),'submittedForReview':!![],'diagramBound':!![],'validation':{'warnings':_0x2f59c2[_0x40047e(0x1d0)]}},'message':_0x40047e(0x1fd)+_0x5677c9['payload']['skillCode']+_0x40047e(0x1ed)+(_0x1a8cd0[_0x40047e(0x203)]??'(unknown)')+_0x40047e(0x1f6)};}const _0x22c461=await _0x2225fe(_0x33d465['appCode'],_0x5677c9[_0x40047e(0x1ef)],{'visibility':'PRIVATE'});throwIfPublishValidationFailed(_0x40047e(0x1f0),_0x5677c9[_0x40047e(0x204)][_0x40047e(0x1e7)],_0x22c461),throwIfUnconfirmedPublishWarnings('personal',_0x5677c9[_0x40047e(0x204)][_0x40047e(0x1e7)],_0x22c461[_0x40047e(0x1d0)],_0x28373c);const _0x5ecefd={'confirmWarnings':_0x28373c},_0x3cdd8e=_0x5677c9[_0x40047e(0x1da)]?await _0x3b4674(_0x5677c9[_0x40047e(0x204)][_0x40047e(0x1e7)],_0x33d465['appCode'],_0x5677c9[_0x40047e(0x1ef)],_0x5ecefd):await _0x4c3852(_0x33d465[_0x40047e(0x1d4)],_0x5677c9['publishInput'],_0x5ecefd);let _0x1c00f5=_0x3cdd8e;if(isMultiFileManifest(_0x5677c9[_0x40047e(0x1ef)][_0x40047e(0x1eb)])){const _0x38924c=await _0x74d4ad('personal',_0x3cdd8e[_0x40047e(0x1e7)]||_0x5677c9[_0x40047e(0x204)][_0x40047e(0x1e7)],_0x33d465[_0x40047e(0x1d4)]);_0x3e880c(_0x5677c9[_0x40047e(0x1ef)][_0x40047e(0x1eb)],_0x38924c),_0x1c00f5={..._0x3cdd8e,'files':_0x5677c9[_0x40047e(0x1ef)][_0x40047e(0x1eb)]};}else{if(isPackageBackedManifest(_0x3cdd8e[_0x40047e(0x1eb)])){const _0x3a2ee8=await _0x74d4ad(_0x40047e(0x1f0),_0x3cdd8e[_0x40047e(0x1e7)]||_0x5677c9[_0x40047e(0x204)][_0x40047e(0x1e7)],_0x33d465['appCode']);_0x30f77c(_0x3cdd8e[_0x40047e(0x1eb)],_0x3a2ee8);}}return _0x1b9225(_0x1e39f1,_0x1c00f5,_0x33d465[_0x40047e(0x1d4)]),{'ok':!![],'data':{...summarizeRuntimeSkill(_0x3cdd8e),'warnings':_0x5677c9[_0x40047e(0x1d0)],'validation':{'warnings':_0x22c461['warnings']},'diagramBound':!![]},'message':_0x5677c9[_0x40047e(0x1da)]?_0x40047e(0x1fc)+_0x5677c9['payload']['skillCode']:_0x40047e(0x1f7)+_0x5677c9[_0x40047e(0x204)]['skillCode']};}function scopeLabel(_0x16d987){const _0x2488e1=a79_0x4757;return _0x16d987===_0x2488e1(0x1ce)?_0x2488e1(0x1de):'Personal';}function withDiagram(_0x491729,_0x45fbda){return{..._0x491729,'diagram':_0x45fbda};}function diagramPackageExclusion(_0x5f1f09){return _0x5f1f09?{'excludedFilePaths':[_0x5f1f09]}:{};}
|
|
1
|
+
function a79_0x3e35(){const _0x557836=['42HcBzkl','scope','\x20Skill\x20','Updated\x20personal\x20Skill\x20','8tEEoKg','1521254glFqUY','Validate\x20a\x20personal\x20Skill\x20push\x20package\x20without\x20creating\x20or\x20updating\x20a\x20remote\x20Skill.','frontmatterDisplayName','Validate\x20a\x20company\x20Skill\x20push\x20package\x20without\x20creating\x20a\x20version\x20or\x20review\x20task.','514195aKUDMf','confirmWarnings','errors','Created\x20personal\x20Skill\x20','appcode','status','(unknown)','validation','diagram-file','Personal','savedSkill','Only\x20personal\x20Skills\x20can\x20be\x20pushed;\x20remote\x20Skill\x20','personal','8071640aRqpKh','../../skills/runtime-skill-sync.js','unknown','authRequired','dir','PRIVATE','submitted','str','trim','identical','payload','975294LZtHoq','5327904smcjMR','\x20for\x20review','/publish/validate','confirm-warnings','files','accessKey','existing','version','48915SLviBp','../../core/api-client.js','130873JABtVh','NAMESPACE_ONLY','warnings','company','1384xyLEJj','skillCode','/api/cli/v1/skills/','\x20has\x20scope=\x22','appCode','resolvedVersion','resolvedSlug','\x20version\x20','input','bool','publishInput','diagramValidated'];a79_0x3e35=function(){return _0x557836;};return a79_0x3e35();}(function(_0xe764c7,_0x5f1476){const _0x4a48f1=a79_0x1acb,_0x63821c=_0xe764c7();while(!![]){try{const _0x7ced5f=parseInt(_0x4a48f1(0x1f2))/0x1*(-parseInt(_0x4a48f1(0x206))/0x2)+parseInt(_0x4a48f1(0x1e7))/0x3+parseInt(_0x4a48f1(0x1e8))/0x4+parseInt(_0x4a48f1(0x20b))/0x5*(-parseInt(_0x4a48f1(0x202))/0x6)+parseInt(_0x4a48f1(0x207))/0x7+parseInt(_0x4a48f1(0x1f6))/0x8*(parseInt(_0x4a48f1(0x1f0))/0x9)+-parseInt(_0x4a48f1(0x1dc))/0xa;if(_0x7ced5f===_0x5f1476)break;else _0x63821c['push'](_0x63821c['shift']());}catch(_0xd7a0f4){_0x63821c['push'](_0x63821c['shift']());}}}(a79_0x3e35,0xba8da));function a79_0x1acb(_0x582006,_0x798a8d){_0x582006=_0x582006-0x1d6;const _0x3e3591=a79_0x3e35();let _0x1acb92=_0x3e3591[_0x582006];return _0x1acb92;}import{CliErrors}from'../../errors.js';import{isMultiFileManifest,isPackageBackedManifest}from'./manifest-helpers.js';import{remotePersonalReadOptions,remoteMissingCompanyReadOptions,remoteMissingPersonalReadOptions}from'./push-flow-helpers.js';import{allowRetargetArgs,buildRetargetWarning,remoteFirstMetadataOptions,resolvePushScope,runRemoteContentPreflight,throwIfBuiltinPushTarget,throwIfUnconfirmedPublishWarnings,throwIfPublishValidationFailed}from'./push-flow-helpers.js';import{withRetargetExistingMetadata}from'./push-retarget.js';import{summarizeRuntimeSkill}from'./summary.js';import{readRequiredSkillDiagramInput}from'./diagram.js';import{throwIfSkillValidationFailed,validateSkillDirectory}from'./validate.js';export async function skillPushDryRun(_0x455ff6){const _0x346688=a79_0x1acb,{getRuntimeSkillByCode:_0x5e123c,validateRuntimeSkillPublish:_0x4d597f}=await import(_0x346688(0x1f1)),{readPushDirectory:_0x5ce0fb,resolvePushDirectoryIdentity:_0x18525f}=await import('../../skills/runtime-skill-sync.js');if(!_0x455ff6['accessKey'])throw CliErrors[_0x346688(0x1df)]();const _0x3a65cd=resolvePushScope(_0x455ff6),_0x2e77e2=validateSkillDirectory(_0x455ff6[_0x346688(0x1e3)](_0x346688(0x1e0)));throwIfSkillValidationFailed(_0x2e77e2);const {diagram:_0x2d8bd6,sourceFilePath:_0x5c286d}=await readRequiredSkillDiagramInput(_0x455ff6[_0x346688(0x1e3)]('diagram-file')),_0x4f9c02=diagramPackageExclusion(_0x5c286d),_0x174d70=_0x18525f(_0x2e77e2['dir'],_0x455ff6[_0x346688(0x1fa)],remoteFirstMetadataOptions()),_0x57fea7=await _0x5e123c(_0x455ff6[_0x346688(0x1fa)],_0x174d70[_0x346688(0x1f7)]);throwIfBuiltinPushTarget(_0x57fea7);if(_0x3a65cd===_0x346688(0x1f5)){const _0x24ca34=_0x5ce0fb(_0x2e77e2[_0x346688(0x1e0)],_0x455ff6[_0x346688(0x1fa)],{...remoteMissingCompanyReadOptions(),..._0x4f9c02}),_0x42e026=await _0x4d597f(_0x455ff6[_0x346688(0x1fa)],withDiagram(_0x24ca34[_0x346688(0x1fe)],_0x2d8bd6),{'visibility':'NAMESPACE_ONLY'});return{'method':'POST','url':_0x346688(0x1f8)+_0x455ff6[_0x346688(0x1fa)]+'/publish/validate','body':{'skillCode':_0x24ca34['skillCode'],'visibility':'NAMESPACE_ONLY','valid':_0x42e026['valid'],'errors':_0x42e026[_0x346688(0x20d)],'warnings':_0x42e026[_0x346688(0x1f4)],'resolvedSlug':_0x42e026[_0x346688(0x1fc)],'resolvedVersion':_0x42e026[_0x346688(0x1fb)],'diagramValidated':_0x42e026['diagramValidated']},'description':_0x346688(0x20a)};}if(_0x57fea7&&_0x57fea7[_0x346688(0x203)]!==_0x346688(0x1db))throw CliErrors['validation'](_0x346688(0x1da)+_0x174d70['skillCode']+'\x20has\x20scope=\x22'+(_0x57fea7['scope']??_0x346688(0x1de))+'\x22.');const _0x421fd7=_0x5ce0fb(_0x2e77e2[_0x346688(0x1e0)],_0x455ff6[_0x346688(0x1fa)],{..._0x57fea7?remotePersonalReadOptions(!![]):remoteMissingPersonalReadOptions(),..._0x4f9c02}),_0x3aba18=await _0x4d597f(_0x455ff6['appCode'],withDiagram(_0x421fd7[_0x346688(0x1fe)],_0x2d8bd6),{'visibility':_0x346688(0x1e1)});return{'method':'POST','url':_0x346688(0x1f8)+_0x455ff6[_0x346688(0x1fa)]+_0x346688(0x1ea),'body':{'skillCode':_0x421fd7['skillCode'],'visibility':_0x346688(0x1e1),'valid':_0x3aba18['valid'],'errors':_0x3aba18[_0x346688(0x20d)],'warnings':_0x3aba18['warnings'],'resolvedSlug':_0x3aba18[_0x346688(0x1fc)],'resolvedVersion':_0x3aba18['resolvedVersion'],'diagramValidated':_0x3aba18[_0x346688(0x201)]},'description':_0x346688(0x208)};}export async function skillPushExecute(_0x3b05be){const _0x153f38=a79_0x1acb,{createPersonalRuntimeSkill:_0xe847db,downloadRuntimeSkillPackage:_0x261e01,getRuntimeSkillByCode:_0x292b77,publishCompanyRuntimeSkill:_0x423a42,updatePersonalRuntimeSkill:_0xb02bd5,validateRuntimeSkillPublish:_0x10e098}=await import(_0x153f38(0x1f1)),{verifyRuntimeSkillPackage:_0x47ac03,verifyRuntimeSkillBundle:_0x2fec11,readPushDirectory:_0x3d1acf,refreshPushDirectoryMetadataFromRemote:_0x2a3684,recordPushedRuntimeSkill:_0x31e756,resolvePushDirectoryIdentity:_0x42ff46}=await import(_0x153f38(0x1dd));if(!_0x3b05be[_0x153f38(0x1ed)])throw CliErrors[_0x153f38(0x1df)]();const _0x2c2541=resolvePushScope(_0x3b05be),_0x3e2c14=_0x3b05be[_0x153f38(0x1ff)](_0x153f38(0x1eb))||_0x3b05be[_0x153f38(0x1ff)](_0x153f38(0x20c)),_0x30ef89=validateSkillDirectory(_0x3b05be[_0x153f38(0x1e3)](_0x153f38(0x1e0)));throwIfSkillValidationFailed(_0x30ef89);const {diagram:_0x8ab6e9,sourceFilePath:_0x18b95b}=await readRequiredSkillDiagramInput(_0x3b05be[_0x153f38(0x1e3)](_0x153f38(0x1d7))),_0x2ef7a9=diagramPackageExclusion(_0x18b95b),_0x58ae00=_0x30ef89[_0x153f38(0x1e0)];let _0x5f7a78;if(_0x2c2541===_0x153f38(0x1f5)){const _0x54e206=_0x42ff46(_0x58ae00,_0x3b05be[_0x153f38(0x1fa)],remoteFirstMetadataOptions()),_0x27e954=await _0x292b77(_0x3b05be[_0x153f38(0x1fa)],_0x54e206[_0x153f38(0x1f7)]);throwIfBuiltinPushTarget(_0x27e954);if(_0x27e954)_0x2a3684(_0x58ae00,_0x27e954,_0x3b05be['appCode']);const _0xfbd519=_0x3d1acf(_0x58ae00,_0x3b05be['appCode'],{..._0x27e954?{'targetScope':'company','ignoreInvalidMetadata':!![]}:remoteMissingCompanyReadOptions(),..._0x2ef7a9});_0x5f7a78={'scope':'company','payload':_0xfbd519,'publishInput':withDiagram(_0xfbd519['input'],_0x8ab6e9),'remoteForPreflight':_0x27e954,'warnings':[]};}else{const _0x280723=_0x3b05be['str'](_0x153f38(0x20f))[_0x153f38(0x1e4)](),_0x2cb386=Boolean(_0x280723),_0x3fe7ac=allowRetargetArgs(_0x2cb386),_0x1f5f3b=_0x42ff46(_0x58ae00,_0x3b05be[_0x153f38(0x1fa)],{...remoteFirstMetadataOptions(),..._0x3fe7ac[0x0]}),_0x34ab28=await _0x292b77(_0x3b05be[_0x153f38(0x1fa)],_0x1f5f3b[_0x153f38(0x1f7)]);throwIfBuiltinPushTarget(_0x34ab28);if(_0x34ab28){if(_0x34ab28[_0x153f38(0x203)]!==_0x153f38(0x1db)){if(_0x2cb386)throw CliErrors[_0x153f38(0x1d6)](_0x153f38(0x1da)+_0x1f5f3b[_0x153f38(0x1f7)]+_0x153f38(0x1f9)+(_0x34ab28[_0x153f38(0x203)]??_0x153f38(0x1de))+'\x22.');_0x2a3684(_0x58ae00,_0x34ab28,_0x3b05be[_0x153f38(0x1fa)]);}else!_0x2cb386&&_0x2a3684(_0x58ae00,_0x34ab28,_0x3b05be[_0x153f38(0x1fa)]);}const _0x5df54f=_0x3d1acf(_0x58ae00,_0x3b05be[_0x153f38(0x1fa)],{..._0x34ab28?remotePersonalReadOptions(_0x2cb386,_0x3fe7ac[0x0]):remoteMissingPersonalReadOptions(_0x3fe7ac[0x0]),..._0x2ef7a9}),_0x3771e9=_0x34ab28?.['scope']===_0x153f38(0x1db)&&_0x34ab28['skillCode']===_0x5df54f[_0x153f38(0x1f7)]?_0x34ab28:undefined,_0x4fb77f=_0x2cb386&&_0x3771e9?withRetargetExistingMetadata(_0x5df54f['input'],_0x3771e9,{'preferInputSkillName':Boolean(_0x5df54f[_0x153f38(0x209)])}):_0x5df54f['input'],_0x5e71d2=_0x2cb386?buildRetargetWarning(_0x1f5f3b['metadata'],_0x3b05be[_0x153f38(0x1fa)]):[];_0x5f7a78={'scope':_0x153f38(0x1db),'payload':_0x5df54f,'publishInput':withDiagram(_0x4fb77f,_0x8ab6e9),'remoteForPreflight':_0x3771e9,'existing':_0x3771e9,'warnings':[..._0x30ef89[_0x153f38(0x1f4)],..._0x5e71d2]};}const _0x5947fd=await runRemoteContentPreflight({'scope':_0x5f7a78[_0x153f38(0x203)],'remote':_0x5f7a78['remoteForPreflight'],'publishInput':_0x5f7a78[_0x153f38(0x200)],'skillCode':_0x5f7a78[_0x153f38(0x1e6)][_0x153f38(0x1f7)],'appCode':_0x3b05be[_0x153f38(0x1fa)],'downloadRuntimeSkillPackage':_0x261e01,'verifyRuntimeSkillBundle':_0x2fec11});if(_0x5947fd[_0x153f38(0x210)]===_0x153f38(0x1e5))return _0x5f7a78['scope']==='company'?_0x31e756(_0x58ae00,_0x5947fd[_0x153f38(0x1d9)],_0x3b05be[_0x153f38(0x1fa)],{'scope':_0x153f38(0x1f5)}):_0x31e756(_0x58ae00,_0x5947fd[_0x153f38(0x1d9)],_0x3b05be[_0x153f38(0x1fa)]),{'ok':!![],'data':{...summarizeRuntimeSkill(_0x5947fd[_0x153f38(0x1d9)]),'scope':_0x5f7a78['scope'],..._0x5f7a78['scope']==='personal'?{'warnings':_0x5f7a78[_0x153f38(0x1f4)]}:{},'alreadyPublished':!![],'contentIdentical':!![],'diagramSubmitted':![]},'message':scopeLabel(_0x5f7a78[_0x153f38(0x203)])+_0x153f38(0x204)+_0x5f7a78[_0x153f38(0x1e6)]['skillCode']+'\x20is\x20already\x20published\x20and\x20content\x20is\x20identical'};if(_0x5f7a78[_0x153f38(0x203)]===_0x153f38(0x1f5)){const _0x460dd7=await _0x10e098(_0x3b05be[_0x153f38(0x1fa)],_0x5f7a78[_0x153f38(0x200)],{'visibility':_0x153f38(0x1f3)});throwIfPublishValidationFailed('company',_0x5f7a78[_0x153f38(0x1e6)][_0x153f38(0x1f7)],_0x460dd7),throwIfUnconfirmedPublishWarnings('company',_0x5f7a78[_0x153f38(0x1e6)][_0x153f38(0x1f7)],_0x460dd7['warnings'],_0x3e2c14);const _0x4e6427=await _0x423a42(_0x3b05be['appCode'],_0x5f7a78[_0x153f38(0x200)],{'confirmWarnings':_0x3e2c14});return _0x31e756(_0x58ae00,{..._0x4e6427,'files':_0x5f7a78[_0x153f38(0x200)][_0x153f38(0x1ec)]},_0x3b05be[_0x153f38(0x1fa)],{'scope':_0x153f38(0x1f5)}),{'ok':!![],'data':{...summarizeRuntimeSkill(_0x4e6427),'scope':_0x153f38(0x1f5),'reviewState':_0x153f38(0x1e2),'submittedForReview':!![],'diagramBound':!![],'validation':{'warnings':_0x460dd7[_0x153f38(0x1f4)]}},'message':'Submitted\x20company\x20Skill\x20'+_0x5f7a78[_0x153f38(0x1e6)][_0x153f38(0x1f7)]+_0x153f38(0x1fd)+(_0x4e6427[_0x153f38(0x1ef)]??_0x153f38(0x211))+_0x153f38(0x1e9)};}const _0x45ae0c=await _0x10e098(_0x3b05be[_0x153f38(0x1fa)],_0x5f7a78[_0x153f38(0x200)],{'visibility':_0x153f38(0x1e1)});throwIfPublishValidationFailed(_0x153f38(0x1db),_0x5f7a78[_0x153f38(0x1e6)][_0x153f38(0x1f7)],_0x45ae0c),throwIfUnconfirmedPublishWarnings(_0x153f38(0x1db),_0x5f7a78[_0x153f38(0x1e6)][_0x153f38(0x1f7)],_0x45ae0c[_0x153f38(0x1f4)],_0x3e2c14);const _0x43dbf9={'confirmWarnings':_0x3e2c14},_0x18f8fe=_0x5f7a78[_0x153f38(0x1ee)]?await _0xb02bd5(_0x5f7a78['payload'][_0x153f38(0x1f7)],_0x3b05be['appCode'],_0x5f7a78['publishInput'],_0x43dbf9):await _0xe847db(_0x3b05be[_0x153f38(0x1fa)],_0x5f7a78['publishInput'],_0x43dbf9);let _0xf5f691=_0x18f8fe;if(isMultiFileManifest(_0x5f7a78[_0x153f38(0x200)][_0x153f38(0x1ec)])){const _0x3f6508=await _0x261e01(_0x153f38(0x1db),_0x18f8fe['skillCode']||_0x5f7a78[_0x153f38(0x1e6)][_0x153f38(0x1f7)],_0x3b05be[_0x153f38(0x1fa)]);_0x2fec11(_0x5f7a78[_0x153f38(0x200)][_0x153f38(0x1ec)],_0x3f6508),_0xf5f691={..._0x18f8fe,'files':_0x5f7a78[_0x153f38(0x200)]['files']};}else{if(isPackageBackedManifest(_0x18f8fe[_0x153f38(0x1ec)])){const _0x1b73aa=await _0x261e01(_0x153f38(0x1db),_0x18f8fe[_0x153f38(0x1f7)]||_0x5f7a78[_0x153f38(0x1e6)][_0x153f38(0x1f7)],_0x3b05be[_0x153f38(0x1fa)]);_0x47ac03(_0x18f8fe['files'],_0x1b73aa);}}return _0x31e756(_0x58ae00,_0xf5f691,_0x3b05be[_0x153f38(0x1fa)]),{'ok':!![],'data':{...summarizeRuntimeSkill(_0x18f8fe),'warnings':_0x5f7a78['warnings'],'validation':{'warnings':_0x45ae0c[_0x153f38(0x1f4)]},'diagramBound':!![]},'message':_0x5f7a78[_0x153f38(0x1ee)]?_0x153f38(0x205)+_0x5f7a78[_0x153f38(0x1e6)][_0x153f38(0x1f7)]:_0x153f38(0x20e)+_0x5f7a78['payload']['skillCode']};}function scopeLabel(_0x457820){const _0x39ec59=a79_0x1acb;return _0x457820===_0x39ec59(0x1f5)?'Company':_0x39ec59(0x1d8);}function withDiagram(_0x491156,_0xb585ac){return{..._0x491156,'diagram':_0xb585ac};}function diagramPackageExclusion(_0x4b26c2){return _0x4b26c2?{'excludedFilePaths':[_0x4b26c2]}:{};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a80_0xd309(){const _0x1c3e34=['publishInput','\x20after\x20successful\x20push.','identical','874036cIpdjv','Review\x20each\x20warning\x20before\x20continuing.','\x20was\x20retargeted\x20to\x20explicit\x20appCode\x20','appCode','(unknown)','394imJDEn','Local\x20Skill\x20metadata\x20appCode\x20','files','remote','skillCode','9LnNePP','Warnings:\x20','downloadRuntimeSkillPackage','lovrabet.skill.json','12100oFNaFi','SkillHub\x20validation\x20returned\x20invalid.','company','Personal','1552788WWctif','\x20Skill\x20push\x20validation\x20reported\x20warning(s)\x20for\x20','length','skill-metadata-appcode-retargeted','warning','Review\x20the\x20updated\x20local\x20Skill\x20metadata\x20before\x20the\x20next\x20push.','verifyRuntimeSkillBundle','version','5471541AdQuGg','\x20Skill\x20push\x20validation\x20failed\x20for\x20','join','5azgNAZ','259987Trenzd','warnings','4485KPcSbQ','builtin','Builtin\x20Skill\x20','\x20cannot\x20be\x20pushed.','Fix\x20real\x20issues.\x20If\x20the\x20remaining\x20warnings\x20are\x20reviewed\x20false\x20positives,\x20rerun\x20with\x20--confirm-warnings\x20to\x20submit\x20the\x20unchanged\x20package.','1930kvZVyE','valid','104ATcHMe','content','skill\x20push\x20supports\x20--scope\x20personal\x20or\x20--scope\x20company;\x20received\x20\x22','Do\x20not\x20modify\x20the\x20source\x20Skill\x20merely\x20to\x20satisfy\x20publishing.','Company','29982420dtdNKI','validation','errors','scope','not-applicable'];a80_0xd309=function(){return _0x1c3e34;};return a80_0xd309();}(function(_0x544b49,_0x4a0a7a){const _0x3f30de=a80_0x3c82,_0x1ce659=_0x544b49();while(!![]){try{const _0x29dae9=parseInt(_0x3f30de(0x99))/0x1*(-parseInt(_0x3f30de(0x7e))/0x2)+-parseInt(_0x3f30de(0x83))/0x3*(parseInt(_0x3f30de(0xad))/0x4)+-parseInt(_0x3f30de(0x96))/0x5*(parseInt(_0x3f30de(0x8b))/0x6)+-parseInt(_0x3f30de(0x97))/0x7*(parseInt(_0x3f30de(0xa0))/0x8)+parseInt(_0x3f30de(0x93))/0x9+-parseInt(_0x3f30de(0x9e))/0xa*(parseInt(_0x3f30de(0x87))/0xb)+parseInt(_0x3f30de(0xa5))/0xc;if(_0x29dae9===_0x4a0a7a)break;else _0x1ce659['push'](_0x1ce659['shift']());}catch(_0x1ca521){_0x1ce659['push'](_0x1ce659['shift']());}}}(a80_0xd309,0x95c69));import{CliErrors}from'../../errors.js';export function resolvePushScope(_0x57690a){const _0x1077ad=a80_0x3c82,_0xc46702=_0x57690a['str'](_0x1077ad(0xa8))||'personal';if(_0xc46702==='personal'||_0xc46702==='company')return _0xc46702;throw CliErrors[_0x1077ad(0xa6)](_0x1077ad(0xa2)+_0xc46702+'\x22.');}export function allowRetargetArgs(_0x81479){return _0x81479?[{'allowAppCodeRetarget':!![]}]:[];}export function remoteFirstMetadataOptions(){return{'ignoreInvalidMetadata':!![],'ignoreMetadataAppCodeMismatch':!![],'ignoreMetadataSkillCode':!![]};}function a80_0x3c82(_0x271a0a,_0x5528f1){_0x271a0a=_0x271a0a-0x7d;const _0xd3096=a80_0xd309();let _0x3c82da=_0xd3096[_0x271a0a];return _0x3c82da;}export function remoteMissingPayloadOptions(){return{'ignoreMetadataForPayload':!![],'ignoreMetadataScope':!![],'ignoreMetadataSkillCode':!![]};}export function remoteMissingCompanyReadOptions(){const _0x3b103b=a80_0x3c82;return{'targetScope':_0x3b103b(0x89),...remoteFirstMetadataOptions(),...remoteMissingPayloadOptions()};}export function remoteMissingPersonalReadOptions(_0x38bdb3={}){return{...remoteFirstMetadataOptions(),...remoteMissingPayloadOptions(),..._0x38bdb3};}export function remotePersonalReadOptions(_0x480e7d,_0x289e9f={}){return{'ignoreInvalidMetadata':!![],..._0x480e7d?{'ignoreMetadataAppCodeMismatch':!![],'ignoreMetadataScope':!![]}:{},..._0x289e9f};}export function throwIfBuiltinPushTarget(_0x333dc4){const _0x446556=a80_0x3c82;if(_0x333dc4?.[_0x446556(0xa8)]!==_0x446556(0x9a))return;throw CliErrors[_0x446556(0xa6)](_0x446556(0x9b)+(_0x333dc4[_0x446556(0x82)]??_0x446556(0x7d))+_0x446556(0x9c),'Use\x20a\x20different\x20skillCode\x20when\x20submitting\x20a\x20personal\x20or\x20company\x20Skill.');}export function throwIfPublishValidationFailed(_0x4a1eab,_0x276358,_0x1b77fb){const _0x569853=a80_0x3c82;if(_0x1b77fb[_0x569853(0xa7)][_0x569853(0x8d)]===0x0&&(_0x1b77fb[_0x569853(0x9f)]||_0x1b77fb[_0x569853(0x98)][_0x569853(0x8d)]>0x0))return;const _0x1dc535=_0x1b77fb[_0x569853(0xa7)][_0x569853(0x8d)]>0x0?_0x1b77fb[_0x569853(0xa7)][_0x569853(0x95)](';\x20'):_0x569853(0x88),_0x3a3122=_0x4a1eab===_0x569853(0x89)?_0x569853(0xa4):_0x569853(0x8a);throw CliErrors[_0x569853(0xa6)](_0x3a3122+_0x569853(0x94)+_0x276358+'.',_0x1dc535);}export function throwIfUnconfirmedPublishWarnings(_0x3f94e4,_0x233c2b,_0x213638,_0x5fcbe0){const _0x44915f=a80_0x3c82;if(_0x213638[_0x44915f(0x8d)]===0x0||_0x5fcbe0)return;const _0x3d7043=_0x3f94e4===_0x44915f(0x89)?_0x44915f(0xa4):_0x44915f(0x8a);throw CliErrors[_0x44915f(0xa6)](_0x3d7043+_0x44915f(0x8c)+_0x233c2b+'.',[_0x44915f(0xae),_0x44915f(0xa3),_0x44915f(0x9d),_0x44915f(0x84)+_0x213638['join'](';\x20')][_0x44915f(0x95)]('\x20'));}export function buildRetargetWarning(_0x45d95b,_0x1fb2ec){const _0x4fa5d5=a80_0x3c82;if(!_0x45d95b?.[_0x4fa5d5(0xb0)]||_0x45d95b[_0x4fa5d5(0xb0)]===_0x1fb2ec)return[];return[{'level':_0x4fa5d5(0x8f),'ruleId':_0x4fa5d5(0x8e),'file':_0x4fa5d5(0x86),'message':_0x4fa5d5(0x7f)+_0x45d95b[_0x4fa5d5(0xb0)]+_0x4fa5d5(0xaf)+_0x1fb2ec+_0x4fa5d5(0xab),'suggestion':_0x4fa5d5(0x90)}];}export async function runRemoteContentPreflight(_0xf1ed9b){const _0x10e999=a80_0x3c82;if(!_0xf1ed9b['remote']||_0xf1ed9b['remote'][_0x10e999(0xa8)]!==_0xf1ed9b[_0x10e999(0xa8)]||!_0xf1ed9b[_0x10e999(0xaa)][_0x10e999(0x80)])return{'status':'not-applicable'};const _0x101d8e=_0xf1ed9b['remote'][_0x10e999(0x82)]||_0xf1ed9b[_0x10e999(0x82)];if(!_0x101d8e)return{'status':_0x10e999(0xa9)};const _0x52fe5c=await _0xf1ed9b[_0x10e999(0x85)](_0xf1ed9b[_0x10e999(0xa8)],_0x101d8e,_0xf1ed9b[_0x10e999(0xb0)],_0xf1ed9b['remote'][_0x10e999(0x92)]);try{_0xf1ed9b[_0x10e999(0x91)](_0xf1ed9b[_0x10e999(0xaa)][_0x10e999(0x80)],_0x52fe5c);}catch{return{'status':'different'};}return{'status':_0x10e999(0xac),'savedSkill':{..._0xf1ed9b[_0x10e999(0x81)],'content':_0xf1ed9b[_0x10e999(0xaa)][_0x10e999(0xa1)],'files':_0xf1ed9b[_0x10e999(0xaa)][_0x10e999(0x80)]}};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a81_0x3fb3(){const _0x128cd2=['97013yokUgh','sourceSessionId','preferInputSkillName','298009MjanpZ','\x20after\x20successful\x20push.','skillName','skill-metadata-appcode-retargeted','54605iDnbZk','\x20was\x20retargeted\x20to\x20explicit\x20appCode\x20','lovrabet.skill.json','1046073smrHkP','2GfefsR','tags','303128qSFVxZ','appCode','version','Local\x20Skill\x20metadata\x20appCode\x20','warning','isArray','description','280576WzhSNZ','54dWmdZn','43857RgufKi','Review\x20the\x20updated\x20local\x20Skill\x20metadata\x20before\x20the\x20next\x20push.'];a81_0x3fb3=function(){return _0x128cd2;};return a81_0x3fb3();}function a81_0x2bc8(_0x319955,_0x207919){_0x319955=_0x319955-0x9a;const _0x3fb3a3=a81_0x3fb3();let _0x2bc812=_0x3fb3a3[_0x319955];return _0x2bc812;}(function(_0x349f45,_0x142cc7){const _0x47de38=a81_0x2bc8,_0x3f6df3=_0x349f45();while(!![]){try{const _0x55dd08=-parseInt(_0x47de38(0xaa))/0x1+parseInt(_0x47de38(0x9a))/0x2*(parseInt(_0x47de38(0xb1))/0x3)+parseInt(_0x47de38(0x9c))/0x4+-parseInt(_0x47de38(0xae))/0x5*(-parseInt(_0x47de38(0xa4))/0x6)+parseInt(_0x47de38(0xa7))/0x7+-parseInt(_0x47de38(0xa3))/0x8+-parseInt(_0x47de38(0xa5))/0x9;if(_0x55dd08===_0x142cc7)break;else _0x3f6df3['push'](_0x3f6df3['shift']());}catch(_0x35f0aa){_0x3f6df3['push'](_0x3f6df3['shift']());}}}(a81_0x3fb3,0x3080b));export function withRetargetExistingMetadata(_0x4f61b1,_0x50ead4,_0x355e41={}){const _0x1c7cf0=a81_0x2bc8,_0x3d5686=_0x355e41[_0x1c7cf0(0xa9)]?_0x4f61b1[_0x1c7cf0(0xac)]??_0x50ead4[_0x1c7cf0(0xac)]:_0x50ead4[_0x1c7cf0(0xac)]??_0x4f61b1[_0x1c7cf0(0xac)];return{..._0x4f61b1,'skillName':_0x3d5686,'description':_0x50ead4[_0x1c7cf0(0xa2)]??_0x4f61b1['description'],'tags':Array[_0x1c7cf0(0xa1)](_0x50ead4[_0x1c7cf0(0x9b)])?_0x50ead4['tags']:_0x4f61b1['tags'],'version':_0x50ead4[_0x1c7cf0(0x9e)]??_0x4f61b1[_0x1c7cf0(0x9e)],'sourceSessionId':_0x50ead4[_0x1c7cf0(0xa8)]??_0x4f61b1[_0x1c7cf0(0xa8)]};}export function buildRetargetWarning(_0xa53ef4,_0x45598d){const _0x57a1b3=a81_0x2bc8;if(!_0xa53ef4?.[_0x57a1b3(0x9d)]||_0xa53ef4[_0x57a1b3(0x9d)]===_0x45598d)return[];return[{'level':_0x57a1b3(0xa0),'ruleId':_0x57a1b3(0xad),'file':_0x57a1b3(0xb0),'message':_0x57a1b3(0x9f)+_0xa53ef4[_0x57a1b3(0x9d)]+_0x57a1b3(0xaf)+_0x45598d+_0x57a1b3(0xab),'suggestion':_0x57a1b3(0xa6)}];}
|