fix eclipse (again)
This commit is contained in:
parent
0dca49fae4
commit
3961c9b58b
|
@ -76,7 +76,7 @@ Contributing to the Elasticsearch codebase
|
||||||
|
|
||||||
**Repository:** [https://github.com/elastic/elasticsearch](https://github.com/elastic/elasticsearch)
|
**Repository:** [https://github.com/elastic/elasticsearch](https://github.com/elastic/elasticsearch)
|
||||||
|
|
||||||
Make sure you have [Gradle](http://gradle.org) installed, as Elasticsearch uses it as its build system. Integration with IntelliJ and Eclipse should work out of the box. Eclipse users can automatically configure their IDE: `File > Import -> Gradle -> Gradle project`. Additionally you will want to ensure that Eclipse is using 2048m of heap by modifying `eclipse.ini` accordingly to avoid GC overhead errors.
|
Make sure you have [Gradle](http://gradle.org) installed, as Elasticsearch uses it as its build system. Integration with IntelliJ and Eclipse should work out of the box. Eclipse users can automatically configure their IDE: `gradle eclipse` then `File: Import: Existing Projects into Workspace`. Select the option `Search for nested projects`. Additionally you will want to ensure that Eclipse is using 2048m of heap by modifying `eclipse.ini` accordingly to avoid GC overhead errors.
|
||||||
|
|
||||||
Please follow these formatting guidelines:
|
Please follow these formatting guidelines:
|
||||||
|
|
||||||
|
|
17
build.gradle
17
build.gradle
|
@ -18,6 +18,7 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
import com.bmuschko.gradle.nexus.NexusPlugin
|
import com.bmuschko.gradle.nexus.NexusPlugin
|
||||||
|
import org.gradle.plugins.ide.eclipse.model.SourceFolder
|
||||||
|
|
||||||
buildscript {
|
buildscript {
|
||||||
repositories {
|
repositories {
|
||||||
|
@ -161,14 +162,20 @@ if (hasProperty('projectsPrefix') == false) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// ecplise configuration
|
// eclipse configuration
|
||||||
allprojects {
|
allprojects {
|
||||||
apply plugin: 'eclipse'
|
apply plugin: 'eclipse'
|
||||||
|
|
||||||
// TODO: similar for intellij
|
plugins.withType(JavaBasePlugin) {
|
||||||
eclipse {
|
eclipse.classpath.defaultOutputDir = new File(project.buildDir, 'eclipse')
|
||||||
classpath {
|
eclipse.classpath.file.whenMerged { classpath ->
|
||||||
defaultOutputDir = new File(project.buildDir, 'eclipse')
|
// give each source folder a unique corresponding output folder
|
||||||
|
int i = 0;
|
||||||
|
classpath.entries.findAll { it instanceof SourceFolder }.each { folder ->
|
||||||
|
i++;
|
||||||
|
// this is *NOT* a path or a file.
|
||||||
|
folder.output = "build/eclipse/" + i
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// otherwise the eclipse merging is *super confusing*
|
// otherwise the eclipse merging is *super confusing*
|
||||||
|
|
|
@ -1 +0,0 @@
|
||||||
/bin/
|
|
Loading…
Reference in New Issue