Advertisement
Guest User

Untitled

a guest
Aug 16th, 2017
53
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 1.19 KB | None | 0 0
  1. import getpass
  2. import glob
  3. import os
  4. import string
  5.  
  6. def start():
  7.     print("Sayris-AI - V 0.0.1\n")
  8.     with open("pass.txt") as f:
  9.      lines = f.readlines()[65]
  10.      pw = lines.rstrip('\n')
  11.     p = "null"
  12.     while pw != p:
  13.      p = getpass.getpass("Enter Passphrase: ")
  14.     print("\n:::: Passphrase Accepted ::::\n")
  15.  
  16. def Module_Loader():
  17.     print("Load Module List :\n")
  18.     os.chdir("./Modules")
  19.     for file in glob.glob("*.py"):
  20.         print(file)
  21.  
  22. def Start_Modules():
  23.     print("Start Modules...")
  24.     while True:
  25.         command = input("Enter a Command : \n").lower()
  26.         print(command)
  27.         if command == "start":
  28.             print("Call Command")
  29.             Start_Modules()
  30.         elif command == "exit":
  31.             print("Shutdown")
  32.             break
  33.         else:
  34.             print("Wrong Command , please Retype")
  35.  
  36. start()
  37.  
  38. while True:
  39.     lowchoice = input("Enter Command: ")
  40.     lowchoice.lower()
  41.     if lowchoice == "start":
  42.         print("Starts Modules")
  43.         Module_Loader()
  44.         Start_Modules()
  45.     elif lowchoice == "exit":
  46.         print("shutting down")
  47.         break
  48.     else:
  49.       print("wrong command please Retype")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement