Skip to content

Commit 9f7552a

Browse files
committed
sort bundles in config:dump-reference command
This backports #17495 to the `2.3` branch.
1 parent b34048b commit 9f7552a

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Command/ConfigDumpReferenceCommand.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,11 @@ protected function execute(InputInterface $input, OutputInterface $output)
6666

6767
if (empty($name)) {
6868
$output->writeln('Available registered bundles with their extension alias if available:');
69+
70+
usort($bundles, function($bundleA, $bundleB) {
71+
return strcmp($bundleA->getName(), $bundleB->getName());
72+
});
73+
6974
foreach ($bundles as $bundle) {
7075
$extension = $bundle->getContainerExtension();
7176
$output->writeln($bundle->getName().($extension ? ': '.$extension->getAlias() : ''));

0 commit comments

Comments
 (0)