written in several programming languages (for example Go and Python)?
Ideally, we would want to keep everything in the same git repository
because 1) it makes easier to keep the Python and Go logic in sync and 2) some
assets are shared by the Python and Go code.
One obvious way is to checkout the project source in some arbitrary
directory like $HOME/projects/myproject, create a subdirectory go
containing all the Go code, and make it accessible in $GOPATH with ln -s
$HOME/projects/myproject/go $GOPATH/src/myproject. But this solution looks
like a dead-end because symbolic links were declared "not supported" many
times on golang-nuts and golang-dev.
Another way is to checkout the full project source (Go and Python) in
$GOPATH/src/myproject and import "myproject/go" instead of "myproject".
It's perfect and idiomatic from Go's point of view. But from Python's point
of view, it's weird to be forced to live in $GOPATH. Go requires the
project source to live in a directory src under $GOPATH. Now let's imagine
that Python would require the project source to be rooted in a directory
lib (for example) under its own $PYPATH. That would make Go's and Python's
requirements contradictory and impossible to satisfy at the same time.
Another way is to create a Go workspace directly in the project source tree
and add it to the $GOPATH. This implies myproject would have its own
src/bin/pkg directories and this approach was explicitly not recommended on
this mailing list in the past (
https://groups.google.com/forum/#!topic/golang-nuts/dxOFYPpJEXo).
I'm not sure how to solve this in a simple and clean way. What is your
experience solving this issue in your own projects?
Nicolas
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.