MCPcopy Index your code
hub / github.com/abiosoft/colima / Load

Function Load

config/configmanager/configmanager.go:107–114  ·  view source on GitHub ↗

Load loads the config. Error is only returned if the config file exists but could not be loaded. No error is returned if the config file does not exist.

()

Source from the content-addressed store, hash-verified

105// Error is only returned if the config file exists but could not be loaded.
106// No error is returned if the config file does not exist.
107func Load() (c config.Config, err error) {
108 f := config.CurrentProfile().File()
109 if _, err := os.Stat(f); err != nil {
110 return c, nil
111 }
112
113 return LoadFrom(f)
114}
115
116// LoadInstance is like Load but returns the config of the currently running instance.
117func LoadInstance() (config.Config, error) {

Callers 2

prepareConfigFunction · 0.92
restart.goFile · 0.92

Calls 4

CurrentProfileFunction · 0.92
LoadFromFunction · 0.85
FileMethod · 0.65
StatMethod · 0.65

Tested by

no test coverage detected