Skip to content

Commit 627080d

Browse files
committed
[CHORE] Removed extraneous `:' from the todo call
1 parent e2d8c7b commit 627080d

1 file changed

Lines changed: 7 additions & 7 deletions

File tree

42PyChecker.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ def check_author_file(project_path: str):
1313
2 if there's too many lines in the file,
1414
3 if the newline char is missing in the end of line
1515
"""
16-
# @todo: Add a skip, Add message if author file is set as optional and handle multiple authors
16+
# @todo Add a skip, Add message if author file is set as optional and handle multiple authors
1717
author_fr = project_path + "/auteur"
1818
author_us = project_path + "/author"
1919
if os.path.exists(author_fr):
@@ -51,7 +51,7 @@ def check_norme(project_path: str):
5151
1 if there isn't any file to check,
5252
2 if some errors/warnings were found
5353
"""
54-
# @todo: Add a skip if norme is set as optional
54+
# @todo Add a skip if norme is set as optional
5555
files = ""
5656
for filename in glob.iglob(project_path + '/**/*.c', recursive=True):
5757
files = files + ' ' + filename
@@ -82,7 +82,7 @@ def check_makefile(project_path: str, binary_name: str):
8282
2 if the binary wasn't removed
8383
3 if the .o files weren't removed
8484
"""
85-
# @todo: Split check_makefile in separate methods for each rule
85+
# @todo Split check_makefile in separate methods for each rule
8686
makefile_path = project_path + '/Makefile'
8787
if not os.path.exists(makefile_path):
8888
print("Error: Makefile not found.")
@@ -95,7 +95,7 @@ def check_makefile(project_path: str, binary_name: str):
9595
file.write(result + '\n')
9696
if os.path.exists(project_path + '/' + binary_name):
9797
file.write("-> Error when processing rule `fclean': It should have removed {}\n".format(binary_name))
98-
#return 2 @todo: Add an error counter
98+
#return 2 @todo Add an error counter
9999
if glob.glob(project_path + '*.o'):
100100
file.write("-> Error when processing rule `fclean': It should have removed *.o\n")
101101
#return 3
@@ -111,7 +111,7 @@ def check_makefile(project_path: str, binary_name: str):
111111
file.write("-> Error when processing rule `fclean': It should have created {}\n".format(binary_name))
112112
if not glob.glob(project_path + '/*.o'):
113113
file.write("-> Error when processing rule `fclean': It should NOT have removed *.o\n")
114-
# @todo: [ -z "$(echo ${MAKEALLTWICE} | grep -i "Nothing to be done")" -a -z "$(echo ${MAKEALLTWICE} | grep -i "is up to date")" ] && printf "%s\n" "-> Failing rule: Processing the rule 'all' twice in a row should result in nothing to be done" && RET=1
114+
# @todo [ -z "$(echo ${MAKEALLTWICE} | grep -i "Nothing to be done")" -a -z "$(echo ${MAKEALLTWICE} | grep -i "is up to date")" ] && printf "%s\n" "-> Failing rule: Processing the rule 'all' twice in a row should result in nothing to be done" && RET=1
115115

116116
file.write("*------------------------------------------------------*\n")
117117
file.write("Checking rule: `clean'\n")
@@ -169,7 +169,7 @@ def check_makefile(project_path: str, binary_name: str):
169169
file.write("--> Error when processing rule `re': It should have compiled a binary named {}\n".format(binary_name))
170170
if not glob.glob(project_path + '/*.o'):
171171
file.write("-> Error when processing rule `fclean': It should NOT have removed *.o\n")
172-
# @todo: [ -z "$(echo ${MAKEALLTWICE} | grep -i "Nothing to be done")" -a -z "$(echo ${MAKEALLTWICE} | grep -i "is up to date")" ] && printf "%s\n" "-> Failing rule: Processing the rule 'all' twice in a row should result in nothing to be done" && RET=1
172+
# @todo [ -z "$(echo ${MAKEALLTWICE} | grep -i "Nothing to be done")" -a -z "$(echo ${MAKEALLTWICE} | grep -i "is up to date")" ] && printf "%s\n" "-> Failing rule: Processing the rule 'all' twice in a row should result in nothing to be done" && RET=1
173173

174174
file.write("*------------------------------------------------------*\n")
175175
file.write("Checking rule: `.PHONY'\n")
@@ -205,7 +205,7 @@ def check_42_commandements(project_path:str):
205205

206206

207207
def check_forbidden_functions(project_path: str, binary: str):
208-
# @todo: Refactor check_forbidden_functions to have a modular authorized_functions (to be used on multiple projects)
208+
# @todo Refactor check_forbidden_functions to have a modular authorized_functions (to be used on multiple projects)
209209
authorized_functions = ['free', 'malloc', 'write', 'main']
210210
functions_called = []
211211
result = subprocess.run(['nm', project_path + '/' + binary], stdout=subprocess.PIPE).stdout.decode('utf-8')

0 commit comments

Comments
 (0)