| Conditions | 3 |
| Paths | 4 |
| Total Lines | 13 |
| Code Lines | 9 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 17 | protected function sqliteEnv() |
||
| 18 | { |
||
| 19 | passthru('sed -i \'s/^DB_/#DB_/g\' .env ', $error); |
||
| 20 | if ($error !== 0) { |
||
| 21 | $this->output->writeln('<error>Error commenting DB_ entries in .env file </error>'); |
||
| 22 | } |
||
| 23 | passthru('sed -i \'s/.*DB_HOST.*/DB_CONNECTION=sqlite\n&/\' .env', $error); |
||
| 24 | if ($error !== 0) { |
||
| 25 | $this->output->writeln('<error>Error adding DB_CONNECTION=sqlite to .env file </error>'); |
||
| 26 | } else { |
||
| 27 | $this->output->writeln('.env file updated successfully'); |
||
| 28 | } |
||
| 29 | } |
||
| 30 | } |
||
| 31 |