2016-06-20 23:47:41 +01:00
|
|
|
# xattr
|
|
|
|
|
2016-06-20 23:50:33 +01:00
|
|
|
> Utility to work with extended filesystem attributes.
|
2024-01-31 10:20:27 +00:00
|
|
|
> More information: <https://keith.github.io/xcode-man-pages/xattr.1.html>.
|
2016-06-20 23:47:41 +01:00
|
|
|
|
|
|
|
- List key:value extended attributes for a given file:
|
|
|
|
|
|
|
|
`xattr -l {{file}}`
|
|
|
|
|
|
|
|
- Write an attribute for a given file:
|
|
|
|
|
|
|
|
`xattr -w {{attribute_key}} {{attribute_value}} {{file}}`
|
|
|
|
|
|
|
|
- Delete an attribute from a given file:
|
|
|
|
|
2017-12-13 03:53:53 +00:00
|
|
|
`xattr -d {{com.apple.quarantine}} {{file}}`
|
2016-06-20 23:47:41 +01:00
|
|
|
|
|
|
|
- Delete all extended attributes from a given file:
|
|
|
|
|
|
|
|
`xattr -c {{file}}`
|
|
|
|
|
|
|
|
- Recursively delete an attribute in a given directory:
|
|
|
|
|
|
|
|
`xattr -rd {{attribute_key}} {{directory}}`
|