PHPackages                             ucan-lab/laravel-dacapo - 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. ucan-lab/laravel-dacapo

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

ucan-lab/laravel-dacapo
=======================

Laravel migration support tools

5.2.0(3y ago)112378.8k—6.1%10[8 issues](https://github.com/ucan-lab/laravel-dacapo/issues)[9 PRs](https://github.com/ucan-lab/laravel-dacapo/pulls)MITPHPPHP ^8.0.2CI failing

Since Nov 5Pushed 2mo ago1 watchersCompare

[ Source](https://github.com/ucan-lab/laravel-dacapo)[ Packagist](https://packagist.org/packages/ucan-lab/laravel-dacapo)[ RSS](/packages/ucan-lab-laravel-dacapo/feed)WikiDiscussions main Synced 3d ago

READMEChangelog (10)Dependencies (5)Versions (68)Used By (0)

Laravel-Dacapo
==============

[](#laravel-dacapo)

[![Build Status](https://camo.githubusercontent.com/13520185a3a0fdb1bd0fe0755c12cba604e678be656fe84010448cccb0e627b4/68747470733a2f2f7472617669732d63692e6f72672f7563616e2d6c61622f6c61726176656c2d64616361706f2e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/ucan-lab/laravel-dacapo)[![Latest Stable Version](https://camo.githubusercontent.com/6859d1f60640428f8f23f4584276fda071b92796c57e1b58dd8bc12c4e2a66e7/68747470733a2f2f706f7365722e707567782e6f72672f7563616e2d6c61622f6c61726176656c2d64616361706f2f762f737461626c65)](https://packagist.org/packages/ucan-lab/laravel-dacapo)[![Total Downloads](https://camo.githubusercontent.com/d7c1212b7ce589c113ca46e249faf81be0cbe404ca491c08ee9cf94fc0f49921/68747470733a2f2f706f7365722e707567782e6f72672f7563616e2d6c61622f6c61726176656c2d64616361706f2f646f776e6c6f616473)](https://packagist.org/packages/ucan-lab/laravel-dacapo)[![Daily Downloads](https://camo.githubusercontent.com/f504809d32ef3a9ad31f1bc188500bc46754509ee6e8614d7ebb971f1996cade/68747470733a2f2f706f7365722e707567782e6f72672f7563616e2d6c61622f6c61726176656c2d64616361706f2f642f6461696c79)](https://packagist.org/packages/ucan-lab/laravel-dacapo)[![License](https://camo.githubusercontent.com/1834c8b16c9ff7660a3878e4c52a15684789f3e1ad0b6e7f976ddf14913dc5ca/68747470733a2f2f706f7365722e707567782e6f72672f7563616e2d6c61622f6c61726176656c2d64616361706f2f6c6963656e7365)](https://packagist.org/packages/ucan-lab/laravel-dacapo)

Introduction
------------

[](#introduction)

Dacapo is a Laravel migration file creation support library. Define the table structure in the schema yml file, Always generate the latest and tidy migration file.

This library is intended for use only in the coding phase. In the operation phase, uninstall and return to normal migration operation.

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

[](#installation)

```
$ composer require --dev ucan-lab/laravel-dacapo

```

Usage
-----

[](#usage)

### Generate default schema.yml

[](#generate-default-schemayml)

```
$ php artisan dacapo:init

```

`database/schemas/default.yml`By default, a schema file for Laravel8 is generated.

```
users:
  columns:
    id:
    name: string
    email:
      type: string
      unique:
    email_verified_at:
      type: timestamp
      nullable:
    password: string
    rememberToken:
    timestamps:

password_resets:
  columns:
    email:
      type: string
      index:
    token: string
    created_at:
      type: timestamp
      nullable:

failed_jobs:
  columns:
    id:
    uuid:
      type: string
      unique:
    connection: text
    queue: text
    payload: longText
    exception: longText
    failed_at:
      type: timestamp
      useCurrent:
```

### Generate migration files

[](#generate-migration-files)

```
$ php artisan dacapo

```

3 files are generated and migrate fresh.

- 1970\_01\_01\_000001\_create\_failed\_jobs\_table.php
- 1970\_01\_01\_000001\_create\_password\_resets\_table.php
- 1970\_01\_01\_000001\_create\_users\_table.php

#### Dacapo Option

[](#dacapo-option)

```
# Execute migrate and seeding
$ php artisan dacapo --seed

```

```
# Do not execute migrate
$ php artisan dacapo --no-migrate

```

### Schema file format

[](#schema-file-format)

- `{}` any value
- `database/schemas/*.yml`
- If it cannot be expressed in YAML, it can be used together with standard migration.
    - `php artisan make:migration`

```
# COMMENT
{TableName}:
  columns:
    {ColumnName}: {ColumnType}
    {ColumnName}:
      type: {ColumnType}
    {ColumnName}:
      unique: true
      nullable: true
      default: {DefaultValue}
      comment: {ColumnName}
      {ColumnModifier}: {ColumnModifierValue}
  indexes:
    - columns: {ColumnName}
      type: {IndexType}
    - columns: [{ColumnName}, {ColumnName}]
      type: {IndexType}
    - columns: {ColumnName}
      type: {IndexType}
      name: {IndexName}
  foreign_keys:
    - columns: {ColumnName}
      references: {ReferenceColumnName}
      table: {ReferenceTableName}
    - columns: {ColumnName}
      references: {ReferenceColumnName}
      table: {ReferenceTableName}
      onUpdateAction: {ConstraintProperty}
      onDeleteAction: {ConstraintProperty}
    - columns: [{ColumnName}, {ColumnName}]
      references: [{ReferenceColumnName}, {ReferenceColumnName}]
      table: {ReferenceTableName}

{TableName}:
  columns:
    {ColumnName}: {ColumnType}

```

### Dacapo Clear Migrations

[](#dacapo-clear-migrations)

```
$ php artisan dacapo:clear
$ php artisan dacapo:clear --all

```

- `--all` Delete including standard migration files.

### Dacapo Stub publish

[](#dacapo-stub-publish)

```
$ php artisan dacapo:stub:publish

```

### Dacapo Uninstall

[](#dacapo-uninstall)

```
$ php artisan dacapo:uninstall
$ composer remove --dev ucan-lab/laravel-dacapo

```

###  Health Score

56

—

FairBetter than 97% of packages

Maintenance56

Moderate activity, may be stable

Popularity51

Moderate usage in the ecosystem

Community15

Small or concentrated contributor base

Maturity81

Battle-tested with a long release history

 Bus Factor1

Top contributor holds 95.1% 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 ~28 days

Recently: every ~78 days

Total

54

Last Release

1281d ago

Major Versions

1.0.0 → 2.0.02019-08-22

2.3.9 → 3.0.02019-11-10

3.3.0 → 4.0.02021-01-10

4.2.1 → 5.0.02022-02-12

4.x-dev → 5.0.12022-02-12

PHP version history (5 changes)0.0.1PHP ^7.0

2.1.1PHP ~7.2

4.0.0PHP ~7.4

4.0.2PHP ^7.4|^8.0

5.0.0PHP ^8.0.2

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/35098175?v=4)[ucan-lab](/maintainers/ucan-lab)[@ucan-lab](https://github.com/ucan-lab)

---

Top Contributors

[![ucan-lab](https://avatars.githubusercontent.com/u/35098175?v=4)](https://github.com/ucan-lab "ucan-lab (387 commits)")[![mpyw](https://avatars.githubusercontent.com/u/1351893?v=4)](https://github.com/mpyw "mpyw (13 commits)")[![renovate[bot]](https://avatars.githubusercontent.com/in/2740?v=4)](https://github.com/renovate[bot] "renovate[bot] (5 commits)")[![ebuildy](https://avatars.githubusercontent.com/u/1219817?v=4)](https://github.com/ebuildy "ebuildy (2 commits)")

---

Tags

dacapolaravellaravel-dacapolaravel-migrationlaravel-packagelaravelmigrationdacapo

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/ucan-lab-laravel-dacapo/health.svg)

```
[![Health](https://phpackages.com/badges/ucan-lab-laravel-dacapo/health.svg)](https://phpackages.com/packages/ucan-lab-laravel-dacapo)
```

###  Alternatives

[statamic/cms

The Statamic CMS Core Package

4.8k3.6M986](/packages/statamic-cms)[darkaonline/l5-swagger

OpenApi or Swagger integration to Laravel

3.0k37.6M134](/packages/darkaonline-l5-swagger)[knuckleswtf/scribe

Generate API documentation for humans from your Laravel codebase.✍

2.3k14.2M62](/packages/knuckleswtf-scribe)[anourvalar/eloquent-serialize

Laravel Query Builder (Eloquent) serialization

11223.5M33](/packages/anourvalar-eloquent-serialize)[rcsofttech/audit-trail-bundle

Enterprise-grade, high-performance Symfony audit trail bundle. Automatically track Doctrine entity changes with split-phase architecture, multiple transports (HTTP, Queue, Doctrine), and sensitive data masking.

1189.8k](/packages/rcsofttech-audit-trail-bundle)[statamic-rad-pack/runway

Eloquently manage your database models in Statamic.

135224.7k7](/packages/statamic-rad-pack-runway)

PHPackages © 2026

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