Peter Kurfer
9791e9f282
- allow to interactively execute checks instead of server mode - use urfave/cli for subcommands
24 lines
No EOL
517 B
TOML
24 lines
No EOL
517 B
TOML
[hooks]
|
|
|
|
pre-commit = [
|
|
"golangci-lint run --fast --fix",
|
|
"husky lint-staged",
|
|
]
|
|
|
|
commit-msg = [
|
|
"husky lint-commit",
|
|
]
|
|
|
|
[lint-staged]
|
|
"*.go" = [
|
|
"goimports -l -w",
|
|
"gofmt -l -w",
|
|
]
|
|
|
|
[lint-commit]
|
|
# could check if this exists
|
|
# email = "^(.+@gmail.com|.+@qq.com)$"
|
|
# optional custom types check regex
|
|
types = "^(feat|fix|build|chore|ci|docs|perf|refactor|revert|style|test)$"
|
|
# optional header check regex
|
|
header = "^(?P<type>\\w+)(\\((?P<scope>[\\w/.-]+)\\))?(?P<breaking>!)?:( +)?(?P<header>.+)" |