summaryrefslogtreecommitdiff
path: root/doBuild.debian.go
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2025-10-24 02:36:25 -0500
committerJeff Carr <[email protected]>2025-10-24 02:36:25 -0500
commitd858946501f58a932521b05534c0a1717476adba (patch)
tree7ab0bdc145220ef44306b15211d46ddae7cfe447 /doBuild.debian.go
parent2ae3b613b8e1cac099eb029ad1baa18cc72bec6d (diff)
try to fix .deb build counter
Diffstat (limited to 'doBuild.debian.go')
-rw-r--r--doBuild.debian.go19
1 files changed, 18 insertions, 1 deletions
diff --git a/doBuild.debian.go b/doBuild.debian.go
index a34bc43..e8f497d 100644
--- a/doBuild.debian.go
+++ b/doBuild.debian.go
@@ -5,6 +5,7 @@ package main
import (
"errors"
+ "fmt"
"os"
"path/filepath"
"strconv"
@@ -24,33 +25,42 @@ func findBuildDeb() *gitpb.Repos {
initForge()
var dumbtable [][]string
+ dumbtable = append(dumbtable, []string{"FullPath", "version", "reason"})
found := gitpb.NewRepos()
for check := range me.forge.Repos.IterAll() {
+ var reason string
if me.forge.Config.IsReadOnly(check.GetNamespace()) {
+ reason = "readonly"
continue
}
if me.forge.Config.IsPrivate(check.GetNamespace()) {
if !argv.Build.Debian.Priv {
+ reason = "private"
continue
}
}
if !check.IsBinary() {
+ reason = "not-binary"
// can't build packages that aren't GO binaries
continue
}
if argv.Build.Debian.Arch != "" {
if check.IsGoPlugin() {
+ reason = "plugin"
continue
}
// mask some packages for arch builds
if strings.Contains(check.Namespace, "fyne") {
+ reason = "plugin"
continue
}
if strings.Contains(check.Namespace, "toolkit") {
+ reason = "broken"
continue
}
if strings.Contains(check.Namespace, "going2git") {
+ reason = "broken"
continue
}
}
@@ -61,8 +71,15 @@ func findBuildDeb() *gitpb.Repos {
if shouldBuild(check) == "yes" {
// need to build
} else {
+ var version string
+ bvers, err := getBuildVersion(check)
+ if err == nil {
+ version = check.DebianCurrentVersion(bvers)
+ } else {
+ version = fmt.Sprintf("err=(%v)", err)
+ }
// log.Info(check.FullPath, "not building for reasons: todo: get reason")
- dumbtable = append(dumbtable, []string{check.FullPath, "not building for reasons: todo: get reason"})
+ dumbtable = append(dumbtable, []string{check.FullPath, version, reason})
continue
}
}