Loading docs/howto/deployment/wsgi/uwsgi.txt +1 −1 Original line number Diff line number Diff line Loading @@ -24,7 +24,7 @@ The uWSGI wiki describes several `installation procedures`_. Using pip, the Python package manager, you can install any uWSGI version with a single command. For example: .. code-block:: bash .. code-block:: console # Install current stable version. $ sudo pip install uwsgi Loading docs/howto/outputting-pdf.txt +1 −1 Original line number Diff line number Diff line Loading @@ -25,7 +25,7 @@ http://www.reportlab.com/software/opensource/rl-toolkit/download/. The `user guide`_ (not coincidentally, a PDF file) explains how to install it. Alternatively, you can also install it with ``pip``: .. code-block:: bash .. code-block:: console $ sudo pip install reportlab Loading docs/howto/upgrade-version.txt +2 −2 Original line number Diff line number Diff line Loading @@ -52,7 +52,7 @@ might want to set up a new environment with all the dependencies first. Exactly which steps you will need to take depends on your installation process. The most convenient way is to use pip_ with the ``--upgrade`` or ``-U`` flag: .. code-block:: bash .. code-block:: console $ pip install -U Django Loading @@ -74,7 +74,7 @@ warnings are silenced by default. It is useful to turn the warnings on so they are shown in the test output (you can also use the flag if you test your app manually using ``manage.py runserver``): .. code-block:: bash .. code-block:: console $ python -Wall manage.py test Loading docs/intro/overview.txt +1 −1 Original line number Diff line number Diff line Loading @@ -51,7 +51,7 @@ Install it Next, run the Django command-line utility to create the database tables automatically: .. code-block:: bash .. code-block:: console $ python manage.py migrate Loading docs/intro/tutorial01.txt +11 −11 Original line number Diff line number Diff line Loading @@ -15,7 +15,7 @@ It'll consist of two parts: We'll assume you have :doc:`Django installed </intro/install>` already. You can tell Django is installed and which version by running the following command: .. code-block:: bash .. code-block:: console $ python -c "import django; print(django.get_version())" Loading Loading @@ -51,7 +51,7 @@ application-specific settings. From the command line, ``cd`` into a directory where you'd like to store your code, then run the following command: .. code-block:: bash .. code-block:: console $ django-admin.py startproject mysite Loading Loading @@ -197,7 +197,7 @@ Some of these applications makes use of at least one database table, though, so we need to create the tables in the database before we can use them. To do that, run the following command: .. code-block:: bash .. code-block:: console $ python manage.py migrate Loading @@ -224,7 +224,7 @@ The development server Let's verify your Django project works. Change into the outer :file:`mysite` directory, if you haven't already, and run the following commands: .. code-block:: bash .. code-block:: console $ python manage.py runserver Loading Loading @@ -262,7 +262,7 @@ It worked! it as a command-line argument. For instance, this command starts the server on port 8080: .. code-block:: bash .. code-block:: console $ python manage.py runserver 8080 Loading @@ -270,7 +270,7 @@ It worked! listen on all public IPs (useful if you want to show off your work on other computers), use: .. code-block:: bash .. code-block:: console $ python manage.py runserver 0.0.0.0:8000 Loading Loading @@ -312,7 +312,7 @@ imported as its own top-level module, rather than a submodule of ``mysite``. To create your app, make sure you're in the same directory as :file:`manage.py` and type this command: .. code-block:: bash .. code-block:: console $ python manage.py startapp polls Loading Loading @@ -441,7 +441,7 @@ look like this: Now Django knows to include the ``polls`` app. Let's run another command: .. code-block:: bash .. code-block:: console $ python manage.py makemigrations polls Loading Loading @@ -471,7 +471,7 @@ schema automatically - that's called :djadmin:`migrate`, and we'll come to it in moment - but first, let's see what SQL that migration would run. The :djadmin:`sqlmigrate` command takes migration names and returns their SQL: .. code-block:: bash .. code-block:: console $ python manage.py sqlmigrate polls 0001 Loading Loading @@ -541,7 +541,7 @@ your project without making migrations or touching the database. Now, run :djadmin:`migrate` again to create those model tables in your database: .. code-block:: bash .. code-block:: console $ python manage.py migrate Operations to perform: Loading Loading @@ -581,7 +581,7 @@ Playing with the API Now, let's hop into the interactive Python shell and play around with the free API Django gives you. To invoke the Python shell, use this command: .. code-block:: bash .. code-block:: console $ python manage.py shell Loading Loading
docs/howto/deployment/wsgi/uwsgi.txt +1 −1 Original line number Diff line number Diff line Loading @@ -24,7 +24,7 @@ The uWSGI wiki describes several `installation procedures`_. Using pip, the Python package manager, you can install any uWSGI version with a single command. For example: .. code-block:: bash .. code-block:: console # Install current stable version. $ sudo pip install uwsgi Loading
docs/howto/outputting-pdf.txt +1 −1 Original line number Diff line number Diff line Loading @@ -25,7 +25,7 @@ http://www.reportlab.com/software/opensource/rl-toolkit/download/. The `user guide`_ (not coincidentally, a PDF file) explains how to install it. Alternatively, you can also install it with ``pip``: .. code-block:: bash .. code-block:: console $ sudo pip install reportlab Loading
docs/howto/upgrade-version.txt +2 −2 Original line number Diff line number Diff line Loading @@ -52,7 +52,7 @@ might want to set up a new environment with all the dependencies first. Exactly which steps you will need to take depends on your installation process. The most convenient way is to use pip_ with the ``--upgrade`` or ``-U`` flag: .. code-block:: bash .. code-block:: console $ pip install -U Django Loading @@ -74,7 +74,7 @@ warnings are silenced by default. It is useful to turn the warnings on so they are shown in the test output (you can also use the flag if you test your app manually using ``manage.py runserver``): .. code-block:: bash .. code-block:: console $ python -Wall manage.py test Loading
docs/intro/overview.txt +1 −1 Original line number Diff line number Diff line Loading @@ -51,7 +51,7 @@ Install it Next, run the Django command-line utility to create the database tables automatically: .. code-block:: bash .. code-block:: console $ python manage.py migrate Loading
docs/intro/tutorial01.txt +11 −11 Original line number Diff line number Diff line Loading @@ -15,7 +15,7 @@ It'll consist of two parts: We'll assume you have :doc:`Django installed </intro/install>` already. You can tell Django is installed and which version by running the following command: .. code-block:: bash .. code-block:: console $ python -c "import django; print(django.get_version())" Loading Loading @@ -51,7 +51,7 @@ application-specific settings. From the command line, ``cd`` into a directory where you'd like to store your code, then run the following command: .. code-block:: bash .. code-block:: console $ django-admin.py startproject mysite Loading Loading @@ -197,7 +197,7 @@ Some of these applications makes use of at least one database table, though, so we need to create the tables in the database before we can use them. To do that, run the following command: .. code-block:: bash .. code-block:: console $ python manage.py migrate Loading @@ -224,7 +224,7 @@ The development server Let's verify your Django project works. Change into the outer :file:`mysite` directory, if you haven't already, and run the following commands: .. code-block:: bash .. code-block:: console $ python manage.py runserver Loading Loading @@ -262,7 +262,7 @@ It worked! it as a command-line argument. For instance, this command starts the server on port 8080: .. code-block:: bash .. code-block:: console $ python manage.py runserver 8080 Loading @@ -270,7 +270,7 @@ It worked! listen on all public IPs (useful if you want to show off your work on other computers), use: .. code-block:: bash .. code-block:: console $ python manage.py runserver 0.0.0.0:8000 Loading Loading @@ -312,7 +312,7 @@ imported as its own top-level module, rather than a submodule of ``mysite``. To create your app, make sure you're in the same directory as :file:`manage.py` and type this command: .. code-block:: bash .. code-block:: console $ python manage.py startapp polls Loading Loading @@ -441,7 +441,7 @@ look like this: Now Django knows to include the ``polls`` app. Let's run another command: .. code-block:: bash .. code-block:: console $ python manage.py makemigrations polls Loading Loading @@ -471,7 +471,7 @@ schema automatically - that's called :djadmin:`migrate`, and we'll come to it in moment - but first, let's see what SQL that migration would run. The :djadmin:`sqlmigrate` command takes migration names and returns their SQL: .. code-block:: bash .. code-block:: console $ python manage.py sqlmigrate polls 0001 Loading Loading @@ -541,7 +541,7 @@ your project without making migrations or touching the database. Now, run :djadmin:`migrate` again to create those model tables in your database: .. code-block:: bash .. code-block:: console $ python manage.py migrate Operations to perform: Loading Loading @@ -581,7 +581,7 @@ Playing with the API Now, let's hop into the interactive Python shell and play around with the free API Django gives you. To invoke the Python shell, use this command: .. code-block:: bash .. code-block:: console $ python manage.py shell Loading