scalastyle / scalastyle-sbt-plugin

scalastyle-sbt-plugin
Apache License 2.0
139 stars 52 forks source link

Support running scalastyle over only files modified in a patch #37

Closed ajsquared closed 9 years ago

ajsquared commented 9 years ago

If you give the scalastyle task the path to a patch file as an argument, it will process only the files modified in that patch. The regex used to extract the file names from the patch is configurable.

matthewfarwell commented 9 years ago

I think this is a bit too specific. Is there any way to make it more general? For instance some would like to be able to include a set of directories, or exclude a set. I would think that it would be inconvenient for you to just specify a single file.

How often do you do this? For instance, if I gave you a way to specify a set of files either on the command line or in a file, you could create another task (say scalastylePatch) which took a patch file, created this file and runs scalastyle?

ajsquared commented 9 years ago

My use case is to be able to run scalastyle over just the files that have changed in a particular commit. Being able to specify a set of files over which to run scalastyle would work too. I'll close this then.