I like using Git Bash, especially when I’m working with the Azure CLI. To make switching easier, I added Git Bash to Windows Terminal so I can move between it and PowerShell without hassle.

To add Git Bash as a profile in Windows Terminal:

  1. Find the installation directory of Git for Windows. For my installation, it is under
    C:\Program Files\Git

  2. Within this directory, navigate to usr\bin to find bash.exe. The full path is something like C:\Program Files\Git\usr\bin\bash.exe

  3. Launch Windows Terminal and go to Settings.

  4. Click Add a new profile.

  5. Configure a new Profile. In my case, I used the below information:

    Name                            : Git Bash  
    Command Line                    : C:\Program Files\Git\usr\bin\bash.exe  
    Icon (Optional)                 : C:\Program Files\Git\mingw64\share\git\git-for-windows.ico  
    Starting Directory (Optional)   : %USERPROFILE%  
    
  6. Click Save. Then close and relaunch the Windows Terminal.

  7. Now you can open a new tab and run a Git Bash terminal.

    gitbash

Adding Git Bash to Windows Terminal makes working across shells simple. Hope that helps.