summaryrefslogtreecommitdiffstats
path: root/Doc/library
diff options
context:
space:
mode:
authorDavid Jones <drj@pobox.com>2019-07-16 14:55:19 (GMT)
committerGregory P. Smith <greg@krypto.org>2019-07-16 14:55:19 (GMT)
commit6a61714cde7037cd9a1bcc11ecccb17fe3081295 (patch)
tree2e74f049d54202aa745690def222d6125ed7d761 /Doc/library
parente8692818afd731c1b7e925c626ac8200b1f1c31e (diff)
downloadcpython-6a61714cde7037cd9a1bcc11ecccb17fe3081295.zip
cpython-6a61714cde7037cd9a1bcc11ecccb17fe3081295.tar.gz
cpython-6a61714cde7037cd9a1bcc11ecccb17fe3081295.tar.bz2
Replace backquote with command substitution in subprocess doc example (GH-13941)
Replace backquotes with POSIXy command substitution in example.
Diffstat (limited to 'Doc/library')
-rw-r--r--Doc/library/subprocess.rst10
1 files changed, 5 insertions, 5 deletions
diff --git a/Doc/library/subprocess.rst b/Doc/library/subprocess.rst
index af33879..7e1e3f9 100644
--- a/Doc/library/subprocess.rst
+++ b/Doc/library/subprocess.rst
@@ -1166,12 +1166,12 @@ In the following examples, we assume that the relevant functions have already
been imported from the :mod:`subprocess` module.
-Replacing /bin/sh shell backquote
-^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+Replacing :program:`/bin/sh` shell command substitution
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.. code-block:: bash
- output=`mycmd myarg`
+ output=$(mycmd myarg)
becomes::
@@ -1182,7 +1182,7 @@ Replacing shell pipeline
.. code-block:: bash
- output=`dmesg | grep hda`
+ output=$(dmesg | grep hda)
becomes::
@@ -1199,7 +1199,7 @@ be used directly:
.. code-block:: bash
- output=`dmesg | grep hda`
+ output=$(dmesg | grep hda)
becomes::