Skip to content

Conversation

@duncanmcclean
Copy link
Member

This pull request fixes an error when creating new sites w/ a database:

 Which database will your application use? ───────────────────┐
 │ MySQL                                                        │
 └──────────────────────────────────────────────────────────────┘


                                               
  Not enough arguments (missing: "timezone").  
                                               

   There was a problem connecting to the database. 

  Once the install process is complete, please run php please install:eloquent-driver to finish setting up the database.

This was happening because...

  1. We were running php please migrate.
  2. The statamic:migrate-dates-to-utc command becomes migrate-dates-to-utc in Please.
  3. Symfony's console uses abbreviation matching, meaning migrate is a valid abbreviation/prefix of migrate-dates-to-utc.
  4. It meant that php please migrate would end up matching migrate-dates-to-utc, rather than falling back to Laravel's migrate command, like it did < v6.
  5. The command requires a timezone argument, hence the error.

This PR fixes it by explicitly using php artisan to run the migration command, rather than rely on the fallback behaviour of php please.

Fixes #101

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Statamic CLI install fails with "Not enough arguments (missing: timezone)" when selecting MySQL

1 participant