Skip to content

Commit 0bde60b

Browse files
dukecat0bhrutledge
andauthored
Normalize command lines in code blocks (#949)
* Remove prompts * Use `code-block:: console` instead of `::` * Use `code-block:: console` instead of `::` & remove prompts * Use code-block:: bash Co-authored-by: Brian Rutledge <brian@bhrutledge.com>
1 parent 0fccca0 commit 0bde60b

4 files changed

Lines changed: 18 additions & 18 deletions

File tree

source/guides/analyzing-pypi-package-downloads.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -272,13 +272,13 @@ number of download for a package with the command ``pypinfo package_name``.
272272

273273
Install `pypinfo`_ using pip.
274274

275-
::
275+
.. code-block:: bash
276276
277277
python -m pip install pypinfo
278278
279279
Usage:
280280

281-
::
281+
.. code-block:: console
282282
283283
$ pypinfo requests
284284
Served from cache: False

source/guides/index-mirrors-and-caches.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ cached copies of :term:`packages <Distribution Package>`:
3737
the requirements using `python -m pip wheel
3838
<https://pip.readthedocs.io/en/latest/reference/pip_wheel.html>`_::
3939

40-
$ python -m pip wheel --wheel-dir=/tmp/wheelhouse SomeProject
41-
$ python -m pip install --no-index --find-links=/tmp/wheelhouse SomeProject
40+
python -m pip wheel --wheel-dir=/tmp/wheelhouse SomeProject
41+
python -m pip install --no-index --find-links=/tmp/wheelhouse SomeProject
4242

4343

4444
Caching with devpi

source/guides/installing-stand-alone-command-line-tools.rst

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -42,14 +42,14 @@ packages, and allows you to safely run the program from anywhere.
4242

4343
Now you can install packages with ``pipx install`` and access the package's entry point(s) from anywhere.
4444

45-
::
45+
.. code-block:: console
4646
4747
$ pipx install PACKAGE
4848
$ ENTRYPOINT_OF_PACKAGE [ARGS]
4949
5050
For example
5151

52-
::
52+
.. code-block:: console
5353
5454
$ pipx install cowsay
5555
installed package cowsay 2.0, Python 3.6.2+
@@ -69,7 +69,7 @@ For example
6969
7070
To see a list of packages installed with pipx and which CLI applications are available, use ``pipx list``.
7171

72-
::
72+
.. code-block:: console
7373
7474
$ pipx list
7575
venvs are in /Users/user/.local/pipx/venvs
@@ -89,10 +89,10 @@ To see a list of packages installed with pipx and which CLI applications are ava
8989
9090
To upgrade or uninstall the package
9191

92-
::
92+
.. code-block:: bash
9393
94-
$ pipx upgrade PACKAGE
95-
$ pipx uninstall PACKAGE
94+
pipx upgrade PACKAGE
95+
pipx uninstall PACKAGE
9696
9797
``pipx`` can be upgraded or uninstalled with pip
9898

@@ -113,21 +113,21 @@ To upgrade or uninstall the package
113113
``pipx`` also allows you to install and run the latest version of a cli tool
114114
in a temporary, ephemeral environment.
115115

116-
::
116+
.. code-block:: bash
117117
118-
$ pipx run PACKAGE [ARGS]
118+
pipx run PACKAGE [ARGS]
119119
120120
For example
121121

122-
::
122+
.. code-block:: bash
123123
124-
$ pipx run cowsay moooo
124+
pipx run cowsay moooo
125125
126126
To see the full list of commands ``pipx`` offers, run
127127

128-
::
128+
.. code-block:: bash
129129
130-
$ pipx --help
130+
pipx --help
131131
132132
You can learn more about ``pipx`` at its homepage,
133133
https://github.com/pypa/pipx.

source/guides/using-testpypi.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,9 @@ Using TestPyPI with Twine
2626
You can upload your distributions to TestPyPI using :ref:`twine` by specifying
2727
the ``--repository`` flag
2828

29-
.. code::
29+
.. code-block:: bash
3030
31-
$ twine upload --repository testpypi dist/*
31+
twine upload --repository testpypi dist/*
3232
3333
You can see if your package has successfully uploaded by navigating to the URL
3434
``https://test.pypi.org/project/<sampleproject>`` where ``sampleproject`` is

0 commit comments

Comments
 (0)