WizardKit/.bin/Scripts/system_checklist.py
Alan Mason 6fc04266d4 2017-11: Retroactive Updates
## MAJOR refactoring done ##

* All .cmd Command scripts
  * Brandind / Settings variables now set via .bin/Scripts/settings/main.py
  * Window titles now set using KIT_FULL_NAME

* All .py Python scripts
  * All ClientDir paths should now use KIT_SHORT_NAME
  * Long lines wrapped to better follow PEP8
  * String formatting now more consistant
  * Updated run_program() and popen_program() calls to use lists
    * (e.g. cmd = ['', '', '']; run_program(cmd))
    ** Should improve clarity IMO
  * Update window titles AFTER init_global_vars() so KIT_FULL_NAME can be used

* Branding / Settings
  * Support tech now configurable
    * (e.g. "Please let {tech} know and they'll look into it")
  * Timezone now configurable
  * Upload info can now be disabled/enabled in .bin/Scripts/settings/main.py

* CHKDSK
  * Combined read-only and fix scripts and added menu

* DISM
  * Combined ScanHealth and RestoreHealth scripts and added menu

* functions/common.py
  * BREAKING: run_program() and popen_program() no longer accept 'args' variable

* Misc
  * Removed Win7 NVMe launcher
    * Never used and Win7 is deprecated
  * Removed "DeviceRemover" and "Display Driver Uninstaller" launchers
    * Both cut too deep and were not useful
  * Removed Nirsoft utilities and Sysinternals Suite launchers
    * Too many tools unused.
    * Added .url links to the websites in case the tools are needed
  * Replaced WinDirStat with TreeSizeFree
  * Replaced Q-Dir launcher with XYplorer launcher
    * Q-Dir was running into issues on Windows 10
  * Removed C.IntRep, ESET, and MBAM launchers from "OSR & VR"
  * Removed JRT
    * Deprecated and discontinued by MBAM
  * Removed unsupported QuickBooks launchers (2014 and older)
  * Removed unsupported Office launchers (2010 and 2013\365)
  * Removed "Revo Uninstaller" launcher
  * Removed infrequently used tools from "Diagnostics"
    * Auslogics DiskDefrag
    * BatteryInfoView
    * BIOSCodes
    * GpuTest
    * HeavyLoad

* Bugfixes
  * major_exception() try-blocks should catch CTL+c again
    * Allows for manual script bailing
2017-11-17 01:02:24 -07:00

105 lines
3.7 KiB
Python

# Wizard Kit: System Checklist
import os
import sys
# Init
os.chdir(os.path.dirname(os.path.realpath(__file__)))
sys.path.append(os.getcwd())
from functions.cleanup import *
from functions.diags import *
from functions.info import *
from functions.product_keys import *
from functions.setup import *
init_global_vars()
os.system('title {}: System Checklist Tool'.format(KIT_NAME_FULL))
global_vars['LogFile'] = r'{LogDir}\System Checklist.log'.format(**global_vars)
if __name__ == '__main__':
try:
stay_awake()
ticket_number = get_ticket_number()
os.system('cls')
other_results = {
'Error': {
'CalledProcessError': 'Unknown Error',
'BIOSKeyNotFoundError': 'BIOS key not found',
},
'Warning': {}}
print_info('Starting System Checklist for Ticket #{}\n'.format(
ticket_number))
# Configure
print_info('Configure')
if global_vars['OS']['Version'] == '10':
try_and_print(message='Explorer...',
function=config_explorer_system, cs='Done')
try_and_print(message='Updating Clock...',
function=update_clock, cs='Done')
# Cleanup
print_info('Cleanup')
try_and_print(message='Desktop...',
function=cleanup_desktop, cs='Done')
try_and_print(message='AdwCleaner...',
function=cleanup_adwcleaner, cs='Done')
# Export system info
print_info('Backup System Information')
try_and_print(message='AIDA64 reports...',
function=run_aida64, cs='Done')
try_and_print(message='File listing...',
function=backup_file_list, cs='Done')
try_and_print(message='Power plans...',
function=backup_power_plans, cs='Done')
try_and_print(message='Product Keys...',
function=run_produkey, cs='Done')
try_and_print(message='Registry...',
function=backup_registry, cs='Done')
# User data
print_info('User Data')
show_user_data_summary()
# Summary
print_info('Summary')
try_and_print(message='Operating System:',
function=show_os_name, ns='Unknown', silent_function=False)
try_and_print(message='Activation:',
function=show_os_activation, ns='Unknown', silent_function=False)
if (not windows_is_activated()
and global_vars['OS']['Version'] in ('8', '10')):
try_and_print(message='BIOS Activation:',
function=activate_windows_with_bios,
other_results=other_results)
try_and_print(message='Installed Office:',
function=get_installed_office, ns='Unknown', print_return=True)
show_free_space()
try_and_print(message='Installed RAM:',
function=show_installed_ram, ns='Unknown', silent_function=False)
# Upload info
if ENABLED_UPLOAD_DATA:
print_info('Finalizing')
try_and_print(message='Compressing Info...',
function=compress_info, cs='Done')
try_and_print(message='Uploading to NAS...',
function=upload_info, cs='Done')
# Play audio, show devices, open Windows updates, and open Activation
popen_program(['mmc', 'devmgmt.msc'])
run_hwinfo_sensors()
popen_program(['control', '/name', 'Microsoft.WindowsUpdate'])
if not windows_is_activated():
popen_program('slui')
sleep(3)
run_xmplay()
# Done
print_standard('\nDone.')
pause('Press Enter exit...')
exit_script()
except SystemExit:
pass
except:
major_exception()