commandexecutelaunchpanewindows-terminal

Windows terminal: open multiple panes and execute specified command


I recently downloaded the new Windows Terminal. I have created the shortcut for opening the multiple panes(which is working fine). However, I am trying to execute a command for the respective pane.

wt -d <path> -c "cls && php artisan serve" ; 
   split-pane -p "Command Prompt" -H -d <path> -c "npm run watch"

I googled for the solution but no luck.

Is this even possible..?


Solution

  • I got a similar setup working. Im running Windows Terminal version 1.8.1444.0

    My goal was to setup a dotnet core app running in left pane and a react-app running in right pane:

    wt -d "C:\path\to\dotnetcoreapp" -p "Command Promt" cmd /k dotnet watch run ; split-pane -d "C:\path\to\reactapp" cmd /k yarn start
    

    Also tried to start an interactive elixir session: wt -d "C:\dev\elixir" cmd /k IEx which also worked fine...