reorder the 'end' var

This commit is contained in:
Jeff Carr 2025-09-12 10:17:03 -05:00
parent 7431308823
commit 692264d1f1
1 changed files with 15 additions and 15 deletions

View File

@ -188,6 +188,21 @@ func (f *Forge) printRepoToTable(repo *gitpb.Repo, sizes []int, full bool) {
}
}
switch repo.GetState() {
case "PERFECT":
case "unchanged":
case "dirty":
case "unknown branches":
if repo.CurrentTag == nil {
end += "(" + repo.GetState() + ") "
} else {
end += "(unknown branch " + repo.CurrentTag.Refname + ") "
}
// end += "(invalid tag) "
default:
end += "(" + repo.GetState() + ") "
}
if repo.GetMasterBranchName() != "master" && repo.GetMasterBranchName() != "main" {
end += "(m:" + repo.GetMasterBranchName() + ") "
}
@ -205,21 +220,6 @@ func (f *Forge) printRepoToTable(repo *gitpb.Repo, sizes []int, full bool) {
end += "(deb:" + debname + ") "
}
switch repo.GetState() {
case "PERFECT":
case "unchanged":
case "dirty":
case "unknown branches":
if repo.CurrentTag == nil {
end += "(" + repo.GetState() + ") "
} else {
end += "(unknown branch " + repo.CurrentTag.Refname + ") "
}
// end += "(invalid tag) "
default:
end += "(" + repo.GetState() + ") "
}
log.Info(cobol.TerminalChomp(start + " " + end))
}