Gcc

From Attie's Wiki
Revision as of 12:13, 9 April 2014 by Attie (Talk | contribs)

Jump to: navigation, search

Highlight the output of gcc

  • warnings will be highlighted yellow
  • errors will be highlighted red
make 2>&1 | sed -re 's/^([^:]+:[0-9]+:[0-9]+: warning: .+)$/\x1B[93m&\x1B[m/g' -e 's/^([^:]+:[0-9]+:[0-9]+: error: .+)$/\x1B[91m&\x1B[m/g'

or... how about a handy alias?

alias make="make 2>&1 | sed -re 's/^([^:]+:[0-9]+:[0-9]+: warning: .+)$/\x1B[93m&\x1B[m/g' -e 's/^([^:]+:[0-9]+:[0-9]+: error: .+)$/\x1B[91m&\x1B[m/g'"
Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox