-
Notifications
You must be signed in to change notification settings - Fork 0
/
sicli.py
41 lines (32 loc) · 993 Bytes
/
sicli.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#Importing Libs
import click
import api
import json
@click.command()
@click.option('--name', prompt='Company name:',
help='The person to greet.')
def cli(name):
json_data = api.techinside(name)
if json_data != "n/a":
dict_data = json.loads(json_data)
click.echo("")
click.echo("> Application and Data :")
for each in dict_data["Application and Data"]:
click.echo("-" + each)
click.echo("")
click.echo("> Utilities : ")
for each in dict_data["Utilities"]:
click.echo("-" + each)
click.echo("")
click.echo("> DevOps :")
for each in dict_data["Application and Data"]:
click.echo("-" + each)
click.echo("")
click.echo("> Business Tools :")
for each in dict_data["Business Tools"]:
click.echo("-" + each)
click.echo("")
else:
click.echo("Company not found")
if __name__ == '__main__':
cli()