Hi Morgan, On 2020-08-14 07:57, Morgan Weetman wrote: > On a side note.. an issue has been raised against my repo regarding > compatibility with BSD-based find in MacOS and Solaris, apparently -xattr > in those distributions doesn't take an argument. > > Could you tell me what the strategy is for handling compatibility between > GNU find and BSD find? Do we try to be compatible? Do we not care and just > do our own thing?
as it's outside of the POSIX specification, we could do whatever we want, but if there is existing behavior in other implementation, then we should try to do the same. If it turns out a feature is so much better, then we can have an extra primitive. I didn't look yet what the others are doing, so just speaking out into the blue, e.g.: * '-xattr' (without argument) to test if a file has extended attributes, * '-xattrname PATTERN' to check with a file has extended attributes matching the given PATTERN, and * '-xattrvalue PATTERN' to check if a file has an extended attribute with a value matching the given pattern. Have a nice day, Berny