RprtCli/app/rprt.php

23 lines
567 B
PHP
Raw Normal View History

#!/usr/bin/env php
<?php
use Symfony\Component\Console\Application;
2022-05-11 19:43:05 +02:00
use RprtCli\Commands\InvoiceCommand;
use RprtCli\Commands\ReportCommand;
use DI\ContainerBuilder;
require __DIR__ . '/vendor/autoload.php';
$builder = new ContainerBuilder();
$builder->addDefinitions('dependencies.php');
$container = $builder->build();
2021-09-20 01:08:42 +02:00
$application = new Application();
2022-05-11 19:43:05 +02:00
$invoiceCommand = $container->get(InvoiceCommand::class);
$application->add($invoiceCommand);
$reportCommand = $container->get(ReportCommand::class);
$application->add($reportCommand);
$application->run();