这个问题基本上是关于composer.json
的正确性以及我们对设置的验证。
我有一个私人作曲家资料库主持人Packages
我在gitlab上有我的PHP代码/包。再次私下托管。
我正在设置magento项目,我的扩展程序位于gitlab和packages
。
设置工作正常。除了Composer没有解决彼此依赖的包/模块的依赖关系。
请注意,根项目具有我的私人仓库的定义。 以下是composer.json(s)
{
"name": "magento/project-community-edition",
"description": "eCommerce Platform for Growth (Community Edition)",
"type": "project",
"version": "2.1.0",
"license": [
"OSL-3.0",
"AFL-3.0"
],
"require": {
"magento/product-community-edition": "2.1.0",
"composer/composer": "@alpha"
},
"require-dev": {
"phpunit/phpunit": "4.1.0",
"squizlabs/php_codesniffer": "1.5.3",
"phpmd/phpmd": "@stable",
"pdepend/pdepend": "2.2.2",
"fabpot/php-cs-fixer": "~1.2",
"lusitanian/oauth": "~0.3 <=0.7.0",
"sebastian/phpcpd": "2.0.0"
},
"config": {
"use-include-path": true
},
"autoload": {
"psr-4": {
"Magento\\Framework\\": "lib/internal/Magento/Framework/",
"Magento\\Setup\\": "setup/src/Magento/Setup/",
"Magento\\": "app/code/Magento/"
},
"psr-0": {
"": "app/code/"
},
"files": [
"app/etc/NonComposerComponentRegistration.php"
]
},
"autoload-dev": {
"psr-4": {
"Magento\\Sniffs\\": "dev/tests/static/framework/Magento/Sniffs/",
"Magento\\Tools\\": "dev/tools/Magento/Tools/",
"Magento\\Tools\\Sanity\\": "dev/build/publication/sanity/Magento/Tools/Sanity/",
"Magento\\TestFramework\\Inspection\\": "dev/tests/static/framework/Magento/TestFramework/Inspection/",
"Magento\\TestFramework\\Utility\\": "dev/tests/static/framework/Magento/TestFramework/Utility/"
}
},
"minimum-stability": "alpha",
"prefer-stable": true,
"repositories": [
{
"type": "composer",
"url": "https://repo.magento.com/"
},
{
"type": "composer",
"url": "https://magerepos.mycompany.com/" # my private repo
}
],
"extra": {
"magento-force": "override"
}
}
{
"name": "mycompany/quickview-backend",
"description": "Backend Module for quickview",
"require": {
"php": "~5.5.0|~5.6.0|~7.0.0",
"magento/module-admin-notification": "100.*"
},
"type": "magento2-module",
"version": "1.0.2",
"license": [
"OSL-3.0",
"AFL-3.0"
],
"autoload": {
"files": [
"registration.php"
],
"psr-4": {
"MyCompany\\Backend\\": ""
}
},
"minimum-stability": "alpha",
"prefer-stable": true
}
{
"name": "mycompany/quickview-frontend",
"description": "Quickview Module Frontend",
"require": {
"php": "~5.5.0|~5.6.0|~7.0.0",
"mycompany/quickview-backend": "dev-master"
},
"type": "magento2-module",
"version": "1.0.1",
"autoload": {
"files": [
"registration.php"
],
"psr-4": {
"MyCompany\\Quickview\\": ""
}
},
"repositories": [
{
"type": "composer",
"url": "https://magerepos.mycompany.com/"
}
],
"minimum-stability": "alpha",
"prefer-stable": true
}
我添加到repositories
的composer.json的minimum-stability
,prefer-stable
,Package Frontend
个节点当作曲家报告无法解析依赖关系的错误时。
首先我尝试如下:
composer require mycompany/quickview-frontend
但它从未奏效我认为可能是稳定性,并且在添加minimum-stability
composer require mycompany/quickview-frontend:dev-master
仍然得到同样的错误:
Your requirements could not be resolved to an installable set of packages.
我理解作曲家不会解析递归存储库,因此我在root composer.json中提到过它。仍然没有运气
还有一件事,所有的包和根项目只有master
分支
你们可以在我出错的地方帮助我吗?