Skip to content

Commit df0161c

Browse files
fix : logo file moved to params
1 parent a563320 commit df0161c

File tree

4 files changed

+25
-16
lines changed

4 files changed

+25
-16
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
<a href="https://waffle.io/sepandhaghighi/qpage"><img src="https://badge.waffle.io/sepandhaghighi/qpage.png?label=ready&title=Ready"/></a>
77
<a href="http://www.qpage.ir/doc"><img src="https://img.shields.io/badge/doc-latest-orange.svg"></a>
88
<a href="https://www.codacy.com/app/sepand-haghighi/qpage?utm_source=github.com&amp;utm_medium=referral&amp;utm_content=sepandhaghighi/qpage&amp;utm_campaign=Badge_Coverage"><img src="https://api.codacy.com/project/badge/Coverage/4d3f9b490b9a42c282b745ae8e2a122c"/></a>
9+
910
</div>
1011
<hr/>
1112
<div align="center">

resource/logo.txt

Lines changed: 0 additions & 5 deletions
This file was deleted.

source/params.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,3 +66,12 @@
6666
files = []
6767
warnings = []
6868
today_time = str(datetime.date.today()) # Get Today Date By datetime module
69+
70+
71+
LOGO='''
72+
____ ___
73+
/ __ \ / _ \___ ____ ____
74+
/ /_/ / / ___/ _ `/ _ `/ -_)
75+
\___\_\/_/ \_,_/\_, /\__/
76+
/___/
77+
'''

source/qpage.py

Lines changed: 15 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -17,25 +17,29 @@
1717

1818
def show_items(enum_list):
1919
""" show item of enum_list
20-
2120
:param enum_list the list that should be shown
2221
:type enum_list : list
2322
"""
2423
for i, item in enumerate(enum_list): # print errors
2524
print(str(i + 1) + "-" + item) # print pass
2625

2726

28-
def print_logo():
29-
""" print qpage logo by characters
30-
31-
"""
32-
if "logo.txt" in os.listdir(RESOURCE_DIR):
33-
logo_path = os.path.join(RESOURCE_DIR, 'logo.txt')
34-
with open(logo_path, "r") as logo_file:
35-
for line in logo_file:
36-
print(line.rstrip())
27+
def print_logo(external=False):
28+
'''
29+
print qpage logo by characters
30+
:param external: bool , choose internal or external logo
31+
:return: None
32+
'''
33+
if external==True:
34+
if "logo.txt" in os.listdir(RESOURCE_DIR):
35+
logo_path = os.path.join(RESOURCE_DIR, 'logo.txt')
36+
with open(logo_path, "r") as logo_file:
37+
for line in logo_file:
38+
print(line.rstrip())
39+
else:
40+
pass
3741
else:
38-
pass
42+
print(LOGO)
3943

4044

4145
def convert_bytes(num):

0 commit comments

Comments
 (0)