Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.os.linux.misc > #4089
| From | Szyk <szyk100@o2.pl> |
|---|---|
| Newsgroups | alt.comp.linux, comp.os.linux.misc |
| Subject | sed - please help me |
| Date | 2012-02-03 21:56 +0100 |
| Organization | Netia S.A. |
| Message-ID | <jghhms$duc$1@mx1.internetia.pl> (permalink) |
Cross-posted to 2 groups.
Hi I want extract class names from C++ file sources. So I think sed will perfeclty fit my needs. I wrote two almos identical sed commands, but second completly does not work. Please tell me why? First command: $ sed -n '/^class[[:space:]]\+[[:alpha:]]\+.*$/p' ./User.h class RoomState class UserBase class UserData : public UserBase class User : public UserBase And similiar but with simple transformation: $ sed -n 's/^class[[:space:]]\+\([[:alpha:]]\+\).*$/\1\n/' ./User.h [no output] thank you Szyk
Back to comp.os.linux.misc | Previous | Next — Next in thread | Find similar | Unroll thread
sed - please help me Szyk <szyk100@o2.pl> - 2012-02-03 21:56 +0100
Re: sed - please help me Baho Utot <baho-utot@invlaid.com> - 2012-02-03 17:59 -0500
Re: sed - please help me Alexandre Aguiar <gnuhealth@asaguiar.net> - 2012-02-03 22:42 -0200
Re: sed - please help me Szyk <szyk100@o2.pl> - 2012-02-04 15:18 +0100
Re: sed - please help me Alexandre Aguiar <gnuhealth@asaguiar.net> - 2012-02-05 11:07 -0200
csiph-web