diff options
Diffstat (limited to 'docs/tutorials')
| -rw-r--r-- | docs/tutorials/wiki2/authorization.rst | 2 | ||||
| -rw-r--r-- | docs/tutorials/wiki2/basiclayout.rst | 2 | ||||
| -rw-r--r-- | docs/tutorials/wiki2/definingmodels.rst | 24 | ||||
| -rw-r--r-- | docs/tutorials/wiki2/installation.rst | 8 |
4 files changed, 16 insertions, 20 deletions
diff --git a/docs/tutorials/wiki2/authorization.rst b/docs/tutorials/wiki2/authorization.rst index 933c37f94..e43519ac9 100644 --- a/docs/tutorials/wiki2/authorization.rst +++ b/docs/tutorials/wiki2/authorization.rst @@ -14,7 +14,7 @@ anyone with access to the server to view pages. We will also add a login page and a logout link on all the pages. The login page will be shown when a user is denied -access to any of the views that require a permission, instead of +access to any of the views that require permission, instead of a default "403 Forbidden" page. We will implement the access control with the following steps: diff --git a/docs/tutorials/wiki2/basiclayout.rst b/docs/tutorials/wiki2/basiclayout.rst index 763deaa32..e8874784c 100644 --- a/docs/tutorials/wiki2/basiclayout.rst +++ b/docs/tutorials/wiki2/basiclayout.rst @@ -97,7 +97,7 @@ with the prefix ``/static`` (by virtue of the first argument to ``add_static_view``). This will serve up static resources for us from within the ``static`` directory of our ``tutorial`` package, in this case, via ``http://localhost:6543/static/`` and below (by virtue of the second argument -to add_static_view). With this declaration, we're saying that any URL that +to ``add_static_view``). With this declaration, we're saying that any URL that starts with ``/static`` should go to the static view; any remainder of its path (e.g. the ``/foo`` in ``/static/foo``) will be used to compose a path to a static file resource, such as a CSS file. diff --git a/docs/tutorials/wiki2/definingmodels.rst b/docs/tutorials/wiki2/definingmodels.rst index 2148582f1..dca6238dd 100644 --- a/docs/tutorials/wiki2/definingmodels.rst +++ b/docs/tutorials/wiki2/definingmodels.rst @@ -31,7 +31,7 @@ following: (The highlighted lines are the ones that need to be changed.) -The first thing we've done is to do is remove the stock ``MyModel`` class +The first thing we've done is remove the stock ``MyModel`` class from the generated ``models.py`` file. The ``MyModel`` class is only a sample and we're not going to use it. @@ -77,25 +77,15 @@ following: (Only the highlighted lines need to be changed.) -Reinitializing the Database ---------------------------- +Installing the Project and re-initializing the Database +------------------------------------------------------- + +Redo the steps in :ref:`installing_project_in_dev_mode`. Because our model has changed, in order to reinitialize the database, we need to rerun the ``initialize_tutorial_db`` command to pick up the changes you've made -to both the models.py file and to the initializedb.py file. From the root of the -``tutorial`` project, directory execute the following commands. - -On UNIX: - -.. code-block:: text - - $ ../bin/initialize_tutorial_db development.ini - -On Windows: - -.. code-block:: text - - c:\pyramidtut\tutorial> ..\Scripts\initialize_tutorial_db development.ini +to both the models.py file and to the initializedb.py file. +See :ref:`initialize_db_wiki2` for instructions. Success will look something like this:: diff --git a/docs/tutorials/wiki2/installation.rst b/docs/tutorials/wiki2/installation.rst index 572bffcab..9fa01d513 100644 --- a/docs/tutorials/wiki2/installation.rst +++ b/docs/tutorials/wiki2/installation.rst @@ -66,6 +66,9 @@ On Windows: startup problems, try putting both the virtualenv and the project into directories that do not contain spaces in their paths. + +.. _installing_project_in_dev_mode: + Installing the Project in "Development Mode" ============================================ @@ -159,7 +162,7 @@ On Windows: .. code-block:: text - c:\pyramidtut\tutorial> ..\Scripts\nosetests --cover-package=tutorial ^ + c:\pyramidtut\tutorial> ..\Scripts\nosetests --cover-package=tutorial \ --cover-erase --with-coverage If successful, you will see output something like this:: @@ -181,6 +184,9 @@ If successful, you will see output something like this:: Looks like our package doesn't quite have 100% test coverage. + +.. _initialize_db_wiki2: + Initializing the Database ========================= |
