From c27fc68acdd59b0aff90b38acc050702eadd6dad Mon Sep 17 00:00:00 2001 From: Hidde Wieringa Date: Thu, 18 Aug 2016 11:02:25 +0200 Subject: [PATCH] Update controllers.rst Added useful debug commands in the debug documentation Merged two commands to shorten the file Fixed bash -> terminal code blocks Updated the command examples to be a list instead pieces of text with large terminal graphics Revert accidental commit Revert invalid changes This reverts commit 8cf0c854908844d2d7c16d11bb1ac485e44e4f50. Fixed typo's and campitalization of titles --- debug/debugging.rst | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/debug/debugging.rst b/debug/debugging.rst index dacf9eab285..5e50ea9111b 100644 --- a/debug/debugging.rst +++ b/debug/debugging.rst @@ -59,3 +59,29 @@ locations. To avoid problems, you can either tell your IDE to ignore the PHP cache files, or you can change the extension used by Symfony for these files:: $kernel->loadClassCache('classes', '.php.cache'); + +Useful Debugging Commands +------------------------- + +When developing a large application, it can be hard to keep track of all the +different services, routes and translations. Luckily, Symfony has some commands +that can help you visualize and find the information. + +``debug:container`` + Displays information about the contents of the Symfony container for all public + services. To find only those matching a name, append the name as an argument. + +``debug:config`` + Shows all configured bundles, their class and their alias. + +``debug:router`` + Displays information about all configured routes in the application as a + table with the name, method, scheme, host and path for each route. + +``debug:translation `` + Shows a table of the translation key, the domain, the translation and the + fallback translation for all known messages, if translations exist for + the given locale. + +When in doubt how to use a console command, open the help section by appending +the ``--help`` option.