I would like to exclude a few directories form error prone. I was trying to use a XepExcludedPaths flag but it seems that it works only for the one path which is a regular expresion of excluded location.
options.errorprone.errorproneArgs.add("-XepExcludedPaths:.*/legacy/model/.*")
works
options.errorprone.errorproneArgs.add("-XepExcludedPaths:.*/new/model/.*,.*/build/.*")
doesn't
Is it possible? I used wrong separator?
It's a single regular expression (literally compiled using Pattern.compile
), so use a pipe instead of a comma:
options.errorprone.errorproneArgs.add("-XepExcludedPaths:(.*/new/model/.*|.*/build/.*)")
or
options.errorprone.errorproneArgs.add("-XepExcludedPaths:.*/(new/model|build)/.*")
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With