Skip to content

Commit 69e87ae

Browse files
authored
Merge pull request #9 from fosslight/develop
Develop
2 parents 1175b62 + f731078 commit 69e87ae

File tree

3 files changed

+32
-2
lines changed

3 files changed

+32
-2
lines changed

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
if __name__ == "__main__":
1414
setup(
1515
name='fosslight_util',
16-
version='1.0.6',
16+
version='1.0.7',
1717
package_dir={"": "src"},
1818
packages=find_packages(where='src'),
1919
description='FOSSLight Util',

src/fosslight_util/help.py

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
#!/usr/bin/env python
2+
# -*- coding: utf-8 -*-
3+
# Copyright (c) 2021 LG Electronics Inc.
4+
# SPDX-License-Identifier: Apache-2.0
5+
import sys
6+
7+
_HELP_MESSAGE_COMMON = """
8+
_______ _______ _______ _______ ___ ___ _______ __ __ _______
9+
| || || || || | | | | || | | || |
10+
| ___|| _ || _____|| _____|| | | | | ___|| |_| ||_ _|
11+
| |___ | | | || |_____ | |_____ | | | | | | __ | | | |
12+
| ___|| |_| ||_____ ||_____ || |___ | | | || || _ | | |
13+
| | | | _____| | _____| || || | | |_| || | | | | |
14+
|___| |_______||_______||_______||_______||___| |_______||__| |__| |___|
15+
"""
16+
17+
class PrintHelpMsg():
18+
message_suffix = ""
19+
20+
def __init__(self, value):
21+
self.message_suffix = value
22+
23+
def print_help_msg(self, exitopt):
24+
print(_HELP_MESSAGE_COMMON)
25+
print(self.message_suffix)
26+
27+
if exitopt == True:
28+
sys.exit()
29+
30+

tests/test_help.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ def main():
1212
Test Test Test
1313
"""
1414
helpMsg = PrintHelpMsg(_HELP_MESSAGE_TEST)
15-
helpMsg.print_help_msg()
15+
helpMsg.print_help_msg(True)
1616

1717
if __name__ == '__main__':
1818
main()

0 commit comments

Comments
 (0)