The UNIX and Linux Forums  


Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com




View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #3 (permalink)  
Old 11-19-2008
Annihilannic Annihilannic is offline Forum Advisor  
  
 

Join Date: May 2008
Location: Sydney, Australia
Posts: 1,009
Why don't you just change the condition where it stops, i.e. when you hit the "doal" line?


Code:
    while (getline && $1 != "doal") {

If you need to do any processing of the "doal" line contents you can just do it after the while loop.