| Conditions | 3 |
| Paths | 7 |
| Total Lines | 27 |
| Code Lines | 14 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 25 | protected function execute (InputInterface $input, OutputInterface $output) |
||
| 26 | { |
||
| 27 | parent::execute($input, $output); |
||
| 28 | |||
| 29 | try |
||
| 30 | { |
||
| 31 | $this->configureBuild($input); |
||
| 32 | $this->website->build(); |
||
| 33 | |||
| 34 | $output->writeln(sprintf("Your site built successfully! It can be found at: %s", |
||
| 35 | $this->website->getConfiguration()->getTargetFolder() . DIRECTORY_SEPARATOR |
||
| 36 | )); |
||
| 37 | } |
||
| 38 | catch (InvalidSyntaxException $e) |
||
| 39 | { |
||
| 40 | $output->writeln(sprintf("Your website failed to build with the following error in file '%s': %s", |
||
| 41 | $e->getPath(), |
||
| 42 | $e->getMessage() |
||
| 43 | )); |
||
| 44 | } |
||
| 45 | catch (\Exception $e) |
||
| 46 | { |
||
| 47 | $output->writeln(sprintf("Your website failed to build with the following error: %s", |
||
| 48 | $e->getMessage() |
||
| 49 | )); |
||
| 50 | } |
||
| 51 | } |
||
| 52 | } |