PHPackages                             nachopitt/db-commands - 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. nachopitt/db-commands

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

nachopitt/db-commands
=====================

v0.3.1(8mo ago)0120MITPHP

Since Dec 7Pushed 8mo ago1 watchersCompare

[ Source](https://github.com/nachopitt/db-commands)[ Packagist](https://packagist.org/packages/nachopitt/db-commands)[ Docs](https://github.com/nachopitt/db-commands)[ RSS](/packages/nachopitt-db-commands/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (4)Dependencies (1)Versions (5)Used By (0)

DB Commands
===========

[](#db-commands)

A set of Laravel Artisan commands for database management.

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

[](#installation)

You can install the package via composer:

```
composer require nachopitt/db-commands
```

Usage
-----

[](#usage)

### `db:create`

[](#dbcreate)

Create a new MySQL database.

```
php artisan db:create {name?}
```

ArgumentDescription`name`The name of the database to create. If not provided, the command will use the database name from your `database.php` config file.### `db:drop`

[](#dbdrop)

Drop an existing MySQL database.

```
php artisan db:drop {name?}
```

ArgumentDescription`name`The name of the database to drop. If not provided, the command will use the database name from your `database.php` config file.### `db:export`

[](#dbexport)

Export an existing MySQL database into SQL statements.

```
php artisan db:export {schema?}
```

ArgumentDescription`schema`The name of the database to export. If not provided, the command will use the database name from your `database.php` config file.### `db:import`

[](#dbimport)

Import a SQL file into an existing MySQL database.

```
php artisan db:import {file?} {--s|schema=} {--i|ignore-foreign-key-checks}
```

ArgumentDescription`file`The path to the SQL file to import. If not provided, the command will use `database_model/{database}.sql`.`--schema`The name of the database to import into. If not provided, the command will use the database name from your `database.php` config file.`--ignore-foreign-key-checks`Ignore foreign key checks while importing.### `db:truncate`

[](#dbtruncate)

Truncate tables from database.

```
php artisan db:truncate {tables?} {--s|schema=} {--i|ignore-foreign-key-checks}
```

ArgumentDescription`tables`A comma-separated list of tables to truncate. If not provided, the command will truncate all tables in the database.`--schema`The name of the database to truncate tables from. If not provided, the command will use the database name from your `database.php` config file.`--ignore-foreign-key-checks`Ignore foreign key checks while truncating.License
-------

[](#license)

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

###  Health Score

31

—

LowBetter than 68% of packages

Maintenance59

Moderate activity, may be stable

Popularity10

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity39

Early-stage or recently created project

 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.

###  Release Activity

Cadence

Every ~333 days

Total

4

Last Release

257d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/4621fa2139363de306d93a14c525eea77e0977409b444f57d80862fde351cc8c?d=identicon)[nachopitt](/maintainers/nachopitt)

---

Top Contributors

[![nachopitt](https://avatars.githubusercontent.com/u/12923928?v=4)](https://github.com/nachopitt "nachopitt (8 commits)")

---

Tags

laravelschemadatabaseexportmysqlsqlimportcreatedrop

### Embed Badge

![Health badge](/badges/nachopitt-db-commands/health.svg)

```
[![Health](https://phpackages.com/badges/nachopitt-db-commands/health.svg)](https://phpackages.com/packages/nachopitt-db-commands)
```

###  Alternatives

[rah/danpu

Zero-dependency MySQL dump library for easily exporting and importing databases

64401.8k10](/packages/rah-danpu)[sarfraznawaz2005/indexer

Laravel package to monitor SELECT queries and offer best possible INDEX fields.

562.7k](/packages/sarfraznawaz2005-indexer)[ramadan/easy-model

A Laravel package for enjoyably managing database queries.

101.6k](/packages/ramadan-easy-model)

PHPackages © 2026

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