shellcheck icon indicating copy to clipboard operation
shellcheck copied to clipboard

How to ignore multiple folders?

Open hongbo-miao opened this issue 4 years ago • 2 comments

  • [x] I searched through https://github.com/koalaman/shellcheck/issues and didn't find anything related

First thanks for the tool!

Current if I run shellcheck **/*.sh, it will check all files in current folder. I know I can use --source-path= to let it check certain folders.

I am wondering is there something like .gitignore to let us ignore some folders?

Currently my workaround way is using

shellcheck $(git ls-files '*.sh')

Also, I found some issues mentioned .shellcheckrc file, but I didn't find any document about this file in the README.md, do we have some document about this file?

Thanks!

hongbo-miao avatar Jun 22 '21 19:06 hongbo-miao

Also, I found some issues mentioned .shellcheckrc file, but I didn't find any document about this file in the README.md, do we have some document about this file?

That thing could probably do with a page in the wiki indeed. It's mentioned in the ignore page.

brother avatar Jun 24 '21 08:06 brother

Sorry to drag this issue back up, but has there been any discussion on adding the ability to exclude certain path/file patterns? I've spent some time digging through issues here and this seemed the most relevant.

I have a particular repository containing many submodules and shellcheck often OOMs while running (on a 32GiB machine). For complex repositories, an exclude list functionality similar to .gitignore would be incredibly useful.

chadsr avatar Apr 09 '24 12:04 chadsr