Check for go.mod.

This commit is contained in:
Jelmer Vernooij 2021-03-20 00:50:02 +00:00
parent a6d333fbd1
commit 4ce2b54c44
No known key found for this signature in database
GPG key ID: 579C160D4C9E23E8

View file

@ -953,6 +953,8 @@ class Golang(BuildSystem):
@classmethod
def probe(cls, path):
if os.path.exists(os.path.join(path, 'go.mod')):
return Golang(path)
for entry in os.scandir(path):
if entry.name.endswith(".go"):
return Golang(path)