@skaile/workspaces 5.10.0 → 5.12.0
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/CHANGELOG.md +146 -0
- package/README.md +14 -2
- package/dist/{asset-feeds-ELEBTNUS.js → asset-feeds-AM6PSSGM.js} +24 -21
- package/dist/asset-feeds-AM6PSSGM.js.map +1 -0
- package/dist/asset-manager/catalog-deployer.js +8 -8
- package/dist/asset-manager/fragments.js +1 -1
- package/dist/asset-manager/index.js +16 -16
- package/dist/asset-manager/installer.js +11 -11
- package/dist/asset-manager/renderers.js +9 -9
- package/dist/asset-manager/src/fragments.d.ts +5 -0
- package/dist/asset-manager/src/fragments.d.ts.map +1 -1
- package/dist/asset-manager/src/index.d.ts +197 -11
- package/dist/asset-manager/src/index.d.ts.map +1 -1
- package/dist/asset-manager/src/install-agent.d.ts +9 -1
- package/dist/asset-manager/src/install-agent.d.ts.map +1 -1
- package/dist/asset-manager/src/install-instances.d.ts.map +1 -1
- package/dist/asset-manager/src/installer.d.ts +33 -3
- package/dist/asset-manager/src/installer.d.ts.map +1 -1
- package/dist/asset-manager/src/renderers.d.ts +5 -0
- package/dist/asset-manager/src/renderers.d.ts.map +1 -1
- package/dist/bridge/drivers/claude-sdk.js +16 -13
- package/dist/bridge/drivers/claude-sdk.js.map +1 -1
- package/dist/bridge/drivers/codex.js +43 -16
- package/dist/bridge/drivers/codex.js.map +1 -1
- package/dist/bridge/drivers/continue.js +10 -10
- package/dist/bridge/drivers/echo.js +2 -2
- package/dist/bridge/drivers/gemini.js +7 -7
- package/dist/bridge/drivers/goose.js +10 -10
- package/dist/bridge/drivers/omp.js +52 -9
- package/dist/bridge/drivers/omp.js.map +1 -1
- package/dist/bridge/drivers/opencode.js +10 -10
- package/dist/bridge/drivers/qwen.js +7 -7
- package/dist/bridge/index.js +12 -12
- package/dist/bridge/src/codex/config-toml.d.ts +8 -3
- package/dist/bridge/src/codex/config-toml.d.ts.map +1 -1
- package/dist/bridge/src/codex/managed-driver.d.ts.map +1 -1
- package/dist/bridge/src/drivers/claude-sdk.d.ts +1 -1
- package/dist/bridge/src/drivers/claude-sdk.d.ts.map +1 -1
- package/dist/bridge/src/drivers/codex.d.ts.map +1 -1
- package/dist/bridge/src/drivers/omp-models-yml.d.ts.map +1 -1
- package/dist/bridge/src/drivers/omp.d.ts +9 -0
- package/dist/bridge/src/drivers/omp.d.ts.map +1 -1
- package/dist/bridge/src/provider-materialize/credential-env.d.ts +15 -0
- package/dist/bridge/src/provider-materialize/credential-env.d.ts.map +1 -1
- package/dist/{chunk-7CR6HT2X.js → chunk-27L6BBAT.js} +9 -9
- package/dist/{chunk-7CR6HT2X.js.map → chunk-27L6BBAT.js.map} +1 -1
- package/dist/{chunk-QG3HOJEK.js → chunk-2JFIFDDO.js} +3 -3
- package/dist/{chunk-QG3HOJEK.js.map → chunk-2JFIFDDO.js.map} +1 -1
- package/dist/{chunk-IJHH4DSW.js → chunk-2X3JBVGD.js} +11 -10
- package/dist/chunk-2X3JBVGD.js.map +1 -0
- package/dist/{chunk-G54USEUP.js → chunk-3HUV2LJF.js} +4 -4
- package/dist/{chunk-G54USEUP.js.map → chunk-3HUV2LJF.js.map} +1 -1
- package/dist/{chunk-JFXQEVLF.js → chunk-3LVB3HGH.js} +3 -3
- package/dist/{chunk-JFXQEVLF.js.map → chunk-3LVB3HGH.js.map} +1 -1
- package/dist/{chunk-32XKCNCL.js → chunk-6VLHITAM.js} +146 -4
- package/dist/chunk-6VLHITAM.js.map +1 -0
- package/dist/{chunk-GEWAIQZ5.js → chunk-7CR2OZPA.js} +10 -12
- package/dist/chunk-7CR2OZPA.js.map +1 -0
- package/dist/{chunk-6HHE63CO.js → chunk-7QWQTA5S.js} +89 -12
- package/dist/chunk-7QWQTA5S.js.map +1 -0
- package/dist/{chunk-7I5VRVDP.js → chunk-7XWUJC3A.js} +4 -4
- package/dist/{chunk-7I5VRVDP.js.map → chunk-7XWUJC3A.js.map} +1 -1
- package/dist/{chunk-3BEY4WK3.js → chunk-C3BMXXTN.js} +203 -31
- package/dist/chunk-C3BMXXTN.js.map +1 -0
- package/dist/{chunk-IXWODEED.js → chunk-CTP3XBMF.js} +47 -8
- package/dist/chunk-CTP3XBMF.js.map +1 -0
- package/dist/{chunk-HOHUEKES.js → chunk-DCHQ6BAZ.js} +3 -3
- package/dist/{chunk-HOHUEKES.js.map → chunk-DCHQ6BAZ.js.map} +1 -1
- package/dist/{chunk-DALV4HHP.js → chunk-DKXNKFKP.js} +3 -2
- package/dist/{chunk-DALV4HHP.js.map → chunk-DKXNKFKP.js.map} +1 -1
- package/dist/{chunk-3MKPZZRE.js → chunk-G3X4MLDB.js} +3 -3
- package/dist/{chunk-3MKPZZRE.js.map → chunk-G3X4MLDB.js.map} +1 -1
- package/dist/{chunk-SBFW3CJH.js → chunk-GWD3QNVS.js} +5 -5
- package/dist/{chunk-SBFW3CJH.js.map → chunk-GWD3QNVS.js.map} +1 -1
- package/dist/chunk-H5U7LNTJ.js +122 -0
- package/dist/chunk-H5U7LNTJ.js.map +1 -0
- package/dist/{chunk-SX5U422E.js → chunk-HYMERG57.js} +3 -3
- package/dist/{chunk-SX5U422E.js.map → chunk-HYMERG57.js.map} +1 -1
- package/dist/{chunk-V5TZH4GF.js → chunk-ICIYSJBQ.js} +4 -4
- package/dist/{chunk-V5TZH4GF.js.map → chunk-ICIYSJBQ.js.map} +1 -1
- package/dist/{chunk-YBQONMH2.js → chunk-ID745F3R.js} +353 -193
- package/dist/chunk-ID745F3R.js.map +1 -0
- package/dist/{chunk-CLTHEKHR.js → chunk-JQ3DXNQV.js} +4 -4
- package/dist/{chunk-CLTHEKHR.js.map → chunk-JQ3DXNQV.js.map} +1 -1
- package/dist/chunk-K4VOEYOR.js +21 -0
- package/dist/chunk-K4VOEYOR.js.map +1 -0
- package/dist/{chunk-XCNK4UE5.js → chunk-KVSDRB35.js} +5 -5
- package/dist/{chunk-XCNK4UE5.js.map → chunk-KVSDRB35.js.map} +1 -1
- package/dist/{chunk-HJ5MCB3L.js → chunk-MF54ZHWT.js} +20 -3
- package/dist/chunk-MF54ZHWT.js.map +1 -0
- package/dist/{chunk-NRDSGLCQ.js → chunk-N5M2EISA.js} +240 -52
- package/dist/chunk-N5M2EISA.js.map +1 -0
- package/dist/{chunk-OBVJ7RPW.js → chunk-NDF24LYP.js} +3 -3
- package/dist/{chunk-OBVJ7RPW.js.map → chunk-NDF24LYP.js.map} +1 -1
- package/dist/{chunk-ZGQTS3Y4.js → chunk-NGJIVDDD.js} +3 -3
- package/dist/{chunk-ZGQTS3Y4.js.map → chunk-NGJIVDDD.js.map} +1 -1
- package/dist/{chunk-PE36IF2D.js → chunk-NJV5SLEK.js} +159 -44
- package/dist/chunk-NJV5SLEK.js.map +1 -0
- package/dist/{chunk-OOWHXOK6.js → chunk-NJXR5OAM.js} +4 -4
- package/dist/{chunk-OOWHXOK6.js.map → chunk-NJXR5OAM.js.map} +1 -1
- package/dist/{chunk-CGYEHQOX.js → chunk-NOA6EJXE.js} +11 -2
- package/dist/chunk-NOA6EJXE.js.map +1 -0
- package/dist/{chunk-V7PQZOBR.js → chunk-NR7H7ZJP.js} +14 -6
- package/dist/chunk-NR7H7ZJP.js.map +1 -0
- package/dist/{chunk-OBYKJB4U.js → chunk-O2SYFJWP.js} +79 -5
- package/dist/chunk-O2SYFJWP.js.map +1 -0
- package/dist/{chunk-5LKOAX7I.js → chunk-OQ5MKDS3.js} +21 -5
- package/dist/chunk-OQ5MKDS3.js.map +1 -0
- package/dist/{chunk-4P3KTUZH.js → chunk-P23WJCH2.js} +51 -14
- package/dist/chunk-P23WJCH2.js.map +1 -0
- package/dist/{chunk-NWDSLXOX.js → chunk-PHRNUTSG.js} +118 -118
- package/dist/chunk-PHRNUTSG.js.map +1 -0
- package/dist/{chunk-JZCSNEHK.js → chunk-PNOGX36L.js} +141 -39
- package/dist/chunk-PNOGX36L.js.map +1 -0
- package/dist/{chunk-4OV5DSBB.js → chunk-PNTXHTBC.js} +5 -5
- package/dist/chunk-PNTXHTBC.js.map +1 -0
- package/dist/{chunk-TRSQP3JD.js → chunk-POQ6PGNE.js} +20 -4
- package/dist/chunk-POQ6PGNE.js.map +1 -0
- package/dist/{chunk-Y63UQZ7P.js → chunk-QCEKGYHF.js} +3 -3
- package/dist/{chunk-Y63UQZ7P.js.map → chunk-QCEKGYHF.js.map} +1 -1
- package/dist/{chunk-GFCXNFTW.js → chunk-SHQMPGOL.js} +4 -4
- package/dist/{chunk-GFCXNFTW.js.map → chunk-SHQMPGOL.js.map} +1 -1
- package/dist/{chunk-WBYDAL6X.js → chunk-SMT3LNAG.js} +4 -4
- package/dist/{chunk-WBYDAL6X.js.map → chunk-SMT3LNAG.js.map} +1 -1
- package/dist/{chunk-2FMEGSBN.js → chunk-T5TSLSRO.js} +135 -47
- package/dist/chunk-T5TSLSRO.js.map +1 -0
- package/dist/{chunk-2JMLDZLP.js → chunk-TVAR4JHA.js} +903 -138
- package/dist/chunk-TVAR4JHA.js.map +1 -0
- package/dist/{chunk-MVQ3Q2HM.js → chunk-UTKENBB6.js} +5 -5
- package/dist/{chunk-MVQ3Q2HM.js.map → chunk-UTKENBB6.js.map} +1 -1
- package/dist/{chunk-TH4CTXHX.js → chunk-VRLKHL74.js} +6 -6
- package/dist/{chunk-TH4CTXHX.js.map → chunk-VRLKHL74.js.map} +1 -1
- package/dist/{chunk-Z2K6BGUR.js → chunk-WI4T3KIS.js} +51 -16
- package/dist/chunk-WI4T3KIS.js.map +1 -0
- package/dist/{chunk-MGGFBZWA.js → chunk-X3RMRJNR.js} +6 -4
- package/dist/chunk-X3RMRJNR.js.map +1 -0
- package/dist/{chunk-FRPBSUFH.js → chunk-X6LKA3TJ.js} +5 -5
- package/dist/{chunk-FRPBSUFH.js.map → chunk-X6LKA3TJ.js.map} +1 -1
- package/dist/{chunk-3KHYGOEY.js → chunk-XMAJJPA4.js} +3 -3
- package/dist/{chunk-3KHYGOEY.js.map → chunk-XMAJJPA4.js.map} +1 -1
- package/dist/{chunk-Y34MSWEZ.js → chunk-XTVSNWLL.js} +19 -7
- package/dist/chunk-XTVSNWLL.js.map +1 -0
- package/dist/{chunk-VLXDXRRX.js → chunk-XZY6SBGU.js} +3 -3
- package/dist/{chunk-VLXDXRRX.js.map → chunk-XZY6SBGU.js.map} +1 -1
- package/dist/{chunk-5QI2JYJC.js → chunk-YQU2BPQD.js} +7 -5
- package/dist/chunk-YQU2BPQD.js.map +1 -0
- package/dist/cli/index.js +1207 -580
- package/dist/cli/index.js.map +1 -1
- package/dist/cli/src/agent-checks.d.ts +40 -0
- package/dist/cli/src/agent-checks.d.ts.map +1 -0
- package/dist/cli/src/asset-feeds.d.ts.map +1 -1
- package/dist/cli/src/commands/asset-cmd.d.ts.map +1 -1
- package/dist/cli/src/commands/catalog.d.ts +24 -0
- package/dist/cli/src/commands/catalog.d.ts.map +1 -1
- package/dist/cli/src/commands/config.d.ts.map +1 -1
- package/dist/cli/src/commands/diff.d.ts +1 -1
- package/dist/cli/src/commands/diff.d.ts.map +1 -1
- package/dist/cli/src/commands/integration.d.ts.map +1 -1
- package/dist/cli/src/commands/library-cmd.d.ts.map +1 -1
- package/dist/cli/src/commands/library-publish.d.ts.map +1 -1
- package/dist/cli/src/commands/manage.d.ts +6 -0
- package/dist/cli/src/commands/manage.d.ts.map +1 -1
- package/dist/cli/src/commands/mcp-server.d.ts +1 -1
- package/dist/cli/src/commands/migrate-assets.d.ts +2 -1
- package/dist/cli/src/commands/migrate-assets.d.ts.map +1 -1
- package/dist/cli/src/commands/migrate.d.ts.map +1 -1
- package/dist/cli/src/commands/outdated.d.ts.map +1 -1
- package/dist/cli/src/commands/plugin/claude-code.d.ts +1 -1
- package/dist/cli/src/commands/plugin/claude-code.d.ts.map +1 -1
- package/dist/cli/src/commands/plugin/types.d.ts +1 -1
- package/dist/cli/src/commands/plugin-registry-cmd.d.ts.map +1 -1
- package/dist/cli/src/commands/project.d.ts +3 -1
- package/dist/cli/src/commands/project.d.ts.map +1 -1
- package/dist/cli/src/commands/publish-core.d.ts +5 -0
- package/dist/cli/src/commands/publish-core.d.ts.map +1 -1
- package/dist/cli/src/commands/run.d.ts +2 -1
- package/dist/cli/src/commands/run.d.ts.map +1 -1
- package/dist/cli/src/commands/serve-preflight.d.ts +22 -0
- package/dist/cli/src/commands/serve-preflight.d.ts.map +1 -0
- package/dist/cli/src/commands/serve.d.ts.map +1 -1
- package/dist/cli/src/commands/source-manifest-publish.d.ts.map +1 -1
- package/dist/cli/src/commands/source-manifest.d.ts.map +1 -1
- package/dist/cli/src/commands/source.d.ts.map +1 -1
- package/dist/cli/src/commands/store.d.ts.map +1 -1
- package/dist/cli/src/commands/tree.d.ts.map +1 -1
- package/dist/cli/src/commands/update.d.ts.map +1 -1
- package/dist/cli/src/commands/validate.d.ts.map +1 -1
- package/dist/cli/src/commands/why.d.ts +1 -0
- package/dist/cli/src/commands/why.d.ts.map +1 -1
- package/dist/cli/src/curated-manifests.d.ts +21 -0
- package/dist/cli/src/curated-manifests.d.ts.map +1 -0
- package/dist/cli/src/helpers.d.ts +12 -0
- package/dist/cli/src/helpers.d.ts.map +1 -1
- package/dist/cli/src/index-busy.d.ts +8 -0
- package/dist/cli/src/index-busy.d.ts.map +1 -0
- package/dist/cli/src/plugin-store/paths.d.ts +7 -3
- package/dist/cli/src/plugin-store/paths.d.ts.map +1 -1
- package/dist/cli/src/skill-checks.d.ts +29 -8
- package/dist/cli/src/skill-checks.d.ts.map +1 -1
- package/dist/cli/src/store-addable.d.ts +18 -0
- package/dist/cli/src/store-addable.d.ts.map +1 -0
- package/dist/connectors/config.js +5 -5
- package/dist/connectors/index.js +16 -16
- package/dist/{connectors-OXP2JBGI.js → connectors-UNKUKEPG.js} +19 -19
- package/dist/{connectors-OXP2JBGI.js.map → connectors-UNKUKEPG.js.map} +1 -1
- package/dist/core/index.js +7 -7
- package/dist/core/logging.js +1 -1
- package/dist/core/manifest.js +2 -2
- package/dist/core/models.js +1 -1
- package/dist/core/publish-manifest.js +2 -2
- package/dist/core/ref.js +1 -1
- package/dist/core/runtime-assets.js +5 -5
- package/dist/core/src/index.d.ts +5 -4
- package/dist/core/src/index.d.ts.map +1 -1
- package/dist/core/src/lock.d.ts +19 -8
- package/dist/core/src/lock.d.ts.map +1 -1
- package/dist/core/src/logging/sinks/sqlite-sink.d.ts.map +1 -1
- package/dist/core/src/manifest.d.ts +5 -0
- package/dist/core/src/manifest.d.ts.map +1 -1
- package/dist/core/src/models.d.ts +4 -4
- package/dist/core/src/models.d.ts.map +1 -1
- package/dist/core/src/package-manager.d.ts +19 -0
- package/dist/core/src/package-manager.d.ts.map +1 -0
- package/dist/core/src/publish-manifest.d.ts +11 -1
- package/dist/core/src/publish-manifest.d.ts.map +1 -1
- package/dist/core/src/repo-manager.d.ts +11 -0
- package/dist/core/src/repo-manager.d.ts.map +1 -1
- package/dist/core/src/settings.d.ts +26 -6
- package/dist/core/src/settings.d.ts.map +1 -1
- package/dist/core/src/walker.d.ts +6 -1
- package/dist/core/src/walker.d.ts.map +1 -1
- package/dist/core/src/workspace-config.d.ts +4 -1
- package/dist/core/src/workspace-config.d.ts.map +1 -1
- package/dist/core/workspace-config.js +4 -4
- package/dist/deploy/index.js +7 -7
- package/dist/discovery/index.js +5 -5
- package/dist/discovery/src/source-config.d.ts.map +1 -1
- package/dist/{ensure-sources-5ISVIA4T.js → ensure-sources-POMEQSTM.js} +19 -19
- package/dist/{ensure-sources-5ISVIA4T.js.map → ensure-sources-POMEQSTM.js.map} +1 -1
- package/dist/factory-assets/connectors/box.js +16 -16
- package/dist/factory-assets/connectors/deploy.js +16 -16
- package/dist/factory-assets/connectors/devserver.js +16 -16
- package/dist/factory-assets/connectors/flow/adapter.js +16 -16
- package/dist/factory-assets/connectors/flow/contract/normalize.d.ts.map +1 -1
- package/dist/factory-assets/connectors/flow/contract.js +1 -1
- package/dist/factory-assets/connectors/flow/engine.js +9 -9
- package/dist/factory-assets/connectors/flow/run-flow.d.ts.map +1 -1
- package/dist/factory-assets/connectors/flow/run-flow.js +18 -18
- package/dist/factory-assets/connectors/flow.js +16 -16
- package/dist/factory-assets/connectors/git.js +16 -16
- package/dist/factory-assets/connectors/gmail.js +16 -16
- package/dist/factory-assets/connectors/googledrive.js +16 -16
- package/dist/factory-assets/connectors/local.js +16 -16
- package/dist/factory-assets/connectors/mattermost.js +16 -16
- package/dist/factory-assets/connectors/memory.js +16 -16
- package/dist/factory-assets/connectors/minio.js +16 -16
- package/dist/factory-assets/connectors/postgres.js +16 -16
- package/dist/factory-assets/connectors/s3.js +16 -16
- package/dist/factory-assets/connectors/sharepoint.js +16 -16
- package/dist/factory-assets/connectors/sqlite.js +16 -16
- package/dist/factory-assets/connectors/static-server.js +16 -16
- package/dist/factory-assets/connectors/tunnel.js +16 -16
- package/dist/factory-assets/connectors/webdav.js +16 -16
- package/dist/factory-assets/connectors/xstate-store.js +16 -16
- package/dist/factory-assets/connectors/xstate.js +16 -16
- package/dist/factory-assets/skills/authoring-skaile-assets/SKILL.md +10 -8
- package/dist/factory-assets/skills/authoring-skaile-manifests/SKILL.md +15 -11
- package/dist/factory-assets/skills/authoring-skaile-manifests/references/dependency-standard.md +16 -11
- package/dist/factory-assets/skills/skaile-author-asset/SKILL.md +2 -2
- package/dist/{flows-HMSE76PO.js → flows-DVKMZKM4.js} +12 -12
- package/dist/{flows-HMSE76PO.js.map → flows-DVKMZKM4.js.map} +1 -1
- package/dist/{helpers-X6URBGSF.js → helpers-Y4OT7VIS.js} +19 -19
- package/dist/{helpers-X6URBGSF.js.map → helpers-Y4OT7VIS.js.map} +1 -1
- package/dist/library/index.js +12 -12
- package/dist/library/install.js +4 -4
- package/dist/library/src/index.d.ts +3 -3
- package/dist/library/src/index.d.ts.map +1 -1
- package/dist/library/src/install/source-fetch-github.d.ts.map +1 -1
- package/dist/library/src/local/db.d.ts +2 -0
- package/dist/library/src/local/db.d.ts.map +1 -1
- package/dist/library/src/local/library-dir.d.ts +26 -0
- package/dist/library/src/local/library-dir.d.ts.map +1 -1
- package/dist/library/src/local/library-manager.d.ts +5 -0
- package/dist/library/src/local/library-manager.d.ts.map +1 -1
- package/dist/library/src/local/library.d.ts +5 -3
- package/dist/library/src/local/library.d.ts.map +1 -1
- package/dist/library/src/local/local-catalog-source.d.ts.map +1 -1
- package/dist/library/src/local/store-paths.d.ts +9 -0
- package/dist/library/src/local/store-paths.d.ts.map +1 -1
- package/dist/library/src/manifest-writer.d.ts.map +1 -1
- package/dist/library/src/remote/index.d.ts +1 -1
- package/dist/library/src/remote/index.d.ts.map +1 -1
- package/dist/library/src/remote/remote-catalog-source.d.ts +17 -0
- package/dist/library/src/remote/remote-catalog-source.d.ts.map +1 -1
- package/dist/library/src/sync/git-driver.d.ts +2 -0
- package/dist/library/src/sync/git-driver.d.ts.map +1 -1
- package/dist/{library-publish-OS3JDW4S.js → library-publish-DI4Q5UOG.js} +73 -38
- package/dist/library-publish-DI4Q5UOG.js.map +1 -0
- package/dist/open-library-N6ESO6IK.js +40 -0
- package/dist/{open-library-4QSUORI6.js.map → open-library-N6ESO6IK.js.map} +1 -1
- package/dist/open-registry-CBZ5MWTT.js +32 -0
- package/dist/{open-registry-VCKS3MP5.js.map → open-registry-CBZ5MWTT.js.map} +1 -1
- package/dist/paths-U6W6MQNQ.js +22 -0
- package/dist/{paths-BVO56A25.js.map → paths-U6W6MQNQ.js.map} +1 -1
- package/dist/{plugin-store-X7GPWGBG.js → plugin-store-XMZSPVBF.js} +48 -12
- package/dist/plugin-store-XMZSPVBF.js.map +1 -0
- package/dist/project-UP52HEHC.js +79 -0
- package/dist/{project-PAXP46RD.js.map → project-UP52HEHC.js.map} +1 -1
- package/dist/resolver/index.js +8 -8
- package/dist/runner/index.js +33 -33
- package/dist/runner/src/agent.d.ts.map +1 -1
- package/dist/runner/src/agents/in-process-host.d.ts.map +1 -1
- package/dist/runner/src/composition/index.d.ts +1 -0
- package/dist/runner/src/composition/index.d.ts.map +1 -1
- package/dist/runner/src/composition/prompt-sections.d.ts +7 -4
- package/dist/runner/src/composition/prompt-sections.d.ts.map +1 -1
- package/dist/runner/src/composition/resolve.d.ts +10 -1
- package/dist/runner/src/composition/resolve.d.ts.map +1 -1
- package/dist/runner/src/composition/verify.d.ts +29 -0
- package/dist/runner/src/composition/verify.d.ts.map +1 -0
- package/dist/runner/src/credential-notice.d.ts +14 -0
- package/dist/runner/src/credential-notice.d.ts.map +1 -0
- package/dist/runner/src/environment.d.ts.map +1 -1
- package/dist/runner/src/final-text.d.ts +17 -0
- package/dist/runner/src/final-text.d.ts.map +1 -0
- package/dist/runner/src/index.d.ts +2 -0
- package/dist/runner/src/index.d.ts.map +1 -1
- package/dist/runner/src/resource-handler.d.ts.map +1 -1
- package/dist/runner/src/serve.d.ts +13 -0
- package/dist/runner/src/serve.d.ts.map +1 -1
- package/dist/runner/src/usage-limit-turn-hold.d.ts +51 -0
- package/dist/runner/src/usage-limit-turn-hold.d.ts.map +1 -0
- package/dist/sdk/asset-manager.js +16 -16
- package/dist/sdk/bridge.js +12 -12
- package/dist/sdk/core.js +7 -7
- package/dist/sdk/flow.js +9 -9
- package/dist/sdk/index.js +36 -34
- package/dist/sdk/index.js.map +1 -1
- package/dist/sdk/resolver.js +8 -8
- package/dist/sdk/runner.js +33 -33
- package/dist/sdk/src/local-runtime.d.ts.map +1 -1
- package/dist/sdk/transport/ws/client.js +1 -1
- package/dist/sdk/transport/ws/server.js +1 -1
- package/dist/sdk/transport/ws.js +2 -2
- package/dist/sdk/transport.js +2 -2
- package/dist/serve-preflight-6P2JJEJ3.js +47 -0
- package/dist/serve-preflight-6P2JJEJ3.js.map +1 -0
- package/dist/{setup-BV55VHWC.js → setup-5IRUH5OS.js} +24 -24
- package/dist/{setup-BV55VHWC.js.map → setup-5IRUH5OS.js.map} +1 -1
- package/dist/{skills-EDFUCJPX.js → skills-HA36RFNM.js} +13 -13
- package/dist/{skills-EDFUCJPX.js.map → skills-HA36RFNM.js.map} +1 -1
- package/dist/source-DX5SGWEI.js +41 -0
- package/dist/{source-E4VAT5RZ.js.map → source-DX5SGWEI.js.map} +1 -1
- package/dist/source-fetch-github-PIO6EMMF.js +4 -0
- package/dist/{source-fetch-github-QN4LLTL5.js.map → source-fetch-github-PIO6EMMF.js.map} +1 -1
- package/dist/{source-manifest-publish-CLEE6TNH.js → source-manifest-publish-NMRLXWVW.js} +27 -26
- package/dist/source-manifest-publish-NMRLXWVW.js.map +1 -0
- package/dist/transport/index.js +2 -2
- package/dist/transport/src/ws/client.d.ts +6 -0
- package/dist/transport/src/ws/client.d.ts.map +1 -1
- package/dist/transport/src/ws/server.d.ts +4 -0
- package/dist/transport/src/ws/server.d.ts.map +1 -1
- package/dist/transport/ws/client.js +1 -1
- package/dist/transport/ws/server.js +1 -1
- package/dist/transport/ws.js +2 -2
- package/dist/tui/index.js +89 -52
- package/dist/tui/index.js.map +1 -1
- package/dist/tui/src/repl-session.d.ts +1 -1
- package/dist/tui/src/repl-session.d.ts.map +1 -1
- package/dist/tui/src/repl.d.ts +3 -0
- package/dist/tui/src/repl.d.ts.map +1 -1
- package/dist/types/manifests.js +1 -1
- package/dist/types/src/manifests/agent-composition.d.ts +20 -0
- package/dist/types/src/manifests/agent-composition.d.ts.map +1 -1
- package/dist/types/src/manifests/agent.d.ts.map +1 -1
- package/dist/types/src/manifests/cron.d.ts +15 -0
- package/dist/types/src/manifests/cron.d.ts.map +1 -0
- package/dist/types/src/manifests/index.d.ts +3 -2
- package/dist/types/src/manifests/index.d.ts.map +1 -1
- package/dist/types/src/manifests/preset.d.ts +1 -1
- package/dist/workspace-plugin/adapters/mcp.js +23 -23
- package/dist/workspace-plugin/adapters/omp.js +106 -51
- package/dist/workspace-plugin/adapters/omp.js.map +1 -1
- package/dist/workspace-plugin/index.js +2 -2
- package/dist/workspace-plugin/src/adapters/claude-code.d.ts.map +1 -1
- package/dist/workspace-plugin/src/adapters/omp.d.ts +11 -2
- package/dist/workspace-plugin/src/adapters/omp.d.ts.map +1 -1
- package/package.json +1 -1
- package/dist/asset-feeds-ELEBTNUS.js.map +0 -1
- package/dist/chunk-2FMEGSBN.js.map +0 -1
- package/dist/chunk-2JMLDZLP.js.map +0 -1
- package/dist/chunk-32XKCNCL.js.map +0 -1
- package/dist/chunk-3BEY4WK3.js.map +0 -1
- package/dist/chunk-4OV5DSBB.js.map +0 -1
- package/dist/chunk-4P3KTUZH.js.map +0 -1
- package/dist/chunk-5LKOAX7I.js.map +0 -1
- package/dist/chunk-5QI2JYJC.js.map +0 -1
- package/dist/chunk-6HHE63CO.js.map +0 -1
- package/dist/chunk-CGYEHQOX.js.map +0 -1
- package/dist/chunk-GEWAIQZ5.js.map +0 -1
- package/dist/chunk-HJ5MCB3L.js.map +0 -1
- package/dist/chunk-IJHH4DSW.js.map +0 -1
- package/dist/chunk-IXWODEED.js.map +0 -1
- package/dist/chunk-JZCSNEHK.js.map +0 -1
- package/dist/chunk-MGGFBZWA.js.map +0 -1
- package/dist/chunk-NRDSGLCQ.js.map +0 -1
- package/dist/chunk-NWDSLXOX.js.map +0 -1
- package/dist/chunk-OBYKJB4U.js.map +0 -1
- package/dist/chunk-PE36IF2D.js.map +0 -1
- package/dist/chunk-R7FOF242.js +0 -59
- package/dist/chunk-R7FOF242.js.map +0 -1
- package/dist/chunk-TRSQP3JD.js.map +0 -1
- package/dist/chunk-V7PQZOBR.js.map +0 -1
- package/dist/chunk-Y34MSWEZ.js.map +0 -1
- package/dist/chunk-YBQONMH2.js.map +0 -1
- package/dist/chunk-Z2K6BGUR.js.map +0 -1
- package/dist/library-publish-OS3JDW4S.js.map +0 -1
- package/dist/open-library-4QSUORI6.js +0 -40
- package/dist/open-registry-VCKS3MP5.js +0 -32
- package/dist/paths-BVO56A25.js +0 -22
- package/dist/plugin-store-X7GPWGBG.js.map +0 -1
- package/dist/project-PAXP46RD.js +0 -41
- package/dist/source-E4VAT5RZ.js +0 -41
- package/dist/source-fetch-github-QN4LLTL5.js +0 -4
- package/dist/source-manifest-publish-CLEE6TNH.js.map +0 -1
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { readManifestSourceConfig, discoverAssetsInTree, barePublisher, createDefaultKindRegistry, sharesItsFolder, SEMVER_RE, parseManifestFile } from './chunk-
|
|
2
|
-
import { installFromManifest, assertSafeManifestPath } from './chunk-
|
|
3
|
-
import { PresetManifestSchema } from './chunk-
|
|
4
|
-
import { defaultLibraryDir, resolveLibraryDir, GLOBAL_INSTALL_DIR_NAME, readLock, buildLibraryLockEntries, writeLock, mergeLockFile, buildLockFile, ManifestYamlEditor } from './chunk-
|
|
5
|
-
import { getGlobalCacheDir, storeManifestSlug, resolveSourcePublisher } from './chunk-
|
|
1
|
+
import { readManifestSourceConfig, discoverAssetsInTree, barePublisher, createDefaultKindRegistry, sharesItsFolder, SEMVER_RE, parseManifestFile } from './chunk-7CR2OZPA.js';
|
|
2
|
+
import { installFromManifest, assertSafeManifestPath } from './chunk-UTKENBB6.js';
|
|
3
|
+
import { PresetManifestSchema } from './chunk-6VLHITAM.js';
|
|
4
|
+
import { defaultLibraryDir, resolveLibraryDir, GLOBAL_INSTALL_DIR_NAME, readLock, buildLibraryLockEntries, writeLock, mergeLockFile, buildLockFile, ManifestYamlEditor } from './chunk-T5TSLSRO.js';
|
|
5
|
+
import { getGlobalCacheDir, storeManifestSlug, resolveSourcePublisher } from './chunk-PNOGX36L.js';
|
|
6
6
|
import { userConfigPath, globalSkaileDir, mergeLegacyEntriesInto, migrateLegacyDir, globalCacheRoot } from './chunk-L5VSIPQD.js';
|
|
7
|
-
import { encodeSkaileManifest, loadSkPublishManifest, SKAILE_MANIFEST_FILENAME } from './chunk-
|
|
8
|
-
import { scanDirectory } from './chunk-
|
|
9
|
-
import { parseAssetRef, assetRefToStr } from './chunk-
|
|
7
|
+
import { encodeSkaileManifest, loadSkPublishManifest, SKAILE_MANIFEST_FILENAME } from './chunk-CTP3XBMF.js';
|
|
8
|
+
import { scanDirectory } from './chunk-XTVSNWLL.js';
|
|
9
|
+
import { parseAssetRef, assetRefToStr } from './chunk-PNTXHTBC.js';
|
|
10
10
|
import { __export } from './chunk-NSBPE2FW.js';
|
|
11
11
|
import * as fs11 from 'fs';
|
|
12
12
|
import { existsSync, mkdirSync, symlinkSync, copyFileSync, cpSync } from 'fs';
|
|
@@ -20,6 +20,7 @@ import { createClient } from '@libsql/client';
|
|
|
20
20
|
import { drizzle } from 'drizzle-orm/libsql';
|
|
21
21
|
import { sqliteTable, text, integer } from 'drizzle-orm/sqlite-core';
|
|
22
22
|
import { spawnSync } from 'child_process';
|
|
23
|
+
import { valid, gt } from 'semver';
|
|
23
24
|
import { isDeepStrictEqual } from 'util';
|
|
24
25
|
|
|
25
26
|
// library/src/library.ts
|
|
@@ -369,6 +370,31 @@ function curatedManifestOverlay(sourceUrl) {
|
|
|
369
370
|
const file = path16.join(getStoreManifestsDir(), `${storeManifestSlug(sourceUrl)}.yaml`);
|
|
370
371
|
return fs11.existsSync(file) ? file : void 0;
|
|
371
372
|
}
|
|
373
|
+
function commitStoreManifest(file, message) {
|
|
374
|
+
const root = getStoreRoot();
|
|
375
|
+
try {
|
|
376
|
+
const rel = path16.relative(root, file);
|
|
377
|
+
if (rel.startsWith("..") || path16.isAbsolute(rel)) return false;
|
|
378
|
+
initStoreGitRepo(root);
|
|
379
|
+
const run = (args) => spawnSync(
|
|
380
|
+
"git",
|
|
381
|
+
[
|
|
382
|
+
"-c",
|
|
383
|
+
"user.name=skaile",
|
|
384
|
+
"-c",
|
|
385
|
+
"user.email=skaile@localhost",
|
|
386
|
+
"-c",
|
|
387
|
+
"commit.gpgsign=false",
|
|
388
|
+
...args
|
|
389
|
+
],
|
|
390
|
+
{ cwd: root, stdio: "ignore" }
|
|
391
|
+
);
|
|
392
|
+
if (run(["add", "--", rel]).status !== 0) return false;
|
|
393
|
+
return run(["commit", "--quiet", "-m", message, "--only", "--", rel]).status === 0;
|
|
394
|
+
} catch {
|
|
395
|
+
return false;
|
|
396
|
+
}
|
|
397
|
+
}
|
|
372
398
|
function migratedMarkerPath() {
|
|
373
399
|
return path16.join(getStoreRoot(), ".migrated");
|
|
374
400
|
}
|
|
@@ -693,6 +719,7 @@ function assertNoLegacyLibDb(newDbPath) {
|
|
|
693
719
|
);
|
|
694
720
|
}
|
|
695
721
|
}
|
|
722
|
+
var INDEX_BUSY_TIMEOUT_MS = 5e3;
|
|
696
723
|
async function createLibraryDb(dbPath) {
|
|
697
724
|
assertNoLegacyLibDb(dbPath);
|
|
698
725
|
try {
|
|
@@ -704,6 +731,7 @@ async function createLibraryDb(dbPath) {
|
|
|
704
731
|
);
|
|
705
732
|
}
|
|
706
733
|
const client = createClient({ url: `file:${dbPath}` });
|
|
734
|
+
await client.execute(`PRAGMA busy_timeout = ${INDEX_BUSY_TIMEOUT_MS}`);
|
|
707
735
|
await client.execute("PRAGMA journal_mode = WAL");
|
|
708
736
|
await client.execute("PRAGMA foreign_keys = ON");
|
|
709
737
|
if (await legacySourcesPresent(client) && !await librariesPresent(client)) {
|
|
@@ -890,7 +918,10 @@ var LocalIndex = class {
|
|
|
890
918
|
this.dbHandleRef = null;
|
|
891
919
|
this.dbPromise = null;
|
|
892
920
|
}
|
|
893
|
-
/**
|
|
921
|
+
/**
|
|
922
|
+
* Internal access for LibraryManager. Do not call from user code. Typed `unknown`
|
|
923
|
+
* so the published `.d.ts` pulls in no drizzle types (p461); the manager casts it.
|
|
924
|
+
*/
|
|
894
925
|
async dbHandle() {
|
|
895
926
|
return this.ensureDb();
|
|
896
927
|
}
|
|
@@ -1260,6 +1291,59 @@ function clearLibraryUnregistered(lib) {
|
|
|
1260
1291
|
else fs11.writeFileSync(file, `${keep.join("\n")}
|
|
1261
1292
|
`, "utf8");
|
|
1262
1293
|
}
|
|
1294
|
+
var RENAMED_FILE = ".renamed-libraries";
|
|
1295
|
+
function readRenames() {
|
|
1296
|
+
const out = /* @__PURE__ */ new Map();
|
|
1297
|
+
try {
|
|
1298
|
+
for (const line of fs11.readFileSync(path16.join(resolveLibraryDir(), RENAMED_FILE), "utf8").split("\n")) {
|
|
1299
|
+
const [from, to] = line.split(" ").map((s) => s.trim());
|
|
1300
|
+
if (from && to && from !== to) out.set(from, to);
|
|
1301
|
+
}
|
|
1302
|
+
} catch {
|
|
1303
|
+
}
|
|
1304
|
+
return out;
|
|
1305
|
+
}
|
|
1306
|
+
function writeRenames(renames) {
|
|
1307
|
+
const file = path16.join(resolveLibraryDir(), RENAMED_FILE);
|
|
1308
|
+
if (renames.size === 0) {
|
|
1309
|
+
fs11.rmSync(file, { force: true });
|
|
1310
|
+
return;
|
|
1311
|
+
}
|
|
1312
|
+
fs11.mkdirSync(resolveLibraryDir(), { recursive: true });
|
|
1313
|
+
fs11.writeFileSync(
|
|
1314
|
+
file,
|
|
1315
|
+
`${[...renames].map(([from, to]) => `${from} ${to}`).join("\n")}
|
|
1316
|
+
`,
|
|
1317
|
+
"utf8"
|
|
1318
|
+
);
|
|
1319
|
+
}
|
|
1320
|
+
function recordLibraryRename(from, to) {
|
|
1321
|
+
if (from === to) return;
|
|
1322
|
+
const renames = readRenames();
|
|
1323
|
+
for (const [k, v] of renames) if (v === from) renames.set(k, to);
|
|
1324
|
+
renames.delete(to);
|
|
1325
|
+
renames.set(from, to);
|
|
1326
|
+
for (const [k, v] of renames) if (k === v) renames.delete(k);
|
|
1327
|
+
writeRenames(renames);
|
|
1328
|
+
}
|
|
1329
|
+
function renamedLibraryName(name) {
|
|
1330
|
+
return readRenames().get(name);
|
|
1331
|
+
}
|
|
1332
|
+
function clearLibraryRenamed(name) {
|
|
1333
|
+
const renames = readRenames();
|
|
1334
|
+
if (renames.delete(name)) writeRenames(renames);
|
|
1335
|
+
}
|
|
1336
|
+
function dropLibraryRenamesTo(name) {
|
|
1337
|
+
const renames = readRenames();
|
|
1338
|
+
let changed = false;
|
|
1339
|
+
for (const [from, to] of renames) {
|
|
1340
|
+
if (to === name) {
|
|
1341
|
+
renames.delete(from);
|
|
1342
|
+
changed = true;
|
|
1343
|
+
}
|
|
1344
|
+
}
|
|
1345
|
+
if (changed) writeRenames(renames);
|
|
1346
|
+
}
|
|
1263
1347
|
|
|
1264
1348
|
// library/src/user-library.ts
|
|
1265
1349
|
var LIBRARY_BACKENDS = ["local", "git"];
|
|
@@ -1374,6 +1458,13 @@ function rebaseInProgress(cwd) {
|
|
|
1374
1458
|
return false;
|
|
1375
1459
|
}
|
|
1376
1460
|
var REBASE_IN_PROGRESS = "rebase in progress; finish it with git rebase --continue";
|
|
1461
|
+
var MERGE_IN_PROGRESS = "merge in progress; resolve the conflicts, then git commit";
|
|
1462
|
+
function mergeInProgress(cwd) {
|
|
1463
|
+
const head = git(cwd, ["rev-parse", "--git-path", "MERGE_HEAD"]);
|
|
1464
|
+
if (head.status === 0 && existsSync(path16.resolve(cwd, head.stdout.trim()))) return true;
|
|
1465
|
+
const unmerged = git(cwd, ["ls-files", "--unmerged"]);
|
|
1466
|
+
return unmerged.status === 0 && unmerged.stdout.trim() !== "";
|
|
1467
|
+
}
|
|
1377
1468
|
function assertLibraryDir(lib) {
|
|
1378
1469
|
if (libraryDirMissing(lib)) {
|
|
1379
1470
|
throw new LibrarySyncError(missingLibraryDirMessage(lib), "library_dir_missing");
|
|
@@ -1382,6 +1473,7 @@ function assertLibraryDir(lib) {
|
|
|
1382
1473
|
function assertNoRebase(lib) {
|
|
1383
1474
|
assertLibraryDir(lib);
|
|
1384
1475
|
if (rebaseInProgress(lib.path)) throw new LibrarySyncError(REBASE_IN_PROGRESS, "remote_error");
|
|
1476
|
+
if (mergeInProgress(lib.path)) throw new LibrarySyncError(MERGE_IN_PROGRESS, "remote_error");
|
|
1385
1477
|
}
|
|
1386
1478
|
function ok(r, action) {
|
|
1387
1479
|
if (r.status !== 0) {
|
|
@@ -1500,6 +1592,13 @@ var GitSyncDriver = class {
|
|
|
1500
1592
|
}
|
|
1501
1593
|
assertNoRebase(lib);
|
|
1502
1594
|
const cfg = gitCfg(lib);
|
|
1595
|
+
if (git(lib.path, ["rev-parse", "--verify", "--quiet", `refs/heads/${cfg.branch}`]).status !== 0) {
|
|
1596
|
+
const current = git(lib.path, ["symbolic-ref", "--short", "-q", "HEAD"]).stdout.trim();
|
|
1597
|
+
throw new LibrarySyncError(
|
|
1598
|
+
current && current !== cfg.branch ? `no local branch "${cfg.branch}" in ${lib.name} (it is on "${current}"); run skaile library set ${lib.name} backendConfig.branch=${current}` : `no local branch "${cfg.branch}" in ${lib.name}; commit something on it first`,
|
|
1599
|
+
"remote_error"
|
|
1600
|
+
);
|
|
1601
|
+
}
|
|
1503
1602
|
const args = ["push", "origin", cfg.branch];
|
|
1504
1603
|
if (opts?.force) args.push("--force-with-lease");
|
|
1505
1604
|
const countRef = "refs/skaile/push-base";
|
|
@@ -1518,9 +1617,16 @@ var GitSyncDriver = class {
|
|
|
1518
1617
|
const baseRef = fetched.status === 0 || remoteHasNoBranch ? countRef : trackingRef;
|
|
1519
1618
|
const local = `refs/heads/${cfg.branch}`;
|
|
1520
1619
|
const pushed = countCommits(lib.path, `${baseRef}..${local}`) ?? countCommits(lib.path, local) ?? 0;
|
|
1620
|
+
const behind = remoteHasNoBranch ? 0 : countCommits(lib.path, `${local}..${baseRef}`) ?? 0;
|
|
1521
1621
|
git(lib.path, ["update-ref", "-d", countRef]);
|
|
1522
1622
|
const pushRes = git(lib.path, args);
|
|
1523
1623
|
if (pushRes.status !== 0 && /non-fast-forward|fetch first|updates were rejected/i.test(pushRes.stderr)) {
|
|
1624
|
+
if (pushed === 0 && behind > 0) {
|
|
1625
|
+
throw new LibrarySyncError(
|
|
1626
|
+
`behind origin by ${behind} commit(s); run skaile library pull ${lib.name}`,
|
|
1627
|
+
"remote_error"
|
|
1628
|
+
);
|
|
1629
|
+
}
|
|
1524
1630
|
throw new LibrarySyncError(
|
|
1525
1631
|
`local and remote both changed; run skaile library git ${lib.name} pull --rebase origin ${cfg.branch}`,
|
|
1526
1632
|
"remote_error"
|
|
@@ -1652,6 +1758,13 @@ var LibraryManager = class {
|
|
|
1652
1758
|
lib;
|
|
1653
1759
|
localDrv = new LocalSyncDriver();
|
|
1654
1760
|
gitDrv = new GitSyncDriver();
|
|
1761
|
+
/**
|
|
1762
|
+
* The index's drizzle handle. `LocalIndex.dbHandle()` is typed `unknown` so the
|
|
1763
|
+
* published `.d.ts` pulls in no drizzle types; the type lives here.
|
|
1764
|
+
*/
|
|
1765
|
+
async db() {
|
|
1766
|
+
return await this.lib.dbHandle();
|
|
1767
|
+
}
|
|
1655
1768
|
/** Resolve the sync driver for a given backend. */
|
|
1656
1769
|
driverFor(backend) {
|
|
1657
1770
|
switch (backend) {
|
|
@@ -1663,7 +1776,7 @@ var LibraryManager = class {
|
|
|
1663
1776
|
}
|
|
1664
1777
|
async addLibrary(input) {
|
|
1665
1778
|
assertValidLibraryName(input.name);
|
|
1666
|
-
const db = await this.
|
|
1779
|
+
const db = await this.db();
|
|
1667
1780
|
const existing = await db.select().from(libraries).where(eq(libraries.name, input.name)).get();
|
|
1668
1781
|
if (existing) throw new DuplicateLibraryNameError(input.name);
|
|
1669
1782
|
const id = crypto.randomUUID();
|
|
@@ -1684,15 +1797,16 @@ var LibraryManager = class {
|
|
|
1684
1797
|
updatedAt: now
|
|
1685
1798
|
}).run();
|
|
1686
1799
|
clearLibraryUnregistered({ name: input.name, path: input.path });
|
|
1800
|
+
clearLibraryRenamed(input.name);
|
|
1687
1801
|
return this.requireLibrary(id);
|
|
1688
1802
|
}
|
|
1689
1803
|
async listLibraries() {
|
|
1690
|
-
const db = await this.
|
|
1804
|
+
const db = await this.db();
|
|
1691
1805
|
const rows = await db.select().from(libraries).all();
|
|
1692
1806
|
return rows.map(rowToLibrary2).sort((a, b) => a.createdAt.getTime() - b.createdAt.getTime());
|
|
1693
1807
|
}
|
|
1694
1808
|
async getLibrary(nameOrId) {
|
|
1695
|
-
const db = await this.
|
|
1809
|
+
const db = await this.db();
|
|
1696
1810
|
let row = await db.select().from(libraries).where(eq(libraries.name, nameOrId)).get();
|
|
1697
1811
|
if (!row) {
|
|
1698
1812
|
row = await db.select().from(libraries).where(eq(libraries.id, nameOrId)).get();
|
|
@@ -1720,7 +1834,7 @@ var LibraryManager = class {
|
|
|
1720
1834
|
async updateLibrary(nameOrId, patch) {
|
|
1721
1835
|
const lib = await this.requireLibrary(nameOrId);
|
|
1722
1836
|
if (patch.name !== void 0 && patch.name !== lib.name) assertValidLibraryName(patch.name);
|
|
1723
|
-
const db = await this.
|
|
1837
|
+
const db = await this.db();
|
|
1724
1838
|
const updates = {
|
|
1725
1839
|
updatedAt: (/* @__PURE__ */ new Date()).toISOString()
|
|
1726
1840
|
};
|
|
@@ -1734,6 +1848,9 @@ var LibraryManager = class {
|
|
|
1734
1848
|
if (patch.isDefault !== void 0) updates.isDefault = patch.isDefault;
|
|
1735
1849
|
if (patch.lastSyncAt !== void 0) updates.lastSyncAt = patch.lastSyncAt.toISOString();
|
|
1736
1850
|
await db.update(libraries).set(updates).where(eq(libraries.id, lib.id)).run();
|
|
1851
|
+
if (patch.name !== void 0 && patch.name !== lib.name) {
|
|
1852
|
+
recordLibraryRename(lib.name, patch.name);
|
|
1853
|
+
}
|
|
1737
1854
|
return this.requireLibrary(lib.id);
|
|
1738
1855
|
}
|
|
1739
1856
|
/**
|
|
@@ -1751,7 +1868,7 @@ var LibraryManager = class {
|
|
|
1751
1868
|
}
|
|
1752
1869
|
async setDefault(nameOrId) {
|
|
1753
1870
|
const lib = await this.requireLibrary(nameOrId);
|
|
1754
|
-
const db = await this.
|
|
1871
|
+
const db = await this.db();
|
|
1755
1872
|
await db.update(libraries).set({ isDefault: false }).run();
|
|
1756
1873
|
await db.update(libraries).set({ isDefault: true, updatedAt: (/* @__PURE__ */ new Date()).toISOString() }).where(eq(libraries.id, lib.id)).run();
|
|
1757
1874
|
return this.requireLibrary(lib.id);
|
|
@@ -1762,6 +1879,7 @@ var LibraryManager = class {
|
|
|
1762
1879
|
if (opts.purge && fs11.existsSync(lib.path)) {
|
|
1763
1880
|
fs11.rmSync(lib.path, { recursive: true, force: true });
|
|
1764
1881
|
}
|
|
1882
|
+
dropLibraryRenamesTo(lib.name);
|
|
1765
1883
|
if (!opts.purge) markLibraryUnregistered(lib);
|
|
1766
1884
|
}
|
|
1767
1885
|
/**
|
|
@@ -1948,19 +2066,10 @@ var LocalCatalogSource = class {
|
|
|
1948
2066
|
errors.push(`${err.path}: ${err.error}`);
|
|
1949
2067
|
}
|
|
1950
2068
|
const advisories = [];
|
|
1951
|
-
let missingSha256Count = 0;
|
|
1952
2069
|
for (const w of result.warnings) {
|
|
1953
|
-
if (w.code === "missing_sha256")
|
|
1954
|
-
missingSha256Count++;
|
|
1955
|
-
continue;
|
|
1956
|
-
}
|
|
2070
|
+
if (w.code === "missing_sha256") continue;
|
|
1957
2071
|
advisories.push(`${w.path}: ${w.warning}`);
|
|
1958
2072
|
}
|
|
1959
|
-
if (missingSha256Count > 0) {
|
|
1960
|
-
advisories.push(
|
|
1961
|
-
`${missingSha256Count} asset(s): sha256 not pinned \u2014 auto-computed locally (pin only for store publish)`
|
|
1962
|
-
);
|
|
1963
|
-
}
|
|
1964
2073
|
const keepRefs = assets.map((a) => a.ref);
|
|
1965
2074
|
let pruned = [];
|
|
1966
2075
|
if (!syncOpts?.only && result.assets.length > 0) {
|
|
@@ -3230,8 +3339,6 @@ function sha256Hex(bytes) {
|
|
|
3230
3339
|
h.update(bytes);
|
|
3231
3340
|
return h.digest("hex");
|
|
3232
3341
|
}
|
|
3233
|
-
|
|
3234
|
-
// library/src/remote/remote-catalog-source.ts
|
|
3235
3342
|
var TarballHashMismatchError = class extends Error {
|
|
3236
3343
|
constructor(expected, actual) {
|
|
3237
3344
|
super(`SHA256 mismatch: expected ${expected}, got ${actual}`);
|
|
@@ -3258,6 +3365,19 @@ var CatalogHttpError = class extends Error {
|
|
|
3258
3365
|
status;
|
|
3259
3366
|
url;
|
|
3260
3367
|
};
|
|
3368
|
+
function describeCatalogError(err, baseUrl) {
|
|
3369
|
+
if (err instanceof OfflineError) return err.message;
|
|
3370
|
+
if (err instanceof CatalogHttpError) {
|
|
3371
|
+
return err.status >= 400 && err.status < 600 && !err.message.startsWith("tRPC") ? `${baseUrl} answered ${err.status} (${err.message})` : `${baseUrl}: ${err.message}`;
|
|
3372
|
+
}
|
|
3373
|
+
const e = err;
|
|
3374
|
+
if (e?.name === "TimeoutError" || e?.name === "AbortError") {
|
|
3375
|
+
return `no answer from ${baseUrl} within ${CATALOG_REQUEST_TIMEOUT_MS / 1e3} s`;
|
|
3376
|
+
}
|
|
3377
|
+
const cause = e?.cause;
|
|
3378
|
+
const why = cause?.code ?? cause?.message ?? e?.message ?? String(err);
|
|
3379
|
+
return `cannot reach ${baseUrl} (${why})`;
|
|
3380
|
+
}
|
|
3261
3381
|
var DEFAULT_TTL_MS = 864e5;
|
|
3262
3382
|
var RemoteCatalogSource = class {
|
|
3263
3383
|
id;
|
|
@@ -3301,6 +3421,8 @@ var RemoteCatalogSource = class {
|
|
|
3301
3421
|
if (this.cache.airGapped) {
|
|
3302
3422
|
const stale2 = this.cache.getResolveStale(ref);
|
|
3303
3423
|
if (stale2) return stale2.value;
|
|
3424
|
+
const listed = this.cachedListedAsset(ref);
|
|
3425
|
+
if (listed) return listed;
|
|
3304
3426
|
throw new OfflineError(`Asset '${ref}' not in cache`);
|
|
3305
3427
|
}
|
|
3306
3428
|
const stale = this.cache.getResolveStale(ref);
|
|
@@ -3312,9 +3434,42 @@ var RemoteCatalogSource = class {
|
|
|
3312
3434
|
return await this.fetchAndStoreResolve(ref);
|
|
3313
3435
|
} catch (err) {
|
|
3314
3436
|
if (stale) return stale.value;
|
|
3437
|
+
const listed = this.cachedListedAsset(ref);
|
|
3438
|
+
if (listed) return listed;
|
|
3315
3439
|
throw err;
|
|
3316
3440
|
}
|
|
3317
3441
|
}
|
|
3442
|
+
/**
|
|
3443
|
+
* The row for `ref` from the cached, unfiltered catalog list (fresh or stale), or `null`.
|
|
3444
|
+
* A version-less ref takes the highest listed version. Never touches the network.
|
|
3445
|
+
*/
|
|
3446
|
+
cachedListedAsset(ref) {
|
|
3447
|
+
const all = this.cache.getList(void 0) ?? this.cache.getListStale(void 0);
|
|
3448
|
+
if (!all) return null;
|
|
3449
|
+
const want = parseAssetRef(ref);
|
|
3450
|
+
const bare = (p) => p?.replace(/^@/, "");
|
|
3451
|
+
const hits = all.items.filter(
|
|
3452
|
+
(a) => a.kind === want.kind && a.name === want.name && (want.publisher === void 0 || bare(a.publisher) === bare(want.publisher)) && (want.pin === void 0 || a.version === want.pin)
|
|
3453
|
+
);
|
|
3454
|
+
if (hits.length === 0) return null;
|
|
3455
|
+
return hits.reduce(
|
|
3456
|
+
(best, a) => valid(a.version) && valid(best.version) && gt(a.version, best.version) ? a : best
|
|
3457
|
+
);
|
|
3458
|
+
}
|
|
3459
|
+
/**
|
|
3460
|
+
* `filter` applied to the cached, unfiltered catalog list (fresh or stale), or `null` when
|
|
3461
|
+
* that list is not cached or `filter` is empty. A `--kind` / publisher query needs no
|
|
3462
|
+
* round trip once the whole list is on disk.
|
|
3463
|
+
*/
|
|
3464
|
+
cachedListFiltered(filter) {
|
|
3465
|
+
if (!filter || !filter.kind && !filter.publisher && !filter.prefix) return null;
|
|
3466
|
+
const all = this.cache.getList(void 0) ?? this.cache.getListStale(void 0);
|
|
3467
|
+
if (!all) return null;
|
|
3468
|
+
const bare = (p) => p.replace(/^@/, "");
|
|
3469
|
+
return all.items.filter(
|
|
3470
|
+
(a) => (!filter.kind || a.kind === filter.kind) && (!filter.publisher || bare(a.publisher) === bare(filter.publisher)) && (!filter.prefix || `${bare(a.publisher)}/${a.name}`.startsWith(filter.prefix))
|
|
3471
|
+
);
|
|
3472
|
+
}
|
|
3318
3473
|
/**
|
|
3319
3474
|
* Fetch `ref` from the store, bypassing the resolve cache, and cache the answer.
|
|
3320
3475
|
* For a caller that knows the cached answer is wrong, e.g. a cached miss for an
|
|
@@ -3340,6 +3495,8 @@ var RemoteCatalogSource = class {
|
|
|
3340
3495
|
if (this.cache.airGapped) {
|
|
3341
3496
|
const stale2 = this.cache.getListStale(filter);
|
|
3342
3497
|
if (stale2) return stale2.items;
|
|
3498
|
+
const subset = this.cachedListFiltered(filter);
|
|
3499
|
+
if (subset) return subset;
|
|
3343
3500
|
throw new OfflineError("Catalog list not in cache");
|
|
3344
3501
|
}
|
|
3345
3502
|
const stale = this.cache.getListStale(filter);
|
|
@@ -3348,7 +3505,13 @@ var RemoteCatalogSource = class {
|
|
|
3348
3505
|
this.scheduleBackground(`list:${filterKey2}`, () => this.fetchAndStoreList(filter));
|
|
3349
3506
|
return stale.items;
|
|
3350
3507
|
}
|
|
3351
|
-
|
|
3508
|
+
try {
|
|
3509
|
+
return await this.fetchAndStoreList(filter);
|
|
3510
|
+
} catch (err) {
|
|
3511
|
+
const subset = this.cachedListFiltered(filter);
|
|
3512
|
+
if (subset) return subset;
|
|
3513
|
+
throw err;
|
|
3514
|
+
}
|
|
3352
3515
|
}
|
|
3353
3516
|
/**
|
|
3354
3517
|
* Fetch the content-addressed tarball for an asset. The bytes are downloaded
|
|
@@ -3452,6 +3615,9 @@ var RemoteCatalogSource = class {
|
|
|
3452
3615
|
* @throws {@link CatalogHttpError} on a non-2xx response or malformed envelope.
|
|
3453
3616
|
*/
|
|
3454
3617
|
async getInstallManifest(ref) {
|
|
3618
|
+
if (this.cache.airGapped) {
|
|
3619
|
+
throw new OfflineError(`Install manifest of '${ref}' is not cached`);
|
|
3620
|
+
}
|
|
3455
3621
|
const url = trpcGetUrl(this.baseUrl, "catalog.getInstallManifest", { ref });
|
|
3456
3622
|
const res = await this.httpClient(url, {
|
|
3457
3623
|
method: "GET",
|
|
@@ -3489,6 +3655,9 @@ var RemoteCatalogSource = class {
|
|
|
3489
3655
|
* @docLink packages/library/api-reference#remote-catalog-source
|
|
3490
3656
|
*/
|
|
3491
3657
|
async getCanonicalDigest(ref) {
|
|
3658
|
+
if (this.cache.airGapped) {
|
|
3659
|
+
throw new OfflineError(`Canonical digest of '${ref}' is not cached`);
|
|
3660
|
+
}
|
|
3492
3661
|
const url = trpcGetUrl(this.baseUrl, "catalog.getCanonicalDigest", { ref });
|
|
3493
3662
|
const res = await this.httpClient(url, {
|
|
3494
3663
|
method: "GET",
|
|
@@ -4077,6 +4246,7 @@ function writeCuratedManifest(input) {
|
|
|
4077
4246
|
fs11.writeFileSync(manifestPath, encodeSkaileManifest(manifest), "utf-8");
|
|
4078
4247
|
return { wrote: true, manifestPath, assetCount: assets.length };
|
|
4079
4248
|
}
|
|
4249
|
+
var DEFAULT_ASSET_VERSION = "0.1.0";
|
|
4080
4250
|
function openManifest(libraryPath) {
|
|
4081
4251
|
const dir = path16.resolve(libraryPath);
|
|
4082
4252
|
const file = path16.join(dir, SKAILE_MANIFEST_FILENAME);
|
|
@@ -4257,7 +4427,9 @@ async function syncManifestWithDisk(libraryPath, defaultPublisher, registry, opt
|
|
|
4257
4427
|
kind: e.kind,
|
|
4258
4428
|
name: e.name,
|
|
4259
4429
|
root,
|
|
4260
|
-
version
|
|
4430
|
+
// A file with no version of its own (AGENT.md) reads as 0.1.0 in every library; the
|
|
4431
|
+
// manifest entry is where that version is kept.
|
|
4432
|
+
version: e.version || DEFAULT_ASSET_VERSION
|
|
4261
4433
|
});
|
|
4262
4434
|
}
|
|
4263
4435
|
return { removed, unknownKind, skipped, failed };
|
|
@@ -4416,6 +4588,6 @@ function detectWorkspaceVersion(dir, filename = "skaile.yaml") {
|
|
|
4416
4588
|
return raw.version === 2 ? 2 : 1;
|
|
4417
4589
|
}
|
|
4418
4590
|
|
|
4419
|
-
export { AssignmentNotFoundError, CatalogCache, CatalogConfigSchema, CatalogHttpError, DuplicateAssignmentError, DuplicateLibraryNameError, GitSyncDriver, InstanceHasConsumersError, InstanceNotFoundError, InterpolationError, KnowledgeManifestSchema, LIBRARY_BACKENDS, LIBRARY_OWNERSHIPS, LOCAL_CATALOG_URL, LibraryConfigSchema, LibraryError, LibraryInstanceRefSchema, LibraryManager, LibrarySectionSchema, LibrarySyncError, LocalCatalogSource, LocalIndex, LocalSyncDriver, LockAssignmentSchema, LockFileSchema, OfflineError, OperationNotPermittedError, PIN_POLICIES, PinPolicySchema, PresetAppliedSchema, PresetExpandedSchema, RemoteCatalogSource, RequiresEdgeSchema, RestCatalogSource, SidecarGit, SkaileConfigSchema, SourceNotFoundError, TarballHashMismatchError, UserLibraryNotFoundError, WorkspaceConfigV2Schema, applyNonStructuralUpgrade, applyPreset, applyPresetFromData, assertManifestEditable, assertValidLibraryName, classifyRef, cloneOrInitGitRepo, conflictingAssetRoot, createEmptyLockFile, curatedManifestOverlay, deriveSlug, detectChanges, detectNestedPresetRefs, detectWorkspaceVersion, ensureGitRepo, evaluateUpgrade, extractLibraryInstanceId, extractReferencedKeys, filterKey, getConfigDefaults, getDefaultValue, getSidecarRoot, getStoreManifestsDir, getStoreRoot, hasInterpolationTokens, installLibraryAsset, interpolate, isGitRepo, isLocalCatalogUrl, isSecretPlaceholder, knowledgeKindProvider, libraryDirMissing, listSidecarSlugsOnDisk, loadLockFile, loadWorkspaceV2, markLibraryUnregistered, migrateSidecarsToStoreIfNeeded, migrateWorkspaceConfig, missingLibraryDirMessage, missingRootAssets, parsePreset, parsePresetYaml, parseWorkspaceV2, projectConfigPath, pruneMissingRootAssets, queryInstancePickerChoices, resolveAllItems, resolveConfig, resolveIndexPath, resolveItem, resolvePin, resolveSidecarPaths, saveConfig, saveLockFile, saveWorkspaceV2, scanAuthoringLibraries, scanLibraryRoot, scanUnlistedAssets, setManifestPublisher, setOriginUrl, sha256Hex, stampManifestPublisher, storeSecrets, syncManifestWithDisk, trackOriginBranch, trpcGetUrl, unregisteredLibraryNames, upsertManifestAsset, validateAllPlaceholders, validateKnowledge, validateNestingDepth, validatePlaceholder, writeCuratedManifest };
|
|
4420
|
-
//# sourceMappingURL=chunk-
|
|
4421
|
-
//# sourceMappingURL=chunk-
|
|
4591
|
+
export { AssignmentNotFoundError, CatalogCache, CatalogConfigSchema, CatalogHttpError, DuplicateAssignmentError, DuplicateLibraryNameError, GitSyncDriver, InstanceHasConsumersError, InstanceNotFoundError, InterpolationError, KnowledgeManifestSchema, LIBRARY_BACKENDS, LIBRARY_OWNERSHIPS, LOCAL_CATALOG_URL, LibraryConfigSchema, LibraryError, LibraryInstanceRefSchema, LibraryManager, LibrarySectionSchema, LibrarySyncError, LocalCatalogSource, LocalIndex, LocalSyncDriver, LockAssignmentSchema, LockFileSchema, OfflineError, OperationNotPermittedError, PIN_POLICIES, PinPolicySchema, PresetAppliedSchema, PresetExpandedSchema, RemoteCatalogSource, RequiresEdgeSchema, RestCatalogSource, SidecarGit, SkaileConfigSchema, SourceNotFoundError, TarballHashMismatchError, UserLibraryNotFoundError, WorkspaceConfigV2Schema, applyNonStructuralUpgrade, applyPreset, applyPresetFromData, assertManifestEditable, assertValidLibraryName, classifyRef, cloneOrInitGitRepo, commitStoreManifest, conflictingAssetRoot, createEmptyLockFile, curatedManifestOverlay, deriveSlug, describeCatalogError, detectChanges, detectNestedPresetRefs, detectWorkspaceVersion, ensureGitRepo, evaluateUpgrade, extractLibraryInstanceId, extractReferencedKeys, filterKey, getConfigDefaults, getDefaultValue, getSidecarRoot, getStoreManifestsDir, getStoreRoot, hasInterpolationTokens, installLibraryAsset, interpolate, isGitRepo, isLocalCatalogUrl, isSecretPlaceholder, knowledgeKindProvider, libraryDirMissing, listSidecarSlugsOnDisk, loadLockFile, loadWorkspaceV2, markLibraryUnregistered, migrateSidecarsToStoreIfNeeded, migrateWorkspaceConfig, missingLibraryDirMessage, missingRootAssets, parsePreset, parsePresetYaml, parseWorkspaceV2, projectConfigPath, pruneMissingRootAssets, queryInstancePickerChoices, recordLibraryRename, renamedLibraryName, resolveAllItems, resolveConfig, resolveIndexPath, resolveItem, resolvePin, resolveSidecarPaths, saveConfig, saveLockFile, saveWorkspaceV2, scanAuthoringLibraries, scanLibraryRoot, scanUnlistedAssets, setManifestPublisher, setOriginUrl, sha256Hex, stampManifestPublisher, storeSecrets, syncManifestWithDisk, trackOriginBranch, trpcGetUrl, unregisteredLibraryNames, upsertManifestAsset, validateAllPlaceholders, validateKnowledge, validateNestingDepth, validatePlaceholder, writeCuratedManifest };
|
|
4592
|
+
//# sourceMappingURL=chunk-C3BMXXTN.js.map
|
|
4593
|
+
//# sourceMappingURL=chunk-C3BMXXTN.js.map
|