Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 21 additions & 5 deletions src/NewCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -571,11 +571,27 @@ protected function askToInstallAddons()
return $this;
}

$this->addons = multiselect('Would you like to install any first-party addons?', [
'collaboration' => 'Collaboration',
'eloquent-driver' => 'Eloquent Driver',
'ssg' => 'Static Site Generator',
]);
$choice = select(
label: 'Would you like to install any first-party addons?',
options: [
$withoutAddonsOption = "No, I'm good for now.",
"Yes, let me pick.",
],
);

if ($choice === $withoutAddonsOption) {
return $this;
}

$this->addons = multiselect(
label: 'Which first-party addons do you want to install?',
options: [
'collaboration' => 'Collaboration',
'eloquent-driver' => 'Eloquent Driver',
'ssg' => 'Static Site Generator',
],
hint: 'Use the space bar to select options.'
);

if (count($this->addons) > 0) {
$this->output->write(" Great. We'll get these installed right after we setup your Statamic site.".PHP_EOL.PHP_EOL);
Expand Down