summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2025-01-08 04:07:33 -0600
committerJeff Carr <[email protected]>2025-01-08 04:07:33 -0600
commit9d97b946168f7b285c9b725c93f1ef69b73ef785 (patch)
treedcc5642e8e004b2481ec71e86d5cdc6fe11bb3ee
parent8e2a557b25a82ab6a61fa71644b6f78d7c9de77f (diff)
tracked down 'dirty' not showing upv0.22.36
-rw-r--r--Makefile2
-rw-r--r--doCommon.go4
-rw-r--r--doGui.go15
-rw-r--r--main.go4
4 files changed, 22 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index f1df801..d84db3b 100644
--- a/Makefile
+++ b/Makefile
@@ -2,8 +2,6 @@ VERSION = $(shell git describe --tags)
BUILDTIME = $(shell date +%Y.%m.%d)
info: install
- @echo "make restart # remove the repos.pb file"
- @echo "make pull-mine # run git pull on my repos"
forge
vet:
diff --git a/doCommon.go b/doCommon.go
index 1a2a3aa..eb48c04 100644
--- a/doCommon.go
+++ b/doCommon.go
@@ -35,12 +35,14 @@ func doGitPull() {
}
func doCheckDirtyAndConfigSave() {
+ var count int
now := time.Now()
all := me.found.SortByFullPath()
for all.Scan() {
repo := all.Next()
dirty := repo.IsDirty()
if repo.CheckDirty() {
+ count += 1
me.found.AppendUniqueGoPath(repo)
if !dirty {
configSave = true
@@ -51,7 +53,7 @@ func doCheckDirtyAndConfigSave() {
}
}
}
- log.Info("dirty check took:", shell.FormatDuration(time.Since(now)))
+ log.Printf("dirty check %d took:%s\n", count, shell.FormatDuration(time.Since(now)))
me.forge.SetConfigSave(configSave)
}
diff --git a/doGui.go b/doGui.go
index b89a5ae..f84f019 100644
--- a/doGui.go
+++ b/doGui.go
@@ -4,14 +4,29 @@ package main
import (
"go.wit.com/gui"
+ "go.wit.com/lib/debugger"
"go.wit.com/lib/gadgets"
"go.wit.com/log"
)
+func debug() {
+ log.Info("cmd line --debugger == true")
+ go func() {
+ log.Sleep(3)
+ log.Info("cmd line --debugger == true")
+ log.Info("cmd line --debugger == true")
+ log.Info("cmd line --debugger == true")
+ log.Info("cmd line --debugger == true")
+ debugger.DebugWindow()
+ }()
+}
+
func doGui() {
me.myGui = gui.New()
me.myGui.Default()
+ // debug()
+
me.mainWindow = gadgets.RawBasicWindow("Forge: (this doesn't work yet)")
me.mainWindow.Make()
me.mainWindow.Show()
diff --git a/main.go b/main.go
index 0563fc1..446e4b9 100644
--- a/main.go
+++ b/main.go
@@ -174,6 +174,10 @@ func main() {
// open the gui unless the user performed some other
// basically, if you run just 'forge' it should open the GUI
+
+ // if opening the GUI, always check git for dirty repos
+ findAll() // select all the repos
+ doCheckDirtyAndConfigSave()
doGui()
okExit("")
}