Fix the prefix check that matches any line with "prefix:"
that fails tox.
The prefix check fails on the following line
which is valid.
failure-notification-prefix: "[releng]"
require a space before prefix: now it cannot match
failure-notification-prefix:
Change-Id: I2d5ee1eb7c858bd5eac03af02f44db2f4a9e46a8
Signed-off-by: Anil Belur <abelur@linuxfoundation.org>
"""Check if a prefix was checked into this repo."""
with open(filename, "r") as _file:
for num, line in enumerate(_file, 1):
- if re.search("prefix:", line):
+ if re.search(r"^\s+prefix:", line):
if '""' not in line:
print(
"ERROR: A non-blank prefix is defined in "