RBT RBT -3 years ago 361
Bash Question

How to use multiple types of command shell in Visual Studio code integrated terminal

I looked at this link which talks about changing the default command shell in the integrated terminal of Visual Studio Code. I was successfully able to change it to Git Bash using below setting in

file. You can open
file by pressing
Ctrl + ,
key combination or
File -> Preferences -> Settings

"terminal.integrated.shell.windows": "C:\\Program Files\\Git\\bin\\bash.exe"


There is a
sign in the integrated terminal with the help of which you can have multiple terminals running parallely as shown in the screenshot below:

enter image description here

So what I want to achieve is to load Git Bash shell in terminal # 1 and Windows Powershell in terminal # 2 and so on. What is the relevant configuration to achieve the same?

Answer Source

In recent version (1.15.0) you can

  • change the settings, then run the terminal, you've set
  • then change the settings again and run the another type of terminal by pressing the + sign
  • and so on...

You can put this in your settings file, and uncomment which one you need.

// 64-bit cmd if available, otherwise 32-bit
//"terminal.integrated.shell.windows": "C:\\Windows\\sysnative\\cmd.exe"
// 64-bit PowerShell if available, otherwise 32-bit
//"terminal.integrated.shell.windows": "C:\\Windows\\sysnative\\WindowsPowerShell\\v1.0\\powershell.exe"
// Git Bash
"terminal.integrated.shell.windows": "C:\\Program Files\\Git\\bin\\bash.exe"
// Bash on Ubuntu (on Windows)
//"terminal.integrated.shell.windows": "C:\\Windows\\sysnative\\bash.exe"
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download