Prefix Pip commands with python -m in docs

This ensures Pip commands will be executed for the current Python
interpreter and not, say, whichever Python interpreter happens to be
associated with `/usr/local/bin/pip`.
This commit is contained in:
Justin Mayer 2020-08-17 07:04:00 +02:00
commit 16975bc3a2
7 changed files with 16 additions and 16 deletions

View file

@ -7,11 +7,11 @@ Python are not supported.
You can install Pelican via several different methods. The simplest is via
`pip <https://pip.pypa.io/en/stable/>`_::
pip install pelican
python -m pip install pelican
Or, if you plan on using Markdown::
pip install "pelican[markdown]"
python -m pip install "pelican[markdown]"
(Keep in mind that operating systems will often require you to prefix the above
command with ``sudo`` in order to install Pelican system-wide.)
@ -26,7 +26,7 @@ session and create a new virtual environment for Pelican::
source bin/activate
Once the virtual environment has been created and activated, Pelican can be
installed via ``pip install pelican`` as noted above. Alternatively, if you
installed via ``python -m pip install pelican`` as noted above. Alternatively, if you
have the project source, you can install Pelican using the distutils method::
cd path-to-Pelican-source
@ -35,7 +35,7 @@ have the project source, you can install Pelican using the distutils method::
If you have Git installed and prefer to install the latest bleeding-edge
version of Pelican rather than a stable release, use the following command::
pip install -e "git+https://github.com/getpelican/pelican.git#egg=pelican"
python -m pip install -e "git+https://github.com/getpelican/pelican.git#egg=pelican"
Once Pelican is installed, you can run ``pelican --help`` to see basic usage
options. For more detail, refer to the :doc:`Publish<publish>` section.
@ -46,17 +46,17 @@ Optional packages
If you plan on using `Markdown <https://pypi.org/project/Markdown/>`_ as a
markup format, you can install Pelican with Markdown support::
pip install "pelican[markdown]"
python -m pip install "pelican[markdown]"
Or you might need to install it a posteriori::
pip install Markdown
python -m pip install Markdown
Typographical enhancements can be enabled in your settings file, but first the
requisite `Typogrify <https://pypi.org/project/typogrify/>`_ library must be
installed::
pip install typogrify
python -m pip install typogrify
Dependencies
------------
@ -88,7 +88,7 @@ Upgrading
If you installed a stable Pelican release via ``pip`` and wish to upgrade to
the latest stable release, you can do so by adding ``--upgrade``::
pip install --upgrade pelican
python -m pip install --upgrade pelican
If you installed Pelican via distutils or the bleeding-edge method, simply
perform the same step to install the most recent version.