Reputation: 19827
I'm looking for the best way to build an IntelliJ project from command line. This is usually needed while compiling IntelliJ project on a build server.
Upvotes: 25
Views: 15439
Reputation: 10877
I wrote a small bash script that creates the necessary files you'd need to create an IntelliJ web project from the commandline. All I did was create a project using the IntelliJ GUI. After inspecting the files, I set a variable for each time the project directory name was used in the files that were created (.idea/module.xml, and project.iml, etc.) The script creates the same files and .idea/ folder that would have been created if you used the GUI.
Upvotes: -1
Reputation: 5712
You can use TeamCity build server, developed by JetBrains. It has a full-functional free edition and has a dedicated IntelliJ IDEA build runner, which can build artifacts from your IDEA project and run configurations.
TeamCity uses JPS command line runner, which is a part of IntelliJ IDEA community edition source base.
Upvotes: 3
Reputation: 5653
In build menu is Generate Ant Build ... Idea will generate build.xml file. You have to intall Ant add it to PATH and then you can call in project directory command ant.
Upvotes: 3