diff options
| author | Jeff Carr <[email protected]> | 2025-01-19 00:36:32 -0600 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2025-01-19 00:36:32 -0600 |
| commit | bdf9d97cf9bf3e9bc0724b6f949089bb46923426 (patch) | |
| tree | 3c4360b2467bcf21c8285dc8f61b24de0f305c89 /humanTable.go | |
| parent | a822e1e4f072fbd735efd328e06fe2bf48a2d660 (diff) | |
reorder target to the end
Diffstat (limited to 'humanTable.go')
| -rw-r--r-- | humanTable.go | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/humanTable.go b/humanTable.go index 0bd9718..7a128fd 100644 --- a/humanTable.go +++ b/humanTable.go @@ -54,7 +54,7 @@ func (f *Forge) PrintHumanTableDirty(allr *gitpb.Repos) { var count int // log.Info(standardStart5("gopath", "cur name", "master", "user", "repo type")) - log.Info(standardTable8("repopath", "cur br", "age", "target", "master", "devel", "user", "curver", "repo type")) + log.Info(standardTable8("repopath", "cur br", "age", "master", "devel", "user", "curver", "target", "repo type")) // all := allr.SortByFullPath() all := allr.All() for all.Scan() { @@ -111,7 +111,7 @@ func standardTable8(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9 string) len5 := 16 len6 := 16 len7 := 16 - len8 := 16 + len8 := 12 len9 := 8 var s string if len(arg1) > len1 { @@ -139,12 +139,12 @@ func standardTable8(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9 string) if len(arg6) > len6 { arg6 = arg6[:len6] } - s += "%-" + fmt.Sprintf("%d", len6) + "s " + s += "%-" + fmt.Sprintf("%d", len6) + "s " if len(arg7) > len7 { arg7 = arg7[:len7] } - s += "%-" + fmt.Sprintf("%d", len7) + "s " + s += "%-" + fmt.Sprintf("%d", len7) + "s " if len(arg8) > len8 { arg8 = arg8[:len8] @@ -164,6 +164,8 @@ func (f *Forge) printRepoToTable(repo *gitpb.Repo) { if repo.IsDirty() { end += "(dirty) " } + + // shortened version numbers var mhort string = repo.GetMasterVersion() var dhort string = repo.GetDevelVersion() var uhort string = repo.GetUserVersion() @@ -178,7 +180,7 @@ func (f *Forge) printRepoToTable(repo *gitpb.Repo) { // age := shell.FormatDuration(time.Since(ctime)) age := shell.FormatDuration(repo.NewestAge()) - start := standardTable8(gopath, cname, age, thort, mhort, dhort, uhort, chort, rtype) + start := standardTable8(gopath, cname, age, mhort, dhort, uhort, chort, thort, rtype) if f.Config.IsReadOnly(repo.GetGoPath()) { end += "(readonly) " |
