From 534ac4829764f317cf2fbc4a18354fcc998c1425 Mon Sep 17 00:00:00 2001 From: Carlton Gibson Date: Thu, 9 Feb 2023 16:48:46 +0100 Subject: Refs #34140 -- Applied rst code-block to non-Python examples. Thanks to J.V. Zammit, Paolo Melchiorre, and Mariusz Felisiak for reviews. --- docs/intro/tutorial02.txt | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'docs/intro/tutorial02.txt') diff --git a/docs/intro/tutorial02.txt b/docs/intro/tutorial02.txt index b37d0c036b..e01975aeed 100644 --- a/docs/intro/tutorial02.txt +++ b/docs/intro/tutorial02.txt @@ -381,7 +381,9 @@ We're using this instead of simply typing "python", because :file:`manage.py` sets the :envvar:`DJANGO_SETTINGS_MODULE` environment variable, which gives Django the Python import path to your :file:`mysite/settings.py` file. -Once you're in the shell, explore the :doc:`database API `:: +Once you're in the shell, explore the :doc:`database API `: + +.. code-block:: pycon >>> from polls.models import Choice, Question # Import the model classes we just wrote. @@ -468,7 +470,9 @@ you aren't familiar with time zone handling in Python, you can learn more in the :doc:`time zone support docs `. Save these changes and start a new Python interactive shell by running -``python manage.py shell`` again:: +``python manage.py shell`` again: + +.. code-block:: pycon >>> from polls.models import Choice, Question -- cgit v1.3