From 149546dc4a8b704f5ba017fd0015197f3bc80a06 Mon Sep 17 00:00:00 2001 From: sysradium Date: Thu, 13 Feb 2025 23:06:37 +0100 Subject: [PATCH] allow python override in Makefile to be able to use it with uv --- Makefile | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/Makefile b/Makefile index c8e7c04f6..63bb930bd 100644 --- a/Makefile +++ b/Makefile @@ -1,18 +1,20 @@ .PHONY: quality style test docs utils +PYTHON ?= python + check_dirs := examples src tests utils # Check code quality of the source code quality: - ruff check $(check_dirs) - ruff format --check $(check_dirs) - python utils/check_tests_in_ci.py + $(PYTHON) -m ruff check $(check_dirs) + $(PYTHON) -m ruff format --check $(check_dirs) + $(PYTHON) utils/check_tests_in_ci.py # Format source code automatically style: - ruff check $(check_dirs) --fix - ruff format $(check_dirs) + $(PYTHON) -m ruff check $(check_dirs) --fix + $(PYTHON) -m ruff format $(check_dirs) # Run smolagents tests test: - pytest ./tests/ \ No newline at end of file + $(PYTHON) -m pytest ./tests/