Hi guys
Thanks a lot for ur help. It was only gonna be a simple script anyway, the "/pat1/,/pat2/ { if ($0 ~ /^[^#].*/) print } " line u suggested vlad is sufficient for me
Cheers
Hi Vlad
Thanks but it returned nothing! The problem is i think that awk goes thru each line applying the pattern clause and THEN after this it looks at teh rest of any pattern amtching directives..?
For example, if a file contains:
This is an example file
foo
list
aaaaaa
bbbbb
#ccccc
ddddd
#eeeee
ffffff
end of list
bar
this is the end of this file
From the above output i would just like to print the uncommented lines between "list" and "end of list". How do i do this...
Hi there
Im fairly new to AWK and was wondering if any1 could help with a dileema i currently have. Id like to be able to print uncommented lines which are between a specified range in a file.
I know how to output the range (/start pattern/, /stop pattern/), i know how to do the match (!~...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.