$ make fmt-check
$ make fmt-fix
$ make lint
Note that staticcheck
is installed as a global dependency to avoid it appearing unused in go.mod
and therefore getting auto-removed on tidy.
$ make test
View the app’s usage guide
$ make usage
go run main.go -h
NAME:
My App - Display a friendly greeting
...
$ go run main.go
Hello, World!
$ go run main.go --name Gopher
Hello, Gopher!
Run the app through make
, using some fixed sample inputs. This is useful for development to check functionality on a few test cases.
$ make run
go run main.go
Hello, World!
go run main.go --name Gopher
Hello, Gopher!
Install the app globally, as per Quickstart or Installation.
Then run it anywhere by name:
$ go-project-template
Hello, World!
See Deploy for building the app for a release.