The UNIX and Linux Forums
>
Top Forums
>
Shell Programming and Scripting
delete lines between patterns
.
User Name
Remember Me?
Password
google unix.com
Forums
Register
Forum Rules
Links
Albums
FAQ
Members List
Calendar
Search
Today's Posts
Mark Forums Read
Thread
:
delete lines between patterns
View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
#
5
(
permalink
)
05-28-2009
shamushamu
Registered User
Join Date: Sep 2008
Posts: 21
Sorry about that, vgersh99. I'm new to Linux and this forum.
I just found and fix my codes. I changed the pattern to:
Code:
awk '/^[1-9]/{ before-=1;after=2; next }
But I'm still very interested to see if anyone has a better solution than this. I believe this can be done using a few lines.
shamushamu
View Public Profile
Find all posts by shamushamu
Find shamushamu's past nominations received
Find shamushamu's present nominations given