Grav Support Plugin
This plugin helps to increase the development speed for Grav-based projects within for IntelliJ Community / Ultimate Edition and PhpStorm
Grav is a flat-file CMS and it's open source.
- PhpStorm 2018.3.*, 2019.1.1, 2019.3.3
- IntelliJ IDEA Ultimate 2018.2.4, 2019.1.1, 2019.3.3
- IntelliJ IDEA Community 2017.2.*
The plugin is also available in the JetBrains Plugins Repository.
Supported Versions of Grav and PHP
The latest plugin supports the following Grav versions: 1.6.*, ...
Furthermore, I only provide support for PHP 7.*. If you have a lower version than the plugin may not work correctly.
To work with Grav, the PHP extensions
openssl must be enabled.
JetBrains Plugins Repository
Open the settings menu CTRL+ALT+S or File | Settings and then go to Plugins. Click on the button Browse repositories and search for Grav Support. This way you will get notified if a new update is available!
Download the latest plugin and install it via the settings menu: CTRL+ALT+S or File | Settings and then under the category Plugins, click on the configuration wheel in the top bar and select Install Plugin from Disk....
The Twig Support plugin must be also installed when using IntelliJ Ultimate/Community. This also applies for YAML, PHP and CSS support.
If you create a new Grav project / module you will have all features enabled by default. Therefore, a "New Project" wizard for Grav-based projects is provided by the plugin within Phpstorm.
If you're using PhpStorm and opening a previously created project you may have to enable the plugin for the current project. The plugin tries to detect a Grav project automatically and notifies the user accordingly. Otherwise open the Settings menu (CTRL+ALT+S) and go to Languages & Frameworks -> Grav and enable the plugin for the current project.
(see the changelog for a complete list)
- Create a Grav module (Community / Ultimate) or project (PhpStorm) using IntelliJ Wizard
- Ability to download and install Grav from the Module Wizard
- Special language file editor
- Tool window to configure basic config files of Grav
- Navigate to the related template file from a page content markdown file
- Create specific configuration files for a theme in the theme directory
- Recognition of basic Grav configuration files
- Create new theme (Tools menu or context menu on a module)
- Create SDK for Grav
- Twig intentions
The plugin requires IDEA Community / Ultimate Edition 2017.2.* or PhpStorm 2017.2.1. With Ultimate you have also PHP support.
You need a valid PHP installation on your machine.
Php should be found in the
The plugin uses the scripts in the
bin directory of Grav to offer
the functionality Grav supports via those scripts.
Help and Common Bugs
Supported Grav versions
The supported Grav versions are fetched from the GitHub repository of getgrav automatically. They can be selected directly in the project wizard of IntelliJ.
Furthermore, it is possible to use any other Grav installation by manually downloading them and specifying the path in the wizard.
"Grav plugin 'devtools' is not installed"
If you get this error message: "Grav plugin 'devtools' is not installed" after using the plugin and creating a new theme then you should follow these steps:
Move into your newly created Grav project and type into the console:
$ bin/gpm install devtools
Support the plugin if you like it:
- Tell your friends who are using IntelliJ and Grav about this plugin
- Star it at GitHub
- Star it on the JetBrains Plugins Repository
- Report bugs or feature requests or even fix / implement them
- Reach out to me directly at firstname.lastname@example.org
Implement Features or Fix Bugs
Fork this repository to your own GitHub account and then clone it to your local device. Open a pull request with improvements.
Please read the IntelliJ Platform SDK Documentation on how to set up the development environment.
If you find any issues, please report them directly by using the GitHub issue tracker instead of review comments.
Automatic Bug Reports
The plugin offers the possibiliy to report errors directly within the IDE. If an exception occurs, the user can submit the error by clicking a link and providing additional details. After, the bug report will be added automatically to this repository as an issue: https://github.com/Grav-IntelliJ-Plugin/GravSupport-Plugin-BugTracker/issues.
Nevertheless, feature requests, enhancements and bugs not captured by the plugin can still be filed in this repository (https://github.com/PioBeat/GravSupport/issues).