This repository has been archived on 2024-10-24. You can view files and clone it, but cannot push or open issues or pull requests.
NG_KillSwitch/main.py

19 lines
408 B
Python
Raw Normal View History

2023-01-31 13:27:10 +00:00
# Project: Telegram PC kill switch bot
# Author: Stanislav Mykhailenko
# License: Unlicense
import ctypes, sys
2023-02-01 17:38:20 +00:00
from googledrive import authenticate
2023-01-31 13:27:10 +00:00
from tg import startBot
def main() -> None:
if ctypes.windll.shell32.IsUserAnAdmin():
startBot()
else:
ctypes.windll.shell32.ShellExecuteW(None, "runas", sys.executable, " ".join(sys.argv), None, 1)
if __name__ == '__main__':
2023-02-01 17:38:20 +00:00
authenticate()
2023-01-31 13:27:10 +00:00
main()