Laravel套餐:发现决心
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Laravel套餐:发现决心相关的知识,希望对你有一定的参考价值。
我如何从项目层中解析发现包?
composer update
使用包信息加载composer存储库更新依赖项(包括require-dev)无需安装或更新生成优化的自动加载文件IlluminateFoundationComposerScripts::postAutoloadDump
@php artisan package:discover
Discovered Package: fideloper/proxy
Discovered Package: gloudemans/shoppingcart
Discovered Package: htmlmin/htmlmin
Discovered Package: mews/purifier
Discovered Package: rap2hpoutre/laravel-log-viewer
Discovered Package: roumen/sitemap
Discovered Package: laravel/socialite
Discovered Package: spatie/laravel-image-optimizer
Discovered Package: aloha/twilio
Discovered Package: laravel/tinker
Discovered Package: socialiteproviders/manager
Discovered Package: davejamesmiller/laravel-breadcrumbs
Package manifest generated successfully.
Composer.json:
{
"name": "laravel/laravel",
"description": "The Laravel Framework.",
"keywords": ["framework", "laravel"],
"license": "MIT",
"type": "project",
"require": {
"php": ">=7.0.0",
"aloha/twilio": "^3.0",
"davejamesmiller/laravel-breadcrumbs": "^4.2",
"fideloper/proxy": "^3.3",
"gloudemans/shoppingcart": "^2.4",
"golonka/bbcodeparser": "^2.2",
"htmlmin/htmlmin": "^5.0",
"kim/activity": "^1.1",
"laravel/framework": "5.5.*",
"laravel/socialite": "^3.0",
"laravel/tinker": "~1.0",
"mews/purifier": "^2.0",
"rap2hpoutre/laravel-log-viewer": "^0.11.0",
"roumen/sitemap": "^2.7",
"socialiteproviders/vkontakte": "^3.0",
"spatie/laravel-image-optimizer": "^1.1"
},
"require-dev": {
"filp/whoops": "~2.0",
"fzaninotto/faker": "~1.4",
"mockery/mockery": "0.9.*",
"phpunit/phpunit": "~6.0"
},
"autoload": {
"classmap": [
"database/seeds",
"database/factories"
],
"psr-4": {
"App\": "app/"
}
},
"autoload-dev": {
"psr-4": {
"Tests\": "tests/"
}
},
"extra": {
"laravel": {
"dont-discover": [
]
}
},
"scripts": {
"post-root-package-install": [
"@php -r "file_exists('.env') || copy('.env.example', '.env');""
],
"post-create-project-cmd": [
"@php artisan key:generate"
],
"post-autoload-dump": [
"Illuminate\Foundation\ComposerScripts::postAutoloadDump",
"@php artisan package:discover"
]
},
"config": {
"preferred-install": "dist",
"sort-packages": true,
"optimize-autoloader": true
}}
怎么解决这个?我有包裹。但为什么发现写?如何解决发现的包?
答案
如果下一个版本与您项目中的其他库冲突或者您的composer.json
中有确切版本,则无法更新。
Laravel有自己的composer.json
,它描述了那样的库版本(它是我的Laravel 5.4的json):
"symfony/console": "~3.2", // ~3.2 means 3.2 ONLY
"symfony/debug": "~3.2",
"symfony/finder": "~3.2",
"symfony/http-foundation": "~3.2",
是composer.json
统治作曲家。
以上是关于Laravel套餐:发现决心的主要内容,如果未能解决你的问题,请参考以下文章