Click to See Complete Forum and Search --> : grep sed awk regex bash my head in


richeee
12-03-2002, 10:14 AM
Hi

I'm new here and came here 'cos I'm stuck and have been for a while. I've been trying to extract words matching a regular expreesion from plain text files. I have the regular expression and I'm happy with that. I'm trying to extract just the word and not the whole line that the regular expression matchess.

The trouble is that the text files are not a all consistant so using $1 $2 etc in sed or awk does not work. Any help appreciated.

Rüpel
12-03-2002, 10:19 AM
expand the regular expression