{{ message }}
Repository navigation
Magefiles in their own nested Go module #464
Answered
by
natefinch
yann-soubeyrand
asked this question in
Q&A
Replies: 1 comment 3 replies
|
It's not a good idea to have two modules in the same repo. It causes a lot of problems with go in general. You can do it, but it's kind of a pain. This might be fixable, but I'm not 100% sure yet. Can you show me what kind of output mage produces in this case? |
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment

Yeah, I think this is because mage is actually running in the root directory, so it's using the go.mod of the root directory. It probably shouldn't do that if you have a
magefilesdirectory, instead it should change the current working directory to that directory to build the magefiles.I think this is fixable, but I'm a little worried it may break other people. I'll have to look at it and do some testing.