Implement minor shortcut for PhpStorm DI resolution.
This commit is contained in:
parent
0edb34358f
commit
cd3ce3dad0
|
@ -0,0 +1,21 @@
|
|||
<?php
|
||||
|
||||
namespace PHPSTORM_META {
|
||||
|
||||
override(
|
||||
\Psr\Container\ContainerInterface::get(0),
|
||||
map(
|
||||
[
|
||||
'' => '@',
|
||||
]
|
||||
)
|
||||
);
|
||||
override(
|
||||
\DI\Container::get(0),
|
||||
map(
|
||||
[
|
||||
'' => '@',
|
||||
]
|
||||
)
|
||||
);
|
||||
}
|
|
@ -177,7 +177,6 @@ class AppFactory
|
|||
$di = $app->getContainer();
|
||||
$routeCollector = $app->getRouteCollector();
|
||||
|
||||
/** @var Environment $environment */
|
||||
$environment = $di->get(Environment::class);
|
||||
|
||||
// Use the PHP-DI Bridge's action invocation helper.
|
||||
|
@ -207,7 +206,6 @@ class AppFactory
|
|||
{
|
||||
$di = $app->getContainer();
|
||||
|
||||
/** @var EventDispatcher $dispatcher */
|
||||
$dispatcher = $di->get(EventDispatcher::class);
|
||||
$dispatcher->dispatch(new Event\BuildRoutes($app));
|
||||
}
|
||||
|
|
|
@ -26,10 +26,12 @@ class SetupCommand extends CommandAbstract
|
|||
$io->title(__('AzuraCast Setup'));
|
||||
$io->writeln(__('Welcome to AzuraCast. Please wait while some key dependencies of AzuraCast are set up...'));
|
||||
|
||||
$io->listing([
|
||||
__('Environment: %s', ucfirst($environment->getAppEnvironment())),
|
||||
__('Installation Method: %s', $environment->isDocker() ? 'Docker' : 'Ansible'),
|
||||
]);
|
||||
$io->listing(
|
||||
[
|
||||
__('Environment: %s', ucfirst($environment->getAppEnvironment())),
|
||||
__('Installation Method: %s', $environment->isDocker() ? 'Docker' : 'Ansible'),
|
||||
]
|
||||
);
|
||||
|
||||
if ($update) {
|
||||
$io->note(__('Running in update mode.'));
|
||||
|
@ -41,7 +43,6 @@ class SetupCommand extends CommandAbstract
|
|||
}
|
||||
}
|
||||
|
||||
/** @var EntityManagerInterface $em */
|
||||
$em = $di->get(EntityManagerInterface::class);
|
||||
$conn = $em->getConnection();
|
||||
|
||||
|
@ -49,9 +50,13 @@ class SetupCommand extends CommandAbstract
|
|||
$io->section(__('Running Database Migrations'));
|
||||
|
||||
$conn->ping();
|
||||
$this->runCommand($output, 'migrations:migrate', [
|
||||
'--allow-no-migration' => true,
|
||||
]);
|
||||
$this->runCommand(
|
||||
$output,
|
||||
'migrations:migrate',
|
||||
[
|
||||
'--allow-no-migration' => true,
|
||||
]
|
||||
);
|
||||
|
||||
$io->newLine();
|
||||
$io->section(__('Generating Database Proxy Classes'));
|
||||
|
@ -97,16 +102,20 @@ class SetupCommand extends CommandAbstract
|
|||
$io->newLine();
|
||||
|
||||
if ($update) {
|
||||
$io->success([
|
||||
__('AzuraCast is now updated to the latest version!'),
|
||||
]);
|
||||
$io->success(
|
||||
[
|
||||
__('AzuraCast is now updated to the latest version!'),
|
||||
]
|
||||
);
|
||||
} else {
|
||||
$public_ip = $acCentral->getIp(false);
|
||||
|
||||
$io->success([
|
||||
__('AzuraCast installation complete!'),
|
||||
__('Visit %s to complete setup.', 'http://' . $public_ip),
|
||||
]);
|
||||
$io->success(
|
||||
[
|
||||
__('AzuraCast installation complete!'),
|
||||
__('Visit %s to complete setup.', 'http://' . $public_ip),
|
||||
]
|
||||
);
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
|
Loading…
Reference in New Issue