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 -->
  #6 (permalink)  
Old 10-13-2008
otheus's Avatar
otheus otheus is offline Forum Staff  
Moderator ala Mode
  
 

Join Date: Feb 2007
Location: Innsbruck, Austria
Posts: 1,889
Quote:
Originally Posted by gugs View Post
[SIZE=2]
Code:
'
+ echo 'sed -n '\''/TEST01.*\.mqsc$/{p;q}'\'''
There's a qouting problem somewhere. These escaped-double-quotes shouldn't be there at all.
[quote][code]
Why can't you just do:

Code:
ls -1t $dir >temp.txt
sed -n "/$NEXT/{p;q}" temp.txt