]> Raphaƫl G. Git Repositories - veranda/blob - bin/console
Fix composer auto-scripts
[veranda] / bin / console
1 #!/usr/bin/env php
2 <?php
3
4 use App\Kernel;
5 use Symfony\Bundle\FrameworkBundle\Console\Application;
6
7 if (!is_dir(dirname(__DIR__).'/vendor')) {
8 throw new LogicException('Dependencies are missing. Try running "composer install".');
9 }
10
11 if (!is_file(dirname(__DIR__).'/vendor/autoload_runtime.php')) {
12 throw new LogicException('Symfony Runtime is missing. Try running "composer require symfony/runtime".');
13 }
14
15 require_once dirname(__DIR__).'/vendor/autoload_runtime.php';
16
17 return function (array $context) {
18 $kernel = new Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG']);
19
20 return new Application($kernel);
21 };