This chapter is a work in progress.
The Eclipse plugin generates files that are used by Eclipse IDE, thus making it possible to import the project into Eclipse ( - - ). Both external and project dependencies are considered.
To use the plugin, include in your build script:
usePlugin('eclipse')
The Eclipse plugin will create different files depending on the other plugins used. If used together with the Java Plugin, .project
and .classpath
files will be generated. If used with the War plugin, additional wtp files will be generated.
There are several tasks (presented in Table 26.1, “Eclipse plugin - tasks”) that the Eclipse plugin provides, but you will probably use only eclipse
task by executing gradle eclipse
.
The Eclipse plugin adds the tasks shown in Table 26.1, “Eclipse plugin - tasks” to a project.
Table 26.1. Eclipse plugin - tasks
Task name | Depends on | Type |
eclipse
|
eclipseCp , eclipseProject , eclipseWtp
|
-
|
eclipseClean
|
-
|
EclipseClean
|
eclipseCp
|
-
|
EclipseClasspath
|
eclipseProject
|
-
|
EclipseProject
|
eclipseWtp
|
-
|
EclipseWtp
|
eclipseWtpModule
|
-
|
EclipseWtpModule
|