diff --git a/CHANGELOG b/CHANGELOG index 83744edbb..610731e9f 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -11,6 +11,7 @@ where they are not used. - #326: Fix OSError 'Not a directory' when creating env on Jython 2.7.0. Thanks Nick Douma (@LordGaav). +- #585: Add documentation for constraints.txt 2.7.0 ----- diff --git a/CONTRIBUTORS b/CONTRIBUTORS index 84ccf2078..a7a39ae9a 100644 --- a/CONTRIBUTORS +++ b/CONTRIBUTORS @@ -49,3 +49,4 @@ Nick Douma Cyril Roelandt Bartolome Sanchez Salado Laszlo Vasko +Alexander Loechel diff --git a/doc/example/basic.txt b/doc/example/basic.txt index 3f0fa0f1f..d867fb65f 100644 --- a/doc/example/basic.txt +++ b/doc/example/basic.txt @@ -82,20 +82,38 @@ configuration:: .. _multiindex: -depending on requirements.txt +depending on requirements.txt or defining constraints ----------------------------------------------- .. versionadded:: 1.6.1 -(experimental) If you have a ``requirements.txt`` file -you can add it to your ``deps`` variable like this:: +(experimental) If you have a ``requirements.txt`` file or a ``constraints.txt`` file you can add it to your ``deps`` variable like this: + +.. code-block:: ini deps = -rrequirements.txt -All installation commands are executed using ``{toxinidir}`` -(the directory where ``tox.ini`` resides) as the current -working directory. Therefore, the underlying ``pip`` installation -will assume ``requirements.txt`` to exist at ``{toxinidir}/requirements.txt``. +or + +.. code-block:: ini + + deps = -cconstraints.txt + +or + +.. code-block:: ini + + deps = -rrequirements.txt -cconstraints.txt + +All installation commands are executed using ``{toxinidir}`` (the directory where ``tox.ini`` resides) as the current working directory. +Therefore, the underlying ``pip`` installation will assume ``requirements.txt`` or ``constraints.txt`` to exist at ``{toxinidir}/requirements.txt`` or ``{toxinidir}/contrains.txt``. + +This is actually a side effect that all elements of the dependency list is directly passed to ``pip``. + +For more details on ``requirements.txt`` files or ``constraints.txt`` files please see: + +* https://pip.pypa.io/en/stable/user_guide/#requirements-files +* https://pip.pypa.io/en/stable/user_guide/#constraints-files using a different default PyPI url -----------------------------------------------