Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Anyone have an example of go modules with an actual application? Not some simple single directory helloworld joke? #30783

Open
rhugga opened this Issue Mar 12, 2019 · 4 comments

Comments

Projects
None yet
5 participants
@rhugga
Copy link

rhugga commented Mar 12, 2019

Pulling my effing hair out trying to sort thru the nightmare go dependencies are.

After we finally got our package working with dep.. we now have to move to go modules because dep ensure was an absolute nightmare in our CI/CD system with all the kubernetes packages.

I can't find a single example or document or blog that isn't just some simple helloworld example regurgitated from the go modules documentation.

Is there a doc or example of doing this with a complex directory structure with many go packages at varying depths?

@ALTree

This comment has been minimized.

Copy link
Member

ALTree commented Mar 12, 2019

Hi.

Somewhat related: #28215 (website: Update "How to Write Go Code" with go modules). It's targeted Go1.13, since it's when modules will be on by default.

Since it's possible that something like what you're requesting here could be written as part of a doc fix for that issue, you could also give your feedback (i.e. vocalize your request for a more detailed, real-world example of modules use) in that thread.

@ALTree ALTree added this to the Go1.13 milestone Mar 12, 2019

@mvdan

This comment has been minimized.

Copy link
Member

mvdan commented Mar 12, 2019

Not some simple single directory helloworld joke?

Pulling my effing hair out trying to sort thru the nightmare go dependencies are.

If you'd like better examples and documentation, I don't think calling the current ones a joke is the way forward. Software can be frustrating, but your issues aren't going to be productive if they read like rants.

Having said that, there are plenty of real-world examples out there to look at, such as:

https://github.com/gohugoio/hugo
https://github.com/golang/tools
https://github.com/etcd-io/etcd
https://github.com/prometheus/prometheus
https://github.com/junegunn/fzf

@agnivade

This comment has been minimized.

Copy link
Member

agnivade commented Mar 13, 2019

Does that above examples give you what you need ?

Regarding documentation, the modules wiki is a pretty comprehensive and up-to-date doc. If you have any specific suggestions, please redirect them to #28215 or feel free to update the wiki itself.

@winjeg

This comment has been minimized.

Copy link

winjeg commented Mar 13, 2019

All my applications written in Golang are using go modules.
Here, take a look
https://github.com/winjeg

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.