spaces in file names

Ken Lai (min-ken.lai@yale.edu)
Sat, 27 Feb 1999 16:49:58 -0500 (EST)

Say I want to rename files in a directory to change spaces to "_":

I've tried using a "for" construct in bash and tcsh, but neither could
catch the whole filename. e.g.

# bash:
for FILE in *; do
ls $FILE
done

# tcsh:
foreach FILE ( * )
ls $FILE
end

Neither of the above could list the files, both only gave me bunches of
file-not-found messages for name fragments.

--
# Ken Lai  <min-ken.lai@yale.edu>  also at  ken.lai@WriteMe.com
# http://pantheon.yale.edu/~ml267/     ICQ# 5845632