IntelliJ IDEA Setup Guide#

Required Plugins#

Go to “Settings/Preferences” → “Plugins” and select the “Marketplace” tab. Search for the following plugins, install them, and restart the IDE if prompted:

You will also need to install the google-java-format plugin. However, a specific version of this plugin is required. Download google-java-format v1.7.0.6 and install it as follows. Make sure to NEVER update this plugin.

  1. Go to “Settings/Preferences” → “Plugins”.

  2. Click the gear icon and select “Install Plugin from Disk”.

  3. Navigate to the downloaded ZIP file and select it.

Formatter For Java#

Kyuubi uses Spotless together with google-java-format to format the Java code.

It is recommended to automatically format your code by applying the following settings:

  1. Go to “Settings/Preferences” → “Other Settings” → “google-java-format Settings”.

  2. Tick the checkbox to enable the plugin.

  3. Change the code style to “Default Google Java style”.

  4. Go to “Settings/Preferences” → “Tools” → “Actions on Save”.

  5. Select “Reformat code”.

If you use the IDEA version is 2021.1 and below, please replace the above steps 4 and 5 by using the Save Actions plugin.

Formatter For Scala#

Enable Scalafmt as follows:

  1. Go to “Settings/Preferences” → “Editor” → “Code Style” → “Scala”

  2. Set “Formatter” to “Scalafmt”

  3. Enable “Reformat on file save”

Checkstyle For Scala#

Enable Scalastyle as follows:

  1. Go to “Settings/Preferences” → “Editor” → “Inspections”.

  2. Search for “Scala style inspection” and enable it.