PHPackages                             cable8mm/xeed - 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. cable8mm/xeed

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

cable8mm/xeed
=============

Xeed generates new model, seed, Nova resources, database seed, factory and migration files for Laravel &amp; Nova based on data from the existing database table.

v2.0.2(6d ago)872.5k↓81%8MITPHPPHP ^8.2.0CI passing

Since Mar 14Pushed 6d ago1 watchersCompare

[ Source](https://github.com/cable8mm/xeed)[ Packagist](https://packagist.org/packages/cable8mm/xeed)[ RSS](/packages/cable8mm-xeed/feed)WikiDiscussions main Synced yesterday

READMEChangelog (10)Dependencies (20)Versions (45)Used By (0)

Xeed - Resources Generator for Laravel &amp; Nova
=================================================

[](#xeed---resources-generator-for-laravel--nova)

[![code-style](https://github.com/cable8mm/xeed/actions/workflows/code-style.yml/badge.svg)](https://github.com/cable8mm/xeed/actions/workflows/code-style.yml)[![run-tests](https://github.com/cable8mm/xeed/actions/workflows/run-tests.yml/badge.svg)](https://github.com/cable8mm/xeed/actions/workflows/run-tests.yml)[![deploy-to-github-pages](https://github.com/cable8mm/xeed/actions/workflows/deploy-to-github-pages.yml/badge.svg)](https://github.com/cable8mm/xeed/actions/workflows/deploy-to-github-pages.yml)[![Packagist Version](https://camo.githubusercontent.com/941e40243d187c420f738c574912404b40dbdb2ed623a40e4f255869d8f84d60/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6361626c65386d6d2f78656564)](https://packagist.org/packages/cable8mm/xeed)[![Packagist Dependency Version](https://camo.githubusercontent.com/e4bdbe965421a20c22beccf34a71a8d75f7ed9f6e20d39a1c269aa239467bb96/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f646570656e64656e63792d762f6361626c65386d6d2f786565642f7068703f6c6f676f3d504850266c6f676f436f6c6f723d776869746526636f6c6f723d373737424234)](https://packagist.org/packages/cable8mm/xeed)[![Laravel Version](https://camo.githubusercontent.com/ec96224ee7a94d24be5bcec66135d4eeff6f6fc252ba4fe7482dbc32adecc60b/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c61726176656c2d392e302532422d4646324432303f6c6f676f3d6c61726176656c266c6162656c436f6c6f723d7768697465)](https://camo.githubusercontent.com/ec96224ee7a94d24be5bcec66135d4eeff6f6fc252ba4fe7482dbc32adecc60b/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c61726176656c2d392e302532422d4646324432303f6c6f676f3d6c61726176656c266c6162656c436f6c6f723d7768697465)[![Static Badge](https://camo.githubusercontent.com/9e1d1d4f1586d3d178bea0e5f766fa10463d0832cba72e2adb87111cff85ae76/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c61726176656c2532304e6f76612d342e302532422d3442413245343f6c6f676f3d6c61726176656c2532306e6f7661266c6f676f436f6c6f723d303045394630266c6162656c436f6c6f723d7768697465)](https://camo.githubusercontent.com/9e1d1d4f1586d3d178bea0e5f766fa10463d0832cba72e2adb87111cff85ae76/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c61726176656c2532304e6f76612d342e302532422d3442413245343f6c6f676f3d6c61726176656c2532306e6f7661266c6f676f436f6c6f723d303045394630266c6162656c436f6c6f723d7768697465)[![Packagist Downloads](https://camo.githubusercontent.com/65af85619f03893de8fb0b6ff8834545608baaf7c5b6112b016f796448c94c90/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6361626c65386d6d2f78656564)](https://packagist.org/packages/cable8mm/xeed/stats)[![Packagist Stars](https://camo.githubusercontent.com/77c22add28f670846701056973f8010431814c9b99925c80a3e8f36ec6a69065/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f73746172732f6361626c65386d6d2f78656564)](https://github.com/cable8mm/xeed/stargazers)[![Packagist License](https://camo.githubusercontent.com/54958c1a98e92a1d23d2bdc0bab2efc169c3c5900a3d970c9e0a629d824ef3e0/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f6361626c65386d6d2f78656564)](https://github.com/cable8mm/xeed/blob/main/LICENSE.md)

Xeed generates new model, seed, Nova resources, database seed, factory and migration files for Laravel &amp; Nova based on data from the existing database table.

Why Xeed?
---------

[](#why-xeed)

Laravel already has migrations and factories, but:

- It cannot reverse-engineer existing databases
- It is repetitive for legacy projects
- Nova resources are manual and slow to maintain

Xeed solves this by generating everything from your real schema.

Tip

It can function as both `php artisan xeed:*` commands for Laravel &amp; Nova providing 100% identical functionality. Therefore, you can use it within your own Laravel &amp; Nova project.

We have provided the API Documentation on the web. For more information, please visit  ❤️

Features
--------

[](#features)

- Database testing is supported
- Generate models for Laravel
- Generate seed files for Laravel
- Generate Nova resources files for Laravel Nova
- Generate database seed files for Laravel
- Generate factories for Laravel
- Generate migrations for Laravel
- Generate belongsTo and hasMany relationships functions for Laravel
- Laravel multi &amp; reserved columns supported
- Laravel integration
- MySQL, SQLite and PostgreSQL supported

### Support &amp; Tested

[](#support--tested)

[![MySQL Supported](https://camo.githubusercontent.com/a67eefb4f779347a39d79a31b13fa2f2e9e8a7d8a0948956ca15546eb37478a0/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4d7953514c2d3434373941313f6c6f676f3d6d7973716c266c6f676f436f6c6f723d7768697465)](https://camo.githubusercontent.com/a67eefb4f779347a39d79a31b13fa2f2e9e8a7d8a0948956ca15546eb37478a0/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4d7953514c2d3434373941313f6c6f676f3d6d7973716c266c6f676f436f6c6f723d7768697465)[![SQLite Supported](https://camo.githubusercontent.com/83d8c3b1dc43cfb5915df7aa56e07098553693711c595058fbc525d170003818/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f53514c6974652d3037343035653f6c6f676f3d73716c697465266c6f676f436f6c6f723d7768697465)](https://camo.githubusercontent.com/83d8c3b1dc43cfb5915df7aa56e07098553693711c595058fbc525d170003818/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f53514c6974652d3037343035653f6c6f676f3d73716c697465266c6f676f436f6c6f723d7768697465)[![PostgreSQL Supported](https://camo.githubusercontent.com/fdaf8f1bccc640779749a129a950089e126255f5dbb162ef8bfa000b52670f0f/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f506f737467726553514c2d426574612d3331363139323f266c6f676f3d706f737467726573716c266c6f676f436f6c6f723d7768697465)](https://camo.githubusercontent.com/fdaf8f1bccc640779749a129a950089e126255f5dbb162ef8bfa000b52670f0f/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f506f737467726553514c2d426574612d3331363139323f266c6f676f3d706f737467726573716c266c6f676f436f6c6f723d7768697465)[![PHP 8.2.0+ Supported](https://camo.githubusercontent.com/cb66a899299d8b9639c3226e542fc5eb34b88eeee83bba66475b608bee886954/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d382e322e302532422d3737374242343f6c6f676f3d706870266c6f676f436f6c6f723d7768697465)](https://camo.githubusercontent.com/cb66a899299d8b9639c3226e542fc5eb34b88eeee83bba66475b608bee886954/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d382e322e302532422d3737374242343f6c6f676f3d706870266c6f676f436f6c6f723d7768697465)[![PHP 8.3.0+ Supported](https://camo.githubusercontent.com/1b5f694494c70725252c02b3b0b403b3e91529fab7d83364ffde5f404a4c61c2/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d382e332e302532422d3737374242343f6c6f676f3d706870266c6f676f436f6c6f723d7768697465)](https://camo.githubusercontent.com/1b5f694494c70725252c02b3b0b403b3e91529fab7d83364ffde5f404a4c61c2/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d382e332e302532422d3737374242343f6c6f676f3d706870266c6f676f436f6c6f723d7768697465)[![PHP 8.4.0+ Supported](https://camo.githubusercontent.com/151cfb4ef4f3ef73fcb822b5d54e1515148d1c125efeb899413be1052d7a33a4/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d382e342e302532422d3737374242343f6c6f676f3d706870266c6f676f436f6c6f723d7768697465)](https://camo.githubusercontent.com/151cfb4ef4f3ef73fcb822b5d54e1515148d1c125efeb899413be1052d7a33a4/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d382e342e302532422d3737374242343f6c6f676f3d706870266c6f676f436f6c6f723d7768697465)[![PHP 8.5.0+ Supported](https://camo.githubusercontent.com/52c0a2e6900c7db8ea9077f565c9863a6e480f92b82e9539cd830b68cb31c99c/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d382e352e302532422d3737374242343f6c6f676f3d706870266c6f676f436f6c6f723d7768697465)](https://camo.githubusercontent.com/52c0a2e6900c7db8ea9077f565c9863a6e480f92b82e9539cd830b68cb31c99c/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d382e352e302532422d3737374242343f6c6f676f3d706870266c6f676f436f6c6f723d7768697465)

### Preview

[](#preview)

[![Preview](https://github.com/cable8mm/cabinet/raw/main/xeed-laravel-preview.gif?raw=true)](https://github.com/cable8mm/cabinet/blob/main/xeed-laravel-preview.gif?raw=true)

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

[](#installation)

```
composer require cable8mm/xeed --dev
```

Usage
-----

[](#usage)

All commands use the current database connection to generate files automatically.

Global options:

`-f` Force overwrite existing files

### Generators

[](#generators)

Models:

```
# Generate all models from database in `app/Models` folder
php artisan xeed:model

php artisan xeed:model -f
```

Factories:

```
# Generate all factories from database in `database/factories' folder
php artisan xeed:factory
```

Seeders:

```
# Generate all seeds from database in `database/seeders` folder
php artisan xeed:seeder

# Generate all seeds from database in `database/seeders` folder
php artisan xeed:faker-seeder
```

Migrations:

```
# Generate a database seed from database in `database/seeders` folder
php artisan xeed:database
```

Migrations:

```
# Generate all migrations from database in `database/migrations' folder
php artisan xeed:migration
```

Relations:

> `xeed:relation` updates existing models, so generate models first if they do not already exist.

```
# Add relation functions to existing models in `app/Models` folder
php artisan xeed:relation

# Force overwrite existing model files while adding relation functions
php artisan xeed:relation -f
```

Nova:

```
# Add the Laravel Nova resources to all tables in `app/Nova` folder
php artisan xeed:nova
```

Cleanup:

```
# Clean generated files, seeders, models, factories and migration files.
php artisan xeed:wipe
```

### Formatting

[](#formatting)

```
# Modify all files to comply with the PSR-12.
composer lint

# Inspect all files to ensure compliance with PSR-12.
composer inspect
```

### Testing

[](#testing)

`Xeed` uses an isolated SQLite database during tests, ensuring your real database is never affected. The test bootstrap recreates `tests/Generate/database.sqlite` when needed and loads the `xeeds` table automatically from `database/xeeds.sqlite.sql`.

```
# Run `vendor/bin/testbench package:test tests`
composer testpack
```

```
# Run `vendor/bin/phpunit tests`
composer test
```

### Changelog

[](#changelog)

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

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

[](#contributing)

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

The below can help you contribute.

The Xeed has a built-in SQLite database, allowing you to contribute easily without needing your own database. Simply create a new file for testing purposes and utilize it. You do not need to commit `tests/Generate/database.sqlite`; the test bootstrap recreates it automatically when you run the test suite.

```
# Create a new empty file for SQLite database
touch tests/Generate/database.sqlite
```

And then,

```
# Run tests
composer test
```

### Database seeds

[](#database-seeds)

For migrations and factories, when you need to execute tests for all database field types, utilize the following command.

```
# Import an 'xeeds' Table into the Database
php artisan xeed

# Drop the 'xeeds' Table from the Database
php artisan xeed drop
```

Utilize migration files for all database field types by referring to the following location `database/*.sql` these files are saved in the specified folder.

### Use `testorchestral/testbench`

[](#use-testorchestraltestbench)

You can utilize `testorchestral/testbench` to execute tests. When running Laravel commands, the generated files are saved in the `vendor/orchestra/testbench-core/laravel/database` folder.

Resources
---------

[](#resources)

Laravel columns **description** for mysql:

Available Column TypesFieldTypeNullKeyDefaultExtraid()idbigint unsignedNOPRIauto\_incrementbigInteger('big\_integer')big\_integerbigintNObinary('binary')binaryblobNOboolean('boolean')booleantinyint(1)NOchar('char', length: 100)charchar(100)NOdateTimeTz('date\_time\_tz', precision: 0)date\_time\_tzdatetimeNOdateTime('date\_time', precision: 0)date\_timedatetimeNOdate('date')datedateNOdecimal('decimal', total: 8, places: 2)decimaldecimal(8,2)NOdouble('double')doubledoubleNOenum('enum', \['easy', 'hard'\])enumenum('easy','hard')NOfloat('float', precision: 53)floatdoubleNOforeignId('foreign\_id')foreign\_idbigint unsignedNOforeignUlid('foreign\_ulid')foreign\_ulidchar(26)NOforeignUuid('foreign\_uuid')foreign\_uuidchar(36)NOgeometry('geometry', subtype: 'point', srid: 0)geometrypointNOinteger('integer')integerintNOipAddress('ip\_address')ip\_addressvarchar(45)NOjson('json')jsonjsonNOjsonb('jsonb')jsonbjsonNOlongText('long\_text')long\_textlongtextNOmacAddress('mac\_address')mac\_addressvarchar(17)NOmediumInteger('medium\_integer')medium\_integermediumintNOmediumText('medium\_text')medium\_textmediumtextNOmorphs('morph')morph\_typevarchar(255)NOMUL*Ditto make 2 fields*morph\_idbigint unsignedNOnullableTimestamps(precision: 0)created\_attimestampYES*Ditto make 2 fields*updated\_attimestampYESnullableMorphs('nullable\_morph')nullable\_morph\_typevarchar(255)YESMUL*Ditto make 2 fields*nullable\_morph\_idbigint unsignedYESnullableUlidMorphs('nullable\_ulid\_morph')nullable\_ulid\_morph\_typevarchar(255)YESMUL*Ditto make 2 fields*nullable\_ulid\_morph\_idchar(26)YESnullableUuidMorphs('nullable\_uuid\_morph')nullable\_uuid\_morph\_typevarchar(255)YESMUL*Ditto make 2 fields*nullable\_uuid\_morph\_idchar(36)YESrememberToken()remember\_tokenvarchar(100)YESset('set', \['strawberry', 'vanilla'\])setset('strawberry','vanilla')NOsmallInteger('small\_integer')small\_integersmallintNOsoftDeletesTz('soft\_delete\_tz', precision: 0)soft\_delete\_tztimestampYESsoftDeletes('soft\_delete', precision: 0)soft\_deletetimestampYESstring('string', length: 100)stringvarchar(100)NOtext('text')texttextNOtime('time\_tz', 0)time\_tztimeNOtime('time', 0)timetimeNOtimestampTz('timestamp\_tz', precision: 0)timestamp\_tztimestampNOtimestamp('timestamp', precision: 0)timestamptimestampNOtinyInteger('tiny\_integer')tiny\_integertinyintNOtinyText('tiny\_text')tiny\_texttinytextNOunsignedBigInteger('unsigned\_big\_integer')unsigned\_big\_integerbigint unsignedNOunsignedInteger('unsigned\_integer')unsigned\_integerint unsignedNOunsignedMediumInteger('unsigned\_medium\_integer')unsigned\_medium\_integermediumint unsignedNOunsignedSmallInteger('unsigned\_small\_integer')unsigned\_small\_integersmallint unsignedNOunsignedTinyInteger('unsigned\_tiny\_integer')unsigned\_tiny\_integertinyint unsignedNOulidMorphs('ulid\_morph')ulid\_morph\_typevarchar(255)NOMUL*Ditto make 2 fields*ulid\_morph\_idchar(26)NOuuidMorphs('uuid\_morph')uuid\_morph\_typevarchar(255)NOMUL*Ditto make 2 fields*uuid\_morph\_idchar(36)NOulid('ulid')ulidchar(26)NOuuid('uuid')uuidchar(36)NOyear('year')yearyearNOCode of Conduct
---------------

[](#code-of-conduct)

In order to ensure that the community is welcoming to all, please review and abide by the [CODE OF CONDUCT](CODE_OF_CONDUCT.md).

Credits
-------

[](#credits)

- [Samgu Lee](https://github.com/cable8mm)

License
-------

[](#license)

The Xeed project is open-sourced software licensed under the [MIT license](LICENSE.md).

###  Health Score

57

—

FairBetter than 98% of packages

Maintenance99

Actively maintained with recent releases

Popularity34

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity67

Established project with proven stability

 Bus Factor1

Top contributor holds 97.8% 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 ~21 days

Recently: every ~119 days

Total

40

Last Release

6d ago

Major Versions

v0.7.5 → v1.0.02024-03-21

v1.6.12 → v2.0.02026-02-13

1.x-dev → v2.0.22026-06-27

PHP version history (3 changes)v0.5.0PHP ^8.0.2

v2.0.1PHP ^8.1.0

v2.0.2PHP ^8.2.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/c910c874a0263a18f9f976273054cd45faa3ffbcba7891992f4ab52d0656dd93?d=identicon)[Sam Lee](/maintainers/Sam%20Lee)

---

Top Contributors

[![cable8mm](https://avatars.githubusercontent.com/u/2672043?v=4)](https://github.com/cable8mm "cable8mm (135 commits)")[![Blucreation](https://avatars.githubusercontent.com/u/2203320?v=4)](https://github.com/Blucreation "Blucreation (1 commits)")[![cognitus](https://avatars.githubusercontent.com/u/2235718?v=4)](https://github.com/cognitus "cognitus (1 commits)")[![Lopoi](https://avatars.githubusercontent.com/u/42871409?v=4)](https://github.com/Lopoi "Lopoi (1 commits)")

---

Tags

database-to-codegeneratorslaravellaravel-novaphpreverse-engineeringscaffoldinglaravelfactorymigrationgeneratorseednovaxeed

###  Code Quality

TestsPHPUnit

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/cable8mm-xeed/health.svg)

```
[![Health](https://phpackages.com/badges/cable8mm-xeed/health.svg)](https://phpackages.com/packages/cable8mm-xeed)
```

###  Alternatives

[laravel/framework

The Laravel Framework.

34.8k543.8M20.1k](/packages/laravel-framework)[tempest/framework

The PHP framework that gets out of your way.

2.2k34.4k15](/packages/tempest-framework)[pimcore/pimcore

Content &amp; Product Management Framework (CMS/PIM/E-Commerce)

3.8k3.8M508](/packages/pimcore-pimcore)[shopware/platform

The Shopware e-commerce core

3.4k1.5M3](/packages/shopware-platform)[spiral/framework

Spiral, High-Performance PHP/Go Framework

2.1k2.2M66](/packages/spiral-framework)[shopware/core

Shopware platform is the core for all Shopware ecommerce products.

585.6M574](/packages/shopware-core)

PHPackages © 2026

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