@@ -6,19 +6,21 @@ SHELL := /usr/bin/env bash
66
77# This variable contains the first goal that matches any of the listed goals
88# here, else it contains an empty string. The net effect is to filter out
9- # whether this current run of `make` requires a Python virtual environment.
9+ # whether this current run of `make` requires a Python virtual environment
10+ # by checking if any of the given goals requires a virtual environment (all
11+ # except the 'venv' and the various 'clean' and 'nuke' goals do). Note that
12+ # checking for 'upgrade' and 'check' goals includes all of their variations.
1013NEED_VENV := $(or \
14+ $(findstring all,$(MAKECMDGOALS ) ) , \
1115 $(findstring setup,$(MAKECMDGOALS ) ) , \
12- $(findstring upgrade-quiet,$(MAKECMDGOALS ) ) , \
1316 $(findstring upgrade,$(MAKECMDGOALS ) ) , \
14- $(findstring requirements,$(MAKECMDGOALS ) ) , \
1517 $(findstring sbom,$(MAKECMDGOALS ) ) , \
16- $(findstring all,$(MAKECMDGOALS ) ) , \
17- $(findstring quick-check,$(MAKECMDGOALS ) ) , \
18+ $(findstring requirements,$(MAKECMDGOALS ) ) , \
1819 $(findstring check,$(MAKECMDGOALS ) ) , \
1920 $(findstring test,$(MAKECMDGOALS ) ) , \
2021 $(findstring dist,$(MAKECMDGOALS ) ) , \
21- $(findstring docs,$(MAKECMDGOALS ) ) \
22+ $(findstring docs,$(MAKECMDGOALS ) ) , \
23+ $(findstring prune,$(MAKECMDGOALS ) ) , \
2224)
2325ifeq ($(NEED_VENV ) ,)
2426 # None of the current goals requires a virtual environment.
0 commit comments