6 ms·
That approach is nice and all if we are dealing with modules which we wish to reuse. If instead we would like to organize our source tree following a deep dire
by Mooby 14y ago
That approach is nice and all if we are dealing with modules which we wish to reuse. If instead we would like to organize our source tree following a deep directory structure, we are forced to screw around with $GOPATH, which is a braindead idea.
- drivebyacct2 14y agoHuh? You can literally just set $GOPATH to any directory. The only stipulation is that you put your source code in a 'src' folder. That's literally all you have to do. I'm going to go out on a limb and guess you're one of the people that cries in IRC and can't be bothered to read either of the pages that detail the design and use of the `go` tool.
- marshray 14y agoYou keep asserting that this $GOPATH is "braindead" but you provide no meaningful criticism of it or suggest any better alternatives. I haven't messed with Go, but nothing about the idea of defining a path for source modules sounds braindead on its face to me. I certainly would give the benefit of any doubt to the designers of Go over some random troll.
- Mooby 14y agoThese are not source modules I'm talking about. If it was only necessary to set $GOPATH to point to source modules then everything would be fine. The problem is that go requires that $GOPATH points to a project's source tree to be able to build it, if the project is organized to store other go source files in subdirectories. We aren't talking about packages or modules intended to be reused in other programs. We are talking about how source code trees are organized.
- marshray 14y agoThe problem is that go requires that $GOPATH points to a project's source tree to be able to build it How is that different than the /I ${INCLUDE} path of C/C++ compilers (and many other languages)?