Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Open another IntelliJ IDEA project from command line

Tags:

So I am creating a program that can automatically open an IntelliJ IDEA Project (.ipr) from the command line. I have it successfully opening with the following command:

Path\To\idea.exe Path\To\ProjectFile\project.ipr 

However, if a project is already currently open in IntelliJ IDEA, it will not open a new one in a new window. IT is possible to open a new project in a new window by doing File -> Open... But is there a way to do this via a commandprompt argument (maybe some sort of flag or something?)?

like image 614
R.J. Avatar asked Feb 21 '13 18:02

R.J.


People also ask

How do I switch between IntelliJ projects?

Switch between projects If you have several opened projects at the same time, you can switch between them using the following options: Switch to the next project window: Ctrl+Alt+] (Window | Next Project Window) Switch to the previous project window: Ctrl+Alt+[ (Window | Previous Project Window)

Can we open multiple projects in IntelliJ?

Most IDEs provide workspaces that contain multiple projects and thus enable you to work on mutliple projects in one instance of the IDE. IntelliJ, which has becom the defacto standard for Java Devs, does not support workspaces.


2 Answers

You can create command-line launcher in IntelliJ IDEA: Tools->Create command line Launcher

This answer can be helpful: https://stackoverflow.com/a/41592203/4191683

like image 169
Piotr Korlaga Avatar answered Sep 24 '22 13:09

Piotr Korlaga


If anyone else runs into this issue. Just recreate the shell command in Tools -> Create command line Launcher. A fresh launcher worked after update.

like image 45
Gabe M Avatar answered Sep 21 '22 13:09

Gabe M