summaryrefslogtreecommitdiff
path: root/globalBuildOptions.go
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2024-01-19 18:37:27 -0600
committerJeff Carr <[email protected]>2024-01-19 18:37:27 -0600
commitdb36cef85a81d1978f5fe1d3bf46698547afd088 (patch)
tree92bea64224a34cc00a22f73d67ebcc3cb32a1d70 /globalBuildOptions.go
parentfa56bf146b80c84eea6f7cd46a589634a69aabef (diff)
more more into repostatus package
better working labels autotypist auto hides hide unmodified repos works again go build args out of order download the toolkits first auto rebuild of autotypist Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'globalBuildOptions.go')
-rw-r--r--globalBuildOptions.go55
1 files changed, 19 insertions, 36 deletions
diff --git a/globalBuildOptions.go b/globalBuildOptions.go
index b140e60..a401e21 100644
--- a/globalBuildOptions.go
+++ b/globalBuildOptions.go
@@ -84,7 +84,7 @@ func globalBuildOptions(box *gui.Node) {
guiBranch.AddText("jcarr")
guiBranch.Custom = func() {
me.toMoveToBranch = guiBranch.String()
- setCurrentBranch.Set("set all branches to " + me.toMoveToBranch)
+ setCurrentBranch.SetLabel("set all branches to " + me.toMoveToBranch)
me.mainBranch.Disable()
}
@@ -105,62 +105,45 @@ func globalBuildOptions(box *gui.Node) {
quickCmdLastPath = "~/go/src"
quickCmds = [][]string{}
log.Warn("scanning allrepos")
- fullpath := "/home/jcarr/go/src"
- quickCmd(fullpath, []string{"mkdir", "-p", "go.wit.com/apps/"})
+ fullpath := "/home/jcarr/"
+ quickCmd(fullpath, []string{"mkdir", "-p", "/home/jcarr/go/src/go.wit.com/apps/"})
+ fullpath = "/home/jcarr/go/src/go.wit.com/apps/"
+ quickCmd(fullpath, []string{"go", "get", "go.wit.com/apps/autotypist"})
fullpath = "/home/jcarr/go/src/go.wit.com/apps/autotypist"
- quickCmd(fullpath, []string{"go", "get", "-v", "go.wit.com/apps/autotypist"})
quickCmd(fullpath, []string{"go", "get", "-v", "go.wit.com/toolkits/debian"})
fullpath = "/home/jcarr/go/src/go.wit.com/toolkits/debian"
+ quickCmd(fullpath, []string{"make", "download"})
quickCmd(fullpath, []string{"make"})
fullpath = "/home/jcarr/go/src/go.wit.com/apps/autotypist"
quickCmd(fullpath, []string{"go", "get", "-v", "-u", "."})
- quickCmd(fullpath, []string{"go", "-v", "-x", "build"})
+ quickCmd(fullpath, []string{"go", "build", "-v", "-x"})
me.script = quickCmds
setGitCommands()
})
- me.rerunGoMod = groupvbox.NewButton("re-run go mod & go tidy", func() {
- me.rerunGoMod.Disable()
- quickCmdDoNotRun = true
- quickCmdLastPath = "~/go/src"
- quickCmds = [][]string{}
+ me.rerunGoMod = groupvbox.NewButton("remove all go.mod and go.sum", func() {
+ quickCmdDoNotRun = false
log.Warn("scanning allrepos")
- os.Unsetenv("GO111MODULE")
for _, path := range me.allrepos {
fullpath := "/home/jcarr/go/src/" + path
- // set the button text for the user
- me.rerunGoMod.SetText("Running go.mod " + fullpath)
-
- quickCmd(fullpath, []string{"pwd"})
- quickCmd(fullpath, []string{"ls", "-l"})
- quickCmd(fullpath, []string{"git", "status"}) // TODO: process this?
- quickCmd(fullpath, []string{"rm", "go.mod", "go.sum"})
+ quickCmd(fullpath, []string{"rm", "-f", "go.mod", "go.sum"})
+ }
+ })
+ me.rerunGoMod = groupvbox.NewButton("re-run go mod & go tidy", func() {
+ quickCmdDoNotRun = false
+ os.Unsetenv("GO111MODULE")
+ log.Warn("scanning allrepos")
+ for _, path := range me.allrepos {
+ fullpath := "/home/jcarr/go/src/" + path
quickCmd(fullpath, []string{"go", "mod", "init"})
- // don't hammer google's golang versioning system
- if quickCmdDoNotRun {
- quickCmd(fullpath, []string{"sleep", ".2"})
- } else {
- log.Sleep(.2)
- }
quickCmd(fullpath, []string{"go", "mod", "tidy"})
- // don't hammer google's golang versioning system
- if quickCmdDoNotRun {
- quickCmd(fullpath, []string{"sleep", ".1"})
- } else {
- log.Sleep(.1)
- }
- quickCmd(fullpath, []string{"git", "status"}) // TODO: process this?
}
- // re-enable the button
- me.rerunGoMod.SetText("re-run go mod & go tidy")
- me.script = quickCmds
- setGitCommands()
- me.rerunGoMod.Enable()
})
+
setCurrentBranch = groupvbox.NewButton("set all branches to", func() {
log.Warn("scanning allrepos")
for repo, path := range me.allrepos {