跳转至

Virtual environment


This uses virtual environments backed by the standard virtualenv tool.

Configuration

The environment plugin name is virtual.

[tool.hatch.envs.<ENV_NAME>]
type = "virtual"
[envs.<ENV_NAME>]
type = "virtual"

Options

Option Default Description
system-packages false Whether or not to give the virtual environment access to the system site-packages directory
python The version of Python to find on your system and subsequently use to create the environment, defaulting to the HATCH_PYTHON environment variable, followed by the first Python executable found along your PATH, followed by the Python executable Hatch is running on. For more information, see the documentation.
env:HATCH_ENV_TYPE_VIRTUAL_PATH An explicit path to the virtual environment

最后更新: August 13, 2022