зеркало из https://github.com/microsoft/lisa.git
Create __main__.py
This commit is contained in:
Родитель
4db08f529f
Коммит
12715dd683
|
@ -0,0 +1,7 @@
|
|||
# Copyright (c) Microsoft Corporation.
|
||||
# Licensed under the MIT license.
|
||||
|
||||
from lisa.main import cli
|
||||
|
||||
if __name__ == "__main__":
|
||||
cli()
|
10
lisa/main.py
10
lisa/main.py
|
@ -151,7 +151,11 @@ def main() -> int:
|
|||
return exit_code
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
def cli() -> int:
|
||||
"""
|
||||
CLI entry point
|
||||
"""
|
||||
|
||||
exit_code = 0
|
||||
try:
|
||||
exit_code = main()
|
||||
|
@ -166,3 +170,7 @@ if __name__ == "__main__":
|
|||
traceback.print_exc()
|
||||
finally:
|
||||
sys.exit(exit_code)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
cli()
|
||||
|
|
Загрузка…
Ссылка в новой задаче