Skip to content
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

Task with name 'clean' not found in root project #1023

Closed
ColtonIdle opened this issue Dec 7, 2021 · 0 comments
Closed

Task with name 'clean' not found in root project #1023

ColtonIdle opened this issue Dec 7, 2021 · 0 comments

Comments

@ColtonIdle
Copy link

ColtonIdle commented Dec 7, 2021

Filing and closing so that this becomes searchable for others in the future (hopefully helpful if you're inheriting a project that you didn't originally setup)

I originally filed #858 (comment) a while back. The gist was that setting up spotless didn't work out of the box with an android project. There was a "workaround" needed, and now after updating spotless to the latest version the workaround isn't needed anymore so you can return the old code that used to be there.

Workaround:

tasks.named("clean", Delete::class) { delete(rootProject.buildDir) }

Fix: (basically revert to what a standard android app comes with out of the box)

tasks.register("clean", Delete::class) {
    delete(rootProject.buildDir)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant