diff options
author | Stéphane Bidoul <stephane.bidoul@gmail.com> | 2023-02-11 15:14:30 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-02-11 15:14:30 +0100 |
commit | 852deddb9c14afdb780e77ea28c2fa6d29f8c2e1 (patch) | |
tree | 084c3d0f0424b57815c26e8be7688cec2ee02df3 | |
parent | 8b7955d49914144d69e2d2cd840c8f35d60f8d9d (diff) | |
parent | e399d7d4ede3f5fad6a3f58b97dbae532daf5e19 (diff) | |
download | pip-852deddb9c14afdb780e77ea28c2fa6d29f8c2e1.tar.gz |
Merge pull request #11775 from pelson/doc/prefix-warning
Document the limitations of the pip install --prefix argument
-rw-r--r-- | news/11775.doc.rst | 2 | ||||
-rw-r--r-- | src/pip/_internal/commands/install.py | 7 |
2 files changed, 8 insertions, 1 deletions
diff --git a/news/11775.doc.rst b/news/11775.doc.rst new file mode 100644 index 000000000..18274b769 --- /dev/null +++ b/news/11775.doc.rst @@ -0,0 +1,2 @@ +Cross-reference the ``--python`` flag from the ``--prefix`` flag, +and mention limitations of ``--prefix`` regarding script installation. diff --git a/src/pip/_internal/commands/install.py b/src/pip/_internal/commands/install.py index b20aeddf8..f24ef17f9 100644 --- a/src/pip/_internal/commands/install.py +++ b/src/pip/_internal/commands/install.py @@ -156,7 +156,12 @@ class InstallCommand(RequirementCommand): default=None, help=( "Installation prefix where lib, bin and other top-level " - "folders are placed" + "folders are placed. Note that the resulting installation may " + "contain scripts and other resources which reference the " + "Python interpreter of pip, and not that of ``--prefix``. " + "See also the ``--python`` option if the intention is to " + "install packages into another (possibly pip-free) " + "environment." ), ) |