diff --git a/config.go b/config.go index 599db3e..4034f66 100644 --- a/config.go +++ b/config.go @@ -7,7 +7,6 @@ import ( "errors" "os" "path/filepath" - "time" "go.wit.com/log" ) @@ -120,9 +119,6 @@ func (c *ForgeConfigs) ConfigLoad() error { if _, err := os.Stat(cpath); err == nil { log.Info("Something has gone wrong. Your", os.Getenv("FORGE_CONFIG"), "directory exists") log.Info("However, the config files could not be loaded") - time.Sleep(2 * time.Second) - os.Exit(-1) - // return errors.New("config files can not be loaded from" + os.Getenv("FORGE_CONFIG")) } // first time user. make a template config file diff --git a/goSrcScan.go b/goSrcScan.go index 5599c46..c13dce3 100644 --- a/goSrcScan.go +++ b/goSrcScan.go @@ -37,7 +37,7 @@ func (f *Forge) ScanGoSrc() (bool, error) { newcount, err := f.rillScanDirs(gopaths) if err != nil { log.Info("go src dir problem. exit for now?", err) - os.Exit(-1) + return false, err } if newcount != 0 { log.Info("forge go src scan found", newcount, "repos") diff --git a/init.go b/init.go index 76df111..559b595 100644 --- a/init.go +++ b/init.go @@ -28,7 +28,6 @@ func Init() *Forge { if err := f.Machine.ConfigLoad(); err != nil { log.Warn("zoopb.ConfigLoad() failed", err) - os.Exit(-1) } f.Machine.InitWit() return f @@ -44,7 +43,6 @@ func InitPB() *Forge { goSrcDir, err := f.findGoSrc() if err != nil { log.Warn("forge init() findGoSrc()", err) - os.Exit(-1) } os.Setenv("FORGE_GOSRC", goSrcDir) } @@ -69,7 +67,6 @@ func InitPB() *Forge { f.Config = new(ForgeConfigs) if err := f.Config.ConfigLoad(); err != nil { log.Warn("forgepb.ConfigLoad() failed", err) - os.Exit(-1) } if f.IsGoWork() {