MCPcopy
hub / github.com/callstack/agent-device / resolveRemoteConfigDefaults

Function resolveRemoteConfigDefaults

src/utils/remote-config.ts:25–43  ·  view source on GitHub ↗
(options: {
  remoteConfig?: string;
  cwd: string;
  env: Record<string, string | undefined>;
})

Source from the content-addressed store, hash-verified

23}
24
25export function resolveRemoteConfigDefaults(options: {
26 remoteConfig?: string;
27 cwd: string;
28 env: Record<string, string | undefined>;
29}): Partial<CliFlags> {
30 if (!options.remoteConfig) {
31 return {};
32 }
33
34 const resolved = resolveRemoteConfigProfile({
35 configPath: options.remoteConfig,
36 cwd: options.cwd,
37 env: options.env,
38 });
39 return {
40 ...profileToCliFlags(resolved.profile),
41 remoteConfig: options.remoteConfig,
42 };
43}

Callers 1

resolveCliOptionsFunction · 0.90

Calls 2

profileToCliFlagsFunction · 0.85

Tested by

no test coverage detected