Background
I am currently in the process of teaching myself python, and I thought that it would be a very cool project to have a sort of \"control c
To restart:
shutdown /r
To log off:
shutdown /l
The final code block (as requested):
Log off:
def shutdown(self): import subprocess subprocess.call(["shutdown", "-f", "-s", "-t", "60"])
Restart:
def shutdown(self): import subprocess subprocess.call(["shutdown", "-f", "-r", "-t", "60"])