基于laravel5.5\5.6\5.x安装laravel-ide-helper失败的解决方法
1、如图安装laravel-ide-helper失败的案列:
laravel-ide-helper提示错误的信息显示:
Your requirements could not be resolved to an installable set of packages.
Problem 1
- barryvdh/laravel-ide-helper 2.12.x-dev is an alias of barryvdh/laravel-ide-helper dev-master and thus requires it to be installed too.
- barryvdh/laravel-ide-helper[dev-master, v2.12.0, ..., v2.12.2] require illuminate/console ^8 || ^9 -> found illuminate/console[v8.0.0, ..., 8.x-dev, v9.0.0-beta.1, ..., 9.x-dev] but these were not loaded, likely because it conflicts with another require.
- Root composer.json requires barryvdh/laravel-ide-helper ^2.12 -> satisfiable by barryvdh/laravel-ide-helper[v2.12.0, v2.12.1, v2.12.2, 2.12.x-dev (alias of dev-master)].
Installation failed, reverting ./composer.json and ./composer.lock to their original content.
2、原因及解决方案: 由于laravel更新至8.x的版本,利用命令安装时,为默认安装2.2的版本,与框架中的信息有冲突,选择安装其它的版本排除干扰。
选择其它版本
composer require --dev barryvdh/laravel-ide-helper 2.8
正确显示状态: 安装ide-helper剩余其它操作:
|