Skip to content

Commit

Permalink
Show default value instead of optional, refs #9181
Browse files Browse the repository at this point in the history
  • Loading branch information
Seldaek committed Sep 8, 2020
1 parent 5555b04 commit 57b4016
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Composer/Command/CreateProjectCommand.php
Expand Up @@ -132,7 +132,8 @@ protected function execute(InputInterface $input, OutputInterface $output)
}

if ($input->isInteractive() && $input->getOption('ask')) {
$input->setArgument('directory', $io->ask('New project directory <comment>[optional]</comment>: '));
$parts = explode("/", strtolower($input->getArgument('package')), 2);
$input->setArgument('directory', $io->ask('New project directory [<comment>'.array_pop($parts).'</comment>]: '));
}

$ignorePlatformReqs = $input->getOption('ignore-platform-reqs') ?: ($input->getOption('ignore-platform-req') ?: false);
Expand Down

0 comments on commit 57b4016

Please sign in to comment.