openclaw
Version:
Multi-channel AI gateway with extensible messaging integrations
3 lines • 892 B
JavaScript
import{t as adoptCurrentPluginMetadataSnapshotIfAbsent}from"./current-plugin-metadata-snapshot-CYi8VAby.mjs";import{i as completePluginMetadataSnapshot}from"./plugin-metadata-snapshot-CDKhemiT.mjs";import{u as readConfigFileSnapshotWithPluginMetadata}from"./io.runtime-BvSeVFIY.mjs";import"./config-DkZ8y8Gv.mjs";
//!src/cli/command-config-snapshot.ts
async function readCommandConfigSnapshot(e){const t=await readConfigFileSnapshotWithPluginMetadata(e);const n=completePluginMetadataSnapshot({snapshot:t.pluginMetadataSnapshot,config:t.snapshot.sourceConfig,env:process.env,workspaceDir:t.pluginMetadataSnapshot?.workspaceDir});if(n)adoptCurrentPluginMetadataSnapshotIfAbsent(n,{config:t.snapshot.sourceConfig,compatibleConfigs:[t.snapshot.config,t.snapshot.runtimeConfig],env:process.env,workspaceDir:n.workspaceDir});return{...t,pluginMetadataSnapshot:n}}export{readCommandConfigSnapshot};