How to build IDEA community edition from source?



How can I build IDEA community edition from source code so that my custom plugin will be included in the 'plugin' directory of the IDEA distribution. I want to build the IDEA distributions to Windows (.exe), Linux (.zip) and MacOS (.dmg).

Thanks in Regards.


Do you develop the plugin in a separate project or you forked intellij-community repository and added the sources of your plugin to its project configuration?


I have developed the plugin as a different project. 


You can do the following (see javadoc for package):

  1. Create a groovy class extending class, override copyAdditionalFiles method and add an instruction which copies the JARs of your plugin to "$targetDirectory/plugins" directory.
  2. Create a gant script which calls BuildTasks.buildProduct method (look at pycharm_community_build.gant for example).

After that you can either call the gant script directory from IDEA or create an Ant file which calls it (look at our build.xml for example).

However this won't produce .dmg file (it can be built on a separate machine under Mac OS) and the produced *.exe files won't be signed. If you want to overcome these problems, you can pass an instance of implementing these tasks to 'buildProduct' method.


Hi Nikolay,

Thank you for the quick response. I will follow the instructions and post if I encounter an issue.


Hi, I have build IDEA with my plugin, but when building I'm getting below error

Cannot extract win JRE: no ‘jbrex8…_x64.tar.gz’ file found

Where can I download the specified JRE. Further, how do I sign the the generated .exe files for windows?

Apart from that for macOs build .dmg file is not build and gives below error

A Mac OS build agent isn’t configured, dmg artifact won’t be produced.

How can I fix it?

Thanks in advance


Hi Nikolay,

I was able to successfully build the community edition with my custom plugin pre-bundled. Thank you very much for the help. 


Hello sajith,

I was wondering if you could possibly take a look at the problem that I'm having with building IJ IDEA on macOS 10.14.4 .   Since it looks like you've successfully built IJ IDEA on macOS, you might be able to help me.  Here's the link to the post:


Any help or suggestions would be greatly and deeply appreciated



Please sign in to leave a comment.