require 'net/http'
def exec_ftp
log_ftp = File.open(File.dirname(__FILE__)+"/../log/ftp/#{time_to_simple_str}-receive.log", 'a+')
source_file="gift_#{Time.now.strftime('%Y%m%d')}.txt"
log_ftp.puts "start exec ftp get file #{Time.now.strftime('%Y%m%d')}"
log_ftp.puts "file name is #{source_file}"
ftp=Net::FTP.open('****') do |ftp|
ftp.login('***', '***')
ftp.chdir('incoming/')
** ftp.getbinaryfile(?,?)**
end
puts "ftp transer end"
sync_data
log_ftp.close
end`
上面的 source_file 的变量名怎么传递