Skip to content

Commit

Permalink
[QuickTour] Use new directory structure
Browse files Browse the repository at this point in the history
  • Loading branch information
wouterj committed Nov 28, 2015
1 parent 215c36d commit c6d436b
Showing 1 changed file with 12 additions and 6 deletions.
18 changes: 12 additions & 6 deletions quick_tour/the_architecture.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,14 @@ but the recommended structure is as follows:

``app/``
The application configuration, templates and translations.
``bin/``
Executable files (e.g. ``bin/console``).
``src/``
The project's PHP code.
``tests/``
Automatic tests (e.g. Unit tests).
``var/``
Generated files (cache, logs, etc.).
``vendor/``
The third-party dependencies.
``web/``
Expand All @@ -30,7 +36,7 @@ stylesheets and JavaScript files. It is also where each :term:`front controller`
lives, such as the production controller shown here::

// web/app.php
require_once __DIR__.'/../app/bootstrap.php.cache';
require_once __DIR__.'/../var/bootstrap.php.cache';
require_once __DIR__.'/../app/AppKernel.php';

use Symfony\Component\HttpFoundation\Request;
Expand Down Expand Up @@ -260,7 +266,7 @@ Symfony applications can contain several configuration files defined in
several formats (YAML, XML, PHP, etc.) Instead of parsing and combining
all those files for each request, Symfony uses its own cache system. In
fact, the application configuration is only parsed for the very first request
and then compiled down to plain PHP code stored in the ``app/cache/``
and then compiled down to plain PHP code stored in the ``var/cache/``
directory.

In the development environment, Symfony is smart enough to update the cache
Expand All @@ -271,10 +277,10 @@ the ``prod`` environment:

.. code-block:: bash
$ php app/console cache:clear --env=prod
$ php bin/console cache:clear --env=prod
When developing a web application, things can go wrong in many ways. The
log files in the ``app/logs/`` directory tell you everything about the requests
log files in the ``var/logs/`` directory tell you everything about the requests
and help you fix the problem quickly.

Using the Command Line Interface
Expand All @@ -288,13 +294,13 @@ Run it without any arguments to learn more about its capabilities:

.. code-block:: bash
$ php app/console
$ php bin/console
The ``--help`` option helps you discover the usage of a command:

.. code-block:: bash
$ php app/console debug:router --help
$ php bin/console debug:router --help
Final Thoughts
--------------
Expand Down

0 comments on commit c6d436b

Please sign in to comment.