https://github.com/knsh14/go-conditional-complexity
Checks conditional complexity of go code
https://github.com/knsh14/go-conditional-complexity
Last synced: 2 days ago
JSON representation
Checks conditional complexity of go code
- Host: GitHub
- URL: https://github.com/knsh14/go-conditional-complexity
- Owner: knsh14
- License: mit
- Created: 2018-11-01T11:27:22.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2019-03-12T16:38:20.000Z (over 7 years ago)
- Last Synced: 2025-06-15T06:48:32.135Z (12 months ago)
- Language: Go
- Size: 25.4 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# go-conditional-complexity
# Install
```
$ go get github.com/knsh14/go-conditional-complexity/cmd/gocc
```
# Usage
```
$ gocc -max 16 -exclude testdata -top 10 -avg ./
```
## -max N
threshold to show. command shows more complicated functions than this parameter.
default value is 12. it is same score to flake8.
## -exclude PATTERN
command will not checks any files to match input pattern.
pattern is complied to go regular expression.
## -top N
output most complicated functions
## -avg
output average complexity for all functions and filtered functions if this flag is set.
## ARG
path to check complexity.
checks all go files under input directory recursive.
if no path is passed. checks current directory.