All files within the same folder must have the same package name. In the main directory where the go.mod file can be found, that package is main. If you want to e.g. make a utils file, with its own package, it needs to be in a folder.

Import and export is done via casing. e.g.

func isNotExported() {}
// vs
func IsExported() {}

Coming from js, where you can do anything (good and bad!), these limitations at first were annoying but I actually quite like them. Every codebase will operate the same and its overall simple.

Though being able to simply grep for export in a file, would have been nice.