Skip to content

Commit

Permalink
app/console -> bin/console
Browse files Browse the repository at this point in the history
  • Loading branch information
wouterj committed Nov 28, 2015
1 parent af97ce1 commit 8794a4d
Show file tree
Hide file tree
Showing 11 changed files with 40 additions and 40 deletions.
2 changes: 1 addition & 1 deletion book/bundles.rst
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ generating a basic bundle skeleton:

.. code-block:: bash
$ php app/console generate:bundle --namespace=Acme/TestBundle
$ php bin/console generate:bundle --namespace=Acme/TestBundle
The bundle skeleton generates a basic controller, template and routing
resource that can be customized. You'll learn more about Symfony's command-line
Expand Down
6 changes: 3 additions & 3 deletions book/configuration.rst
Original file line number Diff line number Diff line change
Expand Up @@ -122,13 +122,13 @@ FrameworkBundle configuration:

.. code-block:: bash
$ app/console config:dump-reference FrameworkBundle
$ bin/console config:dump-reference FrameworkBundle
The extension alias (configuration key) can also be used:

.. code-block:: bash
$ app/console config:dump-reference framework
$ bin/console config:dump-reference framework
.. note::

Expand Down Expand Up @@ -177,7 +177,7 @@ cached files and allow them to rebuild:

.. code-block:: bash
$ php app/console cache:clear --env=prod --no-debug
$ php bin/console cache:clear --env=prod --no-debug
.. note::

Expand Down
2 changes: 1 addition & 1 deletion book/controller.rst
Original file line number Diff line number Diff line change
Expand Up @@ -532,7 +532,7 @@ console command:

.. code-block:: bash
$ php app/console debug:container
$ php bin/console debug:container
.. versionadded:: 2.6
Prior to Symfony 2.6, this command was called ``container:debug``.
Expand Down
24 changes: 12 additions & 12 deletions book/doctrine.rst
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ for you:

.. code-block:: bash
$ php app/console doctrine:database:create
$ php bin/console doctrine:database:create
.. sidebar:: Setting up the Database to be UTF8

Expand All @@ -128,8 +128,8 @@ for you:

.. code-block:: bash
$ php app/console doctrine:database:drop --force
$ php app/console doctrine:database:create
$ php bin/console doctrine:database:drop --force
$ php bin/console doctrine:database:create
There's no way to configure these defaults inside Doctrine, as it tries to be
as agnostic as possible in terms of environment configuration. One way to solve
Expand Down Expand Up @@ -227,7 +227,7 @@ just a simple PHP class.

.. code-block:: bash
$ php app/console doctrine:generate:entity
$ php bin/console doctrine:generate:entity
.. index::
single: Doctrine; Adding mapping metadata
Expand Down Expand Up @@ -392,7 +392,7 @@ a regular PHP class, you need to create getter and setter methods (e.g. ``getNam

.. code-block:: bash
$ php app/console doctrine:generate:entities AppBundle/Entity/Product
$ php bin/console doctrine:generate:entities AppBundle/Entity/Product
This command makes sure that all the getters and setters are generated
for the ``Product`` class. This is a safe command - you can run it over and
Expand Down Expand Up @@ -434,10 +434,10 @@ mapping information) of a bundle or an entire namespace:
.. code-block:: bash
# generates all entities in the AppBundle
$ php app/console doctrine:generate:entities AppBundle
$ php bin/console doctrine:generate:entities AppBundle
# generates all entities of bundles in the Acme namespace
$ php app/console doctrine:generate:entities Acme
$ php bin/console doctrine:generate:entities Acme
.. note::

Expand All @@ -459,7 +459,7 @@ in your application. To do this, run:

.. code-block:: bash
$ php app/console doctrine:schema:update --force
$ php bin/console doctrine:schema:update --force
.. tip::

Expand Down Expand Up @@ -852,7 +852,7 @@ used earlier to generate the missing getter and setter methods:

.. code-block:: bash
$ php app/console doctrine:generate:entities AppBundle
$ php bin/console doctrine:generate:entities AppBundle
Next, add a new method - ``findAllOrderedByName()`` - to the newly generated
repository class. This method will query for all the ``Product`` entities,
Expand Down Expand Up @@ -906,7 +906,7 @@ you can let Doctrine create the class for you.

