The first step in this Advanced Install work-through:
https://docs.backdropcms.org/documentation/advanced-installation
is to run this CLI command:
drush dlb backdrop --path="my-backdrop"
but that command gives this error:
The Drush launcher could not find a Drupal site to operate on. Please do *one* of the following:
- Navigate to any where within your Drupal project and try again.
- Add --root=/path/to/drupal so Drush knows where your site is located.
Any ideas how to get around this?
Comments
I just ran the same drush command inside of a Lando container and it worked fine. Some questions that might help troubleshoot your problem:
1) Where are you trying to set up this Backdrop site with Drush. On your local computer or on a server?
2) Do you have the Backdrop extension for Drush installed?
https://github.com/backdrop-contrib/backdrop-drush-extension
3) If you are working locally (on your home computer or laptop), what are you using for a dev environment (Lando, native tools, MAMP, etc)?
@auxiliaryjoel - In order to use Drush with Backdrop CMS, you do need to install that extension.
https://github.com/backdrop-contrib/backdrop-drush-extension
As it says, make sure that you are running Drush 8. The install instructions for the extension are in the README.
Some related issues:
https://forum.backdropcms.org/forum/issues-installing-drush
https://forum.backdropcms.org/forum/stranded-while-trying-use-drush-inst...
@oadaeh (Jason Flatt).
I mean that it doesn't progress past that first command, as the first command fails with this error:
The Drush launcher could not find a Drupal site to operate on. Please do *one* of the following:
- Navigate to any where within your Drupal project and try again.
- Add --root=/path/to/drupal so Drush knows where your site is located.
@auxiliaryjoel
Do you have Drush 8.x and the Backdrop Drush extension installed? In Zulip you mentioned having trouble getting Drush installed, but that you did have composer running. Does this work?
(hi again by the way)
Okay, so that means that Drush is installed and working.
Is it version 8.x.x? (Execute `drush --version` to find out.)
Did you install the backdrop-drush-extension that @stpaultim mentioned above?