more and more and more

This commit is contained in:
Jeff Carr 2024-12-17 21:58:14 -06:00
parent 491c4455d8
commit 79ea2eaec1
Notes: Jeff Carr 2024-12-17 23:32:51 -06:00
// `autogen:go.mod`

module go.wit.com/apps/guireleaser

go 1.21

toolchain go1.23.4

require (
	github.com/go-cmd/cmd v1.4.3
	go.wit.com/dev/alexflint/arg v1.5.5
	go.wit.com/gui v0.22.14
	go.wit.com/lib/debugger v0.22.5
	go.wit.com/lib/gadgets v0.22.5
	go.wit.com/lib/gui/logsettings v0.22.5
	go.wit.com/lib/gui/repolist v0.22.35
	go.wit.com/lib/gui/shell v0.22.18
	go.wit.com/lib/protobuf/forgepb v0.0.38
	go.wit.com/lib/protobuf/gitpb v0.0.36
	go.wit.com/log v0.22.9
)

require (
	github.com/destel/rill v0.6.0 // indirect
	github.com/google/uuid v1.6.0 // indirect
	go.wit.com/dev/alexflint/scalar v1.2.4 // indirect
	go.wit.com/lib/gui/repostatus v0.22.30 // indirect
	go.wit.com/lib/protobuf/virtbuf v0.2.17 // indirect
	go.wit.com/lib/protobuf/zoopb v0.0.20 // indirect
	go.wit.com/widget v1.1.27 // indirect
	google.golang.org/protobuf v1.36.0 // indirect
)

// `autogen:go.sum`

github.com/destel/rill v0.6.0 h1:8MQRzS6k0akKmwNZFahKIhG1dkBeNxMoWKSfOxkaJNw=
github.com/destel/rill v0.6.0/go.mod h1:srKuXzvGqINUEGYR5b/iwvW+L9/S35RxVHWGYbXNoO4=
github.com/go-cmd/cmd v1.4.3 h1:6y3G+3UqPerXvPcXvj+5QNPHT02BUw7p6PsqRxLNA7Y=
github.com/go-cmd/cmd v1.4.3/go.mod h1:u3hxg/ry+D5kwh8WvUkHLAMe2zQCaXd00t35WfQaOFk=
github.com/go-test/deep v1.1.0 h1:WOcxcdHcvdgThNXjw0t76K42FXTU7HpNQWHpA2HHNlg=
github.com/go-test/deep v1.1.0/go.mod h1:5C2ZWiW0ErCdrYzpqxLbTX7MG14M9iiw8DgHncVwcsE=
github.com/google/go-cmp v0.5.5 h1:Khx7svrCpmxxtHBq5j2mp/xVjsi8hQMfNLvJFAlrGgU=
github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0=
github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
go.wit.com/dev/alexflint/arg v1.5.5 h1:c4jgIb4OvHjnCMRNSjOa1sNLl6WDxV6tIkMVezR9hCk=
go.wit.com/dev/alexflint/arg v1.5.5/go.mod h1:nH3F6TJDaAUgnLkC0WgRN/H047YfN1TYKaWPYr6B8lo=
go.wit.com/dev/alexflint/scalar v1.2.4 h1:zmBeEkObwz1lcelwfGNYP2GS6SQ9e0tdv7JdHwMZEEk=
go.wit.com/dev/alexflint/scalar v1.2.4/go.mod h1:kCNO1Fo5LnnK6+qa+zYhP5fdgfC1C+vx1ti99Md+FAM=
go.wit.com/gui v0.22.14 h1:Ssio1XxZvLB8vzaL0Wxak2Tq9plG5lPtmDcFUz9+4jU=
go.wit.com/gui v0.22.14/go.mod h1:U7Bw4dw+x+sfHhru/jKS9I5APxXdiQIF5B2luJH1cE8=
go.wit.com/lib/debugger v0.22.5 h1:kq5XpoLkVYEQmW4r4y6GZPwO1iItDhlNOU2BT0IGc3I=
go.wit.com/lib/debugger v0.22.5/go.mod h1:+Q1NWiEIjoRzy7cN6c/D0/QcPgdIzYCSxbC8Gaht7mw=
go.wit.com/lib/gadgets v0.22.5 h1:sDBSIVb+MflU705ImwKFvP9hnnZdLVrwy+Xsgp/w7dw=
go.wit.com/lib/gadgets v0.22.5/go.mod h1:Hiap8lateez6bts/DFmu+HSX9y8rgCfmusnG/CiTuGM=
go.wit.com/lib/gui/logsettings v0.22.5 h1:rBv86U4xB5C/t+itqmH8CfXQ5cb+MaIc8E2Z8iCU2E4=
go.wit.com/lib/gui/logsettings v0.22.5/go.mod h1:6Rb0bMC56sdtUbJh/Z7DsRqNH4IHYm5MDbqA3f32KAY=
go.wit.com/lib/gui/repolist v0.22.35 h1:mAj2grfsCH4FoymzNzaz86pSG623dOUSHSJvw7RR9X0=
go.wit.com/lib/gui/repolist v0.22.35/go.mod h1:v/8UO6Z9DI5Ka1rqKFvkEBt7ZyyRKlR10AsVPj7wwzo=
go.wit.com/lib/gui/repostatus v0.22.30 h1:dKciuBvQ8guuDszxX1Bd8XUQfQcB4rjyTZMAYWxA57w=
go.wit.com/lib/gui/repostatus v0.22.30/go.mod h1:7b1iirp10879dGOwVnRGazZVJspfDUbeUhEvP5lqLUo=
go.wit.com/lib/gui/shell v0.22.18 h1:2z14XRxGrNjRKVsfvlk70sWsRZWoLdnL7z0FS+BFzFM=
go.wit.com/lib/gui/shell v0.22.18/go.mod h1:zduuMSWq+EE7w0xbXn+vkoGZ4HJhURVJpvXw8oK9WAU=
go.wit.com/lib/protobuf/forgepb v0.0.38 h1:f/s1J4MERas9jnG8SrKr5S2ReC+JfdUpWE4WFtKw0g0=
go.wit.com/lib/protobuf/forgepb v0.0.38/go.mod h1:lQNRo8OhWzLwBsieOtjiiih89ejijV6/WShfFjYfAW4=
go.wit.com/lib/protobuf/gitpb v0.0.36 h1:WK/aj/Cgw95IL5fHju2WkoFo3awnNgOreqOHUmZyc88=
go.wit.com/lib/protobuf/gitpb v0.0.36/go.mod h1:JoIqZws8Wt0Xsf1cCrcSYtJ3EbSaaAkVtmkJ8C8JO6U=
go.wit.com/lib/protobuf/virtbuf v0.2.17 h1:cTOB0MvafTLuB4DnzOrPKzfD3m+ezz+p/N9TUhGneqY=
go.wit.com/lib/protobuf/virtbuf v0.2.17/go.mod h1:SzNaf2Gcux4cxfFPSIV2Gz8Dcu2hc2IIHXcmk9k7nPg=
go.wit.com/lib/protobuf/zoopb v0.0.20 h1:Ki/MhVuHibwA615hAnXF99My35GYPkGOh3qkTW91Wao=
go.wit.com/lib/protobuf/zoopb v0.0.20/go.mod h1:Sw47KomE+5nzioBTC/Gf8iV3p8gidB7uVoeyAtPvWi4=
go.wit.com/log v0.22.9 h1:aBM6SI2kxlJcBfS/osFTomJqNhO0hfEo1gk+LCqLk7Y=
go.wit.com/log v0.22.9/go.mod h1:4uNPFBqhsAh8zNF+zxVEmC3c/9AZ8JeTfUUvRpddvLQ=
go.wit.com/widget v1.1.27 h1:Yd+qp6GZVwLiTTepShXSeWSDqjaCxLyfhU0ch2FrPZ8=
go.wit.com/widget v1.1.27/go.mod h1:OXIdWk7GhVJRLnHTvf45LbPNXGYG/JjbkfnmXtkoiYE=
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4=
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
google.golang.org/protobuf v1.36.0 h1:mjIs9gYtt56AzC4ZaffQuh88TZurBGhIJMBZGSxNerQ=
google.golang.org/protobuf v1.36.0/go.mod h1:9fA7Ob0pmnwhb644+1+CVWFRbNajQ6iRojtC/QF5bRE=

// `autogen:`
6 changed files with 14 additions and 50 deletions

View File

@ -87,21 +87,10 @@ curl-incrementAllTargetVersions:
list-release-notdone:
curl --silent http://localhost:9419/releaseList?readonly=true
# only show repos that need to be merged to the master branch
curl-list-changed:
curl --silent http://localhost:9419/list?perfect=false
# include repos that you probably can't git push commits
curl-list-everything:
list-all:
curl --silent http://localhost:9419/list?readonly=true
curl-file-for-go.wit.com:
curl --silent http://localhost:9419/goweblist?readonly=true
curl --silent http://localhost:9419/goweblist?readonly=true |sort > ~/go.wit.com.versions
safe-build: install
forge --find-private
wit-package --no-gui --make-install
cd ~/go/src/go.wit.com/lib/xgb/ && GUIRELEASE_REASON="safe-build" guireleaser

