on-internet
← Community

Adding Go Packages

Stack Overflow ·

To learn Go, I wrote a Go program in 2013 (mods in 2020 and now). In 2020 it compiled to binary just fine. The main program, Sndemail.go is in a src folder. Under that are 2 folders (kemail with Kemail.go and osfiles with Osfiles.go along with their test programs). I never had a go.mod file before so I just created it with: go mod init Sndemail Spending hours trying to figure out how to add a package, I still get "Kemail.go is not in std" errors (same for Osfiles). What is the proper syntax for adding the Kemail and Osfiles modules to go.mod? and what is "example.com" that I see everywhere? Th

Comments

Sign in or sign up to comment and upvote.

No comments yet.