@lovrabet/lovrabet-cli 2.2.5-beta.2 → 2.2.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/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/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/shared.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/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/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/risk.js +1 -1
- package/lib/constant/url.js +1 -1
- package/lib/context.js +1 -1
- package/lib/core/api-client.d.ts +3 -3
- package/lib/core/api-client.js +1 -1
- package/lib/core/db-resolver.js +1 -1
- package/lib/core/sdk-client.js +1 -1
- package/lib/errors.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/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/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/apply-jq-filter.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/platform.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 +4 -4
- package/skills/lovrabet/references/lovrabet-schedule-workflow.md +7 -6
- package/skills/lovrabet.manifest.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
const a135_0x12ff76=a135_0x4bfa;(function(_0x5917bc,_0x343b92){const _0x5398a9=a135_0x4bfa,_0x444364=_0x5917bc();while(!![]){try{const _0x5bbafc=-parseInt(_0x5398a9(0x1b6))/0x1*(parseInt(_0x5398a9(0x1c4))/0x2)+-parseInt(_0x5398a9(0x1a8))/0x3*(parseInt(_0x5398a9(0x1ce))/0x4)+-parseInt(_0x5398a9(0x1b4))/0x5+-parseInt(_0x5398a9(0x1aa))/0x6*(parseInt(_0x5398a9(0x1af))/0x7)+parseInt(_0x5398a9(0x1cc))/0x8+parseInt(_0x5398a9(0x1ac))/0x9+parseInt(_0x5398a9(0x1bf))/0xa*(parseInt(_0x5398a9(0x1b7))/0xb);if(_0x5bbafc===_0x343b92)break;else _0x444364['push'](_0x444364['shift']());}catch(_0x366413){_0x444364['push'](_0x444364['shift']());}}}(a135_0x26fc,0x8853c));import{existsSync,lstatSync,mkdirSync,readdirSync,symlinkSync,unlinkSync}from'node:fs';import{basename,dirname,resolve}from'node:path';import a135_0x29292e from'fs-extra';import{CliErrors}from'../../errors.js';import{METADATA_FILE}from'./constants.js';import{isDanglingSymlink,isPathInside,lstatIfPresent,realOrResolved,resolveSymlinkTarget}from'./fs-utils.js';function a135_0x26fc(){const _0x578b23=['3946176sEApHz','lovrabet','736deWlcs','builtin','has','scopes','updated','Refusing\x20to\x20overwrite\x20managed\x20Skill\x20link\x20owned\x20by\x20another\x20app\x20or\x20code:\x20','secret-retriever','trim','skillRoots','created','scope','metadataPath','linked-from-protected-root','skill','appCode','pruneSkillCodes','not-managed-symlink','name','Refusing\x20to\x20overwrite\x20unmanaged\x20symlink:\x20','isSymbolicLink','skipped','map','14502XFdwLW','validation','1038144xxdYEM','accessKey','2968056ctokio','contentHash','metadata-mismatch','14tCqsij','unchanged','protectedLinkRoots','activeSkillCodes','length','4977395NaGDYq','personal','70997Kjuyth','27096322pfmlTF','dir','isDirectory','slice','filter','Only\x20builtin\x20Skills\x20can\x20be\x20linked\x20into\x20the\x20global\x20Skill\x20root:\x20','Refusing\x20to\x20overwrite\x20unmanaged\x20path:\x20','get','10zlVeJa','Refusing\x20to\x20overwrite\x20unmanaged\x20global\x20Skill\x20directory:\x20','project','startsWith','company','14QLzHWS','agentsSkillsDir','push','skillCode','Refusing\x20to\x20copy\x20Skill\x20symlink:\x20','removed','Refusing\x20to\x20overwrite\x20global\x20Skill\x20path:\x20','Refusing\x20to\x20shadow\x20reserved\x20Agent\x20Skill\x20in\x20project\x20scope:\x20'];a135_0x26fc=function(){return _0x578b23;};return a135_0x26fc();}import{readMetadataIfPresent,requireSkillCode}from'./metadata.js';import{getRuntimeSkillCacheRoot,resolveSkillSyncPaths,safePathSegment}from'./paths.js';const {copySync,ensureDirSync,removeSync}=a135_0x29292e,RESERVED_PROJECT_SKILL_CODES=new Set([a135_0x12ff76(0x1cd),'runtime-observe',a135_0x12ff76(0x1d4)]);export function linkEffectiveRuntimeSkills(_0x291562,_0xafa199){const _0x221c8a=a135_0x12ff76,_0x21b72a=new Map();for(const _0x2d047a of _0x291562){const _0x138a26=_0x2d047a[_0x221c8a(0x19f)]['skillCode'];if(!_0x138a26)continue;const _0x423d42=_0x21b72a[_0x221c8a(0x1be)](_0x138a26);(!_0x423d42||_0x2d047a[_0x221c8a(0x1d8)]===_0x221c8a(0x1b5))&&_0x21b72a['set'](_0x138a26,_0x2d047a);}const _0x29dcc4=[];for(const _0x483006 of _0x21b72a['values']()){const _0x1e9f68=requireSkillCode(_0x483006[_0x221c8a(0x19f)]),_0x451fe9=readMetadataIfPresent(_0x483006[_0x221c8a(0x19d)]);if(_0x451fe9?.[_0x221c8a(0x1a0)]!==_0xafa199[_0x221c8a(0x1a0)]||_0x451fe9[_0x221c8a(0x1c7)]!==_0x1e9f68)throw CliErrors[_0x221c8a(0x1a9)]('Refusing\x20to\x20link\x20Skill\x20metadata\x20outside\x20target\x20'+_0xafa199[_0x221c8a(0x1a0)]+':\x20'+_0x483006[_0x221c8a(0x19d)]);const _0x58637f=runtimeSkillLinkName(_0xafa199,_0x1e9f68);for(const _0x225b57 of _0xafa199['skillRoots']){_0x29dcc4[_0x221c8a(0x1c6)](ensureManagedSymlink(resolve(_0x225b57,_0x58637f),_0x483006[_0x221c8a(0x1b8)],_0xafa199,_0x1e9f68));}}return _0x29dcc4;}export function pruneStaleRuntimeSkillLinks(_0x385cdf,_0xa6df57,_0x9ba978){const _0x19d96c=a135_0x12ff76,_0x105d46=new Set([..._0xa6df57][_0x19d96c(0x1a7)](_0x41fe86=>_0x41fe86[_0x19d96c(0x1d5)]())[_0x19d96c(0x1bb)](Boolean)),_0x503a77=_0x9ba978?new Set([..._0x9ba978][_0x19d96c(0x1a7)](_0x150890=>_0x150890[_0x19d96c(0x1d5)]())[_0x19d96c(0x1bb)](Boolean)):undefined,_0x12097d=[];for(const _0x2a5b59 of _0x385cdf[_0x19d96c(0x1d6)]){for(const _0x4efe5a of managedTargetSkillLinkPaths(_0x2a5b59,_0x385cdf)){const _0xcf0db8=runtimeSkillCodeFromLink(_0x385cdf,_0x4efe5a);if(_0x503a77&&!_0x503a77['has'](_0xcf0db8))continue;if(_0x105d46['has'](_0xcf0db8))continue;_0x12097d['push'](removeManagedSkillLink(_0x4efe5a,_0x385cdf,_0xcf0db8));}}return _0x12097d;}export function pruneStaleRuntimeSkillCache(_0x4acb81,_0x2dd32c={}){const _0x2701e7=a135_0x12ff76,_0x531235=new Set([..._0x4acb81[_0x2701e7(0x1b2)]][_0x2701e7(0x1a7)](_0x5f484d=>_0x5f484d[_0x2701e7(0x1d5)]())['filter'](Boolean)),_0x202119=_0x4acb81['pruneSkillCodes']?new Set([..._0x4acb81[_0x2701e7(0x1a1)]][_0x2701e7(0x1a7)](_0x50e33e=>_0x50e33e[_0x2701e7(0x1d5)]())['filter'](Boolean)):undefined,_0x53c24b=_0x4acb81[_0x2701e7(0x1d1)]??[_0x2701e7(0x1b5),_0x2701e7(0x1c3)],_0x1e7518=resolve(getRuntimeSkillCacheRoot(_0x4acb81['env'],_0x4acb81[_0x2701e7(0x1ab)],_0x2dd32c),safePathSegment(_0x4acb81[_0x2701e7(0x1a0)],_0x2701e7(0x1a0))),_0x4cdfa9=[];for(const _0x114bf1 of _0x53c24b){const _0x3f887e=resolve(_0x1e7518,_0x114bf1);if(!existsSync(_0x3f887e))continue;for(const _0x5e6aeb of readdirSync(_0x3f887e,{'withFileTypes':!![]})){if(!_0x5e6aeb[_0x2701e7(0x1b9)]())continue;const _0x5f1c1b=_0x5e6aeb[_0x2701e7(0x1a3)];if(_0x202119&&!_0x202119['has'](_0x5f1c1b))continue;if(_0x531235[_0x2701e7(0x1d0)](_0x5f1c1b))continue;const _0x9b253d=resolve(_0x3f887e,_0x5f1c1b),_0x43e586=readMetadataIfPresent(resolve(_0x9b253d,METADATA_FILE));if(_0x43e586?.[_0x2701e7(0x1a0)]!==_0x4acb81['appCode']||_0x43e586[_0x2701e7(0x1d8)]!==_0x114bf1||_0x43e586[_0x2701e7(0x1c7)]!==_0x5f1c1b){_0x4cdfa9[_0x2701e7(0x1c6)]({'path':_0x9b253d,'action':_0x2701e7(0x1a6),'reason':_0x2701e7(0x1ae)});continue;}if(isLinkedFromAnyRoot(_0x9b253d,_0x4acb81[_0x2701e7(0x1b1)]??[])){_0x4cdfa9['push']({'path':_0x9b253d,'action':_0x2701e7(0x1a6),'reason':_0x2701e7(0x19e)});continue;}removeSync(_0x9b253d),_0x4cdfa9['push']({'path':_0x9b253d,'action':_0x2701e7(0x1c9)});}}return _0x4cdfa9;}export function linkGlobalRuntimeSkills(_0x1ee5d8,_0x55783a={}){const _0x562eed=a135_0x12ff76,_0x4f6281=resolveSkillSyncPaths(_0x55783a),_0x1bf3b9=[];for(const _0xb31918 of _0x1ee5d8){if(_0xb31918['scope']!==_0x562eed(0x1cf))throw CliErrors['validation'](_0x562eed(0x1bc)+_0xb31918[_0x562eed(0x1d8)]);const _0x302d67=requireSkillCode(_0xb31918[_0x562eed(0x19f)]),_0x2ad019=copyManagedSkillDirectory(_0xb31918[_0x562eed(0x1b8)],resolve(_0x4f6281[_0x562eed(0x1c5)],_0x302d67));_0x1bf3b9[_0x562eed(0x1c6)]({..._0x2ad019,'contentHash':_0xb31918[_0x562eed(0x1ad)]});}return _0x1bf3b9;}function ensureManagedSymlink(_0x2d4d95,_0x3894c1,_0x26db12,_0x1cb78d){const _0x4f9f77=a135_0x12ff76;mkdirSync(dirname(_0x2d4d95),{'recursive':!![],'mode':0x1c0});if(existsSync(_0x2d4d95)||isDanglingSymlink(_0x2d4d95)){const _0x142067=lstatSync(_0x2d4d95);if(!_0x142067['isSymbolicLink']())throw CliErrors[_0x4f9f77(0x1a9)](_0x4f9f77(0x1bd)+_0x2d4d95);const _0x599c0b=resolveSymlinkTarget(_0x2d4d95);if(!isPathInside(realOrResolved(_0x599c0b),realOrResolved(_0x26db12['managedRoot'])))throw CliErrors[_0x4f9f77(0x1a9)](_0x4f9f77(0x1a4)+_0x2d4d95);if(realOrResolved(_0x599c0b)===realOrResolved(_0x3894c1))return{'path':_0x2d4d95,'target':_0x3894c1,'action':_0x4f9f77(0x1b0)};const _0x163bd8=readMetadataIfPresent(resolve(_0x599c0b,METADATA_FILE));if(_0x26db12[_0x4f9f77(0x1d8)]==='project'&&(_0x163bd8?.['appCode']!==_0x26db12['appCode']||_0x163bd8['skillCode']!==_0x1cb78d))throw CliErrors[_0x4f9f77(0x1a9)](_0x4f9f77(0x1d3)+_0x2d4d95);return unlinkSync(_0x2d4d95),symlinkSync(_0x3894c1,_0x2d4d95,_0x4f9f77(0x1b8)),{'path':_0x2d4d95,'target':_0x3894c1,'action':_0x4f9f77(0x1d2)};}return symlinkSync(_0x3894c1,_0x2d4d95,_0x4f9f77(0x1b8)),{'path':_0x2d4d95,'target':_0x3894c1,'action':_0x4f9f77(0x1d7)};}function managedTargetSkillLinkPaths(_0x2c6657,_0x23bbec){const _0x55f02b=a135_0x12ff76;if(!existsSync(_0x2c6657))return[];const _0x9cbc32=_0x23bbec['appCode']+'--';return readdirSync(_0x2c6657,{'withFileTypes':!![]})[_0x55f02b(0x1bb)](_0x3876e3=>_0x23bbec[_0x55f02b(0x1d8)]==='project'||_0x3876e3[_0x55f02b(0x1a3)][_0x55f02b(0x1c2)](_0x9cbc32))[_0x55f02b(0x1a7)](_0x26a843=>resolve(_0x2c6657,_0x26a843['name']));}function removeManagedSkillLink(_0x33a39c,_0x49c79b,_0x377b04){const _0x32f1d8=a135_0x12ff76,_0x17df6b=lstatIfPresent(_0x33a39c);if(!_0x17df6b?.[_0x32f1d8(0x1a5)]())return{'path':_0x33a39c,'action':_0x32f1d8(0x1a6),'reason':_0x32f1d8(0x1a2)};const _0x17fa7e=resolveSymlinkTarget(_0x33a39c);if(!isPathInside(realOrResolved(_0x17fa7e),realOrResolved(_0x49c79b['managedRoot'])))return{'path':_0x33a39c,'action':_0x32f1d8(0x1a6),'reason':'external-symlink'};const _0x132b00=readMetadataIfPresent(resolve(_0x17fa7e,METADATA_FILE));if(_0x49c79b[_0x32f1d8(0x1d8)]===_0x32f1d8(0x1c1)&&(_0x132b00?.['appCode']!==_0x49c79b[_0x32f1d8(0x1a0)]||_0x132b00[_0x32f1d8(0x1c7)]!==_0x377b04))return{'path':_0x33a39c,'action':_0x32f1d8(0x1a6),'reason':_0x32f1d8(0x1ae)};return unlinkSync(_0x33a39c),{'path':_0x33a39c,'action':_0x32f1d8(0x1c9)};}function isLinkedFromAnyRoot(_0x2a40eb,_0x35a8bd){const _0x26b615=a135_0x12ff76,_0x141fc9=realOrResolved(_0x2a40eb);for(const _0xc61906 of _0x35a8bd){if(!existsSync(_0xc61906))continue;for(const _0x12305c of readdirSync(_0xc61906,{'withFileTypes':!![]})){if(!_0x12305c[_0x26b615(0x1a5)]())continue;const _0x300845=resolve(_0xc61906,_0x12305c[_0x26b615(0x1a3)]);if(realOrResolved(resolveSymlinkTarget(_0x300845))===_0x141fc9)return!![];}}return![];}function runtimeSkillLinkName(_0xc4d49f,_0x43ad6f){const _0x4615f3=a135_0x12ff76,_0x2ed9ec=safePathSegment(_0x43ad6f,_0x4615f3(0x1c7));if(_0xc4d49f['scope']==='project'&&RESERVED_PROJECT_SKILL_CODES[_0x4615f3(0x1d0)](_0x2ed9ec))throw CliErrors[_0x4615f3(0x1a9)](_0x4615f3(0x1cb)+_0x2ed9ec);return _0xc4d49f['scope']==='project'?_0x2ed9ec:_0xc4d49f[_0x4615f3(0x1a0)]+'--'+_0x2ed9ec;}function a135_0x4bfa(_0x4cf6e4,_0x1f5946){_0x4cf6e4=_0x4cf6e4-0x19d;const _0x26fc71=a135_0x26fc();let _0x4bfa47=_0x26fc71[_0x4cf6e4];return _0x4bfa47;}function runtimeSkillCodeFromLink(_0x4b19f7,_0xc5ac7e){const _0x1c9f81=a135_0x12ff76,_0x14a197=basename(_0xc5ac7e);return _0x4b19f7[_0x1c9f81(0x1d8)]===_0x1c9f81(0x1c1)?_0x14a197:_0x14a197[_0x1c9f81(0x1ba)]((_0x4b19f7[_0x1c9f81(0x1a0)]+'--')[_0x1c9f81(0x1b3)]);}export function copyManagedSkillDirectory(_0x510936,_0x56eb51){const _0x159d04=a135_0x12ff76,_0x107ddf=resolve(_0x56eb51,METADATA_FILE),_0x3b4047=existsSync(_0x56eb51);if(_0x3b4047){const _0x1fcad6=lstatSync(_0x56eb51);if(_0x1fcad6[_0x159d04(0x1a5)]())throw CliErrors['validation']('Refusing\x20to\x20overwrite\x20global\x20Skill\x20symlink:\x20'+_0x56eb51);if(!_0x1fcad6[_0x159d04(0x1b9)]())throw CliErrors[_0x159d04(0x1a9)](_0x159d04(0x1ca)+_0x56eb51);const _0x503351=readMetadataIfPresent(_0x107ddf);if(_0x503351?.[_0x159d04(0x1d8)]!==_0x159d04(0x1cf))throw CliErrors[_0x159d04(0x1a9)](_0x159d04(0x1c0)+_0x56eb51);}ensureDirSync(dirname(_0x56eb51));const _0x3dfc56=_0x3b4047?readMetadataIfPresent(_0x107ddf)?.[_0x159d04(0x1ad)]:undefined,_0x2d1b0a=readMetadataIfPresent(resolve(_0x510936,METADATA_FILE))?.['contentHash'];return _0x3b4047&&removeSync(_0x56eb51),copySkillDirectory(_0x510936,_0x56eb51),{'path':_0x56eb51,'target':_0x510936,'action':!_0x3b4047?_0x159d04(0x1d7):_0x3dfc56===_0x2d1b0a?'unchanged':_0x159d04(0x1d2)};}function copySkillDirectory(_0x4d62f0,_0x5478bb){copySync(_0x4d62f0,_0x5478bb,{'dereference':![],'overwrite':!![],'filter'(_0x3464b2){const _0x68b795=a135_0x4bfa;if(lstatSync(_0x3464b2)[_0x68b795(0x1a5)]())throw CliErrors[_0x68b795(0x1a9)](_0x68b795(0x1c8)+_0x3464b2);return!![];}});}
|
|
1
|
+
const a135_0xb05b96=a135_0x165d;(function(_0x2e03d6,_0x2ad5ec){const _0x28dc11=a135_0x165d,_0x44ff10=_0x2e03d6();while(!![]){try{const _0x1b4dd3=parseInt(_0x28dc11(0xbe))/0x1+-parseInt(_0x28dc11(0xc5))/0x2*(parseInt(_0x28dc11(0x8f))/0x3)+-parseInt(_0x28dc11(0x9f))/0x4*(parseInt(_0x28dc11(0xbb))/0x5)+parseInt(_0x28dc11(0xbc))/0x6+parseInt(_0x28dc11(0xad))/0x7*(-parseInt(_0x28dc11(0x90))/0x8)+-parseInt(_0x28dc11(0x9b))/0x9*(parseInt(_0x28dc11(0xa4))/0xa)+-parseInt(_0x28dc11(0xb6))/0xb*(-parseInt(_0x28dc11(0x94))/0xc);if(_0x1b4dd3===_0x2ad5ec)break;else _0x44ff10['push'](_0x44ff10['shift']());}catch(_0x1f4650){_0x44ff10['push'](_0x44ff10['shift']());}}}(a135_0x3e26,0x8bcef));import{existsSync,lstatSync,mkdirSync,readdirSync,symlinkSync,unlinkSync}from'node:fs';import{basename,dirname,resolve}from'node:path';import a135_0x2eeded from'fs-extra';import{CliErrors}from'../../errors.js';import{METADATA_FILE}from'./constants.js';import{isDanglingSymlink,isPathInside,lstatIfPresent,realOrResolved,resolveSymlinkTarget}from'./fs-utils.js';import{readMetadataIfPresent,requireSkillCode}from'./metadata.js';function a135_0x3e26(){const _0x18dc76=['appCode','9mvlFJT','slice','Refusing\x20to\x20copy\x20Skill\x20symlink:\x20','Refusing\x20to\x20overwrite\x20global\x20Skill\x20path:\x20','4JcRsxa','scope','company','pruneSkillCodes','removed','2723010qxrgea','unchanged','agentsSkillsDir','contentHash','skill','length','filter','map','personal','1417794dkUXTm','managedRoot','set','startsWith','linked-from-protected-root','validation','get','Refusing\x20to\x20overwrite\x20global\x20Skill\x20symlink:\x20','isDirectory','5742erZdLd','updated','env','values','name','2600930XScfDj','174504rKODfy','created','27768yOTlhj','has','external-symlink','push','metadata-mismatch','dir','lovrabet','14GyyJuq','isSymbolicLink','Only\x20builtin\x20Skills\x20can\x20be\x20linked\x20into\x20the\x20global\x20Skill\x20root:\x20','Refusing\x20to\x20shadow\x20reserved\x20Agent\x20Skill\x20in\x20project\x20scope:\x20','Refusing\x20to\x20link\x20Skill\x20metadata\x20outside\x20target\x20','metadataPath','protectedLinkRoots','runtime-observe','skillCode','Refusing\x20to\x20overwrite\x20unmanaged\x20global\x20Skill\x20directory:\x20','278004uxJlhi','16JJZhlO','skipped','project','scopes','54300BHxAaY','accessKey','builtin','Refusing\x20to\x20overwrite\x20unmanaged\x20path:\x20','activeSkillCodes','trim'];a135_0x3e26=function(){return _0x18dc76;};return a135_0x3e26();}import{getRuntimeSkillCacheRoot,resolveSkillSyncPaths,safePathSegment}from'./paths.js';const {copySync,ensureDirSync,removeSync}=a135_0x2eeded,RESERVED_PROJECT_SKILL_CODES=new Set([a135_0xb05b96(0xc4),a135_0xb05b96(0x8c),'secret-retriever']);export function linkEffectiveRuntimeSkills(_0x14cfa7,_0x24c451){const _0x25fb03=a135_0xb05b96,_0xed5468=new Map();for(const _0xebd9ea of _0x14cfa7){const _0x43a4ba=_0xebd9ea[_0x25fb03(0xa8)][_0x25fb03(0x8d)];if(!_0x43a4ba)continue;const _0x1ad549=_0xed5468[_0x25fb03(0xb3)](_0x43a4ba);(!_0x1ad549||_0xebd9ea[_0x25fb03(0xa0)]===_0x25fb03(0xac))&&_0xed5468[_0x25fb03(0xaf)](_0x43a4ba,_0xebd9ea);}const _0x4d1f7d=[];for(const _0x20cb03 of _0xed5468[_0x25fb03(0xb9)]()){const _0x7c4b3f=requireSkillCode(_0x20cb03['skill']),_0x41d781=readMetadataIfPresent(_0x20cb03[_0x25fb03(0x8a)]);if(_0x41d781?.[_0x25fb03(0x9a)]!==_0x24c451['appCode']||_0x41d781[_0x25fb03(0x8d)]!==_0x7c4b3f)throw CliErrors[_0x25fb03(0xb2)](_0x25fb03(0x89)+_0x24c451[_0x25fb03(0x9a)]+':\x20'+_0x20cb03[_0x25fb03(0x8a)]);const _0x2c06a7=runtimeSkillLinkName(_0x24c451,_0x7c4b3f);for(const _0x17e95f of _0x24c451['skillRoots']){_0x4d1f7d[_0x25fb03(0xc1)](ensureManagedSymlink(resolve(_0x17e95f,_0x2c06a7),_0x20cb03['dir'],_0x24c451,_0x7c4b3f));}}return _0x4d1f7d;}export function pruneStaleRuntimeSkillLinks(_0x43f9fa,_0x18a683,_0x3ae2a6){const _0x2c6ee5=a135_0xb05b96,_0x2fa7d0=new Set([..._0x18a683]['map'](_0xe29fc7=>_0xe29fc7[_0x2c6ee5(0x99)]())[_0x2c6ee5(0xaa)](Boolean)),_0x21524f=_0x3ae2a6?new Set([..._0x3ae2a6][_0x2c6ee5(0xab)](_0x37904b=>_0x37904b[_0x2c6ee5(0x99)]())[_0x2c6ee5(0xaa)](Boolean)):undefined,_0x468e0b=[];for(const _0x264580 of _0x43f9fa['skillRoots']){for(const _0x29ddde of managedTargetSkillLinkPaths(_0x264580,_0x43f9fa)){const _0x2c70a8=runtimeSkillCodeFromLink(_0x43f9fa,_0x29ddde);if(_0x21524f&&!_0x21524f[_0x2c6ee5(0xbf)](_0x2c70a8))continue;if(_0x2fa7d0[_0x2c6ee5(0xbf)](_0x2c70a8))continue;_0x468e0b[_0x2c6ee5(0xc1)](removeManagedSkillLink(_0x29ddde,_0x43f9fa,_0x2c70a8));}}return _0x468e0b;}export function pruneStaleRuntimeSkillCache(_0x579935,_0x5c3419={}){const _0x5e7668=a135_0xb05b96,_0x1c9419=new Set([..._0x579935[_0x5e7668(0x98)]]['map'](_0x5aa4cd=>_0x5aa4cd[_0x5e7668(0x99)]())['filter'](Boolean)),_0x5350f0=_0x579935['pruneSkillCodes']?new Set([..._0x579935[_0x5e7668(0xa2)]][_0x5e7668(0xab)](_0x265dd7=>_0x265dd7[_0x5e7668(0x99)]())[_0x5e7668(0xaa)](Boolean)):undefined,_0x3904ca=_0x579935[_0x5e7668(0x93)]??[_0x5e7668(0xac),_0x5e7668(0xa1)],_0x1320e0=resolve(getRuntimeSkillCacheRoot(_0x579935[_0x5e7668(0xb8)],_0x579935[_0x5e7668(0x95)],_0x5c3419),safePathSegment(_0x579935[_0x5e7668(0x9a)],_0x5e7668(0x9a))),_0x33be22=[];for(const _0x44d373 of _0x3904ca){const _0x15bdef=resolve(_0x1320e0,_0x44d373);if(!existsSync(_0x15bdef))continue;for(const _0x1c4958 of readdirSync(_0x15bdef,{'withFileTypes':!![]})){if(!_0x1c4958[_0x5e7668(0xb5)]())continue;const _0x2d1b8c=_0x1c4958[_0x5e7668(0xba)];if(_0x5350f0&&!_0x5350f0[_0x5e7668(0xbf)](_0x2d1b8c))continue;if(_0x1c9419[_0x5e7668(0xbf)](_0x2d1b8c))continue;const _0x315316=resolve(_0x15bdef,_0x2d1b8c),_0x1ed912=readMetadataIfPresent(resolve(_0x315316,METADATA_FILE));if(_0x1ed912?.['appCode']!==_0x579935['appCode']||_0x1ed912[_0x5e7668(0xa0)]!==_0x44d373||_0x1ed912['skillCode']!==_0x2d1b8c){_0x33be22[_0x5e7668(0xc1)]({'path':_0x315316,'action':_0x5e7668(0x91),'reason':_0x5e7668(0xc2)});continue;}if(isLinkedFromAnyRoot(_0x315316,_0x579935[_0x5e7668(0x8b)]??[])){_0x33be22[_0x5e7668(0xc1)]({'path':_0x315316,'action':_0x5e7668(0x91),'reason':_0x5e7668(0xb1)});continue;}removeSync(_0x315316),_0x33be22[_0x5e7668(0xc1)]({'path':_0x315316,'action':'removed'});}}return _0x33be22;}export function linkGlobalRuntimeSkills(_0x3fdff7,_0x894f2c={}){const _0x51dc8a=a135_0xb05b96,_0x22059b=resolveSkillSyncPaths(_0x894f2c),_0x2160c8=[];for(const _0x3c731f of _0x3fdff7){if(_0x3c731f[_0x51dc8a(0xa0)]!==_0x51dc8a(0x96))throw CliErrors[_0x51dc8a(0xb2)](_0x51dc8a(0x87)+_0x3c731f[_0x51dc8a(0xa0)]);const _0x11382e=requireSkillCode(_0x3c731f[_0x51dc8a(0xa8)]),_0x76989d=copyManagedSkillDirectory(_0x3c731f['dir'],resolve(_0x22059b[_0x51dc8a(0xa6)],_0x11382e));_0x2160c8[_0x51dc8a(0xc1)]({..._0x76989d,'contentHash':_0x3c731f[_0x51dc8a(0xa7)]});}return _0x2160c8;}function a135_0x165d(_0x530487,_0x4a4aa5){_0x530487=_0x530487-0x87;const _0x3e26c3=a135_0x3e26();let _0x165db6=_0x3e26c3[_0x530487];return _0x165db6;}function ensureManagedSymlink(_0xde98ac,_0x571024,_0xcb1ecd,_0x541f6f){const _0x376418=a135_0xb05b96;mkdirSync(dirname(_0xde98ac),{'recursive':!![],'mode':0x1c0});if(existsSync(_0xde98ac)||isDanglingSymlink(_0xde98ac)){const _0x5a2e18=lstatSync(_0xde98ac);if(!_0x5a2e18[_0x376418(0xc6)]())throw CliErrors['validation'](_0x376418(0x97)+_0xde98ac);const _0xb987b7=resolveSymlinkTarget(_0xde98ac);if(!isPathInside(realOrResolved(_0xb987b7),realOrResolved(_0xcb1ecd['managedRoot'])))throw CliErrors[_0x376418(0xb2)]('Refusing\x20to\x20overwrite\x20unmanaged\x20symlink:\x20'+_0xde98ac);if(realOrResolved(_0xb987b7)===realOrResolved(_0x571024))return{'path':_0xde98ac,'target':_0x571024,'action':_0x376418(0xa5)};const _0x4b8819=readMetadataIfPresent(resolve(_0xb987b7,METADATA_FILE));if(_0xcb1ecd[_0x376418(0xa0)]===_0x376418(0x92)&&(_0x4b8819?.[_0x376418(0x9a)]!==_0xcb1ecd[_0x376418(0x9a)]||_0x4b8819['skillCode']!==_0x541f6f))throw CliErrors['validation']('Refusing\x20to\x20overwrite\x20managed\x20Skill\x20link\x20owned\x20by\x20another\x20app\x20or\x20code:\x20'+_0xde98ac);return unlinkSync(_0xde98ac),symlinkSync(_0x571024,_0xde98ac,_0x376418(0xc3)),{'path':_0xde98ac,'target':_0x571024,'action':_0x376418(0xb7)};}return symlinkSync(_0x571024,_0xde98ac,'dir'),{'path':_0xde98ac,'target':_0x571024,'action':_0x376418(0xbd)};}function managedTargetSkillLinkPaths(_0x13e110,_0x3f2df2){const _0xa437b7=a135_0xb05b96;if(!existsSync(_0x13e110))return[];const _0x10bc66=_0x3f2df2[_0xa437b7(0x9a)]+'--';return readdirSync(_0x13e110,{'withFileTypes':!![]})[_0xa437b7(0xaa)](_0x62339=>_0x3f2df2[_0xa437b7(0xa0)]===_0xa437b7(0x92)||_0x62339[_0xa437b7(0xba)][_0xa437b7(0xb0)](_0x10bc66))[_0xa437b7(0xab)](_0x3c6986=>resolve(_0x13e110,_0x3c6986[_0xa437b7(0xba)]));}function removeManagedSkillLink(_0x14eb6b,_0x5b9408,_0x160440){const _0x9856e=a135_0xb05b96,_0xd6f5b6=lstatIfPresent(_0x14eb6b);if(!_0xd6f5b6?.[_0x9856e(0xc6)]())return{'path':_0x14eb6b,'action':_0x9856e(0x91),'reason':'not-managed-symlink'};const _0x63b37e=resolveSymlinkTarget(_0x14eb6b);if(!isPathInside(realOrResolved(_0x63b37e),realOrResolved(_0x5b9408[_0x9856e(0xae)])))return{'path':_0x14eb6b,'action':_0x9856e(0x91),'reason':_0x9856e(0xc0)};const _0x5bfde2=readMetadataIfPresent(resolve(_0x63b37e,METADATA_FILE));if(_0x5b9408[_0x9856e(0xa0)]===_0x9856e(0x92)&&(_0x5bfde2?.[_0x9856e(0x9a)]!==_0x5b9408[_0x9856e(0x9a)]||_0x5bfde2[_0x9856e(0x8d)]!==_0x160440))return{'path':_0x14eb6b,'action':_0x9856e(0x91),'reason':_0x9856e(0xc2)};return unlinkSync(_0x14eb6b),{'path':_0x14eb6b,'action':_0x9856e(0xa3)};}function isLinkedFromAnyRoot(_0x1da732,_0x4816f7){const _0x24757d=a135_0xb05b96,_0x559720=realOrResolved(_0x1da732);for(const _0x30828e of _0x4816f7){if(!existsSync(_0x30828e))continue;for(const _0x1d2d0e of readdirSync(_0x30828e,{'withFileTypes':!![]})){if(!_0x1d2d0e[_0x24757d(0xc6)]())continue;const _0x280b0a=resolve(_0x30828e,_0x1d2d0e[_0x24757d(0xba)]);if(realOrResolved(resolveSymlinkTarget(_0x280b0a))===_0x559720)return!![];}}return![];}function runtimeSkillLinkName(_0x574d14,_0x1b3a5a){const _0x577532=a135_0xb05b96,_0x507ac1=safePathSegment(_0x1b3a5a,_0x577532(0x8d));if(_0x574d14[_0x577532(0xa0)]===_0x577532(0x92)&&RESERVED_PROJECT_SKILL_CODES[_0x577532(0xbf)](_0x507ac1))throw CliErrors[_0x577532(0xb2)](_0x577532(0x88)+_0x507ac1);return _0x574d14[_0x577532(0xa0)]===_0x577532(0x92)?_0x507ac1:_0x574d14[_0x577532(0x9a)]+'--'+_0x507ac1;}function runtimeSkillCodeFromLink(_0x419e06,_0x55fe37){const _0x97865a=a135_0xb05b96,_0x4ea05a=basename(_0x55fe37);return _0x419e06['scope']===_0x97865a(0x92)?_0x4ea05a:_0x4ea05a[_0x97865a(0x9c)]((_0x419e06[_0x97865a(0x9a)]+'--')[_0x97865a(0xa9)]);}export function copyManagedSkillDirectory(_0x59a715,_0xe7fb11){const _0x4a7717=a135_0xb05b96,_0x6d88d7=resolve(_0xe7fb11,METADATA_FILE),_0x3ff01c=existsSync(_0xe7fb11);if(_0x3ff01c){const _0x2e15f8=lstatSync(_0xe7fb11);if(_0x2e15f8[_0x4a7717(0xc6)]())throw CliErrors[_0x4a7717(0xb2)](_0x4a7717(0xb4)+_0xe7fb11);if(!_0x2e15f8['isDirectory']())throw CliErrors[_0x4a7717(0xb2)](_0x4a7717(0x9e)+_0xe7fb11);const _0x93442c=readMetadataIfPresent(_0x6d88d7);if(_0x93442c?.['scope']!==_0x4a7717(0x96))throw CliErrors['validation'](_0x4a7717(0x8e)+_0xe7fb11);}ensureDirSync(dirname(_0xe7fb11));const _0x3616bc=_0x3ff01c?readMetadataIfPresent(_0x6d88d7)?.[_0x4a7717(0xa7)]:undefined,_0x2752ad=readMetadataIfPresent(resolve(_0x59a715,METADATA_FILE))?.[_0x4a7717(0xa7)];return _0x3ff01c&&removeSync(_0xe7fb11),copySkillDirectory(_0x59a715,_0xe7fb11),{'path':_0xe7fb11,'target':_0x59a715,'action':!_0x3ff01c?_0x4a7717(0xbd):_0x3616bc===_0x2752ad?_0x4a7717(0xa5):'updated'};}function copySkillDirectory(_0x3838f7,_0x45c32b){copySync(_0x3838f7,_0x45c32b,{'dereference':![],'overwrite':!![],'filter'(_0x113215){const _0xe30d1e=a135_0x165d;if(lstatSync(_0x113215)[_0xe30d1e(0xc6)]())throw CliErrors[_0xe30d1e(0xb2)](_0xe30d1e(0x9d)+_0x113215);return!![];}});}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x5257cb,_0x21633e){const _0xca5154=a136_0x3f1c,_0x5d5474=_0x5257cb();while(!![]){try{const _0x3a7188=-parseInt(_0xca5154(0x1b3))/0x1*(-parseInt(_0xca5154(0x1b5))/0x2)+parseInt(_0xca5154(0x1ac))/0x3*(parseInt(_0xca5154(0x1b8))/0x4)+-parseInt(_0xca5154(0x1a3))/0x5+-parseInt(_0xca5154(0x1ba))/0x6+parseInt(_0xca5154(0x1a4))/0x7+parseInt(_0xca5154(0x1b0))/0x8*(-parseInt(_0xca5154(0x1b2))/0x9)+-parseInt(_0xca5154(0x1a7))/0xa*(parseInt(_0xca5154(0x1a9))/0xb);if(_0x3a7188===_0x21633e)break;else _0x5d5474['push'](_0x5d5474['shift']());}catch(_0x43e701){_0x5d5474['push'](_0x5d5474['shift']());}}}(a136_0x5827,0x9591e));function a136_0x5827(){const _0x54db1b=['tags','set','env','has','isDirectory','metadataPath','cache','sort','map','localeCompare','source','70210ohPdfg','8491665YiyuGf','cacheDir','filter','67370dboxPJ','isArray','11QRnCMQ','\x20!=\x20','isSymbolicLink','2949UXPuCV','trim','push','skillCode','4616tMHekb','project','11592zZnDOa','739109taTVKu','code','2eOhWsi','get','validation','2188HlgrlJ','appCode','6679872ptBVjt','linkedPaths','accessKey','skillMdPath','name','values','Runtime\x20Skill\x20install\x20target\x20app\x20mismatch:\x20','scope','linkedPath','from','scopes','link','dir'];a136_0x5827=function(){return _0x54db1b;};return a136_0x5827();}import{existsSync,readdirSync}from'node:fs';import{resolve}from'node:path';import{CliErrors}from'../../errors.js';import{METADATA_FILE,SKILL_FILE}from'./constants.js';import{readMetadataIfPresent}from'./metadata.js';import{getRuntimeSkillCacheRoot,safePathSegment}from'./paths.js';import{isRuntimeSkillScope,normalizeRuntimeSkillScopes}from'./scopes.js';export function listLocalRuntimeSkills(_0x31a653,_0x1d3055,_0x556766={}){const _0x57980c=a136_0x3f1c,_0x3270a3=safePathSegment(_0x31a653['appCode'],_0x57980c(0x1b9));if(_0x1d3055['appCode']!==_0x3270a3)throw CliErrors[_0x57980c(0x1b7)](_0x57980c(0x1c0)+_0x1d3055[_0x57980c(0x1b9)]+_0x57980c(0x1aa)+_0x3270a3);const _0x590bc4=normalizeRuntimeSkillScopes(_0x31a653['scopes']),_0x301a6a=new Set(_0x590bc4),_0x4d8339=_0x31a653['code']?.[_0x57980c(0x1ad)](),_0x25d922=new Map(),_0x1df482=resolve(getRuntimeSkillCacheRoot(_0x31a653[_0x57980c(0x1c9)],_0x31a653[_0x57980c(0x1bc)],_0x556766),_0x3270a3);for(const _0x13f374 of _0x590bc4){for(const _0x94e13c of localSkillEntryDirs(resolve(_0x1df482,_0x13f374))){collectLocalRuntimeSkill(_0x25d922,_0x94e13c,{'appCode':_0x3270a3,'scopes':_0x301a6a,'code':_0x4d8339,'source':'cache'});}}for(const _0x5664aa of _0x1d3055['skillRoots']){for(const _0x1cf9a2 of localSkillLinkCandidates(_0x5664aa,_0x1d3055,_0x301a6a)){collectLocalRuntimeSkill(_0x25d922,_0x1cf9a2,{'appCode':_0x3270a3,'scopes':_0x301a6a,'code':_0x4d8339,'source':_0x57980c(0x1c5),'linkedPath':_0x1cf9a2});}}return Array[_0x57980c(0x1c3)](_0x25d922[_0x57980c(0x1bf)]())[_0x57980c(0x19f)](compareLocalRuntimeSkills);}function localSkillEntryDirs(_0x40c3c3){const _0x9cb3e5=a136_0x3f1c;if(!existsSync(_0x40c3c3))return[];return readdirSync(_0x40c3c3,{'withFileTypes':!![]})[_0x9cb3e5(0x1a6)](_0x4c3978=>_0x4c3978[_0x9cb3e5(0x1cb)]()||_0x4c3978['isSymbolicLink']())[_0x9cb3e5(0x1a0)](_0xac9afa=>resolve(_0x40c3c3,_0xac9afa[_0x9cb3e5(0x1be)]));}function localSkillLinkCandidates(_0x2ae662,_0x3a67d2,_0x5b20f7){const _0x328c17=a136_0x3f1c;if(!existsSync(_0x2ae662))return[];const _0x57489b=_0x3a67d2['appCode']+'--';return readdirSync(_0x2ae662,{'withFileTypes':!![]})[_0x328c17(0x1a6)](_0x353eb0=>_0x353eb0[_0x328c17(0x1cb)]()||_0x353eb0[_0x328c17(0x1ab)]())[_0x328c17(0x1a6)](_0x2e1ba1=>_0x3a67d2[_0x328c17(0x1c1)]===_0x328c17(0x1b1)||_0x2e1ba1[_0x328c17(0x1be)]['startsWith'](_0x57489b)||_0x5b20f7[_0x328c17(0x1ca)]('builtin'))[_0x328c17(0x1a0)](_0xf9dbe=>resolve(_0x2ae662,_0xf9dbe[_0x328c17(0x1be)]));}function a136_0x3f1c(_0x46ea53,_0x2f48fa){_0x46ea53=_0x46ea53-0x19d;const _0x58271b=a136_0x5827();let _0x3f1c0a=_0x58271b[_0x46ea53];return _0x3f1c0a;}function collectLocalRuntimeSkill(_0x1e10c5,_0x288990,_0x19306f){const _0x36b797=a136_0x3f1c,_0x277fb3=resolve(_0x288990,METADATA_FILE),_0x3f24f9=readMetadataIfPresent(_0x277fb3);if(!_0x3f24f9)return;if(_0x3f24f9[_0x36b797(0x1b9)]!==_0x19306f[_0x36b797(0x1b9)])return;if(!isRuntimeSkillScope(_0x3f24f9[_0x36b797(0x1c1)])||!_0x19306f[_0x36b797(0x1c4)]['has'](_0x3f24f9[_0x36b797(0x1c1)]))return;const _0x3538d5=_0x3f24f9[_0x36b797(0x1af)]?.['trim']();if(!_0x3538d5)return;if(_0x19306f[_0x36b797(0x1b4)]&&_0x3538d5!==_0x19306f[_0x36b797(0x1b4)])return;const _0x58b502=_0x3f24f9['scope']+':'+_0x3538d5,_0x2fc2f8=_0x19306f[_0x36b797(0x1c2)]?[_0x19306f[_0x36b797(0x1c2)]]:[],_0x507c11=_0x1e10c5[_0x36b797(0x1b6)](_0x58b502);if(_0x507c11){_0x19306f[_0x36b797(0x1a2)]===_0x36b797(0x19e)&&(_0x507c11[_0x36b797(0x1c6)]=_0x288990,_0x507c11[_0x36b797(0x1a5)]=_0x288990,_0x507c11[_0x36b797(0x1bd)]=resolve(_0x288990,SKILL_FILE),_0x507c11[_0x36b797(0x19d)]=_0x277fb3);for(const _0x74831a of _0x2fc2f8){!_0x507c11[_0x36b797(0x1bb)]['includes'](_0x74831a)&&_0x507c11[_0x36b797(0x1bb)][_0x36b797(0x1ae)](_0x74831a);}_0x507c11['linkedPaths'][_0x36b797(0x19f)]();return;}_0x1e10c5[_0x36b797(0x1c8)](_0x58b502,{..._0x3f24f9,'tags':Array[_0x36b797(0x1a8)](_0x3f24f9[_0x36b797(0x1c7)])?_0x3f24f9[_0x36b797(0x1c7)]:[],'scope':_0x3f24f9[_0x36b797(0x1c1)],'source':'local','dir':_0x288990,'cacheDir':_0x19306f[_0x36b797(0x1a2)]===_0x36b797(0x19e)?_0x288990:undefined,'skillMdPath':resolve(_0x288990,SKILL_FILE),'metadataPath':_0x277fb3,'linkedPaths':_0x2fc2f8});}function compareLocalRuntimeSkills(_0x4747fa,_0x13b78d){const _0x5334ca=a136_0x3f1c,_0x59bfcd={'personal':0x0,'company':0x1,'builtin':0x2};return _0x59bfcd[_0x4747fa[_0x5334ca(0x1c1)]]-_0x59bfcd[_0x13b78d[_0x5334ca(0x1c1)]]||_0x4747fa[_0x5334ca(0x1af)][_0x5334ca(0x1a1)](_0x13b78d[_0x5334ca(0x1af)])||_0x4747fa[_0x5334ca(0x1c6)][_0x5334ca(0x1a1)](_0x13b78d[_0x5334ca(0x1c6)]);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x3dd1a8,_0x3d9610){const _0x3db67e=a137_0xa3a0,_0x4d05f6=_0x3dd1a8();while(!![]){try{const _0x386d9f=-parseInt(_0x3db67e(0x1a0))/0x1*(parseInt(_0x3db67e(0x1b5))/0x2)+-parseInt(_0x3db67e(0x197))/0x3+parseInt(_0x3db67e(0x1ab))/0x4+parseInt(_0x3db67e(0x1b2))/0x5*(parseInt(_0x3db67e(0x1b3))/0x6)+parseInt(_0x3db67e(0x1b1))/0x7*(parseInt(_0x3db67e(0x194))/0x8)+-parseInt(_0x3db67e(0x1b4))/0x9+-parseInt(_0x3db67e(0x1aa))/0xa;if(_0x386d9f===_0x3d9610)break;else _0x4d05f6['push'](_0x4d05f6['shift']());}catch(_0x256783){_0x4d05f6['push'](_0x4d05f6['shift']());}}}(a137_0x533e,0x6379c));function a137_0xa3a0(_0x1b29c9,_0x1c82ec){_0x1b29c9=_0x1b29c9-0x191;const _0x533ef8=a137_0x533e();let _0xa3a0ac=_0x533ef8[_0x1b29c9];return _0xa3a0ac;}import{readFileSync,readdirSync,realpathSync}from'node:fs';import{relative,resolve}from'node:path';import{CliErrors}from'../../errors.js';import{IGNORED_DIR_NAMES,IGNORED_FILE_NAMES,SKILL_FILE}from'./constants.js';export function fileContent(_0x36634d){const _0xd5153b=a137_0xa3a0;return _0x36634d[_0xd5153b(0x1ac)]??Buffer[_0xd5153b(0x19f)](_0x36634d[_0xd5153b(0x1b9)]??'',_0xd5153b(0x1ae));}export function fileText(_0x28aa56){const _0xc972ae=a137_0xa3a0;return fileContent(_0x28aa56)['toString'](_0xc972ae(0x1ae));}export function normalizeLocalFiles(_0x361d18){const _0x280f25=a137_0xa3a0;if(!Array['isArray'](_0x361d18)||_0x361d18['length']===0x0)return[];const _0x18c237=new Map();for(const _0x1f927c of _0x361d18){if(!_0x1f927c||typeof _0x1f927c!=='object'||typeof _0x1f927c[_0x280f25(0x19c)]!=='string')throw CliErrors[_0x280f25(0x198)]('Skill\x20file\x20path\x20must\x20be\x20text.');const _0x5e894a=normalizeSkillRelativePath(_0x1f927c[_0x280f25(0x19c)]);if(_0x18c237[_0x280f25(0x19a)](_0x5e894a))throw CliErrors[_0x280f25(0x198)](_0x280f25(0x196)+_0x5e894a);if(_0x1f927c[_0x280f25(0x1ac)]!==undefined&&!Buffer[_0x280f25(0x1b0)](_0x1f927c[_0x280f25(0x1ac)]))throw CliErrors[_0x280f25(0x198)]('Skill\x20file\x20bytes\x20must\x20be\x20a\x20Buffer:\x20'+_0x5e894a);if(_0x1f927c['bytes']===undefined&&typeof _0x1f927c['content']!==_0x280f25(0x193))throw CliErrors[_0x280f25(0x198)](_0x280f25(0x195)+_0x5e894a);const _0x7066aa=fileContent(_0x1f927c);_0x18c237[_0x280f25(0x19d)](_0x5e894a,{'path':_0x5e894a,'bytes':_0x7066aa});}return Array['from'](_0x18c237[_0x280f25(0x1ad)]())[_0x280f25(0x1a8)](compareSkillFiles);}export function normalizeManifestFiles(_0x1f075b){const _0x1e8dcf=a137_0xa3a0;if(!Array[_0x1e8dcf(0x192)](_0x1f075b)||_0x1f075b[_0x1e8dcf(0x1a9)]===0x0)return[];const _0xb6abe7=new Map();for(const _0x262e0c of _0x1f075b){if(!_0x262e0c||typeof _0x262e0c!=='object'||typeof _0x262e0c[_0x1e8dcf(0x19c)]!==_0x1e8dcf(0x193))throw CliErrors[_0x1e8dcf(0x198)](_0x1e8dcf(0x19e));const _0x27cb6b=normalizeSkillRelativePath(_0x262e0c[_0x1e8dcf(0x19c)]);if(_0xb6abe7[_0x1e8dcf(0x19a)](_0x27cb6b))throw CliErrors[_0x1e8dcf(0x198)](_0x1e8dcf(0x196)+_0x27cb6b);if(!isSha256Hex(_0x262e0c[_0x1e8dcf(0x1a5)]))throw CliErrors[_0x1e8dcf(0x198)](_0x1e8dcf(0x191)+_0x27cb6b);if(!Number['isSafeInteger'](_0x262e0c['size'])||_0x262e0c[_0x1e8dcf(0x199)]<0x0)throw CliErrors[_0x1e8dcf(0x198)](_0x1e8dcf(0x1b6)+_0x27cb6b);_0xb6abe7[_0x1e8dcf(0x19d)](_0x27cb6b,{'path':_0x27cb6b,'sha256':_0x262e0c[_0x1e8dcf(0x1a5)]['toLowerCase'](),'size':_0x262e0c[_0x1e8dcf(0x199)]});}return Array[_0x1e8dcf(0x19f)](_0xb6abe7[_0x1e8dcf(0x1ad)]())['sort'](compareSkillFiles);}export function scanSkillDirectory(_0x2ea809,_0x58f55d={}){const _0x299dc2=a137_0xa3a0,_0x5949c3=realpathSync(_0x2ea809),_0x2ded90=canonicalExcludedFilePaths(_0x58f55d[_0x299dc2(0x1a4)]),_0x1974ac=[];function _0xc6256(_0x8812b6){const _0x6c485e=_0x299dc2,_0x31df28=readdirSync(_0x8812b6,{'withFileTypes':!![]})[_0x6c485e(0x1a8)]((_0x105ad2,_0x50844b)=>_0x105ad2[_0x6c485e(0x19b)][_0x6c485e(0x1b7)](_0x50844b[_0x6c485e(0x19b)]));for(const _0x1ed2de of _0x31df28){if(_0x1ed2de['isDirectory']()&&IGNORED_DIR_NAMES[_0x6c485e(0x19a)](_0x1ed2de[_0x6c485e(0x19b)]))continue;if(IGNORED_FILE_NAMES[_0x6c485e(0x19a)](_0x1ed2de[_0x6c485e(0x19b)]))continue;const _0x14fea2=resolve(_0x8812b6,_0x1ed2de[_0x6c485e(0x19b)]);if(isExcludedFilePath(_0x14fea2,_0x2ded90))continue;if(_0x1ed2de['isSymbolicLink']())throw CliErrors[_0x6c485e(0x198)]('Skill\x20directory\x20contains\x20unsupported\x20symlink:\x20'+_0x14fea2);const _0x432950=toPosixPath(relative(_0x5949c3,_0x14fea2));if(_0x1ed2de[_0x6c485e(0x1a6)]()){_0xc6256(_0x14fea2);continue;}if(!_0x1ed2de[_0x6c485e(0x1a7)]())continue;validateSkillRelativePath(_0x432950);const _0x2f537a=readFileSync(_0x14fea2);_0x1974ac[_0x6c485e(0x1a1)]({'path':_0x432950,'bytes':_0x2f537a});}}return _0xc6256(_0x5949c3),normalizeLocalFiles(_0x1974ac);}function canonicalExcludedFilePaths(_0x281a63){const _0x1bdc2b=a137_0xa3a0,_0x1c6a8f=new Set();for(const _0x386999 of _0x281a63??[]){const _0x2a0b7c=resolve(_0x386999);_0x1c6a8f[_0x1bdc2b(0x1af)](_0x2a0b7c);try{_0x1c6a8f[_0x1bdc2b(0x1af)](realpathSync(_0x2a0b7c));}catch{}}return _0x1c6a8f;}function isExcludedFilePath(_0x27422c,_0x4d76b3){const _0x1bbdeb=a137_0xa3a0;if(_0x4d76b3[_0x1bbdeb(0x19a)](_0x27422c))return!![];if(_0x4d76b3[_0x1bbdeb(0x199)]===0x0)return![];try{return _0x4d76b3[_0x1bbdeb(0x19a)](realpathSync(_0x27422c));}catch{return![];}}export function compareSkillFiles(_0x50eb18,_0x4fdc28){const _0x3c843a=a137_0xa3a0;if(_0x50eb18[_0x3c843a(0x19c)]===SKILL_FILE)return _0x4fdc28[_0x3c843a(0x19c)]===SKILL_FILE?0x0:-0x1;if(_0x4fdc28[_0x3c843a(0x19c)]===SKILL_FILE)return 0x1;return Buffer['compare'](Buffer['from'](_0x50eb18[_0x3c843a(0x19c)],_0x3c843a(0x1ae)),Buffer['from'](_0x4fdc28[_0x3c843a(0x19c)],_0x3c843a(0x1ae)));}export function normalizeSkillRelativePath(_0x194ba1){const _0x276fcd=a137_0xa3a0,_0x235837=toPosixPath(_0x194ba1[_0x276fcd(0x1a3)]());return validateSkillRelativePath(_0x235837),_0x235837;}function a137_0x533e(){const _0x2cde64=['length','7649520aLXIgV','3062140nWWKii','bytes','values','utf8','add','isBuffer','259ZJSply','6040AbEKEj','3366CTYLjo','2268045zNCFjJ','8aMTtli','Skill\x20file\x20size\x20is\x20invalid:\x20','localeCompare','split','content','Skill\x20file\x20sha256\x20is\x20invalid:\x20','isArray','string','117920mdCFzV','Skill\x20file\x20content\x20must\x20be\x20text\x20or\x20bytes:\x20','Duplicate\x20Skill\x20file\x20path:\x20','1255374esoDxF','validation','size','has','name','path','set','Skill\x20file\x20path\x20must\x20be\x20text.','from','36434lqhQkp','push','includes','trim','excludedFilePaths','sha256','isDirectory','isFile','sort'];a137_0x533e=function(){return _0x2cde64;};return a137_0x533e();}export function validateSkillRelativePath(_0x1ee837){const _0x1ff26d=a137_0xa3a0;if(!_0x1ee837||_0x1ee837['startsWith']('/')||_0x1ee837[_0x1ff26d(0x1a2)]('//'))throw CliErrors['validation']('Unsafe\x20Skill\x20file\x20path:\x20'+_0x1ee837);for(const _0x184543 of _0x1ee837[_0x1ff26d(0x1b8)]('/')){if(!_0x184543||_0x184543==='.'||_0x184543==='..')throw CliErrors[_0x1ff26d(0x198)]('Unsafe\x20Skill\x20file\x20path:\x20'+_0x1ee837);}}export function toPosixPath(_0x1436f1){return _0x1436f1['replace'](/\\/g,'/');}export function isSha256Hex(_0x59c656){const _0x4c1fdd=a137_0xa3a0;return typeof _0x59c656===_0x4c1fdd(0x193)&&/^[a-fA-F0-9]{64}$/['test'](_0x59c656);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(_0x1d52cd,_0x1bfd21){const _0x2f8671=a138_0x349d,_0x46c439=_0x1d52cd();while(!![]){try{const _0x3ff3ec=-parseInt(_0x2f8671(0x122))/0x1*(parseInt(_0x2f8671(0x145))/0x2)+-parseInt(_0x2f8671(0x11d))/0x3*(-parseInt(_0x2f8671(0x125))/0x4)+parseInt(_0x2f8671(0x130))/0x5*(-parseInt(_0x2f8671(0x155))/0x6)+-parseInt(_0x2f8671(0x13e))/0x7*(parseInt(_0x2f8671(0x153))/0x8)+parseInt(_0x2f8671(0x138))/0x9+-parseInt(_0x2f8671(0x127))/0xa+parseInt(_0x2f8671(0x123))/0xb;if(_0x3ff3ec===_0x1bfd21)break;else _0x46c439['push'](_0x46c439['shift']());}catch(_0x20271a){_0x46c439['push'](_0x46c439['shift']());}}}(a138_0x54ff,0x2a854));import{existsSync,lstatSync,mkdirSync,readFileSync,rmSync}from'node:fs';function a138_0x54ff(){const _0xc6f583=['description:\x20','flow','displayName','trim','contentHash','find','16bmXYIY','filter','6SxIfpw','keys','skillName','length','Push\x20the\x20directory\x20first,\x20then\x20rerun\x20skill\x20install.','toString','delete','201XdYXTX','set','match','entries','Runtime\x20Skill\x20package\x20is\x20missing\x20','157SXcGUa','6306080ooKgig','---\x0a','2516eUsJPL','---','1481740dEUZdW','validation','packageBytes','map','isFile','Local\x20Skill\x20files\x20have\x20unpushed\x20edits:\x20','Managed\x20file\x20was\x20removed\x20locally:\x20','status','name','967790hrrQQN','accessKey','example','slice','\x0a---\x0a\x0a','fileHashes','utf8','Remote\x20Skill\x20would\x20overwrite\x20a\x20local\x20non-file\x20path:\x20','863010NrwNeY','.\x20Changed\x20file:\x20','paths','version','test','Managed\x20file\x20is\x20no\x20longer\x20a\x20regular\x20file:\x20','453719LjTBxt','replace','appCode','Remote\x20Skill\x20would\x20overwrite\x20an\x20unmanaged\x20local\x20file:\x20','displayName:\x20','env','pulledAt','838mlLrwN','Local\x20SKILL.md\x20has\x20unpushed\x20edits:\x20','path','schemaVersion','skillCode','scope','force','description'];a138_0x54ff=function(){return _0xc6f583;};return a138_0x54ff();}import{dirname,resolve}from'node:path';import{isCollection,isMap,isNode,parseDocument,visit}from'yaml';import{CliErrors}from'../../errors.js';import{METADATA_FILE,SKILL_FILE}from'./constants.js';import{resolveManagedFilePath,writeBytesAtomic,writeJsonAtomic}from'./fs-utils.js';import{bufferSha256,contentHash,fileHash}from'./hashing.js';import{fileContent,fileText,normalizeLocalFiles}from'./local-files.js';import{buildMetadata,readMetadataIfPresent,requireSkillCode}from'./metadata.js';import{getRuntimeSkillDir}from'./paths.js';import{extractDownloadedPackage,requirePackageBytes}from'./zip-package.js';function a138_0x349d(_0x2b3ea8,_0x3a1708){_0x2b3ea8=_0x2b3ea8-0x119;const _0x54ff92=a138_0x54ff();let _0x349d85=_0x54ff92[_0x2b3ea8];return _0x349d85;}export function materializeRuntimeSkill(_0x2b89df,_0x3368c0,_0x24156a){const _0x176859=a138_0x349d,_0x5d6d25=requireSkillCode(_0x2b89df),_0x4e5dc7=requirePackageBytes(_0x5d6d25,_0x24156a[_0x176859(0x129)]),_0x58cf0e=extractDownloadedPackage(_0x4e5dc7),_0x188bdc=_0x58cf0e[_0x176859(0x152)](_0x1a37b6=>_0x1a37b6['path']===SKILL_FILE);if(!_0x188bdc)throw CliErrors['validation'](_0x176859(0x121)+SKILL_FILE+':\x20'+_0x5d6d25);const _0x2ba848=withMaterializedSkillFrontmatter(_0x58cf0e,_0x2b89df,_0x5d6d25),_0x3467d2=_0x2ba848[_0x176859(0x152)](_0x19c072=>_0x19c072[_0x176859(0x147)]===SKILL_FILE),_0x3d6773=fileText(_0x3467d2),_0xbd1ac3=getRuntimeSkillDir(_0x24156a[_0x176859(0x143)],_0x24156a[_0x176859(0x131)],_0x24156a[_0x176859(0x140)],_0x3368c0,_0x5d6d25,_0x24156a[_0x176859(0x13a)]),_0x12376e=resolve(_0xbd1ac3,SKILL_FILE),_0x27759f=resolve(_0xbd1ac3,METADATA_FILE),_0x4af0e1=contentHash(_0x3d6773),_0x281be3=readMetadataIfPresent(_0x27759f)?.[_0x176859(0x135)];ensurePulledFilesCanBeOverwritten(_0xbd1ac3,_0x27759f,_0x2ba848,_0x24156a[_0x176859(0x14b)]===!![]),mkdirSync(_0xbd1ac3,{'recursive':!![],'mode':0x1c0});const _0x3fa871=existsSync(_0x12376e)?readFileSync(_0x12376e,_0x176859(0x136)):undefined;return materializeFiles(_0xbd1ac3,_0x2ba848),removeStaleManagedFiles(_0xbd1ac3,_0x281be3,_0x2ba848),writeJsonAtomic(_0x27759f,buildMetadata(_0x2b89df,_0x3368c0,_0x24156a['appCode'],_0x4af0e1,_0x24156a[_0x176859(0x144)],_0x2ba848,_0x4e5dc7)),{'skill':_0x2b89df,'scope':_0x3368c0,'dir':_0xbd1ac3,'skillMdPath':_0x12376e,'metadataPath':_0x27759f,'contentHash':_0x4af0e1,'changed':_0x3fa871!==_0x3d6773};}export function reuseMaterializedRuntimeSkill(_0xe3dcd0,_0x2d24e7,_0x168db4){const _0x2fbe20=a138_0x349d,_0x2cda94=_0xe3dcd0[_0x2fbe20(0x13b)]?.['trim']();if(!_0x2cda94)return undefined;const _0x3a26b3=requireSkillCode(_0xe3dcd0),_0x230f08=getRuntimeSkillDir(_0x168db4['env'],_0x168db4[_0x2fbe20(0x131)],_0x168db4[_0x2fbe20(0x140)],_0x2d24e7,_0x3a26b3,_0x168db4[_0x2fbe20(0x13a)]),_0x2aeb11=resolve(_0x230f08,SKILL_FILE),_0x47f98d=resolve(_0x230f08,METADATA_FILE),_0x13700c=readMetadataIfPresent(_0x47f98d);if(!_0x13700c||_0x13700c[_0x2fbe20(0x148)]!==0x2||_0x13700c['appCode']!==_0x168db4[_0x2fbe20(0x140)]||_0x13700c[_0x2fbe20(0x14a)]!==_0x2d24e7||_0x13700c[_0x2fbe20(0x149)]!==_0x3a26b3||_0x13700c[_0x2fbe20(0x13b)]!==_0x2cda94||_0x13700c['id']!==_0xe3dcd0['id']||_0x13700c['skillName']!==_0xe3dcd0[_0x2fbe20(0x157)]||_0x13700c[_0x2fbe20(0x14c)]!==_0xe3dcd0[_0x2fbe20(0x14c)]||_0x13700c[_0x2fbe20(0x132)]!==_0xe3dcd0[_0x2fbe20(0x132)]||_0x13700c[_0x2fbe20(0x12e)]!==_0xe3dcd0['status']||!_0x13700c['contentHash']||!_0x13700c[_0x2fbe20(0x135)]||!Object['hasOwn'](_0x13700c['fileHashes'],SKILL_FILE))return undefined;for(const [_0x50a12f,_0xfafc59]of Object[_0x2fbe20(0x120)](_0x13700c['fileHashes'])){if(!/^[a-f0-9]{64}$/['test'](_0xfafc59))return undefined;const _0x1c6d15=resolveManagedFilePath(_0x230f08,_0x50a12f);if(!existsSync(_0x1c6d15)||!lstatSync(_0x1c6d15)[_0x2fbe20(0x12b)]())return undefined;if(bufferSha256(readFileSync(_0x1c6d15))!==_0xfafc59)return undefined;}return{'skill':_0xe3dcd0,'scope':_0x2d24e7,'dir':_0x230f08,'skillMdPath':_0x2aeb11,'metadataPath':_0x47f98d,'contentHash':_0x13700c[_0x2fbe20(0x151)],'changed':![]};}function withMaterializedSkillFrontmatter(_0x243d3d,_0x5aa4a3,_0x4ae812){const _0x356810=a138_0x349d,_0x3c2ab7=skillDisplayName(_0x5aa4a3,_0x4ae812),_0x1fe41f=_0x5aa4a3[_0x356810(0x14c)]?.[_0x356810(0x150)]()||_0x3c2ab7||_0x4ae812;return normalizeLocalFiles(_0x243d3d)[_0x356810(0x12a)](_0x50b9cd=>{const _0x22800d=_0x356810,_0x1b6f44=fileText(_0x50b9cd);if(_0x50b9cd[_0x22800d(0x147)]!==SKILL_FILE)return _0x50b9cd;if(hasYamlFrontmatter(_0x1b6f44))return{'path':_0x50b9cd[_0x22800d(0x147)],'content':withSyncedDisplayName(_0x1b6f44,_0x3c2ab7)};return{'path':_0x50b9cd[_0x22800d(0x147)],'content':prependSkillFrontmatter(_0x1b6f44,{'name':_0x4ae812,'displayName':_0x3c2ab7,'description':_0x1fe41f})};});}function hasYamlFrontmatter(_0xec4541){const _0x3852b1=a138_0x349d;return/^\uFEFF?---\s*\r?\n/[_0x3852b1(0x13c)](_0xec4541);}function prependSkillFrontmatter(_0x3247ff,_0x1cb547){const _0x3620b9=a138_0x349d,_0x5e710a=_0x3247ff[_0x3620b9(0x13f)](/^\uFEFF/,'');return[_0x3620b9(0x126),'name:\x20'+yamlString(_0x1cb547[_0x3620b9(0x12f)]),_0x1cb547[_0x3620b9(0x14f)]?_0x3620b9(0x142)+yamlString(_0x1cb547[_0x3620b9(0x14f)]):undefined,_0x3620b9(0x14d)+yamlString(_0x1cb547[_0x3620b9(0x14c)]),_0x3620b9(0x126),'',_0x5e710a][_0x3620b9(0x154)](_0x3bcd5a=>_0x3bcd5a!==undefined)['join']('\x0a');}function yamlString(_0xc3f512){const _0x20dca2=a138_0x349d;return JSON['stringify'](_0xc3f512['replace'](/\r/g,'')[_0x20dca2(0x150)]());}function skillDisplayName(_0x13322a,_0x2a6946){const _0x3f56de=a138_0x349d,_0x566f39=_0x13322a[_0x3f56de(0x157)]?.[_0x3f56de(0x150)]();return _0x566f39||_0x2a6946;}function withSyncedDisplayName(_0x5aec3e,_0x1efc36){const _0x24d0dd=a138_0x349d,_0x99e677=_0x5aec3e[_0x24d0dd(0x11f)](/^(\uFEFF?)---\s*\r?\n([\s\S]*?)\r?\n---(?:\r?\n|$)/);if(!_0x99e677)return _0x5aec3e;const _0x3e1f27=_0x99e677[0x1]??'',_0xb1da06=_0x99e677[0x2]??'',_0x3c7a33=parseDocument(_0xb1da06);if(_0x3c7a33['errors'][_0x24d0dd(0x119)]>0x0||!isMap(_0x3c7a33['contents']))return _0x5aec3e;if(_0x1efc36)_0x3c7a33[_0x24d0dd(0x11e)]('displayName',_0x1efc36);else{if(_0x3c7a33['has']('displayName'))_0x3c7a33[_0x24d0dd(0x11c)](_0x24d0dd(0x14f));else return _0x5aec3e;}forceBlockCollections(_0x3c7a33['contents']);const _0x1b5748=_0x3c7a33[_0x24d0dd(0x11b)]({'lineWidth':0x0})['trimEnd'](),_0x257bce=_0x5aec3e[_0x24d0dd(0x133)](_0x99e677[0x0][_0x24d0dd(0x119)])[_0x24d0dd(0x13f)](/^\r?\n/,'');return _0x3e1f27+_0x24d0dd(0x124)+_0x1b5748+_0x24d0dd(0x134)+_0x257bce;}function forceBlockCollections(_0x416069){if(!isNode(_0x416069))return;visit(_0x416069,(_0x168b16,_0x27ca0c)=>{const _0x17ad0a=a138_0x349d;isCollection(_0x27ca0c)&&(_0x27ca0c[_0x17ad0a(0x14e)]=![]);});}function ensurePulledFilesCanBeOverwritten(_0x568cea,_0x580867,_0x24904a,_0x39b042){const _0x5d2aa6=a138_0x349d;if(_0x39b042||!existsSync(_0x580867))return;const _0x40e9e4=readMetadataIfPresent(_0x580867);if(!_0x40e9e4)return;const _0x4f13cc=_0x40e9e4[_0x5d2aa6(0x135)]&&Object[_0x5d2aa6(0x156)](_0x40e9e4[_0x5d2aa6(0x135)])[_0x5d2aa6(0x119)]>0x0?_0x40e9e4[_0x5d2aa6(0x135)]:undefined;if(_0x4f13cc)for(const [_0x939591,_0x35fc49]of Object[_0x5d2aa6(0x120)](_0x4f13cc)){const _0x564e4f=resolveManagedFilePath(_0x568cea,_0x939591);if(!existsSync(_0x564e4f))throw CliErrors[_0x5d2aa6(0x128)]('Local\x20Skill\x20files\x20have\x20unpushed\x20edits:\x20'+_0x568cea,_0x5d2aa6(0x12d)+_0x939591);const _0x320593=lstatSync(_0x564e4f);if(!_0x320593[_0x5d2aa6(0x12b)]())throw CliErrors[_0x5d2aa6(0x128)](_0x5d2aa6(0x12c)+_0x568cea,_0x5d2aa6(0x13d)+_0x939591);const _0x39dc12=bufferSha256(readFileSync(_0x564e4f));if(_0x39dc12!==_0x35fc49)throw CliErrors[_0x5d2aa6(0x128)]('Local\x20Skill\x20files\x20have\x20unpushed\x20edits:\x20'+_0x568cea+_0x5d2aa6(0x139)+_0x939591,'Push\x20the\x20directory\x20first,\x20then\x20rerun\x20skill\x20install.\x20Changed\x20file:\x20'+_0x939591);}else{const _0x55bbe9=resolve(_0x568cea,SKILL_FILE);if(existsSync(_0x55bbe9)&&_0x40e9e4[_0x5d2aa6(0x151)]){const _0x28e2d1=contentHash(readFileSync(_0x55bbe9,_0x5d2aa6(0x136)));if(_0x28e2d1!==_0x40e9e4['contentHash'])throw CliErrors[_0x5d2aa6(0x128)](_0x5d2aa6(0x146)+_0x55bbe9,_0x5d2aa6(0x11a));}}for(const _0x3269f8 of normalizeLocalFiles(_0x24904a)){if(_0x4f13cc?.[_0x3269f8['path']])continue;if(!_0x4f13cc&&_0x3269f8[_0x5d2aa6(0x147)]===SKILL_FILE)continue;const _0x13c69e=resolveManagedFilePath(_0x568cea,_0x3269f8[_0x5d2aa6(0x147)]);if(!existsSync(_0x13c69e))continue;const _0x171de4=lstatSync(_0x13c69e);if(!_0x171de4[_0x5d2aa6(0x12b)]())throw CliErrors[_0x5d2aa6(0x128)](_0x5d2aa6(0x12c)+_0x568cea,_0x5d2aa6(0x137)+_0x3269f8[_0x5d2aa6(0x147)]);const _0x42496e=bufferSha256(readFileSync(_0x13c69e));if(_0x42496e!==fileHash(_0x3269f8))throw CliErrors[_0x5d2aa6(0x128)](_0x5d2aa6(0x12c)+_0x568cea,_0x5d2aa6(0x141)+_0x3269f8[_0x5d2aa6(0x147)]);}}function materializeFiles(_0x1cb3b1,_0x1a5938){const _0x373bee=a138_0x349d;for(const _0x5eb459 of normalizeLocalFiles(_0x1a5938)){const _0x2388c4=resolveManagedFilePath(_0x1cb3b1,_0x5eb459[_0x373bee(0x147)]);mkdirSync(dirname(_0x2388c4),{'recursive':!![],'mode':0x1c0}),writeBytesAtomic(_0x2388c4,fileContent(_0x5eb459),0x180);}}function removeStaleManagedFiles(_0x604e05,_0x270e2e,_0x48f5c6){const _0x282ae4=a138_0x349d;if(!_0x270e2e)return;const _0x594839=new Set(normalizeLocalFiles(_0x48f5c6)[_0x282ae4(0x12a)](_0x32162d=>_0x32162d[_0x282ae4(0x147)]));for(const _0x491c03 of Object[_0x282ae4(0x156)](_0x270e2e)){if(_0x594839['has'](_0x491c03))continue;const _0xeec74e=resolveManagedFilePath(_0x604e05,_0x491c03);existsSync(_0xeec74e)&&lstatSync(_0xeec74e)[_0x282ae4(0x12b)]()&&rmSync(_0xeec74e,{'force':!![]});}}
|
|
1
|
+
(function(_0xee12c4,_0x53e348){const _0x46ee8b=a138_0x17d0,_0x2aaf5b=_0xee12c4();while(!![]){try{const _0x3ffad7=-parseInt(_0x46ee8b(0x218))/0x1+parseInt(_0x46ee8b(0x20d))/0x2*(-parseInt(_0x46ee8b(0x1fe))/0x3)+parseInt(_0x46ee8b(0x208))/0x4*(-parseInt(_0x46ee8b(0x1f4))/0x5)+parseInt(_0x46ee8b(0x20e))/0x6*(parseInt(_0x46ee8b(0x1ec))/0x7)+parseInt(_0x46ee8b(0x1eb))/0x8+-parseInt(_0x46ee8b(0x210))/0x9+-parseInt(_0x46ee8b(0x201))/0xa*(-parseInt(_0x46ee8b(0x1ed))/0xb);if(_0x3ffad7===_0x53e348)break;else _0x2aaf5b['push'](_0x2aaf5b['shift']());}catch(_0x3aa7e4){_0x2aaf5b['push'](_0x2aaf5b['shift']());}}}(a138_0x26ec,0x1d53f));import{existsSync,lstatSync,mkdirSync,readFileSync,rmSync}from'node:fs';function a138_0x17d0(_0x36c0b1,_0x5d051e){_0x36c0b1=_0x36c0b1-0x1e3;const _0x26ec3c=a138_0x26ec();let _0x17d096=_0x26ec3c[_0x36c0b1];return _0x17d096;}import{dirname,resolve}from'node:path';function a138_0x26ec(){const _0x2daf78=['915WvIEcg','match','test','Local\x20Skill\x20files\x20have\x20unpushed\x20edits:\x20','Remote\x20Skill\x20would\x20overwrite\x20an\x20unmanaged\x20local\x20file:\x20','description:\x20','length','flow','scope','keys','3LSzwNW','skillName','appCode','422780zFjVdb','contents','description','Managed\x20file\x20is\x20no\x20longer\x20a\x20regular\x20file:\x20','env','---\x0a','name','980GEQUCI','displayName','Runtime\x20Skill\x20package\x20is\x20missing\x20','entries','accessKey','201846CjpJmt','557958JZjSdV','version','1308024lFkXIK','name:\x20','stringify','---','displayName:\x20','delete','map','Push\x20the\x20directory\x20first,\x20then\x20rerun\x20skill\x20install.','39589OBPrqJ','validation','Managed\x20file\x20was\x20removed\x20locally:\x20','example','pulledAt','isFile','fileHashes','trim','packageBytes','hasOwn','status','force','765696VMnpQI','14bGJikk','44QeFnKm','replace','paths','path','contentHash','has','utf8'];a138_0x26ec=function(){return _0x2daf78;};return a138_0x26ec();}import{isCollection,isMap,isNode,parseDocument,visit}from'yaml';import{CliErrors}from'../../errors.js';import{METADATA_FILE,SKILL_FILE}from'./constants.js';import{resolveManagedFilePath,writeBytesAtomic,writeJsonAtomic}from'./fs-utils.js';import{bufferSha256,contentHash,fileHash}from'./hashing.js';import{fileContent,fileText,normalizeLocalFiles}from'./local-files.js';import{buildMetadata,readMetadataIfPresent,requireSkillCode}from'./metadata.js';import{getRuntimeSkillDir}from'./paths.js';import{extractDownloadedPackage,requirePackageBytes}from'./zip-package.js';export function materializeRuntimeSkill(_0x24038d,_0x3ddff0,_0x236fe8){const _0x4651a7=a138_0x17d0,_0x836d68=requireSkillCode(_0x24038d),_0x24df3d=requirePackageBytes(_0x836d68,_0x236fe8[_0x4651a7(0x1e7)]),_0x4ad2f6=extractDownloadedPackage(_0x24df3d),_0x5df29b=_0x4ad2f6['find'](_0x10b3c8=>_0x10b3c8['path']===SKILL_FILE);if(!_0x5df29b)throw CliErrors['validation'](_0x4651a7(0x20a)+SKILL_FILE+':\x20'+_0x836d68);const _0x145d5c=withMaterializedSkillFrontmatter(_0x4ad2f6,_0x24038d,_0x836d68),_0x426ebe=_0x145d5c['find'](_0x135117=>_0x135117[_0x4651a7(0x1f0)]===SKILL_FILE),_0x56abe4=fileText(_0x426ebe),_0x362355=getRuntimeSkillDir(_0x236fe8['env'],_0x236fe8[_0x4651a7(0x20c)],_0x236fe8[_0x4651a7(0x200)],_0x3ddff0,_0x836d68,_0x236fe8['paths']),_0x148132=resolve(_0x362355,SKILL_FILE),_0x2a1bce=resolve(_0x362355,METADATA_FILE),_0x468a07=contentHash(_0x56abe4),_0x48830e=readMetadataIfPresent(_0x2a1bce)?.[_0x4651a7(0x1e5)];ensurePulledFilesCanBeOverwritten(_0x362355,_0x2a1bce,_0x145d5c,_0x236fe8[_0x4651a7(0x1ea)]===!![]),mkdirSync(_0x362355,{'recursive':!![],'mode':0x1c0});const _0x3f1c7d=existsSync(_0x148132)?readFileSync(_0x148132,_0x4651a7(0x1f3)):undefined;return materializeFiles(_0x362355,_0x145d5c),removeStaleManagedFiles(_0x362355,_0x48830e,_0x145d5c),writeJsonAtomic(_0x2a1bce,buildMetadata(_0x24038d,_0x3ddff0,_0x236fe8['appCode'],_0x468a07,_0x236fe8[_0x4651a7(0x1e3)],_0x145d5c,_0x24df3d)),{'skill':_0x24038d,'scope':_0x3ddff0,'dir':_0x362355,'skillMdPath':_0x148132,'metadataPath':_0x2a1bce,'contentHash':_0x468a07,'changed':_0x3f1c7d!==_0x56abe4};}export function reuseMaterializedRuntimeSkill(_0x36df8c,_0x1d9cfa,_0x3912a5){const _0xc3c801=a138_0x17d0,_0x5db37f=_0x36df8c[_0xc3c801(0x20f)]?.[_0xc3c801(0x1e6)]();if(!_0x5db37f)return undefined;const _0x366ae5=requireSkillCode(_0x36df8c),_0x5f0b89=getRuntimeSkillDir(_0x3912a5[_0xc3c801(0x205)],_0x3912a5['accessKey'],_0x3912a5[_0xc3c801(0x200)],_0x1d9cfa,_0x366ae5,_0x3912a5[_0xc3c801(0x1ef)]),_0x4e6cc0=resolve(_0x5f0b89,SKILL_FILE),_0x4696e5=resolve(_0x5f0b89,METADATA_FILE),_0x4ef220=readMetadataIfPresent(_0x4696e5);if(!_0x4ef220||_0x4ef220['schemaVersion']!==0x2||_0x4ef220[_0xc3c801(0x200)]!==_0x3912a5['appCode']||_0x4ef220[_0xc3c801(0x1fc)]!==_0x1d9cfa||_0x4ef220['skillCode']!==_0x366ae5||_0x4ef220[_0xc3c801(0x20f)]!==_0x5db37f||_0x4ef220['id']!==_0x36df8c['id']||_0x4ef220[_0xc3c801(0x1ff)]!==_0x36df8c[_0xc3c801(0x1ff)]||_0x4ef220[_0xc3c801(0x203)]!==_0x36df8c[_0xc3c801(0x203)]||_0x4ef220[_0xc3c801(0x21b)]!==_0x36df8c[_0xc3c801(0x21b)]||_0x4ef220[_0xc3c801(0x1e9)]!==_0x36df8c['status']||!_0x4ef220[_0xc3c801(0x1f1)]||!_0x4ef220[_0xc3c801(0x1e5)]||!Object[_0xc3c801(0x1e8)](_0x4ef220[_0xc3c801(0x1e5)],SKILL_FILE))return undefined;for(const [_0x55be89,_0x214d8b]of Object[_0xc3c801(0x20b)](_0x4ef220[_0xc3c801(0x1e5)])){if(!/^[a-f0-9]{64}$/[_0xc3c801(0x1f6)](_0x214d8b))return undefined;const _0x3b61eb=resolveManagedFilePath(_0x5f0b89,_0x55be89);if(!existsSync(_0x3b61eb)||!lstatSync(_0x3b61eb)[_0xc3c801(0x1e4)]())return undefined;if(bufferSha256(readFileSync(_0x3b61eb))!==_0x214d8b)return undefined;}return{'skill':_0x36df8c,'scope':_0x1d9cfa,'dir':_0x5f0b89,'skillMdPath':_0x4e6cc0,'metadataPath':_0x4696e5,'contentHash':_0x4ef220['contentHash'],'changed':![]};}function withMaterializedSkillFrontmatter(_0x30992c,_0x123f9c,_0x10022a){const _0x31b76f=a138_0x17d0,_0xc65d86=skillDisplayName(_0x123f9c,_0x10022a),_0x320513=_0x123f9c['description']?.[_0x31b76f(0x1e6)]()||_0xc65d86||_0x10022a;return normalizeLocalFiles(_0x30992c)[_0x31b76f(0x216)](_0x961888=>{const _0x383976=_0x31b76f,_0xa874ae=fileText(_0x961888);if(_0x961888[_0x383976(0x1f0)]!==SKILL_FILE)return _0x961888;if(hasYamlFrontmatter(_0xa874ae))return{'path':_0x961888[_0x383976(0x1f0)],'content':withSyncedDisplayName(_0xa874ae,_0xc65d86)};return{'path':_0x961888[_0x383976(0x1f0)],'content':prependSkillFrontmatter(_0xa874ae,{'name':_0x10022a,'displayName':_0xc65d86,'description':_0x320513})};});}function hasYamlFrontmatter(_0x174561){const _0x583821=a138_0x17d0;return/^\uFEFF?---\s*\r?\n/[_0x583821(0x1f6)](_0x174561);}function prependSkillFrontmatter(_0x5b571a,_0x52a93a){const _0x209fce=a138_0x17d0,_0x1236ce=_0x5b571a['replace'](/^\uFEFF/,'');return[_0x209fce(0x213),_0x209fce(0x211)+yamlString(_0x52a93a[_0x209fce(0x207)]),_0x52a93a[_0x209fce(0x209)]?_0x209fce(0x214)+yamlString(_0x52a93a[_0x209fce(0x209)]):undefined,_0x209fce(0x1f9)+yamlString(_0x52a93a['description']),_0x209fce(0x213),'',_0x1236ce]['filter'](_0x16059f=>_0x16059f!==undefined)['join']('\x0a');}function yamlString(_0x420f39){const _0x1c9098=a138_0x17d0;return JSON[_0x1c9098(0x212)](_0x420f39[_0x1c9098(0x1ee)](/\r/g,'')[_0x1c9098(0x1e6)]());}function skillDisplayName(_0x520287,_0x4648bc){const _0xcb1315=a138_0x17d0,_0x59f33f=_0x520287[_0xcb1315(0x1ff)]?.[_0xcb1315(0x1e6)]();return _0x59f33f||_0x4648bc;}function withSyncedDisplayName(_0x1033ef,_0xea8cad){const _0x21ee3a=a138_0x17d0,_0x352f7f=_0x1033ef[_0x21ee3a(0x1f5)](/^(\uFEFF?)---\s*\r?\n([\s\S]*?)\r?\n---(?:\r?\n|$)/);if(!_0x352f7f)return _0x1033ef;const _0x3dcea3=_0x352f7f[0x1]??'',_0x219f80=_0x352f7f[0x2]??'',_0x141b01=parseDocument(_0x219f80);if(_0x141b01['errors'][_0x21ee3a(0x1fa)]>0x0||!isMap(_0x141b01[_0x21ee3a(0x202)]))return _0x1033ef;if(_0xea8cad)_0x141b01['set']('displayName',_0xea8cad);else{if(_0x141b01[_0x21ee3a(0x1f2)](_0x21ee3a(0x209)))_0x141b01[_0x21ee3a(0x215)]('displayName');else return _0x1033ef;}forceBlockCollections(_0x141b01[_0x21ee3a(0x202)]);const _0x352add=_0x141b01['toString']({'lineWidth':0x0})['trimEnd'](),_0x4042a1=_0x1033ef['slice'](_0x352f7f[0x0]['length'])[_0x21ee3a(0x1ee)](/^\r?\n/,'');return _0x3dcea3+_0x21ee3a(0x206)+_0x352add+'\x0a---\x0a\x0a'+_0x4042a1;}function forceBlockCollections(_0x384d4a){if(!isNode(_0x384d4a))return;visit(_0x384d4a,(_0x24020d,_0x5e0cdf)=>{const _0x1b8f03=a138_0x17d0;isCollection(_0x5e0cdf)&&(_0x5e0cdf[_0x1b8f03(0x1fb)]=![]);});}function ensurePulledFilesCanBeOverwritten(_0x22a05f,_0x37a123,_0x395be8,_0x229332){const _0x3a0f40=a138_0x17d0;if(_0x229332||!existsSync(_0x37a123))return;const _0xb41989=readMetadataIfPresent(_0x37a123);if(!_0xb41989)return;const _0x17cc58=_0xb41989['fileHashes']&&Object[_0x3a0f40(0x1fd)](_0xb41989[_0x3a0f40(0x1e5)])['length']>0x0?_0xb41989['fileHashes']:undefined;if(_0x17cc58)for(const [_0x3ab654,_0x3a9a5d]of Object[_0x3a0f40(0x20b)](_0x17cc58)){const _0x277a29=resolveManagedFilePath(_0x22a05f,_0x3ab654);if(!existsSync(_0x277a29))throw CliErrors['validation']('Local\x20Skill\x20files\x20have\x20unpushed\x20edits:\x20'+_0x22a05f,_0x3a0f40(0x21a)+_0x3ab654);const _0x4c6bbc=lstatSync(_0x277a29);if(!_0x4c6bbc[_0x3a0f40(0x1e4)]())throw CliErrors[_0x3a0f40(0x219)](_0x3a0f40(0x1f7)+_0x22a05f,_0x3a0f40(0x204)+_0x3ab654);const _0x4ecbf8=bufferSha256(readFileSync(_0x277a29));if(_0x4ecbf8!==_0x3a9a5d)throw CliErrors[_0x3a0f40(0x219)](_0x3a0f40(0x1f7)+_0x22a05f+'.\x20Changed\x20file:\x20'+_0x3ab654,'Push\x20the\x20directory\x20first,\x20then\x20rerun\x20skill\x20install.\x20Changed\x20file:\x20'+_0x3ab654);}else{const _0x3210d3=resolve(_0x22a05f,SKILL_FILE);if(existsSync(_0x3210d3)&&_0xb41989[_0x3a0f40(0x1f1)]){const _0x15ef2f=contentHash(readFileSync(_0x3210d3,_0x3a0f40(0x1f3)));if(_0x15ef2f!==_0xb41989['contentHash'])throw CliErrors[_0x3a0f40(0x219)]('Local\x20SKILL.md\x20has\x20unpushed\x20edits:\x20'+_0x3210d3,_0x3a0f40(0x217));}}for(const _0x32be87 of normalizeLocalFiles(_0x395be8)){if(_0x17cc58?.[_0x32be87[_0x3a0f40(0x1f0)]])continue;if(!_0x17cc58&&_0x32be87[_0x3a0f40(0x1f0)]===SKILL_FILE)continue;const _0x178f21=resolveManagedFilePath(_0x22a05f,_0x32be87[_0x3a0f40(0x1f0)]);if(!existsSync(_0x178f21))continue;const _0x4042f4=lstatSync(_0x178f21);if(!_0x4042f4[_0x3a0f40(0x1e4)]())throw CliErrors[_0x3a0f40(0x219)](_0x3a0f40(0x1f7)+_0x22a05f,'Remote\x20Skill\x20would\x20overwrite\x20a\x20local\x20non-file\x20path:\x20'+_0x32be87[_0x3a0f40(0x1f0)]);const _0x19fbd6=bufferSha256(readFileSync(_0x178f21));if(_0x19fbd6!==fileHash(_0x32be87))throw CliErrors['validation']('Local\x20Skill\x20files\x20have\x20unpushed\x20edits:\x20'+_0x22a05f,_0x3a0f40(0x1f8)+_0x32be87[_0x3a0f40(0x1f0)]);}}function materializeFiles(_0x2a8c64,_0x28b291){const _0x42be37=a138_0x17d0;for(const _0x55d599 of normalizeLocalFiles(_0x28b291)){const _0xf19e24=resolveManagedFilePath(_0x2a8c64,_0x55d599[_0x42be37(0x1f0)]);mkdirSync(dirname(_0xf19e24),{'recursive':!![],'mode':0x1c0}),writeBytesAtomic(_0xf19e24,fileContent(_0x55d599),0x180);}}function removeStaleManagedFiles(_0x42ad88,_0x50185f,_0x51a120){const _0x1a2767=a138_0x17d0;if(!_0x50185f)return;const _0x5b2d09=new Set(normalizeLocalFiles(_0x51a120)[_0x1a2767(0x216)](_0x423403=>_0x423403[_0x1a2767(0x1f0)]));for(const _0x47fee4 of Object[_0x1a2767(0x1fd)](_0x50185f)){if(_0x5b2d09[_0x1a2767(0x1f2)](_0x47fee4))continue;const _0x4fa37c=resolveManagedFilePath(_0x42ad88,_0x47fee4);existsSync(_0x4fa37c)&&lstatSync(_0x4fa37c)[_0x1a2767(0x1e4)]()&&rmSync(_0x4fa37c,{'force':!![]});}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4ba630,_0x8c7eb9){const _0x26bee0=a139_0x31d6,_0x4b10a1=_0x4ba630();while(!![]){try{const _0x3d2096=parseInt(_0x26bee0(0x15f))/0x1+parseInt(_0x26bee0(0x17a))/0x2+-parseInt(_0x26bee0(0x155))/0x3+parseInt(_0x26bee0(0x168))/0x4*(parseInt(_0x26bee0(0x15e))/0x5)+parseInt(_0x26bee0(0x15d))/0x6*(-parseInt(_0x26bee0(0x179))/0x7)+parseInt(_0x26bee0(0x15a))/0x8*(parseInt(_0x26bee0(0x16e))/0x9)+parseInt(_0x26bee0(0x175))/0xa*(-parseInt(_0x26bee0(0x16f))/0xb);if(_0x3d2096===_0x8c7eb9)break;else _0x4b10a1['push'](_0x4b10a1['shift']());}catch(_0x1102ad){_0x4b10a1['push'](_0x4b10a1['shift']());}}}(a139_0x41a5,0x6748b));import{existsSync,readFileSync}from'node:fs';import{CliErrors}from'../../errors.js';function a139_0x31d6(_0x170722,_0xdb1f75){_0x170722=_0x170722-0x155;const _0x41a5cc=a139_0x41a5();let _0x31d63e=_0x41a5cc[_0x170722];return _0x31d63e;}import{METADATA_FILE}from'./constants.js';import{bufferSha256,fileHash,fileTreeHash}from'./hashing.js';import{fileContent,normalizeLocalFiles}from'./local-files.js';import{buildSkillPackage,localFilesToManifestFiles}from'./zip-package.js';export function buildMetadata(_0x5cca6f,_0x5f3b06,_0x5aaf72,_0x4f86c5,_0x4dcae3,_0x17e231,_0x2c792b){const _0x377d9c=a139_0x31d6,_0x54924b=_0x17e231?normalizeLocalFiles(_0x17e231):[],_0x28a523=!_0x2c792b&&_0x54924b[_0x377d9c(0x174)]>0x0?buildSkillPackage(_0x54924b):undefined,_0x109eff=_0x2c792b?bufferSha256(_0x2c792b):_0x28a523?.[_0x377d9c(0x166)]['zipSha256'],_0x375d33=_0x2c792b?.[_0x377d9c(0x174)]??_0x28a523?.[_0x377d9c(0x166)][_0x377d9c(0x177)],_0x283b04=_0x54924b[_0x377d9c(0x174)]>0x0?Object['fromEntries'](_0x54924b['map'](_0x3580ab=>[_0x3580ab['path'],fileHash(_0x3580ab)])):undefined;return{'schemaVersion':_0x54924b[_0x377d9c(0x174)]>0x0?0x2:0x1,'id':_0x5cca6f['id'],'appCode':_0x5aaf72,'skillCode':requireSkillCode(_0x5cca6f),'skillName':_0x5cca6f[_0x377d9c(0x16b)],'description':_0x5cca6f['description'],'example':_0x5cca6f[_0x377d9c(0x178)],'scope':_0x5f3b06,'readonly':_0x5f3b06!=='personal'||_0x5cca6f[_0x377d9c(0x162)]===!![],'tenantCode':_0x5cca6f[_0x377d9c(0x176)],'userId':_0x5cca6f[_0x377d9c(0x157)],'version':_0x5cca6f['version'],'status':_0x5cca6f[_0x377d9c(0x172)],'tags':Array[_0x377d9c(0x160)](_0x5cca6f[_0x377d9c(0x165)])?_0x5cca6f[_0x377d9c(0x165)]:[],'hasUpstreamUpdate':_0x5cca6f[_0x377d9c(0x163)],'forkedFromSkillId':_0x5cca6f[_0x377d9c(0x164)],'forkedFromVersion':_0x5cca6f[_0x377d9c(0x167)],'sourceSessionId':_0x5cca6f['sourceSessionId'],'contentHash':_0x4f86c5,'fileHashes':_0x283b04,'treeHash':_0x54924b['length']>0x0?fileTreeHash(localFilesToManifestFiles(_0x54924b)):undefined,'ossPath':remoteManifestOssPath(_0x5cca6f[_0x377d9c(0x171)]),'zipSha256':_0x109eff,'zipSize':_0x375d33,'files':_0x54924b[_0x377d9c(0x174)]>0x0?_0x54924b[_0x377d9c(0x169)](_0x440fe5=>({'path':_0x440fe5[_0x377d9c(0x15c)],'hash':fileHash(_0x440fe5),'size':fileContent(_0x440fe5)[_0x377d9c(0x174)]})):undefined,'pulledAt':_0x4dcae3??new Date()[_0x377d9c(0x16d)]()};}export function requireSkillCode(_0x397e54){const _0x296dce=a139_0x31d6,_0x153740=_0x397e54[_0x296dce(0x16c)]?.[_0x296dce(0x156)]();if(!_0x153740)throw CliErrors[_0x296dce(0x170)](_0x296dce(0x173));return _0x153740;}export function readMetadataIfPresent(_0x5a96e7){const _0x2e73d7=a139_0x31d6;if(!existsSync(_0x5a96e7))return undefined;try{const _0x1dc014=JSON[_0x2e73d7(0x15b)](readFileSync(_0x5a96e7,_0x2e73d7(0x159)));return _0x1dc014;}catch{throw CliErrors[_0x2e73d7(0x170)]('Invalid\x20'+METADATA_FILE+':\x20'+_0x5a96e7);}}function a139_0x41a5(){const _0x27350b=['Runtime\x20Skill\x20is\x20missing\x20skillCode.','length','630GnxmGg','tenantCode','zipSize','example','5577810zACyXy','585750YBvPox','884067RqXEPS','trim','userId','ossPath','utf8','8GxAkrH','parse','path','6xwlGtM','10UnMCvi','397970LkKEpN','isArray','string','readonly','hasUpstreamUpdate','forkedFromSkillId','tags','manifest','forkedFromVersion','1085608DZNLrJ','map','object','skillName','skillCode','toISOString','4109652NJKxMh','30679VUzpdH','validation','files','status'];a139_0x41a5=function(){return _0x27350b;};return a139_0x41a5();}function remoteManifestOssPath(_0x977291){const _0x531d3b=a139_0x31d6;if(!_0x977291||typeof _0x977291!==_0x531d3b(0x16a)||Array[_0x531d3b(0x160)](_0x977291))return undefined;const _0x47ab4b=_0x977291[_0x531d3b(0x158)];return typeof _0x47ab4b===_0x531d3b(0x161)&&_0x47ab4b[_0x531d3b(0x156)]()?_0x47ab4b[_0x531d3b(0x156)]():undefined;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x196022,_0x19b4d5){const _0x1056ab=a140_0x12ca,_0x1b5790=_0x196022();while(!![]){try{const _0x488724=parseInt(_0x1056ab(0xe0))/0x1+-parseInt(_0x1056ab(0xe1))/0x2*(parseInt(_0x1056ab(0xd8))/0x3)+-parseInt(_0x1056ab(0xce))/0x4*(parseInt(_0x1056ab(0xd4))/0x5)+parseInt(_0x1056ab(0xcf))/0x6*(-parseInt(_0x1056ab(0xe9))/0x7)+-parseInt(_0x1056ab(0xda))/0x8+-parseInt(_0x1056ab(0xd0))/0x9*(-parseInt(_0x1056ab(0xd3))/0xa)+parseInt(_0x1056ab(0xdc))/0xb;if(_0x488724===_0x19b4d5)break;else _0x1b5790['push'](_0x1b5790['shift']());}catch(_0x35b698){_0x1b5790['push'](_0x1b5790['shift']());}}}(a140_0x347d,0x416b8));function a140_0x347d(){const _0x2d9d5e=['.agents','1420290TAYPcD','65fTcwXh','skillCode','SKILL_ROOT','homeDirName','6uzKWzZ','CLAUDE_SKILL_ROOT','2848008CUrgem','.workbuddy','11924308sjaFsu','claudeSkillsDir','agentsSkillsDir','includes','87318wpjiRc','217102enJGxH','validation','Unsafe\x20','cache','skills','homeDir','workbuddySkillsDir','cacheRoot','7hlQVzS','71356QmfeXY','3146778PjRnFm','27iwLGCY','appCode'];a140_0x347d=function(){return _0x2d9d5e;};return a140_0x347d();}import{existsSync}from'node:fs';import{homedir}from'node:os';import{resolve}from'node:path';import{fingerprintAccessKey}from'../../commands/app/cache.js';import{PRODUCT_CONFIG,productEnv}from'../../constant/product.js';import{CliErrors}from'../../errors.js';export function resolveSkillSyncPaths(_0x399f44={}){const _0x517978=a140_0x12ca,_0x17e10d=_0x399f44[_0x517978(0xe6)]??homedir(),_0x531e99=resolve(_0x17e10d,PRODUCT_CONFIG[_0x517978(0xd7)],_0x517978(0xe4)),_0xdbcefa=trimmedEnv(_0x517978(0xd6)),_0x55e15f=trimmedEnv(_0x517978(0xd9)),_0x5a91fc=resolve(_0x17e10d,_0x517978(0xdb)),_0x55a411=_0x399f44[_0x517978(0xe7)]??(existsSync(_0x5a91fc)?resolve(_0x5a91fc,_0x517978(0xe5)):undefined);return{'homeDir':_0x17e10d,'cacheRoot':_0x531e99,'managedRoot':resolve(_0x17e10d,PRODUCT_CONFIG['homeDirName']),'agentsSkillsDir':_0x399f44[_0x517978(0xde)]??_0xdbcefa??resolve(_0x17e10d,_0x517978(0xd2),'skills'),'claudeSkillsDir':_0x399f44[_0x517978(0xdd)]??_0x55e15f??resolve(_0x17e10d,'.claude','skills'),'workbuddySkillsDir':_0x55a411};}export function runtimeAgentSkillRoots(_0x1e0bc0){const _0x3bd9a7=a140_0x12ca;return[_0x1e0bc0[_0x3bd9a7(0xde)],_0x1e0bc0[_0x3bd9a7(0xdd)],_0x1e0bc0[_0x3bd9a7(0xe7)]]['filter'](_0x3bda15=>Boolean(_0x3bda15));}export function getRuntimeSkillCacheRoot(_0x2d00f5,_0x109764,_0x1fc72e={}){const _0x1004b0=a140_0x12ca,_0x336703=resolveSkillSyncPaths(_0x1fc72e);return resolve(_0x336703[_0x1004b0(0xe8)],_0x2d00f5,fingerprintAccessKey(_0x109764),'skills');}function a140_0x12ca(_0x1fb05a,_0x6bd572){_0x1fb05a=_0x1fb05a-0xce;const _0x347d14=a140_0x347d();let _0x12ca69=_0x347d14[_0x1fb05a];return _0x12ca69;}export function getRuntimeSkillDir(_0x58e9fc,_0x56105c,_0x77a4e6,_0x3e7cea,_0x8f8abb,_0x5818e6={}){const _0x43ebd9=a140_0x12ca;return resolve(getRuntimeSkillCacheRoot(_0x58e9fc,_0x56105c,_0x5818e6),safePathSegment(_0x77a4e6,_0x43ebd9(0xd1)),_0x3e7cea,safePathSegment(_0x8f8abb,_0x43ebd9(0xd5)));}export function safePathSegment(_0x3975c1,_0x1bd0b4='path\x20segment'){const _0x240c6b=a140_0x12ca;if(!_0x3975c1||_0x3975c1[_0x240c6b(0xdf)]('/')||_0x3975c1['includes']('\x5c')||_0x3975c1[_0x240c6b(0xdf)]('..'))throw CliErrors[_0x240c6b(0xe2)](_0x240c6b(0xe3)+_0x1bd0b4+'\x20for\x20local\x20path:\x20'+_0x3975c1);return _0x3975c1;}function trimmedEnv(_0x321ffd){const _0x2b2b06=productEnv(_0x321ffd)?.['trim']();return _0x2b2b06?_0x2b2b06:undefined;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(_0x3fa481,_0x3601b3){const _0x3df6c4=a141_0x316d,_0x5673da=_0x3fa481();while(!![]){try{const _0x3ecb46=parseInt(_0x3df6c4(0x1d4))/0x1*(parseInt(_0x3df6c4(0x1e3))/0x2)+parseInt(_0x3df6c4(0x1d7))/0x3+-parseInt(_0x3df6c4(0x209))/0x4*(parseInt(_0x3df6c4(0x1e5))/0x5)+parseInt(_0x3df6c4(0x1cf))/0x6*(parseInt(_0x3df6c4(0x1d3))/0x7)+-parseInt(_0x3df6c4(0x1d5))/0x8*(parseInt(_0x3df6c4(0x1dd))/0x9)+parseInt(_0x3df6c4(0x1cc))/0xa+-parseInt(_0x3df6c4(0x1ee))/0xb;if(_0x3ecb46===_0x3601b3)break;else _0x5673da['push'](_0x5673da['shift']());}catch(_0x5cca74){_0x5673da['push'](_0x5673da['shift']());}}}(a141_0x2a08,0xb7bd1));import{existsSync,lstatSync,readFileSync,realpathSync}from'node:fs';import{basename,resolve}from'node:path';import{parse as a141_0x687a9f}from'yaml';import{CliErrors}from'../../errors.js';import{METADATA_FILE,SKILL_FILE}from'./constants.js';import{writeJsonAtomic}from'./fs-utils.js';import{contentHash}from'./hashing.js';import{fileText,normalizeLocalFiles,scanSkillDirectory}from'./local-files.js';import{buildMetadata,readMetadataIfPresent}from'./metadata.js';import{buildSkillPackage,tryNormalizePackageManifest}from'./zip-package.js';export function resolvePushDirectoryIdentity(_0xeadde4,_0x4fb8c6,_0x43b70c={}){const _0x374dbd=a141_0x316d,_0x403fb7=resolvePushDirectoryRoot(_0xeadde4),_0x7ad18c=readPushMetadataIfPresent(resolve(_0x403fb7,METADATA_FILE),{'ignoreInvalidMetadata':_0x43b70c[_0x374dbd(0x1e8)]});if(_0x7ad18c?.[_0x374dbd(0x1f7)]&&_0x7ad18c[_0x374dbd(0x1f7)]!==_0x4fb8c6&&!_0x43b70c[_0x374dbd(0x1fc)]&&!_0x43b70c['ignoreMetadataAppCodeMismatch'])throw CliErrors[_0x374dbd(0x1cb)]('Skill\x20metadata\x20appCode\x20\x22'+_0x7ad18c[_0x374dbd(0x1f7)]+_0x374dbd(0x1e9)+_0x4fb8c6+'\x22.');const _0x21fb0e=resolvePushSkillCode(_0x403fb7,_0x4fb8c6,_0x7ad18c,_0x43b70c);if(!_0x21fb0e)throw CliErrors[_0x374dbd(0x1cb)](_0x374dbd(0x1e4)+SKILL_FILE+',\x20'+METADATA_FILE+_0x374dbd(0x1f3));return{'dir':_0x403fb7,'skillCode':_0x21fb0e,'metadata':_0x7ad18c};}export function readPushDirectory(_0x6c23df,_0x2d6c48,_0x2435cb={}){const _0x4e1b54=a141_0x316d,_0x11b3e1=resolvePushDirectoryIdentity(_0x6c23df,_0x2d6c48,_0x2435cb),_0x4c4956=_0x11b3e1[_0x4e1b54(0x1d8)],_0x557f81=resolve(_0x4c4956,SKILL_FILE);if(!existsSync(_0x557f81)||!lstatSync(_0x557f81)[_0x4e1b54(0x1ff)]())throw CliErrors[_0x4e1b54(0x1cb)]('Missing\x20'+SKILL_FILE+':\x20'+_0x557f81);const _0x5443c5=_0x11b3e1[_0x4e1b54(0x1d9)],_0x29672e=_0x2435cb[_0x4e1b54(0x1eb)]??_0x4e1b54(0x203);if(!_0x2435cb[_0x4e1b54(0x206)]&&_0x5443c5?.['scope']===_0x4e1b54(0x1f1))throw CliErrors[_0x4e1b54(0x1cb)](_0x4e1b54(0x1d1)+METADATA_FILE+'\x20has\x20scope=\x22'+_0x5443c5['scope']+'\x22.');if(!_0x2435cb['ignoreMetadataScope']&&_0x29672e==='personal'&&_0x5443c5?.[_0x4e1b54(0x1de)]&&_0x5443c5[_0x4e1b54(0x1de)]!==_0x4e1b54(0x203))throw CliErrors[_0x4e1b54(0x1cb)](_0x4e1b54(0x201)+METADATA_FILE+_0x4e1b54(0x1e0)+_0x5443c5[_0x4e1b54(0x1de)]+'\x22.',_0x4e1b54(0x1ce)+_0x4c4956+_0x4e1b54(0x1d2));const _0x235b4e=scanSkillDirectory(_0x4c4956,{'excludedFilePaths':_0x2435cb[_0x4e1b54(0x1fb)]}),_0x1f0264=buildSkillPackage(_0x235b4e),_0x3edbf0=readFileSync(_0x557f81,_0x4e1b54(0x1da)),_0x223fb6=_0x11b3e1[_0x4e1b54(0x1db)],_0x166ee0=_0x2435cb['ignoreMetadataForPayload']?undefined:_0x5443c5,_0x4890b4=readSkillDisplayName(_0x3edbf0);return{'skillCode':_0x223fb6,'metadata':_0x5443c5,'frontmatterDisplayName':_0x4890b4,'input':{'skillCode':_0x223fb6,'skillName':_0x4890b4??_0x166ee0?.[_0x4e1b54(0x205)],'description':_0x166ee0?.['description'],'content':_0x3edbf0,'files':_0x1f0264[_0x4e1b54(0x1ea)],'packageBase64':_0x1f0264[_0x4e1b54(0x1f5)],'tags':_0x166ee0?.[_0x4e1b54(0x1f6)],'version':_0x166ee0?.['version'],'sourceSessionId':_0x166ee0?.[_0x4e1b54(0x1f9)]}};}export function refreshPushDirectoryMetadataFromRemote(_0x486c2e,_0x429acf,_0x4ff22e,_0x3036b0={}){const _0x27f9d7=a141_0x316d,_0x49659c=resolvePushDirectoryRoot(_0x486c2e),_0xfd3270=readPushMetadataIfPresent(resolve(_0x49659c,METADATA_FILE),{'ignoreInvalidMetadata':!![]}),_0x4072b0=requireRemoteScope(_0x429acf),_0x2700a4=readLocalSkillContent(_0x49659c),_0x488fe5={..._0x429acf,'appCode':_0x429acf[_0x27f9d7(0x1f7)]??_0x4ff22e,'skillName':_0x429acf['skillName']??_0xfd3270?.[_0x27f9d7(0x205)],'description':_0x429acf[_0x27f9d7(0x1e6)]??_0xfd3270?.['description'],'example':_0x429acf[_0x27f9d7(0x1f0)]??_0xfd3270?.[_0x27f9d7(0x1f0)],'tags':Array['isArray'](_0x429acf['tags'])?_0x429acf[_0x27f9d7(0x1f6)]:_0xfd3270?.[_0x27f9d7(0x1f6)],'sourceSessionId':_0x429acf[_0x27f9d7(0x1f9)]??_0xfd3270?.[_0x27f9d7(0x1f9)],'content':_0x429acf[_0x27f9d7(0x1d0)]??_0x2700a4},_0x32d5f0=buildMetadata(_0x488fe5,_0x4072b0,_0x4ff22e,contentHash(_0x2700a4),_0x3036b0[_0x27f9d7(0x1ef)]);writeJsonAtomic(resolve(_0x49659c,METADATA_FILE),_0x32d5f0);}export function recordPushedRuntimeSkill(_0x4d0399,_0x1107ef,_0x42e93e,_0x1ba7ef={}){const _0x2d831b=a141_0x316d,_0x3bd57e=resolvePushDirectoryRoot(_0x4d0399),_0x12e24e=scanSkillDirectory(_0x3bd57e),_0x5c375c=_0x12e24e['find'](_0x10c3a4=>_0x10c3a4['path']===SKILL_FILE),_0x5146cc=_0x5c375c?fileText(_0x5c375c):'',_0x155514=tryNormalizePackageManifest(_0x1107ef[_0x2d831b(0x1ed)]),_0x170826={..._0x1107ef,'content':_0x1107ef[_0x2d831b(0x1d0)]??_0x5146cc,'files':_0x155514},_0x469574=_0x155514?normalizeLocalFiles(_0x12e24e)[_0x2d831b(0x1ca)](_0x440775=>_0x155514[_0x2d831b(0x1ed)]['some'](_0x1b7ad5=>_0x1b7ad5[_0x2d831b(0x1d6)]===_0x440775[_0x2d831b(0x1d6)])):undefined,_0x319ae9=buildMetadata(_0x170826,_0x1ba7ef[_0x2d831b(0x1de)]??_0x2d831b(0x203),_0x42e93e,contentHash(_0x170826[_0x2d831b(0x1d0)]??''),_0x1ba7ef[_0x2d831b(0x1df)],_0x469574);writeJsonAtomic(resolve(_0x3bd57e,METADATA_FILE),_0x319ae9);}export function deriveSkillCodeFromDirectory(_0x3b8e89,_0x506c52){const _0xdd49c8=a141_0x316d,_0x540de0=basename(resolve(_0x3b8e89)),_0x4cafa7=_0x506c52+'--';return _0x540de0[_0xdd49c8(0x1fe)](_0x4cafa7)?_0x540de0[_0xdd49c8(0x1c8)](_0x4cafa7['length']):_0x540de0;}function resolvePushSkillCode(_0x44137a,_0x32be26,_0x37fc62,_0x4980dd){const _0xf815d5=a141_0x316d,_0x8a15f8=deriveSkillCodeFromSkillFile(_0x44137a)||deriveSkillCodeFromDirectory(_0x44137a,_0x32be26);if(_0x4980dd[_0xf815d5(0x1e1)])return _0x8a15f8;return _0x37fc62?.[_0xf815d5(0x1db)]?.[_0xf815d5(0x1cd)]()||_0x8a15f8;}function deriveSkillCodeFromSkillFile(_0x805976){const _0x2eba57=a141_0x316d,_0x32c6fe=resolve(_0x805976,SKILL_FILE);if(!existsSync(_0x32c6fe)||!lstatSync(_0x32c6fe)[_0x2eba57(0x1ff)]())return undefined;const _0x112c2a=readFileSync(_0x32c6fe,'utf8'),_0x54518d=_0x112c2a[_0x2eba57(0x1dc)](/^---\r?\n([\s\S]*?)\r?\n---(?:\r?\n|$)/);if(!_0x54518d)return undefined;const _0xc71e26=parseFrontmatterObject(_0x54518d[0x1]??''),_0x170edb=scalarToString(_0xc71e26?.[_0x2eba57(0x208)]);return _0x170edb?slugifySkillName(_0x170edb):undefined;}function readSkillDisplayName(_0x4990ee){const _0x1d6011=a141_0x316d,_0x51b829=_0x4990ee[_0x1d6011(0x1dc)](/^---\r?\n([\s\S]*?)\r?\n---(?:\r?\n|$)/);if(!_0x51b829)return undefined;const _0x1c91a1=parseFrontmatterObject(_0x51b829[0x1]??'');return scalarToString(_0x1c91a1?.[_0x1d6011(0x1f8)]);}function a141_0x316d(_0xadbd2a,_0xec0f81){_0xadbd2a=_0xadbd2a-0x1c7;const _0x2a08b1=a141_0x2a08();let _0x316d67=_0x2a08b1[_0xadbd2a];return _0x316d67;}function slugifySkillName(_0x2f8a05){const _0x4d4464=a141_0x316d,_0x42e7a1=_0x2f8a05['trim']()[_0x4d4464(0x1ec)]()[_0x4d4464(0x1c9)](/[^\p{L}\p{N}\p{So}]+/gu,'-')[_0x4d4464(0x1c9)](/^-+/,'')[_0x4d4464(0x1c9)](/-+$/,'')[_0x4d4464(0x1c9)](/-{2,}/g,'-');if(!_0x42e7a1)throw CliErrors[_0x4d4464(0x1cb)](_0x4d4464(0x207)+SKILL_FILE+_0x4d4464(0x1c7));return _0x42e7a1;}function parseFrontmatterObject(_0x3ebd60){const _0xf10de8=a141_0x316d;try{const _0x11c853=a141_0x687a9f(_0x3ebd60);return _0x11c853&&typeof _0x11c853==='object'&&!Array[_0xf10de8(0x204)](_0x11c853)?_0x11c853:undefined;}catch{return undefined;}}function scalarToString(_0x130698){const _0x5961ff=a141_0x316d;if(typeof _0x130698===_0x5961ff(0x1e2))return _0x130698[_0x5961ff(0x1cd)]();if(typeof _0x130698==='number'||typeof _0x130698==='boolean')return String(_0x130698);return undefined;}function resolvePushDirectoryRoot(_0x2bc677){const _0x3a4777=a141_0x316d,_0x365fea=resolve(_0x2bc677);if(!existsSync(_0x365fea))throw CliErrors[_0x3a4777(0x1cb)](_0x3a4777(0x1f4)+_0x2bc677);const _0x232e70=lstatSync(_0x365fea);if(_0x232e70[_0x3a4777(0x1e7)]())return _0x365fea;if(_0x232e70[_0x3a4777(0x1fd)]()){const _0x5caeeb=realpathSync(_0x365fea);if(lstatSync(_0x5caeeb)[_0x3a4777(0x1e7)]())return _0x5caeeb;}throw CliErrors[_0x3a4777(0x1cb)](_0x3a4777(0x1f4)+_0x2bc677);}function requireRemoteScope(_0x3e624c){const _0x58bcea=a141_0x316d;if(_0x3e624c[_0x58bcea(0x1de)]==='personal'||_0x3e624c[_0x58bcea(0x1de)]===_0x58bcea(0x200)||_0x3e624c[_0x58bcea(0x1de)]===_0x58bcea(0x1f1))return _0x3e624c['scope'];throw CliErrors[_0x58bcea(0x1cb)](_0x58bcea(0x202)+(_0x3e624c[_0x58bcea(0x1db)]||_0x58bcea(0x1fa))+_0x58bcea(0x1f2)+(_0x3e624c[_0x58bcea(0x1de)]??'unknown')+'\x22.');}function readLocalSkillContent(_0x5cfe02){const _0x318bd4=a141_0x316d,_0x57bcb0=resolve(_0x5cfe02,SKILL_FILE);return existsSync(_0x57bcb0)&&lstatSync(_0x57bcb0)['isFile']()?readFileSync(_0x57bcb0,_0x318bd4(0x1da)):'';}function a141_0x2a08(){const _0x5609c8=['targetScope','toLowerCase','files','16140762gMfEbx','refreshedAt','example','builtin','\x20has\x20unsupported\x20scope\x20\x22',',\x20or\x20directory\x20name.','Skill\x20directory\x20not\x20found:\x20','packageBase64','tags','appCode','displayName','sourceSessionId','(unknown)','excludedFilePaths','allowAppCodeRetarget','isSymbolicLink','startsWith','isFile','company','Only\x20personal\x20Skills\x20can\x20be\x20pushed;\x20','Remote\x20Skill\x20','personal','isArray','skillName','ignoreMetadataScope','Invalid\x20','name','4LbGUsD','\x20name\x20for\x20SkillHub\x20slug\x20generation.','slice','replace','filter','validation','765530pGabcS','trim','Use\x20lovrabet\x20skill\x20push\x20--scope\x20company\x20--dir\x20','3010908KXPbAu','content','Builtin\x20Skills\x20cannot\x20be\x20pushed;\x20','\x20to\x20submit\x20company\x20Skills\x20for\x20review.','14KsiWQn','1223153XdVOgD','32kTCvvA','path','3559029SNQdvs','dir','metadata','utf8','skillCode','match','67923hKaZSh','scope','pushedAt','\x20has\x20scope=\x22','ignoreMetadataSkillCode','string','2EXJyMD','Unable\x20to\x20resolve\x20skillCode\x20from\x20','6197810xRJDPQ','description','isDirectory','ignoreInvalidMetadata','\x22\x20does\x20not\x20match\x20current\x20appCode\x20\x22','manifest'];a141_0x2a08=function(){return _0x5609c8;};return a141_0x2a08();}function readPushMetadataIfPresent(_0xc0a4ce,_0x43b39d={}){const _0xc2f04d=a141_0x316d;try{return readMetadataIfPresent(_0xc0a4ce);}catch(_0x1c48ea){if(_0x43b39d[_0xc2f04d(0x1e8)])return undefined;throw _0x1c48ea;}}
|
|
1
|
+
(function(_0x3d5de8,_0x5a2a66){const _0x2191f5=a141_0x1619,_0x56bce9=_0x3d5de8();while(!![]){try{const _0x581919=-parseInt(_0x2191f5(0xc1))/0x1+parseInt(_0x2191f5(0xbf))/0x2*(parseInt(_0x2191f5(0x93))/0x3)+parseInt(_0x2191f5(0x94))/0x4+-parseInt(_0x2191f5(0xa5))/0x5*(-parseInt(_0x2191f5(0x9f))/0x6)+parseInt(_0x2191f5(0x91))/0x7+parseInt(_0x2191f5(0x98))/0x8*(-parseInt(_0x2191f5(0xb2))/0x9)+-parseInt(_0x2191f5(0xca))/0xa;if(_0x581919===_0x5a2a66)break;else _0x56bce9['push'](_0x56bce9['shift']());}catch(_0x578526){_0x56bce9['push'](_0x56bce9['shift']());}}}(a141_0x14eb,0xb6f8c));import{existsSync,lstatSync,readFileSync,realpathSync}from'node:fs';import{basename,resolve}from'node:path';import{parse as a141_0x4a2ac6}from'yaml';import{CliErrors}from'../../errors.js';import{METADATA_FILE,SKILL_FILE}from'./constants.js';function a141_0x14eb(){const _0xfc5b57=['8pmATKa','name','description','files','toLowerCase','company','Skill\x20directory\x20not\x20found:\x20','202086GdQIKd','Skill\x20metadata\x20appCode\x20\x22','utf8','scope','targetScope','displayName','215GVATTv','Use\x20lovrabet\x20skill\x20push\x20--scope\x20company\x20--dir\x20','\x20has\x20unsupported\x20scope\x20\x22','startsWith','tags','string','skillName','find','metadata','sourceSessionId','number','Only\x20personal\x20Skills\x20can\x20be\x20pushed;\x20','version','3268089FLqhpV','object','dir',',\x20or\x20directory\x20name.','\x22\x20does\x20not\x20match\x20current\x20appCode\x20\x22','example','match','ignoreMetadataForPayload','builtin','manifest','unknown','ignoreMetadataAppCodeMismatch','replace','409924AWZBih','\x20name\x20for\x20SkillHub\x20slug\x20generation.','1021467lrHatP','trim','some','refreshedAt','isDirectory','Builtin\x20Skills\x20cannot\x20be\x20pushed;\x20','validation','Remote\x20Skill\x20','isFile','3813870AmiTsc','ignoreInvalidMetadata','appCode','path','filter','packageBase64','\x20to\x20submit\x20company\x20Skills\x20for\x20review.','personal','Invalid\x20','pushedAt','238483DqkWgj','excludedFilePaths','6ZbcByv','2492604tTNQeF','skillCode','\x20has\x20scope=\x22','content'];a141_0x14eb=function(){return _0xfc5b57;};return a141_0x14eb();}import{writeJsonAtomic}from'./fs-utils.js';import{contentHash}from'./hashing.js';import{fileText,normalizeLocalFiles,scanSkillDirectory}from'./local-files.js';import{buildMetadata,readMetadataIfPresent}from'./metadata.js';function a141_0x1619(_0x58423b,_0x588f89){_0x58423b=_0x58423b-0x8b;const _0x14eb59=a141_0x14eb();let _0x1619f4=_0x14eb59[_0x58423b];return _0x1619f4;}import{buildSkillPackage,tryNormalizePackageManifest}from'./zip-package.js';export function resolvePushDirectoryIdentity(_0x50fb5a,_0x553cb4,_0x3b34ac={}){const _0xd9d34a=a141_0x1619,_0x845956=resolvePushDirectoryRoot(_0x50fb5a),_0x56d3de=readPushMetadataIfPresent(resolve(_0x845956,METADATA_FILE),{'ignoreInvalidMetadata':_0x3b34ac[_0xd9d34a(0xcb)]});if(_0x56d3de?.[_0xd9d34a(0xcc)]&&_0x56d3de[_0xd9d34a(0xcc)]!==_0x553cb4&&!_0x3b34ac['allowAppCodeRetarget']&&!_0x3b34ac[_0xd9d34a(0xbd)])throw CliErrors['validation'](_0xd9d34a(0xa0)+_0x56d3de[_0xd9d34a(0xcc)]+_0xd9d34a(0xb6)+_0x553cb4+'\x22.');const _0x1b4f30=resolvePushSkillCode(_0x845956,_0x553cb4,_0x56d3de,_0x3b34ac);if(!_0x1b4f30)throw CliErrors[_0xd9d34a(0xc7)]('Unable\x20to\x20resolve\x20skillCode\x20from\x20'+SKILL_FILE+',\x20'+METADATA_FILE+_0xd9d34a(0xb5));return{'dir':_0x845956,'skillCode':_0x1b4f30,'metadata':_0x56d3de};}export function readPushDirectory(_0x2c9471,_0x5b9048,_0x4f010e={}){const _0x18cb76=a141_0x1619,_0x1a6b73=resolvePushDirectoryIdentity(_0x2c9471,_0x5b9048,_0x4f010e),_0x1cb903=_0x1a6b73[_0x18cb76(0xb4)],_0x30ea3d=resolve(_0x1cb903,SKILL_FILE);if(!existsSync(_0x30ea3d)||!lstatSync(_0x30ea3d)['isFile']())throw CliErrors[_0x18cb76(0xc7)]('Missing\x20'+SKILL_FILE+':\x20'+_0x30ea3d);const _0x588561=_0x1a6b73[_0x18cb76(0xad)],_0x37af1d=_0x4f010e[_0x18cb76(0xa3)]??_0x18cb76(0x8e);if(!_0x4f010e['ignoreMetadataScope']&&_0x588561?.[_0x18cb76(0xa2)]===_0x18cb76(0xba))throw CliErrors[_0x18cb76(0xc7)](_0x18cb76(0xc6)+METADATA_FILE+_0x18cb76(0x96)+_0x588561[_0x18cb76(0xa2)]+'\x22.');if(!_0x4f010e['ignoreMetadataScope']&&_0x37af1d===_0x18cb76(0x8e)&&_0x588561?.[_0x18cb76(0xa2)]&&_0x588561['scope']!==_0x18cb76(0x8e))throw CliErrors['validation'](_0x18cb76(0xb0)+METADATA_FILE+_0x18cb76(0x96)+_0x588561[_0x18cb76(0xa2)]+'\x22.',_0x18cb76(0xa6)+_0x1cb903+_0x18cb76(0x8d));const _0x141cd4=scanSkillDirectory(_0x1cb903,{'excludedFilePaths':_0x4f010e[_0x18cb76(0x92)]}),_0x32e3ee=buildSkillPackage(_0x141cd4),_0x4a39d2=readFileSync(_0x30ea3d,_0x18cb76(0xa1)),_0x2d4c2f=_0x1a6b73[_0x18cb76(0x95)],_0x253fef=_0x4f010e[_0x18cb76(0xb9)]?undefined:_0x588561,_0x186d0e=readSkillDisplayName(_0x4a39d2);return{'skillCode':_0x2d4c2f,'metadata':_0x588561,'frontmatterDisplayName':_0x186d0e,'input':{'skillCode':_0x2d4c2f,'skillName':_0x186d0e??_0x253fef?.[_0x18cb76(0xab)],'description':_0x253fef?.[_0x18cb76(0x9a)],'content':_0x4a39d2,'files':_0x32e3ee[_0x18cb76(0xbb)],'packageBase64':_0x32e3ee[_0x18cb76(0x8c)],'tags':_0x253fef?.['tags'],'version':_0x253fef?.[_0x18cb76(0xb1)],'sourceSessionId':_0x253fef?.[_0x18cb76(0xae)]}};}export function refreshPushDirectoryMetadataFromRemote(_0x30b4f4,_0x34e4ce,_0x438ad9,_0x369c3c={}){const _0x451c47=a141_0x1619,_0x126f26=resolvePushDirectoryRoot(_0x30b4f4),_0x41a71c=readPushMetadataIfPresent(resolve(_0x126f26,METADATA_FILE),{'ignoreInvalidMetadata':!![]}),_0x49c4b2=requireRemoteScope(_0x34e4ce),_0x52763c=readLocalSkillContent(_0x126f26),_0x14c31c={..._0x34e4ce,'appCode':_0x34e4ce[_0x451c47(0xcc)]??_0x438ad9,'skillName':_0x34e4ce['skillName']??_0x41a71c?.[_0x451c47(0xab)],'description':_0x34e4ce[_0x451c47(0x9a)]??_0x41a71c?.['description'],'example':_0x34e4ce['example']??_0x41a71c?.[_0x451c47(0xb7)],'tags':Array['isArray'](_0x34e4ce[_0x451c47(0xa9)])?_0x34e4ce['tags']:_0x41a71c?.[_0x451c47(0xa9)],'sourceSessionId':_0x34e4ce[_0x451c47(0xae)]??_0x41a71c?.[_0x451c47(0xae)],'content':_0x34e4ce['content']??_0x52763c},_0x74e1a8=buildMetadata(_0x14c31c,_0x49c4b2,_0x438ad9,contentHash(_0x52763c),_0x369c3c[_0x451c47(0xc4)]);writeJsonAtomic(resolve(_0x126f26,METADATA_FILE),_0x74e1a8);}export function recordPushedRuntimeSkill(_0x28e5ee,_0x58d2e6,_0x4bdc3b,_0x2b74d0={}){const _0xe15ef9=a141_0x1619,_0xdd793d=resolvePushDirectoryRoot(_0x28e5ee),_0x57861b=scanSkillDirectory(_0xdd793d),_0x11a93e=_0x57861b[_0xe15ef9(0xac)](_0x5731ab=>_0x5731ab[_0xe15ef9(0xcd)]===SKILL_FILE),_0x20c96e=_0x11a93e?fileText(_0x11a93e):'',_0x301b9a=tryNormalizePackageManifest(_0x58d2e6['files']),_0x5ee25f={..._0x58d2e6,'content':_0x58d2e6[_0xe15ef9(0x97)]??_0x20c96e,'files':_0x301b9a},_0x3f3e7b=_0x301b9a?normalizeLocalFiles(_0x57861b)[_0xe15ef9(0x8b)](_0x305bae=>_0x301b9a[_0xe15ef9(0x9b)][_0xe15ef9(0xc3)](_0x12e174=>_0x12e174[_0xe15ef9(0xcd)]===_0x305bae[_0xe15ef9(0xcd)])):undefined,_0x3a5341=buildMetadata(_0x5ee25f,_0x2b74d0[_0xe15ef9(0xa2)]??'personal',_0x4bdc3b,contentHash(_0x5ee25f['content']??''),_0x2b74d0[_0xe15ef9(0x90)],_0x3f3e7b);writeJsonAtomic(resolve(_0xdd793d,METADATA_FILE),_0x3a5341);}export function deriveSkillCodeFromDirectory(_0x29a90c,_0x4784e5){const _0x1ee239=a141_0x1619,_0x55a8e5=basename(resolve(_0x29a90c)),_0x261c66=_0x4784e5+'--';return _0x55a8e5[_0x1ee239(0xa8)](_0x261c66)?_0x55a8e5['slice'](_0x261c66['length']):_0x55a8e5;}function resolvePushSkillCode(_0x331d36,_0x812402,_0x239207,_0x57e7a6){const _0x2ee7a9=a141_0x1619,_0x478b19=deriveSkillCodeFromSkillFile(_0x331d36)||deriveSkillCodeFromDirectory(_0x331d36,_0x812402);if(_0x57e7a6['ignoreMetadataSkillCode'])return _0x478b19;return _0x239207?.[_0x2ee7a9(0x95)]?.[_0x2ee7a9(0xc2)]()||_0x478b19;}function deriveSkillCodeFromSkillFile(_0x3d48bd){const _0xb8cd97=a141_0x1619,_0x367510=resolve(_0x3d48bd,SKILL_FILE);if(!existsSync(_0x367510)||!lstatSync(_0x367510)[_0xb8cd97(0xc9)]())return undefined;const _0x2ef97f=readFileSync(_0x367510,_0xb8cd97(0xa1)),_0x4f688a=_0x2ef97f['match'](/^---\r?\n([\s\S]*?)\r?\n---(?:\r?\n|$)/);if(!_0x4f688a)return undefined;const _0x516550=parseFrontmatterObject(_0x4f688a[0x1]??''),_0x523f47=scalarToString(_0x516550?.[_0xb8cd97(0x99)]);return _0x523f47?slugifySkillName(_0x523f47):undefined;}function readSkillDisplayName(_0x5c5748){const _0x5a98ad=a141_0x1619,_0x2e8260=_0x5c5748[_0x5a98ad(0xb8)](/^---\r?\n([\s\S]*?)\r?\n---(?:\r?\n|$)/);if(!_0x2e8260)return undefined;const _0x79a6c3=parseFrontmatterObject(_0x2e8260[0x1]??'');return scalarToString(_0x79a6c3?.[_0x5a98ad(0xa4)]);}function slugifySkillName(_0x188347){const _0x23c79a=a141_0x1619,_0x498771=_0x188347['trim']()[_0x23c79a(0x9c)]()[_0x23c79a(0xbe)](/[^\p{L}\p{N}\p{So}]+/gu,'-')['replace'](/^-+/,'')[_0x23c79a(0xbe)](/-+$/,'')['replace'](/-{2,}/g,'-');if(!_0x498771)throw CliErrors['validation'](_0x23c79a(0x8f)+SKILL_FILE+_0x23c79a(0xc0));return _0x498771;}function parseFrontmatterObject(_0x58a2a9){const _0x1130d7=a141_0x1619;try{const _0x20c998=a141_0x4a2ac6(_0x58a2a9);return _0x20c998&&typeof _0x20c998===_0x1130d7(0xb3)&&!Array['isArray'](_0x20c998)?_0x20c998:undefined;}catch{return undefined;}}function scalarToString(_0x463345){const _0x2d0ce6=a141_0x1619;if(typeof _0x463345===_0x2d0ce6(0xaa))return _0x463345[_0x2d0ce6(0xc2)]();if(typeof _0x463345===_0x2d0ce6(0xaf)||typeof _0x463345==='boolean')return String(_0x463345);return undefined;}function resolvePushDirectoryRoot(_0x3a908b){const _0x4d6e36=a141_0x1619,_0x3aff8e=resolve(_0x3a908b);if(!existsSync(_0x3aff8e))throw CliErrors[_0x4d6e36(0xc7)]('Skill\x20directory\x20not\x20found:\x20'+_0x3a908b);const _0x47bf23=lstatSync(_0x3aff8e);if(_0x47bf23[_0x4d6e36(0xc5)]())return _0x3aff8e;if(_0x47bf23['isSymbolicLink']()){const _0x20a1a8=realpathSync(_0x3aff8e);if(lstatSync(_0x20a1a8)[_0x4d6e36(0xc5)]())return _0x20a1a8;}throw CliErrors['validation'](_0x4d6e36(0x9e)+_0x3a908b);}function requireRemoteScope(_0x48b507){const _0x1b3a40=a141_0x1619;if(_0x48b507[_0x1b3a40(0xa2)]===_0x1b3a40(0x8e)||_0x48b507['scope']===_0x1b3a40(0x9d)||_0x48b507[_0x1b3a40(0xa2)]===_0x1b3a40(0xba))return _0x48b507['scope'];throw CliErrors['validation'](_0x1b3a40(0xc8)+(_0x48b507[_0x1b3a40(0x95)]||'(unknown)')+_0x1b3a40(0xa7)+(_0x48b507['scope']??_0x1b3a40(0xbc))+'\x22.');}function readLocalSkillContent(_0x281de2){const _0x596de7=a141_0x1619,_0xcaa994=resolve(_0x281de2,SKILL_FILE);return existsSync(_0xcaa994)&&lstatSync(_0xcaa994)[_0x596de7(0xc9)]()?readFileSync(_0xcaa994,_0x596de7(0xa1)):'';}function readPushMetadataIfPresent(_0x377287,_0xa9e825={}){try{return readMetadataIfPresent(_0x377287);}catch(_0x33fcd7){if(_0xa9e825['ignoreInvalidMetadata'])return undefined;throw _0x33fcd7;}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a142_0xc27b(){const _0x511a38=['7833kbgBIY','388288hQpOVI','10GqxKsx','384xDImCa','includes','company','15705XECBLN','88383hhCoPB','1inoSJz','637162MgrQvD','validation','1456WTPIlG','5237111iMmUMC','personal','length','1428905FRpnqY','push'];a142_0xc27b=function(){return _0x511a38;};return a142_0xc27b();}(function(_0x4ed96,_0x13071e){const _0x594681=a142_0x1ed4,_0x3dc10f=_0x4ed96();while(!![]){try{const _0x37108e=parseInt(_0x594681(0x188))/0x1*(-parseInt(_0x594681(0x189))/0x2)+parseInt(_0x594681(0x187))/0x3+parseInt(_0x594681(0x181))/0x4+-parseInt(_0x594681(0x17e))/0x5+parseInt(_0x594681(0x183))/0x6*(-parseInt(_0x594681(0x180))/0x7)+parseInt(_0x594681(0x18b))/0x8*(parseInt(_0x594681(0x186))/0x9)+-parseInt(_0x594681(0x182))/0xa*(-parseInt(_0x594681(0x18c))/0xb);if(_0x37108e===_0x13071e)break;else _0x3dc10f['push'](_0x3dc10f['shift']());}catch(_0x4e648f){_0x3dc10f['push'](_0x3dc10f['shift']());}}}(a142_0xc27b,0x3ba16));import{CliErrors}from'../../errors.js';function a142_0x1ed4(_0xc6b89a,_0x81d09f){_0xc6b89a=_0xc6b89a-0x17d;const _0xc27b03=a142_0xc27b();let _0x1ed4c4=_0xc27b03[_0xc6b89a];return _0x1ed4c4;}export function normalizeRuntimeSkillScopes(_0x572518){const _0x169666=a142_0x1ed4,_0x2531f3=_0x572518&&_0x572518[_0x169666(0x17d)]>0x0?_0x572518:[_0x169666(0x18d),'company','builtin'],_0x4f3f60=[];for(const _0x300310 of _0x2531f3){if(!isRuntimeSkillScope(_0x300310))throw CliErrors[_0x169666(0x18a)]('Unsupported\x20runtime\x20Skill\x20scope:\x20'+_0x300310);!_0x4f3f60[_0x169666(0x184)](_0x300310)&&_0x4f3f60[_0x169666(0x17f)](_0x300310);}return _0x4f3f60;}export function isRuntimeSkillScope(_0x5eb1f2){const _0xb86228=a142_0x1ed4;return _0x5eb1f2===_0xb86228(0x18d)||_0x5eb1f2===_0xb86228(0x185)||_0x5eb1f2==='builtin';}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a144_0x5b00ff=a144_0x300f;(function(_0xd09fed,_0x6c73e0){const _0x3176d7=a144_0x300f,_0x6b82d=_0xd09fed();while(!![]){try{const _0x22b629=parseInt(_0x3176d7(0xd2))/0x1*(parseInt(_0x3176d7(0xd6))/0x2)+parseInt(_0x3176d7(0xd3))/0x3*(-parseInt(_0x3176d7(0xc4))/0x4)+-parseInt(_0x3176d7(0xcb))/0x5+parseInt(_0x3176d7(0xc8))/0x6+-parseInt(_0x3176d7(0xc6))/0x7*(parseInt(_0x3176d7(0xc5))/0x8)+-parseInt(_0x3176d7(0xca))/0x9+-parseInt(_0x3176d7(0xc1))/0xa*(-parseInt(_0x3176d7(0xcd))/0xb);if(_0x22b629===_0x6c73e0)break;else _0x6b82d['push'](_0x6b82d['shift']());}catch(_0x82035){_0x6b82d['push'](_0x6b82d['shift']());}}}(a144_0x3aeb,0x91fc5));function a144_0x300f(_0x3320c4,_0x5c3bc9){_0x3320c4=_0x3320c4-0xc1;const _0x3aeb9b=a144_0x3aeb();let _0x300ff7=_0x3aeb9b[_0x3320c4];return _0x300ff7;}import{unzipSync,zipSync}from'fflate';import{CliErrors}from'../../errors.js';import{compareSkillFiles,fileContent,normalizeLocalFiles,normalizeSkillRelativePath}from'./local-files.js';function a144_0x3aeb(){const _0x3b53af=['validation','5108013gdPWFD','4931905wnMoch','Runtime\x20Skill\x20package\x20is\x20not\x20a\x20valid\x20zip\x20file.','40249srtPoX','map','1980-01-01T00:00:00.000Z','Runtime\x20Skill\x20package\x20contains\x20directory\x20entry:\x20','entries','2098sfyfgs','394131MLZLmE','validation_error','name','276TxSJAS','length','path','9470nYZMMt','code','from','32UnAepb','6774584jkSYdG','7BSTIut','object','1770822sbWfEi'];a144_0x3aeb=function(){return _0x3b53af;};return a144_0x3aeb();}const ZIP_MTIME=new Date(a144_0x5b00ff(0xcf));export function createDeterministicZipPackage(_0x24bb1f){const _0x467682=a144_0x5b00ff,_0x663fcf={};for(const _0x33d037 of normalizeLocalFiles(_0x24bb1f)){_0x663fcf[_0x33d037[_0x467682(0xd8)]]=fileContent(_0x33d037);}return Buffer[_0x467682(0xc3)](zipSync(_0x663fcf,{'level':0x0,'mtime':ZIP_MTIME}));}export function parseZipPackage(_0x34decf){const _0x275a51=a144_0x5b00ff;if(_0x34decf[_0x275a51(0xd7)]<0x16)throw CliErrors[_0x275a51(0xc9)](_0x275a51(0xcc));let _0x251e25;try{_0x251e25=unzipSync(_0x34decf,{'filter'(_0x800771){const _0x4f1e59=_0x275a51,_0x58596e=normalizeSkillRelativePath(_0x800771[_0x4f1e59(0xd5)]);if(_0x58596e['endsWith']('/'))throw CliErrors['validation'](_0x4f1e59(0xd0)+_0x58596e);return!![];}});}catch(_0x4225c6){if(isRuntimeSkillValidationError(_0x4225c6))throw _0x4225c6;throw CliErrors[_0x275a51(0xc9)]('Runtime\x20Skill\x20package\x20is\x20not\x20a\x20valid\x20zip\x20file.');}return Object[_0x275a51(0xd1)](_0x251e25)[_0x275a51(0xce)](([_0x35e9be,_0x36df2a])=>({'path':normalizeSkillRelativePath(_0x35e9be),'bytes':Buffer[_0x275a51(0xc3)](_0x36df2a)}))['sort'](compareSkillFiles);}function isRuntimeSkillValidationError(_0xcd6636){const _0x2bd2c3=a144_0x5b00ff;return typeof _0xcd6636===_0x2bd2c3(0xc7)&&_0xcd6636!==null&&_0x2bd2c3(0xc2)in _0xcd6636&&_0xcd6636['code']===_0x2bd2c3(0xd4);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4afd10,_0x515d30){const _0x5355a0=a145_0x3f2a,_0x700822=_0x4afd10();while(!![]){try{const _0x15cca7=parseInt(_0x5355a0(0xd3))/0x1+-parseInt(_0x5355a0(0xc6))/0x2+parseInt(_0x5355a0(0xd6))/0x3*(parseInt(_0x5355a0(0xe8))/0x4)+parseInt(_0x5355a0(0xe5))/0x5*(-parseInt(_0x5355a0(0xcb))/0x6)+-parseInt(_0x5355a0(0xbd))/0x7*(parseInt(_0x5355a0(0xd0))/0x8)+parseInt(_0x5355a0(0xdd))/0x9*(parseInt(_0x5355a0(0xbb))/0xa)+parseInt(_0x5355a0(0xd2))/0xb*(parseInt(_0x5355a0(0xea))/0xc);if(_0x15cca7===_0x515d30)break;else _0x700822['push'](_0x700822['shift']());}catch(_0x755e6e){_0x700822['push'](_0x700822['shift']());}}}(a145_0x12f5,0x826e1));import{CliErrors}from'../../errors.js';function a145_0x3f2a(_0x27eb61,_0x4a9304){_0x27eb61=_0x27eb61-0xb8;const _0x12f56d=a145_0x12f5();let _0x3f2a42=_0x12f56d[_0x27eb61];return _0x3f2a42;}import{SKILL_FILE}from'./constants.js';import{bufferSha256,fileHash,fileTreeHash}from'./hashing.js';import{fileContent,isSha256Hex,normalizeLocalFiles,normalizeManifestFiles}from'./local-files.js';import{createDeterministicZipPackage,parseZipPackage}from'./zip-codec.js';export function buildSkillPackage(_0x52f3b3){const _0x2f61ae=a145_0x3f2a,_0xea7ac4=normalizeLocalFiles(_0x52f3b3);if(!_0xea7ac4[_0x2f61ae(0xe4)](_0x5c8266=>_0x5c8266[_0x2f61ae(0xe7)]===SKILL_FILE))throw CliErrors[_0x2f61ae(0xce)](_0x2f61ae(0xc1)+SKILL_FILE+_0x2f61ae(0xcd));const _0x3423d0=localFilesToManifestFiles(_0xea7ac4),_0x18c78d=createDeterministicZipPackage(_0xea7ac4);return{'manifest':{'schemaVersion':0x2,'treeSha256':fileTreeHash(_0x3423d0),'zipSha256':bufferSha256(_0x18c78d),'zipSize':_0x18c78d['length'],'files':_0x3423d0},'packageBytes':_0x18c78d,'packageBase64':_0x18c78d['toString'](_0x2f61ae(0xbc))};}export function verifyRuntimeSkillPackage(_0x1c3551,_0x4ce036){const _0x5acd9d=a145_0x3f2a,_0x34ceb1=normalizePackageManifest(_0x1c3551,{'requireOssPath':![]});if(!_0x34ceb1)throw CliErrors['validation'](_0x5acd9d(0xc9));return extractAndVerifyPackage(_0x34ceb1,_0x4ce036);}export function verifyRuntimeSkillBundle(_0x246560,_0x3b5b7a){const _0xb62e56=a145_0x3f2a,_0x38b5ca=normalizePackageManifest(_0x246560,{'requireOssPath':![]});if(!_0x38b5ca)throw CliErrors[_0xb62e56(0xce)](_0xb62e56(0xc9));return extractAndVerifyPackageFiles(_0x38b5ca,_0x3b5b7a);}export function tryNormalizePackageManifest(_0x43ef3f){return normalizePackageManifest(_0x43ef3f,{'requireOssPath':![]});}export function requirePackageBytes(_0x2540bf,_0x1d7f11){const _0x42cfeb=a145_0x3f2a;if(!_0x1d7f11||_0x1d7f11['length']===0x0)throw CliErrors['validation'](_0x42cfeb(0xb8)+_0x2540bf);return _0x1d7f11;}export function extractDownloadedPackage(_0x1b0777){const _0x33937f=a145_0x3f2a,_0x597f11=parseZipPackage(_0x1b0777)['map'](_0x53573c=>({'path':_0x53573c[_0x33937f(0xe7)],'bytes':_0x53573c[_0x33937f(0xba)]}));if(!_0x597f11[_0x33937f(0xe4)](_0x55f4fa=>_0x55f4fa[_0x33937f(0xe7)]===SKILL_FILE))throw CliErrors[_0x33937f(0xce)]('Runtime\x20Skill\x20package\x20is\x20missing\x20'+SKILL_FILE+'.');return normalizeLocalFiles(_0x597f11);}export function localFilesToManifestFiles(_0x46aef3){const _0x3c966d=a145_0x3f2a;return normalizeLocalFiles(_0x46aef3)[_0x3c966d(0xc3)](_0x24925b=>({'path':_0x24925b[_0x3c966d(0xe7)],'sha256':fileHash(_0x24925b),'size':fileContent(_0x24925b)[_0x3c966d(0xe3)]}));}function a145_0x12f5(){const _0x5e4eae=['base64','492457NfpoNp','isSafeInteger','sha256','files','Missing\x20','schemaVersion','map','Runtime\x20Skill\x20package\x20sha256\x20mismatch.','push','1550146DnrPgt','Runtime\x20Skill\x20file\x20tree\x20sha256\x20is\x20invalid.','treeSha256','Runtime\x20Skill\x20package\x20manifest\x20is\x20missing.','zipSha256','6xfTsCW','Runtime\x20Skill\x20package\x20entry\x20list\x20mismatch.','\x20in\x20Skill\x20file\x20package.','validation','size','88GaGIyp','Runtime\x20Skill\x20package\x20size\x20mismatch.','1000549uAcnFm','559665HNtzau','Runtime\x20Skill\x20file\x20tree\x20sha256\x20mismatch.','has','1071IjrIhE','Runtime\x20Skill\x20package\x20is\x20missing\x20entry:\x20','requireOssPath','toLowerCase','set','get','ossPath','9CQKuel','Runtime\x20Skill\x20package\x20sha256\x20is\x20invalid.','Runtime\x20Skill\x20package\x20file\x20size\x20mismatch:\x20','trim','Duplicate\x20Skill\x20package\x20entry:\x20','isArray','length','some','1452665WuhnZz','object','path','9160urWgPP','Runtime\x20Skill\x20package\x20size\x20is\x20invalid.','60EgBhyo','Runtime\x20Skill\x20package\x20is\x20required\x20for\x20Skill\x20install:\x20','zipSize','bytes','5417180ZbaSsq'];a145_0x12f5=function(){return _0x5e4eae;};return a145_0x12f5();}function normalizePackageManifest(_0x4c5fc1,_0x142af0){const _0x5b50c9=a145_0x3f2a;if(!_0x4c5fc1||typeof _0x4c5fc1!==_0x5b50c9(0xe6)||Array[_0x5b50c9(0xe2)](_0x4c5fc1))return undefined;const _0x5c770a=_0x4c5fc1,_0x334a2c=typeof _0x5c770a[_0x5b50c9(0xdc)]==='string'?_0x5c770a[_0x5b50c9(0xdc)][_0x5b50c9(0xe0)]():undefined;if(_0x142af0[_0x5b50c9(0xd8)]&&!_0x334a2c)return undefined;if(!Array[_0x5b50c9(0xe2)](_0x5c770a[_0x5b50c9(0xc0)])||_0x5c770a[_0x5b50c9(0xc0)][_0x5b50c9(0xe3)]===0x0)return undefined;if(!isSha256Hex(_0x5c770a['treeSha256']))throw CliErrors['validation'](_0x5b50c9(0xc7));if(!isSha256Hex(_0x5c770a[_0x5b50c9(0xca)]))throw CliErrors[_0x5b50c9(0xce)](_0x5b50c9(0xde));if(!Number['isSafeInteger'](_0x5c770a['zipSize'])||_0x5c770a['zipSize']<0x0)throw CliErrors[_0x5b50c9(0xce)](_0x5b50c9(0xe9));const _0x180959=normalizeManifestFiles(_0x5c770a[_0x5b50c9(0xc0)]);if(!_0x180959['some'](_0x451495=>_0x451495['path']===SKILL_FILE))throw CliErrors[_0x5b50c9(0xce)]('Runtime\x20Skill\x20manifest\x20is\x20missing\x20'+SKILL_FILE+'.');const _0x1f9b70=fileTreeHash(_0x180959);if(_0x1f9b70!==_0x5c770a[_0x5b50c9(0xc8)][_0x5b50c9(0xd9)]())throw CliErrors[_0x5b50c9(0xce)](_0x5b50c9(0xd4));return{'schemaVersion':Number[_0x5b50c9(0xbe)](_0x5c770a['schemaVersion'])?_0x5c770a[_0x5b50c9(0xc2)]:0x2,'ossPath':_0x334a2c,'treeSha256':_0x1f9b70,'zipSha256':_0x5c770a['zipSha256'][_0x5b50c9(0xd9)](),'zipSize':_0x5c770a['zipSize'],'files':_0x180959};}function extractAndVerifyPackage(_0x3ad60e,_0x4c1943){const _0x323653=a145_0x3f2a,_0x1dfaaf=normalizePackageManifest(_0x3ad60e,{'requireOssPath':![]});if(!_0x1dfaaf)throw CliErrors[_0x323653(0xce)]('Runtime\x20Skill\x20package\x20manifest\x20is\x20missing.');if(_0x4c1943[_0x323653(0xe3)]!==_0x1dfaaf[_0x323653(0xb9)])throw CliErrors['validation'](_0x323653(0xd1));const _0x536609=bufferSha256(_0x4c1943);if(_0x536609!==_0x1dfaaf[_0x323653(0xca)])throw CliErrors[_0x323653(0xce)](_0x323653(0xc4));return extractAndVerifyPackageFiles(_0x1dfaaf,_0x4c1943);}function extractAndVerifyPackageFiles(_0x565b7b,_0x30dfa1){const _0x39df85=a145_0x3f2a,_0x2d3c72=parseZipPackage(_0x30dfa1);if(_0x2d3c72[_0x39df85(0xe3)]!==_0x565b7b[_0x39df85(0xc0)][_0x39df85(0xe3)])throw CliErrors[_0x39df85(0xce)](_0x39df85(0xcc));const _0x456efa=new Map();for(const _0xcd9fe4 of _0x2d3c72){if(_0x456efa[_0x39df85(0xd5)](_0xcd9fe4[_0x39df85(0xe7)]))throw CliErrors[_0x39df85(0xce)](_0x39df85(0xe1)+_0xcd9fe4[_0x39df85(0xe7)]);_0x456efa[_0x39df85(0xda)](_0xcd9fe4[_0x39df85(0xe7)],_0xcd9fe4);}const _0x4ea624=[];for(const _0x3ee7c8 of _0x565b7b[_0x39df85(0xc0)]){const _0x13d945=_0x456efa[_0x39df85(0xdb)](_0x3ee7c8[_0x39df85(0xe7)]);if(!_0x13d945)throw CliErrors[_0x39df85(0xce)](_0x39df85(0xd7)+_0x3ee7c8[_0x39df85(0xe7)]);if(_0x13d945[_0x39df85(0xba)]['length']!==_0x3ee7c8[_0x39df85(0xcf)])throw CliErrors[_0x39df85(0xce)](_0x39df85(0xdf)+_0x3ee7c8[_0x39df85(0xe7)]);const _0x6baac3=bufferSha256(_0x13d945[_0x39df85(0xba)]);if(_0x6baac3!==_0x3ee7c8[_0x39df85(0xbf)])throw CliErrors[_0x39df85(0xce)]('Runtime\x20Skill\x20package\x20file\x20sha256\x20mismatch:\x20'+_0x3ee7c8['path']);_0x4ea624[_0x39df85(0xc5)]({'path':_0x3ee7c8[_0x39df85(0xe7)],'bytes':_0x13d945[_0x39df85(0xba)]});}return normalizeLocalFiles(_0x4ea624);}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x531bb6,_0x2242b1){var _0x42a3b7=a146_0x3af0,_0x59296d=_0x531bb6();while(!![]){try{var _0x254e29=parseInt(_0x42a3b7(0x10f))/0x1*(parseInt(_0x42a3b7(0x113))/0x2)+parseInt(_0x42a3b7(0x110))/0x3*(-parseInt(_0x42a3b7(0x116))/0x4)+-parseInt(_0x42a3b7(0x115))/0x5+parseInt(_0x42a3b7(0x111))/0x6*(parseInt(_0x42a3b7(0x114))/0x7)+parseInt(_0x42a3b7(0x10e))/0x8+parseInt(_0x42a3b7(0x117))/0x9*(parseInt(_0x42a3b7(0x10d))/0xa)+parseInt(_0x42a3b7(0x112))/0xb;if(_0x254e29===_0x2242b1)break;else _0x59296d['push'](_0x59296d['shift']());}catch(_0xaad20b){_0x59296d['push'](_0x59296d['shift']());}}}(a146_0x3268,0xbc37f));export{contentHash,fileTreeHash}from'./runtime-skill-sync/hashing.js';export{linkEffectiveRuntimeSkills,linkGlobalRuntimeSkills,pruneStaleRuntimeSkillCache,pruneStaleRuntimeSkillLinks}from'./runtime-skill-sync/links.js';function a146_0x3af0(_0x320c26,_0x269ffd){_0x320c26=_0x320c26-0x10d;var _0x3268f7=a146_0x3268();var _0x3af01b=_0x3268f7[_0x320c26];return _0x3af01b;}export{resolveRuntimeSkillInstallTarget}from'./runtime-skill-sync/install-target.js';export{listLocalRuntimeSkills}from'./runtime-skill-sync/list-local.js';export{materializeRuntimeSkill,reuseMaterializedRuntimeSkill}from'./runtime-skill-sync/materialize.js';export{readMetadataIfPresent}from'./runtime-skill-sync/metadata.js';export{getRuntimeSkillCacheRoot,getRuntimeSkillDir,resolveSkillSyncPaths,runtimeAgentSkillRoots}from'./runtime-skill-sync/paths.js';export{deriveSkillCodeFromDirectory,readPushDirectory,refreshPushDirectoryMetadataFromRemote,recordPushedRuntimeSkill,resolvePushDirectoryIdentity}from'./runtime-skill-sync/push.js';export{buildSkillPackage,verifyRuntimeSkillBundle,verifyRuntimeSkillPackage}from'./runtime-skill-sync/zip-package.js';function a146_0x3268(){var _0x47e6ec=['488024CTJKel','1155984DUQlYZ','36LVetbi','6687654LWDNlQ','3839660WyWKSt','2BRfcGm','7ZHDUpI','6087670EbbzSk','431492zneNFz','5420673vYxTxh','10JFQSCo'];a146_0x3268=function(){return _0x47e6ec;};return a146_0x3268();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a147_0x35ba93=a147_0x364c;(function(_0x2c3440,_0x477cda){const _0x54c1eb=a147_0x364c,_0x3b9783=_0x2c3440();while(!![]){try{const _0xef4fe2=parseInt(_0x54c1eb(0xa2))/0x1*(-parseInt(_0x54c1eb(0xc3))/0x2)+-parseInt(_0x54c1eb(0xa5))/0x3*(parseInt(_0x54c1eb(0x9e))/0x4)+parseInt(_0x54c1eb(0xb0))/0x5*(parseInt(_0x54c1eb(0x9f))/0x6)+parseInt(_0x54c1eb(0xb6))/0x7*(-parseInt(_0x54c1eb(0xb9))/0x8)+-parseInt(_0x54c1eb(0xa9))/0x9+-parseInt(_0x54c1eb(0xa0))/0xa*(-parseInt(_0x54c1eb(0xb1))/0xb)+parseInt(_0x54c1eb(0xac))/0xc;if(_0xef4fe2===_0x477cda)break;else _0x3b9783['push'](_0x3b9783['shift']());}catch(_0x1cd71a){_0x3b9783['push'](_0x3b9783['shift']());}}}(a147_0x30f9,0x4c7cb));import{existsSync,readFileSync}from'node:fs';import{homedir}from'node:os';import{join}from'node:path';export const SKILL_LOCK_RELATIVE_PATH=join('.agents',a147_0x35ba93(0xc1));function a147_0x30f9(){const _0x28beea=['.agents','2659uJnqWI','not-recorded','\x20is\x20unreadable:\x20','168519SaftWZ','globalSkillsDirs','\x22\x20but\x20no\x20SKILL.md\x20was\x20found\x20in\x20known\x20layouts\x20','\x20records\x20\x22','1428867ODqoVJ','present','message','5103480KTiqMT','\x20has\x20no\x20skills\x20map','unusable','includes','10HBcMxe','1925143tUOCfv','lockFile','.claude','find','version','7kYeoMh','join','skills','2982264IvevuR','SKILL.md','kind','home','object','unverifiable','map','absent','.skill-lock.json','recorded','194eiQcxE','4ekksFo','625812dRFpJk','30fipqVq'];a147_0x30f9=function(){return _0x28beea;};return a147_0x30f9();}export const GLOBAL_SKILLS_DIR_RELATIVE_PATHS=[join(a147_0x35ba93(0xa1),'skills'),join(a147_0x35ba93(0xb3),'skills')];function a147_0x364c(_0x3d9889,_0x5cf69b){_0x3d9889=_0x3d9889-0x9e;const _0x30f926=a147_0x30f9();let _0x364cb3=_0x30f926[_0x3d9889];return _0x364cb3;}const SUPPORTED_LOCK_VERSIONS=[0x3];function readLockLookup(_0x479a80,_0xae0153){const _0x37dea2=a147_0x35ba93;if(!existsSync(_0x479a80))return{'kind':_0x37dea2(0xa3)};let _0x2e6508;try{_0x2e6508=JSON['parse'](readFileSync(_0x479a80,'utf8'));}catch(_0x40a596){return{'kind':_0x37dea2(0xae),'reason':_0x479a80+_0x37dea2(0xa4)+_0x40a596[_0x37dea2(0xab)]};}const _0x27f2b5=_0x2e6508;if(typeof _0x27f2b5?.['version']!=='number'||!SUPPORTED_LOCK_VERSIONS[_0x37dea2(0xaf)](_0x27f2b5['version']))return{'kind':'unusable','reason':_0x479a80+'\x20uses\x20unsupported\x20version\x20'+String(_0x27f2b5?.[_0x37dea2(0xb5)])};if(!_0x27f2b5[_0x37dea2(0xb8)]||typeof _0x27f2b5['skills']!==_0x37dea2(0xbd))return{'kind':_0x37dea2(0xae),'reason':_0x479a80+_0x37dea2(0xad)};return _0x27f2b5['skills'][_0xae0153]?{'kind':_0x37dea2(0xc2)}:{'kind':_0x37dea2(0xa3)};}export function resolveInstalledSkill(_0x73486e,_0x2775ec){const _0x3b67ff=a147_0x35ba93,_0x3baa64=_0x2775ec?.[_0x3b67ff(0xbc)]??homedir(),_0x3e8cec=_0x2775ec?.[_0x3b67ff(0xa6)]??GLOBAL_SKILLS_DIR_RELATIVE_PATHS[_0x3b67ff(0xbf)](_0x222c1d=>join(_0x3baa64,_0x222c1d)),_0x48c4f5=_0x2775ec?.[_0x3b67ff(0xb2)]??join(_0x3baa64,SKILL_LOCK_RELATIVE_PATH),_0x2b51e2=_0x3e8cec[_0x3b67ff(0xbf)](_0x6658e2=>join(_0x6658e2,_0x73486e,_0x3b67ff(0xba))),_0x4ec77e=_0x2b51e2[_0x3b67ff(0xb4)](_0x1abf0c=>existsSync(_0x1abf0c));if(_0x4ec77e)return{'state':_0x3b67ff(0xaa),'path':_0x4ec77e};const _0x58668f=readLockLookup(_0x48c4f5,_0x73486e);if(_0x58668f[_0x3b67ff(0xbb)]===_0x3b67ff(0xae))return{'state':_0x3b67ff(0xbe),'reason':_0x58668f['reason']};if(_0x58668f[_0x3b67ff(0xbb)]===_0x3b67ff(0xc2))return{'state':_0x3b67ff(0xbe),'reason':_0x48c4f5+_0x3b67ff(0xa8)+_0x73486e+_0x3b67ff(0xa7)+('('+_0x2b51e2[_0x3b67ff(0xb7)](',\x20')+')')};return{'state':_0x3b67ff(0xc0),'checked':_0x2b51e2};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x26f7a7,_0x6e5252){const _0x3c2c81=a148_0x4984,_0x3931e9=_0x26f7a7();while(!![]){try{const _0x3250d9=-parseInt(_0x3c2c81(0x10c))/0x1+parseInt(_0x3c2c81(0x109))/0x2+parseInt(_0x3c2c81(0x10e))/0x3+parseInt(_0x3c2c81(0x10f))/0x4*(-parseInt(_0x3c2c81(0x10d))/0x5)+parseInt(_0x3c2c81(0x10b))/0x6+parseInt(_0x3c2c81(0x108))/0x7+parseInt(_0x3c2c81(0x10a))/0x8;if(_0x3250d9===_0x6e5252)break;else _0x3931e9['push'](_0x3931e9['shift']());}catch(_0x54d5f5){_0x3931e9['push'](_0x3931e9['shift']());}}}(a148_0x5d2b,0xaeaf1));import{createJqFilter,resolveBundledJqPaths}from'@lovrabet/cli-framework';function a148_0x4984(_0x5af5a1,_0x3fc4a2){_0x5af5a1=_0x5af5a1-0x108;const _0x5d2b21=a148_0x5d2b();let _0x498461=_0x5d2b21[_0x5af5a1];return _0x498461;}function a148_0x5d2b(){const _0x54d5ec=['896270NfGQBk','25GjjNHr','372609lCSvKT','382628KlBnen','646135QMeOiZ','1626510KDumGS','5655112sGAjJB','2120448kFJDRu'];a148_0x5d2b=function(){return _0x54d5ec;};return a148_0x5d2b();}import{CliErrors}from'../errors.js';export const applyJqFilter=createJqFilter(CliErrors,{'bundledJqPaths':resolveBundledJqPaths()});
|