Command godefaultinstance generates at the package level a default instance of a type and functions that call methods on it.
This command is designed to be called with go generate; run godefaultinstance -h for help.
Check out the example at github.com/tcard/godefaultinstance/example.
go get github.com/tcard/godefaultinstance