Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add url option to the core:route command #5172

Merged
merged 4 commits into from Jul 1, 2022
Merged

Add url option to the core:route command #5172

merged 4 commits into from Jul 1, 2022

Conversation

Chi-teck
Copy link
Collaborator

@Chi-teck Chi-teck commented Jun 25, 2022

Motivation

drush route --path is one of may favorite Drush commands. However, it feels a bit boring to manually extract path from URL.

Proposed solution

Add url option. So that the URL copied from the browser address bar can be pasted directly to the command line.

Example:

drush route --url=https://example.com/node/1

@Chi-teck
Copy link
Collaborator Author

@weitzman
Copy link
Member

This is a bit confusing because drush has a global option --uri and that means something similar/overlapping. Maybe just enhance the processing of --path so it can deal with a full url.

@Chi-teck
Copy link
Collaborator Author

Chi-teck commented Jul 1, 2022

Well, yes. Actually when Drupal is installed into a sub-direcotry both --uri and --url options would be needed get to correct result. I've updated the PR to enhance processing of the --path option. The only concern I have is that the path is no longer the right name for that option. I have no idea how to name option that accepts both URL and path.

@weitzman weitzman merged commit 36924fa into drush-ops:11.x Jul 1, 2022
@weitzman
Copy link
Member

weitzman commented Jul 1, 2022

Thanks. IMO option name can remain as is.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants