trivial: Make the quirk style more consistent

This commit is contained in:
Richard Hughes 2021-08-23 16:02:41 +01:00
parent 6a8f285ee2
commit c1ff02f055
8 changed files with 75 additions and 65 deletions

View File

@ -26,12 +26,22 @@ def test_files() -> int:
print("{} has invalid section header: {}".format(fn, line)) print("{} has invalid section header: {}".format(fn, line))
rc = 1 rc = 1
continue continue
for deprecated in ["DeviceInstanceId", "Guid"]:
if line.find(deprecated) != -1:
print("{} has deprecated prefix: {}".format(fn, deprecated))
rc = 1
continue
else: else:
sections = line.split(" = ") sections = line.split(" = ")
if len(sections) != 2: if len(sections) != 2:
print("{} has invalid line: {}".format(fn, line)) print("{} has invalid line: {}".format(fn, line))
rc = 1 rc = 1
continue continue
for section in sections:
if section.strip() != section:
print("{} has invalid spacing: {}".format(fn, line))
rc = 1
break
return rc return rc