【发布时间】:2018-04-18 10:50:30
【问题描述】:
我需要在 php 5.6 的环境中使用 jenssegers/blade 包,所以我需要使用Illuminate 5.1(正是这个版本)。在 vendor/jensegers/blade/composer.json 它需要
"require": {
"illuminate/view": "^5.1"
},
执行 composer update 它会下载需要 php 7+ 的最新版Illuminate (5.6.17)。
Laravel 5.1 与 php >= 5.5.9 一起工作,并且应该与Illumina 5.1 相同。
我想强制下载Illuminate 5.1,所以我删除了vendors/lluminate目录并编辑了vendors/jenssegers/blade/composer.json,删除了版本之前的'^':
"require": {
"illuminate/view": "5.1"
}
但是作曲家更新一直在下载:
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 6 installs, 0 updates, 0 removals
- Installing illuminate/contracts (v5.6.17): Loading from cache
- Installing illuminate/support (v5.6.17): Loading from cache
- Installing illuminate/filesystem (v5.6.17): Loading from cache
- Installing illuminate/container (v5.6.17): Loading from cache
- Installing illuminate/events (v5.6.17): Loading from cache
- Installing illuminate/view (v5.6.17): Loading from cache
【问题讨论】:
-
使用 composer install 代替?
-
尝试:将
vendor/laravel/framework/composer.json从"illuminate/view": "self.version"编辑为"illuminate/view": "^5.1" -
使用 composer install 我得到 5.6.17(如 composer update)。我没有供应商/laravel。我正在使用 jessengers/blade 因为我只需要没有 laravel 的刀片。
-
@SandOfVega 从不编辑
vendor中的内容。从不。 -
我知道@NicoHaase。但是在这种情况下没有其他办法。 :|
标签: php laravel laravel-5 composer-php