koalaman / shellcheck

ShellCheck, a static analysis tool for shell scripts
https://www.shellcheck.net
GNU General Public License v3.0
35.61k stars 1.75k forks source link

Suggestion: only put out number of issues #2104

Open deknos opened 3 years ago

deknos commented 3 years ago

For new checks and feature suggestions

Here's what I wanted or expected to see:

Hi, instead of output every issue i would like to have a parameter which counts every (unwhitelisted) occurence to get a number of all the issue. for example if myscript.sh has 33 issues (which are not excepted in the code), it prints something like this:

shellcheck --count=sum myscript.sh 33

Optional would be counting and printing of occurrences of different types like

shellcheck --count=different myscript.sh
SC2059: 23
SC2086: 45
brother commented 3 years ago

try shellcheck -f gcc file.sh | wc -l