diff options
| -rw-r--r-- | generate.off (renamed from generate.go) | 0 | ||||
| -rw-r--r-- | tablePull.go | 14 |
2 files changed, 8 insertions, 6 deletions
diff --git a/generate.go b/generate.off index 6158d14..6158d14 100644 --- a/generate.go +++ b/generate.off diff --git a/tablePull.go b/tablePull.go index ebe062f..62b69c3 100644 --- a/tablePull.go +++ b/tablePull.go @@ -3,8 +3,7 @@ package forgepb import ( - "path/filepath" - + "go.wit.com/lib/config" "go.wit.com/lib/protobuf/gitpb" "go.wit.com/log" ) @@ -30,11 +29,14 @@ func (f *Forge) makePullTable(pb *gitpb.Repos) *gitpb.ReposTable { // col.SetTitle("mver") col.Width = 15 - col = t.AddStringFunc("blah", func(r *gitpb.Repo) string { - _, base := filepath.Split(r.Namespace) - return base + col = t.AddStringFunc("age", func(r *gitpb.Repo) string { + if r.IsDirty() { + return "*" + } + dur := r.NewestAge() + return config.FormatDuration(dur) }) - col.Width = 9 + col.Width = 3 col = t.AddDevelVersion() col.Width = 15 |
