This feature is supported in the Ultimate edition only.
The following is only valid when Python Plugin is installed and enabled!
In this section:
- Overview
- Configuring manage.py utility
- Running manage.py utility
- Working in the manage.py utility console
- Handling error
Overview
With IntelliJ IDEA, you can run Django manage.py utility from within the IDE. Each task of this utility is executed in the Manage.Py console.
Note that Run manage.py task command is available for both local and remote interpreters.
Configuring manage.py utility
It's important to note that configuration of the manage.py utility is done in the
Django facet page of the Project Structure dialog.
- In the Project Structure dialog, click the module with Python support, and add Django facet.
- Click the Django facet.
- In the Manage.py tasks section, specify the following:
- In the field Manage script, specify the desired
manage.pyscript.
Note that by default IntelliJ IDEA shows themanage.pyscript that resides under the Django project root. If you are not happy with this suggestion, you can choose any othermanage.pyscript by clicking the browse button
. - In the Environment variables field, specify the environment variables to be passed to the script.
By default, this field is empty.
Click the browse button
to open the Environment Variables
dialog box. Use the toolbar buttons to make up the list of variables.If you want to see the system environment variables, click Show link in this dialog box.
- In the field Manage script, specify the desired
Running manage.py utility
- On the main menu, choose
.
The
manage.pyutility starts in its own console. - Type the name of the desired task.
Working in the manage.py utility console
In the manage.py console, one can:
- Scroll through the history of executed commands using the up and down arrow keys.
- Use code completion (⌃Space⌃Space⌃Space^ Space⌥ Slash):

- View quick documentation (F1⌃J⌥Button2 Click^ Q^ Q):

Handling error
IntelliJ IDEA smartly handles errors. When your Django project can't run due to an error, this error displays
in the manage.py console instead of the command line:

