Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How start intellij idea terminal with different folder?

Command line terminal stars with some folder like projectRoot/one subproject every time instead of projectRoot. Personally I did not change any settings for that.

Does any body know how setup Idea to start terminal with project root instead of typing cd .. every time?

like image 683
Cherry Avatar asked Aug 14 '14 03:08

Cherry


People also ask

How do I change directory in IntelliJ?

Change the location of IDE directories From the main menu, select Help | Edit Custom Properties. Specify paths with forward slashes /, including Windows paths (for example, C:/idea/system). After you restart IntelliJ IDEA, it will use the new location of the corresponding directory.

How do I open another terminal in IntelliJ?

Opening Multiple Terminal Sessions For this, we can split our terminal window by right-clicking on it and selecting one of the options so that we can run two in the same window. For example, you can open up the mongo shell in this split window and can see if the commands have any impact on the running server.


1 Answers

I don't quite understand how the Terminal Plugin in IDEA figures out where to start the terminal (though it is always a subfolder of the project root), but there is a sort of workaround for this: always start the terminal in the root of your repo.

In "Settings -> Terminal", add the /K option followed by a command to navigate to the desired path, e.g.:

  • Shell path: cmd /K "cd D:\usr\local\repo"
like image 61
Antonio Simoes Avatar answered Sep 29 '22 07:09

Antonio Simoes