[9.x] Add option to filter out routes defined in vendor packages in route:list command#41254
Merged
taylorotwell merged 4 commits intolaravel:9.xfrom Feb 28, 2022
amiranagram:route-list-command-filter-out-vendor-routes
Merged
[9.x] Add option to filter out routes defined in vendor packages in route:list command#41254taylorotwell merged 4 commits intolaravel:9.xfrom amiranagram:route-list-command-filter-out-vendor-routes
route:list command#41254taylorotwell merged 4 commits intolaravel:9.xfrom
amiranagram:route-list-command-filter-out-vendor-routes
Conversation
Contributor
Author
|
P.S. Would mocking the whole |
Member
|
I like this feature - just not sure about the |
Contributor
Author
|
Agree @nunomaduro, open to suggestions. |
Contributor
|
@amiranagram how about |
Member
|
Nevermind. Agree that |
Contributor
Author
|
Alright. What do you think about tests? @nunomaduro
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR adds the ability for
route:listcommand to filter out routes defined in vendor (third-party) packages.IMHO, very useful option in projects that have tons of registered routes via third-party packages (Horizon, Nova, Debugbar, etc.).
Tests are missing because I can't figure out a way to mock routes so they show another path other than where I defined them (in the test class). So maybe someone can help me out.
Also let me know if
--except-vendoris not a good option name for the command.Cheers.