Skip to content

Commit 9b69df0

Browse files
committed
[CHORE] Changed keyword for todobot to only TODO
1 parent bd6e7ed commit 9b69df0

File tree

11 files changed

+22
-22
lines changed

11 files changed

+22
-22
lines changed

.github/config.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
todo:
2-
keyword: ['@todo', 'TODO:', 'TODO', '@todo:']
2+
keyword: "@todo:"

42PyChecker.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
import argparse
77
import platform
88
from PyChecker.projects import libft, ft_commandements, other
9-
# @todo Add verbose output
9+
# @todo: Add verbose output
1010

1111

1212
def print_header():
@@ -38,7 +38,7 @@ def main():
3838
parser.add_argument("--show-w", help="Displays the warranty warning from the license.", action="store_true")
3939
parser.add_argument("--show-c", help="Displays the conditions warning from the license.", action="store_true")
4040
parser.add_argument("--no-tests", help="Disables all the testing suites for the project.", action="store_true")
41-
# @todo Check what option is given based on the selected project.
41+
# @todo: Check what option is given based on the selected project.
4242
parser.add_argument("--no-required", help="Disables required functions check", action="store_true")
4343
parser.add_argument("--no-libft-unit-test", help="Disables libft-unit-test", action="store_true")
4444
# @todo: Fix --do-benchmark option for libft-unit-test
@@ -83,10 +83,10 @@ def main():
8383
print_header()
8484
if args.project == "libft":
8585
libft.check(root_path, args)
86-
# @todo Handle options for 42commandements: No option can be passed (like --no-norm)
86+
# @todo: Handle options for 42commandements: No option can be passed (like --no-norm)
8787
if args.project == "42commandements":
8888
ft_commandements.check(args)
89-
# @todo Handle options for other: No option can be passed (like --no-norm)
89+
# @todo: Handle options for other: No option can be passed (like --no-norm)
9090
if args.project == "other":
9191
other.check(root_path, args)
9292

PyChecker/projects/libft.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ def check(root_path: str, args):
6565
bonus_functions = ['ft_lstnew.c', 'ft_lstdelone.c', 'ft_lstdel.c',
6666
'ft_lstiter.c', 'ft_lstadd.c', 'ft_lstmap.c']
6767
authorized_functions = ['free', 'malloc', 'write', 'main']
68-
# @todo add libft-unit-test to the testing suite
68+
# @todo: add libft-unit-test to the testing suite
6969
if not args.no_author:
7070
author_results = author.check(args.path)
7171
if not args.no_required:
@@ -88,7 +88,7 @@ def check(root_path: str, args):
8888
if not args.no_maintest:
8989
maintest_ok, maintest_fail = maintest.run_libft(args.path, root_path)
9090
if not args.no_libft_unit_test:
91-
# @todo Add return message/values to results for libft-unit-test
91+
# @todo: Add return message/values to results for libft-unit-test
9292
libft_unit_test.run(root_path, args)
9393
print("\n\n\nThe results are in:\n")
9494
if not args.no_author:
@@ -97,7 +97,7 @@ def check(root_path: str, args):
9797
print("Required Functions: \n" + required_results + '\n')
9898
print("Bonus Functions: \n" + bonus_result + '\n')
9999
if not args.no_extra:
100-
# @todo Stats on all c/h files of project, like with `cloc' ?
100+
# @todo: Stats on all c/h files of project, like with `cloc' ?
101101
print("Extra Functions: -- You have {}\n".format(len(extra_functions)))
102102
if not args.no_norm:
103103
print("Norme results: \n" + norm_results + '\n')

PyChecker/projects/other.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,6 @@ def check(root_path: str, args):
1010
author.check(args.path)
1111
if not args.no_norm:
1212
norme.check(args.path, root_path)
13-
# @todo Add the makefile check and find the binary name itself
14-
# @todo Add forbidden function check based on assumption of what the project is.
13+
# @todo: Add the makefile check and find the binary name itself
14+
# @todo: Add forbidden function check based on assumption of what the project is.
1515
return 0

PyChecker/testing_suite/libft_unit_test.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,4 @@ def run(root_path: str, args):
2929
result = subprocess.run([root_path + '/testing_suites/libft-unit-test/run_test', '-b'], stdout=subprocess.PIPE, stderr=subprocess.STDOUT).stdout.decode('utf-8')
3030
print(result)
3131
file.write(result)
32-
# @todo return results from benchmark and tests
32+
# @todo: return results from benchmark and tests

