Dave Bass wrote:
> Presumably the file names are being corrupted at some point. It could be 
> in Ruby, or it could be in Windows. My approach would be to put some 
> print statements in to find out where exactly the problem lies.

actually, if i use

files.each { |file|
  p i, file
  file.each_byte {|c| print c, ' ' }
  [...]

then the filename print out as a lot of 63, which is the ASCII of "?", 
so it looks like the filenames already come back bad...

using $KCODE = "u"; or   ruby -Ku move.rb doesn't seem to help.  They 
seem to be only indicating the file containing the code uses UTF-8 
encoding.



-- 
Posted via http://www.ruby-forum.com/.