mirror of
https://github.com/shlinkio/shlink.git
synced 2025-02-25 18:45:27 -06:00
Created the console application via a factory
This commit is contained in:
8
bin/cli
8
bin/cli
@@ -1,16 +1,10 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
use Acelaya\UrlShortener\CliCommands\GenerateShortcodeCommand;
|
||||
use Acelaya\UrlShortener\CliCommands\ResolveUrlCommand;
|
||||
use Interop\Container\ContainerInterface;
|
||||
use Symfony\Component\Console\Application as CliApp;
|
||||
|
||||
/** @var ContainerInterface $container */
|
||||
$container = include __DIR__ . '/../config/container.php';
|
||||
|
||||
$app = new CliApp();
|
||||
$app->addCommands([
|
||||
$container->get(GenerateShortcodeCommand::class),
|
||||
$container->get(ResolveUrlCommand::class),
|
||||
]);
|
||||
$app = $container->get(CliApp::class);
|
||||
$app->run();
|
||||
|
||||
Reference in New Issue
Block a user