mirror of
https://github.com/opdavies/build-configs.git
synced 2025-01-23 02:27:33 +00:00
26 lines
835 B
PHP
Executable file
26 lines
835 B
PHP
Executable file
#!/usr/bin/env php
|
|
<?php
|
|
|
|
use OliverDaviesLtd\BuildConfigs\Console\Command\BuildConfigurationCommand;
|
|
use OliverDaviesLtd\BuildConfigs\Validator\ConfigurationValidator;
|
|
use Symfony\Component\Console\Application;
|
|
use Symfony\Component\Filesystem\Filesystem;
|
|
use Twig\Environment;
|
|
use Twig\Loader\FilesystemLoader;
|
|
|
|
require __DIR__ . '/../vendor/autoload.php';
|
|
|
|
$filesystem = new Filesystem();
|
|
$twig = new Environment(new FilesystemLoader([__DIR__.'/../templates']));
|
|
$configurationValidator = new ConfigurationValidator();
|
|
|
|
$application = new Application();
|
|
$command = new BuildConfigurationCommand($twig, $filesystem, $configurationValidator);
|
|
|
|
$application->addCommands([
|
|
new BuildConfigurationCommand($twig, $filesystem, $configurationValidator),
|
|
]);
|
|
|
|
$application->setDefaultCommand('build-configs', true);
|
|
$application->run();
|