more rill. trying to improve logic
This commit is contained in:
parent
f3e7f02e16
commit
82f06c160a
46
TODO
46
TODO
|
@ -2,49 +2,13 @@ notes on what to fix next
|
||||||
|
|
||||||
go-args make patches for alexflint
|
go-args make patches for alexflint
|
||||||
|
|
||||||
forge checkout jcarr
|
forge checkout jcarr (alias username to 'user')
|
||||||
|
forge verify devel branches
|
||||||
|
|
||||||
|
fix going2go build
|
||||||
|
fix fyne build
|
||||||
|
|
||||||
go-mod-clean set ctime on files
|
go-mod-clean set ctime on files
|
||||||
go-mod-clean fix --purge to be used more often. put --purge in 'make clean' ?
|
go-mod-clean fix --purge to be used more often. put --purge in 'make clean' ?
|
||||||
|
|
||||||
guirelease try to figure out where the stupid output is coming from go-mod-clean
|
|
||||||
guireleaser change "title small" to the package being updated"
|
guireleaser change "title small" to the package being updated"
|
||||||
|
|
||||||
wit-test fix zookeeper build
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Running [go-mod-clean --strict] in go.wit.com/lib/gui/repolist
|
|
||||||
fixGoDeps() returned false
|
|
||||||
findNext() update needed go.wit.com/lib/protobuf/forgepb v0.0.48 vs v0.0.47-2-g9e81be8
|
|
||||||
findFix is true. running fixGoDeps()
|
|
||||||
Running [go-mod-clean --strict] in go.wit.com/lib/protobuf/forgepb
|
|
||||||
fixGoDeps() returned false
|
|
||||||
findNext() update needed go.wit.com/lib/protobuf/gitpb v0.0.51 vs v0.0.50-1-g8c06b25
|
|
||||||
findFix is true. running fixGoDeps()
|
|
||||||
Running [go-mod-clean --strict] in go.wit.com/lib/protobuf/gitpb
|
|
||||||
current repo go.wit.com/lib/protobuf/gitpb go dependancy count: 8IsReadOnly = true github.com/destel/rill
|
|
||||||
IsReadOnly = true github.com/go-cmd/cmd
|
|
||||||
IsReadOnly = true github.com/go-test/deep
|
|
||||||
IsReadOnly = true github.com/google/go-cmp
|
|
||||||
IsReadOnly = true golang.org/x/xerrors
|
|
||||||
IsReadOnly = true google.golang.org/protobuf
|
|
||||||
fixGoDeps() returned true
|
|
||||||
current repo go.wit.com/lib/protobuf/gitpb go dependancy count: 8github.com/go-test/deep ok error .v1.1.0. vs .v1.1.1. (ignoring read-only repo)github.com/google/go-cmp ok error .v0.5.5. vs .v0.6.0. (ignoring read-only repo)golang.org/x/xerrors ok error .v0.0.0-20191204190536-9bdfabe68543. vs .. (ignoring read-only repo)google.golang.org/protobuf ok error .v1.36.3. vs .v1.35.2. (ignoring read-only repo)findNext() found something
|
|
||||||
Running [go-mod-clean --strict] in go.wit.com/lib/protobuf/gitpb
|
|
||||||
current repo go.wit.com/lib/protobuf/gitpb go dependancy count: 8IsReadOnly = true github.com/destel/rill
|
|
||||||
IsReadOnly = true github.com/go-cmd/cmd
|
|
||||||
IsReadOnly = true github.com/go-test/deep
|
|
||||||
IsReadOnly = true github.com/google/go-cmp
|
|
||||||
IsReadOnly = true golang.org/x/xerrors
|
|
||||||
IsReadOnly = true google.golang.org/protobuf
|
|
||||||
current repo go.wit.com/lib/protobuf/gitpb go dependancy count: 8github.com/go-test/deep ok error .v1.1.0. vs .v1.1.1. (ignoring read-only repo)github.com/google/go-cmp ok error .v0.5.5. vs .v0.6.0. (ignoring read-only repo)golang.org/x/xerrors ok error .v0.0.0-20191204190536-9bdfabe68543. vs .. (ignoring read-only repo)google.golang.org/protobuf ok error .v1.36.3. vs .v1.35.2. (ignoring read-only repo)GOOD TO RUN ANOTHER DAY ON: go.wit.com/lib/protobuf/gitpb
|
|
||||||
doRelease() worked. findCounter = 13
|
|
||||||
doRelease() on go.wit.com/lib/protobuf/gitpb
|
|
||||||
everything is ok. version starts with v. v0.0.51
|
|
||||||
go.mod exists ok
|
|
||||||
current repo go.wit.com/lib/protobuf/gitpb go dependancy count: 8github.com/go-test/deep ok error .v1.1.0. vs .v1.1.1. (ignoring read-only repo)github.com/google/go-cmp ok error .v0.5.5. vs .v0.6.0. (ignoring read-only repo)golang.org/x/xerrors ok error .v0.0.0-20191204190536-9bdfabe68543. vs .. (ignoring read-only repo)google.golang.org/protobuf ok error .v1.36.3. vs .v1.35.2. (ignoring read-only repo) tag and push master v0.0.51 set protobuf uuids
|
|
||||||
IsProtobuf() == true
|
|
||||||
should add the protobuf files here
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -100,7 +100,7 @@ func runGoClean(check *gitpb.Repo, myarg string) bool {
|
||||||
check.GoDeps = nil
|
check.GoDeps = nil
|
||||||
|
|
||||||
cmd := []string{"go-mod-clean", myarg}
|
cmd := []string{"go-mod-clean", myarg}
|
||||||
log.Info("Running", cmd, "in", check.GetGoPath())
|
// log.Info("Running", cmd, "in", check.GetGoPath())
|
||||||
result := check.Run(cmd)
|
result := check.Run(cmd)
|
||||||
if result.Error != nil {
|
if result.Error != nil {
|
||||||
/*
|
/*
|
||||||
|
@ -125,7 +125,7 @@ func runGoClean(check *gitpb.Repo, myarg string) bool {
|
||||||
if check.ParseGoSum() {
|
if check.ParseGoSum() {
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
log.Info("ParseGoSum() failed")
|
log.Info("ParseGoSum() failed", check.GetGoPath())
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,9 @@ package main
|
||||||
import (
|
import (
|
||||||
"os"
|
"os"
|
||||||
"strings"
|
"strings"
|
||||||
|
"time"
|
||||||
|
|
||||||
|
"go.wit.com/lib/gui/shell"
|
||||||
"go.wit.com/lib/protobuf/forgepb"
|
"go.wit.com/lib/protobuf/forgepb"
|
||||||
"go.wit.com/lib/protobuf/gitpb"
|
"go.wit.com/lib/protobuf/gitpb"
|
||||||
"go.wit.com/log"
|
"go.wit.com/log"
|
||||||
|
@ -62,39 +64,37 @@ func forceReleaseVersion(repo *gitpb.Repo) {
|
||||||
// os.Exit(-1)
|
// os.Exit(-1)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
func rillGoModRestore(repo *gitpb.Repo) error {
|
||||||
|
if repo.GetTargetVersion() == "" {
|
||||||
|
// not set to upgrade
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
if repo.GetLastTag() == repo.GetTargetVersion() {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
if me.forge.Config.IsReadOnly(repo.GetGoPath()) {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
if me.forge.Config.IsPrivate(repo.GetGoPath()) {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
runGoClean(repo, "--restore")
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
func rePrepareRelease() {
|
func rePrepareRelease() {
|
||||||
// reload the config
|
// reload the config
|
||||||
me.forge = forgepb.Init()
|
me.forge = forgepb.Init()
|
||||||
me.found = new(gitpb.Repos)
|
me.found = new(gitpb.Repos)
|
||||||
|
|
||||||
// blank all the target versions incase they were saved in the config .pb file
|
now := time.Now()
|
||||||
|
me.forge.RillFuncError(rillGoModRestore)
|
||||||
|
log.Printf("rillFixGodeps() (%d total repos) took:%s\n", me.forge.Repos.Len(), shell.FormatDuration(time.Since(now)))
|
||||||
|
|
||||||
all := me.forge.Repos.SortByFullPath()
|
all := me.forge.Repos.SortByFullPath()
|
||||||
for all.Scan() {
|
for all.Scan() {
|
||||||
check := all.Next()
|
check := all.Next()
|
||||||
|
|
||||||
// set the target version to the current master version
|
|
||||||
lastTag := check.GetLastTag()
|
|
||||||
check.SetTargetVersion(lastTag)
|
|
||||||
if me.forge.Config.IsReadOnly(check.GetGoPath()) {
|
|
||||||
// can't release readonly repos
|
|
||||||
continue
|
|
||||||
}
|
|
||||||
if me.forge.Config.IsPrivate(check.GetGoPath()) {
|
|
||||||
// can't release readonly repos
|
|
||||||
continue
|
|
||||||
}
|
|
||||||
|
|
||||||
if !runGoClean(check, "--restore") {
|
|
||||||
log.Info("gomodclean probably failed here. that's ok", check.GetGoPath())
|
|
||||||
// os.Exit(-1)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
all = me.forge.Repos.SortByFullPath()
|
|
||||||
for all.Scan() {
|
|
||||||
check := all.Next()
|
|
||||||
|
|
||||||
if me.forge.Config.IsReadOnly(check.GetGoPath()) {
|
if me.forge.Config.IsReadOnly(check.GetGoPath()) {
|
||||||
// can't release readonly repos
|
// can't release readonly repos
|
||||||
continue
|
continue
|
||||||
|
|
Loading…
Reference in New Issue