for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Task\TaskBundle\Command;
use Symfony\Component\Console\Command\Command;
use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Output\OutputInterface;
use Task\SchedulerInterface;
/**
* Run pending tasks.
*
* @author @wachterjohannes <[email protected]>
*/
class RunCommand extends Command
{
* @var SchedulerInterface
private $scheduler;
public function __construct(SchedulerInterface $scheduler)
parent::__construct('task:run');
$this->scheduler = $scheduler;
}
* {@inheritdoc}
protected function configure()
$this->setDescription('Run pending tasks');
protected function execute(InputInterface $input, OutputInterface $output)
$this->scheduler->run();