VeryGoodOpenSource/very_good_analysis

I would love to have per rule exclude of the folder.

Closed this issue ยท 5 comments

In case of generated protobuf files, the very_good_analysis does report issues.

I would like to add a rule filter (exclude filter) per folder, so the generated files would not be included.
for example lib/src/proto/**

Ahh I just had the same issues, how do I ignore a folder

Hi @magillus and @arpitjacob ๐Ÿ‘‹
Thanks for opening an issue!

You should be able to exclude files/folders like so:

include: package:very_good_analysis/analysis_options.yaml

analyzer:
  exclude:
    - "**/*.g.dart"
    - "**/*.freezed.dart"
    - "**/proto/**"

Let me know if that helps ๐Ÿ‘

Thanks this worked for me, only issue is when I open any of those excluded files, VScode immediately throws all the error even though the file is excluded.

@arpitjacob do you have a sample app which reproduces the issue? Thanks!

@arpitjacob do you have a sample app which reproduces the issue? Thanks!

Hi please ignore this, it works great, I wasn't excluding the files properly.