laravel / jetstream

Tailwind scaffolding for the Laravel framework.
https://jetstream.laravel.com
MIT License
3.98k stars 822 forks source link

Support disabled interactivity for the database migration prompt. #1465

Closed serious-angel closed 8 months ago

serious-angel commented 8 months ago

Dear Developers,

Thank you for the incredibly marvelous project...

May I ask regarding the migration confirmation prompt. The prompt seems to be activated even with --no-intraction option set, and when $input->isInteractive() returns false.

The issue is that this is the single and only prompt with laravel new --no-interactive --database mysql #... command executed from the installer package.

I believe that an explicit disablement of interactivity means all default choices to be set automatically, and the default for the prompt mentioned, even if it can be destructive, may assume yes (as it does right now) and be considered adequate. Though, a warning in docs or during an execution should not make it worse.

What do you think if the confirm could be disabled if $input->isInteractive() returns false, and continue assuming it's confirmed by default, or well, additional option like --migrate ^^?

Best and kind regards

driesvints commented 8 months ago

I ran laravel new test-prompts --no-interaction --database mysql and no prompt was activated. It just ran everything as expected. I'm on the latest v5.7.0 version of the installer.

serious-angel commented 7 months ago

I ran laravel new test-prompts --no-interaction --database mysql and no prompt was activated. It just ran everything as expected. I'm on the latest v5.7.0 version of the installer.

I am sorry, but it seems you missed the --jet option I probably missed to explicitly state, too. I assumed it by default, since it's the reason why I started it in this repo and not at Laravel Installer. Please try again with --jet option, since it's the Jetstream logic causes it it seems.