diff options
| author | Jeff Carr <[email protected]> | 2025-10-19 05:08:00 -0500 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2025-10-19 05:08:00 -0500 |
| commit | 2bbc498b02cbbe3ba68de391bffbe79ab0f226fc (patch) | |
| tree | 3a09151aeb7a1294e83d61e847e74f9a982b837b /exit.go | |
| parent | c78eff62bb86594f71f9ff43ff151820ae8e94d9 (diff) | |
new argvv0.0.125
Diffstat (limited to 'exit.go')
| -rw-r--r-- | exit.go | 9 |
1 files changed, 4 insertions, 5 deletions
@@ -1,7 +1,7 @@ package main import ( - "os" + "fmt" "go.wit.com/lib/protobuf/gitpb" "go.wit.com/log" @@ -10,18 +10,17 @@ import ( func okExit(check *gitpb.Repo, msg string) { log.Info("exit() go-mod-clean on", check.Namespace, "ok") log.DaemonMode(true) - log.Info(msg) - os.Exit(0) + me.argv.GoodExit(msg) } func badExit(check *gitpb.Repo, err error) { log.DaemonMode(true) - log.Info("go-mod-clean failed: ", err, forge.Config.ReposDir) if check != nil { if argv.Strict != nil { // if in strict mode, remove the go.mod and go.sum eraseGoMod(check) } } - os.Exit(-1) + s := fmt.Sprintf("failed: %s", me.forge.Config.ReposDir) + me.argv.BadExit(s, err) } |
