Add support for ANSI Color Codes in log Outputs
By langenba... on April 26, 2012 11:51 (imported from Google Code)
What steps will reproduce the problem?
1.create a hook on the server side (linux but maybe also works local) which uses colors (for example 'echo "\n$(tput -Tansi setaf 1) Text$(tput -Tansi sgr0)\n"' in a bash script).
2. let the hook execute (I used a post-recive hook)
3. look at the output window of tortoise git.
What is the expected output? What do you see instead?
I expect Text output in read color, but I see some wired chars. At least Tortoisegit should ignore the unprintable chars and only show the pure text.
[1m executed successfully [m
What version of the product are you using? On what operating system?
Windows 7 Version TortoiseGit 1.7.8.0 and TortoiseGit-2012-04-25-993e5a-32bit with utf-8 support
git version 1.7.8.msysgit.0
Please provide any additional information below.
In mysysgit the Output is colored and everything looks fine.
The Output of Tortoise git looks like:
----
git.exe push --progress "origin" test:test
Compressing objects: 100% (3/3)
Writing objects: 100% (3/3)
Writing objects: 100% (3/3), 287 bytes, done.
remote: 1 files changed, 0 insertions(+), 1 deletions(-)
remote: done.
remote: [1m executed successfully [m
To my_user@192.168.170.101:/tmp/test.git
8e15c3e..a6d3bf2 test -> test
Success
-----
Output like it should look like
----
git.exe push --progress "origin" test:test
Compressing objects: 100% (3/3)
Writing objects: 100% (3/3)
Writing objects: 100% (3/3), 287 bytes, done.
remote: 1 files changed, 0 insertions(+), 1 deletions(-)
remote: done.
remote: executed successfully
To my_user@192.168.170.101:/tmp/test.git
8e15c3e..a6d3bf2 test -> test
Success
---