Skip to content

Instantly share code, notes, and snippets.

@kartikshah
Created February 17, 2012 22:44
Show Gist options
  • Save kartikshah/1855924 to your computer and use it in GitHub Desktop.
Save kartikshah/1855924 to your computer and use it in GitHub Desktop.
Color output of linux tail command
$tail -100f /var/log/applications/application.log | awk '
/INFO/ {print "\033[32m" $0 "\033[39m"}
/Exception/ {print "\033[31m" $0 "\033[39m"}
'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment