Guest User

Untitled

a guest
Dec 12th, 2018
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.66 KB | None | 0 0
  1. tail -f $@ | awk '
  2. /INFO/ {
  3. print "\033[32m" $0 "\033[39m"
  4. next
  5. }
  6.  
  7. /WARN/ {
  8. print "\033[33m" $0 "\033[39m"
  9. next
  10. }
  11.  
  12. /ERROR/ {
  13. print "\033[31m" $0 "\033[39m"
  14. next
  15. }
  16. /FATAL/ {
  17. print "\033[31m" $0 "\033[39m"
  18. next
  19. }
  20.  
  21. { print $0 }
  22.  
  23. '
  24.  
  25.  
  26.  
  27.  
  28. # Black 0;30 Dark Gray 1;30
  29. # Blue 0;34 Light Blue 1;34
  30. # Green 0;32 Light Green 1;32
  31. # Cyan 0;36 Light Cyan 1;36
  32. # Red 0;31 Light Red 1;31
  33. # Purple 0;35 Light Purple 1;35
  34. # Brown 0;33 Yellow 1;33
  35. # Light Gray 0;37 White 1;37
Add Comment
Please, Sign In to add comment