Download the PHP package mayconbordin/l5-db-commands without Composer
On this page you can find all versions of the php package mayconbordin/l5-db-commands. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download mayconbordin/l5-db-commands
More information about mayconbordin/l5-db-commands
Files in mayconbordin/l5-db-commands
Package l5-db-commands
Short Description A set of commands to create/drop/dump/restore databases on Laravel 5
License MIT
Homepage https://github.com/mayconbordin/l5-db-commands
Informations about the package l5-db-commands
l5-db-commands
A set of commands to create/drop/dump/restore/shell databases on Laravel 5.
Supported DBMSs: MySQL, PostgreSQL and SQLite.
Installation
In order to install just add
to your composer.json. Then run composer install
or composer update
.
Then in your config/app.php
add
in the providers
array.
Commands
db:create [options]
Create a new database with the default connection from the configuration file.
Options:
--database
: The name of the database connection in the configuration file.
db:drop [options]
Drop an existing database with the default connection from the configuration file.
Options:
--database
: The name of the database connection in the configuration file.
db:dump [options] [--] [<output>]
Dump the schema and data of an existing database with the default connection from the configuration file. By
default the dump is printed on the screen, optionally it can be written to <output>
.
Options:
--database
: The name of the database connection in the configuration file.--data-only
: Dumps only the data.
db:restore [options] [--] <dump-file>
Restore the schema and data from <dump-file>
to an existing database with the default connection from the configuration file.
Options:
--database
: The name of the database connection in the configuration file.
db:shell [options]
Open a shell to an existing database with the default connection from the configuration file.
For PostgreSQL you might have to create a
~/.pgpass
file withlocalhost:5432:mydbname:postgres:mypass
and chmod 600.
Options:
--database
: The name of the database connection in the configuration file.
db:exec:sql [options] [--] <file>
Execute SQL file from <file>
to an existing database with the default connection from the configuration file.
Options:
--database
: The name of the database connection in the configuration file.