summaryrefslogtreecommitdiff
path: root/findNext.go
diff options
context:
space:
mode:
Diffstat (limited to 'findNext.go')
-rw-r--r--findNext.go34
1 files changed, 26 insertions, 8 deletions
diff --git a/findNext.go b/findNext.go
index 4ff430c..34f09b3 100644
--- a/findNext.go
+++ b/findNext.go
@@ -2,8 +2,11 @@
package main
import (
+ "time"
+
"go.wit.com/log"
+ "go.wit.com/lib/gui/shell"
"go.wit.com/lib/protobuf/gitpb"
)
@@ -11,10 +14,23 @@ var findCounter int
var findFix bool = false
var findOk bool = true
+func rillFixGodeps(repo *gitpb.Repo) error {
+ if fixGodeps(repo) {
+ log.Info("fixGoDeps() returned true")
+ } else {
+ log.Info("fixGoDeps() returned false")
+ }
+ return nil
+}
+
// trys to figure out if there is still something to update
// todo: redo this logic as it is terrible
// rename this findNext()
func findNext() bool {
+ now := time.Now()
+ me.forge.RillFuncError(2, 2, rillFixGodeps)
+ log.Printf("rillFixGodeps() (%d total repos) took:%s\n", me.forge.Repos.Len(), shell.FormatDuration(time.Since(now)))
+
findCounter = 0
all := me.forge.Repos.SortByFullPath()
for all.Scan() {
@@ -38,15 +54,17 @@ func findNext() bool {
log.Info("findNext() skipping dirty")
continue
}
- if findFix {
- log.Info("findFix is true. running fixGoDeps()")
- if fixGodeps(check) {
- log.Info("fixGoDeps() returned true")
- } else {
- log.Info("fixGoDeps() returned false")
- }
+ /*
+ if findFix {
+ log.Info("findFix is true. running fixGoDeps()")
+ if fixGodeps(check) {
+ log.Info("fixGoDeps() returned true")
+ } else {
+ log.Info("fixGoDeps() returned false")
+ }
- }
+ }
+ */
findCounter += 1
if !check.ParseGoSum() {
continue