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 -->
  #4 (permalink)  
Old 10-17-2006
tipsy tipsy is offline
Registered User
  
 

Join Date: Jun 2006
Posts: 35
Here it is:

files=`ls -1 $dir`

for file in `echo $files`
do
echo $dir/$file
done

-- I wanted to list the files in a folder and use that list for further processing. Instead of taking the filenames into a file, I take it into a variable. The filenames here are tab delimited.

Regards,
T.