-
Notifications
You must be signed in to change notification settings - Fork 1
/
zoomer.py
37 lines (31 loc) · 1.05 KB
/
zoomer.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
import configparser
from cli import parse_arguments
import utils
def main():
args = parse_arguments()
if args.getmousepos:
utils.getjoinposn()
elif args.updatepass is not None:
utils.update_pass(args.updatepass)
elif args.append is not None:
utils.append(args.append)
elif args.changepass is not None:
utils.change_pass(args.changepass)
else:
config = configparser.ConfigParser()
config.read("data.ini")
joinposn = config["VALUES"]["join"].split(", ")
try:
joinposn = [int(x) for x in joinposn]
except ValueError:
# fmt: off
print(
"Oops, it looks like you haven't"
"set the positon of join button."
)
# fmt: on
subject = utils.get_subject() if args.subject is None else args.subject
zoom_id, zoom_pass = utils.get_credentials(subject)
utils.auto_type(zoom_id, zoom_pass, joinposn)
if __name__ == "__main__":
main()