Adds duplication check for source files in CI
This commit is contained in:
parent
fefa001bb6
commit
39e13bf530
2 changed files with 25 additions and 8 deletions
14
tools/scripts/checkDuplicateFilenames.py
Normal file
14
tools/scripts/checkDuplicateFilenames.py
Normal file
|
@ -0,0 +1,14 @@
|
|||
#!/usr/bin/env python3
|
||||
|
||||
import os
|
||||
import sys
|
||||
|
||||
files_set = set()
|
||||
|
||||
for root, dir, files in os.walk("src/catch2"):
|
||||
for file in files:
|
||||
if file not in files_set:
|
||||
files_set.add(file)
|
||||
else:
|
||||
print("File %s is duplicate" % file)
|
||||
sys.exit(1)
|
Loading…
Add table
Add a link
Reference in a new issue