Overview How to auto-format the *.go source files Formatting is contentious but not consequential Formatting - Recursively SRC_ROOT=$HOME/git-repos/go; gofmt -s -w $SRC_ROOT; Goland Official docs Gotcha gofmt and go fmt are different Arguments are different Other Resources https://go.dev/blog/gofmt https://pkg.go.dev/cmd/gofmt