From c26a082e75058243adea5a94dd643c822a22e8fc Mon Sep 17 00:00:00 2001 From: Jeff Carr Date: Thu, 1 Feb 2024 15:39:06 -0600 Subject: [PATCH] self update at the end is triggered Signed-off-by: Jeff Carr --- releaseWindow.go | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/releaseWindow.go b/releaseWindow.go index 252d3f8..d59bd76 100644 --- a/releaseWindow.go +++ b/releaseWindow.go @@ -150,16 +150,18 @@ func createReleaseBox(box *gui.Node) { gopath := release.current.String() cmd := []string{"go", "get", "-v", gopath + "@" + release.version.String()} - log.Info("SHOULD RUN cmd HERE to update myself:", cmd) - log.Info("SHOULD RUN cmd HERE:", cmd) log.Info("SHOULD RUN cmd HERE:", cmd) - if release.guireleaser != nil { + if release.guireleaser == nil { + log.Info("CAN NOT SELF UPDATE HERE. cmd =", cmd) + return + } else { os.Unsetenv("GO111MODULE") log.Info("TRYING TO SELF UPDATE HERE. cmd =", cmd) err, out := release.guireleaser.status.RunCmd(cmd) if err == nil { - log.Info("SELF UPDATE WORKED\n", out) + log.Info("SELF UPDATE OK. out =", out) + log.Info("SELF UPDATE WORKED") } else { log.Info("SELF UPDATE FAILED err =", err) log.Info("SELF UPDATE FAILED out =", out)