@skaile/workspaces 6.5.0 → 6.6.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 +8 -0
- package/dist/ai-sdk.js +9 -9
- package/dist/{asset-feeds-4I6Z4OI3.js → asset-feeds-WQ6YQPHV.js} +20 -20
- package/dist/{asset-feeds-4I6Z4OI3.js.map → asset-feeds-WQ6YQPHV.js.map} +1 -1
- package/dist/asset-manager/catalog-deployer.js +7 -7
- package/dist/asset-manager/index.js +12 -12
- package/dist/asset-manager/installer.js +8 -8
- package/dist/asset-manager/renderers.js +7 -7
- package/dist/bridge/harnesses/claude-sdk.js +10 -10
- package/dist/bridge/harnesses/codex.js +11 -11
- package/dist/bridge/harnesses/continue.js +10 -10
- package/dist/bridge/harnesses/echo.js +3 -3
- package/dist/bridge/harnesses/gemini.js +7 -7
- package/dist/bridge/harnesses/goose.js +10 -10
- package/dist/bridge/harnesses/omp.js +5 -5
- package/dist/bridge/harnesses/opencode.js +10 -10
- package/dist/bridge/harnesses/qwen.js +7 -7
- package/dist/bridge/index.js +15 -15
- package/dist/{chunk-J5JWLKLB.js → chunk-2TLPC6TQ.js} +11 -11
- package/dist/{chunk-J5JWLKLB.js.map → chunk-2TLPC6TQ.js.map} +1 -1
- package/dist/{chunk-2IAWVUW3.js → chunk-4BFEPZ6J.js} +4 -4
- package/dist/{chunk-2IAWVUW3.js.map → chunk-4BFEPZ6J.js.map} +1 -1
- package/dist/{chunk-KUADKMNX.js → chunk-4J7JQX4G.js} +4 -4
- package/dist/{chunk-KUADKMNX.js.map → chunk-4J7JQX4G.js.map} +1 -1
- package/dist/{chunk-USVUS4DJ.js → chunk-5ETYBC2X.js} +7 -7
- package/dist/{chunk-USVUS4DJ.js.map → chunk-5ETYBC2X.js.map} +1 -1
- package/dist/{chunk-X44XKBZX.js → chunk-5XHQBCB5.js} +3 -3
- package/dist/{chunk-X44XKBZX.js.map → chunk-5XHQBCB5.js.map} +1 -1
- package/dist/{chunk-OLHHN3NO.js → chunk-65UAC3ZR.js} +3 -3
- package/dist/{chunk-OLHHN3NO.js.map → chunk-65UAC3ZR.js.map} +1 -1
- package/dist/{chunk-7H4GTP7V.js → chunk-6A6HE5LW.js} +3 -3
- package/dist/{chunk-7H4GTP7V.js.map → chunk-6A6HE5LW.js.map} +1 -1
- package/dist/{chunk-UMLCKKIA.js → chunk-6ARPZHOV.js} +6 -6
- package/dist/{chunk-UMLCKKIA.js.map → chunk-6ARPZHOV.js.map} +1 -1
- package/dist/{chunk-K4DHYTUM.js → chunk-6RHWTZPT.js} +3 -3
- package/dist/{chunk-K4DHYTUM.js.map → chunk-6RHWTZPT.js.map} +1 -1
- package/dist/{chunk-IWKKTCXY.js → chunk-6SXSVKQY.js} +7 -5
- package/dist/chunk-6SXSVKQY.js.map +1 -0
- package/dist/{chunk-OBZ5WQ32.js → chunk-7I5PNB2G.js} +3 -3
- package/dist/{chunk-OBZ5WQ32.js.map → chunk-7I5PNB2G.js.map} +1 -1
- package/dist/{chunk-SRTWKZP2.js → chunk-7PVGND4J.js} +8 -8
- package/dist/{chunk-SRTWKZP2.js.map → chunk-7PVGND4J.js.map} +1 -1
- package/dist/{chunk-TROEC2Z2.js → chunk-7SJHSGUV.js} +16 -16
- package/dist/{chunk-TROEC2Z2.js.map → chunk-7SJHSGUV.js.map} +1 -1
- package/dist/{chunk-TNQLDEM6.js → chunk-AQNW2FET.js} +230 -35
- package/dist/chunk-AQNW2FET.js.map +1 -0
- package/dist/{chunk-6EKQENAP.js → chunk-B6N653ZG.js} +6 -6
- package/dist/{chunk-6EKQENAP.js.map → chunk-B6N653ZG.js.map} +1 -1
- package/dist/{chunk-NSIOBKDX.js → chunk-BSMW3PX2.js} +2 -2
- package/dist/{chunk-NSIOBKDX.js.map → chunk-BSMW3PX2.js.map} +1 -1
- package/dist/{chunk-HTGTNN2B.js → chunk-CMXDFTA2.js} +3 -3
- package/dist/{chunk-HTGTNN2B.js.map → chunk-CMXDFTA2.js.map} +1 -1
- package/dist/{chunk-2HS357RA.js → chunk-DI6J2PJB.js} +7 -7
- package/dist/{chunk-2HS357RA.js.map → chunk-DI6J2PJB.js.map} +1 -1
- package/dist/{chunk-T7HGEMNB.js → chunk-DS6UUCFG.js} +3 -3
- package/dist/{chunk-T7HGEMNB.js.map → chunk-DS6UUCFG.js.map} +1 -1
- package/dist/{chunk-23SG4JRV.js → chunk-E2EC6SAX.js} +3 -3
- package/dist/{chunk-23SG4JRV.js.map → chunk-E2EC6SAX.js.map} +1 -1
- package/dist/{chunk-ETF6Q3R3.js → chunk-EPXZQIC6.js} +3 -3
- package/dist/{chunk-ETF6Q3R3.js.map → chunk-EPXZQIC6.js.map} +1 -1
- package/dist/{chunk-SZTHSPRC.js → chunk-F4CZQD3T.js} +3 -3
- package/dist/{chunk-SZTHSPRC.js.map → chunk-F4CZQD3T.js.map} +1 -1
- package/dist/{chunk-AVFRFGM2.js → chunk-GNUA7XT2.js} +3 -2
- package/dist/chunk-GNUA7XT2.js.map +1 -0
- package/dist/{chunk-6Y3SC7O4.js → chunk-GTAHU4N4.js} +4 -4
- package/dist/{chunk-6Y3SC7O4.js.map → chunk-GTAHU4N4.js.map} +1 -1
- package/dist/{chunk-3KSLUVKB.js → chunk-GTGWRKMJ.js} +6 -6
- package/dist/{chunk-3KSLUVKB.js.map → chunk-GTGWRKMJ.js.map} +1 -1
- package/dist/{chunk-YRC2EFOU.js → chunk-HGZN6JLP.js} +4 -4
- package/dist/{chunk-YRC2EFOU.js.map → chunk-HGZN6JLP.js.map} +1 -1
- package/dist/{chunk-KYNCY3F3.js → chunk-HQAPUPBE.js} +3 -3
- package/dist/{chunk-KYNCY3F3.js.map → chunk-HQAPUPBE.js.map} +1 -1
- package/dist/{chunk-HPA3RP5E.js → chunk-I5IF3JCG.js} +3 -3
- package/dist/{chunk-HPA3RP5E.js.map → chunk-I5IF3JCG.js.map} +1 -1
- package/dist/{chunk-7EMS2GZO.js → chunk-J262X4JU.js} +12 -12
- package/dist/{chunk-7EMS2GZO.js.map → chunk-J262X4JU.js.map} +1 -1
- package/dist/{chunk-22ZX33H6.js → chunk-J4WKNJHO.js} +4 -4
- package/dist/{chunk-22ZX33H6.js.map → chunk-J4WKNJHO.js.map} +1 -1
- package/dist/{chunk-G4NCSYWR.js → chunk-JIQUF3X2.js} +4 -4
- package/dist/{chunk-G4NCSYWR.js.map → chunk-JIQUF3X2.js.map} +1 -1
- package/dist/{chunk-IS3NIZBX.js → chunk-JRVQV7WC.js} +11 -11
- package/dist/{chunk-IS3NIZBX.js.map → chunk-JRVQV7WC.js.map} +1 -1
- package/dist/{chunk-UZET67SO.js → chunk-LBJ4M5J2.js} +4 -4
- package/dist/{chunk-UZET67SO.js.map → chunk-LBJ4M5J2.js.map} +1 -1
- package/dist/{chunk-TGUMN5G7.js → chunk-MMOWIRHP.js} +8 -8
- package/dist/{chunk-TGUMN5G7.js.map → chunk-MMOWIRHP.js.map} +1 -1
- package/dist/{chunk-EO7KGX6P.js → chunk-MXI3XWV6.js} +4 -4
- package/dist/{chunk-EO7KGX6P.js.map → chunk-MXI3XWV6.js.map} +1 -1
- package/dist/{chunk-LE6QS4PG.js → chunk-N2PBAXAA.js} +3 -3
- package/dist/{chunk-LE6QS4PG.js.map → chunk-N2PBAXAA.js.map} +1 -1
- package/dist/{chunk-YBEJCQE5.js → chunk-O7QZI6MQ.js} +3 -3
- package/dist/{chunk-YBEJCQE5.js.map → chunk-O7QZI6MQ.js.map} +1 -1
- package/dist/{chunk-ZUU2PLA3.js → chunk-OY22B7E2.js} +3 -3
- package/dist/{chunk-ZUU2PLA3.js.map → chunk-OY22B7E2.js.map} +1 -1
- package/dist/{chunk-W5KCAWGN.js → chunk-PTJTOPE5.js} +3 -3
- package/dist/{chunk-W5KCAWGN.js.map → chunk-PTJTOPE5.js.map} +1 -1
- package/dist/{chunk-WFLQMAR5.js → chunk-RAU5QPI6.js} +5 -5
- package/dist/{chunk-WFLQMAR5.js.map → chunk-RAU5QPI6.js.map} +1 -1
- package/dist/{chunk-AFTZNR2W.js → chunk-RHCEX2EV.js} +3 -3
- package/dist/{chunk-AFTZNR2W.js.map → chunk-RHCEX2EV.js.map} +1 -1
- package/dist/{chunk-Z2X7UZEZ.js → chunk-SCRYXAHH.js} +6 -6
- package/dist/{chunk-Z2X7UZEZ.js.map → chunk-SCRYXAHH.js.map} +1 -1
- package/dist/{chunk-DKXNKFKP.js → chunk-SGI5MRKP.js} +75 -3
- package/dist/chunk-SGI5MRKP.js.map +1 -0
- package/dist/{chunk-KA2GLAPS.js → chunk-SHTXMERQ.js} +7 -7
- package/dist/{chunk-KA2GLAPS.js.map → chunk-SHTXMERQ.js.map} +1 -1
- package/dist/{chunk-SN663FCA.js → chunk-SZKCE7EC.js} +5 -5
- package/dist/{chunk-SN663FCA.js.map → chunk-SZKCE7EC.js.map} +1 -1
- package/dist/{chunk-S7DVT2BV.js → chunk-TCH5UDKT.js} +4 -4
- package/dist/{chunk-S7DVT2BV.js.map → chunk-TCH5UDKT.js.map} +1 -1
- package/dist/{chunk-THX5EE3K.js → chunk-TUFNY6OD.js} +3 -3
- package/dist/{chunk-THX5EE3K.js.map → chunk-TUFNY6OD.js.map} +1 -1
- package/dist/{chunk-EN5REMWV.js → chunk-U3UDOX6I.js} +4 -4
- package/dist/{chunk-EN5REMWV.js.map → chunk-U3UDOX6I.js.map} +1 -1
- package/dist/{chunk-3DA74PLW.js → chunk-USSP43U3.js} +3 -3
- package/dist/{chunk-3DA74PLW.js.map → chunk-USSP43U3.js.map} +1 -1
- package/dist/{chunk-U6KRTCNA.js → chunk-VJRL6ZK6.js} +3 -3
- package/dist/{chunk-U6KRTCNA.js.map → chunk-VJRL6ZK6.js.map} +1 -1
- package/dist/{chunk-B4BLJUYN.js → chunk-VXYZ5M7Z.js} +24 -18
- package/dist/{chunk-B4BLJUYN.js.map → chunk-VXYZ5M7Z.js.map} +1 -1
- package/dist/{chunk-E6UWI3TP.js → chunk-WW5NAU6N.js} +3 -3
- package/dist/{chunk-E6UWI3TP.js.map → chunk-WW5NAU6N.js.map} +1 -1
- package/dist/{chunk-J6YPKMMY.js → chunk-XD3RYAMR.js} +6 -6
- package/dist/{chunk-J6YPKMMY.js.map → chunk-XD3RYAMR.js.map} +1 -1
- package/dist/{chunk-DNXPXJ3X.js → chunk-XYCYGN3Q.js} +14 -14
- package/dist/{chunk-DNXPXJ3X.js.map → chunk-XYCYGN3Q.js.map} +1 -1
- package/dist/{chunk-B436SG5P.js → chunk-YN6N3RBM.js} +7 -7
- package/dist/{chunk-B436SG5P.js.map → chunk-YN6N3RBM.js.map} +1 -1
- package/dist/{chunk-TDPQOR3C.js → chunk-Z4FERR4U.js} +2 -2
- package/dist/{chunk-TDPQOR3C.js.map → chunk-Z4FERR4U.js.map} +1 -1
- package/dist/{claude-code-JY6CYEG7.js → claude-code-LZH7Y4Y5.js} +5 -5
- package/dist/{claude-code-JY6CYEG7.js.map → claude-code-LZH7Y4Y5.js.map} +1 -1
- package/dist/cli/index.js +91 -91
- package/dist/connectors/config.js +4 -4
- package/dist/connectors/index.js +18 -18
- package/dist/connectors/src/connector-manager.d.ts.map +1 -1
- package/dist/connectors/src/mount-ledger.d.ts.map +1 -1
- package/dist/{connectors-VLFOQNS6.js → connectors-HU5MHSUJ.js} +21 -21
- package/dist/{connectors-VLFOQNS6.js.map → connectors-HU5MHSUJ.js.map} +1 -1
- package/dist/core/index.js +6 -6
- package/dist/core/logging.js +1 -1
- package/dist/core/manifest.js +1 -1
- package/dist/core/publish-manifest.js +2 -2
- package/dist/core/runtime-assets.js +4 -4
- package/dist/core/src/logging/index.d.ts +1 -0
- package/dist/core/src/logging/index.d.ts.map +1 -1
- package/dist/core/src/logging/log-safe-text.d.ts +20 -0
- package/dist/core/src/logging/log-safe-text.d.ts.map +1 -0
- package/dist/core/src/manifest.d.ts.map +1 -1
- package/dist/core/src/workspace-config.d.ts +6 -0
- package/dist/core/src/workspace-config.d.ts.map +1 -1
- package/dist/core/workspace-config.js +3 -3
- package/dist/deploy/index.js +6 -6
- package/dist/discovery/index.js +3 -3
- package/dist/{ensure-sources-6O54DUQB.js → ensure-sources-CAMWJTMR.js} +24 -24
- package/dist/{ensure-sources-6O54DUQB.js.map → ensure-sources-CAMWJTMR.js.map} +1 -1
- package/dist/factory-assets/connectors/box.js +18 -18
- package/dist/factory-assets/connectors/deploy.js +18 -18
- package/dist/factory-assets/connectors/devserver.js +18 -18
- package/dist/factory-assets/connectors/flow/adapter.js +18 -18
- package/dist/factory-assets/connectors/flow/engine.js +7 -7
- package/dist/factory-assets/connectors/flow/run-flow.js +20 -20
- package/dist/factory-assets/connectors/flow.js +18 -18
- package/dist/factory-assets/connectors/git.js +18 -18
- package/dist/factory-assets/connectors/gmail.js +18 -18
- package/dist/factory-assets/connectors/googledrive.js +18 -18
- package/dist/factory-assets/connectors/local.js +18 -18
- package/dist/factory-assets/connectors/mattermost.js +18 -18
- package/dist/factory-assets/connectors/memory.js +18 -18
- package/dist/factory-assets/connectors/minio.js +18 -18
- package/dist/factory-assets/connectors/postgres.js +18 -18
- package/dist/factory-assets/connectors/s3.js +18 -18
- package/dist/factory-assets/connectors/sharepoint.js +18 -18
- package/dist/factory-assets/connectors/sqlite.js +18 -18
- package/dist/factory-assets/connectors/static-server.js +18 -18
- package/dist/factory-assets/connectors/tunnel.js +18 -18
- package/dist/factory-assets/connectors/webdav.js +18 -18
- package/dist/factory-assets/connectors/xstate-store.js +18 -18
- package/dist/factory-assets/connectors/xstate.js +18 -18
- package/dist/{flows-CIUPK7SB.js → flows-GVOVQGQW.js} +11 -11
- package/dist/{flows-CIUPK7SB.js.map → flows-GVOVQGQW.js.map} +1 -1
- package/dist/{helpers-YHDQHQEQ.js → helpers-WMCCODAV.js} +24 -24
- package/dist/{helpers-YHDQHQEQ.js.map → helpers-WMCCODAV.js.map} +1 -1
- package/dist/library/index.js +9 -9
- package/dist/library/install.js +3 -3
- package/dist/{library-publish-MUGUST43.js → library-publish-UQQMHTND.js} +49 -49
- package/dist/{library-publish-MUGUST43.js.map → library-publish-UQQMHTND.js.map} +1 -1
- package/dist/model-endpoint/index.js +9 -9
- package/dist/{open-library-BVQCB37E.js → open-library-OJ4HT2X4.js} +27 -27
- package/dist/{open-library-BVQCB37E.js.map → open-library-OJ4HT2X4.js.map} +1 -1
- package/dist/{open-registry-JCSIAKEC.js → open-registry-LWGIOJDK.js} +13 -13
- package/dist/{open-registry-JCSIAKEC.js.map → open-registry-LWGIOJDK.js.map} +1 -1
- package/dist/{paths-XLKCAFRZ.js → paths-FR2752HV.js} +9 -9
- package/dist/{paths-XLKCAFRZ.js.map → paths-FR2752HV.js.map} +1 -1
- package/dist/{plugin-store-NGRUTCJI.js → plugin-store-IALJUBN2.js} +9 -9
- package/dist/{plugin-store-NGRUTCJI.js.map → plugin-store-IALJUBN2.js.map} +1 -1
- package/dist/{project-BGYMLAS6.js → project-UQFCYHYS.js} +45 -45
- package/dist/{project-BGYMLAS6.js.map → project-UQFCYHYS.js.map} +1 -1
- package/dist/resolver/index.js +7 -7
- package/dist/runner/index.js +34 -34
- package/dist/runner/src/external-mcp.d.ts +22 -0
- package/dist/runner/src/external-mcp.d.ts.map +1 -1
- package/dist/runner/src/mcp-tools-snapshot.d.ts +13 -0
- package/dist/runner/src/mcp-tools-snapshot.d.ts.map +1 -0
- package/dist/runner/src/resources.d.ts +14 -0
- package/dist/runner/src/resources.d.ts.map +1 -1
- package/dist/runner/src/serve.d.ts.map +1 -1
- package/dist/sdk/asset-manager.js +12 -12
- package/dist/sdk/bridge.js +15 -15
- package/dist/sdk/core.js +6 -6
- package/dist/sdk/flow.js +7 -7
- package/dist/sdk/index.js +34 -34
- package/dist/sdk/resolver.js +7 -7
- package/dist/sdk/runner.js +34 -34
- package/dist/sdk/transport/ws/server.js +7 -7
- package/dist/sdk/transport/ws.js +7 -7
- package/dist/sdk/transport.js +7 -7
- package/dist/{serve-preflight-GQY5DZX6.js → serve-preflight-TYEKHC32.js} +27 -27
- package/dist/{serve-preflight-GQY5DZX6.js.map → serve-preflight-TYEKHC32.js.map} +1 -1
- package/dist/{setup-2NWSKSCO.js → setup-4JV2IMCB.js} +25 -25
- package/dist/{setup-2NWSKSCO.js.map → setup-4JV2IMCB.js.map} +1 -1
- package/dist/{skills-PXZOL2FZ.js → skills-6QTKFMLW.js} +12 -12
- package/dist/{skills-PXZOL2FZ.js.map → skills-6QTKFMLW.js.map} +1 -1
- package/dist/{source-XA3L4H6I.js → source-XYMMJVKR.js} +44 -44
- package/dist/{source-XA3L4H6I.js.map → source-XYMMJVKR.js.map} +1 -1
- package/dist/{source-manifest-publish-QEGMTS33.js → source-manifest-publish-SZFGGKB4.js} +46 -46
- package/dist/{source-manifest-publish-QEGMTS33.js.map → source-manifest-publish-SZFGGKB4.js.map} +1 -1
- package/dist/transport/index.js +7 -7
- package/dist/transport/ws/server.js +7 -7
- package/dist/transport/ws.js +7 -7
- package/dist/tui/index.js +34 -34
- package/dist/workspace-plugin/adapters/mcp.js +25 -25
- package/dist/workspace-plugin/adapters/omp.js +14 -14
- package/dist/workspace-plugin/index.js +2 -2
- package/package.json +1 -1
- package/dist/chunk-AVFRFGM2.js.map +0 -1
- package/dist/chunk-DKXNKFKP.js.map +0 -1
- package/dist/chunk-IWKKTCXY.js.map +0 -1
- package/dist/chunk-TNQLDEM6.js.map +0 -1
package/dist/{source-manifest-publish-QEGMTS33.js.map → source-manifest-publish-SZFGGKB4.js.map}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../cli/src/commands/source-manifest-publish.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAsCA,IAAM,yBAAA,GAA4B,sBAAA;AAW3B,SAAS,0BAAA,CACd,UACA,SAAA,EACmB;AACnB,EAAA,MAAM,UAAU,QAAA,CAAS,MAAA,IAAU,EAAC,EAAG,GAAA,CAAI,CAAC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,EAAA,IAAI,UAAA,CAAW,WAAW,CAAA,EAAG;AAC3B,IAAA,OAAA,CAAQ,qDAAgD,CAAA;AACxD,IAAA;AAAA,EACF;AAEA,EAAA,MAAM,SAAmB,EAAC;AAC1B,EAAA,KAAA,MAAW,KAAK,UAAA,EAAY;AAC1B,IAAA,IAAI;AACF,MAAA,MAAM,GAAA,CAAI,cAAA,CAAe,CAAA,CAAE,EAAE,CAAA;AAC7B,MAAA,MAAA,CAAO,KAAK,CAAA,EAAG,CAAA,CAAE,IAAI,CAAA,CAAA,EAAI,CAAA,CAAE,IAAI,CAAA,CAAE,CAAA;AAAA,IACnC,SAAS,GAAA,EAAK;AACZ,MAAA,OAAA;AAAA,QACE,CAAA,eAAA,EAAkB,CAAA,CAAE,IAAI,CAAA,CAAA,EAAI,CAAA,CAAE,IAAI,CAAA,EAAA,EAAK,GAAA,YAAe,KAAA,GAAQ,GAAA,CAAI,OAAA,GAAU,MAAA,CAAO,GAAG,CAAC,CAAA;AAAA,OACzF;AAAA,IACF;AAAA,EACF;AAEA,EAAA,KAAA,CAAM,CAAA,OAAA,EAAU,MAAA,CAAO,MAAM,CAAA,UAAA,CAAY,CAAA;AACzC,EAAA,KAAA,MAAW,CAAA,IAAK,MAAA,EAAQ,OAAA,CAAQ,CAAA,EAAA,EAAK,CAAC,CAAA,CAAE,CAAA;AAC1C","file":"source-manifest-publish-QEGMTS33.js","sourcesContent":["/**\n * `skaile source manifest publish` / `yank` — the curator-publish flow. Takes a\n * locally-curated sidecar manifest (over a foreign public GitHub repo) and:\n *\n * 1. Pushes the curated `skaile.manifest.yaml` to the curator's OWN public\n * \"sidecar\" repo (bytes stay in the foreign source; the sidecar holds only\n * the manifest pointing at it).\n * 2. Registers the foreign source + the sidecar (url + pinned commit) with the\n * store, syncs it, and publishes each curated asset.\n *\n * `yank` is the inverse: unpublish each currently-published asset of the source.\n *\n * The store REST surface is reached through the injectable {@link PublisherClient}\n * (default HTTP client); git side-effects go through an injectable `spawn`. Both\n * seams keep the pure helpers + orchestration unit/integration-testable without a\n * live store or a real remote.\n *\n * @docLink cli/commands/source#manifest-publish\n */\n\nimport { spawnSync } from \"node:child_process\";\nimport { existsSync, mkdirSync, readFileSync, rmSync, writeFileSync } from \"node:fs\";\nimport { dirname, join } from \"node:path\";\nimport {\n decodeSkaileManifest,\n encodeSkaileManifest,\n globalSettingsPath,\n type SkPublishManifest,\n sourceCacheKey,\n} from \"@skaile/workspaces/core\";\nimport { logErr, logInfo, logOk, logWarn, S } from \"../helpers.ts\";\nimport { makeHttpPublisherClient, type PublisherClient } from \"../store-publisher.ts\";\nimport { isStoreAuthenticated } from \"../store-client.ts\";\nimport { bareName, exitOnEmptyAsset, publishToStore, refFor } from \"./publish-core.ts\";\nimport { sourceClonePath } from \"./source.ts\";\nimport { missingManifestMessage, resolveSourceArg } from \"./source-manifest.ts\";\n\n/** The fixed filename a sidecar repo carries at its root. */\nconst SIDECAR_MANIFEST_FILENAME = \"skaile.manifest.yaml\";\n\n/** Injectable spawn contract — the subset of `spawnSync` these helpers use. */\ntype SpawnLike = typeof spawnSync;\n\n/**\n * Return a copy of `manifest` normalized for publication under `namespace`:\n * the top-level `publisher` is set to `namespace` and every per-asset\n * `publisher` override is removed so all assets inherit the top-level one.\n * Pure — the input is not mutated.\n */\nexport function normalizePublishedManifest(\n manifest: SkPublishManifest,\n namespace: string,\n): SkPublishManifest {\n const assets = (manifest.assets ?? []).map((a) => {\n const { publisher: _drop, ...rest } = a;\n return rest;\n });\n return { ...manifest, publisher: namespace, assets };\n}\n\n// ── Sidecar-repo association (~/.skaile/settings.json) ────────────────────────\n\n/**\n * Path to the user settings file — the same `$SKAILE_HOME/settings.json`\n * (`~/.skaile/settings.json`) the store client reads tokens from, so the sidecar\n * association lives beside the store manifests and tests isolate through the\n * same `SKAILE_HOME` seam.\n */\nfunction settingsFile(): string {\n return globalSettingsPath();\n}\n\nfunction readSettings(): Record<string, any> {\n const file = settingsFile();\n if (!existsSync(file)) return {};\n try {\n return JSON.parse(readFileSync(file, \"utf-8\"));\n } catch {\n return {};\n }\n}\n\n/**\n * The sidecar repo URL previously associated with a source `slug`, if any.\n * Reads `settings.sidecarRepos?.[slug]?.repo`.\n */\nexport function getSidecarRepo(slug: string): string | undefined {\n const settings = readSettings();\n return settings.sidecarRepos?.[slug]?.repo;\n}\n\n/**\n * Persist the sidecar repo URL for a source `slug`, preserving every other\n * settings key. Stored as an object (`{ repo }`) so a `path` (or other fields)\n * can be added later without a schema migration.\n */\nexport function saveSidecarRepo(slug: string, repo: string): void {\n const file = settingsFile();\n mkdirSync(dirname(file), { recursive: true });\n const settings = readSettings();\n const sidecarRepos = { ...(settings.sidecarRepos ?? {}) };\n sidecarRepos[slug] = { ...(sidecarRepos[slug] ?? {}), repo };\n settings.sidecarRepos = sidecarRepos;\n writeFileSync(file, JSON.stringify(settings, null, 2), \"utf-8\");\n}\n\n// ── Sidecar push ──────────────────────────────────────────────────────────────\n\n/**\n * Run a git command in `cwd` via the injected spawn, throwing with the captured\n * stderr on failure. Returns trimmed stdout.\n */\nfunction git(spawn: SpawnLike, cwd: string, args: string[]): string {\n const res = spawn(\"git\", [\"-C\", cwd, ...args], { encoding: \"utf-8\" });\n if (res.status !== 0) {\n const stderr = (res.stderr ?? \"\").toString().trim();\n throw new Error(`git ${args.join(\" \")} failed: ${stderr || `exit ${res.status}`}`);\n }\n return (res.stdout ?? \"\").toString().trim();\n}\n\n/**\n * Clone the curator's sidecar repo, write the curated manifest at its root, and\n * commit + push. Returns the pushed commit sha (used to pin the store source).\n *\n * Idempotent re-publish: when the manifest is unchanged `git commit` fails with\n * \"nothing to commit\" — we swallow that and return the current HEAD so a no-op\n * re-run still yields a valid pin. Any push/auth failure surfaces as a thrown\n * Error carrying git's stderr.\n */\nexport function pushSidecarManifest(opts: {\n sidecarRepoUrl: string;\n manifestText: string;\n spawn?: SpawnLike;\n}): { commitSha: string } {\n const spawn = opts.spawn ?? spawnSync;\n // Dedicated dir next to the source clone cache; wipe any stale clone first so\n // a re-publish always starts from a clean shallow checkout of the remote.\n const cloneDir = `${sourceClonePath(sourceCacheKey(opts.sidecarRepoUrl))}-sidecar-push`;\n rmSync(cloneDir, { recursive: true, force: true });\n mkdirSync(dirname(cloneDir), { recursive: true });\n\n // The clone is scratch — always remove it afterwards (success or failure) so a\n // failed push never leaves a stale checkout in the cache dir.\n try {\n const cloneRes = spawn(\"git\", [\"clone\", \"--depth\", \"1\", opts.sidecarRepoUrl, cloneDir], {\n encoding: \"utf-8\",\n });\n if (cloneRes.status !== 0) {\n const stderr = (cloneRes.stderr ?? \"\").toString().trim();\n throw new Error(\n `git clone ${opts.sidecarRepoUrl} failed: ${stderr || `exit ${cloneRes.status}`}`,\n );\n }\n\n writeFileSync(join(cloneDir, SIDECAR_MANIFEST_FILENAME), opts.manifestText, \"utf-8\");\n git(spawn, cloneDir, [\"add\", SIDECAR_MANIFEST_FILENAME]);\n\n // Fixed bot identity via -c so the commit succeeds regardless of the curator's\n // git config (the sidecar push is a machine action, not authored work).\n const commitRes = spawn(\n \"git\",\n [\n \"-C\",\n cloneDir,\n \"-c\",\n \"user.email=publish@skaile.store\",\n \"-c\",\n \"user.name=skaile\",\n \"commit\",\n \"-m\",\n \"chore(sidecar): publish curated manifest\",\n ],\n { encoding: \"utf-8\" },\n );\n if (commitRes.status !== 0) {\n const out = `${commitRes.stdout ?? \"\"}${commitRes.stderr ?? \"\"}`;\n // Nothing changed → idempotent re-publish; keep the existing HEAD.\n if (!/nothing to commit/i.test(out)) {\n throw new Error(`git commit failed: ${out.trim() || `exit ${commitRes.status}`}`);\n }\n } else {\n // `push origin HEAD` (not a bare `push`) so a fresh sidecar repo with an\n // unborn/renamed default branch still gets its branch created on the remote.\n git(spawn, cloneDir, [\"push\", \"origin\", \"HEAD\"]);\n }\n\n return { commitSha: git(spawn, cloneDir, [\"rev-parse\", \"HEAD\"]) };\n } finally {\n rmSync(cloneDir, { recursive: true, force: true });\n }\n}\n\n// ── Orchestration ───────────────────────────────────────────────────────────\n\n/**\n * `source manifest publish <src>` — publish a curated sidecar manifest to the\n * store. See the module header for the full flow. Store calls go through\n * `client` (default HTTP); git side-effects through `spawn` (default\n * `spawnSync`). The auth gate is enforced only for the default HTTP client so\n * injected fakes bypass it.\n */\nexport async function runPublish(\n arg: string,\n opts: {\n projectDir: string;\n as?: string;\n sidecarRepo?: string;\n ref?: string;\n dryRun?: boolean;\n },\n client?: PublisherClient,\n spawn: SpawnLike = spawnSync,\n): Promise<void> {\n const injected = client !== undefined;\n const pub = client ?? makeHttpPublisherClient();\n\n const { url, slug, manifestFile, ambiguous } = resolveSourceArg(arg, opts.projectDir);\n\n if (!existsSync(manifestFile)) {\n logErr(missingManifestMessage(slug, manifestFile, ambiguous));\n process.exit(1);\n }\n\n const { manifest, diagnostics } = decodeSkaileManifest(readFileSync(manifestFile, \"utf-8\"));\n if (diagnostics.some((d) => d.severity === \"error\")) {\n for (const d of diagnostics.filter((x) => x.severity === \"error\")) {\n logErr(`${d.code}: ${d.message}`);\n }\n logErr(\n \"The curated manifest has errors — fix them with `skaile source manifest edit` / \" +\n \"`verify` before publishing.\",\n );\n process.exit(1);\n }\n\n // A real publish makes store calls (+ `me()` when `--as` is omitted), so it\n // needs a token. `--dry-run` is an offline preview: never gate it on auth.\n const authed = injected || isStoreAuthenticated();\n if (!opts.dryRun && !authed) {\n logErr(\"Not signed in — run `skaile store login` first.\");\n process.exit(1);\n }\n\n // Namespace: `--as` wins; else the caller's verified identity. Prefer the\n // GitHub handle (`githubLogin`) over the store login (`username`) — for a user\n // whose login differs from their GitHub handle the login namespace may be\n // reserved (matches the CLI's `resolveLibraryPublisher` precedence). In an\n // unauthenticated dry-run we cannot call `me()`, so show a placeholder.\n let namespace: string;\n if (opts.as) namespace = opts.as;\n else if (authed) {\n const me = await pub.me();\n // `||` not `??`: an empty-string githubLogin (partially-connected account) is\n // not a usable namespace — fall back to the login rather than publish under \"\".\n namespace = me.githubLogin || me.username;\n } else namespace = \"<your store username>\";\n\n const normalized = normalizePublishedManifest(manifest, namespace);\n const publishedText = encodeSkaileManifest(normalized);\n\n const wouldBeRefs = (normalized.assets ?? []).map((a) =>\n refFor(a.kind, namespace, a.name, a.version ?? normalized.version),\n );\n\n if (opts.dryRun) {\n const sidecar = opts.sidecarRepo ?? getSidecarRepo(slug) ?? \"<none — pass --sidecar-repo>\";\n logInfo(`Publish plan for ${S.bold(slug)}:`);\n logInfo(` namespace: ${namespace}`);\n logInfo(` sidecar repo: ${sidecar}`);\n logInfo(` source ref: ${opts.ref ?? \"main\"}`);\n logInfo(` would publish ${wouldBeRefs.length} asset(s):`);\n for (const r of wouldBeRefs) logInfo(` ${r}`);\n return;\n }\n\n const sidecarRepoUrl = opts.sidecarRepo ?? getSidecarRepo(slug);\n if (!sidecarRepoUrl) {\n logErr(\n \"No sidecar repo associated with this source. Pass \" +\n `${S.cmd(\"--sidecar-repo https://github.com/<you>/<repo>\")} — it must be a ` +\n \"PUBLIC GitHub repo you own; the curated manifest is committed there and the \" +\n \"store pins to that commit.\",\n );\n process.exit(1);\n }\n if (opts.sidecarRepo) saveSidecarRepo(slug, sidecarRepoUrl);\n\n const { commitSha } = pushSidecarManifest({ sidecarRepoUrl, manifestText: publishedText, spawn });\n logOk(`Pushed curated manifest to ${S.dim(sidecarRepoUrl)} @ ${commitSha.slice(0, 10)}.`);\n\n // The FOREIGN repo's ref to ingest (branch/sha). Defaults to `main`.\n const sourceRef = opts.ref ?? \"main\";\n\n const { published } = await publishToStore({\n sourceUrl: url,\n ref: sourceRef,\n sidecar: { url: sidecarRepoUrl, ref: commitSha },\n manifest: normalized,\n client: pub,\n });\n\n if (published.length > 0) {\n logInfo(`Consumers can now install them with \\`skaile add ${published[0]}\\`.`);\n }\n}\n\n/**\n * `source manifest yank <src>` — unpublish the source's published assets (all,\n * or the single asset matching `opts.asset`'s name). Auth-gated like publish.\n */\nexport async function runYank(\n arg: string,\n opts: { projectDir: string; asset?: string },\n client?: PublisherClient,\n): Promise<void> {\n exitOnEmptyAsset(opts.asset);\n const injected = client !== undefined;\n const pub = client ?? makeHttpPublisherClient();\n\n const { url, slug } = resolveSourceArg(arg, opts.projectDir);\n\n if (!injected && !isStoreAuthenticated()) {\n logErr(\"Not signed in — run `skaile store login` first.\");\n process.exit(1);\n }\n\n const rows = await pub.sourcesList();\n const source = rows.find((r) => r.url === url);\n if (!source) {\n logErr(`Source \"${slug}\" is not registered in the store — nothing to yank.`);\n process.exit(1);\n }\n\n // Optionally narrow to a single asset by name (accept a bare name or a ref).\n const targetName = opts.asset ? bareName(opts.asset) : undefined;\n const candidates = (await pub.sourceCandidates(source.id)).filter(\n (c) => c.published && (!targetName || c.name === targetName),\n );\n if (candidates.length === 0) {\n logWarn(\"No published assets matched — nothing to yank.\");\n return;\n }\n\n const yanked: string[] = [];\n for (const c of candidates) {\n try {\n await pub.assetUnpublish(c.id);\n yanked.push(`${c.kind}:${c.name}`);\n } catch (err) {\n logWarn(\n `Failed to yank ${c.kind}:${c.name}: ${err instanceof Error ? err.message : String(err)}`,\n );\n }\n }\n\n logOk(`Yanked ${yanked.length} asset(s):`);\n for (const r of yanked) logInfo(` ${r}`);\n}\n"]}
|
|
1
|
+
{"version":3,"sources":["../cli/src/commands/source-manifest-publish.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAsCA,IAAM,yBAAA,GAA4B,sBAAA;AAW3B,SAAS,0BAAA,CACd,UACA,SAAA,EACmB;AACnB,EAAA,MAAM,UAAU,QAAA,CAAS,MAAA,IAAU,EAAC,EAAG,GAAA,CAAI,CAAC,CAAA,KAAM;AAChD,IAAA,MAAM,EAAE,SAAA,EAAW,KAAA,EAAO,GAAG,MAAK,GAAI,CAAA;AACtC,IAAA,OAAO,IAAA;AAAA,EACT,CAAC,CAAA;AACD,EAAA,OAAO,EAAE,GAAG,QAAA,EAAU,SAAA,EAAW,WAAW,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AA,IAAI;AACF,MAAA,MAAM,GAAA,CAAI,cAAA,CAAe,CAAA,CAAE,EAAE,CAAA;AAC7B,MAAA,MAAA,CAAO,KAAK,CAAA,EAAG,CAAA,CAAE,IAAI,CAAA,CAAA,EAAI,CAAA,CAAE,IAAI,CAAA,CAAE,CAAA;AAAA,IACnC,SAAS,GAAA,EAAK;AACZ,MAAA,OAAA;AAAA,QACE,CAAA,eAAA,EAAkB,CAAA,CAAE,IAAI,CAAA,CAAA,EAAI,CAAA,CAAE,IAAI,CAAA,EAAA,EAAK,GAAA,YAAe,KAAA,GAAQ,GAAA,CAAI,OAAA,GAAU,MAAA,CAAO,GAAG,CAAC,CAAA;AAAA,OACzF;AAAA,IACF;AAAA,EACF;AAEA,EAAA,KAAA,CAAM,CAAA,OAAA,EAAU,MAAA,CAAO,MAAM,CAAA,UAAA,CAAY,CAAA;AACzC,EAAA,KAAA,MAAW,CAAA,IAAK,MAAA,EAAQ,OAAA,CAAQ,CAAA,EAAA,EAAK,CAAC,CAAA,CAAE,CAAA;AAC1C","file":"source-manifest-publish-SZFGGKB4.js","sourcesContent":["/**\n * `skaile source manifest publish` / `yank` — the curator-publish flow. Takes a\n * locally-curated sidecar manifest (over a foreign public GitHub repo) and:\n *\n * 1. Pushes the curated `skaile.manifest.yaml` to the curator's OWN public\n * \"sidecar\" repo (bytes stay in the foreign source; the sidecar holds only\n * the manifest pointing at it).\n * 2. Registers the foreign source + the sidecar (url + pinned commit) with the\n * store, syncs it, and publishes each curated asset.\n *\n * `yank` is the inverse: unpublish each currently-published asset of the source.\n *\n * The store REST surface is reached through the injectable {@link PublisherClient}\n * (default HTTP client); git side-effects go through an injectable `spawn`. Both\n * seams keep the pure helpers + orchestration unit/integration-testable without a\n * live store or a real remote.\n *\n * @docLink cli/commands/source#manifest-publish\n */\n\nimport { spawnSync } from \"node:child_process\";\nimport { existsSync, mkdirSync, readFileSync, rmSync, writeFileSync } from \"node:fs\";\nimport { dirname, join } from \"node:path\";\nimport {\n decodeSkaileManifest,\n encodeSkaileManifest,\n globalSettingsPath,\n type SkPublishManifest,\n sourceCacheKey,\n} from \"@skaile/workspaces/core\";\nimport { logErr, logInfo, logOk, logWarn, S } from \"../helpers.ts\";\nimport { makeHttpPublisherClient, type PublisherClient } from \"../store-publisher.ts\";\nimport { isStoreAuthenticated } from \"../store-client.ts\";\nimport { bareName, exitOnEmptyAsset, publishToStore, refFor } from \"./publish-core.ts\";\nimport { sourceClonePath } from \"./source.ts\";\nimport { missingManifestMessage, resolveSourceArg } from \"./source-manifest.ts\";\n\n/** The fixed filename a sidecar repo carries at its root. */\nconst SIDECAR_MANIFEST_FILENAME = \"skaile.manifest.yaml\";\n\n/** Injectable spawn contract — the subset of `spawnSync` these helpers use. */\ntype SpawnLike = typeof spawnSync;\n\n/**\n * Return a copy of `manifest` normalized for publication under `namespace`:\n * the top-level `publisher` is set to `namespace` and every per-asset\n * `publisher` override is removed so all assets inherit the top-level one.\n * Pure — the input is not mutated.\n */\nexport function normalizePublishedManifest(\n manifest: SkPublishManifest,\n namespace: string,\n): SkPublishManifest {\n const assets = (manifest.assets ?? []).map((a) => {\n const { publisher: _drop, ...rest } = a;\n return rest;\n });\n return { ...manifest, publisher: namespace, assets };\n}\n\n// ── Sidecar-repo association (~/.skaile/settings.json) ────────────────────────\n\n/**\n * Path to the user settings file — the same `$SKAILE_HOME/settings.json`\n * (`~/.skaile/settings.json`) the store client reads tokens from, so the sidecar\n * association lives beside the store manifests and tests isolate through the\n * same `SKAILE_HOME` seam.\n */\nfunction settingsFile(): string {\n return globalSettingsPath();\n}\n\nfunction readSettings(): Record<string, any> {\n const file = settingsFile();\n if (!existsSync(file)) return {};\n try {\n return JSON.parse(readFileSync(file, \"utf-8\"));\n } catch {\n return {};\n }\n}\n\n/**\n * The sidecar repo URL previously associated with a source `slug`, if any.\n * Reads `settings.sidecarRepos?.[slug]?.repo`.\n */\nexport function getSidecarRepo(slug: string): string | undefined {\n const settings = readSettings();\n return settings.sidecarRepos?.[slug]?.repo;\n}\n\n/**\n * Persist the sidecar repo URL for a source `slug`, preserving every other\n * settings key. Stored as an object (`{ repo }`) so a `path` (or other fields)\n * can be added later without a schema migration.\n */\nexport function saveSidecarRepo(slug: string, repo: string): void {\n const file = settingsFile();\n mkdirSync(dirname(file), { recursive: true });\n const settings = readSettings();\n const sidecarRepos = { ...(settings.sidecarRepos ?? {}) };\n sidecarRepos[slug] = { ...(sidecarRepos[slug] ?? {}), repo };\n settings.sidecarRepos = sidecarRepos;\n writeFileSync(file, JSON.stringify(settings, null, 2), \"utf-8\");\n}\n\n// ── Sidecar push ──────────────────────────────────────────────────────────────\n\n/**\n * Run a git command in `cwd` via the injected spawn, throwing with the captured\n * stderr on failure. Returns trimmed stdout.\n */\nfunction git(spawn: SpawnLike, cwd: string, args: string[]): string {\n const res = spawn(\"git\", [\"-C\", cwd, ...args], { encoding: \"utf-8\" });\n if (res.status !== 0) {\n const stderr = (res.stderr ?? \"\").toString().trim();\n throw new Error(`git ${args.join(\" \")} failed: ${stderr || `exit ${res.status}`}`);\n }\n return (res.stdout ?? \"\").toString().trim();\n}\n\n/**\n * Clone the curator's sidecar repo, write the curated manifest at its root, and\n * commit + push. Returns the pushed commit sha (used to pin the store source).\n *\n * Idempotent re-publish: when the manifest is unchanged `git commit` fails with\n * \"nothing to commit\" — we swallow that and return the current HEAD so a no-op\n * re-run still yields a valid pin. Any push/auth failure surfaces as a thrown\n * Error carrying git's stderr.\n */\nexport function pushSidecarManifest(opts: {\n sidecarRepoUrl: string;\n manifestText: string;\n spawn?: SpawnLike;\n}): { commitSha: string } {\n const spawn = opts.spawn ?? spawnSync;\n // Dedicated dir next to the source clone cache; wipe any stale clone first so\n // a re-publish always starts from a clean shallow checkout of the remote.\n const cloneDir = `${sourceClonePath(sourceCacheKey(opts.sidecarRepoUrl))}-sidecar-push`;\n rmSync(cloneDir, { recursive: true, force: true });\n mkdirSync(dirname(cloneDir), { recursive: true });\n\n // The clone is scratch — always remove it afterwards (success or failure) so a\n // failed push never leaves a stale checkout in the cache dir.\n try {\n const cloneRes = spawn(\"git\", [\"clone\", \"--depth\", \"1\", opts.sidecarRepoUrl, cloneDir], {\n encoding: \"utf-8\",\n });\n if (cloneRes.status !== 0) {\n const stderr = (cloneRes.stderr ?? \"\").toString().trim();\n throw new Error(\n `git clone ${opts.sidecarRepoUrl} failed: ${stderr || `exit ${cloneRes.status}`}`,\n );\n }\n\n writeFileSync(join(cloneDir, SIDECAR_MANIFEST_FILENAME), opts.manifestText, \"utf-8\");\n git(spawn, cloneDir, [\"add\", SIDECAR_MANIFEST_FILENAME]);\n\n // Fixed bot identity via -c so the commit succeeds regardless of the curator's\n // git config (the sidecar push is a machine action, not authored work).\n const commitRes = spawn(\n \"git\",\n [\n \"-C\",\n cloneDir,\n \"-c\",\n \"user.email=publish@skaile.store\",\n \"-c\",\n \"user.name=skaile\",\n \"commit\",\n \"-m\",\n \"chore(sidecar): publish curated manifest\",\n ],\n { encoding: \"utf-8\" },\n );\n if (commitRes.status !== 0) {\n const out = `${commitRes.stdout ?? \"\"}${commitRes.stderr ?? \"\"}`;\n // Nothing changed → idempotent re-publish; keep the existing HEAD.\n if (!/nothing to commit/i.test(out)) {\n throw new Error(`git commit failed: ${out.trim() || `exit ${commitRes.status}`}`);\n }\n } else {\n // `push origin HEAD` (not a bare `push`) so a fresh sidecar repo with an\n // unborn/renamed default branch still gets its branch created on the remote.\n git(spawn, cloneDir, [\"push\", \"origin\", \"HEAD\"]);\n }\n\n return { commitSha: git(spawn, cloneDir, [\"rev-parse\", \"HEAD\"]) };\n } finally {\n rmSync(cloneDir, { recursive: true, force: true });\n }\n}\n\n// ── Orchestration ───────────────────────────────────────────────────────────\n\n/**\n * `source manifest publish <src>` — publish a curated sidecar manifest to the\n * store. See the module header for the full flow. Store calls go through\n * `client` (default HTTP); git side-effects through `spawn` (default\n * `spawnSync`). The auth gate is enforced only for the default HTTP client so\n * injected fakes bypass it.\n */\nexport async function runPublish(\n arg: string,\n opts: {\n projectDir: string;\n as?: string;\n sidecarRepo?: string;\n ref?: string;\n dryRun?: boolean;\n },\n client?: PublisherClient,\n spawn: SpawnLike = spawnSync,\n): Promise<void> {\n const injected = client !== undefined;\n const pub = client ?? makeHttpPublisherClient();\n\n const { url, slug, manifestFile, ambiguous } = resolveSourceArg(arg, opts.projectDir);\n\n if (!existsSync(manifestFile)) {\n logErr(missingManifestMessage(slug, manifestFile, ambiguous));\n process.exit(1);\n }\n\n const { manifest, diagnostics } = decodeSkaileManifest(readFileSync(manifestFile, \"utf-8\"));\n if (diagnostics.some((d) => d.severity === \"error\")) {\n for (const d of diagnostics.filter((x) => x.severity === \"error\")) {\n logErr(`${d.code}: ${d.message}`);\n }\n logErr(\n \"The curated manifest has errors — fix them with `skaile source manifest edit` / \" +\n \"`verify` before publishing.\",\n );\n process.exit(1);\n }\n\n // A real publish makes store calls (+ `me()` when `--as` is omitted), so it\n // needs a token. `--dry-run` is an offline preview: never gate it on auth.\n const authed = injected || isStoreAuthenticated();\n if (!opts.dryRun && !authed) {\n logErr(\"Not signed in — run `skaile store login` first.\");\n process.exit(1);\n }\n\n // Namespace: `--as` wins; else the caller's verified identity. Prefer the\n // GitHub handle (`githubLogin`) over the store login (`username`) — for a user\n // whose login differs from their GitHub handle the login namespace may be\n // reserved (matches the CLI's `resolveLibraryPublisher` precedence). In an\n // unauthenticated dry-run we cannot call `me()`, so show a placeholder.\n let namespace: string;\n if (opts.as) namespace = opts.as;\n else if (authed) {\n const me = await pub.me();\n // `||` not `??`: an empty-string githubLogin (partially-connected account) is\n // not a usable namespace — fall back to the login rather than publish under \"\".\n namespace = me.githubLogin || me.username;\n } else namespace = \"<your store username>\";\n\n const normalized = normalizePublishedManifest(manifest, namespace);\n const publishedText = encodeSkaileManifest(normalized);\n\n const wouldBeRefs = (normalized.assets ?? []).map((a) =>\n refFor(a.kind, namespace, a.name, a.version ?? normalized.version),\n );\n\n if (opts.dryRun) {\n const sidecar = opts.sidecarRepo ?? getSidecarRepo(slug) ?? \"<none — pass --sidecar-repo>\";\n logInfo(`Publish plan for ${S.bold(slug)}:`);\n logInfo(` namespace: ${namespace}`);\n logInfo(` sidecar repo: ${sidecar}`);\n logInfo(` source ref: ${opts.ref ?? \"main\"}`);\n logInfo(` would publish ${wouldBeRefs.length} asset(s):`);\n for (const r of wouldBeRefs) logInfo(` ${r}`);\n return;\n }\n\n const sidecarRepoUrl = opts.sidecarRepo ?? getSidecarRepo(slug);\n if (!sidecarRepoUrl) {\n logErr(\n \"No sidecar repo associated with this source. Pass \" +\n `${S.cmd(\"--sidecar-repo https://github.com/<you>/<repo>\")} — it must be a ` +\n \"PUBLIC GitHub repo you own; the curated manifest is committed there and the \" +\n \"store pins to that commit.\",\n );\n process.exit(1);\n }\n if (opts.sidecarRepo) saveSidecarRepo(slug, sidecarRepoUrl);\n\n const { commitSha } = pushSidecarManifest({ sidecarRepoUrl, manifestText: publishedText, spawn });\n logOk(`Pushed curated manifest to ${S.dim(sidecarRepoUrl)} @ ${commitSha.slice(0, 10)}.`);\n\n // The FOREIGN repo's ref to ingest (branch/sha). Defaults to `main`.\n const sourceRef = opts.ref ?? \"main\";\n\n const { published } = await publishToStore({\n sourceUrl: url,\n ref: sourceRef,\n sidecar: { url: sidecarRepoUrl, ref: commitSha },\n manifest: normalized,\n client: pub,\n });\n\n if (published.length > 0) {\n logInfo(`Consumers can now install them with \\`skaile add ${published[0]}\\`.`);\n }\n}\n\n/**\n * `source manifest yank <src>` — unpublish the source's published assets (all,\n * or the single asset matching `opts.asset`'s name). Auth-gated like publish.\n */\nexport async function runYank(\n arg: string,\n opts: { projectDir: string; asset?: string },\n client?: PublisherClient,\n): Promise<void> {\n exitOnEmptyAsset(opts.asset);\n const injected = client !== undefined;\n const pub = client ?? makeHttpPublisherClient();\n\n const { url, slug } = resolveSourceArg(arg, opts.projectDir);\n\n if (!injected && !isStoreAuthenticated()) {\n logErr(\"Not signed in — run `skaile store login` first.\");\n process.exit(1);\n }\n\n const rows = await pub.sourcesList();\n const source = rows.find((r) => r.url === url);\n if (!source) {\n logErr(`Source \"${slug}\" is not registered in the store — nothing to yank.`);\n process.exit(1);\n }\n\n // Optionally narrow to a single asset by name (accept a bare name or a ref).\n const targetName = opts.asset ? bareName(opts.asset) : undefined;\n const candidates = (await pub.sourceCandidates(source.id)).filter(\n (c) => c.published && (!targetName || c.name === targetName),\n );\n if (candidates.length === 0) {\n logWarn(\"No published assets matched — nothing to yank.\");\n return;\n }\n\n const yanked: string[] = [];\n for (const c of candidates) {\n try {\n await pub.assetUnpublish(c.id);\n yanked.push(`${c.kind}:${c.name}`);\n } catch (err) {\n logWarn(\n `Failed to yank ${c.kind}:${c.name}: ${err instanceof Error ? err.message : String(err)}`,\n );\n }\n }\n\n logOk(`Yanked ${yanked.length} asset(s):`);\n for (const r of yanked) logInfo(` ${r}`);\n}\n"]}
|
package/dist/transport/index.js
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
import '../chunk-O7SG5PC2.js';
|
|
2
2
|
import '../chunk-7QBNJTTQ.js';
|
|
3
3
|
export { WebSocketClientTransport } from '../chunk-O2SYFJWP.js';
|
|
4
|
-
export { WebSocketServerTransport } from '../chunk-
|
|
4
|
+
export { WebSocketServerTransport } from '../chunk-6A6HE5LW.js';
|
|
5
5
|
import '../chunk-32NA4TVC.js';
|
|
6
|
-
import '../chunk-
|
|
6
|
+
import '../chunk-6ARPZHOV.js';
|
|
7
7
|
import '../chunk-4GY63JU6.js';
|
|
8
|
-
import '../chunk-
|
|
8
|
+
import '../chunk-JIQUF3X2.js';
|
|
9
9
|
import '../chunk-5KRMNUL4.js';
|
|
10
10
|
import '../chunk-C5HFK34M.js';
|
|
11
11
|
import '../chunk-MWXYN6NY.js';
|
|
12
|
-
import '../chunk-
|
|
12
|
+
import '../chunk-6SXSVKQY.js';
|
|
13
13
|
import '../chunk-L5VSIPQD.js';
|
|
14
14
|
import '../chunk-VTETQCR6.js';
|
|
15
|
-
import '../chunk-
|
|
16
|
-
import '../chunk-
|
|
15
|
+
import '../chunk-E2EC6SAX.js';
|
|
16
|
+
import '../chunk-GNUA7XT2.js';
|
|
17
17
|
import '../chunk-RVRB27AN.js';
|
|
18
18
|
import '../chunk-V5KG6CCV.js';
|
|
19
19
|
import '../chunk-VSX2G7LA.js';
|
|
20
20
|
import '../chunk-RXGPFAMN.js';
|
|
21
|
-
import '../chunk-
|
|
21
|
+
import '../chunk-SGI5MRKP.js';
|
|
22
22
|
import '../chunk-C3CAXQMA.js';
|
|
23
23
|
import '../chunk-BOFL7GIF.js';
|
|
24
24
|
import '../chunk-NSBPE2FW.js';
|
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
export { WebSocketServerTransport } from '../../chunk-
|
|
1
|
+
export { WebSocketServerTransport } from '../../chunk-6A6HE5LW.js';
|
|
2
2
|
import '../../chunk-32NA4TVC.js';
|
|
3
|
-
export { needsWildcardProbe } from '../../chunk-
|
|
3
|
+
export { needsWildcardProbe } from '../../chunk-6ARPZHOV.js';
|
|
4
4
|
import '../../chunk-4GY63JU6.js';
|
|
5
|
-
import '../../chunk-
|
|
5
|
+
import '../../chunk-JIQUF3X2.js';
|
|
6
6
|
import '../../chunk-5KRMNUL4.js';
|
|
7
7
|
import '../../chunk-C5HFK34M.js';
|
|
8
8
|
import '../../chunk-MWXYN6NY.js';
|
|
9
|
-
import '../../chunk-
|
|
9
|
+
import '../../chunk-6SXSVKQY.js';
|
|
10
10
|
import '../../chunk-L5VSIPQD.js';
|
|
11
11
|
import '../../chunk-VTETQCR6.js';
|
|
12
|
-
import '../../chunk-
|
|
13
|
-
import '../../chunk-
|
|
12
|
+
import '../../chunk-E2EC6SAX.js';
|
|
13
|
+
import '../../chunk-GNUA7XT2.js';
|
|
14
14
|
import '../../chunk-RVRB27AN.js';
|
|
15
15
|
import '../../chunk-V5KG6CCV.js';
|
|
16
16
|
import '../../chunk-VSX2G7LA.js';
|
|
17
17
|
import '../../chunk-RXGPFAMN.js';
|
|
18
|
-
import '../../chunk-
|
|
18
|
+
import '../../chunk-SGI5MRKP.js';
|
|
19
19
|
import '../../chunk-C3CAXQMA.js';
|
|
20
20
|
import '../../chunk-BOFL7GIF.js';
|
|
21
21
|
import '../../chunk-NSBPE2FW.js';
|
package/dist/transport/ws.js
CHANGED
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
import '../chunk-7QBNJTTQ.js';
|
|
2
2
|
export { WebSocketClientTransport } from '../chunk-O2SYFJWP.js';
|
|
3
|
-
export { WebSocketServerTransport } from '../chunk-
|
|
3
|
+
export { WebSocketServerTransport } from '../chunk-6A6HE5LW.js';
|
|
4
4
|
export { BEARER_SUBPROTOCOL_PREFIX, decodeBearerFromHeader, encodeBearerSubprotocol, tokensEqual } from '../chunk-32NA4TVC.js';
|
|
5
|
-
import '../chunk-
|
|
5
|
+
import '../chunk-6ARPZHOV.js';
|
|
6
6
|
import '../chunk-4GY63JU6.js';
|
|
7
|
-
import '../chunk-
|
|
7
|
+
import '../chunk-JIQUF3X2.js';
|
|
8
8
|
import '../chunk-5KRMNUL4.js';
|
|
9
9
|
import '../chunk-C5HFK34M.js';
|
|
10
10
|
import '../chunk-MWXYN6NY.js';
|
|
11
|
-
import '../chunk-
|
|
11
|
+
import '../chunk-6SXSVKQY.js';
|
|
12
12
|
import '../chunk-L5VSIPQD.js';
|
|
13
13
|
import '../chunk-VTETQCR6.js';
|
|
14
|
-
import '../chunk-
|
|
15
|
-
import '../chunk-
|
|
14
|
+
import '../chunk-E2EC6SAX.js';
|
|
15
|
+
import '../chunk-GNUA7XT2.js';
|
|
16
16
|
import '../chunk-RVRB27AN.js';
|
|
17
17
|
import '../chunk-V5KG6CCV.js';
|
|
18
18
|
import '../chunk-VSX2G7LA.js';
|
|
19
19
|
import '../chunk-RXGPFAMN.js';
|
|
20
|
-
import '../chunk-
|
|
20
|
+
import '../chunk-SGI5MRKP.js';
|
|
21
21
|
import '../chunk-C3CAXQMA.js';
|
|
22
22
|
import '../chunk-BOFL7GIF.js';
|
|
23
23
|
import '../chunk-NSBPE2FW.js';
|
package/dist/tui/index.js
CHANGED
|
@@ -1,50 +1,50 @@
|
|
|
1
|
-
import { resolveInstanceAgentDir, instanceSessionOverrides, bootstrapRunnerLogStore, createAgentSession, unresolvedCredentialNotices, createFinalTextFallback } from '../chunk-
|
|
2
|
-
import '../chunk-
|
|
3
|
-
import '../chunk-
|
|
4
|
-
import '../chunk-
|
|
5
|
-
import '../chunk-
|
|
1
|
+
import { resolveInstanceAgentDir, instanceSessionOverrides, bootstrapRunnerLogStore, createAgentSession, unresolvedCredentialNotices, createFinalTextFallback } from '../chunk-AQNW2FET.js';
|
|
2
|
+
import '../chunk-Z4FERR4U.js';
|
|
3
|
+
import '../chunk-GTGWRKMJ.js';
|
|
4
|
+
import '../chunk-7I5PNB2G.js';
|
|
5
|
+
import '../chunk-O7QZI6MQ.js';
|
|
6
6
|
import '../chunk-WYZXSJBK.js';
|
|
7
|
-
import '../chunk-
|
|
8
|
-
import '../chunk-
|
|
7
|
+
import '../chunk-GTAHU4N4.js';
|
|
8
|
+
import '../chunk-HQAPUPBE.js';
|
|
9
9
|
import '../chunk-KW37WNXY.js';
|
|
10
10
|
import '../chunk-3MWQKQUB.js';
|
|
11
|
-
import '../chunk-
|
|
11
|
+
import '../chunk-SZKCE7EC.js';
|
|
12
12
|
import '../chunk-O7SG5PC2.js';
|
|
13
13
|
import '../chunk-7QBNJTTQ.js';
|
|
14
14
|
import '../chunk-O2SYFJWP.js';
|
|
15
|
-
import '../chunk-
|
|
15
|
+
import '../chunk-6A6HE5LW.js';
|
|
16
16
|
import '../chunk-32NA4TVC.js';
|
|
17
17
|
import '../chunk-W3UDISS2.js';
|
|
18
|
-
import '../chunk-
|
|
19
|
-
import '../chunk-
|
|
18
|
+
import '../chunk-CMXDFTA2.js';
|
|
19
|
+
import '../chunk-5ETYBC2X.js';
|
|
20
20
|
import '../chunk-4R6DROGN.js';
|
|
21
|
-
import '../chunk-
|
|
22
|
-
import '../chunk-
|
|
23
|
-
import '../chunk-
|
|
21
|
+
import '../chunk-PTJTOPE5.js';
|
|
22
|
+
import '../chunk-USSP43U3.js';
|
|
23
|
+
import '../chunk-VXYZ5M7Z.js';
|
|
24
24
|
import '../chunk-2M3VLKT2.js';
|
|
25
|
-
import { loadConnectorDeclarations } from '../chunk-
|
|
26
|
-
import '../chunk-
|
|
27
|
-
import '../chunk-
|
|
28
|
-
import { approvalCardOf, APPROVE_ONCE, DENY } from '../chunk-
|
|
29
|
-
import '../chunk-
|
|
25
|
+
import { loadConnectorDeclarations } from '../chunk-4BFEPZ6J.js';
|
|
26
|
+
import '../chunk-YN6N3RBM.js';
|
|
27
|
+
import '../chunk-TCH5UDKT.js';
|
|
28
|
+
import { approvalCardOf, APPROVE_ONCE, DENY } from '../chunk-U3UDOX6I.js';
|
|
29
|
+
import '../chunk-65UAC3ZR.js';
|
|
30
30
|
import '../chunk-LOO5CB5M.js';
|
|
31
31
|
import '../chunk-KSUT5KAE.js';
|
|
32
|
-
import '../chunk-
|
|
32
|
+
import '../chunk-OY22B7E2.js';
|
|
33
33
|
import '../chunk-5DE3DGVR.js';
|
|
34
34
|
import '../chunk-7DN6JKP2.js';
|
|
35
|
-
import '../chunk-
|
|
36
|
-
import '../chunk-
|
|
37
|
-
import '../chunk-
|
|
38
|
-
import '../chunk-
|
|
35
|
+
import '../chunk-WW5NAU6N.js';
|
|
36
|
+
import '../chunk-MXI3XWV6.js';
|
|
37
|
+
import '../chunk-F4CZQD3T.js';
|
|
38
|
+
import '../chunk-BSMW3PX2.js';
|
|
39
39
|
import '../chunk-G5SUWZEU.js';
|
|
40
40
|
import '../chunk-IFGTRL2I.js';
|
|
41
|
-
import '../chunk-
|
|
41
|
+
import '../chunk-5XHQBCB5.js';
|
|
42
42
|
import '../chunk-WD3L5QSU.js';
|
|
43
43
|
import '../chunk-7RGTAEG6.js';
|
|
44
44
|
import '../chunk-G5SYFFMD.js';
|
|
45
|
-
import '../chunk-
|
|
46
|
-
import '../chunk-
|
|
47
|
-
import '../chunk-
|
|
45
|
+
import '../chunk-MMOWIRHP.js';
|
|
46
|
+
import '../chunk-J4WKNJHO.js';
|
|
47
|
+
import '../chunk-VJRL6ZK6.js';
|
|
48
48
|
import '../chunk-F3D25RGM.js';
|
|
49
49
|
import '../chunk-3TXEJN4W.js';
|
|
50
50
|
import '../chunk-ISHJITXJ.js';
|
|
@@ -52,22 +52,22 @@ import '../chunk-LNFKL23K.js';
|
|
|
52
52
|
import '../chunk-JRN5QF4C.js';
|
|
53
53
|
import '../chunk-NUELZWCF.js';
|
|
54
54
|
import '../chunk-VT6G5AJV.js';
|
|
55
|
-
import { resolveSettings } from '../chunk-
|
|
55
|
+
import { resolveSettings } from '../chunk-6ARPZHOV.js';
|
|
56
56
|
import '../chunk-4GY63JU6.js';
|
|
57
|
-
import '../chunk-
|
|
57
|
+
import '../chunk-JIQUF3X2.js';
|
|
58
58
|
import { deployedBase } from '../chunk-5KRMNUL4.js';
|
|
59
59
|
import { DEFAULT_HARNESS_ID } from '../chunk-C5HFK34M.js';
|
|
60
60
|
import '../chunk-MWXYN6NY.js';
|
|
61
|
-
import { resolveSkWorkspaceConfig, resolveAgentDir } from '../chunk-
|
|
61
|
+
import { resolveSkWorkspaceConfig, resolveAgentDir } from '../chunk-6SXSVKQY.js';
|
|
62
62
|
import '../chunk-L5VSIPQD.js';
|
|
63
63
|
import { harnessNameForHarnessId } from '../chunk-VTETQCR6.js';
|
|
64
|
-
import '../chunk-
|
|
65
|
-
import '../chunk-
|
|
64
|
+
import '../chunk-E2EC6SAX.js';
|
|
65
|
+
import '../chunk-GNUA7XT2.js';
|
|
66
66
|
import '../chunk-RVRB27AN.js';
|
|
67
67
|
import '../chunk-V5KG6CCV.js';
|
|
68
68
|
import '../chunk-VSX2G7LA.js';
|
|
69
69
|
import '../chunk-RXGPFAMN.js';
|
|
70
|
-
import '../chunk-
|
|
70
|
+
import '../chunk-SGI5MRKP.js';
|
|
71
71
|
import '../chunk-C3CAXQMA.js';
|
|
72
72
|
import '../chunk-BOFL7GIF.js';
|
|
73
73
|
import '../chunk-NSBPE2FW.js';
|
|
@@ -1,32 +1,32 @@
|
|
|
1
|
-
export { buildWorkspaceMcpServer, buildWorkspaceMcpStdioServer, buildWorkspaceToolDefs, runMcpServerStdio } from '../../chunk-
|
|
2
|
-
import '../../chunk-
|
|
3
|
-
import '../../chunk-
|
|
1
|
+
export { buildWorkspaceMcpServer, buildWorkspaceMcpStdioServer, buildWorkspaceToolDefs, runMcpServerStdio } from '../../chunk-GTGWRKMJ.js';
|
|
2
|
+
import '../../chunk-7I5PNB2G.js';
|
|
3
|
+
import '../../chunk-O7QZI6MQ.js';
|
|
4
4
|
import '../../chunk-WYZXSJBK.js';
|
|
5
|
-
import '../../chunk-
|
|
6
|
-
import '../../chunk-
|
|
5
|
+
import '../../chunk-GTAHU4N4.js';
|
|
6
|
+
import '../../chunk-HQAPUPBE.js';
|
|
7
7
|
import '../../chunk-KW37WNXY.js';
|
|
8
8
|
import '../../chunk-3MWQKQUB.js';
|
|
9
|
-
import '../../chunk-
|
|
10
|
-
import '../../chunk-
|
|
11
|
-
import '../../chunk-
|
|
9
|
+
import '../../chunk-PTJTOPE5.js';
|
|
10
|
+
import '../../chunk-USSP43U3.js';
|
|
11
|
+
import '../../chunk-VXYZ5M7Z.js';
|
|
12
12
|
import '../../chunk-2M3VLKT2.js';
|
|
13
|
-
import '../../chunk-
|
|
14
|
-
import '../../chunk-
|
|
15
|
-
import '../../chunk-
|
|
16
|
-
import '../../chunk-
|
|
17
|
-
import '../../chunk-
|
|
13
|
+
import '../../chunk-4BFEPZ6J.js';
|
|
14
|
+
import '../../chunk-YN6N3RBM.js';
|
|
15
|
+
import '../../chunk-TCH5UDKT.js';
|
|
16
|
+
import '../../chunk-U3UDOX6I.js';
|
|
17
|
+
import '../../chunk-65UAC3ZR.js';
|
|
18
18
|
import '../../chunk-LOO5CB5M.js';
|
|
19
19
|
import '../../chunk-KSUT5KAE.js';
|
|
20
|
-
import '../../chunk-
|
|
20
|
+
import '../../chunk-OY22B7E2.js';
|
|
21
21
|
import '../../chunk-5DE3DGVR.js';
|
|
22
22
|
import '../../chunk-7DN6JKP2.js';
|
|
23
|
-
import '../../chunk-
|
|
24
|
-
import '../../chunk-
|
|
25
|
-
import '../../chunk-
|
|
26
|
-
import '../../chunk-
|
|
23
|
+
import '../../chunk-WW5NAU6N.js';
|
|
24
|
+
import '../../chunk-MXI3XWV6.js';
|
|
25
|
+
import '../../chunk-F4CZQD3T.js';
|
|
26
|
+
import '../../chunk-BSMW3PX2.js';
|
|
27
27
|
import '../../chunk-G5SUWZEU.js';
|
|
28
28
|
import '../../chunk-IFGTRL2I.js';
|
|
29
|
-
import '../../chunk-
|
|
29
|
+
import '../../chunk-5XHQBCB5.js';
|
|
30
30
|
import '../../chunk-WD3L5QSU.js';
|
|
31
31
|
import '../../chunk-7RGTAEG6.js';
|
|
32
32
|
import '../../chunk-G5SYFFMD.js';
|
|
@@ -34,22 +34,22 @@ import '../../chunk-LNFKL23K.js';
|
|
|
34
34
|
import '../../chunk-JRN5QF4C.js';
|
|
35
35
|
import '../../chunk-NUELZWCF.js';
|
|
36
36
|
import '../../chunk-VT6G5AJV.js';
|
|
37
|
-
import '../../chunk-
|
|
37
|
+
import '../../chunk-6ARPZHOV.js';
|
|
38
38
|
import '../../chunk-4GY63JU6.js';
|
|
39
|
-
import '../../chunk-
|
|
39
|
+
import '../../chunk-JIQUF3X2.js';
|
|
40
40
|
import '../../chunk-5KRMNUL4.js';
|
|
41
41
|
import '../../chunk-C5HFK34M.js';
|
|
42
42
|
import '../../chunk-MWXYN6NY.js';
|
|
43
|
-
import '../../chunk-
|
|
43
|
+
import '../../chunk-6SXSVKQY.js';
|
|
44
44
|
import '../../chunk-L5VSIPQD.js';
|
|
45
45
|
import '../../chunk-VTETQCR6.js';
|
|
46
|
-
import '../../chunk-
|
|
47
|
-
import '../../chunk-
|
|
46
|
+
import '../../chunk-E2EC6SAX.js';
|
|
47
|
+
import '../../chunk-GNUA7XT2.js';
|
|
48
48
|
import '../../chunk-RVRB27AN.js';
|
|
49
49
|
import '../../chunk-V5KG6CCV.js';
|
|
50
50
|
import '../../chunk-VSX2G7LA.js';
|
|
51
51
|
import '../../chunk-RXGPFAMN.js';
|
|
52
|
-
import '../../chunk-
|
|
52
|
+
import '../../chunk-SGI5MRKP.js';
|
|
53
53
|
import '../../chunk-C3CAXQMA.js';
|
|
54
54
|
import '../../chunk-BOFL7GIF.js';
|
|
55
55
|
import '../../chunk-NSBPE2FW.js';
|
|
@@ -126,7 +126,7 @@ function buildOmpToolSet(plugin) {
|
|
|
126
126
|
description: "List all mounts declared in skaile.yaml with their mount status.",
|
|
127
127
|
parameters: {},
|
|
128
128
|
handler: async () => {
|
|
129
|
-
const { mountList } = await import('../../connectors-
|
|
129
|
+
const { mountList } = await import('../../connectors-HU5MHSUJ.js');
|
|
130
130
|
return (await mountList(plugin.connectorManager)).content[0].text;
|
|
131
131
|
}
|
|
132
132
|
},
|
|
@@ -135,7 +135,7 @@ function buildOmpToolSet(plugin) {
|
|
|
135
135
|
description: "Sync a mount (pull latest from remote).",
|
|
136
136
|
parameters: { mount_id: { type: "string" } },
|
|
137
137
|
handler: async ({ mount_id }) => {
|
|
138
|
-
const { mountSync } = await import('../../connectors-
|
|
138
|
+
const { mountSync } = await import('../../connectors-HU5MHSUJ.js');
|
|
139
139
|
return (await mountSync(plugin.connectorManager, mount_id)).content[0].text;
|
|
140
140
|
}
|
|
141
141
|
},
|
|
@@ -144,7 +144,7 @@ function buildOmpToolSet(plugin) {
|
|
|
144
144
|
description: "List all available flow definitions from ai-assets.",
|
|
145
145
|
parameters: {},
|
|
146
146
|
handler: async () => {
|
|
147
|
-
const { flowList } = await import('../../flows-
|
|
147
|
+
const { flowList } = await import('../../flows-GVOVQGQW.js');
|
|
148
148
|
return (await flowList(plugin.projectDir)).content[0].text;
|
|
149
149
|
}
|
|
150
150
|
},
|
|
@@ -153,7 +153,7 @@ function buildOmpToolSet(plugin) {
|
|
|
153
153
|
description: "List past flow run sessions for this workspace.",
|
|
154
154
|
parameters: {},
|
|
155
155
|
handler: async () => {
|
|
156
|
-
const { flowListSessions } = await import('../../flows-
|
|
156
|
+
const { flowListSessions } = await import('../../flows-GVOVQGQW.js');
|
|
157
157
|
return (await flowListSessions(plugin.projectDir)).content[0].text;
|
|
158
158
|
}
|
|
159
159
|
},
|
|
@@ -162,7 +162,7 @@ function buildOmpToolSet(plugin) {
|
|
|
162
162
|
description: "List all skills in the ai-assets catalog.",
|
|
163
163
|
parameters: {},
|
|
164
164
|
handler: async () => {
|
|
165
|
-
const { skillList } = await import('../../skills-
|
|
165
|
+
const { skillList } = await import('../../skills-6QTKFMLW.js');
|
|
166
166
|
return (await skillList(plugin.projectDir)).content[0].text;
|
|
167
167
|
}
|
|
168
168
|
},
|
|
@@ -171,7 +171,7 @@ function buildOmpToolSet(plugin) {
|
|
|
171
171
|
description: "Search skills by name, description, or keywords.",
|
|
172
172
|
parameters: { query: { type: "string" } },
|
|
173
173
|
handler: async ({ query }) => {
|
|
174
|
-
const { skillSearch } = await import('../../skills-
|
|
174
|
+
const { skillSearch } = await import('../../skills-6QTKFMLW.js');
|
|
175
175
|
return (await skillSearch(plugin.projectDir, query)).content[0].text;
|
|
176
176
|
}
|
|
177
177
|
},
|
|
@@ -180,7 +180,7 @@ function buildOmpToolSet(plugin) {
|
|
|
180
180
|
description: "Show the full SKILL.md content for a skill.",
|
|
181
181
|
parameters: { skill_id: { type: "string" } },
|
|
182
182
|
handler: async ({ skill_id }) => {
|
|
183
|
-
const { skillShow } = await import('../../skills-
|
|
183
|
+
const { skillShow } = await import('../../skills-6QTKFMLW.js');
|
|
184
184
|
return (await skillShow(plugin.projectDir, skill_id)).content[0].text;
|
|
185
185
|
}
|
|
186
186
|
},
|
|
@@ -189,7 +189,7 @@ function buildOmpToolSet(plugin) {
|
|
|
189
189
|
description: "List connectors declared in skaile.yaml as {connected, failed, notice?}. A host-managed mount in `connected` carries `health` {status: ok|stale|failed, errorClass, checkedAt}; if it is not ok, tell the user and do not write to it. `failed` holds connectors that did not connect this session, with the failure reason \u2014 their mount paths are dead directories, not synced workspaces.",
|
|
190
190
|
parameters: {},
|
|
191
191
|
handler: async () => {
|
|
192
|
-
const { connectorList } = await import('../../connectors-
|
|
192
|
+
const { connectorList } = await import('../../connectors-HU5MHSUJ.js');
|
|
193
193
|
return (await connectorList(plugin.connectorManager)).content[0].text;
|
|
194
194
|
}
|
|
195
195
|
},
|
|
@@ -198,7 +198,7 @@ function buildOmpToolSet(plugin) {
|
|
|
198
198
|
description: "Read content from a connector by path.",
|
|
199
199
|
parameters: { connector_id: { type: "string" }, path: { type: "string" } },
|
|
200
200
|
handler: async ({ connector_id, path }) => {
|
|
201
|
-
const { connectorRead } = await import('../../connectors-
|
|
201
|
+
const { connectorRead } = await import('../../connectors-HU5MHSUJ.js');
|
|
202
202
|
return (await connectorRead(plugin.connectorManager, connector_id, path)).content[0].text;
|
|
203
203
|
}
|
|
204
204
|
},
|
|
@@ -215,7 +215,7 @@ function buildOmpToolSet(plugin) {
|
|
|
215
215
|
operation,
|
|
216
216
|
args
|
|
217
217
|
}) => {
|
|
218
|
-
const { connectorExec } = await import('../../connectors-
|
|
218
|
+
const { connectorExec } = await import('../../connectors-HU5MHSUJ.js');
|
|
219
219
|
return (await connectorExec(plugin.connectorManager, connector_id, operation, args ?? {})).content[0].text;
|
|
220
220
|
}
|
|
221
221
|
},
|
|
@@ -271,7 +271,7 @@ async function handleSlashCommand(plugin, group, args) {
|
|
|
271
271
|
}
|
|
272
272
|
}
|
|
273
273
|
async function handleFlowCommand(plugin, sub, rest) {
|
|
274
|
-
const { flowList, flowShow, flowListSessions, flowGetSession } = await import('../../flows-
|
|
274
|
+
const { flowList, flowShow, flowListSessions, flowGetSession } = await import('../../flows-GVOVQGQW.js');
|
|
275
275
|
if (!sub || sub === "list") return (await flowList(plugin.projectDir)).content[0].text;
|
|
276
276
|
if (sub === "show" && rest[0])
|
|
277
277
|
return (await flowShow(plugin.projectDir, rest[0])).content[0].text;
|
|
@@ -281,7 +281,7 @@ async function handleFlowCommand(plugin, sub, rest) {
|
|
|
281
281
|
return "Usage: /flow list | show <id> | sessions | session <runId>";
|
|
282
282
|
}
|
|
283
283
|
async function handleConnectorCommand(plugin, sub, rest) {
|
|
284
|
-
const { connectorList, connectorRead, connectorExec, connectorDescribe } = await import('../../connectors-
|
|
284
|
+
const { connectorList, connectorRead, connectorExec, connectorDescribe } = await import('../../connectors-HU5MHSUJ.js');
|
|
285
285
|
if (!sub || sub === "list") return (await connectorList(plugin.connectorManager)).content[0].text;
|
|
286
286
|
if (sub === "read" && rest[0] && rest[1])
|
|
287
287
|
return (await connectorRead(plugin.connectorManager, rest[0], rest[1])).content[0].text;
|
|
@@ -300,7 +300,7 @@ async function handleConnectorCommand(plugin, sub, rest) {
|
|
|
300
300
|
return "Usage: /connector list | read <id> <path> | exec <id> <op> [json-args] | describe <id>";
|
|
301
301
|
}
|
|
302
302
|
async function handleSkillCommand(plugin, sub, rest) {
|
|
303
|
-
const { skillList, skillShow, skillSearch } = await import('../../skills-
|
|
303
|
+
const { skillList, skillShow, skillSearch } = await import('../../skills-6QTKFMLW.js');
|
|
304
304
|
if (sub === "run" && rest[0])
|
|
305
305
|
return (await skillShow(plugin.projectDir, rest[0])).content[0].text;
|
|
306
306
|
if (!sub || sub === "list") return (await skillList(plugin.projectDir)).content[0].text;
|
|
@@ -311,7 +311,7 @@ async function handleSkillCommand(plugin, sub, rest) {
|
|
|
311
311
|
return "Usage: /skill list | show <id> | search <query> | run <id>";
|
|
312
312
|
}
|
|
313
313
|
async function handleMountsCommand(plugin, sub, rest) {
|
|
314
|
-
const { mountList, mountSync, mountStatus } = await import('../../connectors-
|
|
314
|
+
const { mountList, mountSync, mountStatus } = await import('../../connectors-HU5MHSUJ.js');
|
|
315
315
|
if (!sub || sub === "list") return (await mountList(plugin.connectorManager)).content[0].text;
|
|
316
316
|
if (sub === "sync" && rest[0])
|
|
317
317
|
return (await mountSync(plugin.connectorManager, rest[0])).content[0].text;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { PluginStore, WorkspacePlugin, buildClaudePluginFiles, resolveProjectDir } from '../chunk-
|
|
1
|
+
export { PluginStore, WorkspacePlugin, buildClaudePluginFiles, resolveProjectDir } from '../chunk-Z4FERR4U.js';
|
|
2
2
|
export { err, ok, okJson } from '../chunk-3MWQKQUB.js';
|
|
3
3
|
import '../chunk-C5HFK34M.js';
|
|
4
|
-
import '../chunk-
|
|
4
|
+
import '../chunk-SGI5MRKP.js';
|
|
5
5
|
import '../chunk-C3CAXQMA.js';
|
|
6
6
|
import '../chunk-BOFL7GIF.js';
|
|
7
7
|
import '../chunk-NSBPE2FW.js';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@skaile/workspaces",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.6.0",
|
|
4
4
|
"description": "Skaile workspaces runtime — types, core, bridge, runner, store, connectors, and supporting layers as one publishable package",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"packageManager": "bun@1.3.9",
|