Added a "Yes to all" option to User Data Transfer
This commit is contained in:
parent
a7451f86ba
commit
30dcd8758e
1 changed files with 13 additions and 5 deletions
|
|
@ -393,10 +393,18 @@ def scan_source(source_obj, dest_path, rel_path='', interactive=True):
|
|||
if not interactive:
|
||||
print_success('Auto-Selected: {}'.format(item.path))
|
||||
root_items.append('{}'.format(item.path))
|
||||
elif ask('Extract: "{}{}{}" ?'.format(
|
||||
else:
|
||||
prompt = 'Transfer: "{}{}{}" ?'.format(
|
||||
rel_path,
|
||||
os.sep if rel_path else '',
|
||||
item.name)):
|
||||
item.name)
|
||||
choices = ['Yes', 'No', 'All', 'Quit']
|
||||
answer = choice(prompt=prompt, choices=choices)
|
||||
if answer == 'Quit':
|
||||
abort()
|
||||
elif answer == 'All':
|
||||
interactive = False
|
||||
if answer in ['Yes', 'All']:
|
||||
root_items.append('{}'.format(item.path))
|
||||
if REGEX_WINDOWS_OLD.search(item.name):
|
||||
item.name = '{}{}{}'.format(
|
||||
|
|
|
|||
Loading…
Reference in a new issue