Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon.

Pages: 1-

You may appreciate this

Name: Anonymous 2009-08-28 4:05

Hi /prog/. I'd like to give you this humble sed script that you might appreciate if you are a programmer and you'd like to find out quickly errors and warnings from gcc stderr


#!/bin/sed -rf

s/^([^ :]+):([0-9]+)/\x1b[36m\1\x1b[0m:\x1b[36m\2\x1b[0m:/g
s/([wW][aA][rR][nN][iI][nN][gG])/\x1b[32m\1\x1b[0m/g
s/([eE][rR][rR][oO][rR])/\x1b[31m\1\x1b[0m/g


In order to use it, just redirect gcc's stderr into it, like:

gcc -c mystuff.c 2>&1 | ./the_sed_script

or

make 2>&1 | ./the_sed_script

Name: Anonymous 2009-08-28 4:27

Ever heard of the i flag?

Name: Anonymous 2009-08-28 4:28

Nope. I've read almost all gcc options, but usually I found thing like -fgetthefuckoutofhere ...but I think I'll lurk it out.

Name: Anonymous 2009-08-28 4:30


gcc -i -Wall lulz.c
cc1: error: unrecognized command line option "-i"


...wait, what?

Name: Anonymous 2009-08-28 5:25

>>3-4
Perhaps I should of been clearer. http://www.regular-expressions.info/modifiers.html
It's quite hard to miss.

Name: Anonymous 2009-08-28 5:40

Thanks anon

Name: Anonymous 2009-08-28 5:43

>>5
should of
Back to /lounge/, milkyboy.

Name: Anonymous 2009-08-28 6:29

>>7
IHBT

Name: Anonymous 2009-08-28 8:52

i use xcode and what is this?

Name: Anonymous 2009-08-29 5:11

What.. WHAT THE FUCK HAPPENED TO ALL MY DATA FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF

Name: Anonymous 2011-01-31 21:08

<-- check em dubz

Name: tray 2012-03-14 15:28

you better be

Don't change these.
Name: Email:
Entire Thread Thread List