From 650517ccf579b178d01cfddef0eb392584f4ab61 Mon Sep 17 00:00:00 2001 From: Remco de Boer <29308176+redeboer@users.noreply.github.com> Date: Tue, 7 Nov 2023 13:46:28 +0100 Subject: [PATCH] DX: switch to black pre-commit hook --- src/repoma/check_dev_files/black.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/repoma/check_dev_files/black.py b/src/repoma/check_dev_files/black.py index e27b7855..9e3522aa 100644 --- a/src/repoma/check_dev_files/black.py +++ b/src/repoma/check_dev_files/black.py @@ -30,6 +30,7 @@ def main(has_notebooks: bool) -> None: executor = Executor() executor(_remove_outdated_settings) executor(_update_black_settings) + executor(remove_precommit_hook, "https://github.com/psf/black") executor(_update_precommit_repo, has_notebooks) executor(add_extension_recommendation, "ms-python.black-formatter") executor(set_setting, {"black-formatter.importStrategy": "fromEnvironment"}) @@ -81,7 +82,7 @@ def _update_black_settings() -> None: def _update_precommit_repo(has_notebooks: bool) -> None: expected_hook = CommentedMap( - repo="https://github.com/psf/black", + repo="https://github.com/psf/black-pre-commit-mirror", hooks=[CommentedMap(id="black")], ) if has_notebooks: