diff --git a/src/Composer/Command/RequireCommand.php b/src/Composer/Command/RequireCommand.php index 10522aee7..e32abdc1e 100644 --- a/src/Composer/Command/RequireCommand.php +++ b/src/Composer/Command/RequireCommand.php @@ -64,6 +64,11 @@ EOT return 1; } + if (!is_writable($file)) { + $output->writeln(''.$file.' is not writable.'); + + return 1; + } $dialog = $this->getHelperSet()->get('dialog');