tar: --owner and --group names and numbers
The --owner and --group options now accept operands of the form NAME:NUM, so that you can specify both symbolic name and numeric ID for owner and group. Also, in these options, NAME no longer needs to be present in the current host's user and group databases; this implements Debian enhancement request 136231 <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=136231> reported by Mark W. Eichin, communicated by Thayne Harbaugh to bug-tar in <http://lists.gnu.org/archive/html/bug-tar/2011-08/msg00001.html>. * NEWS, doc/tar.texi (Option Summary, override): Document enhancement. * src/common.h (group_name_option, owner_name_option): New decls. * src/create.c (start_header): Don't assume owner and group names are in current host database. * src/tar.c (parse_owner_group): New function, for parsing NAME:NUM. (parse_opt): Use it. (decode_options): Initialize owner_name_option, group_name_option. * tests/owner.at: New file, to test this enhancement. * tests/Makefile.am (TESTSUITE_AT): Add it. * tests/testsuite.at: Include it.
This commit is contained in:
@@ -222,6 +222,7 @@ m4_include([multiv07.at])
|
||||
m4_include([multiv08.at])
|
||||
|
||||
m4_include([old.at])
|
||||
m4_include([owner.at])
|
||||
|
||||
m4_include([recurse.at])
|
||||
|
||||
|
||||
Reference in New Issue
Block a user