Skip to content
Snippets Groups Projects
Commit d028ba1d authored by Amir MOHAMMADI's avatar Amir MOHAMMADI
Browse files

[bdt dev checkout] install pre-commit hook if config is available

parent a3985227
No related branches found
No related tags found
1 merge request!289[bdt dev checkout] install pre-commit hook if config is available
Pipeline #60856 passed
......@@ -62,6 +62,13 @@ def checkout(ctx, names, use_https, subfolder):
subprocess.check_call(["git", "clone", url, dest])
# call pre-commit if its configuration exists
if os.path.isfile(os.path.join(dest, ".pre-commit-config.yaml")):
click.echo(
"Installing pre-commit hooks. Make sure you have pre-commit installed."
)
subprocess.check_call(["pre-commit", "install"], cwd=dest)
@with_plugins(iter_entry_points("bdt.dev.cli"))
@click.group(
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment