Permalink
Browse files

support $NO_COLOR

  • Loading branch information...
chneukirchen committed Jan 29, 2018
1 parent a5dcf17 commit 8f0ac7c8abb4e0830d6cf72bbbd5f38c44b4266d
Showing with 5 additions and 0 deletions.
  1. +3 −0 lr.1
  2. +2 −0 lr.c
3 lr.1
@@ -115,6 +115,9 @@ Don't enter directories.
.It Fl G
Colorize output to TTY.
Use twice to force colorized output.
If the environment variable
.Ev NO_COLOR
is set, colors are never used.
.It Fl X
Output OSC 8 hyperlinks to TTY.
Use twice to force hyperlinks.
2 lr.c
@@ -2468,6 +2468,8 @@ main(int argc, char *argv[])
if (Xflag == 1)
Xflag = 0;
}
if (getenv("NO_COLOR"))
Gflag = 0;
analyze_format();
if (Uflag) {

0 comments on commit 8f0ac7c

Please sign in to comment.