News for hackers. Stuff that matters.
Re:Show HN: Easy-to-configure Web Server in Go by pandeiro on Saturday July 27, 2013 @09:57AM (#6112881)
Code organization question: is this a common convention in Go, to nest the main package in a subdirectory and put all of the 'modules' in different files but with the same package name?

(I'm more used to the Clojure namespace/filesystem symmetry, so this is somewhat new to me. I like the more shallow project tree but it's not immediately apparent where things are defined.)

Re:Show HN: Easy-to-configure Web Server in Go by redbad on Saturday July 27, 2013 @10:07AM (#6112918)
In a package, main or otherwise, files are purely for programmer convenience. They define import scope but are otherwise transparent to the toolchain.
Re:Show HN: Easy-to-configure Web Server in Go by sarnowski on Saturday July 27, 2013 @05:30PM (#6114518)
You have to have your main() in package "main" and all your files in one directory have to be in the same package. So when you want a main() and your logic in a "real" package, your have to seperate them.