11NAME := avstack
22INSTALL_STAMP := .install.stamp
3- POETRY := $(shell command -v poetry 2> /dev/null)
3+ UV := $(shell command -v uv 2> /dev/null)
44PYFOLDERS := avstack tests third_party/mmdetection/CUSTOM third_party/mmdetection3d/CUSTOM
55.DEFAULT_GOAL := help
66
1717 @echo " Check the Makefile to know exactly what each target is doing."
1818
1919install : $(INSTALL_STAMP )
20- $(INSTALL_STAMP ) : pyproject.toml poetry.lock
21- @if [ -z $( POETRY) ]; then echo " Poetry could not be found. See https://python-poetry.org/docs/" ; exit 2; fi
22- # $(POETRY) install --all-extras
23- $(POETRY ) install
20+ $(INSTALL_STAMP ) : pyproject.toml uv.lock
21+ @if [ -z $( UV) ]; then echo " uv could not be found. See https://docs.astral.sh/uv/" ; exit 2; fi
22+ # $(UV) sync --all-extras
2423 touch $(INSTALL_STAMP )
2524
2625.PHONY : clean
@@ -30,18 +29,18 @@ clean:
3029
3130.PHONY : lint
3231lint : $(INSTALL_STAMP )
33- $(POETRY ) run isort --profile=black --lines-after-imports=2 --check-only $(PYFOLDERS )
34- $(POETRY ) run black --check $(PYFOLDERS ) --diff
35- $(POETRY ) run flake8 --ignore=W503,E501 $(PYFOLDERS )
36- $(POETRY ) run mypy $(PYFOLDERS ) --ignore-missing-imports
37- $(POETRY ) run bandit -r $(NAME ) -s B608
32+ $(UV ) run isort --profile=black --lines-after-imports=2 --check-only $(PYFOLDERS )
33+ $(UV ) run black --check $(PYFOLDERS ) --diff
34+ $(UV ) run flake8 --ignore=W503,E501 $(PYFOLDERS )
35+ $(UV ) run mypy $(PYFOLDERS ) --ignore-missing-imports
36+ $(UV ) run bandit -r $(NAME ) -s B608
3837
3938.PHONY : format
4039format : $(INSTALL_STAMP )
41- $(POETRY ) run autoflake --remove-all-unused-imports -i -r $(PYFOLDERS ) --exclude=__init__.py
42- $(POETRY ) run isort --profile=black --lines-after-imports=2 $(PYFOLDERS )
43- $(POETRY ) run black $(PYFOLDERS )
40+ $(UV ) run autoflake --remove-all-unused-imports -i -r $(PYFOLDERS ) --exclude=__init__.py
41+ $(UV ) run isort --profile=black --lines-after-imports=2 $(PYFOLDERS )
42+ $(UV ) run black $(PYFOLDERS )
4443
4544.PHONY : test
4645test : $(INSTALL_STAMP )
47- $(POETRY ) run pytest ./tests/ --cov-report term-missing --cov-fail-under 0 --cov $(NAME )
46+ $(UV ) run pytest ./tests/ --cov-report term-missing --cov-fail-under 0 --cov $(NAME )
0 commit comments