covex-nn/extra-flex

This package is abandoned and no longer maintained. The author suggests using the covex-nn/environment package instead.

ExtraFlex plugin

Installs: 10 338

Dependents: 0

Suggesters: 0

Security: 0

Stars: 7

Watchers: 3

Forks: 3

Open Issues: 0

Type:composer-plugin

0.3.1 2018-05-23 06:53 UTC

This package is not auto-updated.

Last update: 2019-02-20 19:19:55 UTC


README

Extra-Flex is a composer plugin for Symfony Flex.

Extra-Flex allows to keep recipe for composer package together in the same repository with a package itself.

Extra-Flex allows to install recipe on require command and uninstall on remove command. Also recipe could be applied on demand without requiring a package with additional apply command.

To enable Extra-Flex run composer require covex-nn/extra-flex after composer create-project symfony/skeleton

To include recipe into a package, add extra data to composer.json:

{
    "extra": {
        "recipe-dir": ".flex"     
    }
}

Example

Require covex-nn/extra-flex-foobar and apply recipe immediately:

composer create-project symfony/skeleton .
composer require covex-nn/extra-flex
composer require covex-nn/extra-flex-foobar
composer remove covex-nn/extra-flex-foobar

Apply recipe from covex-nn/extra-flex-foobar without require package:

composer create-project symfony/skeleton .
composer require covex-nn/extra-flex
composer apply covex-nn/extra-flex-foobar 1.0.2
cat composer.json

See composer.json from covex-nn/extra-flex-foobar for details.

Extending Flex

To extend Flex, your composer-plugin could subscribe to one of Extra-Flex events:

  • pre-flex-configurator-install
  • post-flex-configurator-install
  • pre-flex-configurator-unconfigure
  • post-flex-configurator-unconfigure
  • pre-flex-downloader-getRecipes
  • post-flex-downloader-getRecipes