From d017cb9c6166506e8cb3386dcf4281ba30be80fd Mon Sep 17 00:00:00 2001 From: dereuromark Date: Wed, 6 Sep 2017 01:34:15 +0200 Subject: [PATCH] use generatorTasks key --- config/app.dist.php | 3 +++ docs/Generator.md | 2 +- src/Generator/TaskCollection.php | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/config/app.dist.php b/config/app.dist.php index 3f60d3b0..e22e18ae 100644 --- a/config/app.dist.php +++ b/config/app.dist.php @@ -15,5 +15,8 @@ ], // Always add annotations even if not needed 'preemptive' => false, + // For meta file generator + 'generatorTasks' => [ + ], ], ]; diff --git a/docs/Generator.md b/docs/Generator.md index 19aecec8..4e8d1654 100644 --- a/docs/Generator.md +++ b/docs/Generator.md @@ -42,7 +42,7 @@ class MyTask implements TaskInterface { Then add it to the config: ```php 'IdeHelper' => [ - 'tasks' => [ + 'generatorTasks' => [ App\Generator\Task\MyTask::class, ], ], diff --git a/src/Generator/TaskCollection.php b/src/Generator/TaskCollection.php index 36db92b6..fc7a14b3 100644 --- a/src/Generator/TaskCollection.php +++ b/src/Generator/TaskCollection.php @@ -25,7 +25,7 @@ class TaskCollection { */ public function __construct(array $tasks = []) { if (!$tasks) { - $configTasks = (array)Configure::read('IdeHelper.tasks'); + $configTasks = (array)Configure::read('IdeHelper.generatorTasks'); $tasks = array_merge($this->defaultTasks, $configTasks); }