Enabled ERUNT registry backup in d7 diagnostics

This commit is contained in:
2Shirt 2018-10-07 19:05:39 -06:00
parent 877a9c6634
commit 8189d412eb
2 changed files with 6 additions and 4 deletions

View file

@ -82,7 +82,7 @@ def backup_power_plans():
cmd = ['powercfg', '-export', out, guid]
run_program(cmd, check=False)
def backup_registry():
def backup_registry(overwrite=False):
"""Backup registry including user hives."""
extract_item('erunt', silent=True)
cmd = [
@ -92,6 +92,8 @@ def backup_registry():
'curuser',
'otherusers',
'/noprogresswindow']
if overwrite:
cmd.append('/noconfirmdelete')
run_program(cmd)
def get_folder_size(path):

View file

@ -162,9 +162,9 @@ if __name__ == '__main__':
function=backup_power_plans, cs='Done')
try_and_print(message='Product Keys...',
function=run_produkey, cs='Done', other_results=other_results)
if not D7_MODE:
try_and_print(message='Registry...',
function=backup_registry, cs='Done', other_results=other_results)
try_and_print(message='Registry...',
function=backup_registry, cs='Done', other_results=other_results,
overwrite=True)
# Summary
if not D7_MODE: