Below is the tail statement:
tail -4 FDECMP1_$$.log
I need to print the last 4 lines of file FDECMP1_$$.log
in Red.
Below is the tail statement:
tail -4 FDECMP1_$$.log
I need to print the last 4 lines of file FDECMP1_$$.log
in Red.
This command will do the job:
printf "%s" $(printf '\033[0;31m');tail -4 FDECMP1_$$.log
As @galoget showed, you can use the ANSI escape sequences to change the coloring of shell texts.
This answer has more information on this and a nice xterm-256-color-chart to conveniently find the correct color for your purposes.
tail
command, though. – Ned64 Feb 14 '18 at 08:32