| Conditions | 3 |
| Paths | 4 |
| Total Lines | 14 |
| Code Lines | 9 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 47 | public function onPrePatchEvent(PatchEvent $event): void |
||
| 48 | { |
||
| 49 | $config = $this->config; |
||
| 50 | if ($config->get('phpbrew.set_prompt')) { |
||
| 51 | $event->addPatch('.bashrc', 'export PHPBREW_SET_PROMPT=1'); |
||
| 52 | $this->logger->debug('+phpbrew configured <comment>PHPBREW_USE_PROMPT</comment>'); |
||
| 53 | } |
||
| 54 | if ($config->get('phpbrew.rc_enable')) { |
||
| 55 | $event->addPatch('.bashrc', 'export PHPBREW_RC_ENABLE=1'); |
||
| 56 | $this->logger->debug('+phpbrew configured <comment>PHPBREW_RC_ENABLE</comment>'); |
||
| 57 | } |
||
| 58 | |||
| 59 | $phpBrewScript = $config->get('dotfiles.home_dir').'/.phpbrew/bashrc'; |
||
| 60 | $event->addPatch('.bashrc', 'source "'.$phpBrewScript.'"'); |
||
| 61 | } |
||
| 63 |