MCPcopy Create free account
hub / github.com/chainreactors/EvilProxy / runtimeConfigYAML

Function runtimeConfigYAML

internal/pluginhost/config.go:77–84  ·  view source on GitHub ↗
(item config.PluginInstanceConfig, enabled bool)

Source from the content-addressed store, hash-verified

75}
76
77func runtimeConfigYAML(item config.PluginInstanceConfig, enabled bool) []byte {
78 rawNode := normalizedConfigNode(item, enabled)
79 rawYAML := bytes.TrimSpace(mustMarshalYAML(rawNode))
80 if len(rawYAML) == 0 {
81 return append([]byte(nil), defaultRuntimeConfigYAML...)
82 }
83 return append(append([]byte(nil), rawYAML...), '\n')
84}
85
86func desiredPluginVersions(items map[string]runtimeItemConfig) map[string]string {
87 if len(items) == 0 {

Calls 2

normalizedConfigNodeFunction · 0.85
mustMarshalYAMLFunction · 0.85