Fix hyperlink for elements of the type 'KtFile'#3386
Merged
schalkms merged 3 commits intodetekt:masterfrom Jan 18, 2021
Merged
Conversation
337c48b to
a67ba86
Compare
Codecov Report
@@ Coverage Diff @@
## master #3386 +/- ##
============================================
+ Coverage 80.45% 80.46% +0.01%
- Complexity 2737 2739 +2
============================================
Files 447 448 +1
Lines 8287 8282 -5
Branches 1573 1573
============================================
- Hits 6667 6664 -3
+ Misses 772 771 -1
+ Partials 848 847 -1
Continue to review full report at Codecov.
|
e31e758 to
88c7eac
Compare
88c7eac to
9b5bd96
Compare
schalkms
reviewed
Jan 18, 2021
Member
schalkms
left a comment
There was a problem hiding this comment.
Thanks for the detailed investigation! This PR looks very good! Finally, this issue gets closed. I like it.
detekt-api/src/test/kotlin/io/gitlab/arturbosch/detekt/api/EntitySpec.kt
Outdated
Show resolved
Hide resolved
detekt-api/src/main/kotlin/io/gitlab/arturbosch/detekt/api/internal/Signatures.kt
Show resolved
Hide resolved
…itySpec.kt Co-authored-by: M Schalk <30376729+schalkms@users.noreply.github.com>
9 tasks
BraisGabin
approved these changes
Jan 18, 2021
Member
BraisGabin
left a comment
There was a problem hiding this comment.
Thanks! Really good investigation!
schalkms
approved these changes
Jan 18, 2021
This was referenced Mar 11, 2021
Closed
This was referenced Mar 11, 2021
This was referenced Mar 18, 2021
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Issue: #2340
Description:
IntelliJ (and consequently Android Studio), considers the following implementation when enabling hyperlink in its terminal emulator: AbstractFileHyperlinkFilter
I noticed that there were two issues happening related to hyperlinks not being enabled in the output of detect:
Example of the point 2 before the changes I applied in this PR:

Fix:
A fix for point 2 is to simplify the Entity name in the case of Files by getting the file name without the absolute path since the path is also written along with the output.
Regarding other terminal emulators, it really depends on the terminal emulator you're using to specify the way of hyperlinking: https://gist.github.com/egmontkob/eb114294efbcd5adb1944c9f3cb5feda.
This only tackles the IntelliJ Terminal Emulator.