Closed cmosetick closed 8 years ago
Created a PR to get this started: https://github.com/fragmenta/fragmenta-cms/pull/13
I'm not sure about switching to the gb layout, I'll look into it at some point but there are very few external dependencies, so gb is not required and not a priority for me right now. I do want to keep the project go gettable (which is why the server.go file is in the main directory), and I think using gb precludes that and forces you to use the gb tool.
Re your problem above, I suspect your GOPATH is in fact /Users/chris, since you have a src dir under there. Fragmenta should probably refuse to generate and give you an error rather than generating with absolute paths though.
I've had a think about this and would prefer to keep the project go gettable I'm afraid (which is mostly why server.go is in the root folder).
I'm leaving this issue open for discussion of gb or future vendoring solutions.
Would it be acceptable to recognise an app which had server.go inside the src dir as a valid app as well? If so I'd be open to doing that, keeping the default go-gettable but allowing use of gb if people want to use it.
As the blessed approach to vendoring uses go get and a /vendor dir, I think I will be using that approach in my own projects using something like govend or godep.
gb
is the preferred tool now for building and managing go projects, because gb can guarantee reproducible builds. This means that everything is self contained in the "project dir" and simplifies the differences between development and production environments. http://getgb.io/docs/usage/ video intro to gbAlso, review the vendor plugin: https://godoc.org/github.com/constabulary/gb/cmd/gb-vendor
I'm having issues with fragmenta no matter where my project is located on my local system.
I'm having issues with absolute paths. Here, I placed my fragmenta "site" in my "gocode dir", which is in my path, but even in another location, I'm having trouble.