File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -7,6 +7,9 @@ SHELL := bash
77PACKAGE_NAME := package
88PACKAGE_VERSION := $(shell python -c $$'try: import $(PACKAGE_NAME ) ; print($(PACKAGE_NAME ) .__version__) ;\nexcept: print("unknown");')
99
10+ # If a PYTHON environment variable exists then use that, else define it here.
11+ PYTHON ?= python3.13
12+
1013# This variable contains the first goal that matches any of the listed goals
1114# here, else it contains an empty string. The net effect is to filter out
1215# whether this current run of `make` requires a Python virtual environment
6972 if [ -d .venv/ ]; then \
7073 echo " Found an inactive Python virtual environment, please activate or nuke it" && exit 1; \
7174 fi
72- if [ -z " ${PYTHON} " ]; then \
73- echo " Creating virtual environment in .venv/ for python3.13" ; \
74- python3.13 -m venv --upgrade-deps --prompt . .venv; \
75- else \
76- echo " Creating virtual environment in .venv/ for ${PYTHON} " ; \
77- ${PYTHON} -m venv --upgrade-deps --prompt . .venv; \
78- fi
75+ echo " Creating virtual environment in .venv/ for ${PYTHON} " ; \
76+ ${PYTHON} -m venv --upgrade-deps --prompt . .venv; \
7977 touch .venv/pip.conf
8078
8179# Set up a newly created virtual environment. Note: pre-commit uses the
You can’t perform that action at this time.
0 commit comments