MCPcopy Create free account
hub / github.com/caarlos0/env / parseKeyForOption

Function parseKeyForOption

env.go:656–659  ·  view source on GitHub ↗

split the env tag's key into the expected key and desired option, if any.

(key string)

Source from the content-addressed store, hash-verified

654
655// split the env tag's key into the expected key and desired option, if any.
656func parseKeyForOption(key string) (string, []string) {
657 opts := strings.Split(key, ",")
658 return opts[0], opts[1:]
659}
660
661func getFromFile(filename string) (value string, err error) {
662 b, err := os.ReadFile(filename)

Callers 1

parseFieldParamsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected