curl/docs/cmdline-opts/xattr.md
Dan Fandrich 954177b9da tool_xattr: create the user.creator xattr attribute
This indicates that the file was created by curl which can help a user
determine the origin of a file. Like the other attributes, this is only
enabled with the --xattr option.

Closes #15237
2024-10-11 10:13:37 -07:00

24 lines
657 B
Markdown

---
c: Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
SPDX-License-Identifier: curl
Long: xattr
Help: Store metadata in extended file attributes
Category: output
Added: 7.21.3
Multi: boolean
See-also:
- remote-time
- write-out
- verbose
Example:
- --xattr -o storage $URL
---
# `--xattr`
When saving output to a file, tell curl to store file metadata in extended
file attributes. Currently, `curl` is stored in the `creator` attribute,
the URL is stored in the `xdg.origin.url` attribute and, for HTTP, the content
type is stored in the `mime_type` attribute. If the file system does not
support extended attributes, a warning is issued.