You are not logged in.

#1 2018-06-18 06:48:50

zw963
Member
Registered: 2018-06-18
Posts: 213

Don't show colored output content after redirect in konsole.(SOLVED)

I have some git log output, it colored correct like following

13783151214904.png

But, when I redirect output to nl,  color is gone, like following

32618942827994.png


When i use other distro, nl can correct keep colored output, e.g. Slackware, OpenSUSE, Ubuntu.

Thanks

Last edited by zw963 (2018-09-23 19:37:19)

Offline

#2 2018-06-18 09:50:09

Mr.Elendig
#archlinux@freenode channel op
From: The intertubes
Registered: 2004-11-07
Posts: 4,097

Re: Don't show colored output content after redirect in konsole.(SOLVED)

git log --color=always ?

Edit: you can make it the default in your git config.

Last edited by Mr.Elendig (2018-06-18 10:22:21)


Evil #archlinux@libera.chat channel op and general support dude.
. files on github, Screenshots, Random pics and the rest

Offline

#3 2018-06-18 15:19:32

eschwartz
Fellow
Registered: 2014-08-08
Posts: 4,097

Re: Don't show colored output content after redirect in konsole.(SOLVED)

If you always use nl, you could insert it into core.pager


Managing AUR repos The Right Way -- aurpublish (now a standalone tool)

Offline

#4 2018-06-25 16:13:03

zw963
Member
Registered: 2018-06-18
Posts: 213

Re: Don't show colored output content after redirect in konsole.(SOLVED)

Mr.Elendig wrote:

git log --color=always ?

Edit: you can make it the default in your git config.

Thanks, this working for me.

Offline

Board footer

Powered by FluxBB