How can I discover if two given files have the same permissions in Ruby?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Compare files’ permission bits.
where
aandbare filenames. Use modulo octal 1000 to remove additional information about the node, i.e. whether it’s a file or directory, whether it has a sticky bit, etc.