How to redirect logging to different log files on the package level of the source code (in buildSrc) in Gradle?


(dtserekhman) #1

Is there a way to easily specify different log files for different log levels and possibly for different Java/Groovy packages under buildSrc? Is there some file similar to log4j.xml that Gradle uses for its logging framework where I can specify all of this information?

Or the only way around is to implement StandardOutputListener and add it to the LoggingManager? But this way I think my capabilities are limited. For example, how can I still specify logging at the groovy source code package level?

Thanks, Dmitriy.