Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

GoLang / Google App Engine - Directory structure

I started developing an app with GoLang & GAE but I am having a hard time finding out how to layout the files. This is how I keep my GoLang files organized so far (before using GAE)

-golang
--bin
--pkg
--src
---breinbaas.nl
----lib
-----package1
-----package2

If I want to develop an app for GAE I would like to put it into

-golang
--src
---breinbaas
----deploy
-----mygae_app

But how am I able to use the files in the lib directory?

Is there a way to use the go files in the golang/src/breinbaas/lib directory? I keep getting a package not found error and the only way I can resolve this is by copying the lib directory to golang/src/breinbaas/deploy/mygae-app but that would mean copying source files to more than one location which is very bad for consistency.

Thx in advance! Rob

like image 230
BreinBaas Avatar asked Nov 04 '22 14:11

BreinBaas


1 Answers

The Go App Engine SDK doesn't currently support uploading packages from your GOPATH, so for now copying is your only option.

Feel free to create an issue about this on the Google App Engine issue tracker.

like image 138
proppy Avatar answered Nov 09 '22 03:11

proppy