Is there a way to compare the permission string of two files and output the string if they match?
For ex:
-rw-r--r-- 1 user newuser 0 2009-03-12 16:45 file2
-rw-r--r-- 1 user newuser 0 2009-03-12 16:46 fileone
output:
-rw-r--r--
If they don't match output will be just like
drwxr-xr-x 2 user newuser 4096 2009-02-10 04:18 Templates
-rw-r--r-- 1 user root 6 2009-04-28 00:40 -v
Thank you