summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2025-10-26 20:03:05 -0500
committerJeff Carr <[email protected]>2025-10-26 20:03:05 -0500
commit9292d023b97783fc06ca5f21d67a03338ee10913 (patch)
tree56a9d8c351f7dcc0123100c0ac07b23016c0c1fd
parent13ab64473928e679caf8a79c87a1152386f953a0 (diff)
only build changed stuff
-rw-r--r--doBuild.go17
1 files changed, 13 insertions, 4 deletions
diff --git a/doBuild.go b/doBuild.go
index 3663a9e..c12b2b6 100644
--- a/doBuild.go
+++ b/doBuild.go
@@ -42,7 +42,7 @@ func doBuild() (string, error) {
}
tobuild := gitpb.NewRepos()
var simpletable [][]string
- simpletable = append(simpletable, []string{"debname", "version", " age", "smartver", "curb", "curver", "newb", "arch", "FullPath"})
+ simpletable = append(simpletable, []string{"debname", "version", " age", "smartver", "curb", "curver", "newb", "build", "arch", "FullPath"})
for i, line := range strings.Split(string(data), "\n") {
var path string
var debname string
@@ -98,15 +98,24 @@ func doBuild() (string, error) {
}
cmd := makeGoDebCmd(repo, newcount, "")
cmdstr := fmt.Sprintf("%v", cmd)
- simpletable = append(simpletable, []string{debname, p.Version, age, smartver, bcount, curver, newcount, arches, cmdstr})
+ build := "no"
+ if (smartver != curver) || repo.CheckDirty() {
+ build = "yes"
+ repo.DirtyList = cmd
+ tobuild.Clone(repo)
+ }
+
+ simpletable = append(simpletable, []string{debname, p.Version, age, smartver, bcount, curver, newcount, build, arches, cmdstr})
- repo.DirtyList = cmd
- tobuild.Clone(repo)
}
footer := cobol.SimpleTable(simpletable)
log.Info("simple build table footer:", footer)
+ if argv.DryRun {
+ return "dryrun", nil
+ }
+
// for r := range tobuild.IterAll() {
// log.Info(r.FullPath, r.DirtyList)
// }