mirror of
https://github.com/espressif/esp-idf
synced 2025-03-09 17:19:09 -04:00
ci: allow running check-readmes pre-commit hook without IDF_PATH set
... which may happen when making a git commit using a GUI tool.
This commit is contained in:
parent
9653af8d04
commit
8870ffc6e1
@ -406,6 +406,9 @@ if __name__ == '__main__':
|
||||
|
||||
arg = parser.parse_args()
|
||||
|
||||
# Since this script is executed from the pre-commit hook environment, make sure IDF_PATH is set
|
||||
os.environ['IDF_PATH'] = os.path.realpath(os.path.join(os.path.dirname(__file__), '..', '..'))
|
||||
|
||||
if arg.action == 'sort-yaml':
|
||||
sort_yaml(arg.files)
|
||||
else:
|
||||
|
Loading…
x
Reference in New Issue
Block a user