Closed kaby76 closed 2 years ago
The solution is here. I'm not sure where I read the syntax with the "@"-sign, but it is wrong. The right code is:
composer require antlr/antlr4-php-runtime:0.5.1
# or
composer require antlr/antlr4-php-runtime:0.5.0
# or
composer require antlr/antlr4-php-runtime:0.6.0
Nevertheless, it should be explained in the readme.md, especially for a specific branch, e.g., 4.9.3 of the Antlr tool is incompatible with version 0.6.0 of antlr/antlr-php-runtime, so the instructions are wrong. Small details really matter.
I'm trying to install version 0.5.1 of this library. I can do
and the package is installed.
However, if I do
I get this:
In order to install the specific version, I have to:
Create a composer.json file with
{ "require": { "antlr/antlr4-php-runtime": "0.5.1" } }
Invoke via a shell
composer install
.The instructions say nothing of this, and in fact, describe using the "composer require" command, not "composer install", and do not require a composer.json file to be created. It took many hours to figure out how to work around this mess.
How do I use composer require to install 0.5.1?
Please explain.