I am converting two text files to an array using readlines
f1 = File.open('current_routes.txt')
f2 = File.open('production_routes.txt')
file1lines = f1.readlines
file2lines = f2.readlines
puts file1lines.inspect
puts ''
puts file2lines.inspect
The two files are an exact copy and paste of each other:
["DEPRECATION WARNING: Sprockets method `register_engine` is deprecated.\n", "Please register a mime type using `register_mime_type` then\n"]
["DEPRECATION WARNING: Sprockets method `register_engine` is deprecated.\r\n", "Please register a mime type using `register_mime_type` then\r\n"]
Why does inspect on the first file add \n and inspection of the second file add \r\n?
I am trying to compare the files for differences and this is giving me trouble
Or maybe I should stick with golf.