Git Bash Terminal Redraw Issue Fix [Solved]

Symptoms & Diagnosis

Git Bash terminal flickering or redraw issues usually manifest during active command-line sessions. Users often report screen tearing, text overlapping, or artifacts remaining on the screen after running commands like git log or vim.

You can diagnose the issue by observing how the terminal handles window resizing. If the text fails to wrap or if the cursor becomes misaligned with the actual input line, your terminal is experiencing a rendering conflict between the MinTTY emulator and the Windows console host.

Common symptoms include the “phantom text” effect where old command output stays visible in the background and a noticeable delay when scrolling through long directories or commit histories.

Git Bash terminal with screen flickering and redraw errors on a monitor.

Troubleshooting Guide

The most effective way to resolve redrawing issues is to force a terminal reset or adjust the terminal emulation type. Use the following table to identify the best approach based on your specific symptom:

Symptom Root Cause Recommended Fix
Screen Flickering Hardware Acceleration Disable GPU Rendering in MinTTY
Artifacting/Phantom Text Buffer Overflow Run ‘reset’ command
Misaligned Cursor Wrong TERM variable Set TERM to xterm-256color

To perform a soft reset of your terminal state without closing the window, execute the following command in your Git Bash prompt:

reset

If the issue persists, you should verify your environment variables. Ensure your terminal is identifying itself correctly to the shell by adding this line to your .bashrc file:

export TERM=xterm-256color

Adjusting MinTTY Options

Right-click the Git Bash title bar and select “Options”. Navigate to “Terminal” and ensure “Type of terminal” is set to xterm-256color. Under the “Window” section, try toggling the “UI language” or “Character set” if you see strange symbols instead of lines.

Prevention

To prevent future redraw issues, keep your Git for Windows installation updated. Newer versions include patches for the underlying MinTTY emulator that specifically address Windows 10 and 11 console compatibility.

Consider switching to the Windows Terminal app. You can host a Git Bash profile inside Windows Terminal, which utilizes a more modern rendering engine (DirectWrite) that is significantly less prone to flickering than the legacy standalone Git Bash window.

Finally, avoid using overly complex custom prompts (PS1) with non-standard Unicode characters if you notice frequent cursor drift, as these often confuse the terminal’s width calculation logic.