LUCENE-9438: moved eclipse template files under corresponding gradle's script.

This commit is contained in:
Dawid Weiss 2020-08-31 15:09:26 +02:00
parent 4a2a2da462
commit 66eb9f7f3d
10 changed files with 9 additions and 1 deletions

View File

@ -57,5 +57,11 @@ allprojects {
propertyOrEnvOrDefault = { propName, envName, defValue ->
return propertyOrDefault(propName, envOrDefault(envName, defValue));
}
// Locate script-relative resource folder. This is context-sensitive so pass
// the right buildscript (top-level).
scriptResources = { buildscript ->
return file(buildscript.sourceFile.absolutePath.replaceAll('.gradle$', ""))
}
}
}

View File

@ -18,6 +18,8 @@
import org.gradle.plugins.ide.eclipse.model.SourceFolder
import org.gradle.plugins.ide.eclipse.model.ClasspathEntry
def resources = scriptResources(buildscript)
configure(rootProject) {
apply plugin: "eclipse"
@ -73,7 +75,7 @@ configure(rootProject) {
eclipseJdt {
doLast {
project.sync {
from rootProject.file("dev-tools/eclipse/dot.settings")
from rootProject.file("${resources}/dot.settings")
into rootProject.file(".settings")
}
}