View File

@ -208,7 +208,7 @@ func doRelease() bool {
if !doReleaseFindNext() {
log.Info("doReleaseFindNext() could not find a new", findCounter)
log.Info("THIS PROBABLY MEANS THAT ACTUALLY WE ARE TOTALLY DONE?", findCounter)
count := me.forge.PrintReleaseReport()
count := me.forge.PrintReleaseReport(me.found)
log.Info("count =", count)
os.Setenv("FindNextDone", "true")
return false

37
http.go
View File

@ -28,9 +28,6 @@ func okHandler(w http.ResponseWriter, r *http.Request) {
repoName := r.URL.Query().Get("repo")
version := r.URL.Query().Get("version")
comment := r.URL.Query().Get("comment")
readonly := r.URL.Query().Get("readonly")
onlydirty := r.URL.Query().Get("onlydirty")
perfect := r.URL.Query().Get("perfect")
whitelist := r.URL.Query().Get("whitelist")
switch route {
@ -174,40 +171,10 @@ func okHandler(w http.ResponseWriter, r *http.Request) {
showNext()
return
case "/list":
PrintReport(readonly, onlydirty, perfect)
me.forge.PrintReleaseReport(me.forge.Repos)
return
case "/releaseList":
me.forge.PrintReleaseReport()
return
case "/goweblist":
loop := me.repos.View.ReposAll()
for loop.Scan() {
repo := loop.Repo()
lastTag := repo.LastTag()
tag := repo.Status.NewestTag()
gitAge, err := tag.GetDate()
if err != nil {
log.Info(fmt.Sprintf("tag date error", repo.Name()))
}
// if lastTag == "" {
// lastTag = tag.Name()
// }
if repo.ReadOnly() {
if readonly == "true" {
continue
}
}
// dur := time.Since(gitAge)
// log.Info(fmt.Sprintf("%-60s %s %s %s", repo.Name(), lastTag, shell.FormatDuration(dur), lastTag, tag.Name()))
log.Info(fmt.Sprintf("%s %d %s", repo.Name(), gitAge.Unix(), lastTag))
/*
for _, tag := range repo.Tags.ListAll() {
log.Info(fmt.Sprintf("%-60s %s", "", tag.Name()))
}
*/
}
me.forge.PrintReleaseReport(me.found)
return
default:
log.Info("BAD URL = " + route)

View File

@ -11,6 +11,7 @@ import (
"go.wit.com/gui"
"go.wit.com/lib/gui/shell"
"go.wit.com/lib/protobuf/forgepb"
"go.wit.com/lib/protobuf/gitpb"
"go.wit.com/log"
)
@ -26,6 +27,8 @@ func main() {
// load the ~/.config/forge/ config
me.forge = forgepb.Init()
me.found = new(gitpb.Repos)
// me.forge.ConfigPrintTable()
os.Setenv("REPO_WORK_PATH", me.forge.GetGoSrc())

View File

@ -14,7 +14,7 @@ func makePrepareRelease() {
// if it succeeds, disable this button
me.setBranchesToMasterB.Disable()
me.release.box.Enable()
me.forge.PrintReleaseReport()
me.forge.PrintReleaseReport(me.found)
} else {
log.Info("setAllBranchesToMaster() failed")
}
@ -25,7 +25,8 @@ func makePrepareRelease() {
check := all.Next()
// set the target version to the current master version
check.SetTargetVersion("")
lastTag := check.GetLastTag()
check.SetTargetVersion(lastTag)
}
all = me.forge.Repos.SortByFullPath()
@ -41,12 +42,14 @@ func makePrepareRelease() {
lastTag := check.GetLastTag()
if master != lastTag {
forceReleaseVersion(check)
me.found.AppendUniqueGoPath(check)
continue
}
if argv.Protobuf && check.GetRepoType() == "protobuf" {
// if --protobuf, this will force upgrade each one
forceReleaseVersion(check)
me.found.AppendUniqueGoPath(check)
continue
}
@ -60,6 +63,7 @@ func makePrepareRelease() {
}
log.Printf("dependancy checks indicate a new release is needed for %s\n", check.GetGoPath())
forceReleaseVersion(check)
me.found.AppendUniqueGoPath(check)
}
}

View File

@ -19,6 +19,7 @@ type autoType struct {
reposgrid *gui.Node
reposgroup *gui.Node
current *gitpb.Repo
found *gitpb.Repos // stores the list of repos to process things on
// this is the repo we are starting in
// make sure it never changes so go.mod and go.sum are always there