PyChecker/testing_suite/maintest.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -41,10 +41,10 @@ def run_libft(project_path: str, root_path: str):
4141
'lstadd', 'lstiter', 'lstmap']
4242
missing_functions = []
4343
for file in maintest_functions:
44-
# @todo Add a check to handle libft where file aren't at libft/ but can be in libft/src
44+
# @todo: Add a check to handle libft where file aren't at libft/ but can be in libft/src
4545
if not os.path.exists(project_path + '/ft_' + file + '.c'):
4646
missing_functions.append(file)
47-
# @todo special case for memalloc and memdel
47+
# @todo: special case for memalloc and memdel
4848
comment_define(root_path + '/testing_suites/Maintest/libft/main.c', root_path + '/libft_main.c', missing_functions)
4949
with open(root_path + "/.mymaintest", 'w+') as file:
5050
file.write("*------------------------------------------------------*\n")
@@ -62,12 +62,12 @@ def run_libft(project_path: str, root_path: str):
6262
print(result)
6363
result = subprocess.run([root_path + '/libft_main.out'], stdout=subprocess.PIPE,
6464
stderr=subprocess.STDOUT).stdout.decode('utf-8')
65-
# @todo Count number of OK and FAILs and yellow tests to get score for maintest
65+
# @todo: Count number of OK and FAILs and yellow tests to get score for maintest
6666
file.write(result + '\n')
6767
print(result)
6868
if platform.system() == "Linux":
6969
print("-- Disclaimer: Some of these test may fail where they woudn't on Darwin. (Because Linux ?)")
7070
os.remove(root_path + "/libft_main.c")
7171
os.remove(root_path + "/libft_main.out")
72-
# @todo Check if FAIL is the right keyword.
72+
# @todo: Check if FAIL is the right keyword.
7373
return result.count("OK"), result.count("FAIL")

PyChecker/testing_suite/moulitest.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ def execute_test(test_name: str, root_path: str):
4141
file.write("Warning: This file contains escape sequences. Please use"
4242
" `cat' to view it properly.\n")
4343
file.write("*------------------------------------------------------*\n")
44-
# @todo Get the result line of moulitest and parse it.
44+
# @todo: Get the result line of moulitest and parse it.
4545
result = subprocess.run('make ' + test_name + ' -C ' + root_path +
4646
'/testing_suites/moulitest', shell=True,
4747
stdout=subprocess.PIPE,
@@ -67,7 +67,7 @@ def run(project_path: str, has_libft_bonuses: bool, project: str, root_path: str
6767
with open(root_path + "/testing_suites/moulitest/config.ini", 'w+') as file:
6868
file.write("LIBFT_PATH = " + project_path)
6969
include_libft_bonuses(root_path)
70-
# @todo Fix moulitest makefile (it starts the bonus even when not asked.)
70+
# @todo: Fix moulitest makefile (it starts the bonus even when not asked.)
7171
if not has_libft_bonuses:
7272
exclude_libft_bonuses(root_path)
7373
results = execute_test("libft_bonus", root_path)

PyChecker/utils/author.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ def check(project_path: str):
1717
2 if there's too many lines in the file,
1818
3 if the newline char is missing in the end of line
1919
"""
20-
# @todo message and handle multiple authors
20+
# @todo: message and handle multiple authors
2121
print("*---------------------------------------------------------------*")
2222
print("*--------------------------Author file--------------------------*")
2323
print("*---------------------------------------------------------------*")

PyChecker/utils/forbidden_functions.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ def check(project_path: str, binary: str, authorized_func, root_path: str):
2121
print("*---------------------------------------------------------------*")
2222
ret = ""
2323
functions_called = []
24-
# @todo Check difference between Darwin and Linux `nm'
24+
# @todo: Check difference between Darwin and Linux `nm'
2525
subprocess.run(['make', '-C', project_path, 'all'], stdout=subprocess.PIPE,
2626
stderr=subprocess.STDOUT)
2727
result = subprocess.run(['nm', project_path + '/' + binary],

PyChecker/utils/makefile.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ def check_makefile_all(project_path: str, binary_name: str, root_path: str):
7878
print("-> Error when processing rule `all':"
7979
" It should NOT have removed *.o")
8080
error_count += 1
81-
# @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
81+
# @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
8282
return error_count
8383

8484

@@ -253,7 +253,7 @@ def check_makefile_name(project_path: str, binary_name: str, root_path: str):
253253
print("-> Error when processing rule `fclean': It should"
254254
" NOT have removed *.o\n")
255255
error_count += 1
256-
# @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
256+
# @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
257257
return error_count
258258

259259

0 commit comments

Comments
 (0)