.. code-block:: bash
$ php app/console doctrine:generate:entity --no-interaction \
$ php bin/console doctrine:generate:entity --no-interaction \
--entity="AppBundle:Category" \
--fields="name:string(255)"
Expand Down Expand Up @@ -1063,7 +1063,7 @@ methods for you:

.. code-block:: bash
$ php app/console doctrine:generate:entities AppBundle
$ php bin/console doctrine:generate:entities AppBundle
Ignore the Doctrine metadata for a moment. You now have two classes - ``Category``
and ``Product`` with a natural one-to-many relationship. The ``Category``
Expand Down Expand Up @@ -1092,7 +1092,7 @@ table, and ``product.category_id`` column, and new foreign key:

.. code-block:: bash
$ php app/console doctrine:schema:update --force
$ php bin/console doctrine:schema:update --force
.. note::

Expand Down
10 changes: 5 additions & 5 deletions book/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ browsing the project directory and executing this command:
.. code-block:: bash
$ cd my_project_name/
$ php app/console server:run
$ php bin/console server:run
Then, open your browser and access the ``http://localhost:8000/`` URL to see the
Welcome Page of Symfony:
Expand Down Expand Up @@ -195,7 +195,7 @@ server with the ``server:stop`` command:

.. code-block:: bash
$ php app/console server:stop
$ php bin/console server:stop
Checking Symfony Application Configuration and Setup
----------------------------------------------------
Expand Down Expand Up @@ -265,7 +265,7 @@ If there are any issues, correct them now before moving on.
If none of the previous methods work for you, change the umask so that the
cache and log directories will be group-writable or world-writable (depending
if the web server user and the command line user are in the same group or not).
To achieve this, put the following line at the beginning of the ``app/console``,
To achieve this, put the following line at the beginning of the ``bin/console``,
``web/app.php`` and ``web/app_dev.php`` files::

umask(0002); // This will let the permissions be 0775
Expand Down Expand Up @@ -306,7 +306,7 @@ several minutes to complete.

.. code-block:: bash
$ php app/console security:check
$ php bin/console security:check
A good security practice is to execute this command regularly to be able to
update or replace compromised dependencies as soon as possible.
Expand All @@ -331,7 +331,7 @@ of the Symfony Installer anywhere in your system:
c:\projects\> php symfony demo
Once downloaded, enter into the ``symfony_demo/`` directory and run the PHP's
built-in web server executing the ``php app/console server:run`` command. Access
built-in web server executing the ``php bin/console server:run`` command. Access
to the ``http://localhost:8000`` URL in your browser to start using the Symfony
Demo application.

Expand Down
4 changes: 2 additions & 2 deletions book/page_creation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -544,11 +544,11 @@ by changing one option in this configuration file. To find out how, see the
:doc:`Configuration Reference </reference/index>` section.

Or, to get a big example dump of all of the valid configuration under a key,
use the handy ``app/console`` command:
use the handy ``bin/console`` command:

.. code-block:: bash
$ app/console config:dump-reference framework
$ bin/console config:dump-reference framework
There's a lot more power behind Symfony's configuration system, including
environments, imports and parameters. To learn all of it, see the
Expand Down
6 changes: 3 additions & 3 deletions book/routing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1393,7 +1393,7 @@ the command by running the following from the root of your project.

.. code-block:: bash
$ php app/console debug:router
$ php bin/console debug:router
.. versionadded:: 2.6
Prior to Symfony 2.6, this command was called ``router:debug``.
Expand All @@ -1415,14 +1415,14 @@ the route name after the command:

.. code-block:: bash
$ php app/console debug:router article_show
$ php bin/console debug:router article_show
Likewise, if you want to test whether a URL matches a given route, you can
use the ``router:match`` console command:

.. code-block:: bash
$ php app/console router:match /blog/my-latest-post
$ php bin/console router:match /blog/my-latest-post
This command will print which route the URL matches.

Expand Down
2 changes: 1 addition & 1 deletion book/security.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1363,7 +1363,7 @@ security vulnerability in your installed dependencies:

