#!/usr/bin/env php <?php use Opdavies\DrupalModuleGenerator\Command\GenerateDrupal7Command; use Opdavies\DrupalModuleGenerator\Service\ModuleNameConverter; use Opdavies\DrupalModuleGenerator\Service\TestNameConverter; use Symfony\Component\Console\Application; use Symfony\Component\Finder\Finder; if (file_exists(__DIR__.'/../../../autoload.php')) { require __DIR__.'/../../../autoload.php'; } else { require __DIR__.'/../vendor/autoload.php'; } $app = new Application('Drupal Module Generator'); $finder = new Finder(); $moduleNameConverter = new ModuleNameConverter(); $testNameConverter = new TestNameConverter(); $app->addCommands([ new GenerateDrupal7Command($finder, $moduleNameConverter, $testNameConverter), ]); $app->run();