From: Peter Bailey Date: 2013-05-09T20:33:33+09:00 Subject: Re: Problem with FileUtils move command. Matthew Kerwin wrote in post #1108321: > On May 9, 2013 2:51 AM, "Daniel Stephens" > wrote: >> >> Maybe it's not in [0]?? Drop that loop at the top of your script as well > and lets see what we get. >> >> ARGV.each do |arg| >> puts "Argument: #{arg}" >> end > > Pro tip: When debugging vars that may be nil, use #p instead of #puts. > You > get much more useful output, e.g.: > > p ARGV[0] #=> nil > p ARGV #=> [] > > Sent from my phone, so excuse the typos. I get this: F:\workflows\graphics\Asura-Non\RCSCR\in>e:\live\scripts\ruby\asura-non\rcscr\rcscr_pdf_single.rb hlst205ar-15.pdf nil [] ARGV == C:/Ruby200/lib/ruby/2.0.0/fileutils.rb:1631:in `path': no implicit conversion of nil into String (TypeError) from C:/Ruby200/lib/ruby/2.0.0/fileutils.rb:1631:in `fu_each_src_dest0' from C:/Ruby200/lib/ruby/2.0.0/fileutils.rb:1618:in `fu_each_src_dest' from C:/Ruby200/lib/ruby/2.0.0/fileutils.rb:580:in `mv' from e:/live/scripts/ruby/asura-non/rcscr/RCSCR_PDF_single.rb:33:in `
' -- Posted via http://www.ruby-forum.com/.