From 4d7c8628f619b431f9af6f39586fe4c5565720df Mon Sep 17 00:00:00 2001 From: Hugo Sales Date: Wed, 18 Mar 2020 10:51:10 +0000 Subject: [PATCH] [DOCTRINE] Configure cli-config for doctrine console and ensure DATABASE is set to UTF-8 --- bin/doctrine | 1 + composer.lock | 378 ++++++++++++++++++++++++++++++++++ config/cli-config.php | 12 ++ config/packages/doctrine.yaml | 1 + 4 files changed, 392 insertions(+) create mode 120000 bin/doctrine create mode 100644 config/cli-config.php diff --git a/bin/doctrine b/bin/doctrine new file mode 120000 index 0000000000..0f72e36f91 --- /dev/null +++ b/bin/doctrine @@ -0,0 +1 @@ +../vendor/doctrine/orm/bin/doctrine \ No newline at end of file diff --git a/composer.lock b/composer.lock index 8191bbf369..5c2e5267da 100644 --- a/composer.lock +++ b/composer.lock @@ -2350,6 +2350,20 @@ ], "description": "Symfony Config Component", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-04T09:41:09+00:00" }, { @@ -2426,6 +2440,20 @@ ], "description": "Symfony Console Component", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-24T15:05:31+00:00" }, { @@ -2499,6 +2527,20 @@ ], "description": "Symfony DependencyInjection Component", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-24T15:05:31+00:00" }, { @@ -2652,6 +2694,20 @@ "env", "environment" ], + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-29T10:07:09+00:00" }, { @@ -2707,6 +2763,20 @@ ], "description": "Symfony ErrorHandler Component", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-29T10:07:09+00:00" }, { @@ -2777,6 +2847,20 @@ ], "description": "Symfony EventDispatcher Component", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-22T20:09:08+00:00" }, { @@ -2886,6 +2970,20 @@ ], "description": "Symfony ExpressionLanguage Component", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-24T15:05:31+00:00" }, { @@ -2985,6 +3083,20 @@ ], "description": "Symfony Finder Component", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-14T07:43:07+00:00" }, { @@ -3118,6 +3230,20 @@ ], "description": "Symfony Form Component", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-29T10:07:09+00:00" }, { @@ -3248,6 +3374,20 @@ ], "description": "Symfony FrameworkBundle", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-29T10:07:09+00:00" }, { @@ -3316,6 +3456,20 @@ ], "description": "Symfony HttpClient component", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-26T22:30:10+00:00" }, { @@ -3524,6 +3678,20 @@ ], "description": "Symfony HttpKernel Component", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-29T10:41:30+00:00" }, { @@ -3657,6 +3825,20 @@ "l10n", "localization" ], + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-04T09:41:09+00:00" }, { @@ -3786,6 +3968,20 @@ "mime", "mime-type" ], + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-04T09:41:09+00:00" }, { @@ -3972,6 +4168,20 @@ "notification", "notifier" ], + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-24T17:03:13+00:00" }, { @@ -4681,6 +4891,20 @@ "uri", "url" ], + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-25T14:24:11+00:00" }, { @@ -5097,6 +5321,20 @@ ], "description": "Symfony Serializer Component", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-29T10:07:09+00:00" }, { @@ -5299,6 +5537,20 @@ "utf-8", "utf8" ], + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-26T22:30:10+00:00" }, { @@ -5376,6 +5628,20 @@ ], "description": "Symfony Translation Component", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-04T07:41:34+00:00" }, { @@ -5609,6 +5875,20 @@ ], "description": "Symfony TwigBundle", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-04T09:47:34+00:00" }, { @@ -5730,6 +6010,20 @@ ], "description": "Symfony Validator Component", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-29T10:07:09+00:00" }, { @@ -5865,6 +6159,20 @@ "instantiate", "serialize" ], + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-04T09:47:34+00:00" }, { @@ -5999,6 +6307,20 @@ ], "description": "Symfony Yaml Component", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-03T13:51:17+00:00" }, { @@ -6582,6 +6904,20 @@ ], "description": "Symfony BrowserKit Component", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-24T15:05:31+00:00" }, { @@ -6701,6 +7037,20 @@ ], "description": "Symfony DebugBundle", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-01-04T14:08:26+00:00" }, { @@ -6792,6 +7142,20 @@ ], "description": "Symfony DomCrawler Component", "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-02-29T10:07:09+00:00" }, { @@ -6860,6 +7224,20 @@ "scaffold", "scaffolding" ], + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], "time": "2020-03-04T13:57:29+00:00" }, { diff --git a/config/cli-config.php b/config/cli-config.php new file mode 100644 index 0000000000..45856e1cf1 --- /dev/null +++ b/config/cli-config.php @@ -0,0 +1,12 @@ +boot(); +$entityManager = $kernel->getContainer()->get('doctrine.orm.default_entity_manager'); + +return ConsoleRunner::createHelperSet($entityManager); diff --git a/config/packages/doctrine.yaml b/config/packages/doctrine.yaml index 3a24482e61..b805c0f350 100644 --- a/config/packages/doctrine.yaml +++ b/config/packages/doctrine.yaml @@ -2,6 +2,7 @@ doctrine: dbal: # TODO In case of special URL characters, this needs to be handled differently url: '%env(resolve:DATABASE_URL)%' + charset: UTF8 orm: auto_generate_proxy_classes: true naming_strategy: doctrine.orm.naming_strategy.underscore_number_aware