You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
# read file and write to archive
|
|
File.open("archive.log", "a") do |saved|
|
|
File.foreach("mylogfile.log") do |sending|
|
|
puts("data = #{sending}")
|
|
# Make sure we keep a backup
|
|
saved.puts(sending) # removed superfluous string interpolation
|
|
end
|
|
end
|