dayvonjersen/linguist

go mod tidy: "./testutil" is relative, but relative import paths are not supported in module mode

Opened this issue · 2 comments

$ go mod tidy
go: finding module for package github.com/smartystreets/goconvey/convey
go: finding module for package gopkg.in/check.v1
go: found gopkg.in/check.v1 in gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c
go: found github.com/smartystreets/goconvey/convey in github.com/smartystreets/goconvey v1.8.1
go: downloading golang.org/x/text v0.8.0
github.com/ianlewis/linguist/cmd/l imports
        github.com/dayvonjersen/git4go tested by
        github.com/dayvonjersen/git4go.test imports
        ./testutil: "./testutil" is relative, but relative import paths are not supported in module mode

Probably migrating to a more supported library like https://github.com/go-git/go-git would be better.

Probably migrating to a more supported library like https://github.com/go-git/go-git would be better.

Though I'm a bit curious why the l command doesn't just walk the regular directory tree and ignore files that match .git, .gitignore etc. rather than use a git library to parse the committed code.

Edit: I see it has options for both..