View Single Post
  #7 (permalink)  
Old 05-09-2008
ripat ripat is offline
Registered User
 

Join Date: Oct 2006
Location: Belgium
Posts: 167
Adapted from ghostdog74's solution

Code:
awk 'BEGIN{RS=""}
!/code : 0/ {
        match ($0, /code : [0-9]+/, a)
        print $0 > "/tmp/file_" gensub(/code : /, "", 1, a[0])
   }'
Reply With Quote