fsfw/contrib/fsfw_contrib/Catch2-3.7.1/tools/scripts/checkDuplicateFilenames.py

15 lines
288 B
Python
Raw Permalink Normal View History

2024-10-29 10:49:46 +01:00
#!/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)