more logic for 'READY' state

Signed-off-by: Jeff Carr <jcarr@wit.com>
This commit is contained in:
Jeff Carr 2024-01-31 03:00:10 -06:00
parent 576580772e
commit 417f5be49b
2 changed files with 12 additions and 3 deletions

View File

@ -18,6 +18,9 @@ func CheckReady() bool {
lastS := release.current.status.GetLastTagVersion() lastS := release.current.status.GetLastTagVersion()
log.Info("repo:", release.current.String(), goSumS, dirtyS, lastS) log.Info("repo:", release.current.String(), goSumS, dirtyS, lastS)
if goSumS == "READY" {
return true
}
if release.current.status.ReadOnly() { if release.current.status.ReadOnly() {
log.Info("\trepo is read only") log.Info("\trepo is read only")
return false return false

View File

@ -200,10 +200,12 @@ func createReleaseBox(box *gui.Node) {
} }
}) })
/*
release.sendVersionB = release.grid.NewButton("send version", func() { release.sendVersionB = release.grid.NewButton("send version", func() {
log.Info("set version()") log.Info("set version()")
release.current.status.SetVersion(partS[0], partS[1], partS[2], release.reason.String()) release.current.status.SetVersion(partS[0], partS[1], partS[2], release.reason.String())
}) })
*/
release.grid.NewButton("set ignore", func() { release.grid.NewButton("set ignore", func() {
tmp := release.current.getGoSumStatus() tmp := release.current.getGoSumStatus()
@ -212,6 +214,7 @@ func createReleaseBox(box *gui.Node) {
release.whitelist[release.current.String()] = release.current release.whitelist[release.current.String()] = release.current
}) })
/*
release.checkDirtyB = release.grid.NewButton("checkDirty()", func() { release.checkDirtyB = release.grid.NewButton("checkDirty()", func() {
buttonDisable() buttonDisable()
if release.current.checkDirty() { if release.current.checkDirty() {
@ -221,6 +224,7 @@ func createReleaseBox(box *gui.Node) {
} }
buttonEnable() buttonEnable()
}) })
*/
release.checkSafeB = release.grid.NewButton("checkSafeGoSumRemake()", func() { release.checkSafeB = release.grid.NewButton("checkSafeGoSumRemake()", func() {
buttonDisable() buttonDisable()
@ -235,6 +239,10 @@ func createReleaseBox(box *gui.Node) {
log.Info("repo has go.sum requirements that are clean") log.Info("repo has go.sum requirements that are clean")
release.current.setGoSumStatus("CLEAN") release.current.setGoSumStatus("CLEAN")
} else { } else {
}
buttonEnable()
})
/*
if missing == "" { if missing == "" {
log.Info("BAD VERSION repo has go.sum requirements that are screwed up.", tmp) log.Info("BAD VERSION repo has go.sum requirements that are screwed up.", tmp)
if release.current.getGoSumStatus() == "BAD" { if release.current.getGoSumStatus() == "BAD" {
@ -264,9 +272,7 @@ func createReleaseBox(box *gui.Node) {
} }
// addRepo(reposgrid, missing, "master", "master", "master") // addRepo(reposgrid, missing, "master", "master", "master")
} }
} */
buttonEnable()
})
release.grid.NewButton("CheckPrimativeGoMod()", func() { release.grid.NewButton("CheckPrimativeGoMod()", func() {
tmp := release.current.String() tmp := release.current.String()
log.Info("Run CheckGoSum on repo:", tmp) log.Info("Run CheckGoSum on repo:", tmp)