Hi Stuart, 

(I'm not 100% confident, so take this with a grain of salt ;) )

In my experience, I have always found it best to have go.mod in the 
project's root directory (as well as only using one go.mod per repo). You 
could also use go mod vendor command, which will download all of the 
dependencies to a local "vendor" folder in the root of your main module, 
and rewrite the replace directives to point to those local paths (note you 
would need to use "go build -mod=vendor" to build). 
Also note that the go tool prefers the latest "tagged" release when 
considering dependencies, so it may be helpful to tag a working version of 
your module (which shouldn't contain replace directives to local paths) 
with something like "v0.0.1-alpha" or similar. You can find more info by 
running "go help modules" command.

-K

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/0f666676-e437-4284-9b39-5bd7527a1424%40googlegroups.com.

Reply via email to