PHPackages                             igonics/laravel-specific-migrate - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. igonics/laravel-specific-migrate

ActiveLibrary

igonics/laravel-specific-migrate
================================

Specific File Migrations for Laravel 5

1221PHP

Since Mar 1Pushed 9y ago1 watchersCompare

[ Source](https://github.com/IGonics/laravel-specific-migrate)[ Packagist](https://packagist.org/packages/igonics/laravel-specific-migrate)[ RSS](/packages/igonics-laravel-specific-migrate/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

Laravel Specific File Migrator
==============================

[](#laravel-specific-file-migrator)

Migrate Specific Migrations

Installation
------------

[](#installation)

Step 1. Install using composer

```
composer require igonics/laravel-specific-migrate

```

Step 2. Add Service Provider to config/app.php

```
return [
     ...
     "providers":[
        ...
        IGonics\Migrations\Providers\SpecificMigratorServiceProvider::class,
     ]
];

```

Usage
-----

[](#usage)

Migrating specific files

```
php artisan migrate:specific --files="filename_1, filename_2"

```

Rollback specific files

```
php artisan migrate:specific-rollback --files="filename_1, filename_2"

```

### Using the specific migrator

[](#using-the-specific-migrator)

Migrating specific files

```
class MigrateComponent extends Command
{
    /**
     * The name and signature of the console command.
     *
     * @var string
     */
    protected $name = 'component:migrate';

    /**
     * The console command description.
     *
     * @var string
     */
    protected $description = 'Migrate Component Schema';

    /**
     * Create a new command instance.
     */
    public function __construct()
    {
        parent::__construct();
    }

    /**
     * Execute the console command.
     *
     * @return mixed
     */
    public function handle()
    {
        $relativePath = database_path('migrations');
        $path = __DIR__.$relativePath;
        //var_dump($path);
        $files = array_filter(scandir($path), function ($file) {
            return preg_match("/\.php/", $file) == 1;
        });
        $files = array_map(function ($file) use ($path) {
            return str_replace([$path, '.php'], '', $file);
        }, $files);
        //var_dump($files);

        $this->call('migrate:specific', [
            '--force' => true,
            '--path' => str_replace(app_path(), '', $path),
            '--files' => implode(',', $files),
        ]);
    }
}

```

Rolling back specific files

```
class RollbackComponent extends Command
{
    /**
     * The name and signature of the console command.
     *
     * @var string
     */
    protected $name = 'component:rollback';

    /**
     * The console command description.
     *
     * @var string
     */
    protected $description = 'Rollback Component Schema';

    /**
     * Create a new command instance.
     */
    public function __construct()
    {
        parent::__construct();
    }

    /**
     * Execute the console command.
     *
     * @return mixed
     */
    public function handle()
    {
        $relativePath = database_path('migrations');
        $path = __DIR__.$relativePath;
        //var_dump($path);
        $files = array_filter(scandir($path), function ($file) {
            return preg_match("/\.php/", $file) == 1;
        });
        $files = array_map(function ($file) use ($path) {
            return str_replace([$path, '.php'], '', $file);
        }, $files);
        //var_dump($files);

        $this->call('migrate:specific-rollback', [
            '--force' => true,
            '--path' => str_replace(app_path(), '', $path),
            '--files' => implode(',', $files),
        ]);
    }
}

```

\#MIT License Copyright (c) 2016 IGonics

Maintained by
=============

[](#maintained-by)

[IGonics](http://igonics.com)

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity13

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/dc24e1601653d26f1f28ad970bdb5a18f52ae4974e0cc2c0104750253eaf178f?d=identicon)[ggordon](/maintainers/ggordon)

---

Top Contributors

[![gggordon](https://avatars.githubusercontent.com/u/6540335?v=4)](https://github.com/gggordon "gggordon (22 commits)")

---

Tags

igonicslaravelmigrationpackagephpspecific

### Embed Badge

![Health badge](/badges/igonics-laravel-specific-migrate/health.svg)

```
[![Health](https://phpackages.com/badges/igonics-laravel-specific-migrate/health.svg)](https://phpackages.com/packages/igonics-laravel-specific-migrate)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
