UPDATE:
My tech support fixed and explained the following, which I don’t yet fully understand, but am posting here for anyone else who might experience this type issue.
There were two issues.
- the repository seemed to be missing. composer.json doesn’t mention your Git URLs but did have a few others listed. I added yours:
"repositories": [
{
"type": "git",
"url": "https://github.com/acquia/mc-cs-plugin-sparkpost.git"
},
{
"type": "git",
"url": "https://github.com/mautic/FOSOAuthServerBundle.git"
},
{
"type": "git",
"url": "https://github.com/mautic/SpBundle.git"
},
{
"type": "git",
"url": "https://github.com/mautic/SymfonyBridgeBundle.git"
}
],
- This brought us back to the PHP version error:
- ts-navghane/sparkpost-plugin dev-main requires php >=8.0.0 which does not match your installed version 7.3.33.
php
is aliased to php8.0 binary in .bashrc, however composer is its own executable and won’t use this alias. You can get around that by running php to run composer as following:
php $(which composer) require ts-navghane/sparkpost-plugin
In order to keep this problem at bay in the future, I have added a new alias for composer:
# User specific aliases and functions
alias php='/usr/local/php80/bin/php'
alias composer='/usr/local/php80/bin/php /usr/local/bin/composer'