Quantcast

[RFE] --reference option for setfattr

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[RFE] --reference option for setfattr

Ales Zelinka
Hello,

currently when I want to copy all extended attributes from one file to
another, I have to use ugly command like this:

getfattr --dump -m '-' /etc/samba/smb.conf |sed 's;file:
etc/samba/smb.conf;file: /tmp/smb.conf;'| setfattr --restore=-

Would you please implement --reference=some_file option that will read
all extended attributes set on some_file and set them on pathname?

The previous use case would then look like this:

setfattr --reference=/etc/samba/smb.conf /tmp/smb.conf

Other commands from file-attributes-manipulation familly already have
parameter like this (chmod, chown, chcon,...)

Thanks

Ales Zelinka


Loading...