From 6ddbaa53d09ea47e9f0b39420f05329dabffe789 Mon Sep 17 00:00:00 2001 From: "Alexander M. Turek" Date: Fri, 15 Apr 2022 15:41:52 +0200 Subject: [PATCH] Remove the doctrine binary --- UPGRADE.md | 8 +++ bin/doctrine | 4 -- bin/doctrine-pear.php | 42 ------------- bin/doctrine.bat | 9 --- bin/doctrine.php | 61 ------------------- composer.json | 1 - .../ORM/Tools/Console/ConsoleRunner.php | 24 -------- 7 files changed, 8 insertions(+), 141 deletions(-) delete mode 100755 bin/doctrine delete mode 100644 bin/doctrine-pear.php delete mode 100644 bin/doctrine.bat delete mode 100644 bin/doctrine.php diff --git a/UPGRADE.md b/UPGRADE.md index 698b19ecd73..ec42b89bfb3 100644 --- a/UPGRADE.md +++ b/UPGRADE.md @@ -1,5 +1,13 @@ # Upgrade to 3.0 +## BC Break: Removed the `doctrine` binary. + +The documentation explains how the console tools can be bootstrapped for +standalone usage. + +The method `ConsoleRunner::printCliConfigTemplate()` has been removed as well +because it was only useful in the context of the `doctrine` binary. + ## BC Break: Removed `EntityManagerHelper` and related logic All console commands require a `$entityManagerProvider` to be passed via the diff --git a/bin/doctrine b/bin/doctrine deleted file mode 100755 index 83d38042920..00000000000 --- a/bin/doctrine +++ /dev/null @@ -1,4 +0,0 @@ -#!/usr/bin/env php -register(); - -$classLoader = new \Doctrine\Common\ClassLoader('Symfony'); -$classLoader->register(); - -$configFile = getcwd() . DIRECTORY_SEPARATOR . 'cli-config.php'; - -$helperSet = null; -if (file_exists($configFile)) { - if ( ! is_readable($configFile)) { - trigger_error( - 'Configuration file [' . $configFile . '] does not have read permission.', E_USER_ERROR - ); - } - - require $configFile; - - foreach ($GLOBALS as $helperSetCandidate) { - if ($helperSetCandidate instanceof \Symfony\Component\Console\Helper\HelperSet) { - $helperSet = $helperSetCandidate; - break; - } - } -} - -$helperSet = ($helperSet) ?: new \Symfony\Component\Console\Helper\HelperSet(); - -\Doctrine\ORM\Tools\Console\ConsoleRunner::run($helperSet); diff --git a/bin/doctrine.bat b/bin/doctrine.bat deleted file mode 100644 index a91645cc457..00000000000 --- a/bin/doctrine.bat +++ /dev/null @@ -1,9 +0,0 @@ -@echo off - -if "%PHPBIN%" == "" set PHPBIN=@php_bin@ -if not exist "%PHPBIN%" if "%PHP_PEAR_PHP_BIN%" neq "" goto USE_PEAR_PATH -GOTO RUN -:USE_PEAR_PATH -set PHPBIN=%PHP_PEAR_PHP_BIN% -:RUN -"%PHPBIN%" "@bin_dir@\doctrine" %* diff --git a/bin/doctrine.php b/bin/doctrine.php deleted file mode 100644 index d2e1c3253f3..00000000000 --- a/bin/doctrine.php +++ /dev/null @@ -1,61 +0,0 @@ -