Skip to content

Commit

Permalink
FIx Makefile with Python 3 command names
Browse files Browse the repository at this point in the history
Use `python3` instead of `python`.

Try `pytest-3` if `pytest` is not available.
  • Loading branch information
DimitriPapadopoulos committed Oct 30, 2022
1 parent 458de80 commit 5090410
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ check-dictionaries:
done
@if command -v pytest > /dev/null; then \
pytest codespell_lib/tests/test_dictionary.py; \
elif command -v pytest-3 > /dev/null; then \
pytest-3 codespell_lib/tests/test_dictionary.py; \
else \
echo "Test dependencies not present, install using 'pip install -e \".[dev]\"'"; \
exit 1; \
Expand All @@ -48,13 +50,20 @@ check-manifest:
check-manifest --no-build-isolation

check-distutils:
python setup.py check --restructuredtext --strict
python3 setup.py check --restructuredtext --strict

flake8:
flake8

pytest:
pytest codespell_lib
@if command -v pytest > /dev/null; then \
pytest codespell_lib; \
elif command -v pytest-3 > /dev/null; then \
pytest-3 codespell_lib; \
else \
echo "Test dependencies not present, install using 'pip install -e \".[dev]\"'"; \
exit 1; \
fi

clean:
rm -rf codespell.1

0 comments on commit 5090410

Please sign in to comment.