MCPcopy Index your code
hub / github.com/github/github-mcp-server / AllTools

Method AllTools

pkg/inventory/registry.go:299–311  ·  view source on GitHub ↗

AllTools returns all tools without any filtering, sorted deterministically.

()

Source from the content-addressed store, hash-verified

297
298// AllTools returns all tools without any filtering, sorted deterministically.
299func (r *Inventory) AllTools() []ServerTool {
300 result := slices.Clone(r.tools)
301
302 // Sort deterministically: by toolset ID, then by tool name
303 sort.Slice(result, func(i, j int) bool {
304 if result[i].Toolset.ID != result[j].Toolset.ID {
305 return result[i].Toolset.ID < result[j].Toolset.ID
306 }
307 return result[i].Tool.Name < result[j].Tool.Name
308 })
309
310 return result
311}
312
313// AvailableToolsets returns the unique toolsets that have tools, in sorted order.
314// This is the ordered intersection of toolsets with reality - only toolsets that

Callers 4

AvailableToolsetsMethod · 0.95
TestNewRegistryWithToolsFunction · 0.80
TestAllToolsFunction · 0.80

Calls

no outgoing calls

Tested by 2

TestNewRegistryWithToolsFunction · 0.64
TestAllToolsFunction · 0.64