# Gulp tool window

> **TL;DR**
> `Context menu of a Gulpfile.js - Show Gulp Tasks`
>
>
>
>
>
> `View | Tool Windows | Gulp`

Use this tool window to run [Gulp.js tasks](http://gulpjs.com/) The result of executing a task is shown in the [Run tool window](run-tool-window.html).  The tool window shows the Gulp.js output, reports the errors occurred, lists the packages or plugins that have not been found, etc. The name of the last executed task is displayed on the title bar of the tool window.

## Before you start

Procedure:

1. Download and install [Node.js](http://nodejs.org/#download).

2. Install the gulp-cli package (Gulp command-line interface) globally and install the gulp package as a development dependency. For more information, refer to [Installing Gulp.js](using-gulp-task-runner.html#installingGulp).

## Running tasks

> **Tip:**
> * When you build a tree of tasks for the first time during an IntelliJ IDEA session, the Gulp tool window is not opened yet.
>
> * If you already opened the Gulp tool window, you can access it with [Search everywhere](searching-everywhere.html). Press `Shift` (Windows), `Shift` (macOS), `Shift` (IntelliJ IDEA Classic (macOS)), `Shift` (macOS System Shortcuts), `Shift` (XWin), `Shift` (GNOME), `Shift` (KDE), `Shift` (Emacs), `Shift` (Sublime Text), `Shift` (Sublime Text (macOS)), `Shift` (NetBeans), `Shift` (Visual Studio), `Shift` (Visual Studio (macOS)), `Shift` (Eclipse), `Shift` (Eclipse (macOS)) twice to open the search window, start typing your query, for example, `Gulp task`, and select Show Gulp Tasks from the list. Alternatively, select `View | Tool Windows | Gulp` from the main menu.

Procedure: To open the Gulp tool window

* Select the required `Gulpfile.js` file in the   Project tool window  (`Alt+1` (Windows), `⌘ 1` (macOS), `⌘ 1` (IntelliJ IDEA Classic (macOS)), `⌘ 1` (macOS System Shortcuts), `Alt+1` (XWin), `Alt+1` (GNOME), `Alt+1` (KDE), `Alt+1` (Emacs), `Alt+1` (Sublime Text), `⌘ 1` (Sublime Text (macOS)), `Ctrl+1` (NetBeans), `Ctrl+Alt+L` (Visual Studio), `⌘ ⌥ L` (Visual Studio (macOS)), `Alt+1` (Eclipse), `Alt+1` (Eclipse (macOS)))  or open it in the editor and choose Show Gulp Tasks from the context menu.

By default IntelliJ IDEA does not recognize ES6 in `Gulpfile.js` and fails to build a task tree. To solve this problem, update the default Gulp.js run configuration.

Procedure: To build a tasks tree from a ES6 Gulpfile.js

1. Go to `Run | Edit Configurations`. Alternatively, select Edit Configurations from the Run widget on the toolbar.

![Open the Edit Configurations dialog](https://resources.jetbrains.com.cn/help/img/idea/2026.2/ws_node_run_config_create.png)

2. Under the Templates node, click Gulp.js.

3. In the [Run/Debug Configuration: Gulp.js](run-debug-configuration-gulp-js.html) dialog that opens, type `--harmony` in the Node options field and click OK.

Procedure: To build a tree of tasks

* In the Gulp tool window, click ![the Add button](https://resources.jetbrains.com.cn/help/img/idea/2026.2/app.expui.general.add.svg) on the toolbar and choose the required `Gulpfile.js` file from the list.         By default, IntelliJ IDEA shows the `Gulpfile.js` file in the root of your project.

* If you have another `Gulpfile.js` file, click Choose Gulpfile.js and select the `Gulpfile.js` file you need in the dialog that opens. IntelliJ IDEA adds a new node with the path to the chosen `Gulpfile.js` file on its title and builds a tasks tree under the new node.

Procedure: To re-build a tree

* Switch to the required node and click ![Reload Scripts](https://resources.jetbrains.com.cn/help/img/idea/2026.2/app.actions.refresh.svg) on the toolbar.

Procedure: To sort the tasks in a tree by their names

* Click ![Settings](https://resources.jetbrains.com.cn/help/img/idea/2026.2/app.general.gear.svg) on the toolbar, choose Sort by from the menu, and then choose Name.

By default, a tree shows the tasks in the order in which they are defined in `Gulpfile.js` (option Definition order).

Procedure: To run a task

* Double-click the task.

* Select the task in the tree and press `Enter` (Windows), `⏎` (macOS), `⏎` (IntelliJ IDEA Classic (macOS)), `⏎` (macOS System Shortcuts), `Enter` (XWin), `Enter` (GNOME), `Enter` (KDE), `Enter` (Emacs), `Enter` (Sublime Text), `⏎` (Sublime Text (macOS)), `Enter` (NetBeans), `Enter` (Visual Studio), `⏎` (Visual Studio (macOS)), `Enter` (Eclipse), `⏎` (Eclipse (macOS)) or choose Run <task name> from the context menu.

Procedure: To run the default task

* Select the root node in the tree, and choose Run default from the context menu of the selection.

Procedure: To run several tasks

* Use the multiselect mode: hold `Shift` (Windows), `Shift` (macOS), `Shift` (IntelliJ IDEA Classic (macOS)), `Shift` (macOS System Shortcuts), `Shift` (XWin), `Shift` (GNOME), `Shift` (KDE), `Shift` (Emacs), `Shift` (Sublime Text), `Shift` (Sublime Text (macOS)), `Shift` (NetBeans), `Shift` (Visual Studio), `Shift` (Visual Studio (macOS)), `Shift` (Eclipse), `Shift` (Eclipse (macOS)) (for adjacent items) or `Ctrl` (Windows), `Ctrl` (macOS), `Ctrl` (IntelliJ IDEA Classic (macOS)), `Ctrl` (macOS System Shortcuts), `Ctrl` (XWin), `Ctrl` (GNOME), `Ctrl` (KDE), `Ctrl` (Emacs), `Ctrl` (Sublime Text), `Ctrl` (Sublime Text (macOS)), `Ctrl` (NetBeans), `Ctrl` (Visual Studio), `Ctrl` (Visual Studio (macOS)), `Ctrl` (Eclipse), `Ctrl` (Eclipse (macOS)) (for non-adjacent items) keys and select the required tasks, then choose Run or Debug from the context menu of the selection.

Procedure: To navigate to the definition of a task

* Select the required task in the tree, and choose Jump to source from the context menu of the selection.

## Toolbar

|  ![](https://resources.jetbrains.com.cn/help/img/idea/2026.2/app.expui.general.add.svg)  |  Add Gulpfile  |  Click this button to have a task tree for another `Gulpfile.js` file built. Choose the required `Gulpfile.js` file from the list. IntelliJ IDEA builds a task tree and shows it under a separate node.  |
|  ![minusSign.png](https://resources.jetbrains.com.cn/help/img/idea/2026.2/minusSign.png)  |  Remove Gulpfile  |  Click this button to remove the task tree under the selected node.  |
|  ![icon_reload_grunt.png](https://resources.jetbrains.com.cn/help/img/idea/2026.2/icon_reload_grunt.png)  |  Reload tasks  |  Click this button to have the task tree under the selected node re-built. You may need a tree re-built after updating the corresponding `Gulpfile.js` file because Gulp.js does not apply changes to trees on the fly.  |
|  ![Collapse all](https://resources.jetbrains.com.cn/help/img/idea/2026.2/app.expui.general.collapseAll.svg)  |  Collapse all  |  Click this button to hide all the tasks trees and have only Gulpfile.js nodes displayed.  |
|  ![View Modes](https://resources.jetbrains.com.cn/help/img/idea/2026.2/app.general.gear.svg)  |                |     Click this button to configure the current view and to change the viewing modes of the tool window . For more information, refer to [Tool window view modes](viewing-modes.html) .       Note that most of the menu items are options that you can turn on or off. An option which is on has a check mark to the left of its name. The Gulp-specific options are:        * Gulp Settings: select this option to open the [Gulp Settings dialog](run-debug-configuration-gulp-js.html) and update the current settings for Gulp and for the Node.js runtime, refer to [Gulp](using-gulp-task-runner.html).    * Sort by: select this option to configure the order in which tasks are shown in trees. Click ![Settings](https://resources.jetbrains.com.cn/help/img/idea/2026.2/app.general.gear.svg) on the toolbar, choose Sort by from the menu, and then choose Name. By default, a tree shows the tasks in the order in which they are defined in `Gulpfile.js` (option Definition order).    |
|  ![Hide](https://resources.jetbrains.com.cn/help/img/idea/2026.2/app.general.hideToolWindow.svg)  |  Hide  |  Click this button to hide the tool window. To have it displayed again, select `View \| Tool Windows \| Gulp` in the main menu. The tool window appears again showing all the previously built trees of tasks.  |

## Context menu of a tree

|  Gulp Settings  |  Choose this menu item to open the Gulp Settings dialog and view or edit the Node.js configuration  |
|  Jump to Source  |  Choose this menu item to open the `Gulpfile.js` file for which the current tree is built.  |
|  Reload tasks  |  Choose this menu item to have the tree of tasks under the selected node re-built.  |
|  Copy Path  |  Choose this menu item to save the path to the `Gulpfile.js` file according to which the current tree was built to the clipboard.  |
|  Remove Gulpfile.js  |  Choose this menu item to remove the tree of tasks under the selected node.  |

## Context menu of a task

|  Run <task name>  |  Choose this menu item to run the selected task.  |
|  Debug <task name>  |  Choose this menu item to debug the selected task.  |
|  Edit <task name> settings  |  Choose this menu item to open the Run/Debug Configuration dialog and edit the predefined settings for the selected task.  |
|  Jump to Source  |  Choose this menu item to open the `Gulpfile.js` file for which the current tree is built and navigate to the definition of the selected task.  |

## See also

### Procedures

[Gulp](using-gulp-task-runner.html)

### Reference

[Run/Debug Configuration: Gulp.js](run-debug-configuration-gulp-js.html)

