I have been tasked with updating my code shop’s long-abandoned Drupal 7 codebase to the most recent Drupal core, in order to bring in the latest security fixes (it’s currently using v7.67). But all the knowledge I had about how to use drush seems to now be completely worthless.
What is this “composer” thing that it keeps complaining about? We never used anything like that back when we were still developing this Drupal 7 project (we abandoned PHP and switched to Python/Django a few years ago). I tried installing Drush through
composer require drush/drush, which worked (and dumped a load of new code into my repo for some reason…). But even though I’m running it in the root of my repo, it says this:
! (NOTE) Drupal root not found. Pass --root or a @siteAlias in order to see Drupal-specific commands.
When I pass the root folder name via –root, it says the same thing. Thus, my old strategy of just running
drush up drupal, which worked dozens of times in the past, no longer works.
Could someone who understands how Drush works these days explain to me how I can use it to update my codebase? Or maybe there’s a way to install an old version of Drush that can actually understand my repo’s layout? That’d be even better.