PHPackages                             caherrera/laravel-migrate-check - 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. [Database &amp; ORM](/categories/database)
4. /
5. caherrera/laravel-migrate-check

ActiveLibrary[Database &amp; ORM](/categories/database)

caherrera/laravel-migrate-check
===============================

A command to check for pending migrations. Exits with number of pending migrations if there are any

v1.2.2(7y ago)034MITPHPPHP ^7.0

Since Dec 20Pushed 7y ago1 watchersCompare

[ Source](https://github.com/caherrera/laravel-migrate-check)[ Packagist](https://packagist.org/packages/caherrera/laravel-migrate-check)[ Docs](https://github.com/caherrera/laravel-migrate-check)[ RSS](/packages/caherrera-laravel-migrate-check/feed)WikiDiscussions master Synced today

READMEChangelogDependencies (5)Versions (6)Used By (0)

###### FORK

[](#fork)

This is a fork from [erjanmx/laravel-migrate-check](https://github.com/erjanmx/laravel-migrate-check)

### An artisan command to check for pending migrations. Exits with number of pending migrations if there are any

[](#an-artisan-command-to-check-for-pending-migrations-exits-with-number-of-pending-migrations-if-there-are-any)

[![Build Status](https://camo.githubusercontent.com/769e0272aa369110b273bad955ba311051fdbd81137859f1d850df20472f042f/68747470733a2f2f7472617669732d63692e6f72672f6361686572726572612f6c61726176656c2d6d6967726174652d636865636b2e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/caherrera/laravel-migrate-check)

Laravel has a `migrate:status` command to check status of migrations. But this command mostly for humans. There are situations where one needs to know whether to run migrations when using autodeployment, maybe with switching to maintenance mode.

This package contains a `migrate:check` command that exits with number of pending migrations if there are any migrations to run.

Requirements
------------

[](#requirements)

This command supports all database drivers that Laravel does.

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

[](#installation)

You can install the package via composer:

```
composer require caherrera/laravel-migrate-check
```

Thanks to Laravel 5.5 package auto-discovery the `migrate:check` command will be registered

Usage
-----

[](#usage)

```
php artisan migrate:сheck
```

You can specify database and path to migration file via options just like they are used in `php artisan migrate` command

[![ezgif com-gif-maker](https://user-images.githubusercontent.com/4899432/34324977-691c5ca2-e895-11e7-9564-f4313763bc74.gif)](https://user-images.githubusercontent.com/4899432/34324977-691c5ca2-e895-11e7-9564-f4313763bc74.gif)

Changelog
---------

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently.

Testing
-------

[](#testing)

In order for the test to be run you should set up an empty mysql database `laravel_migrate_check` . The username should be `root`, the required password should be empty.

```
$ composer test
```

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity62

Established project with proven stability

 Bus Factor1

Top contributor holds 66.7% 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.

###  Release Activity

Cadence

Every ~80 days

Total

5

Last Release

2742d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/18551113?v=4)[Carlos Herrera](/maintainers/caherrera)[@caherrera](https://github.com/caherrera)

---

Top Contributors

[![erjanmx](https://avatars.githubusercontent.com/u/4899432?v=4)](https://github.com/erjanmx "erjanmx (12 commits)")[![CarlosItline](https://avatars.githubusercontent.com/u/3080413?v=4)](https://github.com/CarlosItline "CarlosItline (4 commits)")[![erjanmx-onlinesup](https://avatars.githubusercontent.com/u/22002562?v=4)](https://github.com/erjanmx-onlinesup "erjanmx-onlinesup (2 commits)")

---

Tags

checkdatabaseeloquentmigratelaravel-migrate-check

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/caherrera-laravel-migrate-check/health.svg)

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

###  Alternatives

[spatie/laravel-backup

A Laravel package to backup your application

6.0k21.8M191](/packages/spatie-laravel-backup)[mongodb/laravel-mongodb

A MongoDB based Eloquent model and Query builder for Laravel

7.1k7.2M71](/packages/mongodb-laravel-mongodb)[erjanmx/laravel-migrate-check

A command to check for pending migrations. Exits with non-zero code if there are any

54273.8k1](/packages/erjanmx-laravel-migrate-check)[toponepercent/baum

Baum is an implementation of the Nested Set pattern for Eloquent models.

3154.7k](/packages/toponepercent-baum)

PHPackages © 2026

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