Skip to content
Snippets Groups Projects
Commit 7fbcb9dd authored by Daniel Kurowski's avatar Daniel Kurowski
Browse files

initializeDatabase: add parameter to reset

parent 8d27fe8a
No related branches found
No related tags found
1 merge request!46initializeDatabase: add parameter to reset
Pipeline #44638 passed
......@@ -11,6 +11,10 @@ require __DIR__ . '/../vendor/autoload.php';
$connection = require __DIR__ . '/createConnection.local.php';
\assert($connection instanceof Connection);
if (isset($_SERVER['argv'][1]) && $_SERVER['argv'][1] === '--reset') {
$connection->nativeQuery('DROP SCHEMA IF EXISTS public CASCADE');
}
$connection->nativeQuery('CREATE SCHEMA IF NOT EXISTS public');
$connection->nativeQuery(<<<SQL
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment