laravel/laravel的composer.json

name: The name of the package. It consists of vendor name and project name, separated by /

description: A short description of the package. Usually this is just one line long

keywords: An array of keywords that the package is related to. These can be used for searching and filtering

license: The license of the package

type: The type of the package, Package types are used for custom installation logic.
project: This denotes a project rather than a library. For example application shells like the Symfony

require: Lists packages required by this package

require-dev: Lists packages required for developing this package, or running tests, etc. The dev requirements of the root package are installed by default

autoload: Autoload mapping for a PHP autoloader.
Currently PSR-0 autoloading, PSR-4 autoloading, classmap generation and files includes are supported.

PSR-4: Under the psr-4 key you define a mapping from namespaces to paths, relative to the package root. Namespace prefixes must end in \\

Classmap:The classmap references are all combined, during install/update, into a single key => value array which may be found in the generated file vendor/composer/autoload_classmap.php

autoload-dev: This section allows to define autoload rules for development purposes
Classes needed to run the test suite should not be included in the main autoload rules to avoid polluting the autoloader in production and when other people use your package as a dependency

scripts: Composer allows you to hook into various parts of the installation process through the use of scripts
post-root-package-install: occurs after the root package has been installed, during the create-project command
post-create-project-cmd: occurs after the create-project command has been executed
post-install-cmd: occurs after the install command has been executed with a lock file present
post-update-cmd: occurs after the update command has been executed, or after the install command has been executed without a lock file present

config: A set of configuration options. It is only used for projects
preferred-install: This option allows you to set the install method Composer will prefer to use

时间: 2024-11-03 22:17:09

laravel/laravel的composer.json的相关文章

composer通过composer.json下载laravel包----barryvdh/laravel-debugbar

1.去Packagist网站https://packagist.org/packages/barryvdh/laravel-debugbar#dev-master找到 右边是版本,选择想要的版本,只需要复制后面的版本号就可以比如  2.2.x-dev 2. 在laravel框架里面的composer.json上加上这一行,然后到cmd命令行里面.composer update  然后就下载下来了 3. 去app.php里面加入上图那行然后保存,就可以去页面上看了.Barryvdh\Debugba

安装 Laravel 遇到问题?你需要更新 composer.json 文件

<pre class="markdown-doc"> ~~~ url 转载自 https://9iphp.com/web/laravel/laravel-install-fail-update-composer.html~~~在使用最新版 Composer 安装 Laravel 的时候,你可能会遇到下面的问题而安装失败: ~~~ shell$ php composer.phar create-project --prefer-dist laravel/laravel blo

laravel中引入composer安装在vendor中的第三方应用

一.安装第三方应用 方法一:使用命令行安装第三方(已phpword为例): composer require phpoffce/phpword ^v0.14.* 方法二: 修改主项目composer.json文件: require": { "php": ">=7.1.3", "fideloper/proxy": "~4.0", "laravel/framework": "5.6.*

Laravel安装和composer安装

下载地址:https://getcomposer.org/download/ 他会自动找到你的php目录,如果没有记得手动修改  一直点下一步,即可. 如果安装不成功,可能是之前安装过composer没有卸载干净,其实composer就是一些php文件,找到他们删除即可. composer remove:移除composer composer config -l -g | grep "home|dir" -E:找到对应的目录   where composer:找到对应的安装位置 通过

laravel/laravel和laravel/framework有何区别?

在安装laravel的时候,我们一般是download github上的laravel/laravel,随后执行composer install,在这个过程中,你会发现composer其中的一项工作是 安装laravel/framework到vendor目录中,(为了看清楚这个过程,我们可以执行composer install --dry-run模拟安装dependency的过程).那么laravel/laravel和laravel/framework到底是什么关系呢? (master)*$ c

composer.json:项目安装

基本用法 基本用法 安装 composer.json:项目安装 关于 require Key 包名称 包版本 下一个重要版本(波浪号运算符) 稳定性 安装依赖包 composer.lock - 锁文件 Packagist 自动加载 安装 安装 Composer,你只需要下载 composer.phar 可执行文件. curl -sS https://getcomposer.org/installer | php 详细请查看 简介 章节. 要检查 Composer 是否正常工作,只需要通过 php

[Laravel] Laravel的基本数据库操作部分

[laravel] laravel的数据库配置 找到程序目录结构下.env文件 配置基本的数据库连接信息 DB_HOST=127.0.0.1 DB_PORT=3306 DB_DATABASE=blog DB_USERNAME=root DB_PASSWORD=root 修改完.env文件需要重启服务 [laravel] laravel的数据库入门 控制器中导入DB数据库操作类,use DB 使用DB类的静态方法select来查询数据库,DB::select(),参数:sql语句,参数值数组 例如

laravel开发之-composer安装(windows)

1 在https://getcomposer.org/download/中下载composer.exe 2 选择php.exe安装composer 3 cmd命令框中输入composer.查看是否安装成功 4 打开https://pkg.phpcomposer.com/选择中国镜像,安装全局配置文件 5 安装成功后,输入命令:composer global require "laravel/installer",将laravel项目下载到本地 6 输入命令:composer globa

[laravel] Laravel - composer install

#composer installLoading composer repositories with package informationUpdating dependencies (including require-dev) - Installing zgldh/workerboy (v0.15) Downloading: 100% - Installing vlucas/phpdotenv (v2.3.0) Downloading: 100% - Installing symfony/