don't preserve any attributes by default
This commit is contained in:
parent
bdc1df9b6f
commit
45905e8f35
5
gcp
5
gcp
|
@ -556,7 +556,7 @@ class GCP():
|
|||
parser.add_argument("-f", "--force", action="store_true", default=False,
|
||||
help=_("force overwriting of existing files"))
|
||||
|
||||
parser.add_argument("--preserve", action="store", default='mode,ownership,timestamps',
|
||||
parser.add_argument("--preserve", action="store", default='',
|
||||
help=_("preserve the specified attributes"))
|
||||
|
||||
parser.add_argument("-L", "--dereference", action="store_true", default=False,
|
||||
|
@ -614,6 +614,7 @@ class GCP():
|
|||
if options.verbose:
|
||||
logging.getLogger().setLevel(logging.DEBUG)
|
||||
|
||||
if len(options.preserve):
|
||||
preserve = set(options.preserve.split(','))
|
||||
if not preserve.issubset(const_PRESERVE):
|
||||
error (_("Invalide --preserve value\nvalid values are:"))
|
||||
|
@ -622,6 +623,8 @@ class GCP():
|
|||
exit(1)
|
||||
else:
|
||||
options.preserve = preserve
|
||||
else:
|
||||
options.preserve=set()
|
||||
|
||||
self.__sourcesSaving(options, args)
|
||||
|
||||
|
|
Loading…
Reference in New Issue