Closed angusmcleod closed 3 years ago
Go has a syntax formatting rules which can be enforced with gofmt
. Is that what you are looking for?
Yup, that looks like what we need :+1:. Perhaps packaged as a pre-commit script: https://github.com/golang/go/blob/release-branch.go1.1/misc/git/pre-commit. Would you mind making a PR adding that as a pre-commit script if you agree that's the way to implement to ensure adherence by multiple contributors?
Making hooks part of a repo is considered bad practice, because it can result in pretty sneaky actions. I will open a separate PR addressing this after #15 is merged.
Establish syntax rules and a linter for this repository, and perorm the first repo-wide syntax correction. The linter should be added to the CI, depending on whether #9 is complete or not.