MCPcopy Create free account
hub / github.com/nikivdev/go / resolveDocSpec

Function resolveDocSpec

cli/flow/main.go:1591–1600  ·  view source on GitHub ↗
(key string)

Source from the content-addressed store, hash-verified

1589}
1590
1591func resolveDocSpec(key string) (docSpec, bool) {
1592 normalized := strings.TrimSpace(strings.ToLower(key))
1593 normalized = strings.ReplaceAll(normalized, "_", "-")
1594 if alias, ok := docSpecAliases[normalized]; ok {
1595 normalized = alias
1596 }
1597
1598 spec, ok := docSpecs[normalized]
1599 return spec, ok
1600}
1601
1602func openDoc(ctx *snap.Context, spec docSpec) error {
1603 now := time.Now()

Callers 1

runOpenDocFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected