my $red = "\033[31m"; # is there a semicolon missing at the end of the ANSI escape? if( $ENV{NO_COLOR} || ! -t) { $red = ""; }