# Delete

API Documentation: | `Delete`

Deletes files or directories. Example:

    task makePretty(type: Delete) {
      delete 'uglyFolder', 'uglyFile'
    }

### Properties

Property | Description
`delete` | The set of files which will be deleted by this task.
`targetFiles` | The resolved set of files which will be deleted by this task.

### Property details

#### ``Set`<`Object`>` `delete`

The set of files which will be deleted by this task.

#### `FileCollection` `targetFiles` (read-only)

The resolved set of files which will be deleted by this task.

### Script blocks

No script blocks

### Methods

Method | Description
`delete(targets)` | Adds some files to be deleted by this task. The given targets are evaluated as for `Project.files()`.

### Method details

#### `Delete` `delete`(``Object`...` targets)

Adds some files to be deleted by this task. The given targets are evaluated as for `Project.files()`.