Skip to content

Commit 87caef3

Browse files
committed
Update plugins to be compatible with 2.0 interface
1 parent cdefad9 commit 87caef3

File tree

3 files changed

+50
-2
lines changed

3 files changed

+50
-2
lines changed

composer.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@
1212
"version": "2.1.0",
1313
"require": {
1414
"php": "^7.1",
15-
"composer-plugin-api": "^1.0"
15+
"composer-plugin-api": "^1.0 || ^2.0"
1616
},
1717
"require-dev": {
1818
"phpunit/phpunit": "^7.5",
19-
"composer/composer": "^1.3",
19+
"composer/composer": "^1.3 || ^2.0",
2020
"kint-php/kint": "@stable",
2121
"mediact/testing-suite": "^2.0",
2222
"mikey179/vfsstream": "^1.6"

src/InstallerPlugin.php

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,30 @@ public function activate(Composer $composer, IOInterface $inputOutput): void
5050
{
5151
}
5252

53+
/**
54+
* Remove any hooks from Composer.
55+
*
56+
* @param Composer $composer
57+
* @param IOInterface $io
58+
*
59+
* @return void
60+
*/
61+
public function deactivate(Composer $composer, IOInterface $io): void
62+
{
63+
}
64+
65+
/**
66+
* Prepare the plugin to be uninstalled
67+
*
68+
* @param Composer $composer
69+
* @param IOInterface $io
70+
*
71+
* @return void
72+
*/
73+
public function uninstall(Composer $composer, IOInterface $io): void
74+
{
75+
}
76+
5377
/**
5478
* Get the subscribed events.
5579
*

src/Plugin.php

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,30 @@ public function activate(Composer $composer, IOInterface $inputOutput): void
5656
{
5757
}
5858

59+
/**
60+
* Remove any hooks from Composer.
61+
*
62+
* @param Composer $composer
63+
* @param IOInterface $io
64+
*
65+
* @return void
66+
*/
67+
public function deactivate(Composer $composer, IOInterface $io): void
68+
{
69+
}
70+
71+
/**
72+
* Prepare the plugin to be uninstalled
73+
*
74+
* @param Composer $composer
75+
* @param IOInterface $io
76+
*
77+
* @return void
78+
*/
79+
public function uninstall(Composer $composer, IOInterface $io): void
80+
{
81+
}
82+
5983
/**
6084
* Get the subscribed events.
6185
*

0 commit comments

Comments
 (0)