Update Emsisoft sections
This commit is contained in:
parent
da74063d8a
commit
38a40c5551
2 changed files with 23 additions and 19 deletions
|
|
@ -64,7 +64,9 @@ BASE_MENUS = {
|
||||||
MenuEntry('BleachBit', 'auto_bleachbit'),
|
MenuEntry('BleachBit', 'auto_bleachbit'),
|
||||||
MenuEntry('HitmanPro', 'auto_hitmanpro'),
|
MenuEntry('HitmanPro', 'auto_hitmanpro'),
|
||||||
MenuEntry('KVRT', 'auto_kvrt'),
|
MenuEntry('KVRT', 'auto_kvrt'),
|
||||||
MenuEntry('EmsisoftCmd', 'auto_emsisoft_cmd'),
|
MenuEntry('EmsisoftCmd', 'auto_emsisoft_cmd_run'),
|
||||||
|
MenuEntry('Reboot', 'auto_reboot'),
|
||||||
|
MenuEntry('EmsisoftCmd (Uninstall)', 'auto_emsisoft_cmd_uninstall'),
|
||||||
MenuEntry('Windows Defender', 'auto_microsoft_defender'),
|
MenuEntry('Windows Defender', 'auto_microsoft_defender'),
|
||||||
MenuEntry('Remove Custom Power Plan', 'auto_remove_power_plan'),
|
MenuEntry('Remove Custom Power Plan', 'auto_remove_power_plan'),
|
||||||
MenuEntry('Reboot', 'auto_reboot'),
|
MenuEntry('Reboot', 'auto_reboot'),
|
||||||
|
|
|
||||||
|
|
@ -657,12 +657,18 @@ def auto_dism(group, name):
|
||||||
reboot()
|
reboot()
|
||||||
|
|
||||||
|
|
||||||
def auto_emsisoft_cmd(group, name):
|
def auto_emsisoft_cmd_run(group, name):
|
||||||
"""Run EmisoftCmd."""
|
"""Run EmisoftCmd."""
|
||||||
TRY_PRINT.run('EmsisoftCmd (Install)...', install_emsisoft_cmd)
|
TRY_PRINT.run('EmsisoftCmd (Install)...', install_emsisoft_cmd)
|
||||||
TRY_PRINT.run('EmsisoftCmd (Update)...', update_emsisoft_cmd)
|
TRY_PRINT.run('EmsisoftCmd (Update)...', update_emsisoft_cmd)
|
||||||
result = TRY_PRINT.run('EmsisoftCmd (Scan)...', run_emsisoft_cmd_scan)
|
result = TRY_PRINT.run('EmsisoftCmd (Scan)...', run_emsisoft_cmd_scan)
|
||||||
TRY_PRINT.run('EmsisoftCmd (Uninstall)...', uninstall_emsisoft_cmd)
|
TRY_PRINT.run('EmsisoftCmd (Uninstall Service)...', delete_emsisoft_cmd_service)
|
||||||
|
save_settings(group, name, result=result)
|
||||||
|
|
||||||
|
|
||||||
|
def auto_emsisoft_cmd_uninstall(group, name):
|
||||||
|
"""Uninstall EmsisoftCmd."""
|
||||||
|
result = TRY_PRINT.run('EmsisoftCmd (Uninstall)...', uninstall_emsisoft_cmd)
|
||||||
save_settings(group, name, result=result)
|
save_settings(group, name, result=result)
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -973,6 +979,17 @@ def backup_registry():
|
||||||
run_tool('ERUNT', 'ERUNT', backup_path, 'sysreg', 'curuser', 'otherusers')
|
run_tool('ERUNT', 'ERUNT', backup_path, 'sysreg', 'curuser', 'otherusers')
|
||||||
|
|
||||||
|
|
||||||
|
def delete_emsisoft_cmd_service():
|
||||||
|
"""Delete EmsisoftCmd service."""
|
||||||
|
try:
|
||||||
|
stop_service('epp')
|
||||||
|
except GenericError:
|
||||||
|
pass
|
||||||
|
|
||||||
|
# Delete service
|
||||||
|
run_program(['sc', 'delete', 'epp'], check=False)
|
||||||
|
|
||||||
|
|
||||||
def delete_registry_null_keys():
|
def delete_registry_null_keys():
|
||||||
"""Delete registry keys with embedded null characters."""
|
"""Delete registry keys with embedded null characters."""
|
||||||
run_tool('RegDelNull', 'RegDelNull', '-s', '-y', download=True)
|
run_tool('RegDelNull', 'RegDelNull', '-s', '-y', download=True)
|
||||||
|
|
@ -1205,22 +1222,7 @@ def run_tdsskiller():
|
||||||
|
|
||||||
|
|
||||||
def uninstall_emsisoft_cmd():
|
def uninstall_emsisoft_cmd():
|
||||||
"""Uninstall EmsisoftCmd.
|
"""Uninstall EmsisoftCmd."""
|
||||||
|
|
||||||
NOTE: If the epp service was installed previously then it may get in
|
|
||||||
the way. Just in case this wil attempt to stop and delete it.
|
|
||||||
"""
|
|
||||||
try:
|
|
||||||
stop_service('epp')
|
|
||||||
except GenericError:
|
|
||||||
# Ignore and delete *most* of EmsisoftCmd
|
|
||||||
pass
|
|
||||||
|
|
||||||
# Delete service (if possible / present)
|
|
||||||
run_program(['sc', 'delete', 'epp'], check=False)
|
|
||||||
|
|
||||||
# Delete install dir
|
|
||||||
## NOTE: Using ingore_errors=True in case service dll can't be removed.
|
|
||||||
delete_folder(EMSISOFT_INSTALL_PATH, force=True, ignore_errors=True)
|
delete_folder(EMSISOFT_INSTALL_PATH, force=True, ignore_errors=True)
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue