Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add workaround for macOS TAR archive xattrs
This commit introduces a workaround for an issue with TAR archives created with libarchive on Darwin/macOS. When encountering a file that has extended attributes, such as the com.apple.provenance attribute, it will add a corresponding AppleDouble file with the prefix "._" in the same directory. Because these files have the same filename otherwise, the buf tool will see these when they correspond to proto files and subsequently fail to parse them as protobuf IDL. Due to the fact that libarchive is used by default with the version of tar that ships with macOS, and the provenance extended attribute is set by macOS under many conditions when SIP is enabled, archives with these files are likely to occur on macOS. This workaround is not needed by .zip as libarchive .zip files do not seem to have the same behavior. Closes #2387.
- Loading branch information