Skip to content

Latest commit

 

History

History
43 lines (31 loc) · 749 Bytes

database_shell.md

File metadata and controls

43 lines (31 loc) · 749 Bytes

Database Shell

Attempts to launch the Postgres shell using the current project database configuration.

Installation

Add the DatabaseShellConsole to your ConsoleDependencyProvider:

<?php

namespace Pyz\Zed\Console;

// ...
use Inviqa\Zed\SprykerDebug\Communication\Console\DatabaseShellConsole;

class ConsoleDependencyProvider extends SprykerConsoleDependencyProvider
{
    // ...

    protected function getConsoleCommands(Container $container)
    {
        return [
            // ...
            new DatabaseShellConsole(),
        ];
    }
}

Usage

Connect to the psql shell:

$ ./vendor/bin/console debug:database:shell

Note that the psql shell will need to be available.