MCPcopy Index your code
hub / github.com/chain/Core / Parse

Function Parse

env/env.go:190–198  ·  view source on GitHub ↗

Parse parses known env vars and assigns the values to the variables that were previously registered. If any values cannot be parsed, Parse prints an error message for each one and exits the process with status 1.

()

Source from the content-addressed store, hash-verified

188// Parse prints an error message for each one
189// and exits the process with status 1.
190func Parse() {
191 ok := true
192 for _, f := range funcs {
193 ok = f() && ok
194 }
195 if !ok {
196 os.Exit(1)
197 }
198}

Callers 10

TestIntFunction · 0.70
TestIntVarFunction · 0.70
TestBoolFunction · 0.70
TestBoolVarFunction · 0.70
TestURLFunction · 0.70
TestURLVarFunction · 0.70
TestStringFunction · 0.70
TestStringVarFunction · 0.70
TestStringSliceFunction · 0.70
TestStringSliceVarFunction · 0.70

Calls 1

fFunction · 0.85

Tested by 10

TestIntFunction · 0.56
TestIntVarFunction · 0.56
TestBoolFunction · 0.56
TestBoolVarFunction · 0.56
TestURLFunction · 0.56
TestURLVarFunction · 0.56
TestStringFunction · 0.56
TestStringVarFunction · 0.56
TestStringSliceFunction · 0.56
TestStringSliceVarFunction · 0.56