-
Notifications
You must be signed in to change notification settings - Fork 160
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
Cannot apply to buildSrc #743
Comments
Can you share a build scan? Also, a minor reproducer would be nice. @wakingrufus we could probably automatically filter out this directory when the kotlin-dsl plugin is applied. Thoughts? |
The scan is here: https://scans.gradle.com/s/enzehbyek47qs Attached a simple reproducer. |
We could. I don't see this problem in regular projects using the kotlin-dsl plugin, so what is different about buildSrc that causes this? |
tl;dr: It looks like something is getting cached in I ran into this same problem: ktlint was reporting errors in the Kotlin code that Gradle generates in ktlint {
filter {
exclude {
it.file.relativeTo(projectDir).startsWith(File("build"))
}
}
} ...and it continued reporting these errors. Eventually I used I was able to narrow the problem down to
"WORKS" and "FAILS" indicate the outcome of running |
When I add the plugin to buildSrc/build.gradle.kts:
it fails on classes generated by Gradle, even though I explicitly instruct the plugin not to include them.
The text was updated successfully, but these errors were encountered: