Tests: Relax contributors for multi-language names

This commit is contained in:
Wilson Snyder 2025-09-12 08:43:45 -04:00
parent a4656b823d
commit 8b7a841f09
1 changed files with 17 additions and 7 deletions

View File

@ -59,13 +59,23 @@ def check():
print("Check: " + author)
if re.search(r'\[bot\]', author):
continue
if author not in Contributors:
test.error("Certify your contribution by sorted-inserting '" + author +
"' into docs/CONTRIBUTORS.\n"
" If '" + author +
"' is not your real name, please fix 'name=' in ~/.gitconfig\n"
" Also check your https://github.com account's Settings->Profile->Name\n"
" matches your ~/.gitconfig 'name='.\n")
if author in Contributors:
continue
# Slower subset-of-string test
ok = False
for contrib2 in sorted(Contributors.keys()):
if author in contrib2:
ok = True
break
if ok:
continue
test.error("Certify your contribution by sorted-inserting '" + author +
"' into docs/CONTRIBUTORS.\n"
" If '" + author +
"' is not your real name, please fix 'name=' in ~/.gitconfig\n"
" Also check your https://github.com account's Settings->Profile->Name\n"
" matches your ~/.gitconfig 'name='.\n")
if 'VERILATOR_TEST_NO_CONTRIBUTORS' in os.environ: