compiles again. doesn't work
This commit is contained in:
parent
24e942df16
commit
f7c9af9537
2
Makefile
2
Makefile
|
@ -14,6 +14,7 @@ vet:
|
|||
build:
|
||||
echo "build it!"
|
||||
-rm resources/*.so
|
||||
-mkdir resources/
|
||||
cp -a ~/go/src/go.wit.com/toolkits/*.so resources/
|
||||
GO111MODULE=off go build \
|
||||
-ldflags "-X main.VERSION=${VERSION} -X main.BUILDTIME=${BUILDTIME} -X gui.GUIVERSION=${VERSION}"
|
||||
|
@ -34,6 +35,7 @@ redomod:
|
|||
rm -f go.*
|
||||
GO111MODULE= go mod init
|
||||
GO111MODULE= go mod tidy
|
||||
go mod edit -go=1.20
|
||||
|
||||
curl-help:
|
||||
curl --silent http://localhost:9419/help
|
||||
|
|
|
@ -34,6 +34,7 @@ func doRelease() bool {
|
|||
log.Info("go.mod disappeared. need to run go mod init and go mod tidy here:", pwd)
|
||||
shell.RunRealtime([]string{"go", "mod", "init"})
|
||||
shell.RunRealtime([]string{"go", "mod", "tidy"})
|
||||
shell.RunRealtime([]string{"go", "mod", "edit", "-go=1.20"})
|
||||
}
|
||||
|
||||
curName := me.current.Status.GetCurrentBranchName()
|
||||
|
|
|
@ -1,35 +0,0 @@
|
|||
package main
|
||||
|
||||
// this initializes the repos
|
||||
|
||||
import (
|
||||
"strings"
|
||||
|
||||
"go.wit.com/lib/gui/repostatus"
|
||||
"go.wit.com/log"
|
||||
)
|
||||
|
||||
func (r *repoWindow) initRepoList() {
|
||||
r.View.InitRepoList(".config/guireleaser")
|
||||
|
||||
log.Info("scanning everything in ~/go/src")
|
||||
for i, path := range repostatus.ListGitDirectories() {
|
||||
// log.Info("addRepo()", i, path)
|
||||
path = strings.TrimPrefix(path, me.goSrcPwd.String())
|
||||
path = strings.Trim(path, "/")
|
||||
log.Info("addRepo()", i, path)
|
||||
r.View.NewRepo(path)
|
||||
}
|
||||
}
|
||||
|
||||
func (r *repoWindow) tmpRepoList() {
|
||||
|
||||
log.Info("scanning everything in ~/go/src")
|
||||
for i, path := range repostatus.ListGitDirectories() {
|
||||
// log.Info("addRepo()", i, path)
|
||||
path = strings.TrimPrefix(path, me.goSrcPwd.String())
|
||||
path = strings.Trim(path, "/")
|
||||
log.Info("addRepo()", i, path)
|
||||
r.View.NewRepo(path)
|
||||
}
|
||||
}
|
19
main.go
19
main.go
|
@ -9,6 +9,7 @@ import (
|
|||
"go.wit.com/gui"
|
||||
"go.wit.com/lib/gui/gowit"
|
||||
"go.wit.com/lib/gui/shell"
|
||||
"go.wit.com/lib/protobuf/forgepb"
|
||||
"go.wit.com/log"
|
||||
)
|
||||
|
||||
|
@ -23,16 +24,9 @@ func main() {
|
|||
me = new(autoType)
|
||||
|
||||
// load the ~/.config/forge/ config
|
||||
if err := me.forge.ConfigLoad(); err != nil {
|
||||
log.Warn("forgepb.ConfigLoad() failed", err)
|
||||
os.Exit(-1)
|
||||
}
|
||||
|
||||
// load the ~/.config/forge/ machine file from zoopb
|
||||
if err := me.machine.ConfigLoad(); err != nil {
|
||||
log.Warn("zoopb.ConfigLoad() failed", err)
|
||||
os.Exit(-1)
|
||||
}
|
||||
me.forge = forgepb.Init()
|
||||
me.forge.ConfigPrintTable()
|
||||
os.Setenv("REPO_WORK_PATH", me.forge.GetGoSrc())
|
||||
|
||||
// parse the command line
|
||||
arg.MustParse(&myargs)
|
||||
|
@ -111,10 +105,6 @@ func main() {
|
|||
me.release.box.Disable()
|
||||
me.Disable()
|
||||
|
||||
// parse config file and scan for .git repos
|
||||
me.repos.initRepoList()
|
||||
// setTargetVersion()
|
||||
|
||||
// register a Show/Hide function for the repo list table
|
||||
me.repos.View.RegisterHideFunction(hideFunction)
|
||||
|
||||
|
@ -122,7 +112,6 @@ func main() {
|
|||
// TODO: should not really be necessary directly after init()
|
||||
me.repos.View.ScanRepositories()
|
||||
|
||||
|
||||
loop := me.repos.View.ReposSortByName()
|
||||
for loop.Scan() {
|
||||
repo := loop.Repo()
|
||||
|
|
|
@ -6,7 +6,6 @@ import (
|
|||
"go.wit.com/lib/gadgets"
|
||||
"go.wit.com/lib/gui/repolist"
|
||||
"go.wit.com/lib/protobuf/forgepb"
|
||||
"go.wit.com/lib/protobuf/zoopb"
|
||||
)
|
||||
|
||||
var me *autoType
|
||||
|
@ -29,10 +28,7 @@ type autoType struct {
|
|||
repos *repoWindow
|
||||
|
||||
// your customized repo preferences and settings
|
||||
forge forgepb.Repos
|
||||
|
||||
// use zookeeper to get the list of installed packages
|
||||
machine zoopb.Machine
|
||||
forge *forgepb.Forge
|
||||
|
||||
// #### autotypist Global Build Options
|
||||
// what to change all the branches to
|
||||
|
|
Loading…
Reference in New Issue