Go modules and packages: how to create a module and how to split an app into packages
Every Go project starts the same way: one main.go, it works, it grows, and at some point you have a 1500-line file
and the question “how do I split this up” - followed by “and what is the difference between a module and a package
again”. This post is the answer I give every time. It is short on theory and long on the three commands and one
directory layout you actually need, with links to the official docs for the parts I skip.