platformsh/legacy-cli

drush "Command is not defined" (due to incorrect quoting)

Closed this issue · 4 comments

Previously, I was able to do this:
platform drush "cr -l mymultisite"

On 3.49.1, if I try and run the same command, I get this:
Command "cr -l mymultisite" is not defined.

I'm assuming this got broken in: 5a3ab4d

Happy to change my syntax if there is another way to do this.

Actually, I think more than just multisite is affected. Even the example command is not working for me:
platform drush user-login --mail=name@example.com
The "--mail" option does not exist.

platform --environment=develop drush 'user-login --mail=name@example.com'
Command "user-login --mail=name@example.com" is not defined.

There is a workaround for your syntax before #861 can be released - use -- before the drush command, unquoted:

platform drush -- cr -l mymultisite
platform --environment=develop drush -- user-login --mail=name@example.com

Great thanks. Might be good to get some test coverage on this if possible?

It would be good yes... for now it's fixed in version 3.49.2 (platform up to update)