I have an angular project and a java project and I would like to have a script for cmder that starts both of them in their specific directory in split window view so I can see both their logs.

Like this: enter image description here

I know I can create a task file but I don't know how to configure it to create 2 (or more) terminals in split window view


I would like to elaborate more on my question. I want with 1 script/command/configuration(?) to do the following thing:

  1. Start cmder
  2. on a terminal on top to run ng serve on the specific path that I have my angular application
  3. create another terminal on the bottom and on a different path, I want to run mvn spring-boot:run so that I have a cmder environment that looks like in the image I posted

You may setup your configuration and specify to cmder save all tabs and reload them at startup.

Right-click the green icon on the left of the title bar and choose Settings....

In the Settings dialog, click on Startup and then on Auto save/restore opened tabs, and finally on Save settings. Your tab setup should now be saved on exit and restored on startup.

enter image description here

If you are trying to run several commands in two horizontal panes, perhaps it would be simpler to put everything in a task file, using the "Tasks file" option in the Startup section, like this :

-cur_console:d:"C:\Temp":t:Win1 command1
-cur_console:s1T50V:d:"C:\Temp\":t:Win2 command2

The first task starts in the opened console in folder C:\Temp, is named Win1 and runs command1. The second task starts in the opened console in folder C:\Temp, is named Win2 and runs command2. It is added to the first console - s1T - and takes 50 percent of the height vertically (50V).

  • Thank you for the answer. This is partially what I want to do. I want to open the tabs and run a specific script on each tab/terminal. The save/restore only restores the tabs/terminals to their previous paths but does not run the script that was run last in them. – zpontikas Oct 18 '18 at 6:54
  • You may modify the scripts used for starting the tasks in Startup > Tasks. – harrymc Oct 18 '18 at 6:57
  • Yes ok, so how do I do, what I asked? – zpontikas Oct 18 '18 at 7:03
  • You will see the two tasks you started in the startup task (first one normally) and you can modify the commands. You will need to read the help, though. – harrymc Oct 18 '18 at 7:31
  • 1
    I added a simpler option, which may be more in line with what you ask for. – harrymc Oct 18 '18 at 9:06

Even though @harrymc answered the question I want to add the exact solution to my question here:

  • Create a file with the following 2 lines (for an explanation for each command look at @harrymc's post above)

    -cur_console:d:"C:\Temp\frontend\":t:frontEnd "ng serve"
    -cur_console:s1T50V:d:"C:\Temp\server\":t:server "mvn spring-boot:run"

  • Open cmder -> Settings -> Startup -> Tasks File -> (Win+Alt+P) and select the saved file from the previous step.

  • Save and restart

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.