I need some help.
when i use the following command, it deletes all lines containing WINNT& v2010 and WINNT& v2010.2
I just want it to delete lines containing WINNT & v2010 only.
perl -n -i.bak -e 'print unless /WINNT/&&/v2010/' *.*
Danish
I need some help.
when i use the following command, it deletes all lines containing WINNT& v2010 and WINNT& v2010.2
I just want it to delete lines containing WINNT & v2010 only.
perl -n -i.bak -e 'print unless /WINNT/&&/v2010/' *.*
Danish
Please give more clue : how look your input file ?
where can the v2010 located in the line ? beginning ? end ? before WINNT or after ?
same questions for the WINNT occurrence.
sed '/.*WINNT.*v2010[^\.].*/d;/.*v2010[^\.].*WINNT.*/d' infile
?
Assuming that there is a space on either side of "v2010":
perl -n -i.bak -e 'print unless /WINNT/ && /\sv2010\s/' *.*