.. code-block:: bash
$ php app/console security:check
$ php bin/console security:check
A good security practice is to execute this command regularly to be able to
update or replace compromised dependencies as soon as possible. Internally,
Expand Down
6 changes: 3 additions & 3 deletions book/service_container.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1147,7 +1147,7 @@ console. To show all services and the class for each service, run:

.. code-block:: bash
$ php app/console debug:container
$ php bin/console debug:container
.. versionadded:: 2.6
Prior to Symfony 2.6, this command was called ``container:debug``.
Expand All @@ -1156,7 +1156,7 @@ By default, only public services are shown, but you can also view private servic

.. code-block:: bash
$ php app/console debug:container --show-private
$ php bin/console debug:container --show-private
.. note::

Expand All @@ -1170,7 +1170,7 @@ its id:

.. code-block:: bash
$ php app/console debug:container my_mailer
$ php bin/console debug:container my_mailer
Learn more
----------
Expand Down
8 changes: 4 additions & 4 deletions book/templating.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1211,7 +1211,7 @@ should use the ``parent()`` Twig function to include everything from the ``style
block of the base template.

You can also include assets located in your bundles' ``Resources/public`` folder.
You will need to run the ``php app/console assets:install target [--symlink]``
You will need to run the ``php bin/console assets:install target [--symlink]``
command, which moves (or symlinks) files into the correct location. (target
is by default "web").

Expand Down Expand Up @@ -1391,7 +1391,7 @@ to create it). You're now free to customize the template.
.. caution::

If you add a template in a new location, you *may* need to clear your
cache (``php app/console cache:clear``), even if you are in debug mode.
cache (``php bin/console cache:clear``), even if you are in debug mode.

This logic also applies to base bundle templates. Suppose also that each
template in AcmeBlogBundle inherits from a base template called
Expand Down Expand Up @@ -1641,10 +1641,10 @@ console command:
.. code-block:: bash
# You can check by filename:
$ php app/console lint:twig app/Resources/views/article/recent_list.html.twig
$ php bin/console lint:twig app/Resources/views/article/recent_list.html.twig
# or by directory:
$ php app/console lint:twig app/Resources/views
$ php bin/console lint:twig app/Resources/views
.. _template-formats:

Expand Down
10 changes: 5 additions & 5 deletions book/translation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,7 @@ For more options, see :ref:`component-translator-message-catalogs`.

.. code-block:: bash
$ php app/console cache:clear
$ php bin/console cache:clear
.. _book-translation-fallback:

Expand Down Expand Up @@ -815,7 +815,7 @@ To inspect all messages in the ``fr`` locale for the AcmeDemoBundle, run:

.. code-block:: bash
$ php app/console debug:translation fr AcmeDemoBundle
$ php bin/console debug:translation fr AcmeDemoBundle
You will get this output:

Expand Down Expand Up @@ -856,15 +856,15 @@ By default all domains are inspected, but it is possible to specify a single dom

.. code-block:: bash
$ php app/console debug:translation en AcmeDemoBundle --domain=messages
$ php bin/console debug:translation en AcmeDemoBundle --domain=messages
When bundles have a lot of messages, it is useful to display only the unused
or only the missing messages, by using the ``--only-unused`` or ``--only-missing`` switches:

.. code-block:: bash
$ php app/console debug:translation en AcmeDemoBundle --only-unused
$ php app/console debug:translation en AcmeDemoBundle --only-missing
$ php bin/console debug:translation en AcmeDemoBundle --only-unused
$ php bin/console debug:translation en AcmeDemoBundle --only-missing
Summary
-------
Expand Down

2 comments on commit 8794a4d

@andrzej-aa
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm going through the Symfony 3.0 book and at the step when I had to install symfony demo I encountered a problem. There is no bin/console file. It is still in the app directory.

@wouterj
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@andrzej-aa a fix for that is already submitted and will be online soon for the articles explicitely relating to the demo application.

As for the book, the Symfony demo doesn't use symfony 3 yet. The solution is to either read the 2.8 book documentation or use another application than the Symfony demo (e.g. the Standard Edition).

Please sign in to comment.