Skip to content

Latest commit

 

History

History
54 lines (39 loc) · 767 Bytes

README.md

File metadata and controls

54 lines (39 loc) · 767 Bytes

Composer plugin example

Here is a simple example of a composer plugin.

Structure

plugin
├── src
│   └── Plugin.php
├── composer.json
├── composer.lock

Usage

Add require into composer.json

{
  "require": {
    "cslant/composer-plugin-example": "dev-main"
  },
  "repositories": [
    {
      "type": "git",
      "url": "https://github.com/cslant/composer-plugin-example.git"
    }
  ]
}

Run composer command

composer update

Check vendor directory

ls vendor/cslant/composer-plugin-example

Reference

Composer install demo

composer require cslant/composer-plugin-example