Skip to content

cslant/composer-plugin-example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

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