diff options
Diffstat (limited to 'main.go')
| -rw-r--r-- | main.go | 20 |
1 files changed, 11 insertions, 9 deletions
@@ -36,7 +36,7 @@ func main() { log.Info(err) os.Exit(-1) } - log.Info("go.work directory:", wdir) + log.Info("scanning directory:", wdir) os.Setenv("REPO_WORK_PATH", wdir) // readControlFile() @@ -62,18 +62,20 @@ func main() { godep := newr.Status.GetGoDeps() for gopath, version := range godep { - log.Info("git clone =", gopath, version) - rv.NewRepo(gopath) + if _, err := rv.NewRepo(gopath); err != nil { + log.Info("git clone failed for", gopath, version) + } } - for _, repo := range rv.AllRepos() { - log.Info("found repo", repo.GoPath(), repo.Status.Path()) + log.Info("all repositories are cloned") + if ! myargs.NoWork { + log.Info("Creating", wdir + "/go.work") + rv.MakeGoWork() } - rv.MakeGoWork() - // rv.Watchdog(func() { - // log.Info("watchdog") - // }) +// for _, repo := range rv.AllRepos() { +// log.Info("found repo", repo.GoPath(), repo.Status.Path()) +// } } func clone(path string) { |
