Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
x/vgo: share local code inside custom $GOPATH #25053
I want to use
How could I use
Im trying to compile with script like this:
Without any actions I get this error:
If I change
Also, If I put something like this into
The result is:
Am I doing something wrong, or is this know limitation, or any other suggestion?
Currently I've found the solution:
Also, seems like
Any way, what is the convenient way to store the
Sorry for missing this when it came in. The top-level domain problem was real and I believe was fixed. It sounds like you got everything working once you added the require statement. I filed #26241 to try to make that experience better.
I'm not sure what you mean by "the v folder". I see it in the tree output, but I don't know what is in it. If it's like common, then the way is to give it an import prefix.
I think this is the mismatch. Typically instead of making the monorepo hold all of $GOPATH, you should make the root correspond to some directory like "$GOPATH/src/you.com/myrepo". Then "common" would be at the top level of the repo but imported as "you.com/myrepo/common", and similarly the go.mod would say "module you.com/myrepo/common". And then v would be the same: "module you.com/myrepo/v".