Build: Rework eclipse settings copy so it does not get automatically cleaned
Gradle has "rules" for certain task names, and clean is one of these. When you run clean, it searches for any tasks named cleanX, and tries to reverse engineer the X task. For eclipse, this means it finds cleanEclipse, and internally runs it (but this does not show up as a dependency of clean in tasks list!!). Since we added .settings as an additional file to delete with cleanEclipse, this gets deleted when running just "clean". It doesn't delete the other files because those have their own clean methods, and dependencies are not followed in this insanity. This change simply makes a separate task for cleaning eclipse settings.
This commit is contained in:
parent
454de6a8f2
commit
9bfa613901
|
@ -303,9 +303,10 @@ allprojects {
|
|||
into '.settings'
|
||||
}
|
||||
// otherwise .settings is not nuked entirely
|
||||
tasks.cleanEclipse {
|
||||
task wipeEclipseSettings(type: Delete) {
|
||||
delete '.settings'
|
||||
}
|
||||
tasks.cleanEclipse.dependsOn(wipeEclipseSettings)
|
||||
// otherwise the eclipse merging is *super confusing*
|
||||
tasks.eclipse.dependsOn(cleanEclipse, copyEclipseSettings)
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue