diff --git a/common.go b/common.go index 4b2215a..a2f71f2 100644 --- a/common.go +++ b/common.go @@ -14,12 +14,12 @@ func (rs *RepoStatus) Changed() (string, bool) { return "", false } - return rs.Changes(), rs.changed + return rs.getChanges(), rs.changed } // keeps a human readable list of things that have -// changed -func (rs *RepoStatus) Changes() string { +// changed. todo: timestampe these? +func (rs *RepoStatus) getChanges() string { return rs.changes } @@ -165,3 +165,26 @@ func (rs *RepoStatus) Build() bool { log.Warn("build failed", name) return false } + +func (rs *RepoStatus) GetGoSumStatus() string { + return rs.goSumStatus.String() +} + +func (rs *RepoStatus) SetGoSumStatus(s string) { + rs.goSumStatus.SetText(s) +} + +func (rs *RepoStatus) GetTargetVersion() string { + return rs.targetReleaseVersion.String() +} + +func (rs *RepoStatus) IncrementVersion() bool { + return rs.setTag() +} + +// TODO: run this through the sanity check! +func (rs *RepoStatus) SetTargetVersion(s string) { + // todo: redo setTag to do increment logic + // func (rs *RepoStatus) setTag() bool { + rs.targetReleaseVersion.SetText(s) +} diff --git a/draw.go b/draw.go index cc57eae..427b65c 100644 --- a/draw.go +++ b/draw.go @@ -31,7 +31,3 @@ func (rs *RepoStatus) drawGitStatus(box *gui.Node) { rs.speed = gadgets.NewOneLiner(newgrid, "refresh speed =") rs.speedActual = gadgets.NewOneLiner(newgrid, "speed actual =") } - -func (rs *RepoStatus) SetGoSumStatus(s string) { - rs.goSumStatus.SetText(s) -} diff --git a/new.go b/new.go index efaf988..cd23bbe 100644 --- a/new.go +++ b/new.go @@ -15,14 +15,16 @@ func init() { windowMap = make(map[string]*RepoStatus) } -func ListAll() { +// deprecate this +func ListAllOld() { for path, rs := range windowMap { log.Warn(rs.GetMasterVersion(), path) } } // returns the object for the path -func FindPath(path string) *RepoStatus { +// deprecate this +func FindPathOld(path string) *RepoStatus { if windowMap[path] == nil { log.Log(INFO, "FindPath() not initialized yet", path) return nil