我的网站是用Drupal 8.3.2构建的。我想更新到Drupal8.9.x,但我不想移动到Drupal9.x。我运行了以下命令。
composer update drupal/core-recommended:8.9 --with-dependencies我收到了这些错误。该站点使用PHP 7.3.33。
无法在http://repo.packagist.org中加载包centreon/centreon :无法解析版本约束优化-浏览器-配置-dev:无效版本字符串“优化-浏览器-配置-dev”
我试着安装centreon/centreon,但是没有软件包。
有人能帮我解决这个问题吗?
这是用于站点的composer.json文件的内容。
{
"name": "drupal/drupal",
"description": "Drupal is an open source content management platform powering millions of websites and applications.",
"type": "project",
"license": "GPL-2.0+",
"require": {
"composer/installers": "^1.9",
"wikimedia/composer-merge-plugin": "^1.4"
},
"replace": {
"drupal/core": "^8.3"
},
"minimum-stability": "dev",
"prefer-stable": true,
"config": {
"preferred-install": "dist",
"autoloader-suffix": "Drupal8"
},
"extra": {
"_readme": [
"By default Drupal loads the autoloader from ./vendor/autoload.php.",
"To change the autoloader you can edit ./autoload.php.",
"This file specifies the packages.drupal.org repository.",
"You can read more about this composer repository at:",
"https://www.drupal.org/node/2718229"
],
"merge-plugin": {
"include": [
"core/composer.json"
],
"recurse": false,
"replace": false,
"merge-extra": false
},
"installer-paths": {
"core": ["type:drupal-core"],
"modules/contrib/{$name}": ["type:drupal-module"],
"profiles/contrib/{$name}": ["type:drupal-profile"],
"themes/contrib/{$name}": ["type:drupal-theme"],
"drush/contrib/{$name}": ["type:drupal-drush"],
"modules/custom/{$name}": ["type:drupal-custom-module"],
"themes/custom/{$name}": ["type:drupal-custom-theme"]
}
},
"autoload": {
"psr-4": {
"Drupal\\Core\\Composer\\": "core/lib/Drupal\Core/Composer"
}
},
"scripts": {
"pre-autoload-dump": "Drupal\\Core\\Composer\\Composer::preAutoloadDump",
"post-autoload-dump": [
"Drupal\\Core\\Composer\\Composer::ensureHtaccess"
],
"post-package-install": "Drupal\\Core\\Composer\\Composer::vendorTestCodeCleanup",
"post-package-update": "Drupal\\Core\\Composer\\Composer::vendorTestCodeCleanup"
},
"repositories": [
{
"type": "composer",
"url": "https://packages.drupal.org/8"
}
]
}发布于 2022-03-15 13:36:47
我遵循这些步骤来解决问题。
Step 1:将Composer降级到1.10.9
作曲家自我更新1.10.9
Step 2:在命令下运行
作曲家要求drupal/病理自动:^1.6
Step 3:在命令下运行
composer remove -dev webflo/drupal-core-require dev
Step 4:在命令下运行
编写器要求--使用依赖项更新drupal/core:^8.8 symfony/finder:^3.4 symfony/文件系统:^3.4
Step 5:在命令下运行
编写器要求--dev -具有依赖项的更新- drupal/core-dev:^8.8 symfony/调试:^3.4
命令6:在Step 下面运行
编写器删除-n symfony/finder symfony/文件系统symfony/debug
Step 7:在命令下运行
钻井updb
Step 8:在命令下运行
钻钻铬
Step 9:更新setings.php
在Drupal8.8.0中,同步目录是在$settings而不是$config_directories中定义的,因此应该更新Settings.php文件。
更改如下:
$config_directories = 'foo/bar';
至
$settings = 'foo/bar';
https://drupal.stackexchange.com/questions/310186
复制相似问题