Skip to content

Commit

Permalink
Ignore the output by go modules
Browse files Browse the repository at this point in the history
  • Loading branch information
nukosuke committed Jun 5, 2019
1 parent 900af2b commit bbbd23d
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions goveralls.go
Original file line number Diff line number Diff line change
Expand Up @@ -109,9 +109,14 @@ func getPkgs(pkg string) ([]string, error) {
allPkgs := strings.Split(strings.Trim(string(out), "\n"), "\n")
pkgs := make([]string, 0, len(allPkgs))
for _, p := range allPkgs {
if !strings.Contains(p, "/vendor/") {
pkgs = append(pkgs, p)
if strings.Contains(p, "/vendor/") {
continue
}
// go modules output
if strings.Contains(p, "go: ") {
continue
}
pkgs = append(pkgs, p)
}
return pkgs, nil
}
Expand Down

0 comments on commit bbbd23d

Please sign in to comment.