On browsing through the
of @Niels van Reijmersdal answer, I found this written in the README
Markovtsev Vadim implemented a very similar analysis that claims to be 20%-6x faster than Git of Theseus. It's named Hercules and there's a great blog post about all the complexity going into the analysis of Git history.
So well lookup Hercules and go through ...
You can do this in Administration -> Configuration -> Analysis Scope -> Restrict Scope of Coding Rules. You need to specify the code of the rule (without spaces) and a file path pattern to filter. If you use the maven standard **/src/main/** will work for you.
For more information see the docs where it states that you can:
...exclude files/directories ...