diff options
| author | Jeff Carr <[email protected]> | 2024-12-05 12:29:47 -0600 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2024-12-05 12:29:47 -0600 |
| commit | 816760d1372d6d1922a9916f3150e49f3fd562cd (patch) | |
| tree | 0889b24fabb5d35dc0db53d0bbf71a985427c89b /findRepos.go | |
| parent | 0463030e80f480f0d38989f4231db8b1651b40bc (diff) | |
developing on this now
Diffstat (limited to 'findRepos.go')
| -rw-r--r-- | findRepos.go | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/findRepos.go b/findRepos.go new file mode 100644 index 0000000..1463d09 --- /dev/null +++ b/findRepos.go @@ -0,0 +1,40 @@ +package main + +import ( + "go.wit.com/log" +) + +func findRepos() { + if argv.FindAll { + var configsave bool + repos := me.forge.Repos.SortByGoPath() + for repos.Scan() { + repo := repos.Next() + if me.forge.Config.IsReadOnly(repo.GoPath) && !argv.FindReadOnly { + if repo.ReadOnly { + continue + } + log.Info("todo: ConfigSave() readonly flag on repo is wrong", repo.GoPath) + repo.ReadOnly = true + configsave = true + continue + } + me.found.AppendUniqueGoPath(repo) + } + if configsave { + log.Info("should ConfigSave here") + me.forge.Repos.ConfigSave() + } + } + + if argv.FindPrivate { + findPrivate() + } + + if argv.FindMine { + findMine() + } + if argv.FindFavorites { + findFavorites() + } +} |
