-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathArgs.py
More file actions
38 lines (27 loc) · 1.01 KB
/
Args.py
File metadata and controls
38 lines (27 loc) · 1.01 KB
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
import argparse
class Args:
def __init__(self):
self.parser = argparse.ArgumentParser(
description=
'Mirror Telegram Channel.')
self.parser.add_argument('--mt_proxy', '-p', help='Use built-in MTProxy Server.', action='store_true')
self.parser.add_argument('--iter_messages', '-i', help='Run Iter Messages Action.', action='store_true')
self.parser.add_argument('--config', '-c', help='Run Download NOW.', type=str, default='default',
action='store')
self.args = self.parser.parse_args()
@property
def mt_proxy(self):
return self.args.__dict__['mt_proxy']
@property
def iter_messages(self):
return self.args.__dict__['iter_messages']
@property
def run_now(self):
return self.args.__dict__['run_now']
@property
def run_test(self):
return self.args.__dict__['run_test']
@property
def config(self):
return self.args.__dict__['config']
args = Args()