-
Notifications
You must be signed in to change notification settings - Fork 2
/
__init__.py
67 lines (64 loc) · 2.53 KB
/
__init__.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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
"""Configuration file for toolbox addon"""
from .System import version
from .Container import rm
from .Addon import placeholder # Toolbox class
__override__ = {
'System.version': 'Version',
'Container.rm': 'Rm',
'Addon.placeholder': 'Toolbox',
}
__argparse__ = [
{
'namespace': "Version",
'position': "Self",
'subcommand': None,
'actions': [
"add_argument('--client', '-c', \
action='store_true', \
dest='client', \
help='Show the Tsaotun version information')",
],
},
{
'namespace': "Container",
'position': "Child",
'subcommand': "rm",
'actions': [
"add_argument('--clear', \
action='store_true', \
dest='clear', \
help='Remove all dead and alive containers. \
You still need to give a whatever container ID.')",
],
},
{
'namespace': "System",
'position': "Child",
'subcommand': None,
'actions': [
"add_parser('{}', \
formatter_class=argparse.RawDescriptionHelpFormatter, \
usage='%(prog)s [OPTIONS] [COMMANDS]', description=textwrap.dedent('''\
A Tsaotun's addon that provides useful aliases for you\
'''))".format(__name__),
"add_argument('container', \
type=str, \
metavar='CONTAINER', \
nargs='?', \
help='Container to execute')",
"add_argument('--host', \
action='store_true', \
dest='t_host', \
help='Enter the VM that was created by HyperKit (Mac OS X/macOS).')",
"add_argument('--shell', \
action='store_true', \
help='Enter into the shell of given container.')",
"add_argument('--show-ip', \
action='store_true', \
help='Show the IP address of given container.')",
"add_argument('--exec', \
type=str, \
help='Execute a command.')",
]
},
]