class
Illuminate
/
Database
/
Console
/
Migrations
/
MigrateCommand
You are viewing an older version of the documentation. For the latest, please visit master documentation.
MigrateCommand
Extends
Uses
Properties
protected
$signature string
The name and signature of the console command.
Default: 'migrate {--database= : The database connection to use}
{--force : Force the operation to run when in production}
{--path=* : The path(s) to the migrations files to be executed}
{--realpath : Indicate any provided migration file paths are pre-resolved absolute paths}
{--schema-path= : The path to a schema dump file}
{--pretend : Dump the SQL queries that would be run}
{--seed : Indicates if the seed task should be re-run}
{--seeder= : The class name of the root seeder}
{--step : Force the migrations to be run so they can be rolled back individually}'
protected
$description string
The console command description.
Default: 'Run the database migrations'
Methods
public
__construct ( Migrator $migrator , Dispatcher $dispatcher ) : void
Create a new migration command instance.
Parameters
- $migrator Migrator
- $dispatcher Dispatcher
public
handle ( ) : int
Execute the console command.
protected
prepareDatabase ( ) : void
Prepare the migration database for running.
protected
loadSchemaState ( ) : void
Load the schema state to seed the initial database schema structure.
protected
schemaPath ( $connection ) : string
Get the path to the stored schema for the given connection.
Parameters
- $connection Connection