Add python-fire, Remove pyinquirer from main runner script
This commit is contained in:
parent
d7531412cf
commit
69c93fd894
18
main.py
18
main.py
@ -1,6 +1,6 @@
|
||||
from PyInquirer import prompt
|
||||
import importlib
|
||||
import os
|
||||
import fire
|
||||
|
||||
|
||||
def load_modules():
|
||||
@ -16,19 +16,5 @@ def load_modules():
|
||||
return loaded_modules
|
||||
|
||||
|
||||
def open_module_selection(module_names):
|
||||
print("Available Modules:")
|
||||
module_selection = [
|
||||
{
|
||||
'type': 'checkbox',
|
||||
'message': 'Select modules',
|
||||
'name': 'modules',
|
||||
'choices': list(map(lambda x: {"name": x}, list(module_names)))
|
||||
}
|
||||
]
|
||||
return prompt(module_selection)['modules']
|
||||
|
||||
|
||||
modules = load_modules()
|
||||
|
||||
[modules[module].run() for module in open_module_selection(modules.keys())]
|
||||
fire.Fire(modules)
|
||||
|
@ -1 +1,2 @@
|
||||
fire
|
||||
PyInquirer==1.0.3
|
||||
|
Loading…
Reference in New Issue
Block a user