-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.py
More file actions
26 lines (20 loc) · 1010 Bytes
/
main.py
File metadata and controls
26 lines (20 loc) · 1010 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
import checkSystem
from config import debug_error, debug_warning, debug_success, init, printLogo
from winreg import REG_DWORD
if __name__ == '__main__':
init()
printLogo()
windowsVersion :int = checkSystem.checkWindowsVersion()
print(f'\n\t\tWindows {windowsVersion}')
if(windowsVersion == 10 or windowsVersion == 11):
checkSystem.stopUpdateService('wuauserv')
checkSystem.changeServiceStartType('wuauserv', 'disabled')
checkSystem.regeditDisableUpdate('NoAutoUpdate', 1, REG_DWORD, r'SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU')
if(windowsVersion == 7):
checkSystem.stopUpdateService('wuauserv')
checkSystem.changeServiceStartType('wuauserv', 'disabled')
checkSystem.regeditDisableUpdate('DisableOSUpgrade', 1, REG_DWORD, r'SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate')
print('Programm is complete!\n')
print('Author:\n')
print('https://github.com/LiDevMon', '\n')
input('Press ENTER to extit')