Working with IntelliJ IDEA
Last modified by Vincent Massol on 2019/09/20 17:17
Contents
Install IntelliJ IDEA
- Download and Install IntelliJ IDEA
- Setup IntelliJ IDEA so that it respects the code style of the XWiki project
Get the source for XWiki
The source for XWiki is available via a source repository.
Create an IntelliJ IDEA project
IntelliJ IDEA supports Maven out of the box so all you need to do is open the pom.xml file for the project you wish to build/debug.
Building sources
In IDEA's menu, click on Build > Make Project.
Troubleshooting
Plenty of errors in imports
This mean IDEA wasn't able to resolve the dependencies of the module you're in. One typical cause is because IDEA failed to read the XWiki Maven POMs. And one reason for that is that XWiki requires a recent version of Maven, while IDEA may embed an oldish version. This is causing problems such as the one in the following screenshot, preventing IDEA from resolving dependencies:
You also need to make sure that you've configured Maven properly with a good settings.xml file.