MCPcopy
hub / github.com/opencloud-eu/opencloud / checkConfigPath

Function checkConfigPath

opencloud/pkg/init/functions.go:13–19  ·  view source on GitHub ↗
(configPath string)

Source from the content-addressed store, hash-verified

11)
12
13func checkConfigPath(configPath string) error {
14 targetPath := path.Join(configPath, configFilename)
15 if _, err := os.Stat(targetPath); err == nil {
16 return fmt.Errorf("config in %s already exists", targetPath)
17 }
18 return nil
19}
20
21func configExists(configPath string) bool {
22 targetPath := path.Join(configPath, configFilename)

Callers 1

CreateConfigFunction · 0.85

Calls 2

ErrorfMethod · 0.80
StatMethod · 0.65

Tested by

no test coverage detected