Skip to content

Commit

Permalink
minor #11627 [FrameworkBundle] [TwigBundle] Move debug commands to de…
Browse files Browse the repository at this point in the history
…bug namespace (matthieuauger)

This PR was merged into the 2.6-dev branch.

Discussion
----------

[FrameworkBundle] [TwigBundle] Move debug commands to debug namespace

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | yes
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT

Instead of having several namespaces with only one debug command (container:debug, event-dispatcher:debug), move all these debug commands to a new **debug** namespace.

Related to #10388 (comment)

I don't how to tag these aliases as deprecated as there are only here for backward compatibility.
The renaming should also be done in the Swiftmailer Bundle.

Commits
-------

fd0e229 Move debug commands to debug namespace
  • Loading branch information
nicolas-grekas committed Aug 13, 2014
2 parents 3baea1f + fd0e229 commit 9680c35
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,10 @@ class ConfigDebugCommand extends AbstractConfigCommand
protected function configure()
{
$this
->setName('config:debug')
->setName('debug:config')
->setAliases(array(
'config:debug',
))
->setDefinition(array(
new InputArgument('name', InputArgument::OPTIONAL, 'The Bundle name or the extension alias'),
))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,10 @@ class ContainerDebugCommand extends ContainerAwareCommand
protected function configure()
{
$this
->setName('container:debug')
->setName('debug:container')
->setAliases(array(
'container:debug',
))
->setDefinition(array(
new InputArgument('name', InputArgument::OPTIONAL, 'A service name (foo)'),
new InputOption('show-private', null, InputOption::VALUE_NONE, 'Used to show public *and* private services'),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,10 @@ public function isEnabled()
protected function configure()
{
$this
->setName('router:debug')
->setName('debug:router')
->setAliases(array(
'router:debug',
))
->setDefinition(array(
new InputArgument('name', InputArgument::OPTIONAL, 'A route name'),
new InputOption('show-controllers', null, InputOption::VALUE_NONE, 'Show assigned controllers in overview'),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,10 @@ class TranslationDebugCommand extends ContainerAwareCommand
protected function configure()
{
$this
->setName('translation:debug')
->setName('debug:translation')
->setAliases(array(
'translation:debug',
))
->setDefinition(array(
new InputArgument('locale', InputArgument::REQUIRED, 'The locale'),
new InputArgument('bundle', InputArgument::REQUIRED, 'The bundle name'),
Expand Down
5 changes: 4 additions & 1 deletion src/Symfony/Bundle/TwigBundle/Command/DebugCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,10 @@ class DebugCommand extends ContainerAwareCommand
protected function configure()
{
$this
->setName('twig:debug')
->setName('debug:twig')
->setAliases(array(
'twig:debug',
))
->setDefinition(array(
new InputArgument('filter', InputArgument::OPTIONAL, 'Show details for all entries matching this filter'),
new InputOption('format', null, InputOption::VALUE_REQUIRED, 'Output format: text or json', 'text'),
Expand Down

0 comments on commit 9680c35

Please sign in to comment.