freebsd-nq/usr.sbin/extattr
Alan Somers c29930cfd6 Allow setextattr(8) to take attribute values from stdin
Add the -i option to setextattr. This option allow extended attribute data
to be provided via stdin. Add a -qq option to getextattr, which omits the
trailing newline. Together these options can be used to work with extended
attributes whose values are large and/or binary.

usr.sbin/extattr/Makefile:
	Link against libsbuf which is used for processing stdin data.

usr.sbin/extattr/rmextattr.8:
	Document setextattr's -i option, getextattr's -qq option, and remove
	the BUG about setextattr only being useful for strings.

usr.sbin/extattr/rmextattr.c:
	For setextattr operations, buffer attribute data in an sbuf. If -i
	is specified, pull the data from stdin, otherwise from the
	appropriate argurment.

	Update usage text and argument validation code for setextattr's -i
	option.

usr.sbin/extattr/tests/extattr_test.sh
	Add tests for -q and -i.

Reviewed by:	wblock (manpage)
MFC after:	4 weeks
Sponsored by:	Spectra Logic Corp
Differential Revision:	https://reviews.freebsd.org/D6090
2016-05-04 20:20:55 +00:00
..
tests Allow setextattr(8) to take attribute values from stdin 2016-05-04 20:20:55 +00:00
Makefile Allow setextattr(8) to take attribute values from stdin 2016-05-04 20:20:55 +00:00
Makefile.depend Add META_MODE support. 2015-06-13 19:20:56 +00:00
rmextattr.8 Allow setextattr(8) to take attribute values from stdin 2016-05-04 20:20:55 +00:00
rmextattr.c Allow setextattr(8) to take attribute values from stdin 2016-05-04 20:20:55 +00:00