Terminal: GIT Bash has bad flicker

Created on 6 Aug 2020  路  10Comments  路  Source: microsoft/terminal

Environment

Windows build number: Microsoft Windows [Version 10.0.19042.423]
Windows Terminal version (if applicable):  1.1.2021.0  

Any other software?
Git for windows:  v2.28.0

Steps to reproduce

  1. Open a "GIT Bash" terminal session
  2. Press backspace key
  3. BashFlicker

Expected behavior

No nasty flicker

Actual behavior

Nasty flicker

Needs-Attention Needs-Tag-Fix Needs-Triage

Most helpful comment

To fix: nano ~/.inputrc and add the text set bell-style none or set bell-style audible. Press Ctrl + O and Ctrl + X to Save and Exit.

I found this behaviour to be really distracting/disurbing.
The regular Git Bash terminal does exhibit this behaviour, though I can confirm that /c/Program Files/Git/etc/.inputrc does contain set bell-style visible (and that command is not overwritten by anything in .inputrc.

Note that set bell-style audible does not give a ping sound in Git Bash in Windows Terminal, but it does do so in regular Git Bash.

All 10 comments

That looks to me like they're using the "visual bell". Is there anything about bell-style in your ~/.inputrc or /etc/inputrc?

I don't have a ~/.inputrc file and this is GIT Bash on windows so no /etc folder either - but I suspect you are correct as it does correlate with when I might normally hear a "bing".

Git for Windows does install an /etc directory (perhaps mapped to C:\Program Files\Git\etc) and an /etc/inputrc file that includes set bell-style visible.

https://github.com/git-for-windows/build-extra/blob/1227299bc78df003c3b246edbd04a583ac162dc7/git-extra/inputrc#L1-L2

Ok - I will close invalid - can it be disabled in Terminal settings, or do I need to do the local /etc/inputrc?

Closing invalid - Terminal is honouring inputrc settings...

I believe the visual bell uses the flash capability from terminfo. For xterm-256color, the value is \E[?5h$<100/>\E[?5l. AFAIK, Windows Terminal does not provide a way to disable the \E[?5h and \E[?5l control sequences. It might be best to set bell-style audible or set bell-style none in ~/.inputrc so that the setting will survive Git for Windows upgrades.

On the other hand, if DECSCNM is primarily used for visual bell, then it might make sense for Windows Terminal to disable it when animations are disabled according to SystemParametersInfo SPI_GETCLIENTAREAANIMATION.

To fix: nano ~/.inputrc and add the text set bell-style none or set bell-style audible. Press Ctrl + O and Ctrl + X to Save and Exit.

I found this behaviour to be really distracting/disurbing.
The regular Git Bash terminal does exhibit this behaviour, though I can confirm that /c/Program Files/Git/etc/.inputrc does contain set bell-style visible (and that command is not overwritten by anything in .inputrc.

Note that set bell-style audible does not give a ping sound in Git Bash in Windows Terminal, but it does do so in regular Git Bash.

So, that鈥檚 because we only recently got support for visual bells at all. There鈥檚 an escape sequence that inverts the entire screen, and a visual bell is typically implemented by sending it, waiting a bit, and then sending it again.

Git Bash will start doing this inbox in Windows at some point with the next Desktop release, as it is required by standard for us to support it.

set bell-style audible does not give a ping sound in Git Bash in Windows Terminal

Seemingly covered by https://github.com/microsoft/terminal/issues/1608 and https://github.com/microsoft/terminal/issues/4046.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

TayYuanGeng picture TayYuanGeng  路  3Comments

ghvanderweg picture ghvanderweg  路  3Comments

Wid-Mimosa picture Wid-Mimosa  路  3Comments

ghost picture ghost  路  3Comments

mrmlnc picture mrmlnc  路  3Comments