|
|
|
@ -141,6 +141,28 @@ class Application extends BaseApplication
|
|
|
|
|
return $workingDir;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* {@inheritDoc}
|
|
|
|
|
*/
|
|
|
|
|
public function renderException($e, $output)
|
|
|
|
|
{
|
|
|
|
|
try {
|
|
|
|
|
$composer = $this->getComposer(false);
|
|
|
|
|
if ($composer) {
|
|
|
|
|
$config = $composer->getConfig();
|
|
|
|
|
|
|
|
|
|
$minSpaceFree = 1024*1024;
|
|
|
|
|
if ((($df = disk_free_space($dir = $config->get('home'))) !== false && $df < $minSpaceFree)
|
|
|
|
|
|| (($df = disk_free_space($dir = $config->get('vendor-dir'))) !== false && $df < $minSpaceFree)
|
|
|
|
|
) {
|
|
|
|
|
$output->writeln('<error>The disk hosting '.$dir.' is full, this may be the cause of the following exception</error>');
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
} catch (\Exception $e) {}
|
|
|
|
|
|
|
|
|
|
return parent::renderException($e, $output);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* @param bool $required
|
|
|
|
|
* @throws JsonValidationException
|
|
|
|
|