diff --git a/clone.go b/clone.go index 91edf62..52bfabd 100644 --- a/clone.go +++ b/clone.go @@ -43,7 +43,7 @@ func clone(gopath string) (*gitpb.Repo, error) { log.Info("repo cloned failed", filepath.Join(forge.GetGoSrc(), gopath)) return nil, errors.New(fullgitdir + " was not created") } - log.Info("onward and upward") + log.Info("go-clone clone() onward and upward") return pb, nil } @@ -113,7 +113,9 @@ func recursiveClone(check *gitpb.Repo) error { func makeValidGoSum(check *gitpb.Repo) error { if check.Exists("go.mod") { + log.Info("makeValidGoSum() attempt SetPrimitive()") if err := check.SetPrimitive(); err != nil { + log.Info("SetPrimitive() failed", err) return err } } diff --git a/main.go b/main.go index aded69d..c31dbdb 100644 --- a/main.go +++ b/main.go @@ -49,14 +49,25 @@ func main() { } autoWork() if argv.Build { - if err := makeValidGoSum(workingRepo); err != nil { - badExit(err) + log.Info("STARTING BUILD", workingRepo.GoPath) + /* + if err := makeValidGoSum(workingRepo); err != nil { + badExit(err) + } + if err := build(); err != nil { + badExit(err) + } + */ + if workingRepo.RepoType() == "binary" || workingRepo.RepoType() == "plugin" { + log.Info("build will probably fail", workingRepo.GoPath, "is", workingRepo.RepoType()) } - if err := build(); err != nil { + if err := forge.Build(workingRepo, nil); err != nil { + log.Warn("BUILD FAILED", workingRepo.GoPath, err) badExit(err) } } if argv.Install { + log.Info("STARTING INSTALL", workingRepo.GoPath) // can only install binary or plugin go packages if workingRepo.RepoType() == "binary" || workingRepo.RepoType() == "plugin" { log.Info("install will probably fail", workingRepo.GoPath, "is", workingRepo.RepoType())