MCPcopy Create free account
hub / github.com/Chat2AnyLLM/code-agent-manager / loadBundled

Function loadBundled

internal/repoconfig/repoconfig.go:215–234  ·  view source on GitHub ↗

---------- per-source loaders -----------------------------------------------

(kind entities.Kind)

Source from the content-addressed store, hash-verified

213// ---------- per-source loaders -----------------------------------------------
214
215func loadBundled(kind entities.Kind) (map[string]RepoEntry, error) {
216 var raw []byte
217 switch kind {
218 case entities.KindSkill:
219 raw = bundledSkillRepos
220 case entities.KindAgent:
221 raw = bundledAgentRepos
222 case entities.KindPlugin:
223 raw = bundledPluginRepos
224 case entities.KindPrompt:
225 raw = bundledPromptRepos
226 case entities.KindInstruction:
227 raw = bundledInstructionRepos
228 default:
229 // Unknown kinds return an empty map so config.yaml sources
230 // can still be loaded.
231 return make(map[string]RepoEntry), nil
232 }
233 return parseRepoJSON(raw)
234}
235
236// LoadLocalSource reads a JSON repo file from the given path, expanding ~.
237// Used for both config.yaml local sources and direct path lookups.

Callers 6

TestBundledSkillReposFunction · 0.85
TestBundledAgentReposFunction · 0.85
TestBundledPluginReposFunction · 0.85
LoadAllFunction · 0.85

Calls 1

parseRepoJSONFunction · 0.85

Tested by 5

TestBundledSkillReposFunction · 0.68
TestBundledAgentReposFunction · 0.68
TestBundledPluginReposFunction · 0.68