mirror of
https://github.com/NovaOSS/violet.git
synced 2024-11-25 16:23:59 +01:00
21 lines
411 B
Python
21 lines
411 B
Python
import sys
|
|
import colorama
|
|
|
|
import violet
|
|
|
|
colorama.init(autoreset=True)
|
|
|
|
if len(sys.argv) > 1:
|
|
prompt = ' '.join(sys.argv[1:])
|
|
print(violet.respond(prompt)['colored'])
|
|
|
|
else:
|
|
while True:
|
|
try:
|
|
prompt = input(colorama.Fore.BLUE)
|
|
except KeyboardInterrupt:
|
|
sys.exit(0)
|
|
|
|
print(colorama.Fore.RESET, end='')
|
|
print(violet.respond(prompt)['colored'])
|