Does anyone know why Drush doesn't recognize the Drupal 7 installation when I run
It gives me the following error message.
Command cache-rebuild requires Drupal core version 8+ to run.
drush status and
drush -d give me the right root and right configuration.
I installed Drush with
composer require "drush/drush": "7.x-dev".