-
Notifications
You must be signed in to change notification settings - Fork 22
/
mondrian.php
executable file
·39 lines (33 loc) · 948 Bytes
/
mondrian.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#!/usr/bin/env php
<?php
/*
* Standalone Console
*
* Uses the Symfony Console Component (which is great !)
*/
require_once __DIR__ . '/vendor/autoload.php';
use Trismegiste\Mondrian\Plugin\Application;
use Trismegiste\Mondrian\Command;
$info = json_decode(file_get_contents(__DIR__ . DIRECTORY_SEPARATOR . 'composer.json'));
/*
* Init application
*/
$application = new Application('Mondrian', '1.2');
$application->addCommands(array(
new Command\TypeHintConfig(),
new Command\DigraphCommand(),
new Command\UsedCentralityCommand(),
new Command\DependCentralityCommand(),
new Command\HiddenCouplingCommand(),
new Command\SpaghettiCommand(),
new Command\CyclicCommand(),
new Command\LiskovCommand(),
new Command\ContractorCommand(),
new Command\BadInterfaceCommand(),
new Command\FactoryGenerator()
));
/*
* init plugins
*/
$application->addPlugin($info->extra->plugins);
$application->run();