File.identical?(file_1, file_2) รข true or false
Instance Public methods
Returns true
if the named files are identical.
file_1 and file_2 can be an IO object.
open("a", "w") {} p File.identical?("a", "a") #=> true p File.identical?("a", "./a") #=> true File.link("a", "b") p File.identical?("a", "b") #=> true File.symlink("a", "c") p File.identical?("a", "c") #=> true open("d", "w") {} p File.identical?("a", "d") #=> false
Please login to continue.