Skip to content

Commit 16e84d0

Browse files
authored
Merge pull request github#18929 from github/mbg/go/filter-more-vendor-dirs
Go: Support more dependency managers in `IsGolangVendorDirectory`
2 parents c7dc8a3 + b872c60 commit 16e84d0

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

go/extractor/util/util.go

+4-1
Original file line numberDiff line numberDiff line change
@@ -307,5 +307,8 @@ func fileExists(path string) bool {
307307
// and contains a `modules.txt` file.
308308
func IsGolangVendorDirectory(dirPath string) bool {
309309
return filepath.Base(dirPath) == "vendor" &&
310-
(fileExists(filepath.Join(dirPath, "modules.txt")) || fileExists(filepath.Join(dirPath, "../glide.yaml")))
310+
(fileExists(filepath.Join(dirPath, "modules.txt")) ||
311+
fileExists(filepath.Join(dirPath, "../glide.yaml")) ||
312+
fileExists(filepath.Join(dirPath, "../Gopkg.lock")) ||
313+
fileExists(filepath.Join(dirPath, "../vendor.conf")))
311314
}

0 commit comments

Comments
 (0)