Currently pretty much every external linter has copy-pasted the following code:
```lang=php
public function getVersion() {
list($stdout) = execx('%C --version', $this->getExecutableCommand());
$matches = null;
if (!preg_match('/^v(?P<version>\d+\.\d+\.\d+)$/', $stdout, $matches)) {
return null;
}
return $matches['version'];
}
```
We can reduce the boilerplate code here by providing a simpler interface consisting of `getVersionFlags` and `parseVersionOutput`.