Skip to content

Instantly share code, notes, and snippets.

@mcfdn
Last active August 15, 2016 16:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mcfdn/bbcb5622800a92ade71c9416487e490b to your computer and use it in GitHub Desktop.
Save mcfdn/bbcb5622800a92ade71c9416487e490b to your computer and use it in GitHub Desktop.
Doctrine ORM cli-config.php for Laravel 5.2
<?php
require __DIR__ . '/bootstrap/autoload.php';
$app = require_once __DIR__ . '/bootstrap/app.php';
$kernel = $app->make(Illuminate\Contracts\Http\Kernel::class);
$kernel->handle(Illuminate\Http\Request::capture());
$entityManager = $app->make(Doctrine\ORM\EntityManager::class);
return Doctrine\ORM\Tools\Console\ConsoleRunner\ConsoleRunner::createHelperSet($entityManager);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment