blob: 223462d088ea8277981a84d3101e4e0ca66329aa [file] [log] [blame] [view]
Dmitri Shuralyovbb6383d2015-02-05 19:02:00 -08001[`go generate`](https://blog.golang.org/generate) is only useful if you have tools to use it with! Here is an incomplete list of useful tools that generate code.
Samer Mastersonb3551a02015-02-02 14:38:50 -08002
Dmitri Shuralyovbb6383d2015-02-05 19:02:00 -08003* [go tool yacc](https://golang.org/cmd/yacc/) – Yacc for Go.
4* [stringer](https://godoc.org/golang.org/x/tools/cmd/stringer) – Implements `fmt.Stringer` interface for enums.
Dmitri Shuralyov8ecaf0b2015-02-05 19:04:53 -08005* [gostringer](https://godoc.org/github.com/sourcegraph/gostringer) – Implements `fmt.GoStringer` interface for enums.
Dmitri Shuralyovbb6383d2015-02-05 19:02:00 -08006* [jsonenums](https://github.com/campoy/jsonenums) – Implements `json.Marshaler` and `json.Unmarshaler` interfaces for enums.
Samer Masterson39421262015-02-02 15:04:14 -08007* [gen-mocks](https://sourcegraph.com/sourcegraph/gen-mocks) – Generate mocks for interfaces. Used in [go-sourcegraph](https://sourcegraph.com/sourcegraph.com/sourcegraph/go-sourcegraph@master/.tree/sourcegraph).