theofidry/composer-inheritance-plugin

Composer 插件,用于合并多个子 composer.json 文件

资助包维护!
theofidry

安装次数: 93,173

依赖者: 0

建议者: 0

安全: 0

星标: 28

关注者: 5

分支: 3

公开问题: 0

类型:composer-plugin

v1.2.0 2021-10-11 06:37 UTC

This package is auto-updated.

Last update: 2024-09-11 12:41:01 UTC


README

Package version Build Status License

Wikimedia composer-merge-plugin 的观点性版本,用于与 bamarni/composer-bin-plugin 配对使用。

使用方法

如果您熟悉 bamarni/composer-bin-plugin,您知道可以轻松管理多个命名空间,而不会影响项目依赖。然而,有一个问题:您 vendor-bin 目录中的 composer.json 文件完全与项目根目录的 composer.json 文件隔离。通过 wikimedia/composer-merge-plugin 可以改变这一点。这个库预先配置了这个插件,以便更方便地使用。

实时示例: https://github.com/nelmio/alice

/nelmio-alice-project
├── composer.json <-- uses bamarni/composer-bin-plugin to manage vendor-bin
├── composer.lock
├── vendor/
└── vendor-bin/
    ├── laravel
    |   ├── composer.json <-- uses theofidry/composer-inheritance-plugin to
    |   |                     inherit from the root `composer.json` and add
    |   |                     dependencies related to Laravel to test the
    |   |                     Laravel bridge
    |   ├── composer.lock
    |   └── vendor/
    └── symfony
        ├── composer.json <-- uses theofidry/composer-inheritance-plugin to
        |                     inherit from the root `composer.json` and add
        |                     dependencies related to Symfony to test the
        |                     Symfony bridge
        ├── composer.lock
        └── vendor/