Skip to content
Permalink
Browse files

Add lazy loading console commands support

  • Loading branch information...
FVesely authored and f3l1x committed May 16, 2019
1 parent 84c5889 commit 681b4f94858d523ab4ec0afca7e3ede9a150a699
Showing with 12 additions and 3 deletions.
  1. +4 −1 src/Command/HelpCommand.php
  2. +4 −1 src/Command/ListCommand.php
  3. +4 −1 src/Command/RunCommand.php
@@ -9,9 +9,12 @@
class HelpCommand extends Command
{
/** @var string */
protected static $defaultName = 'scheduler:help';
protected function configure(): void
{
$this->setName('scheduler:help')
$this->setName(self::$defaultName)
->setDescription('Print cron syntax');
}
@@ -16,6 +16,9 @@
class ListCommand extends Command
{
/** @var string */
protected static $defaultName = 'scheduler:list';
/** @var IScheduler */
private $scheduler;
@@ -27,7 +30,7 @@ public function __construct(IScheduler $scheduler)
protected function configure(): void
{
$this->setName('scheduler:list')
$this->setName(self::$defaultName)
->setDescription('List all scheduler jobs');
}
@@ -10,6 +10,9 @@
class RunCommand extends Command
{
/** @var string */
protected static $defaultName = 'scheduler:run';
/** @var IScheduler */
private $scheduler;
@@ -21,7 +24,7 @@ public function __construct(IScheduler $scheduler)
protected function configure(): void
{
$this->setName('scheduler:run')
$this->setName(self::$defaultName)
->setDescription('Run scheduler jobs');
}

0 comments on commit 681b4f9

Please sign in to comment.
You can’t perform that action at this time.