composer安装magento2出现不兼容问题

5.37K 浏览M2安装设置composer m2

composer安装magento2出现不兼容问题

root@VM-4-6-ubuntu:~# composer create-project --repository-url=https://repo.magento.com/ magento/project-community-edition gfjg
Do not run Composer as root/super user! See https://getcomposer.org/root for details
Continue as root/super user [yes]? yes
Creating a "magento/project-community-edition" project at "./gfjg"
Installing magento/project-community-edition (2.4.1)
- Installing magento/project-community-edition (2.4.1): Extracting archive
Created project in /root/gfjg
Loading composer repositories with package information
Updating dependencies
Your requirements could not be resolved to an installable set of packages.

Problem 1
- Root composer.json requires magento/composer-root-update-plugin ~1.0 -> satisfiable by magento/composer-root-update-plugin[1.0.0].
- magento/composer-root-update-plugin 1.0.0 requires composer-plugin-api ^1.0 -> found composer-plugin-api[2.0.0] but it does not match the constraint.
Problem 2
- Root composer.json requires dealerdirect/phpcodesniffer-composer-installer ^0.5.0 -> satisfiable by dealerdirect/phpcodesniffer-composer-installer[v0.5.0].
- dealerdirect/phpcodesniffer-composer-installer v0.5.0 requires composer-plugin-api ^1.0 -> found composer-plugin-api[2.0.0] but it does not match the constraint.
Problem 3
- laminas/laminas-dependency-plugin[1.0.0, ..., 1.0.4] require composer-plugin-api ^1.1 -> found composer-plugin-api[2.0.0] but it does not match the constraint.
- magento/product-community-edition 2.4.1 requires laminas/laminas-dependency-plugin ^1.0 -> satisfiable by laminas/laminas-dependency-plugin[1.0.0, ..., 1.0.4].
- Root composer.json requires magento/product-community-edition 2.4.1 -> satisfiable by magento/product-community-edition[2.4.1].

You are using Composer 2, which some of your plugins seem to be incompatible with. Make sure you update your plugins or report a plugin-issue to ask them to support Composer 2.

0

你当前安装magento使用的是composer2   但magento尚未支持composer2  请将你的composer降级到composer1.10版本  再去安装即可

0
您正在查看1个回答中的1个,单击此处查看所有回答。