Skip to content

Specifying the supported version of Composer in composer.json #9625

Discussion options

You must be logged in to vote

if you want to force using composer 2, you can add a requirement on composer-runtime-api: ^2. There is no equivalent way to force using composer 1 as there is no composer-runtime-api package in v1.

Depending on composer/composer as a dependency will not lock the version of composer being run. It will install the code of composer in your vendor folder when running composer. But that code installed there won't be used to run composer (that's too late anyway).

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@stof
Comment options

Answer selected by Seldaek
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants