summaryrefslogtreecommitdiff
path: root/goDep.parseGoSum.go
diff options
context:
space:
mode:
Diffstat (limited to 'goDep.parseGoSum.go')
-rw-r--r--goDep.parseGoSum.go11
1 files changed, 9 insertions, 2 deletions
diff --git a/goDep.parseGoSum.go b/goDep.parseGoSum.go
index 69e4826..5bf3f29 100644
--- a/goDep.parseGoSum.go
+++ b/goDep.parseGoSum.go
@@ -17,13 +17,20 @@ import (
func (repo *Repo) ParseGoSum() (bool, error) {
// empty out what was there before
repo.GoDeps = nil
+
+ // check of the repo is a primative
+ // that means, there is not a go.sum file
+ // because the package is completely self contained!
+ if ok, _ := repo.IsPrimitive(); ok {
+ log.Info("This repo is primative!")
+ return true, nil
+ }
tmp := filepath.Join(repo.FullPath, "go.sum")
gosum, err := os.Open(tmp)
+ defer gosum.Close()
if err != nil {
- log.Warn("missing go.sum", repo.FullPath)
return false, err
}
- defer gosum.Close()
scanner := bufio.NewScanner(gosum)
log.Info("gosum:", tmp)