From b8fa7456f7381e313bef895966db7deb0df5bae5 Mon Sep 17 00:00:00 2001 From: Amir MOHAMMADI <amir.mohammadi@idiap.ch> Date: Thu, 25 Mar 2021 16:08:43 +0100 Subject: [PATCH] [ci][check] use available python to install pre-commit --- bob/devtools/scripts/ci.py | 4 ++-- conda/meta.yaml | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/bob/devtools/scripts/ci.py b/bob/devtools/scripts/ci.py index ab7fd920..ca22a5b8 100644 --- a/bob/devtools/scripts/ci.py +++ b/bob/devtools/scripts/ci.py @@ -1019,10 +1019,10 @@ def check(root): if os.path.isfile(path): from ..bootstrap import run_cmdline - run_cmdline(["pip", "install", "--user", "--upgrade", "pre-commit"]) + run_cmdline(["python", "-m", "pip", "install", "pre-commit"]) try: backup = os.environ.get("SKIP", "") os.environ["SKIP"] = "sphinx-build,sphinx-doctest" - run_cmdline(["pre-commit", "run", "--all-files"]) + run_cmdline(["python", "-m", "pre_commit", "run", "--all-files"]) finally: os.environ["SKIP"] = backup diff --git a/conda/meta.yaml b/conda/meta.yaml index 09a2ed1e..8d3b99cd 100644 --- a/conda/meta.yaml +++ b/conda/meta.yaml @@ -51,6 +51,7 @@ requirements: - psutil - tabulate - python-graphviz + - pip test: requires: -- GitLab