weaverryan / the-open-source-list

Ryan's ongoing list of things that he things he'd love someone (or himself) to do in the open source world
12 stars 1 forks source link

Add search to debug:router #5

Open weaverryan opened 8 years ago

weaverryan commented 8 years ago

The debug:container command has a search (e.g. bin/console debug:container foo). The same should be done for debug:router.

voronkovich commented 8 years ago

@weaverryan, I think it's better to remove the search feature from the debug:container and just use the pipe and grep: php app/console debug:router | grep homepage

bocharsky-bw commented 8 years ago

The bin/console debug:container foo allows to chose a service name from matched list by entering its ordinal number in order to see explicit information about selected service. This way we don't need to enter the exact name of the service, that could be a bit hard to remember and write (for example, my_super_cool_bundle.twig.extension.my_very_cool_service).

In a case of debug:router, I need to know the exact route name to see explicit info about it. So I need to use grep command to find its exact name first, copy it, and then to use this found name in the next command to see a more detailed info about this route.

I'm :+1: to have a search for debug:router because with this feature you type less and debug faster.

BTW, I think it would be fine if the debug commands consistent with each other and have the same behaviour.

voronkovich commented 8 years ago

@bocharsky-bw, I didn't know about this feature, I always used grep. Thanks for the explanation. :+1: for this proposal

aitboudad commented 8 years ago

I've been working on this feature but it was rejected (see https://github.com/symfony/symfony/pull/14810)

weaverryan commented 8 years ago

Hmm, that's interesting since you modeled it pretty much exactly from symfony/symfony#11339 for the container, which I find really useful (especially in trainings).

I just commented on there - thanks for noting this!