summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--humanTable.go12
-rw-r--r--init.go2
2 files changed, 8 insertions, 6 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) "
diff --git a/init.go b/init.go
index 7b29c32..8d3342f 100644
--- a/init.go
+++ b/init.go
@@ -106,7 +106,7 @@ func (f *Forge) InitPB() {
} else {
log.Log(INFO, "forgepb.Init() FORGE_GOSRC ", os.Getenv("FORGE_GOSRC"), "(go.work = false)")
}
- f.Repos = new(gitpb.Repos)
+ f.Repos = gitpb.NewRepos()
f.Repos.ConfigLoad()
}