DEV Community

Tuner9696
Tuner9696

Posted on

A Practical Windows Terminal Setup with Git Bash and Automatic Pane Layout

When I start my workday, I prefer my development environment to be ready immediately πŸ™‚
Switching shells or manually arranging panes is a small but repeated cost.

This article describes a simple and consistent setup using Windows Terminal and Git Bash, configured to open five panes automatically on startup.


Why I Use Git Bash as the Default Shell πŸ€”

Windows Terminal supports multiple shells, including PowerShell and WSL.
While these tools are powerful, I prefer Git Bash for most daily development tasks.

My reasons are straightforward:

  • Familiar Linux-style commands
  • Minimal configuration
  • No context switching between environments

For consistency, I decided to use Git Bash as the default shell across all panes.


Step 1: Install Required Applications πŸ› οΈ

First, install the necessary tools.

Windows Terminal

winget install Microsoft.WindowsTerminal
Enter fullscreen mode Exit fullscreen mode

Git Bash (Git for Windows)

winget install Git.Git
Enter fullscreen mode Exit fullscreen mode

After installing Git, restarting the terminal once helps avoid potential PATH-related issues πŸ‘


Step 2: Register Git Bash as a Windows Terminal Profile βš™οΈ

Next, Git Bash is added as a custom profile.

  1. Open Windows Terminal
  2. Press Ctrl + , to open Settings
  3. Select Add a new profile β†’ Empty profile
  4. Configure the profile as follows:
Name: Git Bash
Command line:
C:\Program Files\Git\bin\bash.exe --login -i
Enter fullscreen mode Exit fullscreen mode
  1. Open Startup
  2. Set Default profile to Git Bash
  3. Save the settings

This ensures that Windows Terminal always launches Git Bash by default.


Step 3: Create a Shortcut for a Five-Pane Layout 🧩

To reduce manual setup, I use a desktop shortcut that opens Windows Terminal with a predefined pane layout.

This shortcut:

  • Launches Windows Terminal
  • Uses Git Bash in all panes
  • Splits the window into five panes
  • Starts in a specified directory

Replace your-username with your Windows user name.

wt -p "Git Bash" -d "C:\Users\your-username\Desktop" ; \
split-pane -V -p "Git Bash" -d "C:\Users\your-username\Desktop" ; \
move-focus Left ; \
split-pane -H -p "Git Bash" -d "C:\Users\your-username\Desktop" ; \
move-focus Right ; \
split-pane -H -p "Git Bash" -d "C:\Users\your-username\Desktop" ; \
split-pane -H -p "Git Bash" -d "C:\Users\your-username\Desktop"
Enter fullscreen mode Exit fullscreen mode

Name the shortcut something simple, such as Dev Terminal.


Step 4: Enable Automatic Launch on Windows Startup πŸš€

To ensure the environment is always ready, I register the shortcut in the Windows startup folder.

  1. Press Win + R
  2. Enter shell:startup
  3. Paste the shortcut into the folder

With this configuration, the terminal opens automatically when Windows starts.

Top comments (0)