aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/copyright_checking.py
diff options
context:
space:
mode:
authorsaturneric <[email protected]>2024-01-18 05:32:25 +0000
committersaturneric <[email protected]>2024-01-18 05:32:25 +0000
commit38e4a656dbdd14cf7a6a91cda6c814b5290acd93 (patch)
tree33f614f861dec8fef4ea456dda26abab2e3329f5 /scripts/copyright_checking.py
parentfix: improve code quality, docs and ci files (diff)
downloadGpgFrontend-38e4a656dbdd14cf7a6a91cda6c814b5290acd93.tar.gz
GpgFrontend-38e4a656dbdd14cf7a6a91cda6c814b5290acd93.zip
fix: slove codacy issues
Diffstat (limited to 'scripts/copyright_checking.py')
-rw-r--r--scripts/copyright_checking.py2
1 files changed, 0 insertions, 2 deletions
diff --git a/scripts/copyright_checking.py b/scripts/copyright_checking.py
index 82099b22..6002e0fe 100644
--- a/scripts/copyright_checking.py
+++ b/scripts/copyright_checking.py
@@ -63,13 +63,11 @@ def check_copright_by_path(path, copyright_text, suffix):
file_path = os.path.join(root, file)
with open(file_path, 'r', encoding='utf-8') as f:
content = f.read()
-
if copyright_text not in content:
print(f"copyright declaration missing: {file_path}")
check_copright_by_path("src", copyright_text_source, ('.c', '.cpp', '.h', '.hpp'))
check_copright_by_path("test", copyright_text_source, ('.c', '.cpp', '.h', '.hpp'))
-
check_copright_by_path("src", copyright_text_script, ('.txt'))
check_copright_by_path("src", copyright_text_script, ('.txt'))
print("check done") \ No newline at end of file