-
-
Notifications
You must be signed in to change notification settings - Fork 778
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add a new ConsoleReport format #4027
Conversation
Codecov Report
@@ Coverage Diff @@
## main #4027 +/- ##
=========================================
Coverage 83.51% 83.51%
+ Complexity 3186 3185 -1
=========================================
Files 461 463 +2
Lines 9095 9095
Branches 1768 1767 -1
=========================================
Hits 7596 7596
Misses 570 570
Partials 929 929
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that this should be the one turned on by default.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Other than the name I really like this. The name seems to imply that all others are unreadable. Maybe something like LinePerFindingReport
?
Agree. How about somethine like |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great work 👍
...src/main/kotlin/io/gitlab/arturbosch/detekt/core/reporting/console/ReadableFindingsReport.kt
Outdated
Show resolved
Hide resolved
* Contains a clear read of the console report, where each line contains location, messages and issue id. | ||
* See: https://detekt.github.io/detekt/configurations.html#console-reports | ||
*/ | ||
class ReadableFindingsReport : ConsoleReport() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could we refactor FindingsReport
and this class to a single hierarchy? Apparently the difference is just the (Map<String, List<Finding>>) -> String
function that they're invoking.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wouldn't call this ReadableFindingsReport. Is the other FindingsReport not readable? I would prefer to call it ConciseFindingsReport.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I changed the name to LiteFindingsReport
as suggested above.
This addresses #3423.
This new consoleReport will be turned off by default. For comparison, I will list the console report from other tools below:
Existing FindingsReport
New LiteFindingsReport
Checkstyle
Ktlint
Kotlinc