MCPcopy Index your code
hub / github.com/Opencode-DCP/opencode-dynamic-context-pruning / mergeCommands

Function mergeCommands

lib/config.ts:861–873  ·  view source on GitHub ↗
(
    base: PluginConfig["commands"],
    override?: Partial<PluginConfig["commands"]>,
)

Source from the content-addressed store, hash-verified

859}
860
861function mergeCommands(
862 base: PluginConfig["commands"],
863 override?: Partial<PluginConfig["commands"]>,
864): PluginConfig["commands"] {
865 if (!override) {
866 return base
867 }
868
869 return {
870 enabled: override.enabled ?? base.enabled,
871 protectedTools: [...new Set([...base.protectedTools, ...(override.protectedTools ?? [])])],
872 }
873}
874
875function mergeManualMode(
876 base: PluginConfig["manualMode"],

Callers 1

mergeLayerFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected