Skip to content

Commit

Permalink
Merge pull request #2871 from webknjaz/maintenance/docs-pip-editable-…
Browse files Browse the repository at this point in the history
…v21.1

Document that pip works with editable `setup.cfg`
  • Loading branch information
jaraco authored Nov 12, 2021
2 parents 8ab7799 + ba39e18 commit 8c3aa84
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 9 deletions.
4 changes: 4 additions & 0 deletions changelog.d/2871.doc.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Added a note to the docs that it is possible to install
``setup.py``-less projects in editable mode with :doc:`pip v21.1+
<pip:index>`, only having ``setup.cfg`` and ``pyproject.toml`` in
project root -- by :user:`webknjaz`
2 changes: 2 additions & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -171,3 +171,5 @@
towncrier_draft_include_empty = False

extensions += ['jaraco.tidelift']

intersphinx_mapping['pip'] = 'https://pip.pypa.io/en/latest', None
19 changes: 10 additions & 9 deletions docs/userguide/quickstart.rst
Original file line number Diff line number Diff line change
Expand Up @@ -186,17 +186,18 @@ For more details, see :doc:`datafiles`

Development mode
================
``setuptools`` allows you to install a package without copying any files
to your interpreter directory (e.g. the ``site-packages`` directory). This
allows you to modify your source code and have the changes take effect without
you having to rebuild and reinstall. This is currently incompatible with
PEP 517 and therefore it requires a ``setup.py`` script with the following
content::

import setuptools
setuptools.setup()
.. tip::

Prior to :ref:`pip v21.1 <pip:v21-1>`, a ``setup.py`` script was
required to be compatible with development mode. With late
versions of pip, any project may be installed in this mode.

Then::
``setuptools`` allows you to install a package without copying any files
to your interpreter directory (e.g. the ``site-packages`` directory).
This allows you to modify your source code and have the changes take
effect without you having to rebuild and reinstall.
Here's how to do it::

pip install --editable .

Expand Down

0 comments on commit 8c3aa84

Please sign in to comment.