Fix libs:ssl-config project setup (#39074)

The build script file for the `:libs:elasticsearch-ssl-config` and
`:libs:ssl-config-tests` projects was incorrectly named `eclipse.build.gradle`
 while the expected name was `eclipse-build.gradle`.
In addition, this also adds a missing snippet in the `build.gradle` conf file,
that fixes the project setup for Eclipse users.
This commit is contained in:
Albert Zaharovits 2019-02-19 02:17:05 +02:00 committed by Albert Zaharovits
parent 6bc88b00ec
commit 5c30446bd0
3 changed files with 17 additions and 3 deletions

View File

@ -34,9 +34,23 @@ dependencies {
testCompile "org.hamcrest:hamcrest-all:${versions.hamcrest}" testCompile "org.hamcrest:hamcrest-all:${versions.hamcrest}"
} }
if (isEclipse) {
// in eclipse the project is under a fake root, we need to change around the source sets
sourceSets {
if (project.path == ":libs:ssl-config") {
main.java.srcDirs = ['java']
main.resources.srcDirs = ['resources']
} else {
test.java.srcDirs = ['java']
test.resources.srcDirs = ['resources']
}
}
}
forbiddenApisMain { forbiddenApisMain {
replaceSignatureFiles 'jdk-signatures' replaceSignatureFiles 'jdk-signatures'
} }
forbiddenPatterns { forbiddenPatterns {
exclude '**/*.key' exclude '**/*.key'
exclude '**/*.pem' exclude '**/*.pem'

View File

@ -1,2 +1,2 @@
// this is just shell gradle file for eclipse to have separate projects for geo src and tests // this is just shell gradle file for eclipse to have separate projects for ssl-config src and tests
apply from: '../../build.gradle' apply from: '../../build.gradle'

View File

@ -1,5 +1,5 @@
// this is just shell gradle file for eclipse to have separate projects for geo src and tests // this is just shell gradle file for eclipse to have separate projects for ssl-config src and tests
apply from: '../../build.gradle' apply from: '../../build.gradle'
dependencies { dependencies {
testCompile project(':libs:elasticsearch-ssl-config') testCompile project(':libs:elasticsearch-ssl-config')
} }