# Chapter 26. The Eclipse Plugin

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 (File - Import... - Existing Projects into Workspace). 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.

## 26.1. Usage

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`.

## 26.2. Tasks

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`