Skip to content

fix ansi code srg0 to include \033[m

boxofrox requested to merge boxofrox/procps:fix/ansi-code-srg0 into master

This change fixes color resets that are otherwise ignored for git log --graph --decorate --pretty=oneline --abbrev-commit --all within a tmux -2 session.

I wrote this patch months ago and vaguely remember seeing a spec that specified SRG0 as either \033[0m or \033[m, but I can't recall where, and two references indicate otherwise [1] [2]. So I claim this change supports a de facto standard. Otherwise I have to convince everyone else to stop using \033[m.

[1] http://www.vt100.net/docs/vt220-rm/chapter4.html#S4.9.1
[2] http://www.vt100.net/docs/vt100-ug/chapter3.html#SGR

Merge request reports