How do I exclude `kotlin-compiler-embeddable-2.0.2...
# intellij
c
How do I exclude
kotlin-compiler-embeddable-2.0.21.jar
and the other Gradle Kotlin dependencies from double-shift search and "Go to Declaration"? I know they're only used by Gradle because clicking one shows the "script dependencies sources analyses are disabled" banner, but they don't show up in my project dependencies in IDEA so I can't exclude them via scope. My whole search looks like this, and all of the duplicates are decompiled classes from the wrong Kotlin version. I never added these as dependencies, and they don't even appear in my project dependencies.
t
kotlin-compiler-embeddable-2.0.21.jar
and similar entries appear to come from Gradle/Kotlin script dependencies rather than regular project dependencies, which is why they may not appear in Project Structure. I'm not aware of a supported way to exclude them from both Search Everywhere and Go to Declaration. This looks related to KTIJ-22311, although that ticket covers navigation into script dependencies rather than filtering them. The entries prefixed with
Gradle:
may have a different source, so could you check where they come from under External Libraries? If there is still no way to filter them, please file a KTIJ ticket with your IDE build, Gradle/Kotlin versions and a small sample project.
c
Thank you for replying! The ones prefixed with
Gradle:
come from my explicit dependency on the compiler: Kotlin Compiler 2.4.21. I'm writing a plugin for that compiler version, and those do appear in External Libraries for my project like any other.
t
Thanks, that explains the
Gradle:
entries. This looks like the issue already reported in KTIJ-28728. You can add a comment there with your case and vote for the issue.