Merge pull request #5070 from jepler/check-duplicate-topdir

check vid/pid: find topdir relative to this script
This commit is contained in:
Dan Halbert 2021-07-27 21:08:33 -04:00 committed by GitHub
commit 7641bf15c0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -72,13 +72,7 @@ def configboard_files():
:returns: A ``pathlib.Path.glob()`` generator object
"""
working_dir = pathlib.Path().resolve()
if not working_dir.name.startswith("circuitpython") and not working_dir.name.startswith(
"micropython"
):
raise RuntimeError(
"Please run USB VID/PID duplicate verification at the " "top-level directory."
)
working_dir = pathlib.Path(__file__).resolve().parent.parent
return working_dir.glob("ports/**/boards/**/mpconfigboard.mk")