Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update command.py #3

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions command.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,29 @@
import os
import pyttsx3

engine = pyttsx3.init()
engine.say("Hello there..how are you..")
engine.say("Please tell me your name by typing ")
engine.runAndWait()
user = input("Please Enter Your name : ")
engine.say("Hello {0}".format(user))
engine.runAndWait()

os.system("color 0e")


engine.say("This is a Modern command line Interface created by Anand Prabhakar")
engine.runAndWait()

print("==========================================================================")
print("\n||\tCommand Line Interface CLI 1.0 By Anand Prabhakar,Bihar,India\t||\n||\tPowered by Python. \t\t\t\t\t\t||\n||\tjust learning..no commercial use.. \t\t\t\t||\n")
print("==========================================================================")
def main():
engine = pyttsx3.init()
engine.say("Please Enter the command you want to run")
engine.runAndWait()
command = input("\n\tEnter the command you want to execute : ")

print("Output after execution : \n")
print("============================================================")
commanding(command)
Expand All @@ -15,7 +34,13 @@ def main():

def commanding(i):
os.system("color 0a")
engine = pyttsx3.init()
engine.say("You have entered the following command")
engine.say(i)
engine.runAndWait()
a = os.system(i)
engine.say("Here is output for the command you entered")
engine.runAndWait()
print("\n\t\tDo you want to Enter Command again\n")
print("-------------------------------------------------------------")
main()
Expand Down