utrack / Goban
Licence: mit
linter that bans usage of certain methods and functions
Stars: ✭ 18
Programming Languages
go
31211 projects - #10 most used programming language
goban
goban
is a Go(lang) linter that bans usage of user-supplied list of functions.
Usage
goban -cfg goban.cfg ./...
Config
Config is a newline-delimited list of banned symbols. Comments start with pound symbol (#).
Examples:
# bans method `url.Query()` on type *net/url.URL
(*net/url.URL).Query
# bans `context.TODO()`
context.TODO
If symbol has a comment on the same line - then it is printed along with the report.
fmt.Errorf # use pkg/errors instead
yields /path/to/file/foo.go:145:15: fmt.Errorf is banned - use pkg/errors instead
TODO
- [ ] Ban variables as well
- [ ] Support wildcards for rules
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].