Download the PHP package artesaos/migrator without Composer

On this page you can find all versions of the php package artesaos/migrator. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package migrator

artesaos/migrator

Latest Stable Version Total Downloads Monthly Downloads License

This package is a customized version of Laravel's default database migrator, it was designed to register migrations on services providers and support namespacing as well.

There is no timestamp previews since the run order is based on how you register the migrations.

Warning

This Package Supports Laravel starting on 5.2 up to the latest stable version.

Installing

In order to install Migrator, run the following command into your Laravel 5.2+ project:

After installing the Package, you can now register it's provider into your config/app.php file:

And publish configuration: with

Upgrading from v1.x to v2.0.

On v1.x, this package uses the same table name as the default migration engine.

On version v2, there is a separate table used for tracking migrations, and it defaults to: migrator_table

If you are upgrading from v1, you may either rename the migrations table to migrator_table OR publish the config file and set the migrator table name to migrations.

Either should work.

v2 works alongside default migrations, for projects who want to namespace migrations but already have many migrations in place.

Usage

As the default Laravel migrator, this one has all the original commands, to list the available options, you can see all the available options using php artisan command.

Creating Migrations

In order to generate an empty migration, please provide the migrator with the full qualified class name, as the example.

php artisan migrator:make 'MyApp\MyModule\Database\Migrations\CreateOrdersTable' --create=orders

This will create a migration class into the right directory, the resulting file is slightly different from the default Laravel generated:

To declare your table fields, just follow the usual schema build practices, this package don't make anything different there.

As the normal migrator, you can pass the option --table instead of --create in order to generate a update migration instead of a create one. Also, you can create a empty migration not passing any of those options.

Registering migrations.

Inside any service provider of your choice (usually on the same namespace that you're storing the migrations), you easily register the migrations using the Migrator\MigratorTrait:


All versions of migrator with dependencies

PHP Build Version
Package Version
No informations.
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package artesaos/migrator contains the following files

Loading the files please wait ....