When JGit fails, it doesn't throw an IOException (atleast not all the time). I was getting custom exceptions that extend IllegalArguments like when the \r was still in the file. When it happened it skipped displaying our chain of the exception. This will ensure we get our message in.
Similar to https://github.com/checkstyle/checkstyle/blob/master/src/main/java/com/puppycrawl/tools/checkstyle/Checker.java#L298-L300
When JGit fails, it doesn't throw an IOException (atleast not all the time). I was getting custom exceptions that extend IllegalArguments like when the
\r
was still in the file. When it happened it skipped displaying our chain of the exception. This will ensure we get our message in.