From 6ab62632a39590247be107b47722766616740399 Mon Sep 17 00:00:00 2001 From: Alexey Skobkin Date: Sun, 20 Jan 2019 02:32:50 +0300 Subject: [PATCH 01/13] composer update ocramius/proxy-manager --- app/config/config.yml | 6 ------ composer.lock | 31 ++++++++++++++++--------------- 2 files changed, 16 insertions(+), 21 deletions(-) diff --git a/app/config/config.yml b/app/config/config.yml index 7bca1d6..e5ecb61 100644 --- a/app/config/config.yml +++ b/app/config/config.yml @@ -50,12 +50,6 @@ doctrine: user: "%database_user%" password: "%database_password%" charset: UTF8 - # if using pdo_sqlite as your database driver: - # 1. add the path in parameters.yml - # e.g. database_path: "%kernel.root_dir%/data/data.db3" - # 2. Uncomment database_path in parameters.yml.dist - # 3. Uncomment next line: - # path: "%database_path%" orm: auto_generate_proxy_classes: "%kernel.debug%" diff --git a/composer.lock b/composer.lock index ee82f49..c1e2e03 100644 --- a/composer.lock +++ b/composer.lock @@ -1698,33 +1698,34 @@ }, { "name": "ocramius/proxy-manager", - "version": "2.1.1", + "version": "2.2.2", "source": { "type": "git", "url": "https://github.com/Ocramius/ProxyManager.git", - "reference": "e18ac876b2e4819c76349de8f78ccc8ef1554cd7" + "reference": "14b137b06b0f911944132df9d51e445a35920ab1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Ocramius/ProxyManager/zipball/e18ac876b2e4819c76349de8f78ccc8ef1554cd7", - "reference": "e18ac876b2e4819c76349de8f78ccc8ef1554cd7", + "url": "https://api.github.com/repos/Ocramius/ProxyManager/zipball/14b137b06b0f911944132df9d51e445a35920ab1", + "reference": "14b137b06b0f911944132df9d51e445a35920ab1", "shasum": "" }, "require": { - "ocramius/package-versions": "^1.1.1", - "php": "^7.1.0", - "zendframework/zend-code": "^3.1.0" + "ocramius/package-versions": "^1.1.3", + "php": "^7.2.0", + "zendframework/zend-code": "^3.3.0" }, "require-dev": { - "couscous/couscous": "^1.5.2", + "couscous/couscous": "^1.6.1", "ext-phar": "*", - "humbug/humbug": "dev-master@DEV", - "nikic/php-parser": "^3.0.4", + "humbug/humbug": "1.0.0-RC.0@RC", + "nikic/php-parser": "^3.1.1", + "padraic/phpunit-accelerator": "dev-master@DEV", "phpbench/phpbench": "^0.12.2", - "phpstan/phpstan": "^0.6.4", - "phpunit/phpunit": "^5.6.4", - "phpunit/phpunit-mock-objects": "^3.4.1", - "squizlabs/php_codesniffer": "^2.7.0" + "phpstan/phpstan": "dev-master#856eb10a81c1d27c701a83f167dc870fd8f4236a as 0.9.999", + "phpstan/phpstan-phpunit": "dev-master#5629c0a1f4a9c417cb1077cf6693ad9753895761", + "phpunit/phpunit": "^6.4.3", + "squizlabs/php_codesniffer": "^2.9.1" }, "suggest": { "ocramius/generated-hydrator": "To have very fast object to array to object conversion for ghost objects", @@ -1763,7 +1764,7 @@ "proxy pattern", "service proxies" ], - "time": "2017-05-04T11:12:50+00:00" + "time": "2018-09-27T13:45:01+00:00" }, { "name": "paragonie/random_compat", From 50b046978b549d96422ce56aa8a346f51a1b4cfe Mon Sep 17 00:00:00 2001 From: Alexey Skobkin Date: Sun, 20 Jan 2019 02:33:37 +0300 Subject: [PATCH 02/13] composer remove sensio/distribution-bundle --- composer.json | 1 - composer.lock | 156 +------------------------------------------------- 2 files changed, 1 insertion(+), 156 deletions(-) diff --git a/composer.json b/composer.json index 9776194..bc92113 100644 --- a/composer.json +++ b/composer.json @@ -16,7 +16,6 @@ "doctrine/doctrine-migrations-bundle": "^2.0", "doctrine/orm": "^2.5", "incenteev/composer-parameter-handler": "^2.0", - "sensio/distribution-bundle": "^5.0", "sensio/framework-extra-bundle": "^3.0.2", "sentry/sentry-symfony": "^2.2", "symfony/monolog-bundle": "^3.1", diff --git a/composer.lock b/composer.lock index c1e2e03..32ded92 100644 --- a/composer.lock +++ b/composer.lock @@ -4,64 +4,8 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "42a2feb6a87d88f529bf2827bf08c2df", + "content-hash": "8a652239de8a0748004c6d50b98f3c3b", "packages": [ - { - "name": "composer/ca-bundle", - "version": "1.1.3", - "source": { - "type": "git", - "url": "https://github.com/composer/ca-bundle.git", - "reference": "8afa52cd417f4ec417b4bfe86b68106538a87660" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/composer/ca-bundle/zipball/8afa52cd417f4ec417b4bfe86b68106538a87660", - "reference": "8afa52cd417f4ec417b4bfe86b68106538a87660", - "shasum": "" - }, - "require": { - "ext-openssl": "*", - "ext-pcre": "*", - "php": "^5.3.2 || ^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.5", - "psr/log": "^1.0", - "symfony/process": "^2.5 || ^3.0 || ^4.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.x-dev" - } - }, - "autoload": { - "psr-4": { - "Composer\\CaBundle\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jordi Boggiano", - "email": "j.boggiano@seld.be", - "homepage": "http://seld.be" - } - ], - "description": "Lets you find a path to the system CA bundle, and includes a fallback to the Mozilla CA bundle.", - "keywords": [ - "cabundle", - "cacert", - "certificate", - "ssl", - "tls" - ], - "time": "2018-10-18T06:09:13+00:00" - }, { "name": "doctrine/annotations", "version": "v1.6.0", @@ -2050,58 +1994,6 @@ ], "time": "2017-10-23T01:57:42+00:00" }, - { - "name": "sensio/distribution-bundle", - "version": "v5.0.24", - "source": { - "type": "git", - "url": "https://github.com/sensiolabs/SensioDistributionBundle.git", - "reference": "59eac70f15f97ee945924948a6f5e2f6f86b7a4b" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sensiolabs/SensioDistributionBundle/zipball/59eac70f15f97ee945924948a6f5e2f6f86b7a4b", - "reference": "59eac70f15f97ee945924948a6f5e2f6f86b7a4b", - "shasum": "" - }, - "require": { - "php": ">=5.3.9", - "sensiolabs/security-checker": "~5.0", - "symfony/class-loader": "~2.3|~3.0", - "symfony/config": "~2.3|~3.0", - "symfony/dependency-injection": "~2.3|~3.0", - "symfony/filesystem": "~2.3|~3.0", - "symfony/http-kernel": "~2.3|~3.0", - "symfony/process": "~2.3|~3.0" - }, - "type": "symfony-bundle", - "extra": { - "branch-alias": { - "dev-master": "5.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Sensio\\Bundle\\DistributionBundle\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - } - ], - "description": "Base bundle for Symfony Distributions", - "keywords": [ - "configuration", - "distribution" - ], - "time": "2018-12-14T17:36:15+00:00" - }, { "name": "sensio/framework-extra-bundle", "version": "v3.0.29", @@ -2172,52 +2064,6 @@ ], "time": "2017-12-14T19:03:23+00:00" }, - { - "name": "sensiolabs/security-checker", - "version": "v5.0.3", - "source": { - "type": "git", - "url": "https://github.com/sensiolabs/security-checker.git", - "reference": "46be3f58adac13084497961e10eed9a7fb4d44d1" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sensiolabs/security-checker/zipball/46be3f58adac13084497961e10eed9a7fb4d44d1", - "reference": "46be3f58adac13084497961e10eed9a7fb4d44d1", - "shasum": "" - }, - "require": { - "composer/ca-bundle": "^1.0", - "php": ">=5.5.9", - "symfony/console": "~2.7|~3.0|~4.0" - }, - "bin": [ - "security-checker" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "5.0-dev" - } - }, - "autoload": { - "psr-4": { - "SensioLabs\\Security\\": "SensioLabs/Security" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien.potencier@gmail.com" - } - ], - "description": "A security checker for your composer.lock", - "time": "2018-12-19T17:14:59+00:00" - }, { "name": "sentry/sentry", "version": "1.10.0", From c88cad6c146abcd5c832107842624c2c96560cc3 Mon Sep 17 00:00:00 2001 From: Alexey Skobkin Date: Sun, 20 Jan 2019 02:39:06 +0300 Subject: [PATCH 03/13] composer update sensio/framework-extra-bundle (v3.0.29 => v5.2.4) --- composer.json | 2 +- composer.lock | 49 +++++++++++++++++++++++++------------------------ 2 files changed, 26 insertions(+), 25 deletions(-) diff --git a/composer.json b/composer.json index bc92113..32c82fe 100644 --- a/composer.json +++ b/composer.json @@ -16,7 +16,7 @@ "doctrine/doctrine-migrations-bundle": "^2.0", "doctrine/orm": "^2.5", "incenteev/composer-parameter-handler": "^2.0", - "sensio/framework-extra-bundle": "^3.0.2", + "sensio/framework-extra-bundle": "^5", "sentry/sentry-symfony": "^2.2", "symfony/monolog-bundle": "^3.1", "symfony/symfony": "^3.4", diff --git a/composer.lock b/composer.lock index 32ded92..7e5c867 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "8a652239de8a0748004c6d50b98f3c3b", + "content-hash": "0218e8260fd98189a3dccdd39583ddff", "packages": [ { "name": "doctrine/annotations", @@ -1996,38 +1996,39 @@ }, { "name": "sensio/framework-extra-bundle", - "version": "v3.0.29", + "version": "v5.2.4", "source": { "type": "git", "url": "https://github.com/sensiolabs/SensioFrameworkExtraBundle.git", - "reference": "bb907234df776b68922eb4b25bfa061683597b6a" + "reference": "1fdf591c4b388e62dbb2579de89c1560b33f865d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sensiolabs/SensioFrameworkExtraBundle/zipball/bb907234df776b68922eb4b25bfa061683597b6a", - "reference": "bb907234df776b68922eb4b25bfa061683597b6a", + "url": "https://api.github.com/repos/sensiolabs/SensioFrameworkExtraBundle/zipball/1fdf591c4b388e62dbb2579de89c1560b33f865d", + "reference": "1fdf591c4b388e62dbb2579de89c1560b33f865d", "shasum": "" }, "require": { - "doctrine/common": "~2.2", - "symfony/dependency-injection": "~2.3|~3.0", - "symfony/framework-bundle": "~2.3|~3.0|~4.0" + "doctrine/common": "^2.2", + "symfony/config": "^3.3|^4.0", + "symfony/dependency-injection": "^3.3|^4.0", + "symfony/framework-bundle": "^3.4|^4.0", + "symfony/http-kernel": "^3.3|^4.0" }, "require-dev": { - "doctrine/doctrine-bundle": "~1.5", - "doctrine/orm": "~2.4,>=2.4.5", - "symfony/asset": "~2.7|~3.0|~4.0", - "symfony/browser-kit": "~2.3|~3.0|~4.0", - "symfony/dom-crawler": "~2.3|~3.0|~4.0", - "symfony/expression-language": "~2.4|~3.0|~4.0", - "symfony/finder": "~2.3|~3.0|~4.0", - "symfony/phpunit-bridge": "~3.2|~4.0", - "symfony/psr-http-message-bridge": "^0.3|^1.0", - "symfony/security-bundle": "~2.4|~3.0|~4.0", - "symfony/templating": "~2.3|~3.0|~4.0", - "symfony/translation": "~2.3|~3.0|~4.0", - "symfony/twig-bundle": "~2.3|~3.0|~4.0", - "symfony/yaml": "~2.3|~3.0|~4.0", + "doctrine/doctrine-bundle": "^1.6", + "doctrine/orm": "^2.5", + "symfony/browser-kit": "^3.3|^4.0", + "symfony/dom-crawler": "^3.3|^4.0", + "symfony/expression-language": "^3.3|^4.0", + "symfony/finder": "^3.3|^4.0", + "symfony/monolog-bridge": "^3.0|^4.0", + "symfony/monolog-bundle": "^3.2", + "symfony/phpunit-bridge": "^3.4.19|^4.1.8", + "symfony/psr-http-message-bridge": "^0.3", + "symfony/security-bundle": "^3.3|^4.0", + "symfony/twig-bundle": "^3.3|^4.0", + "symfony/yaml": "^3.3|^4.0", "twig/twig": "~1.12|~2.0", "zendframework/zend-diactoros": "^1.3" }, @@ -2039,7 +2040,7 @@ "type": "symfony-bundle", "extra": { "branch-alias": { - "dev-master": "3.0.x-dev" + "dev-master": "5.2.x-dev" } }, "autoload": { @@ -2062,7 +2063,7 @@ "annotations", "controllers" ], - "time": "2017-12-14T19:03:23+00:00" + "time": "2018-12-11T16:59:23+00:00" }, { "name": "sentry/sentry", From 95c652e4d63134175f19f6140d681d4e6e67b359 Mon Sep 17 00:00:00 2001 From: Alexey Skobkin Date: Sun, 20 Jan 2019 02:42:01 +0300 Subject: [PATCH 04/13] Missing bundle fix in kernel. --- app/AppKernel.php | 1 - 1 file changed, 1 deletion(-) diff --git a/app/AppKernel.php b/app/AppKernel.php index 181b93c..854180d 100644 --- a/app/AppKernel.php +++ b/app/AppKernel.php @@ -25,7 +25,6 @@ class AppKernel extends Kernel $bundles[] = new Symfony\Bundle\DebugBundle\DebugBundle(); $bundles[] = new Symfony\Bundle\WebProfilerBundle\WebProfilerBundle(); $bundles[] = new Symfony\Bundle\WebServerBundle\WebServerBundle(); - $bundles[] = new Sensio\Bundle\DistributionBundle\SensioDistributionBundle(); } return $bundles; From da13c321fee8139bf4ae1ed91644c68dc6676015 Mon Sep 17 00:00:00 2001 From: Alexey Skobkin Date: Sun, 20 Jan 2019 04:52:57 +0300 Subject: [PATCH 05/13] Symfony update to 4.2 and Flex. File hierarchy updated according to Flex. Deps reinstall and remaining refactoring are needed. --- .env.dist | 21 + .gitignore | 16 +- app/.htaccess | 7 - app/AppCache.php | 9 - app/AppKernel.php | 37 - app/SymfonyRequirements.php | 810 ------------------ app/autoload.php | 13 - app/check.php | 145 ---- app/config/config.yml | 63 -- app/config/config_test.yml | 20 - app/config/parameters.yml.dist | 18 - app/config/routing.yml | 21 - app/config/routing_dev.yml | 14 - app/config/services.yml | 30 - app/console | 20 - app/phpunit.xml.dist | 37 - bin/console | 28 + bin/doctrine | 1 + bin/doctrine-dbal | 1 + bin/doctrine-migrations | 1 + bin/sentry | 1 + composer.json | 47 +- composer.lock | 432 +++++----- config/bootstrap.php | 17 + config/bundles.php | 17 + .../packages/dev/monolog.yaml | 13 - config/packages/dev/routing.yaml | 3 + config/packages/dev/web_profiler.yaml | 3 + config/packages/doctrine.yaml | 14 + config/packages/doctrine_migrations.yaml | 3 + config/packages/form.yaml | 3 + config/packages/framework.yaml | 12 + .../packages/prod/monolog.yaml | 13 - config/packages/prod/sentry.yaml | 2 + config/packages/routing.yaml | 3 + .../packages/security.yaml | 0 config/packages/sensio_framework_extra.yaml | 3 + config/packages/sentry.yaml | 3 + config/packages/serializer.yaml | 3 + config/packages/test/doctrine.yaml | 6 + config/packages/test/framework.yaml | 6 + config/packages/test/web_profiler.yaml | 3 + config/packages/translation.yaml | 7 + config/packages/twig.yaml | 6 + config/packages/validation.yaml | 3 + config/routes.yaml | 21 + config/routes/dev/twig.yaml | 3 + config/routes/dev/web_profiles.yaml | 7 + config/services.yaml | 24 + .../Resources/public => public}/css/base.css | 0 {web => public}/favicon.ico | Bin .../public => public}/images/favicon.ico | Bin public/index.php | 17 + .../public => public}/js/copypaste.js | 0 {web => public}/robots.txt | 0 .../DropExpiredPasteCommand.php} | 30 +- .../Controller/PasteController.php | 79 +- .../DataFixtures/ORM/LoadLanguages.php | 4 +- .../CopyPasteBundle => }/Entity/Copypaste.php | 164 +--- .../CopyPasteBundle => }/Entity/Language.php | 2 +- .../Form/CopypasteType.php | 22 +- .../Form/FakeCaptchaType.php | 12 +- src/Kernel.php | 39 + .../Migrations}/Version20150302205121.php | 2 +- .../Migrations}/Version20150302213116.php | 2 +- .../Migrations}/Version20150302223210.php | 2 +- .../Migrations}/Version20150303224825.php | 2 +- .../Migrations}/Version20150305184842.php | 2 +- .../Migrations}/Version20150316014139.php | 2 +- .../DependencyInjection/Configuration.php | 29 - .../SkobkinCopyPasteExtension.php | 27 - .../SkobkinCopyPasteBundle.php | 9 - symfony.lock | 11 + .../views => templates}/Form/fields.html.twig | 0 .../Form/form_paste_create.html.twig | 0 .../views => templates}/Paste/new.html.twig | 0 .../views => templates}/Paste/show.html.twig | 0 .../views => templates}/base.html.twig | 6 +- .../views => templates}/layout.html.twig | 2 +- .../views => templates}/sidebar.html.twig | 0 {app/cache => tests}/.gitkeep | 0 .../messages.ru.xliff | 0 {app/logs => var/cache}/.gitkeep | 0 var/log/.gitkeep | 0 web/.htaccess | 62 -- web/app.php | 17 - web/app_dev.php | 26 - 87 files changed, 598 insertions(+), 1962 deletions(-) create mode 100644 .env.dist delete mode 100644 app/.htaccess delete mode 100644 app/AppCache.php delete mode 100644 app/AppKernel.php delete mode 100644 app/SymfonyRequirements.php delete mode 100644 app/autoload.php delete mode 100644 app/check.php delete mode 100644 app/config/config.yml delete mode 100644 app/config/config_test.yml delete mode 100644 app/config/parameters.yml.dist delete mode 100644 app/config/routing.yml delete mode 100644 app/config/routing_dev.yml delete mode 100644 app/config/services.yml delete mode 100644 app/console delete mode 100644 app/phpunit.xml.dist create mode 100755 bin/console create mode 120000 bin/doctrine create mode 120000 bin/doctrine-dbal create mode 120000 bin/doctrine-migrations create mode 120000 bin/sentry create mode 100644 config/bootstrap.php create mode 100644 config/bundles.php rename app/config/config_dev.yml => config/packages/dev/monolog.yaml (78%) create mode 100644 config/packages/dev/routing.yaml create mode 100644 config/packages/dev/web_profiler.yaml create mode 100644 config/packages/doctrine.yaml create mode 100644 config/packages/doctrine_migrations.yaml create mode 100644 config/packages/form.yaml create mode 100644 config/packages/framework.yaml rename app/config/config_prod.yml => config/packages/prod/monolog.yaml (59%) create mode 100644 config/packages/prod/sentry.yaml create mode 100644 config/packages/routing.yaml rename app/config/security.yml => config/packages/security.yaml (100%) create mode 100644 config/packages/sensio_framework_extra.yaml create mode 100644 config/packages/sentry.yaml create mode 100644 config/packages/serializer.yaml create mode 100644 config/packages/test/doctrine.yaml create mode 100644 config/packages/test/framework.yaml create mode 100644 config/packages/test/web_profiler.yaml create mode 100644 config/packages/translation.yaml create mode 100644 config/packages/twig.yaml create mode 100644 config/packages/validation.yaml create mode 100644 config/routes.yaml create mode 100644 config/routes/dev/twig.yaml create mode 100644 config/routes/dev/web_profiles.yaml create mode 100644 config/services.yaml rename {src/Skobkin/Bundle/CopyPasteBundle/Resources/public => public}/css/base.css (100%) rename {web => public}/favicon.ico (100%) rename {src/Skobkin/Bundle/CopyPasteBundle/Resources/public => public}/images/favicon.ico (100%) create mode 100644 public/index.php rename {src/Skobkin/Bundle/CopyPasteBundle/Resources/public => public}/js/copypaste.js (100%) rename {web => public}/robots.txt (100%) rename src/{Skobkin/Bundle/CopyPasteBundle/Command/DropExpiredCopypastesCommand.php => Command/DropExpiredPasteCommand.php} (56%) rename src/{Skobkin/Bundle/CopyPasteBundle => }/Controller/PasteController.php (75%) rename src/{Skobkin/Bundle/CopyPasteBundle => }/DataFixtures/ORM/LoadLanguages.php (96%) rename src/{Skobkin/Bundle/CopyPasteBundle => }/Entity/Copypaste.php (53%) rename src/{Skobkin/Bundle/CopyPasteBundle => }/Entity/Language.php (97%) rename src/{Skobkin/Bundle/CopyPasteBundle => }/Form/CopypasteType.php (87%) rename src/{Skobkin/Bundle/CopyPasteBundle => }/Form/FakeCaptchaType.php (76%) create mode 100644 src/Kernel.php rename {app/DoctrineMigrations => src/Migrations}/Version20150302205121.php (98%) rename {app/DoctrineMigrations => src/Migrations}/Version20150302213116.php (99%) rename {app/DoctrineMigrations => src/Migrations}/Version20150302223210.php (98%) rename {app/DoctrineMigrations => src/Migrations}/Version20150303224825.php (93%) rename {app/DoctrineMigrations => src/Migrations}/Version20150305184842.php (94%) rename {app/DoctrineMigrations => src/Migrations}/Version20150316014139.php (97%) delete mode 100644 src/Skobkin/Bundle/CopyPasteBundle/DependencyInjection/Configuration.php delete mode 100644 src/Skobkin/Bundle/CopyPasteBundle/DependencyInjection/SkobkinCopyPasteExtension.php delete mode 100644 src/Skobkin/Bundle/CopyPasteBundle/SkobkinCopyPasteBundle.php create mode 100644 symfony.lock rename {app/Resources/views => templates}/Form/fields.html.twig (100%) rename {app/Resources/views => templates}/Form/form_paste_create.html.twig (100%) rename {app/Resources/views => templates}/Paste/new.html.twig (100%) rename {app/Resources/views => templates}/Paste/show.html.twig (100%) rename {app/Resources/views => templates}/base.html.twig (87%) rename {app/Resources/views => templates}/layout.html.twig (95%) rename {app/Resources/views => templates}/sidebar.html.twig (100%) rename {app/cache => tests}/.gitkeep (100%) rename {app/Resources/translations => translations}/messages.ru.xliff (100%) rename {app/logs => var/cache}/.gitkeep (100%) create mode 100644 var/log/.gitkeep delete mode 100644 web/.htaccess delete mode 100644 web/app.php delete mode 100644 web/app_dev.php diff --git a/.env.dist b/.env.dist new file mode 100644 index 0000000..7d0f3ea --- /dev/null +++ b/.env.dist @@ -0,0 +1,21 @@ +# This file is a "template" of which env vars need to be defined for your application +# Copy this file to .env file for development, create environment variables when deploying to production +# https://symfony.com/doc/current/best_practices/configuration.html#infrastructure-related-configuration + +###> symfony/framework-bundle ### +APP_ENV=dev +APP_SECRET=xxx +#TRUSTED_PROXIES=127.0.0.1,127.0.0.2 +#TRUSTED_HOSTS=localhost,example.com +###< symfony/framework-bundle ### + +###> doctrine/doctrine-bundle ### +# Format described at http://docs.doctrine-project.org/projects/doctrine-dbal/en/latest/reference/configuration.html#connecting-using-a-url +# For an SQLite database, use: "sqlite:///%kernel.project_dir%/var/data.db" +# Configure your db driver and server_version in config/packages/doctrine.yaml +DATABASE_URL=postgres://$PGUSER:$PGPASSWORD@127.0.0.1:5436/test?application_name=point_tools +###< doctrine/doctrine-bundle ### + +###> sentry/sentry-symfony ### +SENTRY_DSN= +###< sentry/sentry-symfony ### \ No newline at end of file diff --git a/.gitignore b/.gitignore index 8e1dd0f..5b2d4da 100644 --- a/.gitignore +++ b/.gitignore @@ -1,13 +1,7 @@ /.idea/ -/web/bundles/ -/app/bootstrap.php.cache -/app/cache/* -/app/config/parameters.yml -/app/logs/* -!app/cache/.gitkeep -!app/logs/.gitkeep -/app/phpunit.xml -/build/ +/var/cache/* +/var/log/* +!/var/cache/.gitkeep +!/var/log/.gitkeep /vendor/ -/bin/ -/composer.phar +/.env \ No newline at end of file diff --git a/app/.htaccess b/app/.htaccess deleted file mode 100644 index fb1de45..0000000 --- a/app/.htaccess +++ /dev/null @@ -1,7 +0,0 @@ - - Require all denied - - - Order deny,allow - Deny from all - diff --git a/app/AppCache.php b/app/AppCache.php deleted file mode 100644 index ddb51db..0000000 --- a/app/AppCache.php +++ /dev/null @@ -1,9 +0,0 @@ -getEnvironment(), array('dev', 'test'))) { - $bundles[] = new Symfony\Bundle\DebugBundle\DebugBundle(); - $bundles[] = new Symfony\Bundle\WebProfilerBundle\WebProfilerBundle(); - $bundles[] = new Symfony\Bundle\WebServerBundle\WebServerBundle(); - } - - return $bundles; - } - - public function registerContainerConfiguration(LoaderInterface $loader) - { - $loader->load($this->getRootDir().'/config/config_'.$this->getEnvironment().'.yml'); - } -} diff --git a/app/SymfonyRequirements.php b/app/SymfonyRequirements.php deleted file mode 100644 index 4a1fcc6..0000000 --- a/app/SymfonyRequirements.php +++ /dev/null @@ -1,810 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -/* - * Users of PHP 5.2 should be able to run the requirements checks. - * This is why the file and all classes must be compatible with PHP 5.2+ - * (e.g. not using namespaces and closures). - * - * ************** CAUTION ************** - * - * DO NOT EDIT THIS FILE as it will be overridden by Composer as part of - * the installation/update process. The original file resides in the - * SensioDistributionBundle. - * - * ************** CAUTION ************** - */ - -/** - * Represents a single PHP requirement, e.g. an installed extension. - * It can be a mandatory requirement or an optional recommendation. - * There is a special subclass, named PhpIniRequirement, to check a php.ini configuration. - * - * @author Tobias Schultze - */ -class Requirement -{ - private $fulfilled; - private $testMessage; - private $helpText; - private $helpHtml; - private $optional; - - /** - * Constructor that initializes the requirement. - * - * @param bool $fulfilled Whether the requirement is fulfilled - * @param string $testMessage The message for testing the requirement - * @param string $helpHtml The help text formatted in HTML for resolving the problem - * @param string|null $helpText The help text (when null, it will be inferred from $helpHtml, i.e. stripped from HTML tags) - * @param bool $optional Whether this is only an optional recommendation not a mandatory requirement - */ - public function __construct($fulfilled, $testMessage, $helpHtml, $helpText = null, $optional = false) - { - $this->fulfilled = (bool) $fulfilled; - $this->testMessage = (string) $testMessage; - $this->helpHtml = (string) $helpHtml; - $this->helpText = null === $helpText ? strip_tags($this->helpHtml) : (string) $helpText; - $this->optional = (bool) $optional; - } - - /** - * Returns whether the requirement is fulfilled. - * - * @return bool true if fulfilled, otherwise false - */ - public function isFulfilled() - { - return $this->fulfilled; - } - - /** - * Returns the message for testing the requirement. - * - * @return string The test message - */ - public function getTestMessage() - { - return $this->testMessage; - } - - /** - * Returns the help text for resolving the problem. - * - * @return string The help text - */ - public function getHelpText() - { - return $this->helpText; - } - - /** - * Returns the help text formatted in HTML. - * - * @return string The HTML help - */ - public function getHelpHtml() - { - return $this->helpHtml; - } - - /** - * Returns whether this is only an optional recommendation and not a mandatory requirement. - * - * @return bool true if optional, false if mandatory - */ - public function isOptional() - { - return $this->optional; - } -} - -/** - * Represents a PHP requirement in form of a php.ini configuration. - * - * @author Tobias Schultze - */ -class PhpIniRequirement extends Requirement -{ - /** - * Constructor that initializes the requirement. - * - * @param string $cfgName The configuration name used for ini_get() - * @param bool|callback $evaluation Either a boolean indicating whether the configuration should evaluate to true or false, - * or a callback function receiving the configuration value as parameter to determine the fulfillment of the requirement - * @param bool $approveCfgAbsence If true the Requirement will be fulfilled even if the configuration option does not exist, i.e. ini_get() returns false. - * This is helpful for abandoned configs in later PHP versions or configs of an optional extension, like Suhosin. - * Example: You require a config to be true but PHP later removes this config and defaults it to true internally. - * @param string|null $testMessage The message for testing the requirement (when null and $evaluation is a boolean a default message is derived) - * @param string|null $helpHtml The help text formatted in HTML for resolving the problem (when null and $evaluation is a boolean a default help is derived) - * @param string|null $helpText The help text (when null, it will be inferred from $helpHtml, i.e. stripped from HTML tags) - * @param bool $optional Whether this is only an optional recommendation not a mandatory requirement - */ - public function __construct($cfgName, $evaluation, $approveCfgAbsence = false, $testMessage = null, $helpHtml = null, $helpText = null, $optional = false) - { - $cfgValue = ini_get($cfgName); - - if (is_callable($evaluation)) { - if (null === $testMessage || null === $helpHtml) { - throw new InvalidArgumentException('You must provide the parameters testMessage and helpHtml for a callback evaluation.'); - } - - $fulfilled = call_user_func($evaluation, $cfgValue); - } else { - if (null === $testMessage) { - $testMessage = sprintf('%s %s be %s in php.ini', - $cfgName, - $optional ? 'should' : 'must', - $evaluation ? 'enabled' : 'disabled' - ); - } - - if (null === $helpHtml) { - $helpHtml = sprintf('Set %s to %s in php.ini*.', - $cfgName, - $evaluation ? 'on' : 'off' - ); - } - - $fulfilled = $evaluation == $cfgValue; - } - - parent::__construct($fulfilled || ($approveCfgAbsence && false === $cfgValue), $testMessage, $helpHtml, $helpText, $optional); - } -} - -/** - * A RequirementCollection represents a set of Requirement instances. - * - * @author Tobias Schultze - */ -class RequirementCollection implements IteratorAggregate -{ - /** - * @var Requirement[] - */ - private $requirements = array(); - - /** - * Gets the current RequirementCollection as an Iterator. - * - * @return Traversable A Traversable interface - */ - public function getIterator() - { - return new ArrayIterator($this->requirements); - } - - /** - * Adds a Requirement. - * - * @param Requirement $requirement A Requirement instance - */ - public function add(Requirement $requirement) - { - $this->requirements[] = $requirement; - } - - /** - * Adds a mandatory requirement. - * - * @param bool $fulfilled Whether the requirement is fulfilled - * @param string $testMessage The message for testing the requirement - * @param string $helpHtml The help text formatted in HTML for resolving the problem - * @param string|null $helpText The help text (when null, it will be inferred from $helpHtml, i.e. stripped from HTML tags) - */ - public function addRequirement($fulfilled, $testMessage, $helpHtml, $helpText = null) - { - $this->add(new Requirement($fulfilled, $testMessage, $helpHtml, $helpText, false)); - } - - /** - * Adds an optional recommendation. - * - * @param bool $fulfilled Whether the recommendation is fulfilled - * @param string $testMessage The message for testing the recommendation - * @param string $helpHtml The help text formatted in HTML for resolving the problem - * @param string|null $helpText The help text (when null, it will be inferred from $helpHtml, i.e. stripped from HTML tags) - */ - public function addRecommendation($fulfilled, $testMessage, $helpHtml, $helpText = null) - { - $this->add(new Requirement($fulfilled, $testMessage, $helpHtml, $helpText, true)); - } - - /** - * Adds a mandatory requirement in form of a php.ini configuration. - * - * @param string $cfgName The configuration name used for ini_get() - * @param bool|callback $evaluation Either a boolean indicating whether the configuration should evaluate to true or false, - * or a callback function receiving the configuration value as parameter to determine the fulfillment of the requirement - * @param bool $approveCfgAbsence If true the Requirement will be fulfilled even if the configuration option does not exist, i.e. ini_get() returns false. - * This is helpful for abandoned configs in later PHP versions or configs of an optional extension, like Suhosin. - * Example: You require a config to be true but PHP later removes this config and defaults it to true internally. - * @param string $testMessage The message for testing the requirement (when null and $evaluation is a boolean a default message is derived) - * @param string $helpHtml The help text formatted in HTML for resolving the problem (when null and $evaluation is a boolean a default help is derived) - * @param string|null $helpText The help text (when null, it will be inferred from $helpHtml, i.e. stripped from HTML tags) - */ - public function addPhpIniRequirement($cfgName, $evaluation, $approveCfgAbsence = false, $testMessage = null, $helpHtml = null, $helpText = null) - { - $this->add(new PhpIniRequirement($cfgName, $evaluation, $approveCfgAbsence, $testMessage, $helpHtml, $helpText, false)); - } - - /** - * Adds an optional recommendation in form of a php.ini configuration. - * - * @param string $cfgName The configuration name used for ini_get() - * @param bool|callback $evaluation Either a boolean indicating whether the configuration should evaluate to true or false, - * or a callback function receiving the configuration value as parameter to determine the fulfillment of the requirement - * @param bool $approveCfgAbsence If true the Requirement will be fulfilled even if the configuration option does not exist, i.e. ini_get() returns false. - * This is helpful for abandoned configs in later PHP versions or configs of an optional extension, like Suhosin. - * Example: You require a config to be true but PHP later removes this config and defaults it to true internally. - * @param string $testMessage The message for testing the requirement (when null and $evaluation is a boolean a default message is derived) - * @param string $helpHtml The help text formatted in HTML for resolving the problem (when null and $evaluation is a boolean a default help is derived) - * @param string|null $helpText The help text (when null, it will be inferred from $helpHtml, i.e. stripped from HTML tags) - */ - public function addPhpIniRecommendation($cfgName, $evaluation, $approveCfgAbsence = false, $testMessage = null, $helpHtml = null, $helpText = null) - { - $this->add(new PhpIniRequirement($cfgName, $evaluation, $approveCfgAbsence, $testMessage, $helpHtml, $helpText, true)); - } - - /** - * Adds a requirement collection to the current set of requirements. - * - * @param RequirementCollection $collection A RequirementCollection instance - */ - public function addCollection(RequirementCollection $collection) - { - $this->requirements = array_merge($this->requirements, $collection->all()); - } - - /** - * Returns both requirements and recommendations. - * - * @return Requirement[] - */ - public function all() - { - return $this->requirements; - } - - /** - * Returns all mandatory requirements. - * - * @return Requirement[] - */ - public function getRequirements() - { - $array = array(); - foreach ($this->requirements as $req) { - if (!$req->isOptional()) { - $array[] = $req; - } - } - - return $array; - } - - /** - * Returns the mandatory requirements that were not met. - * - * @return Requirement[] - */ - public function getFailedRequirements() - { - $array = array(); - foreach ($this->requirements as $req) { - if (!$req->isFulfilled() && !$req->isOptional()) { - $array[] = $req; - } - } - - return $array; - } - - /** - * Returns all optional recommendations. - * - * @return Requirement[] - */ - public function getRecommendations() - { - $array = array(); - foreach ($this->requirements as $req) { - if ($req->isOptional()) { - $array[] = $req; - } - } - - return $array; - } - - /** - * Returns the recommendations that were not met. - * - * @return Requirement[] - */ - public function getFailedRecommendations() - { - $array = array(); - foreach ($this->requirements as $req) { - if (!$req->isFulfilled() && $req->isOptional()) { - $array[] = $req; - } - } - - return $array; - } - - /** - * Returns whether a php.ini configuration is not correct. - * - * @return bool php.ini configuration problem? - */ - public function hasPhpIniConfigIssue() - { - foreach ($this->requirements as $req) { - if (!$req->isFulfilled() && $req instanceof PhpIniRequirement) { - return true; - } - } - - return false; - } - - /** - * Returns the PHP configuration file (php.ini) path. - * - * @return string|false php.ini file path - */ - public function getPhpIniConfigPath() - { - return get_cfg_var('cfg_file_path'); - } -} - -/** - * This class specifies all requirements and optional recommendations that - * are necessary to run the Symfony Standard Edition. - * - * @author Tobias Schultze - * @author Fabien Potencier - */ -class SymfonyRequirements extends RequirementCollection -{ - const LEGACY_REQUIRED_PHP_VERSION = '5.3.3'; - const REQUIRED_PHP_VERSION = '5.5.9'; - - /** - * Constructor that initializes the requirements. - */ - public function __construct() - { - /* mandatory requirements follow */ - - $installedPhpVersion = PHP_VERSION; - $requiredPhpVersion = $this->getPhpRequiredVersion(); - - $this->addRecommendation( - $requiredPhpVersion, - 'Vendors should be installed in order to check all requirements.', - 'Run the composer install command.', - 'Run the "composer install" command.' - ); - - if (false !== $requiredPhpVersion) { - $this->addRequirement( - version_compare($installedPhpVersion, $requiredPhpVersion, '>='), - sprintf('PHP version must be at least %s (%s installed)', $requiredPhpVersion, $installedPhpVersion), - sprintf('You are running PHP version "%s", but Symfony needs at least PHP "%s" to run. - Before using Symfony, upgrade your PHP installation, preferably to the latest version.', - $installedPhpVersion, $requiredPhpVersion), - sprintf('Install PHP %s or newer (installed version is %s)', $requiredPhpVersion, $installedPhpVersion) - ); - } - - $this->addRequirement( - version_compare($installedPhpVersion, '5.3.16', '!='), - 'PHP version must not be 5.3.16 as Symfony won\'t work properly with it', - 'Install PHP 5.3.17 or newer (or downgrade to an earlier PHP version)' - ); - - $this->addRequirement( - is_dir(__DIR__.'/../vendor/composer'), - 'Vendor libraries must be installed', - 'Vendor libraries are missing. Install composer following instructions from http://getcomposer.org/. '. - 'Then run "php composer.phar install" to install them.' - ); - - $cacheDir = is_dir(__DIR__.'/../var/cache') ? __DIR__.'/../var/cache' : __DIR__.'/cache'; - - $this->addRequirement( - is_writable($cacheDir), - 'app/cache/ or var/cache/ directory must be writable', - 'Change the permissions of either "app/cache/" or "var/cache/" directory so that the web server can write into it.' - ); - - $logsDir = is_dir(__DIR__.'/../var/logs') ? __DIR__.'/../var/logs' : __DIR__.'/logs'; - - $this->addRequirement( - is_writable($logsDir), - 'app/logs/ or var/logs/ directory must be writable', - 'Change the permissions of either "app/logs/" or "var/logs/" directory so that the web server can write into it.' - ); - - if (version_compare($installedPhpVersion, '7.0.0', '<')) { - $this->addPhpIniRequirement( - 'date.timezone', true, false, - 'date.timezone setting must be set', - 'Set the "date.timezone" setting in php.ini* (like Europe/Paris).' - ); - } - - if (false !== $requiredPhpVersion && version_compare($installedPhpVersion, $requiredPhpVersion, '>=')) { - $this->addRequirement( - in_array(@date_default_timezone_get(), DateTimeZone::listIdentifiers(), true), - sprintf('Configured default timezone "%s" must be supported by your installation of PHP', @date_default_timezone_get()), - 'Your default timezone is not supported by PHP. Check for typos in your php.ini file and have a look at the list of deprecated timezones at http://php.net/manual/en/timezones.others.php.' - ); - } - - $this->addRequirement( - function_exists('iconv'), - 'iconv() must be available', - 'Install and enable the iconv extension.' - ); - - $this->addRequirement( - function_exists('json_encode'), - 'json_encode() must be available', - 'Install and enable the JSON extension.' - ); - - $this->addRequirement( - function_exists('session_start'), - 'session_start() must be available', - 'Install and enable the session extension.' - ); - - $this->addRequirement( - function_exists('ctype_alpha'), - 'ctype_alpha() must be available', - 'Install and enable the ctype extension.' - ); - - $this->addRequirement( - function_exists('token_get_all'), - 'token_get_all() must be available', - 'Install and enable the Tokenizer extension.' - ); - - $this->addRequirement( - function_exists('simplexml_import_dom'), - 'simplexml_import_dom() must be available', - 'Install and enable the SimpleXML extension.' - ); - - if (function_exists('apc_store') && ini_get('apc.enabled')) { - if (version_compare($installedPhpVersion, '5.4.0', '>=')) { - $this->addRequirement( - version_compare(phpversion('apc'), '3.1.13', '>='), - 'APC version must be at least 3.1.13 when using PHP 5.4', - 'Upgrade your APC extension (3.1.13+).' - ); - } else { - $this->addRequirement( - version_compare(phpversion('apc'), '3.0.17', '>='), - 'APC version must be at least 3.0.17', - 'Upgrade your APC extension (3.0.17+).' - ); - } - } - - $this->addPhpIniRequirement('detect_unicode', false); - - if (extension_loaded('suhosin')) { - $this->addPhpIniRequirement( - 'suhosin.executor.include.whitelist', - create_function('$cfgValue', 'return false !== stripos($cfgValue, "phar");'), - false, - 'suhosin.executor.include.whitelist must be configured correctly in php.ini', - 'Add "phar" to suhosin.executor.include.whitelist in php.ini*.' - ); - } - - if (extension_loaded('xdebug')) { - $this->addPhpIniRequirement( - 'xdebug.show_exception_trace', false, true - ); - - $this->addPhpIniRequirement( - 'xdebug.scream', false, true - ); - - $this->addPhpIniRecommendation( - 'xdebug.max_nesting_level', - create_function('$cfgValue', 'return $cfgValue > 100;'), - true, - 'xdebug.max_nesting_level should be above 100 in php.ini', - 'Set "xdebug.max_nesting_level" to e.g. "250" in php.ini* to stop Xdebug\'s infinite recursion protection erroneously throwing a fatal error in your project.' - ); - } - - $pcreVersion = defined('PCRE_VERSION') ? (float) PCRE_VERSION : null; - - $this->addRequirement( - null !== $pcreVersion, - 'PCRE extension must be available', - 'Install the PCRE extension (version 8.0+).' - ); - - if (extension_loaded('mbstring')) { - $this->addPhpIniRequirement( - 'mbstring.func_overload', - create_function('$cfgValue', 'return (int) $cfgValue === 0;'), - true, - 'string functions should not be overloaded', - 'Set "mbstring.func_overload" to 0 in php.ini* to disable function overloading by the mbstring extension.' - ); - } - - /* optional recommendations follow */ - - if (file_exists(__DIR__.'/../vendor/composer')) { - require_once __DIR__.'/../vendor/autoload.php'; - - try { - $r = new ReflectionClass('Sensio\Bundle\DistributionBundle\SensioDistributionBundle'); - - $contents = file_get_contents(dirname($r->getFileName()).'/Resources/skeleton/app/SymfonyRequirements.php'); - } catch (ReflectionException $e) { - $contents = ''; - } - $this->addRecommendation( - file_get_contents(__FILE__) === $contents, - 'Requirements file should be up-to-date', - 'Your requirements file is outdated. Run composer install and re-check your configuration.' - ); - } - - $this->addRecommendation( - version_compare($installedPhpVersion, '5.3.4', '>='), - 'You should use at least PHP 5.3.4 due to PHP bug #52083 in earlier versions', - 'Your project might malfunction randomly due to PHP bug #52083 ("Notice: Trying to get property of non-object"). Install PHP 5.3.4 or newer.' - ); - - $this->addRecommendation( - version_compare($installedPhpVersion, '5.3.8', '>='), - 'When using annotations you should have at least PHP 5.3.8 due to PHP bug #55156', - 'Install PHP 5.3.8 or newer if your project uses annotations.' - ); - - $this->addRecommendation( - version_compare($installedPhpVersion, '5.4.0', '!='), - 'You should not use PHP 5.4.0 due to the PHP bug #61453', - 'Your project might not work properly due to the PHP bug #61453 ("Cannot dump definitions which have method calls"). Install PHP 5.4.1 or newer.' - ); - - $this->addRecommendation( - version_compare($installedPhpVersion, '5.4.11', '>='), - 'When using the logout handler from the Symfony Security Component, you should have at least PHP 5.4.11 due to PHP bug #63379 (as a workaround, you can also set invalidate_session to false in the security logout handler configuration)', - 'Install PHP 5.4.11 or newer if your project uses the logout handler from the Symfony Security Component.' - ); - - $this->addRecommendation( - (version_compare($installedPhpVersion, '5.3.18', '>=') && version_compare($installedPhpVersion, '5.4.0', '<')) - || - version_compare($installedPhpVersion, '5.4.8', '>='), - 'You should use PHP 5.3.18+ or PHP 5.4.8+ to always get nice error messages for fatal errors in the development environment due to PHP bug #61767/#60909', - 'Install PHP 5.3.18+ or PHP 5.4.8+ if you want nice error messages for all fatal errors in the development environment.' - ); - - if (null !== $pcreVersion) { - $this->addRecommendation( - $pcreVersion >= 8.0, - sprintf('PCRE extension should be at least version 8.0 (%s installed)', $pcreVersion), - 'PCRE 8.0+ is preconfigured in PHP since 5.3.2 but you are using an outdated version of it. Symfony probably works anyway but it is recommended to upgrade your PCRE extension.' - ); - } - - $this->addRecommendation( - class_exists('DomDocument'), - 'PHP-DOM and PHP-XML modules should be installed', - 'Install and enable the PHP-DOM and the PHP-XML modules.' - ); - - $this->addRecommendation( - function_exists('mb_strlen'), - 'mb_strlen() should be available', - 'Install and enable the mbstring extension.' - ); - - $this->addRecommendation( - function_exists('utf8_decode'), - 'utf8_decode() should be available', - 'Install and enable the XML extension.' - ); - - $this->addRecommendation( - function_exists('filter_var'), - 'filter_var() should be available', - 'Install and enable the filter extension.' - ); - - if (!defined('PHP_WINDOWS_VERSION_BUILD')) { - $this->addRecommendation( - function_exists('posix_isatty'), - 'posix_isatty() should be available', - 'Install and enable the php_posix extension (used to colorize the CLI output).' - ); - } - - $this->addRecommendation( - extension_loaded('intl'), - 'intl extension should be available', - 'Install and enable the intl extension (used for validators).' - ); - - if (extension_loaded('intl')) { - // in some WAMP server installations, new Collator() returns null - $this->addRecommendation( - null !== new Collator('fr_FR'), - 'intl extension should be correctly configured', - 'The intl extension does not behave properly. This problem is typical on PHP 5.3.X x64 WIN builds.' - ); - - // check for compatible ICU versions (only done when you have the intl extension) - if (defined('INTL_ICU_VERSION')) { - $version = INTL_ICU_VERSION; - } else { - $reflector = new ReflectionExtension('intl'); - - ob_start(); - $reflector->info(); - $output = strip_tags(ob_get_clean()); - - preg_match('/^ICU version +(?:=> )?(.*)$/m', $output, $matches); - $version = $matches[1]; - } - - $this->addRecommendation( - version_compare($version, '4.0', '>='), - 'intl ICU version should be at least 4+', - 'Upgrade your intl extension with a newer ICU version (4+).' - ); - - if (class_exists('Symfony\Component\Intl\Intl')) { - $this->addRecommendation( - \Symfony\Component\Intl\Intl::getIcuDataVersion() <= \Symfony\Component\Intl\Intl::getIcuVersion(), - sprintf('intl ICU version installed on your system is outdated (%s) and does not match the ICU data bundled with Symfony (%s)', \Symfony\Component\Intl\Intl::getIcuVersion(), \Symfony\Component\Intl\Intl::getIcuDataVersion()), - 'To get the latest internationalization data upgrade the ICU system package and the intl PHP extension.' - ); - if (\Symfony\Component\Intl\Intl::getIcuDataVersion() <= \Symfony\Component\Intl\Intl::getIcuVersion()) { - $this->addRecommendation( - \Symfony\Component\Intl\Intl::getIcuDataVersion() === \Symfony\Component\Intl\Intl::getIcuVersion(), - sprintf('intl ICU version installed on your system (%s) does not match the ICU data bundled with Symfony (%s)', \Symfony\Component\Intl\Intl::getIcuVersion(), \Symfony\Component\Intl\Intl::getIcuDataVersion()), - 'To avoid internationalization data inconsistencies upgrade the symfony/intl component.' - ); - } - } - - $this->addPhpIniRecommendation( - 'intl.error_level', - create_function('$cfgValue', 'return (int) $cfgValue === 0;'), - true, - 'intl.error_level should be 0 in php.ini', - 'Set "intl.error_level" to "0" in php.ini* to inhibit the messages when an error occurs in ICU functions.' - ); - } - - $accelerator = - (extension_loaded('eaccelerator') && ini_get('eaccelerator.enable')) - || - (extension_loaded('apc') && ini_get('apc.enabled')) - || - (extension_loaded('Zend Optimizer+') && ini_get('zend_optimizerplus.enable')) - || - (extension_loaded('Zend OPcache') && ini_get('opcache.enable')) - || - (extension_loaded('xcache') && ini_get('xcache.cacher')) - || - (extension_loaded('wincache') && ini_get('wincache.ocenabled')) - ; - - $this->addRecommendation( - $accelerator, - 'a PHP accelerator should be installed', - 'Install and/or enable a PHP accelerator (highly recommended).' - ); - - if ('WIN' === strtoupper(substr(PHP_OS, 0, 3))) { - $this->addRecommendation( - $this->getRealpathCacheSize() >= 5 * 1024 * 1024, - 'realpath_cache_size should be at least 5M in php.ini', - 'Setting "realpath_cache_size" to e.g. "5242880" or "5M" in php.ini* may improve performance on Windows significantly in some cases.' - ); - } - - $this->addPhpIniRecommendation('short_open_tag', false); - - $this->addPhpIniRecommendation('magic_quotes_gpc', false, true); - - $this->addPhpIniRecommendation('register_globals', false, true); - - $this->addPhpIniRecommendation('session.auto_start', false); - - $this->addRecommendation( - class_exists('PDO'), - 'PDO should be installed', - 'Install PDO (mandatory for Doctrine).' - ); - - if (class_exists('PDO')) { - $drivers = PDO::getAvailableDrivers(); - $this->addRecommendation( - count($drivers) > 0, - sprintf('PDO should have some drivers installed (currently available: %s)', count($drivers) ? implode(', ', $drivers) : 'none'), - 'Install PDO drivers (mandatory for Doctrine).' - ); - } - } - - /** - * Loads realpath_cache_size from php.ini and converts it to int. - * - * (e.g. 16k is converted to 16384 int) - * - * @return int - */ - protected function getRealpathCacheSize() - { - $size = ini_get('realpath_cache_size'); - $size = trim($size); - $unit = ''; - if (!ctype_digit($size)) { - $unit = strtolower(substr($size, -1, 1)); - $size = (int) substr($size, 0, -1); - } - switch ($unit) { - case 'g': - return $size * 1024 * 1024 * 1024; - case 'm': - return $size * 1024 * 1024; - case 'k': - return $size * 1024; - default: - return (int) $size; - } - } - - /** - * Defines PHP required version from Symfony version. - * - * @return string|false The PHP required version or false if it could not be guessed - */ - protected function getPhpRequiredVersion() - { - if (!file_exists($path = __DIR__.'/../composer.lock')) { - return false; - } - - $composerLock = json_decode(file_get_contents($path), true); - foreach ($composerLock['packages'] as $package) { - $name = $package['name']; - if ('symfony/symfony' !== $name && 'symfony/http-kernel' !== $name) { - continue; - } - - return (int) $package['version'][1] > 2 ? self::REQUIRED_PHP_VERSION : self::LEGACY_REQUIRED_PHP_VERSION; - } - - return false; - } -} diff --git a/app/autoload.php b/app/autoload.php deleted file mode 100644 index 70526bb..0000000 --- a/app/autoload.php +++ /dev/null @@ -1,13 +0,0 @@ -getPhpIniConfigPath(); - -echo_title('Symfony Requirements Checker'); - -echo '> PHP is using the following php.ini file:'.PHP_EOL; -if ($iniPath) { - echo_style('green', ' '.$iniPath); -} else { - echo_style('yellow', ' WARNING: No configuration file (php.ini) used by PHP!'); -} - -echo PHP_EOL.PHP_EOL; - -echo '> Checking Symfony requirements:'.PHP_EOL.' '; - -$messages = array(); -foreach ($symfonyRequirements->getRequirements() as $req) { - if ($helpText = get_error_message($req, $lineSize)) { - echo_style('red', 'E'); - $messages['error'][] = $helpText; - } else { - echo_style('green', '.'); - } -} - -$checkPassed = empty($messages['error']); - -foreach ($symfonyRequirements->getRecommendations() as $req) { - if ($helpText = get_error_message($req, $lineSize)) { - echo_style('yellow', 'W'); - $messages['warning'][] = $helpText; - } else { - echo_style('green', '.'); - } -} - -if ($checkPassed) { - echo_block('success', 'OK', 'Your system is ready to run Symfony projects'); -} else { - echo_block('error', 'ERROR', 'Your system is not ready to run Symfony projects'); - - echo_title('Fix the following mandatory requirements', 'red'); - - foreach ($messages['error'] as $helpText) { - echo ' * '.$helpText.PHP_EOL; - } -} - -if (!empty($messages['warning'])) { - echo_title('Optional recommendations to improve your setup', 'yellow'); - - foreach ($messages['warning'] as $helpText) { - echo ' * '.$helpText.PHP_EOL; - } -} - -echo PHP_EOL; -echo_style('title', 'Note'); -echo ' The command console could use a different php.ini file'.PHP_EOL; -echo_style('title', '~~~~'); -echo ' than the one used with your web server. To be on the'.PHP_EOL; -echo ' safe side, please check the requirements from your web'.PHP_EOL; -echo ' server using the '; -echo_style('yellow', 'web/config.php'); -echo ' script.'.PHP_EOL; -echo PHP_EOL; - -exit($checkPassed ? 0 : 1); - -function get_error_message(Requirement $requirement, $lineSize) -{ - if ($requirement->isFulfilled()) { - return; - } - - $errorMessage = wordwrap($requirement->getTestMessage(), $lineSize - 3, PHP_EOL.' ').PHP_EOL; - $errorMessage .= ' > '.wordwrap($requirement->getHelpText(), $lineSize - 5, PHP_EOL.' > ').PHP_EOL; - - return $errorMessage; -} - -function echo_title($title, $style = null) -{ - $style = $style ?: 'title'; - - echo PHP_EOL; - echo_style($style, $title.PHP_EOL); - echo_style($style, str_repeat('~', strlen($title)).PHP_EOL); - echo PHP_EOL; -} - -function echo_style($style, $message) -{ - // ANSI color codes - $styles = array( - 'reset' => "\033[0m", - 'red' => "\033[31m", - 'green' => "\033[32m", - 'yellow' => "\033[33m", - 'error' => "\033[37;41m", - 'success' => "\033[37;42m", - 'title' => "\033[34m", - ); - $supports = has_color_support(); - - echo($supports ? $styles[$style] : '').$message.($supports ? $styles['reset'] : ''); -} - -function echo_block($style, $title, $message) -{ - $message = ' '.trim($message).' '; - $width = strlen($message); - - echo PHP_EOL.PHP_EOL; - - echo_style($style, str_repeat(' ', $width)); - echo PHP_EOL; - echo_style($style, str_pad(' ['.$title.']', $width, ' ', STR_PAD_RIGHT)); - echo PHP_EOL; - echo_style($style, $message); - echo PHP_EOL; - echo_style($style, str_repeat(' ', $width)); - echo PHP_EOL; -} - -function has_color_support() -{ - static $support; - - if (null === $support) { - if (DIRECTORY_SEPARATOR == '\\') { - $support = false !== getenv('ANSICON') || 'ON' === getenv('ConEmuANSI'); - } else { - $support = function_exists('posix_isatty') && @posix_isatty(STDOUT); - } - } - - return $support; -} diff --git a/app/config/config.yml b/app/config/config.yml deleted file mode 100644 index e5ecb61..0000000 --- a/app/config/config.yml +++ /dev/null @@ -1,63 +0,0 @@ -imports: - - { resource: parameters.yml } - - { resource: security.yml } - - { resource: services.yml } - -framework: - #esi: ~ - translator: { fallbacks: ["%locale%"] } - secret: "%secret%" - router: - resource: "%kernel.root_dir%/config/routing.yml" - strict_requirements: ~ - form: ~ - csrf_protection: ~ - validation: { enable_annotations: true } - #serializer: { enable_annotations: true } - default_locale: '%locale%' - trusted_hosts: ~ - session: - # handler_id set to null will use default session handler from php.ini - handler_id: ~ - fragments: ~ - http_method_override: true - assets: ~ - php_errors: - log: true - -sensio_framework_extra: - router: - annotations: false - -sentry: - dsn: '%sentry_dsn%' - -# Twig Configuration -twig: - debug: "%kernel.debug%" - strict_variables: "%kernel.debug%" - form_themes: - - 'bootstrap_3_layout.html.twig' - - 'Form/fields.html.twig' - -# Doctrine Configuration -doctrine: - dbal: - driver: "%database_driver%" - host: "%database_host%" - port: "%database_port%" - dbname: "%database_name%" - user: "%database_user%" - password: "%database_password%" - charset: UTF8 - - orm: - auto_generate_proxy_classes: "%kernel.debug%" - auto_mapping: true - -doctrine_migrations: - dir_name: "%kernel.root_dir%/DoctrineMigrations" - namespace: Application\Migrations - table_name: migration_versions - name: Application Migrations - diff --git a/app/config/config_test.yml b/app/config/config_test.yml deleted file mode 100644 index 0d900f7..0000000 --- a/app/config/config_test.yml +++ /dev/null @@ -1,20 +0,0 @@ -imports: - - { resource: config_dev.yml } - -doctrine: - dbal: - dbname: "%test_database_name%" - port: "%test_database_port%" - user: "%test_database_user%" - password: "%test_database_password%" - -framework: - test: ~ - session: - storage_id: session.storage.mock_file - profiler: - collect: false - -web_profiler: - toolbar: false - intercept_redirects: false diff --git a/app/config/parameters.yml.dist b/app/config/parameters.yml.dist deleted file mode 100644 index bff5162..0000000 --- a/app/config/parameters.yml.dist +++ /dev/null @@ -1,18 +0,0 @@ -# This file is a "template" of what your parameters.yml file should look like -parameters: - database_driver: pdo_mysql - database_host: 127.0.0.1 - database_port: ~ - database_name: symfony - database_user: root - database_password: ~ - # You should uncomment this if you want use pdo_sqlite - # database_path: "%kernel.root_dir%/data.db3" - - locale: en - - # A secret key that's used to generate certain security-related tokens - secret: ThisTokenIsNotSoSecretChangeIt - - # Sentry logging - sentry_dsn: ~ \ No newline at end of file diff --git a/app/config/routing.yml b/app/config/routing.yml deleted file mode 100644 index 36812d1..0000000 --- a/app/config/routing.yml +++ /dev/null @@ -1,21 +0,0 @@ -paste_show_public: - path: /{id} - defaults: { _controller: 'Skobkin\Bundle\CopyPasteBundle\Controller\PasteController::showAction', secret: null } - requirements: - id: \d+ - -paste_show_private: - path: /{id}/{secret} - defaults: { _controller: 'Skobkin\Bundle\CopyPasteBundle\Controller\PasteController::showAction' } - requirements: - id: \d+ - secret: \w{16} - -paste_new: - path: / - defaults: { _controller: 'Skobkin\Bundle\CopyPasteBundle\Controller\PasteController::newAction' } - -paste_create: - path: /create - defaults: { _controller: 'Skobkin\Bundle\CopyPasteBundle\Controller\PasteController::createAction' } - methods: POST \ No newline at end of file diff --git a/app/config/routing_dev.yml b/app/config/routing_dev.yml deleted file mode 100644 index 404f6a3..0000000 --- a/app/config/routing_dev.yml +++ /dev/null @@ -1,14 +0,0 @@ -_wdt: - resource: "@WebProfilerBundle/Resources/config/routing/wdt.xml" - prefix: /_wdt - -_profiler: - resource: "@WebProfilerBundle/Resources/config/routing/profiler.xml" - prefix: /_profiler - -_errors: - resource: "@TwigBundle/Resources/config/routing/errors.xml" - prefix: /_error - -_main: - resource: routing.yml diff --git a/app/config/services.yml b/app/config/services.yml deleted file mode 100644 index 718e7c3..0000000 --- a/app/config/services.yml +++ /dev/null @@ -1,30 +0,0 @@ -# Learn more about services, parameters and containers at -# http://symfony.com/doc/current/book/service_container.html -parameters: -# parameter_name: value - -services: - # default configuration for services in *this* file - _defaults: - # automatically injects dependencies in your services - autowire: true - # automatically registers your services as commands, event subscribers, etc. - autoconfigure: true - # this means you cannot fetch services directly from the container via $container->get() - # if you need to do this, you can override this setting on individual services - public: false - - # makes classes in src/AppBundle available to be used as services - # this creates a service per class whose id is the fully-qualified class name - Skobkin\Bundle\CopyPasteBundle\: - resource: '../../src/Skobkin/Bundle/CopyPasteBundle/*' - # you can exclude directories or files - # but if a service is unused, it's removed anyway - exclude: '../../src/Skobkin/Bundle/CopyPasteBundle/{DataFixtures,DependencyInjection,Entity,Repository,Tests}' - - # controllers are imported separately to make sure they're public - # and have a tag that allows actions to type-hint services - Skobkin\Bundle\CopyPasteBundle\Controller\: - resource: '../../src/Skobkin/Bundle/CopyPasteBundle/Controller' - public: true - tags: ['controller.service_arguments'] diff --git a/app/console b/app/console deleted file mode 100644 index f14e052..0000000 --- a/app/console +++ /dev/null @@ -1,20 +0,0 @@ -#!/usr/bin/env php -getParameterOption(['--env', '-e'], getenv('SYMFONY_ENV') ?: 'dev', true); -$debug = getenv('SYMFONY_DEBUG') !== '0' && !$input->hasParameterOption('--no-debug', true) && $env !== 'prod'; -if ($debug) { - Debug::enable(); -} -$kernel = new AppKernel($env, $debug); -$application = new Application($kernel); -$application->run($input); \ No newline at end of file diff --git a/app/phpunit.xml.dist b/app/phpunit.xml.dist deleted file mode 100644 index 2b41503..0000000 --- a/app/phpunit.xml.dist +++ /dev/null @@ -1,37 +0,0 @@ - - - - - - - ../src/*/*Bundle/Tests - ../src/*/Bundle/*Bundle/Tests - ../src/*Bundle/Tests - - - - - - - - ../src - - ../src/*Bundle/Resources - ../src/*Bundle/Tests - ../src/*/*Bundle/Resources - ../src/*/*Bundle/Tests - ../src/*/Bundle/*Bundle/Resources - ../src/*/Bundle/*Bundle/Tests - - - - diff --git a/bin/console b/bin/console new file mode 100755 index 0000000..ec2be25 --- /dev/null +++ b/bin/console @@ -0,0 +1,28 @@ +#!/usr/bin/env php +getParameterOption(['--env', '-e'], null, true)) { + putenv('APP_ENV='.$_SERVER['APP_ENV'] = $_ENV['APP_ENV'] = $env); +} +if ($input->hasParameterOption('--no-debug', true)) { + putenv('APP_DEBUG='.$_SERVER['APP_DEBUG'] = $_ENV['APP_DEBUG'] = '0'); +} +require dirname(__DIR__).'/config/bootstrap.php'; +if ($_SERVER['APP_DEBUG']) { + umask(0000); + if (class_exists(Debug::class)) { + Debug::enable(); + } +} +$kernel = new Kernel($_SERVER['APP_ENV'], (bool) $_SERVER['APP_DEBUG']); +$application = new Application($kernel); +$application->run($input); \ No newline at end of file diff --git a/bin/doctrine b/bin/doctrine new file mode 120000 index 0000000..0f72e36 --- /dev/null +++ b/bin/doctrine @@ -0,0 +1 @@ +../vendor/doctrine/orm/bin/doctrine \ No newline at end of file diff --git a/bin/doctrine-dbal b/bin/doctrine-dbal new file mode 120000 index 0000000..110e93c --- /dev/null +++ b/bin/doctrine-dbal @@ -0,0 +1 @@ +../vendor/doctrine/dbal/bin/doctrine-dbal \ No newline at end of file diff --git a/bin/doctrine-migrations b/bin/doctrine-migrations new file mode 120000 index 0000000..7184da7 --- /dev/null +++ b/bin/doctrine-migrations @@ -0,0 +1 @@ +../vendor/doctrine/migrations/bin/doctrine-migrations \ No newline at end of file diff --git a/bin/sentry b/bin/sentry new file mode 120000 index 0000000..775ae14 --- /dev/null +++ b/bin/sentry @@ -0,0 +1 @@ +../vendor/sentry/sentry/bin/sentry \ No newline at end of file diff --git a/composer.json b/composer.json index 32c82fe..edcdc35 100644 --- a/composer.json +++ b/composer.json @@ -4,8 +4,14 @@ "type": "project", "description": "Online code sharing app", "autoload": { - "psr-4": { "": "src/" }, - "classmap": [ "app/AppKernel.php", "app/AppCache.php" ] + "psr-4": { + "App\\": "src/" + } + }, + "autoload-dev": { + "psr-4": { + "App\\Tests\\": "tests/" + } }, "minimum-stability": "stable", "require": { @@ -18,42 +24,37 @@ "incenteev/composer-parameter-handler": "^2.0", "sensio/framework-extra-bundle": "^5", "sentry/sentry-symfony": "^2.2", + "symfony/flex": "^1.1", "symfony/monolog-bundle": "^3.1", - "symfony/symfony": "^3.4", "theodordiaconu/geshi": "dev-master", "theodordiaconu/geshi-bundle": "dev-master" },"require-dev": { - "symfony/web-server-bundle": "^3.4" + "symfony/web-server-bundle": "^4.2" + }, + "conflict": { + "symfony/symfony": "*" }, "scripts": { - "symfony-scripts": [ - "Incenteev\\ParameterHandler\\ScriptHandler::buildParameters", - "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::buildBootstrap", - "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::clearCache", - "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::installAssets", - "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::installRequirementsFile", - "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::prepareDeploymentTarget" - ], + "auto-scripts": { + "cache:clear": "symfony-cmd", + "assets:install %PUBLIC_DIR%": "symfony-cmd" + }, "post-install-cmd": [ - "@symfony-scripts" + "@auto-scripts" ], "post-update-cmd": [ - "@symfony-scripts" + "@auto-scripts" ] }, "config": { - "bin-dir": "bin", + "preferred-install": { + "*": "dist" + }, "sort-packages": true }, "extra": { - "symfony-app-dir": "app", - "symfony-web-dir": "web", - "symfony-assets-install": "relative", - "incenteev-parameters": { - "file": "app/config/parameters.yml" - }, - "branch-alias": { - "dev-master": "3.1-dev" + "symfony": { + "allow-contrib": false } } } diff --git a/composer.lock b/composer.lock index 7e5c867..ff7583a 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "0218e8260fd98189a3dccdd39583ddff", + "content-hash": "d2f44b3978879aaf95f741728ffc9e5f", "packages": [ { "name": "doctrine/annotations", @@ -1710,51 +1710,6 @@ ], "time": "2018-09-27T13:45:01+00:00" }, - { - "name": "paragonie/random_compat", - "version": "v9.99.99", - "source": { - "type": "git", - "url": "https://github.com/paragonie/random_compat.git", - "reference": "84b4dfb120c6f9b4ff7b3685f9b8f1aa365a0c95" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/paragonie/random_compat/zipball/84b4dfb120c6f9b4ff7b3685f9b8f1aa365a0c95", - "reference": "84b4dfb120c6f9b4ff7b3685f9b8f1aa365a0c95", - "shasum": "" - }, - "require": { - "php": "^7" - }, - "require-dev": { - "phpunit/phpunit": "4.*|5.*", - "vimeo/psalm": "^1" - }, - "suggest": { - "ext-libsodium": "Provides a modern crypto API that can be used to generate random bytes." - }, - "type": "library", - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Paragon Initiative Enterprises", - "email": "security@paragonie.com", - "homepage": "https://paragonie.com" - } - ], - "description": "PHP 5.x polyfill for random_bytes() and random_int() from PHP 7", - "keywords": [ - "csprng", - "polyfill", - "pseudorandom", - "random" - ], - "time": "2018-07-02T15:55:56+00:00" - }, { "name": "psr/cache", "version": "1.0.1", @@ -2198,6 +2153,121 @@ ], "time": "2019-01-05T13:33:24+00:00" }, + { + "name": "symfony/contracts", + "version": "v1.0.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/contracts.git", + "reference": "1aa7ab2429c3d594dd70689604b5cf7421254cdf" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/contracts/zipball/1aa7ab2429c3d594dd70689604b5cf7421254cdf", + "reference": "1aa7ab2429c3d594dd70689604b5cf7421254cdf", + "shasum": "" + }, + "require": { + "php": "^7.1.3" + }, + "require-dev": { + "psr/cache": "^1.0", + "psr/container": "^1.0" + }, + "suggest": { + "psr/cache": "When using the Cache contracts", + "psr/container": "When using the Service contracts", + "symfony/cache-contracts-implementation": "", + "symfony/service-contracts-implementation": "", + "symfony/translation-contracts-implementation": "" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Contracts\\": "" + }, + "exclude-from-classmap": [ + "**/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "A set of abstractions extracted out of the Symfony components", + "homepage": "https://symfony.com", + "keywords": [ + "abstractions", + "contracts", + "decoupling", + "interfaces", + "interoperability", + "standards" + ], + "time": "2018-12-05T08:06:11+00:00" + }, + { + "name": "symfony/flex", + "version": "v1.1.8", + "source": { + "type": "git", + "url": "https://github.com/symfony/flex.git", + "reference": "955774ecf07b10230bb5b44e150ba078b45f68fa" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/flex/zipball/955774ecf07b10230bb5b44e150ba078b45f68fa", + "reference": "955774ecf07b10230bb5b44e150ba078b45f68fa", + "shasum": "" + }, + "require": { + "composer-plugin-api": "^1.0", + "php": "^7.0" + }, + "require-dev": { + "composer/composer": "^1.0.2", + "symfony/phpunit-bridge": "^3.2.8" + }, + "type": "composer-plugin", + "extra": { + "branch-alias": { + "dev-master": "1.1-dev" + }, + "class": "Symfony\\Flex\\Flex" + }, + "autoload": { + "psr-4": { + "Symfony\\Flex\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien.potencier@gmail.com" + } + ], + "description": "Composer plugin for Symfony", + "time": "2018-11-15T06:11:38+00:00" + }, { "name": "symfony/monolog-bundle", "version": "v3.3.1", @@ -2261,62 +2331,6 @@ ], "time": "2018-11-04T09:58:13+00:00" }, - { - "name": "symfony/polyfill-apcu", - "version": "v1.10.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-apcu.git", - "reference": "19e1b73bf255265ad0b568f81766ae2a3266d8d2" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-apcu/zipball/19e1b73bf255265ad0b568f81766ae2a3266d8d2", - "reference": "19e1b73bf255265ad0b568f81766ae2a3266d8d2", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.9-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Apcu\\": "" - }, - "files": [ - "bootstrap.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill backporting apcu_* functions to lower PHP versions", - "homepage": "https://symfony.com", - "keywords": [ - "apcu", - "compatibility", - "polyfill", - "portable", - "shim" - ], - "time": "2018-08-06T14:22:27+00:00" - }, { "name": "symfony/polyfill-ctype", "version": "v1.10.0", @@ -2493,22 +2507,21 @@ "time": "2018-09-21T13:07:52+00:00" }, { - "name": "symfony/polyfill-php56", + "name": "symfony/polyfill-php72", "version": "v1.10.0", "source": { "type": "git", - "url": "https://github.com/symfony/polyfill-php56.git", - "reference": "ff208829fe1aa48ab9af356992bb7199fed551af" + "url": "https://github.com/symfony/polyfill-php72.git", + "reference": "9050816e2ca34a8e916c3a0ae8b9c2fccf68b631" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php56/zipball/ff208829fe1aa48ab9af356992bb7199fed551af", - "reference": "ff208829fe1aa48ab9af356992bb7199fed551af", + "url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/9050816e2ca34a8e916c3a0ae8b9c2fccf68b631", + "reference": "9050816e2ca34a8e916c3a0ae8b9c2fccf68b631", "shasum": "" }, "require": { - "php": ">=5.3.3", - "symfony/polyfill-util": "~1.0" + "php": ">=5.3.3" }, "type": "library", "extra": { @@ -2518,7 +2531,7 @@ }, "autoload": { "psr-4": { - "Symfony\\Polyfill\\Php56\\": "" + "Symfony\\Polyfill\\Php72\\": "" }, "files": [ "bootstrap.php" @@ -2538,7 +2551,7 @@ "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony polyfill backporting some PHP 5.6+ features to lower PHP versions", + "description": "Symfony polyfill backporting some PHP 7.2+ features to lower PHP versions", "homepage": "https://symfony.com", "keywords": [ "compatibility", @@ -2546,167 +2559,59 @@ "portable", "shim" ], - "time": "2018-09-21T06:26:08+00:00" - }, - { - "name": "symfony/polyfill-php70", - "version": "v1.10.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-php70.git", - "reference": "6b88000cdd431cd2e940caa2cb569201f3f84224" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php70/zipball/6b88000cdd431cd2e940caa2cb569201f3f84224", - "reference": "6b88000cdd431cd2e940caa2cb569201f3f84224", - "shasum": "" - }, - "require": { - "paragonie/random_compat": "~1.0|~2.0|~9.99", - "php": ">=5.3.3" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.9-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Php70\\": "" - }, - "files": [ - "bootstrap.php" - ], - "classmap": [ - "Resources/stubs" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill backporting some PHP 7.0+ features to lower PHP versions", - "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "polyfill", - "portable", - "shim" - ], - "time": "2018-09-21T06:26:08+00:00" - }, - { - "name": "symfony/polyfill-util", - "version": "v1.10.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-util.git", - "reference": "3b58903eae668d348a7126f999b0da0f2f93611c" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-util/zipball/3b58903eae668d348a7126f999b0da0f2f93611c", - "reference": "3b58903eae668d348a7126f999b0da0f2f93611c", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.9-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Util\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony utilities for portability of PHP codes", - "homepage": "https://symfony.com", - "keywords": [ - "compat", - "compatibility", - "polyfill", - "shim" - ], - "time": "2018-09-30T16:36:12+00:00" + "time": "2018-09-21T13:07:52+00:00" }, { "name": "symfony/symfony", - "version": "v3.4.21", + "version": "v4.2.2", "source": { "type": "git", "url": "https://github.com/symfony/symfony.git", - "reference": "c7a57e0bcc3c57ae697f072b3e862487b6fd0030" + "reference": "4b3e32332fd3559a644a262be53228422e5393d3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/symfony/zipball/c7a57e0bcc3c57ae697f072b3e862487b6fd0030", - "reference": "c7a57e0bcc3c57ae697f072b3e862487b6fd0030", + "url": "https://api.github.com/repos/symfony/symfony/zipball/4b3e32332fd3559a644a262be53228422e5393d3", + "reference": "4b3e32332fd3559a644a262be53228422e5393d3", "shasum": "" }, "require": { - "doctrine/common": "~2.4", + "doctrine/collections": "~1.0", + "doctrine/event-manager": "~1.0", + "doctrine/persistence": "~1.0", "ext-xml": "*", "fig/link-util": "^1.0", - "php": "^5.5.9|>=7.0.8", + "php": "^7.1.3", "psr/cache": "~1.0", "psr/container": "^1.0", "psr/link": "^1.0", "psr/log": "~1.0", "psr/simple-cache": "^1.0", - "symfony/polyfill-apcu": "~1.1", + "symfony/contracts": "^1.0.2", "symfony/polyfill-ctype": "~1.8", "symfony/polyfill-intl-icu": "~1.0", "symfony/polyfill-mbstring": "~1.0", - "symfony/polyfill-php56": "~1.0", - "symfony/polyfill-php70": "~1.6", + "symfony/polyfill-php72": "~1.5", "twig/twig": "^1.35|^2.4.4" }, "conflict": { "phpdocumentor/reflection-docblock": "<3.0||>=3.2.0,<3.2.2", "phpdocumentor/type-resolver": "<0.3.0", - "phpunit/phpunit": "<4.8.35|<5.4.3,>=5.0" + "phpunit/phpunit": "<5.4.3" }, "provide": { "psr/cache-implementation": "1.0", "psr/container-implementation": "1.0", "psr/log-implementation": "1.0", - "psr/simple-cache-implementation": "1.0" + "psr/simple-cache-implementation": "1.0", + "symfony/cache-contracts": "1.0", + "symfony/service-contracts": "1.0", + "symfony/translation-contracts": "1.0" }, "replace": { "symfony/asset": "self.version", "symfony/browser-kit": "self.version", "symfony/cache": "self.version", - "symfony/class-loader": "self.version", "symfony/config": "self.version", "symfony/console": "self.version", "symfony/css-selector": "self.version", @@ -2728,6 +2633,7 @@ "symfony/intl": "self.version", "symfony/ldap": "self.version", "symfony/lock": "self.version", + "symfony/messenger": "self.version", "symfony/monolog-bridge": "self.version", "symfony/options-resolver": "self.version", "symfony/process": "self.version", @@ -2749,6 +2655,7 @@ "symfony/twig-bundle": "self.version", "symfony/validator": "self.version", "symfony/var-dumper": "self.version", + "symfony/var-exporter": "self.version", "symfony/web-link": "self.version", "symfony/web-profiler-bundle": "self.version", "symfony/web-server-bundle": "self.version", @@ -2763,18 +2670,19 @@ "doctrine/dbal": "~2.4", "doctrine/doctrine-bundle": "~1.4", "doctrine/orm": "~2.4,>=2.4.5", + "doctrine/reflection": "~1.0", "egulias/email-validator": "~1.2,>=1.2.8|~2.0", "monolog/monolog": "~1.11", "ocramius/proxy-manager": "~0.4|~1.0|~2.0", "phpdocumentor/reflection-docblock": "^3.0|^4.0", - "predis/predis": "~1.0", + "predis/predis": "~1.1", "symfony/phpunit-bridge": "~3.4|~4.0", "symfony/security-acl": "~2.8|~3.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.4-dev" + "dev-master": "4.2-dev" } }, "autoload": { @@ -2812,7 +2720,7 @@ "keywords": [ "framework" ], - "time": "2019-01-06T15:54:26+00:00" + "time": "2019-01-06T16:19:41+00:00" }, { "name": "theodordiaconu/geshi", @@ -3069,7 +2977,53 @@ "time": "2018-04-25T15:33:34+00:00" } ], - "packages-dev": [], + "packages-dev": [ + { + "name": "paragonie/random_compat", + "version": "v9.99.99", + "source": { + "type": "git", + "url": "https://github.com/paragonie/random_compat.git", + "reference": "84b4dfb120c6f9b4ff7b3685f9b8f1aa365a0c95" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/paragonie/random_compat/zipball/84b4dfb120c6f9b4ff7b3685f9b8f1aa365a0c95", + "reference": "84b4dfb120c6f9b4ff7b3685f9b8f1aa365a0c95", + "shasum": "" + }, + "require": { + "php": "^7" + }, + "require-dev": { + "phpunit/phpunit": "4.*|5.*", + "vimeo/psalm": "^1" + }, + "suggest": { + "ext-libsodium": "Provides a modern crypto API that can be used to generate random bytes." + }, + "type": "library", + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Paragon Initiative Enterprises", + "email": "security@paragonie.com", + "homepage": "https://paragonie.com" + } + ], + "description": "PHP 5.x polyfill for random_bytes() and random_int() from PHP 7", + "keywords": [ + "csprng", + "polyfill", + "pseudorandom", + "random" + ], + "time": "2018-07-02T15:55:56+00:00" + } + ], "aliases": [], "minimum-stability": "stable", "stability-flags": { diff --git a/config/bootstrap.php b/config/bootstrap.php new file mode 100644 index 0000000..c52f821 --- /dev/null +++ b/config/bootstrap.php @@ -0,0 +1,17 @@ +=1.2) +if (is_array($env = @include dirname(__DIR__).'/.env.local.php')) { + $_SERVER += $env; + $_ENV += $env; +} elseif (!class_exists(Dotenv::class)) { + throw new RuntimeException('Please run "composer require symfony/dotenv" to load the ".env" files configuring the application.'); +} else { + // load all the .env files + (new Dotenv())->loadEnv(dirname(__DIR__).'/.env'); +} +$_SERVER['APP_ENV'] = $_ENV['APP_ENV'] = ($_SERVER['APP_ENV'] ?? $_ENV['APP_ENV'] ?? null) ?: 'dev'; +$_SERVER['APP_DEBUG'] = $_SERVER['APP_DEBUG'] ?? $_ENV['APP_DEBUG'] ?? 'prod' !== $_SERVER['APP_ENV']; +$_SERVER['APP_DEBUG'] = $_ENV['APP_DEBUG'] = (int) $_SERVER['APP_DEBUG'] || filter_var($_SERVER['APP_DEBUG'], FILTER_VALIDATE_BOOLEAN) ? '1' : '0'; diff --git a/config/bundles.php b/config/bundles.php new file mode 100644 index 0000000..97c1560 --- /dev/null +++ b/config/bundles.php @@ -0,0 +1,17 @@ + ['all' => true], + Symfony\Bundle\SecurityBundle\SecurityBundle::class => ['all' => true], + Symfony\Bundle\TwigBundle\TwigBundle::class => ['all' => true], + Symfony\Bundle\MonologBundle\MonologBundle::class => ['all' => true], + Doctrine\Bundle\DoctrineBundle\DoctrineBundle::class => ['all' => true], + Doctrine\Bundle\MigrationsBundle\DoctrineMigrationsBundle::class => ['all' => true], + Doctrine\Bundle\FixturesBundle\DoctrineFixturesBundle::class => ['all' => true], + Sensio\Bundle\FrameworkExtraBundle\SensioFrameworkExtraBundle::class => ['all' => true], + DT\Bundle\GeshiBundle\DTGeshiBundle::class => ['all' => true], + Sentry\SentryBundle\SentryBundle::class => ['all' => true], + Symfony\Bundle\DebugBundle\DebugBundle::class => ['dev' => true, 'test' => true], + Symfony\Bundle\WebProfilerBundle\WebProfilerBundle::class => ['dev' => true, 'test' => true], + Symfony\Bundle\WebServerBundle\WebServerBundle::class => ['dev' => true, 'test' => true], +]; \ No newline at end of file diff --git a/app/config/config_dev.yml b/config/packages/dev/monolog.yaml similarity index 78% rename from app/config/config_dev.yml rename to config/packages/dev/monolog.yaml index b30a818..479f837 100644 --- a/app/config/config_dev.yml +++ b/config/packages/dev/monolog.yaml @@ -1,16 +1,3 @@ -imports: - - { resource: config.yml } - -framework: - router: - resource: "%kernel.root_dir%/config/routing_dev.yml" - strict_requirements: true - profiler: { only_exceptions: false } - -web_profiler: - toolbar: true - intercept_redirects: false - monolog: handlers: main: diff --git a/config/packages/dev/routing.yaml b/config/packages/dev/routing.yaml new file mode 100644 index 0000000..4116679 --- /dev/null +++ b/config/packages/dev/routing.yaml @@ -0,0 +1,3 @@ +framework: + router: + strict_requirements: true diff --git a/config/packages/dev/web_profiler.yaml b/config/packages/dev/web_profiler.yaml new file mode 100644 index 0000000..1f1cb2b --- /dev/null +++ b/config/packages/dev/web_profiler.yaml @@ -0,0 +1,3 @@ +web_profiler: + toolbar: true + intercept_redirects: false diff --git a/config/packages/doctrine.yaml b/config/packages/doctrine.yaml new file mode 100644 index 0000000..5d5dd1d --- /dev/null +++ b/config/packages/doctrine.yaml @@ -0,0 +1,14 @@ +parameters: + env(DATABASE_URL): '' + +doctrine: + dbal: + default_connection: default + connections: + default: + driver: 'mysqli' + url: '%env(resolve:DATABASE_URL)%' + charset: UTF8 + + orm: + auto_generate_proxy_classes: "%kernel.debug%" diff --git a/config/packages/doctrine_migrations.yaml b/config/packages/doctrine_migrations.yaml new file mode 100644 index 0000000..b5aa645 --- /dev/null +++ b/config/packages/doctrine_migrations.yaml @@ -0,0 +1,3 @@ +doctrine_migrations: + dir_name: '%kernel.project_dir%/src/Migrations' + namespace: Migrations diff --git a/config/packages/form.yaml b/config/packages/form.yaml new file mode 100644 index 0000000..b0eeb43 --- /dev/null +++ b/config/packages/form.yaml @@ -0,0 +1,3 @@ +framework: + form: ~ + csrf_protection: ~ diff --git a/config/packages/framework.yaml b/config/packages/framework.yaml new file mode 100644 index 0000000..a52f4a2 --- /dev/null +++ b/config/packages/framework.yaml @@ -0,0 +1,12 @@ +framework: + #esi: ~ + secret: '%env(APP_SECRET)%' + trusted_hosts: ~ + session: + # handler_id set to null will use default session handler from php.ini + handler_id: ~ + fragments: ~ + http_method_override: true + assets: ~ + php_errors: + log: true diff --git a/app/config/config_prod.yml b/config/packages/prod/monolog.yaml similarity index 59% rename from app/config/config_prod.yml rename to config/packages/prod/monolog.yaml index 342837a..25f2c67 100644 --- a/app/config/config_prod.yml +++ b/config/packages/prod/monolog.yaml @@ -1,16 +1,3 @@ -imports: - - { resource: config.yml } - -#framework: -# validation: -# cache: apc - -#doctrine: -# orm: -# metadata_cache_driver: apc -# result_cache_driver: apc -# query_cache_driver: apc - monolog: handlers: main: diff --git a/config/packages/prod/sentry.yaml b/config/packages/prod/sentry.yaml new file mode 100644 index 0000000..b957d81 --- /dev/null +++ b/config/packages/prod/sentry.yaml @@ -0,0 +1,2 @@ +sentry: + dsn: '%sentry_dsn%' diff --git a/config/packages/routing.yaml b/config/packages/routing.yaml new file mode 100644 index 0000000..368bc7f --- /dev/null +++ b/config/packages/routing.yaml @@ -0,0 +1,3 @@ +framework: + router: + strict_requirements: ~ diff --git a/app/config/security.yml b/config/packages/security.yaml similarity index 100% rename from app/config/security.yml rename to config/packages/security.yaml diff --git a/config/packages/sensio_framework_extra.yaml b/config/packages/sensio_framework_extra.yaml new file mode 100644 index 0000000..20e5cf3 --- /dev/null +++ b/config/packages/sensio_framework_extra.yaml @@ -0,0 +1,3 @@ +sensio_framework_extra: + router: + annotations: false \ No newline at end of file diff --git a/config/packages/sentry.yaml b/config/packages/sentry.yaml new file mode 100644 index 0000000..97bee87 --- /dev/null +++ b/config/packages/sentry.yaml @@ -0,0 +1,3 @@ +sentry: + options: + curl_method: async diff --git a/config/packages/serializer.yaml b/config/packages/serializer.yaml new file mode 100644 index 0000000..1795b43 --- /dev/null +++ b/config/packages/serializer.yaml @@ -0,0 +1,3 @@ +framework: + serializer: + enable_annotations: true diff --git a/config/packages/test/doctrine.yaml b/config/packages/test/doctrine.yaml new file mode 100644 index 0000000..4b2ec5d --- /dev/null +++ b/config/packages/test/doctrine.yaml @@ -0,0 +1,6 @@ +doctrine: + dbal: + dbname: "%test_database_name%" + port: "%test_database_port%" + user: "%test_database_user%" + password: "%test_database_password%" diff --git a/config/packages/test/framework.yaml b/config/packages/test/framework.yaml new file mode 100644 index 0000000..344d275 --- /dev/null +++ b/config/packages/test/framework.yaml @@ -0,0 +1,6 @@ +framework: + test: ~ + session: + storage_id: session.storage.mock_file + profiler: + collect: false diff --git a/config/packages/test/web_profiler.yaml b/config/packages/test/web_profiler.yaml new file mode 100644 index 0000000..85319b4 --- /dev/null +++ b/config/packages/test/web_profiler.yaml @@ -0,0 +1,3 @@ +web_profiler: + toolbar: false + intercept_redirects: false diff --git a/config/packages/translation.yaml b/config/packages/translation.yaml new file mode 100644 index 0000000..1edfbe2 --- /dev/null +++ b/config/packages/translation.yaml @@ -0,0 +1,7 @@ +framework: + default_locale: '%locale%' + translator: + paths: + - '%kernel.project_dir%/translations' + fallbacks: + - '%locale%' diff --git a/config/packages/twig.yaml b/config/packages/twig.yaml new file mode 100644 index 0000000..81fef93 --- /dev/null +++ b/config/packages/twig.yaml @@ -0,0 +1,6 @@ +twig: + debug: "%kernel.debug%" + strict_variables: "%kernel.debug%" + form_themes: + - 'bootstrap_3_layout.html.twig' + - 'Form/fields.html.twig' diff --git a/config/packages/validation.yaml b/config/packages/validation.yaml new file mode 100644 index 0000000..61807db --- /dev/null +++ b/config/packages/validation.yaml @@ -0,0 +1,3 @@ +framework: + validation: + enable_annotations: true diff --git a/config/routes.yaml b/config/routes.yaml new file mode 100644 index 0000000..49e4ce1 --- /dev/null +++ b/config/routes.yaml @@ -0,0 +1,21 @@ +paste_show_public: + path: /{id} + defaults: { _controller: 'App\Controller\PasteController::showAction', secret: null } + requirements: + id: \d+ + +paste_show_private: + path: /{id}/{secret} + defaults: { _controller: 'App\Controller\PasteController::showAction' } + requirements: + id: \d+ + secret: \w{16} + +paste_new: + path: / + defaults: { _controller: 'App\Controller\PasteController::newAction' } + +paste_create: + path: /create + defaults: { _controller: 'App\Controller\PasteController::createAction' } + methods: POST \ No newline at end of file diff --git a/config/routes/dev/twig.yaml b/config/routes/dev/twig.yaml new file mode 100644 index 0000000..f4ee839 --- /dev/null +++ b/config/routes/dev/twig.yaml @@ -0,0 +1,3 @@ +_errors: + resource: '@TwigBundle/Resources/config/routing/errors.xml' + prefix: /_error diff --git a/config/routes/dev/web_profiles.yaml b/config/routes/dev/web_profiles.yaml new file mode 100644 index 0000000..c82beff --- /dev/null +++ b/config/routes/dev/web_profiles.yaml @@ -0,0 +1,7 @@ +web_profiler_wdt: + resource: '@WebProfilerBundle/Resources/config/routing/wdt.xml' + prefix: /_wdt + +web_profiler_profiler: + resource: '@WebProfilerBundle/Resources/config/routing/profiler.xml' + prefix: /_profiler diff --git a/config/services.yaml b/config/services.yaml new file mode 100644 index 0000000..fe6be92 --- /dev/null +++ b/config/services.yaml @@ -0,0 +1,24 @@ +# Learn more about services, parameters and containers at +# http://symfony.com/doc/current/book/service_container.html +parameters: + locale: 'ru' + container.dumper.inline_class_loader: true + +services: + # default configuration for services in *this* file + _defaults: + # automatically injects dependencies in your services + autowire: true + # automatically registers your services as commands, event subscribers, etc. + autoconfigure: true + # this means you cannot fetch services directly from the container via $container->get() + # if you need to do this, you can override this setting on individual services + public: false + + App\: + resource: '../src/*' + exclude: '../src/{DataFixtures,Entity,Migrations,Tests,Kernel.php}' + + App\Controller\: + resource: '../src/Controller' + tags: ['controller.service_arguments'] diff --git a/src/Skobkin/Bundle/CopyPasteBundle/Resources/public/css/base.css b/public/css/base.css similarity index 100% rename from src/Skobkin/Bundle/CopyPasteBundle/Resources/public/css/base.css rename to public/css/base.css diff --git a/web/favicon.ico b/public/favicon.ico similarity index 100% rename from web/favicon.ico rename to public/favicon.ico diff --git a/src/Skobkin/Bundle/CopyPasteBundle/Resources/public/images/favicon.ico b/public/images/favicon.ico similarity index 100% rename from src/Skobkin/Bundle/CopyPasteBundle/Resources/public/images/favicon.ico rename to public/images/favicon.ico diff --git a/public/index.php b/public/index.php new file mode 100644 index 0000000..c52f821 --- /dev/null +++ b/public/index.php @@ -0,0 +1,17 @@ +=1.2) +if (is_array($env = @include dirname(__DIR__).'/.env.local.php')) { + $_SERVER += $env; + $_ENV += $env; +} elseif (!class_exists(Dotenv::class)) { + throw new RuntimeException('Please run "composer require symfony/dotenv" to load the ".env" files configuring the application.'); +} else { + // load all the .env files + (new Dotenv())->loadEnv(dirname(__DIR__).'/.env'); +} +$_SERVER['APP_ENV'] = $_ENV['APP_ENV'] = ($_SERVER['APP_ENV'] ?? $_ENV['APP_ENV'] ?? null) ?: 'dev'; +$_SERVER['APP_DEBUG'] = $_SERVER['APP_DEBUG'] ?? $_ENV['APP_DEBUG'] ?? 'prod' !== $_SERVER['APP_ENV']; +$_SERVER['APP_DEBUG'] = $_ENV['APP_DEBUG'] = (int) $_SERVER['APP_DEBUG'] || filter_var($_SERVER['APP_DEBUG'], FILTER_VALIDATE_BOOLEAN) ? '1' : '0'; diff --git a/src/Skobkin/Bundle/CopyPasteBundle/Resources/public/js/copypaste.js b/public/js/copypaste.js similarity index 100% rename from src/Skobkin/Bundle/CopyPasteBundle/Resources/public/js/copypaste.js rename to public/js/copypaste.js diff --git a/web/robots.txt b/public/robots.txt similarity index 100% rename from web/robots.txt rename to public/robots.txt diff --git a/src/Skobkin/Bundle/CopyPasteBundle/Command/DropExpiredCopypastesCommand.php b/src/Command/DropExpiredPasteCommand.php similarity index 56% rename from src/Skobkin/Bundle/CopyPasteBundle/Command/DropExpiredCopypastesCommand.php rename to src/Command/DropExpiredPasteCommand.php index 9570fde..91c5db9 100644 --- a/src/Skobkin/Bundle/CopyPasteBundle/Command/DropExpiredCopypastesCommand.php +++ b/src/Command/DropExpiredPasteCommand.php @@ -1,21 +1,30 @@ em = $em; + } + protected function configure() { $this @@ -27,17 +36,14 @@ class DropExpiredCopypastesCommand extends ContainerAwareCommand protected function execute(InputInterface $input, OutputInterface $output) { $output->write('Deleting expired entities...'); - - /* @var $em EntityManager */ - $em = $this->getContainer()->get('doctrine')->getManager(); // @todo move to repository - $queryBuilder = $em->createQueryBuilder() - ->delete('SkobkinCopyPasteBundle:Copypaste c') + $qb = $this->em->createQueryBuilder() + ->delete(Copypaste::class, 'c') ->where('c.dateExpire < :now') ->andWhere('c.dateExpire IS NOT NULL') ->setParameter('now', new \DateTime()); - $queryBuilder->getQuery()->execute(); + $qb->getQuery()->execute(); $output->writeln('Done.'); } diff --git a/src/Skobkin/Bundle/CopyPasteBundle/Controller/PasteController.php b/src/Controller/PasteController.php similarity index 75% rename from src/Skobkin/Bundle/CopyPasteBundle/Controller/PasteController.php rename to src/Controller/PasteController.php index d94c3c2..6d90231 100644 --- a/src/Skobkin/Bundle/CopyPasteBundle/Controller/PasteController.php +++ b/src/Controller/PasteController.php @@ -1,26 +1,19 @@ createCreateForm($paste); @@ -63,31 +56,7 @@ class PasteController extends Controller throw $this->createAccessDeniedException('Sorry :('); } - /** - * Creates a form to create a Copypaste entity. - * - * @param Copypaste $entity The entity - * - * @return Form The form - */ - private function createCreateForm(Copypaste $entity) - { - $form = $this->createForm(CopypasteType::class, $entity, [ - 'action' => $this->generateUrl('paste_create'), - 'method' => 'POST', - ]); - - $form->add('submit', SubmitType::class, ['label' => 'Create']); - - return $form; - } - - /** - * Displays a form to create a new Copypaste entity. - * - * @return Response - */ - public function newAction() + public function newAction(): Response { $paste = new Copypaste(); $createForm = $this->createCreateForm($paste); @@ -98,16 +67,11 @@ class PasteController extends Controller ]); } - /** - * Finds and displays a Copypaste entity. - * - * @return Response - */ - public function showAction(int $id, ?string $secret, HighlighterInterface $highlighter) + public function showAction(int $id, ?string $secret, HighlighterInterface $highlighter): Response { $em = $this->getDoctrine()->getManager(); - /* @var $paste Copypaste */ + /* @var $paste \App\Entity\Copypaste */ $paste = $em->getRepository(Copypaste::class)->findOneBy([ 'id' =>$id, 'secret' => $secret @@ -130,13 +94,8 @@ class PasteController extends Controller 'form_create' => $editForm->createView(), ]); } - - /** - * Main page - * - * @return Response - */ - public function sidebarAction() + + public function sidebarAction(): Response { $em = $this->getDoctrine()->getManager(); @@ -149,4 +108,16 @@ class PasteController extends Controller return $this->render('sidebar.html.twig', ['pastes' => $pastes]); } + + private function createCreateForm(Copypaste $entity): FormInterface + { + $form = $this->createForm(CopypasteType::class, $entity, [ + 'action' => $this->generateUrl('paste_create'), + 'method' => 'POST', + ]); + + $form->add('submit', SubmitType::class, ['label' => 'Create']); + + return $form; + } } diff --git a/src/Skobkin/Bundle/CopyPasteBundle/DataFixtures/ORM/LoadLanguages.php b/src/DataFixtures/ORM/LoadLanguages.php similarity index 96% rename from src/Skobkin/Bundle/CopyPasteBundle/DataFixtures/ORM/LoadLanguages.php rename to src/DataFixtures/ORM/LoadLanguages.php index 905492e..a23bc3a 100644 --- a/src/Skobkin/Bundle/CopyPasteBundle/DataFixtures/ORM/LoadLanguages.php +++ b/src/DataFixtures/ORM/LoadLanguages.php @@ -1,6 +1,6 @@ datePublished = new \DateTime(); } - /** - * Get id - * - * @return integer - */ - public function getId() + public function getId(): int { return $this->id; } @@ -113,219 +104,108 @@ class Copypaste return (string) $this->id; } - /** - * Set text - * - * @param string $text - * @return Paste - */ - public function setText($text) + public function setText(string $text): self { $this->text = $text; return $this; } - /** - * Get text - * - * @return string - */ - public function getText() + public function getText(): string { return $this->text; } - /** - * Set description - * - * @param string $description - * @return Paste - */ - public function setDescription($description) + public function setDescription(string $description): self { $this->description = $description; return $this; } - /** - * Get code description - * - * @return string - */ - public function getDescription() + public function getDescription(): ?string { return $this->description; } - /** - * Set language - * - * @param integer $language - * @return Paste - */ - public function setLanguage($language) + public function setLanguage(Language $language): self { $this->language = $language; return $this; } - /** - * Get language - * - * @return integer - */ - public function getLanguage() + public function getLanguage(): Language { return $this->language; } - /** - * Set filename - * - * @param string $filename - * @return Paste - */ - public function setFilename($filename) + public function setFilename(string $filename): self { $this->fileName = $filename; return $this; } - /** - * Get filename - * - * @return string - */ - public function getFilename() + public function getFilename(): ?string { return $this->fileName; } - /** - * Set author - * - * @param string $author - * @return Paste - */ - public function setAuthor($author) + public function setAuthor(string $author): self { $this->author = $author; return $this; } - /** - * Get author - * - * @return string - */ - public function getAuthor() + public function getAuthor(): ?string { return $this->author; } - /** - * Set publication date - * - * @param \DateTime $datePublished - * @return Paste - */ - public function setDatePublished($datePublished) - { - $this->datePublished = $datePublished; - - return $this; - } - - /** - * Get publication date - * - * @return \DateTime - */ - public function getDatePublished() + public function getDatePublished(): \DateTime { return $this->datePublished; } - /** - * Set expiration date - * - * @param \DateTime $dateExpire - * @return Paste - */ - public function setDateExpire($dateExpire) + public function setDateExpire(\DateTime $dateExpire): self { $this->dateExpire = $dateExpire; return $this; } - /** - * Get expiration date - * - * @return \DateTime - */ - public function getDateExpire() + public function getDateExpire(): ?\DateTime { return $this->dateExpire; } - /** - * Set ip - * - * @param string $ip - * @return Paste - */ - public function setIp($ip) + public function setIp(string $ip): self { $this->ip = $ip; return $this; } - /** - * Get ip - * - * @return string - */ - public function getIp() + public function getIp(): string { return $this->ip; } - /** - * Set secret - * - * @param string $secret - * @return Paste - */ - public function setSecret($secret) + public function setSecret(?string $secret): self { $this->secret = $secret; return $this; } - /** - * Get secret - * - * @return string - */ - public function getSecret() + public function getSecret(): ?string { return $this->secret; } - - /** - * Check if copypaste is private - * - * @return boolean - */ - public function isPrivate() + + public function isPrivate(): bool { return ($this->secret === null) ? false : true; } diff --git a/src/Skobkin/Bundle/CopyPasteBundle/Entity/Language.php b/src/Entity/Language.php similarity index 97% rename from src/Skobkin/Bundle/CopyPasteBundle/Entity/Language.php rename to src/Entity/Language.php index 75f3cf9..41597a9 100644 --- a/src/Skobkin/Bundle/CopyPasteBundle/Entity/Language.php +++ b/src/Entity/Language.php @@ -1,6 +1,6 @@ add('language', EntityType::class, [ 'label' => 'paste_add_form_language', - 'class' => 'Skobkin\Bundle\CopyPasteBundle\Entity\Language', + 'class' => Language::class, 'query_builder' => function (EntityRepository $repo) { /* @var $qb QueryBuilder */ return $repo->createQueryBuilder('lang') @@ -79,23 +80,10 @@ class CopypasteType extends AbstractType ; } - /** - * @param OptionsResolver $resolver - */ public function configureOptions(OptionsResolver $resolver) { $resolver->setDefaults([ - 'data_class' => 'Skobkin\Bundle\CopyPasteBundle\Entity\Copypaste' + 'data_class' => Copypaste::class ]); } - - /** - * @return null|string - */ - public function getBlockPrefix() - { - return 'copypaste'; - } - - } diff --git a/src/Skobkin/Bundle/CopyPasteBundle/Form/FakeCaptchaType.php b/src/Form/FakeCaptchaType.php similarity index 76% rename from src/Skobkin/Bundle/CopyPasteBundle/Form/FakeCaptchaType.php rename to src/Form/FakeCaptchaType.php index 58a4c4b..2e6750a 100644 --- a/src/Skobkin/Bundle/CopyPasteBundle/Form/FakeCaptchaType.php +++ b/src/Form/FakeCaptchaType.php @@ -1,6 +1,6 @@ getProjectDir().'/config/bundles.php'; + foreach ($contents as $class => $envs) { + if ($envs[$this->environment] ?? $envs['all'] ?? false) { + yield new $class(); + } + } + } + protected function configureContainer(ContainerBuilder $container, LoaderInterface $loader) + { + $container->addResource(new FileResource($this->getProjectDir().'/config/bundles.php')); + $container->setParameter('container.dumper.inline_class_loader', true); + $confDir = $this->getProjectDir().'/config'; + $loader->load($confDir.'/{packages}/*'.self::CONFIG_EXTS, 'glob'); + $loader->load($confDir.'/{packages}/'.$this->environment.'/**/*'.self::CONFIG_EXTS, 'glob'); + $loader->load($confDir.'/{services}'.self::CONFIG_EXTS, 'glob'); + $loader->load($confDir.'/{services}_'.$this->environment.self::CONFIG_EXTS, 'glob'); + } + protected function configureRoutes(RouteCollectionBuilder $routes) + { + $confDir = $this->getProjectDir().'/config'; + $routes->import($confDir.'/{routes}/*'.self::CONFIG_EXTS, '/', 'glob'); + $routes->import($confDir.'/{routes}/'.$this->environment.'/**/*'.self::CONFIG_EXTS, '/', 'glob'); + $routes->import($confDir.'/{routes}'.self::CONFIG_EXTS, '/', 'glob'); + } +} diff --git a/app/DoctrineMigrations/Version20150302205121.php b/src/Migrations/Version20150302205121.php similarity index 98% rename from app/DoctrineMigrations/Version20150302205121.php rename to src/Migrations/Version20150302205121.php index 637c634..a3d67c0 100644 --- a/app/DoctrineMigrations/Version20150302205121.php +++ b/src/Migrations/Version20150302205121.php @@ -1,6 +1,6 @@ root('skobkin_copy_paste'); - - // Here you should define the parameters that are allowed to - // configure your bundle. See the documentation linked above for - // more information on that topic. - - return $treeBuilder; - } -} diff --git a/src/Skobkin/Bundle/CopyPasteBundle/DependencyInjection/SkobkinCopyPasteExtension.php b/src/Skobkin/Bundle/CopyPasteBundle/DependencyInjection/SkobkinCopyPasteExtension.php deleted file mode 100644 index 8728e2a..0000000 --- a/src/Skobkin/Bundle/CopyPasteBundle/DependencyInjection/SkobkinCopyPasteExtension.php +++ /dev/null @@ -1,27 +0,0 @@ -processConfiguration($configuration, $configs); - - $loader = new Loader\YamlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config')); - } -} diff --git a/src/Skobkin/Bundle/CopyPasteBundle/SkobkinCopyPasteBundle.php b/src/Skobkin/Bundle/CopyPasteBundle/SkobkinCopyPasteBundle.php deleted file mode 100644 index d5c8cd6..0000000 --- a/src/Skobkin/Bundle/CopyPasteBundle/SkobkinCopyPasteBundle.php +++ /dev/null @@ -1,9 +0,0 @@ - + {% endblock %} {% block javascript %} {{- parent() -}} - + {% endblock %} {%- block header -%} @@ -46,7 +46,7 @@ {%- endblock -%} {%- block sidebar -%} - {{ render(controller('Skobkin\\Bundle\\CopyPasteBundle\\Controller\\PasteController::sidebarAction')) }} + {{ render(controller('App\\Controller\\PasteController::sidebarAction')) }} {%- endblock -%} {% block content %}{% endblock %} diff --git a/app/Resources/views/layout.html.twig b/templates/layout.html.twig similarity index 95% rename from app/Resources/views/layout.html.twig rename to templates/layout.html.twig index 11caa5c..7755374 100644 --- a/app/Resources/views/layout.html.twig +++ b/templates/layout.html.twig @@ -4,7 +4,7 @@ {%- block head -%} {% block title %}CopyPaste{% endblock %} - + {%- block css -%} {%- endblock -%} diff --git a/app/Resources/views/sidebar.html.twig b/templates/sidebar.html.twig similarity index 100% rename from app/Resources/views/sidebar.html.twig rename to templates/sidebar.html.twig diff --git a/app/cache/.gitkeep b/tests/.gitkeep similarity index 100% rename from app/cache/.gitkeep rename to tests/.gitkeep diff --git a/app/Resources/translations/messages.ru.xliff b/translations/messages.ru.xliff similarity index 100% rename from app/Resources/translations/messages.ru.xliff rename to translations/messages.ru.xliff diff --git a/app/logs/.gitkeep b/var/cache/.gitkeep similarity index 100% rename from app/logs/.gitkeep rename to var/cache/.gitkeep diff --git a/var/log/.gitkeep b/var/log/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/web/.htaccess b/web/.htaccess deleted file mode 100644 index 94b3892..0000000 --- a/web/.htaccess +++ /dev/null @@ -1,62 +0,0 @@ -# Use the front controller as index file. It serves as a fallback solution when -# every other rewrite/redirect fails (e.g. in an aliased environment without -# mod_rewrite). Additionally, this reduces the matching process for the -# start page (path "/") because otherwise Apache will apply the rewriting rules -# to each configured DirectoryIndex file (e.g. index.php, index.html, index.pl). -DirectoryIndex app.php - -# Disabling MultiViews prevents unwanted negotiation, e.g. "/app" should not resolve -# to the front controller "/app.php" but be rewritten to "/app.php/app". - - Options -MultiViews - - - - RewriteEngine On - - # Determine the RewriteBase automatically and set it as environment variable. - # If you are using Apache aliases to do mass virtual hosting or installed the - # project in a subdirectory, the base path will be prepended to allow proper - # resolution of the app.php file and to redirect to the correct URI. It will - # work in environments without path prefix as well, providing a safe, one-size - # fits all solution. But as you do not need it in this case, you can comment - # the following 2 lines to eliminate the overhead. - RewriteCond %{REQUEST_URI}::$1 ^(/.+)/(.*)::\2$ - RewriteRule ^(.*) - [E=BASE:%1] - - # Sets the HTTP_AUTHORIZATION header removed by apache - RewriteCond %{HTTP:Authorization} . - RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}] - - # Redirect to URI without front controller to prevent duplicate content - # (with and without `/app.php`). Only do this redirect on the initial - # rewrite by Apache and not on subsequent cycles. Otherwise we would get an - # endless redirect loop (request -> rewrite to front controller -> - # redirect -> request -> ...). - # So in case you get a "too many redirects" error or you always get redirected - # to the start page because your Apache does not expose the REDIRECT_STATUS - # environment variable, you have 2 choices: - # - disable this feature by commenting the following 2 lines or - # - use Apache >= 2.3.9 and replace all L flags by END flags and remove the - # following RewriteCond (best solution) - RewriteCond %{ENV:REDIRECT_STATUS} ^$ - RewriteRule ^app\.php(/(.*)|$) %{ENV:BASE}/$2 [R=301,L] - - # If the requested filename exists, simply serve it. - # We only want to let Apache serve files and not directories. - RewriteCond %{REQUEST_FILENAME} -f - RewriteRule .? - [L] - - # Rewrite all other queries to the front controller. - RewriteRule .? %{ENV:BASE}/app.php [L] - - - - - # When mod_rewrite is not available, we instruct a temporary redirect of - # the start page to the front controller explicitly so that the website - # and the generated links can still be used. - RedirectMatch 302 ^/$ /app.php/ - # RedirectTemp cannot be used instead - - diff --git a/web/app.php b/web/app.php deleted file mode 100644 index 433163b..0000000 --- a/web/app.php +++ /dev/null @@ -1,17 +0,0 @@ -loadClassCache(); -} -//$kernel = new AppCache($kernel); -// When using the HttpCache, you need to call the method in your front controller instead of relying on the configuration parameter -//Request::enableHttpMethodParameterOverride(); -$request = Request::createFromGlobals(); -$response = $kernel->handle($request); -$response->send(); -$kernel->terminate($request, $response); \ No newline at end of file diff --git a/web/app_dev.php b/web/app_dev.php deleted file mode 100644 index 1d9e45f..0000000 --- a/web/app_dev.php +++ /dev/null @@ -1,26 +0,0 @@ -loadClassCache(); -} -$request = Request::createFromGlobals(); -$response = $kernel->handle($request); -$response->send(); -$kernel->terminate($request, $response); \ No newline at end of file From 6a95bbee348947ad3d3603e00ee185ab1ec34faf Mon Sep 17 00:00:00 2001 From: Alexey Skobkin Date: Sun, 20 Jan 2019 05:13:32 +0300 Subject: [PATCH 06/13] Deps reinstall, config fixes, cleaning. --- .gitignore | 14 +- composer.json | 15 +- composer.lock | 3265 ++++++++++++++++++--- config/packages/cache.yaml | 19 + config/packages/dev/debug.yaml | 4 + config/packages/dev/easy_log_handler.yaml | 16 + config/packages/doctrine.yaml | 10 +- config/packages/form.yaml | 3 - config/packages/framework.yaml | 1 - config/packages/serializer.yaml | 3 - config/packages/test/routing.yaml | 3 + config/packages/validation.yaml | 3 - config/routes/dev/web_profiler.yaml | 7 + src/Controller/.gitignore | 0 symfony.lock | 180 ++ translations/.gitignore | 0 16 files changed, 3077 insertions(+), 466 deletions(-) create mode 100644 config/packages/cache.yaml create mode 100644 config/packages/dev/debug.yaml create mode 100644 config/packages/dev/easy_log_handler.yaml delete mode 100644 config/packages/form.yaml delete mode 100644 config/packages/serializer.yaml create mode 100644 config/packages/test/routing.yaml delete mode 100644 config/packages/validation.yaml create mode 100644 config/routes/dev/web_profiler.yaml create mode 100644 src/Controller/.gitignore create mode 100644 translations/.gitignore diff --git a/.gitignore b/.gitignore index 5b2d4da..d2f575b 100644 --- a/.gitignore +++ b/.gitignore @@ -4,4 +4,16 @@ !/var/cache/.gitkeep !/var/log/.gitkeep /vendor/ -/.env \ No newline at end of file +/.env +###> symfony/framework-bundle ### +/.env.local +/.env.local.php +/.env.*.local +/public/bundles/ +/var/ +/vendor/ +###< symfony/framework-bundle ### + +###> symfony/web-server-bundle ### +/.web-server-pid +###< symfony/web-server-bundle ### diff --git a/composer.json b/composer.json index edcdc35..9d43bee 100644 --- a/composer.json +++ b/composer.json @@ -18,17 +18,24 @@ "php": ">=7.1.0", "doctrine/annotations": "^1.3", "doctrine/doctrine-bundle": "^1.4", - "doctrine/doctrine-fixtures-bundle": "^2.2", "doctrine/doctrine-migrations-bundle": "^2.0", "doctrine/orm": "^2.5", - "incenteev/composer-parameter-handler": "^2.0", - "sensio/framework-extra-bundle": "^5", + "sensio/framework-extra-bundle": "^5.2", "sentry/sentry-symfony": "^2.2", "symfony/flex": "^1.1", - "symfony/monolog-bundle": "^3.1", + "symfony/form": "^4.2", + "symfony/monolog-bundle": "^3.3", + "symfony/orm-pack": "^1.0", + "symfony/security-bundle": "^4.2", + "symfony/translation": "^4.2", + "symfony/twig-bundle": "^4.2", "theodordiaconu/geshi": "dev-master", "theodordiaconu/geshi-bundle": "dev-master" },"require-dev": { + "doctrine/doctrine-fixtures-bundle": "^3.1", + "symfony/debug-pack": "^1.0", + "symfony/dotenv": "^4.2", + "symfony/profiler-pack": "^1.0", "symfony/web-server-bundle": "^4.2" }, "conflict": { diff --git a/composer.lock b/composer.lock index ff7583a..a3b5910 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "d2f44b3978879aaf95f741728ffc9e5f", + "content-hash": "3488c5d4756be564e9c5076a918bd373", "packages": [ { "name": "doctrine/annotations", @@ -297,66 +297,6 @@ ], "time": "2018-11-21T01:24:55+00:00" }, - { - "name": "doctrine/data-fixtures", - "version": "v1.3.1", - "source": { - "type": "git", - "url": "https://github.com/doctrine/data-fixtures.git", - "reference": "3a1e2c3c600e615a2dffe56d4ca0875cc5233e0a" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/data-fixtures/zipball/3a1e2c3c600e615a2dffe56d4ca0875cc5233e0a", - "reference": "3a1e2c3c600e615a2dffe56d4ca0875cc5233e0a", - "shasum": "" - }, - "require": { - "doctrine/common": "~2.2", - "php": "^7.1" - }, - "conflict": { - "doctrine/phpcr-odm": "<1.3.0" - }, - "require-dev": { - "doctrine/dbal": "^2.5.4", - "doctrine/orm": "^2.5.4", - "phpunit/phpunit": "^7.0" - }, - "suggest": { - "alcaeus/mongo-php-adapter": "For using MongoDB ODM with PHP 7", - "doctrine/mongodb-odm": "For loading MongoDB ODM fixtures", - "doctrine/orm": "For loading ORM fixtures", - "doctrine/phpcr-odm": "For loading PHPCR ODM fixtures" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.3.x-dev" - } - }, - "autoload": { - "psr-4": { - "Doctrine\\Common\\DataFixtures\\": "lib/Doctrine/Common/DataFixtures" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - } - ], - "description": "Data Fixtures for all Doctrine Object Managers", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "database" - ], - "time": "2018-03-20T09:06:36+00:00" - }, { "name": "doctrine/dbal", "version": "v2.9.2", @@ -615,63 +555,6 @@ ], "time": "2018-11-09T06:25:35+00:00" }, - { - "name": "doctrine/doctrine-fixtures-bundle", - "version": "v2.4.1", - "source": { - "type": "git", - "url": "https://github.com/doctrine/DoctrineFixturesBundle.git", - "reference": "74b8cc70a4a25b774628ee59f4cdf3623a146273" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/DoctrineFixturesBundle/zipball/74b8cc70a4a25b774628ee59f4cdf3623a146273", - "reference": "74b8cc70a4a25b774628ee59f4cdf3623a146273", - "shasum": "" - }, - "require": { - "doctrine/data-fixtures": "~1.0", - "doctrine/doctrine-bundle": "~1.0", - "php": ">=5.3.2", - "symfony/doctrine-bridge": "~2.7|~3.0|~4.0" - }, - "type": "symfony-bundle", - "extra": { - "branch-alias": { - "dev-master": "2.4.x-dev" - } - }, - "autoload": { - "psr-4": { - "Doctrine\\Bundle\\FixturesBundle\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Symfony Community", - "homepage": "http://symfony.com/contributors" - }, - { - "name": "Doctrine Project", - "homepage": "http://www.doctrine-project.org" - }, - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - } - ], - "description": "Symfony DoctrineFixturesBundle", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "Fixture", - "persistence" - ], - "time": "2017-10-30T19:26:42+00:00" - }, { "name": "doctrine/doctrine-migrations-bundle", "version": "v2.0.0", @@ -1307,111 +1190,6 @@ ], "time": "2018-06-14T14:45:07+00:00" }, - { - "name": "fig/link-util", - "version": "1.0.0", - "source": { - "type": "git", - "url": "https://github.com/php-fig/link-util.git", - "reference": "1a07821801a148be4add11ab0603e4af55a72fac" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/php-fig/link-util/zipball/1a07821801a148be4add11ab0603e4af55a72fac", - "reference": "1a07821801a148be4add11ab0603e4af55a72fac", - "shasum": "" - }, - "require": { - "php": ">=5.5.0", - "psr/link": "~1.0@dev" - }, - "require-dev": { - "phpunit/phpunit": "^5.1", - "squizlabs/php_codesniffer": "^2.3.1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Fig\\Link\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" - } - ], - "description": "Common utility implementations for HTTP links", - "keywords": [ - "http", - "http-link", - "link", - "psr", - "psr-13", - "rest" - ], - "time": "2016-10-17T18:31:11+00:00" - }, - { - "name": "incenteev/composer-parameter-handler", - "version": "v2.1.3", - "source": { - "type": "git", - "url": "https://github.com/Incenteev/ParameterHandler.git", - "reference": "933c45a34814f27f2345c11c37d46b3ca7303550" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Incenteev/ParameterHandler/zipball/933c45a34814f27f2345c11c37d46b3ca7303550", - "reference": "933c45a34814f27f2345c11c37d46b3ca7303550", - "shasum": "" - }, - "require": { - "php": ">=5.3.3", - "symfony/yaml": "^2.3 || ^3.0 || ^4.0" - }, - "require-dev": { - "composer/composer": "^1.0@dev", - "symfony/filesystem": "^2.3 || ^3 || ^4", - "symfony/phpunit-bridge": "^4.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.1.x-dev" - } - }, - "autoload": { - "psr-4": { - "Incenteev\\ParameterHandler\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Christophe Coevoet", - "email": "stof@notk.org" - } - ], - "description": "Composer script handling your ignored parameter file", - "homepage": "https://github.com/Incenteev/ParameterHandler", - "keywords": [ - "parameters management" - ], - "time": "2018-02-13T18:05:56+00:00" - }, { "name": "jdorn/sql-formatter", "version": "v1.2.17", @@ -1805,55 +1583,6 @@ ], "time": "2017-02-14T16:28:37+00:00" }, - { - "name": "psr/link", - "version": "1.0.0", - "source": { - "type": "git", - "url": "https://github.com/php-fig/link.git", - "reference": "eea8e8662d5cd3ae4517c9b864493f59fca95562" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/php-fig/link/zipball/eea8e8662d5cd3ae4517c9b864493f59fca95562", - "reference": "eea8e8662d5cd3ae4517c9b864493f59fca95562", - "shasum": "" - }, - "require": { - "php": ">=5.3.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Psr\\Link\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" - } - ], - "description": "Common interfaces for HTTP links", - "keywords": [ - "http", - "http-link", - "link", - "psr", - "psr-13", - "rest" - ], - "time": "2016-10-28T16:06:13+00:00" - }, { "name": "psr/log", "version": "1.1.0", @@ -2153,6 +1882,215 @@ ], "time": "2019-01-05T13:33:24+00:00" }, + { + "name": "symfony/cache", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/cache.git", + "reference": "dd223d4bb9a2f9a4b4992851800b349739c40860" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/cache/zipball/dd223d4bb9a2f9a4b4992851800b349739c40860", + "reference": "dd223d4bb9a2f9a4b4992851800b349739c40860", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "psr/cache": "~1.0", + "psr/log": "~1.0", + "psr/simple-cache": "^1.0", + "symfony/contracts": "^1.0", + "symfony/var-exporter": "^4.2" + }, + "conflict": { + "doctrine/dbal": "<2.5", + "symfony/dependency-injection": "<3.4", + "symfony/var-dumper": "<3.4" + }, + "provide": { + "psr/cache-implementation": "1.0", + "psr/simple-cache-implementation": "1.0", + "symfony/cache-contracts-implementation": "1.0" + }, + "require-dev": { + "cache/integration-tests": "dev-master", + "doctrine/cache": "~1.6", + "doctrine/dbal": "~2.5", + "predis/predis": "~1.1", + "symfony/config": "~4.2", + "symfony/dependency-injection": "~3.4|~4.1", + "symfony/var-dumper": "^4.1.1" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Cache\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Cache component with PSR-6, PSR-16, and tags", + "homepage": "https://symfony.com", + "keywords": [ + "caching", + "psr6" + ], + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/config", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/config.git", + "reference": "a7a7d0a0244cfc82f040729ccf769e6cf55a78fb" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/config/zipball/a7a7d0a0244cfc82f040729ccf769e6cf55a78fb", + "reference": "a7a7d0a0244cfc82f040729ccf769e6cf55a78fb", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/filesystem": "~3.4|~4.0", + "symfony/polyfill-ctype": "~1.8" + }, + "conflict": { + "symfony/finder": "<3.4" + }, + "require-dev": { + "symfony/dependency-injection": "~3.4|~4.0", + "symfony/event-dispatcher": "~3.4|~4.0", + "symfony/finder": "~3.4|~4.0", + "symfony/yaml": "~3.4|~4.0" + }, + "suggest": { + "symfony/yaml": "To use the yaml reference dumper" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Config\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Config Component", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/console", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/console.git", + "reference": "b0a03c1bb0fcbe288629956cf2f1dd3f1dc97522" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/console/zipball/b0a03c1bb0fcbe288629956cf2f1dd3f1dc97522", + "reference": "b0a03c1bb0fcbe288629956cf2f1dd3f1dc97522", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/contracts": "^1.0", + "symfony/polyfill-mbstring": "~1.0" + }, + "conflict": { + "symfony/dependency-injection": "<3.4", + "symfony/process": "<3.3" + }, + "require-dev": { + "psr/log": "~1.0", + "symfony/config": "~3.4|~4.0", + "symfony/dependency-injection": "~3.4|~4.0", + "symfony/event-dispatcher": "~3.4|~4.0", + "symfony/lock": "~3.4|~4.0", + "symfony/process": "~3.4|~4.0" + }, + "suggest": { + "psr/log-implementation": "For using the console logger", + "symfony/event-dispatcher": "", + "symfony/lock": "", + "symfony/process": "" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Console\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Console Component", + "homepage": "https://symfony.com", + "time": "2019-01-04T15:13:53+00:00" + }, { "name": "symfony/contracts", "version": "v1.0.2", @@ -2221,6 +2159,386 @@ ], "time": "2018-12-05T08:06:11+00:00" }, + { + "name": "symfony/debug", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/debug.git", + "reference": "64cb33c81e37d19b7715d4a6a4d49c1c382066dd" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/debug/zipball/64cb33c81e37d19b7715d4a6a4d49c1c382066dd", + "reference": "64cb33c81e37d19b7715d4a6a4d49c1c382066dd", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "psr/log": "~1.0" + }, + "conflict": { + "symfony/http-kernel": "<3.4" + }, + "require-dev": { + "symfony/http-kernel": "~3.4|~4.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Debug\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Debug Component", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/dependency-injection", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/dependency-injection.git", + "reference": "a28dda9df1d5494367454cad91e44751ac53921c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/dependency-injection/zipball/a28dda9df1d5494367454cad91e44751ac53921c", + "reference": "a28dda9df1d5494367454cad91e44751ac53921c", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "psr/container": "^1.0", + "symfony/contracts": "^1.0" + }, + "conflict": { + "symfony/config": "<4.2", + "symfony/finder": "<3.4", + "symfony/proxy-manager-bridge": "<3.4", + "symfony/yaml": "<3.4" + }, + "provide": { + "psr/container-implementation": "1.0", + "symfony/service-contracts-implementation": "1.0" + }, + "require-dev": { + "symfony/config": "~4.2", + "symfony/expression-language": "~3.4|~4.0", + "symfony/yaml": "~3.4|~4.0" + }, + "suggest": { + "symfony/config": "", + "symfony/expression-language": "For using expressions in service container configuration", + "symfony/finder": "For using double-star glob patterns or when GLOB_BRACE portability is required", + "symfony/proxy-manager-bridge": "Generate service proxies to lazy load them", + "symfony/yaml": "" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\DependencyInjection\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony DependencyInjection Component", + "homepage": "https://symfony.com", + "time": "2019-01-05T16:37:49+00:00" + }, + { + "name": "symfony/doctrine-bridge", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/doctrine-bridge.git", + "reference": "9dd24388fad8ae89b3f97a6eec70a18aabf3f7db" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/doctrine-bridge/zipball/9dd24388fad8ae89b3f97a6eec70a18aabf3f7db", + "reference": "9dd24388fad8ae89b3f97a6eec70a18aabf3f7db", + "shasum": "" + }, + "require": { + "doctrine/collections": "~1.0", + "doctrine/event-manager": "~1.0", + "doctrine/persistence": "~1.0", + "php": "^7.1.3", + "symfony/contracts": "^1.0", + "symfony/polyfill-ctype": "~1.8", + "symfony/polyfill-mbstring": "~1.0" + }, + "conflict": { + "phpunit/phpunit": "<4.8.35|<5.4.3,>=5.0", + "symfony/dependency-injection": "<3.4", + "symfony/messenger": "<4.2" + }, + "require-dev": { + "doctrine/annotations": "~1.0", + "doctrine/cache": "~1.6", + "doctrine/data-fixtures": "1.0.*", + "doctrine/dbal": "~2.4", + "doctrine/orm": "^2.4.5", + "doctrine/reflection": "~1.0", + "symfony/dependency-injection": "~3.4|~4.0", + "symfony/expression-language": "~3.4|~4.0", + "symfony/form": "~3.4|~4.0", + "symfony/http-kernel": "~3.4|~4.0", + "symfony/messenger": "~4.2", + "symfony/property-access": "~3.4|~4.0", + "symfony/property-info": "~3.4|~4.0", + "symfony/proxy-manager-bridge": "~3.4|~4.0", + "symfony/security": "~3.4|~4.0", + "symfony/stopwatch": "~3.4|~4.0", + "symfony/translation": "~3.4|~4.0", + "symfony/validator": "~3.4|~4.0" + }, + "suggest": { + "doctrine/data-fixtures": "", + "doctrine/dbal": "", + "doctrine/orm": "", + "symfony/form": "", + "symfony/property-info": "", + "symfony/validator": "" + }, + "type": "symfony-bridge", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Bridge\\Doctrine\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Doctrine Bridge", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/event-dispatcher", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/event-dispatcher.git", + "reference": "887de6d34c86cf0cb6cbf910afb170cdb743cb5e" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/887de6d34c86cf0cb6cbf910afb170cdb743cb5e", + "reference": "887de6d34c86cf0cb6cbf910afb170cdb743cb5e", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/contracts": "^1.0" + }, + "conflict": { + "symfony/dependency-injection": "<3.4" + }, + "require-dev": { + "psr/log": "~1.0", + "symfony/config": "~3.4|~4.0", + "symfony/dependency-injection": "~3.4|~4.0", + "symfony/expression-language": "~3.4|~4.0", + "symfony/stopwatch": "~3.4|~4.0" + }, + "suggest": { + "symfony/dependency-injection": "", + "symfony/http-kernel": "" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\EventDispatcher\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony EventDispatcher Component", + "homepage": "https://symfony.com", + "time": "2019-01-05T16:37:49+00:00" + }, + { + "name": "symfony/filesystem", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/filesystem.git", + "reference": "c2ffd9a93f2d6c5be2f68a0aa7953cc229f871f8" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/filesystem/zipball/c2ffd9a93f2d6c5be2f68a0aa7953cc229f871f8", + "reference": "c2ffd9a93f2d6c5be2f68a0aa7953cc229f871f8", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/polyfill-ctype": "~1.8" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Filesystem\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Filesystem Component", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/finder", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/finder.git", + "reference": "9094d69e8c6ee3fe186a0ec5a4f1401e506071ce" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/finder/zipball/9094d69e8c6ee3fe186a0ec5a4f1401e506071ce", + "reference": "9094d69e8c6ee3fe186a0ec5a4f1401e506071ce", + "shasum": "" + }, + "require": { + "php": "^7.1.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Finder\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Finder Component", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, { "name": "symfony/flex", "version": "v1.1.8", @@ -2268,6 +2586,551 @@ "description": "Composer plugin for Symfony", "time": "2018-11-15T06:11:38+00:00" }, + { + "name": "symfony/form", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/form.git", + "reference": "3361332a168850dc8b3abd133553f66c0cb28b1c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/form/zipball/3361332a168850dc8b3abd133553f66c0cb28b1c", + "reference": "3361332a168850dc8b3abd133553f66c0cb28b1c", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/event-dispatcher": "~3.4|~4.0", + "symfony/intl": "~3.4|~4.0", + "symfony/options-resolver": "~4.2", + "symfony/polyfill-ctype": "~1.8", + "symfony/polyfill-mbstring": "~1.0", + "symfony/property-access": "~3.4|~4.0" + }, + "conflict": { + "phpunit/phpunit": "<4.8.35|<5.4.3,>=5.0", + "symfony/dependency-injection": "<3.4", + "symfony/doctrine-bridge": "<3.4", + "symfony/framework-bundle": "<3.4", + "symfony/http-kernel": "<3.4", + "symfony/translation": "<4.2", + "symfony/twig-bridge": "<3.4.5|<4.0.5,>=4.0" + }, + "require-dev": { + "doctrine/collections": "~1.0", + "symfony/config": "~3.4|~4.0", + "symfony/console": "~3.4|~4.0", + "symfony/dependency-injection": "~3.4|~4.0", + "symfony/http-foundation": "~3.4|~4.0", + "symfony/http-kernel": "~3.4|~4.0", + "symfony/security-csrf": "~3.4|~4.0", + "symfony/translation": "~4.2", + "symfony/validator": "~3.4|~4.0", + "symfony/var-dumper": "~3.4|~4.0" + }, + "suggest": { + "symfony/framework-bundle": "For templating with PHP.", + "symfony/security-csrf": "For protecting forms against CSRF attacks.", + "symfony/twig-bridge": "For templating with Twig.", + "symfony/validator": "For form validation." + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Form\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Form Component", + "homepage": "https://symfony.com", + "time": "2019-01-05T16:37:49+00:00" + }, + { + "name": "symfony/framework-bundle", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/framework-bundle.git", + "reference": "6cba25ea9489d62addb9971a4bdcf42a5639e641" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/framework-bundle/zipball/6cba25ea9489d62addb9971a4bdcf42a5639e641", + "reference": "6cba25ea9489d62addb9971a4bdcf42a5639e641", + "shasum": "" + }, + "require": { + "ext-xml": "*", + "php": "^7.1.3", + "symfony/cache": "~4.2", + "symfony/config": "~4.2", + "symfony/contracts": "^1.0.2", + "symfony/dependency-injection": "^4.2", + "symfony/event-dispatcher": "^4.1", + "symfony/filesystem": "~3.4|~4.0", + "symfony/finder": "~3.4|~4.0", + "symfony/http-foundation": "^4.1.2", + "symfony/http-kernel": "^4.2", + "symfony/polyfill-mbstring": "~1.0", + "symfony/routing": "^4.1" + }, + "conflict": { + "phpdocumentor/reflection-docblock": "<3.0", + "phpdocumentor/type-resolver": "<0.2.1", + "phpunit/phpunit": "<4.8.35|<5.4.3,>=5.0", + "symfony/asset": "<3.4", + "symfony/console": "<3.4", + "symfony/dotenv": "<4.2", + "symfony/form": "<4.2", + "symfony/messenger": "<4.2", + "symfony/property-info": "<3.4", + "symfony/serializer": "<4.2", + "symfony/stopwatch": "<3.4", + "symfony/translation": "<4.2", + "symfony/twig-bridge": "<4.1.1", + "symfony/validator": "<4.1", + "symfony/workflow": "<4.1" + }, + "require-dev": { + "doctrine/annotations": "~1.0", + "doctrine/cache": "~1.0", + "fig/link-util": "^1.0", + "phpdocumentor/reflection-docblock": "^3.0|^4.0", + "symfony/asset": "~3.4|~4.0", + "symfony/browser-kit": "~3.4|~4.0", + "symfony/console": "~3.4|~4.0", + "symfony/css-selector": "~3.4|~4.0", + "symfony/dom-crawler": "~3.4|~4.0", + "symfony/expression-language": "~3.4|~4.0", + "symfony/form": "^4.2", + "symfony/lock": "~3.4|~4.0", + "symfony/messenger": "^4.2", + "symfony/polyfill-intl-icu": "~1.0", + "symfony/process": "~3.4|~4.0", + "symfony/property-info": "~3.4|~4.0", + "symfony/security": "~3.4|~4.0", + "symfony/security-core": "~3.4|~4.0", + "symfony/security-csrf": "~3.4|~4.0", + "symfony/serializer": "^4.2", + "symfony/stopwatch": "~3.4|~4.0", + "symfony/templating": "~3.4|~4.0", + "symfony/translation": "~4.2", + "symfony/validator": "^4.1", + "symfony/var-dumper": "~3.4|~4.0", + "symfony/web-link": "~3.4|~4.0", + "symfony/workflow": "^4.1", + "symfony/yaml": "~3.4|~4.0", + "twig/twig": "~1.34|~2.4" + }, + "suggest": { + "ext-apcu": "For best performance of the system caches", + "symfony/console": "For using the console commands", + "symfony/form": "For using forms", + "symfony/property-info": "For using the property_info service", + "symfony/serializer": "For using the serializer service", + "symfony/validator": "For using validation", + "symfony/web-link": "For using web links, features such as preloading, prefetching or prerendering", + "symfony/yaml": "For using the debug:config and lint:yaml commands" + }, + "type": "symfony-bundle", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Bundle\\FrameworkBundle\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony FrameworkBundle", + "homepage": "https://symfony.com", + "time": "2019-01-05T16:37:49+00:00" + }, + { + "name": "symfony/http-foundation", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/http-foundation.git", + "reference": "a633d422a09242064ba24e44a6e1494c5126de86" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/http-foundation/zipball/a633d422a09242064ba24e44a6e1494c5126de86", + "reference": "a633d422a09242064ba24e44a6e1494c5126de86", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/polyfill-mbstring": "~1.1" + }, + "require-dev": { + "predis/predis": "~1.0", + "symfony/expression-language": "~3.4|~4.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\HttpFoundation\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony HttpFoundation Component", + "homepage": "https://symfony.com", + "time": "2019-01-05T16:37:49+00:00" + }, + { + "name": "symfony/http-kernel", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/http-kernel.git", + "reference": "83de6543328917c18d5498eeb6bb6d36f7aab31b" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/83de6543328917c18d5498eeb6bb6d36f7aab31b", + "reference": "83de6543328917c18d5498eeb6bb6d36f7aab31b", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "psr/log": "~1.0", + "symfony/contracts": "^1.0.2", + "symfony/debug": "~3.4|~4.0", + "symfony/event-dispatcher": "~4.1", + "symfony/http-foundation": "^4.1.1", + "symfony/polyfill-ctype": "~1.8" + }, + "conflict": { + "symfony/config": "<3.4", + "symfony/dependency-injection": "<4.2", + "symfony/translation": "<4.2", + "symfony/var-dumper": "<4.1.1", + "twig/twig": "<1.34|<2.4,>=2" + }, + "provide": { + "psr/log-implementation": "1.0" + }, + "require-dev": { + "psr/cache": "~1.0", + "symfony/browser-kit": "~3.4|~4.0", + "symfony/config": "~3.4|~4.0", + "symfony/console": "~3.4|~4.0", + "symfony/css-selector": "~3.4|~4.0", + "symfony/dependency-injection": "^4.2", + "symfony/dom-crawler": "~3.4|~4.0", + "symfony/expression-language": "~3.4|~4.0", + "symfony/finder": "~3.4|~4.0", + "symfony/process": "~3.4|~4.0", + "symfony/routing": "~3.4|~4.0", + "symfony/stopwatch": "~3.4|~4.0", + "symfony/templating": "~3.4|~4.0", + "symfony/translation": "~4.2", + "symfony/var-dumper": "^4.1.1" + }, + "suggest": { + "symfony/browser-kit": "", + "symfony/config": "", + "symfony/console": "", + "symfony/dependency-injection": "", + "symfony/var-dumper": "" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\HttpKernel\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony HttpKernel Component", + "homepage": "https://symfony.com", + "time": "2019-01-06T16:19:23+00:00" + }, + { + "name": "symfony/inflector", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/inflector.git", + "reference": "9f64271222922ef1a10e43f77d88baf72bf22b0e" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/inflector/zipball/9f64271222922ef1a10e43f77d88baf72bf22b0e", + "reference": "9f64271222922ef1a10e43f77d88baf72bf22b0e", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/polyfill-ctype": "~1.8" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Inflector\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Bernhard Schussek", + "email": "bschussek@gmail.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Inflector Component", + "homepage": "https://symfony.com", + "keywords": [ + "inflection", + "pluralize", + "singularize", + "string", + "symfony", + "words" + ], + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/intl", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/intl.git", + "reference": "9bc515dfd1f02bcf64309ab5fd86bace4f43b86d" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/intl/zipball/9bc515dfd1f02bcf64309ab5fd86bace4f43b86d", + "reference": "9bc515dfd1f02bcf64309ab5fd86bace4f43b86d", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/polyfill-intl-icu": "~1.0" + }, + "require-dev": { + "symfony/filesystem": "~3.4|~4.0" + }, + "suggest": { + "ext-intl": "to use the component with locales other than \"en\"" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Intl\\": "" + }, + "classmap": [ + "Resources/stubs" + ], + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Bernhard Schussek", + "email": "bschussek@gmail.com" + }, + { + "name": "Eriksen Costa", + "email": "eriksen.costa@infranology.com.br" + }, + { + "name": "Igor Wiedler", + "email": "igor@wiedler.ch" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "A PHP replacement layer for the C intl extension that includes additional data from the ICU library.", + "homepage": "https://symfony.com", + "keywords": [ + "i18n", + "icu", + "internationalization", + "intl", + "l10n", + "localization" + ], + "time": "2019-01-05T16:37:49+00:00" + }, + { + "name": "symfony/monolog-bridge", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/monolog-bridge.git", + "reference": "8fa559511f1d215ca81e22f222d50eb029f93902" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/monolog-bridge/zipball/8fa559511f1d215ca81e22f222d50eb029f93902", + "reference": "8fa559511f1d215ca81e22f222d50eb029f93902", + "shasum": "" + }, + "require": { + "monolog/monolog": "~1.19", + "php": "^7.1.3", + "symfony/contracts": "^1.0", + "symfony/http-kernel": "~3.4|~4.0" + }, + "conflict": { + "symfony/console": "<3.4", + "symfony/http-foundation": "<3.4" + }, + "require-dev": { + "symfony/console": "~3.4|~4.0", + "symfony/event-dispatcher": "~3.4|~4.0", + "symfony/security-core": "~3.4|~4.0", + "symfony/var-dumper": "~3.4|~4.0" + }, + "suggest": { + "symfony/console": "For the possibility to show log messages in console commands depending on verbosity settings.", + "symfony/event-dispatcher": "Needed when using log messages in console commands.", + "symfony/http-kernel": "For using the debugging handlers together with the response life cycle of the HTTP kernel.", + "symfony/var-dumper": "For using the debugging handlers like the console handler or the log server handler." + }, + "type": "symfony-bridge", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Bridge\\Monolog\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Monolog Bridge", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, { "name": "symfony/monolog-bundle", "version": "v3.3.1", @@ -2331,6 +3194,88 @@ ], "time": "2018-11-04T09:58:13+00:00" }, + { + "name": "symfony/options-resolver", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/options-resolver.git", + "reference": "fbcb106aeee72f3450298bf73324d2cc00d083d1" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/options-resolver/zipball/fbcb106aeee72f3450298bf73324d2cc00d083d1", + "reference": "fbcb106aeee72f3450298bf73324d2cc00d083d1", + "shasum": "" + }, + "require": { + "php": "^7.1.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\OptionsResolver\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony OptionsResolver Component", + "homepage": "https://symfony.com", + "keywords": [ + "config", + "configuration", + "options" + ], + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/orm-pack", + "version": "v1.0.6", + "source": { + "type": "git", + "url": "https://github.com/symfony/orm-pack.git", + "reference": "36c2a928482dc5f05c5c1c1b947242ae03ff1335" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/orm-pack/zipball/36c2a928482dc5f05c5c1c1b947242ae03ff1335", + "reference": "36c2a928482dc5f05c5c1c1b947242ae03ff1335", + "shasum": "" + }, + "require": { + "doctrine/doctrine-bundle": "^1.6.10", + "doctrine/doctrine-migrations-bundle": "^1.3|^2.0", + "doctrine/orm": "^2.5.11", + "php": "^7.0" + }, + "type": "symfony-pack", + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "A pack for the Doctrine ORM", + "time": "2019-01-16T09:49:15+00:00" + }, { "name": "symfony/polyfill-ctype", "version": "v1.10.0", @@ -2507,177 +3452,28 @@ "time": "2018-09-21T13:07:52+00:00" }, { - "name": "symfony/polyfill-php72", - "version": "v1.10.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-php72.git", - "reference": "9050816e2ca34a8e916c3a0ae8b9c2fccf68b631" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/9050816e2ca34a8e916c3a0ae8b9c2fccf68b631", - "reference": "9050816e2ca34a8e916c3a0ae8b9c2fccf68b631", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.9-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Php72\\": "" - }, - "files": [ - "bootstrap.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill backporting some PHP 7.2+ features to lower PHP versions", - "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "polyfill", - "portable", - "shim" - ], - "time": "2018-09-21T13:07:52+00:00" - }, - { - "name": "symfony/symfony", + "name": "symfony/property-access", "version": "v4.2.2", "source": { "type": "git", - "url": "https://github.com/symfony/symfony.git", - "reference": "4b3e32332fd3559a644a262be53228422e5393d3" + "url": "https://github.com/symfony/property-access.git", + "reference": "a21d40670000f61a1a4b90a607d54696aad914cd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/symfony/zipball/4b3e32332fd3559a644a262be53228422e5393d3", - "reference": "4b3e32332fd3559a644a262be53228422e5393d3", + "url": "https://api.github.com/repos/symfony/property-access/zipball/a21d40670000f61a1a4b90a607d54696aad914cd", + "reference": "a21d40670000f61a1a4b90a607d54696aad914cd", "shasum": "" }, "require": { - "doctrine/collections": "~1.0", - "doctrine/event-manager": "~1.0", - "doctrine/persistence": "~1.0", - "ext-xml": "*", - "fig/link-util": "^1.0", "php": "^7.1.3", - "psr/cache": "~1.0", - "psr/container": "^1.0", - "psr/link": "^1.0", - "psr/log": "~1.0", - "psr/simple-cache": "^1.0", - "symfony/contracts": "^1.0.2", - "symfony/polyfill-ctype": "~1.8", - "symfony/polyfill-intl-icu": "~1.0", - "symfony/polyfill-mbstring": "~1.0", - "symfony/polyfill-php72": "~1.5", - "twig/twig": "^1.35|^2.4.4" - }, - "conflict": { - "phpdocumentor/reflection-docblock": "<3.0||>=3.2.0,<3.2.2", - "phpdocumentor/type-resolver": "<0.3.0", - "phpunit/phpunit": "<5.4.3" - }, - "provide": { - "psr/cache-implementation": "1.0", - "psr/container-implementation": "1.0", - "psr/log-implementation": "1.0", - "psr/simple-cache-implementation": "1.0", - "symfony/cache-contracts": "1.0", - "symfony/service-contracts": "1.0", - "symfony/translation-contracts": "1.0" - }, - "replace": { - "symfony/asset": "self.version", - "symfony/browser-kit": "self.version", - "symfony/cache": "self.version", - "symfony/config": "self.version", - "symfony/console": "self.version", - "symfony/css-selector": "self.version", - "symfony/debug": "self.version", - "symfony/debug-bundle": "self.version", - "symfony/dependency-injection": "self.version", - "symfony/doctrine-bridge": "self.version", - "symfony/dom-crawler": "self.version", - "symfony/dotenv": "self.version", - "symfony/event-dispatcher": "self.version", - "symfony/expression-language": "self.version", - "symfony/filesystem": "self.version", - "symfony/finder": "self.version", - "symfony/form": "self.version", - "symfony/framework-bundle": "self.version", - "symfony/http-foundation": "self.version", - "symfony/http-kernel": "self.version", - "symfony/inflector": "self.version", - "symfony/intl": "self.version", - "symfony/ldap": "self.version", - "symfony/lock": "self.version", - "symfony/messenger": "self.version", - "symfony/monolog-bridge": "self.version", - "symfony/options-resolver": "self.version", - "symfony/process": "self.version", - "symfony/property-access": "self.version", - "symfony/property-info": "self.version", - "symfony/proxy-manager-bridge": "self.version", - "symfony/routing": "self.version", - "symfony/security": "self.version", - "symfony/security-bundle": "self.version", - "symfony/security-core": "self.version", - "symfony/security-csrf": "self.version", - "symfony/security-guard": "self.version", - "symfony/security-http": "self.version", - "symfony/serializer": "self.version", - "symfony/stopwatch": "self.version", - "symfony/templating": "self.version", - "symfony/translation": "self.version", - "symfony/twig-bridge": "self.version", - "symfony/twig-bundle": "self.version", - "symfony/validator": "self.version", - "symfony/var-dumper": "self.version", - "symfony/var-exporter": "self.version", - "symfony/web-link": "self.version", - "symfony/web-profiler-bundle": "self.version", - "symfony/web-server-bundle": "self.version", - "symfony/workflow": "self.version", - "symfony/yaml": "self.version" + "symfony/inflector": "~3.4|~4.0" }, "require-dev": { - "cache/integration-tests": "dev-master", - "doctrine/annotations": "~1.0", - "doctrine/cache": "~1.6", - "doctrine/data-fixtures": "1.0.*", - "doctrine/dbal": "~2.4", - "doctrine/doctrine-bundle": "~1.4", - "doctrine/orm": "~2.4,>=2.4.5", - "doctrine/reflection": "~1.0", - "egulias/email-validator": "~1.2,>=1.2.8|~2.0", - "monolog/monolog": "~1.11", - "ocramius/proxy-manager": "~0.4|~1.0|~2.0", - "phpdocumentor/reflection-docblock": "^3.0|^4.0", - "predis/predis": "~1.1", - "symfony/phpunit-bridge": "~3.4|~4.0", - "symfony/security-acl": "~2.8|~3.0" + "symfony/cache": "~3.4|~4.0" + }, + "suggest": { + "psr/cache-implementation": "To cache access methods." }, "type": "library", "extra": { @@ -2687,18 +3483,10 @@ }, "autoload": { "psr-4": { - "Symfony\\Bridge\\Doctrine\\": "src/Symfony/Bridge/Doctrine/", - "Symfony\\Bridge\\Monolog\\": "src/Symfony/Bridge/Monolog/", - "Symfony\\Bridge\\ProxyManager\\": "src/Symfony/Bridge/ProxyManager/", - "Symfony\\Bridge\\Twig\\": "src/Symfony/Bridge/Twig/", - "Symfony\\Bundle\\": "src/Symfony/Bundle/", - "Symfony\\Component\\": "src/Symfony/Component/" + "Symfony\\Component\\PropertyAccess\\": "" }, - "classmap": [ - "src/Symfony/Component/Intl/Resources/stubs" - ], "exclude-from-classmap": [ - "**/Tests/" + "/Tests/" ] }, "notification-url": "https://packagist.org/downloads/", @@ -2715,12 +3503,780 @@ "homepage": "https://symfony.com/contributors" } ], - "description": "The Symfony PHP framework", + "description": "Symfony PropertyAccess Component", "homepage": "https://symfony.com", "keywords": [ - "framework" + "access", + "array", + "extraction", + "index", + "injection", + "object", + "property", + "property path", + "reflection" ], - "time": "2019-01-06T16:19:41+00:00" + "time": "2019-01-05T16:37:49+00:00" + }, + { + "name": "symfony/routing", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/routing.git", + "reference": "e69b7a13a0b58af378a49b49dd7084462de16cee" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/routing/zipball/e69b7a13a0b58af378a49b49dd7084462de16cee", + "reference": "e69b7a13a0b58af378a49b49dd7084462de16cee", + "shasum": "" + }, + "require": { + "php": "^7.1.3" + }, + "conflict": { + "symfony/config": "<4.2", + "symfony/dependency-injection": "<3.4", + "symfony/yaml": "<3.4" + }, + "require-dev": { + "doctrine/annotations": "~1.0", + "psr/log": "~1.0", + "symfony/config": "~4.2", + "symfony/dependency-injection": "~3.4|~4.0", + "symfony/expression-language": "~3.4|~4.0", + "symfony/http-foundation": "~3.4|~4.0", + "symfony/yaml": "~3.4|~4.0" + }, + "suggest": { + "doctrine/annotations": "For using the annotation loader", + "symfony/config": "For using the all-in-one router or any loader", + "symfony/dependency-injection": "For loading routes from a service", + "symfony/expression-language": "For using expression matching", + "symfony/http-foundation": "For using a Symfony Request object", + "symfony/yaml": "For using the YAML loader" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Routing\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Routing Component", + "homepage": "https://symfony.com", + "keywords": [ + "router", + "routing", + "uri", + "url" + ], + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/security-bundle", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/security-bundle.git", + "reference": "404bb89be12ba0e493e05f0a3196f07915bd155f" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/security-bundle/zipball/404bb89be12ba0e493e05f0a3196f07915bd155f", + "reference": "404bb89be12ba0e493e05f0a3196f07915bd155f", + "shasum": "" + }, + "require": { + "ext-xml": "*", + "php": "^7.1.3", + "symfony/config": "^4.2", + "symfony/dependency-injection": "^4.2", + "symfony/http-kernel": "^4.1", + "symfony/security-core": "~4.2", + "symfony/security-csrf": "~4.2", + "symfony/security-guard": "~4.2", + "symfony/security-http": "~4.2" + }, + "conflict": { + "symfony/browser-kit": "<4.2", + "symfony/console": "<3.4", + "symfony/event-dispatcher": "<3.4", + "symfony/framework-bundle": "<4.2", + "symfony/twig-bundle": "<4.2", + "symfony/var-dumper": "<3.4" + }, + "require-dev": { + "doctrine/doctrine-bundle": "~1.5", + "symfony/asset": "~3.4|~4.0", + "symfony/browser-kit": "~4.2", + "symfony/console": "~3.4|~4.0", + "symfony/css-selector": "~3.4|~4.0", + "symfony/dom-crawler": "~3.4|~4.0", + "symfony/event-dispatcher": "~3.4|~4.0", + "symfony/expression-language": "~3.4|~4.0", + "symfony/form": "~3.4|~4.0", + "symfony/framework-bundle": "~4.2", + "symfony/http-foundation": "~3.4|~4.0", + "symfony/process": "~3.4|~4.0", + "symfony/translation": "~3.4|~4.0", + "symfony/twig-bridge": "~3.4|~4.0", + "symfony/twig-bundle": "~4.2", + "symfony/validator": "~3.4|~4.0", + "symfony/var-dumper": "~3.4|~4.0", + "symfony/yaml": "~3.4|~4.0", + "twig/twig": "~1.34|~2.4" + }, + "type": "symfony-bundle", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Bundle\\SecurityBundle\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony SecurityBundle", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/security-core", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/security-core.git", + "reference": "b5129a59e1c052b0bfef97ad9b657b42e0f4e5f5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/security-core/zipball/b5129a59e1c052b0bfef97ad9b657b42e0f4e5f5", + "reference": "b5129a59e1c052b0bfef97ad9b657b42e0f4e5f5", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/contracts": "^1.0" + }, + "require-dev": { + "psr/container": "^1.0", + "psr/log": "~1.0", + "symfony/event-dispatcher": "~3.4|~4.0", + "symfony/expression-language": "~3.4|~4.0", + "symfony/http-foundation": "~3.4|~4.0", + "symfony/ldap": "~3.4|~4.0", + "symfony/validator": "~3.4|~4.0" + }, + "suggest": { + "psr/container-implementation": "To instantiate the Security class", + "symfony/event-dispatcher": "", + "symfony/expression-language": "For using the expression voter", + "symfony/http-foundation": "", + "symfony/ldap": "For using LDAP integration", + "symfony/validator": "For using the user password constraint" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Security\\Core\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Security Component - Core Library", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/security-csrf", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/security-csrf.git", + "reference": "f53f651be1383e2a3db4372ff6784db6218cd16d" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/security-csrf/zipball/f53f651be1383e2a3db4372ff6784db6218cd16d", + "reference": "f53f651be1383e2a3db4372ff6784db6218cd16d", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/security-core": "~3.4|~4.0" + }, + "conflict": { + "symfony/http-foundation": "<3.4" + }, + "require-dev": { + "symfony/http-foundation": "~3.4|~4.0" + }, + "suggest": { + "symfony/http-foundation": "For using the class SessionTokenStorage." + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Security\\Csrf\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Security Component - CSRF Library", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/security-guard", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/security-guard.git", + "reference": "5e2ff0a09ea74f3290f5c23921098308ad91b15f" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/security-guard/zipball/5e2ff0a09ea74f3290f5c23921098308ad91b15f", + "reference": "5e2ff0a09ea74f3290f5c23921098308ad91b15f", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/security-core": "~3.4|~4.0", + "symfony/security-http": "~3.4|~4.0" + }, + "require-dev": { + "psr/log": "~1.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Security\\Guard\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Security Component - Guard", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/security-http", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/security-http.git", + "reference": "0d8dab27f2409fba34d3b7f1f0ebcf1ec344c1b7" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/security-http/zipball/0d8dab27f2409fba34d3b7f1f0ebcf1ec344c1b7", + "reference": "0d8dab27f2409fba34d3b7f1f0ebcf1ec344c1b7", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/event-dispatcher": "~3.4|~4.0", + "symfony/http-foundation": "~3.4|~4.0", + "symfony/http-kernel": "~3.4|~4.0", + "symfony/property-access": "~3.4|~4.0", + "symfony/security-core": "~3.4|~4.0" + }, + "conflict": { + "symfony/security-csrf": "<3.4.11|~4.0,<4.0.11" + }, + "require-dev": { + "psr/log": "~1.0", + "symfony/routing": "~3.4|~4.0", + "symfony/security-csrf": "^3.4.11|^4.0.11" + }, + "suggest": { + "symfony/routing": "For using the HttpUtils class to create sub-requests, redirect the user, and match URLs", + "symfony/security-csrf": "For using tokens to protect authentication/logout attempts" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Security\\Http\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Security Component - HTTP Integration", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/stopwatch", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/stopwatch.git", + "reference": "af62b35760fc92c8dbdce659b4eebdfe0e6a0472" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/stopwatch/zipball/af62b35760fc92c8dbdce659b4eebdfe0e6a0472", + "reference": "af62b35760fc92c8dbdce659b4eebdfe0e6a0472", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/contracts": "^1.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Stopwatch\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Stopwatch Component", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/translation", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/translation.git", + "reference": "939fb792d73f2ce80e6ae9019d205fc480f1c9a0" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/translation/zipball/939fb792d73f2ce80e6ae9019d205fc480f1c9a0", + "reference": "939fb792d73f2ce80e6ae9019d205fc480f1c9a0", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/contracts": "^1.0.2", + "symfony/polyfill-mbstring": "~1.0" + }, + "conflict": { + "symfony/config": "<3.4", + "symfony/dependency-injection": "<3.4", + "symfony/yaml": "<3.4" + }, + "provide": { + "symfony/translation-contracts-implementation": "1.0" + }, + "require-dev": { + "psr/log": "~1.0", + "symfony/config": "~3.4|~4.0", + "symfony/console": "~3.4|~4.0", + "symfony/dependency-injection": "~3.4|~4.0", + "symfony/finder": "~2.8|~3.0|~4.0", + "symfony/intl": "~3.4|~4.0", + "symfony/yaml": "~3.4|~4.0" + }, + "suggest": { + "psr/log-implementation": "To use logging capability in translator", + "symfony/config": "", + "symfony/yaml": "" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Translation\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Translation Component", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/twig-bridge", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/twig-bridge.git", + "reference": "bf9379a4fae77a05a2446880bc7867651e8b2a87" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/twig-bridge/zipball/bf9379a4fae77a05a2446880bc7867651e8b2a87", + "reference": "bf9379a4fae77a05a2446880bc7867651e8b2a87", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/contracts": "^1.0.2", + "twig/twig": "^1.35|^2.4.4" + }, + "conflict": { + "symfony/console": "<3.4", + "symfony/form": "<4.2", + "symfony/translation": "<4.2" + }, + "require-dev": { + "symfony/asset": "~3.4|~4.0", + "symfony/console": "~3.4|~4.0", + "symfony/dependency-injection": "~3.4|~4.0", + "symfony/expression-language": "~3.4|~4.0", + "symfony/finder": "~3.4|~4.0", + "symfony/form": "^4.2", + "symfony/http-foundation": "~3.4|~4.0", + "symfony/http-kernel": "~3.4|~4.0", + "symfony/polyfill-intl-icu": "~1.0", + "symfony/routing": "~3.4|~4.0", + "symfony/security": "~3.4|~4.0", + "symfony/security-acl": "~2.8|~3.0", + "symfony/stopwatch": "~3.4|~4.0", + "symfony/templating": "~3.4|~4.0", + "symfony/translation": "~4.2", + "symfony/var-dumper": "~3.4|~4.0", + "symfony/web-link": "~3.4|~4.0", + "symfony/workflow": "~3.4|~4.0", + "symfony/yaml": "~3.4|~4.0" + }, + "suggest": { + "symfony/asset": "For using the AssetExtension", + "symfony/expression-language": "For using the ExpressionExtension", + "symfony/finder": "", + "symfony/form": "For using the FormExtension", + "symfony/http-kernel": "For using the HttpKernelExtension", + "symfony/routing": "For using the RoutingExtension", + "symfony/security": "For using the SecurityExtension", + "symfony/stopwatch": "For using the StopwatchExtension", + "symfony/templating": "For using the TwigEngine", + "symfony/translation": "For using the TranslationExtension", + "symfony/var-dumper": "For using the DumpExtension", + "symfony/web-link": "For using the WebLinkExtension", + "symfony/yaml": "For using the YamlExtension" + }, + "type": "symfony-bridge", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Bridge\\Twig\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Twig Bridge", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/twig-bundle", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/twig-bundle.git", + "reference": "28066429877c23536cd74feec17154e8089d87f5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/twig-bundle/zipball/28066429877c23536cd74feec17154e8089d87f5", + "reference": "28066429877c23536cd74feec17154e8089d87f5", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/config": "~4.2", + "symfony/http-foundation": "~4.1", + "symfony/http-kernel": "~4.1", + "symfony/polyfill-ctype": "~1.8", + "symfony/twig-bridge": "^4.2", + "twig/twig": "~1.34|~2.4" + }, + "conflict": { + "symfony/dependency-injection": "<4.1", + "symfony/framework-bundle": "<4.1", + "symfony/translation": "<4.2" + }, + "require-dev": { + "doctrine/annotations": "~1.0", + "doctrine/cache": "~1.0", + "symfony/asset": "~3.4|~4.0", + "symfony/dependency-injection": "~4.1", + "symfony/expression-language": "~3.4|~4.0", + "symfony/finder": "~3.4|~4.0", + "symfony/form": "~3.4|~4.0", + "symfony/framework-bundle": "~4.1", + "symfony/routing": "~3.4|~4.0", + "symfony/stopwatch": "~3.4|~4.0", + "symfony/templating": "~3.4|~4.0", + "symfony/translation": "^4.2", + "symfony/web-link": "~3.4|~4.0", + "symfony/yaml": "~3.4|~4.0" + }, + "type": "symfony-bundle", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Bundle\\TwigBundle\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony TwigBundle", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/var-exporter", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/var-exporter.git", + "reference": "51bd782120fa2bfed89452f142d2a47c4b51101c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/var-exporter/zipball/51bd782120fa2bfed89452f142d2a47c4b51101c", + "reference": "51bd782120fa2bfed89452f142d2a47c4b51101c", + "shasum": "" + }, + "require": { + "php": "^7.1.3" + }, + "require-dev": { + "symfony/var-dumper": "^4.1.1" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\VarExporter\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "A blend of var_export() + serialize() to turn any serializable data structure to plain PHP code", + "homepage": "https://symfony.com", + "keywords": [ + "clone", + "construct", + "export", + "hydrate", + "instantiate", + "serialize" + ], + "time": "2019-01-03T09:09:06+00:00" }, { "name": "theodordiaconu/geshi", @@ -2978,6 +4534,233 @@ } ], "packages-dev": [ + { + "name": "doctrine/data-fixtures", + "version": "v1.3.1", + "source": { + "type": "git", + "url": "https://github.com/doctrine/data-fixtures.git", + "reference": "3a1e2c3c600e615a2dffe56d4ca0875cc5233e0a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/doctrine/data-fixtures/zipball/3a1e2c3c600e615a2dffe56d4ca0875cc5233e0a", + "reference": "3a1e2c3c600e615a2dffe56d4ca0875cc5233e0a", + "shasum": "" + }, + "require": { + "doctrine/common": "~2.2", + "php": "^7.1" + }, + "conflict": { + "doctrine/phpcr-odm": "<1.3.0" + }, + "require-dev": { + "doctrine/dbal": "^2.5.4", + "doctrine/orm": "^2.5.4", + "phpunit/phpunit": "^7.0" + }, + "suggest": { + "alcaeus/mongo-php-adapter": "For using MongoDB ODM with PHP 7", + "doctrine/mongodb-odm": "For loading MongoDB ODM fixtures", + "doctrine/orm": "For loading ORM fixtures", + "doctrine/phpcr-odm": "For loading PHPCR ODM fixtures" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.3.x-dev" + } + }, + "autoload": { + "psr-4": { + "Doctrine\\Common\\DataFixtures\\": "lib/Doctrine/Common/DataFixtures" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jonathan Wage", + "email": "jonwage@gmail.com" + } + ], + "description": "Data Fixtures for all Doctrine Object Managers", + "homepage": "http://www.doctrine-project.org", + "keywords": [ + "database" + ], + "time": "2018-03-20T09:06:36+00:00" + }, + { + "name": "doctrine/doctrine-fixtures-bundle", + "version": "3.1.0", + "source": { + "type": "git", + "url": "https://github.com/doctrine/DoctrineFixturesBundle.git", + "reference": "f016565b251c2dfa32a8d6da44d1650dc9ec1498" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/doctrine/DoctrineFixturesBundle/zipball/f016565b251c2dfa32a8d6da44d1650dc9ec1498", + "reference": "f016565b251c2dfa32a8d6da44d1650dc9ec1498", + "shasum": "" + }, + "require": { + "doctrine/data-fixtures": "^1.3", + "doctrine/doctrine-bundle": "^1.6", + "php": "^7.1", + "symfony/doctrine-bridge": "~3.4|^4.1", + "symfony/framework-bundle": "^3.4|^4.1" + }, + "require-dev": { + "doctrine/coding-standard": "^5.0", + "phpunit/phpunit": "^7.4", + "symfony/phpunit-bridge": "^4.1" + }, + "type": "symfony-bundle", + "extra": { + "branch-alias": { + "dev-master": "3.1.x-dev" + } + }, + "autoload": { + "psr-4": { + "Doctrine\\Bundle\\FixturesBundle\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Symfony Community", + "homepage": "http://symfony.com/contributors" + }, + { + "name": "Doctrine Project", + "homepage": "http://www.doctrine-project.org" + }, + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + } + ], + "description": "Symfony DoctrineFixturesBundle", + "homepage": "http://www.doctrine-project.org", + "keywords": [ + "Fixture", + "persistence" + ], + "time": "2018-12-21T10:10:51+00:00" + }, + { + "name": "easycorp/easy-log-handler", + "version": "v1.0.7", + "source": { + "type": "git", + "url": "https://github.com/EasyCorp/easy-log-handler.git", + "reference": "5f95717248d20684f88cfb878d8bf3d78aadcbba" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/EasyCorp/easy-log-handler/zipball/5f95717248d20684f88cfb878d8bf3d78aadcbba", + "reference": "5f95717248d20684f88cfb878d8bf3d78aadcbba", + "shasum": "" + }, + "require": { + "monolog/monolog": "~1.6", + "php": ">=5.3.0", + "symfony/yaml": "~2.3|~3.0|~4.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "EasyCorp\\EasyLog\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Javier Eguiluz", + "email": "javiereguiluz@gmail.com" + }, + { + "name": "Project Contributors", + "homepage": "https://github.com/EasyCorp/easy-log-handler" + } + ], + "description": "A handler for Monolog that optimizes log messages to be processed by humans instead of software. Improve your productivity with logs that are easy to understand.", + "homepage": "https://github.com/EasyCorp/easy-log-handler", + "keywords": [ + "easy", + "log", + "logging", + "monolog", + "productivity" + ], + "time": "2018-07-27T15:41:37+00:00" + }, + { + "name": "fig/link-util", + "version": "1.0.0", + "source": { + "type": "git", + "url": "https://github.com/php-fig/link-util.git", + "reference": "1a07821801a148be4add11ab0603e4af55a72fac" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/link-util/zipball/1a07821801a148be4add11ab0603e4af55a72fac", + "reference": "1a07821801a148be4add11ab0603e4af55a72fac", + "shasum": "" + }, + "require": { + "php": ">=5.5.0", + "psr/link": "~1.0@dev" + }, + "require-dev": { + "phpunit/phpunit": "^5.1", + "squizlabs/php_codesniffer": "^2.3.1" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Fig\\Link\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" + } + ], + "description": "Common utility implementations for HTTP links", + "keywords": [ + "http", + "http-link", + "link", + "psr", + "psr-13", + "rest" + ], + "time": "2016-10-17T18:31:11+00:00" + }, { "name": "paragonie/random_compat", "version": "v9.99.99", @@ -3022,6 +4805,600 @@ "random" ], "time": "2018-07-02T15:55:56+00:00" + }, + { + "name": "psr/link", + "version": "1.0.0", + "source": { + "type": "git", + "url": "https://github.com/php-fig/link.git", + "reference": "eea8e8662d5cd3ae4517c9b864493f59fca95562" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/link/zipball/eea8e8662d5cd3ae4517c9b864493f59fca95562", + "reference": "eea8e8662d5cd3ae4517c9b864493f59fca95562", + "shasum": "" + }, + "require": { + "php": ">=5.3.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\Link\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" + } + ], + "description": "Common interfaces for HTTP links", + "keywords": [ + "http", + "http-link", + "link", + "psr", + "psr-13", + "rest" + ], + "time": "2016-10-28T16:06:13+00:00" + }, + { + "name": "symfony/debug-bundle", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/debug-bundle.git", + "reference": "be5cf5e46533de3e9325a2442fb4075787545140" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/debug-bundle/zipball/be5cf5e46533de3e9325a2442fb4075787545140", + "reference": "be5cf5e46533de3e9325a2442fb4075787545140", + "shasum": "" + }, + "require": { + "ext-xml": "*", + "php": "^7.1.3", + "symfony/http-kernel": "~3.4|~4.0", + "symfony/twig-bridge": "~3.4|~4.0", + "symfony/var-dumper": "^4.1.1" + }, + "conflict": { + "symfony/config": "<4.2", + "symfony/dependency-injection": "<3.4" + }, + "require-dev": { + "symfony/config": "~4.2", + "symfony/dependency-injection": "~3.4|~4.0", + "symfony/web-profiler-bundle": "~3.4|~4.0" + }, + "suggest": { + "symfony/config": "For service container configuration", + "symfony/dependency-injection": "For using as a service from the container" + }, + "type": "symfony-bundle", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Bundle\\DebugBundle\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony DebugBundle", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/debug-pack", + "version": "v1.0.7", + "source": { + "type": "git", + "url": "https://github.com/symfony/debug-pack.git", + "reference": "09a4a1e9bf2465987d4f79db0ad6c11cc632bc79" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/debug-pack/zipball/09a4a1e9bf2465987d4f79db0ad6c11cc632bc79", + "reference": "09a4a1e9bf2465987d4f79db0ad6c11cc632bc79", + "shasum": "" + }, + "require": { + "easycorp/easy-log-handler": "^1.0.7", + "php": "^7.0", + "symfony/debug-bundle": "*", + "symfony/monolog-bundle": "^3.0", + "symfony/profiler-pack": "*", + "symfony/var-dumper": "*" + }, + "type": "symfony-pack", + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "A debug pack for Symfony projects", + "time": "2018-12-10T12:11:11+00:00" + }, + { + "name": "symfony/dotenv", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/dotenv.git", + "reference": "36e4e4750a88f52a5542bd8a54a947cb57039ece" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/dotenv/zipball/36e4e4750a88f52a5542bd8a54a947cb57039ece", + "reference": "36e4e4750a88f52a5542bd8a54a947cb57039ece", + "shasum": "" + }, + "require": { + "php": "^7.1.3" + }, + "require-dev": { + "symfony/process": "~3.4|~4.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Dotenv\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Registers environment variables from a .env file", + "homepage": "https://symfony.com", + "keywords": [ + "dotenv", + "env", + "environment" + ], + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/polyfill-php72", + "version": "v1.10.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-php72.git", + "reference": "9050816e2ca34a8e916c3a0ae8b9c2fccf68b631" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/9050816e2ca34a8e916c3a0ae8b9c2fccf68b631", + "reference": "9050816e2ca34a8e916c3a0ae8b9c2fccf68b631", + "shasum": "" + }, + "require": { + "php": ">=5.3.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.9-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Polyfill\\Php72\\": "" + }, + "files": [ + "bootstrap.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill backporting some PHP 7.2+ features to lower PHP versions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "polyfill", + "portable", + "shim" + ], + "time": "2018-09-21T13:07:52+00:00" + }, + { + "name": "symfony/process", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/process.git", + "reference": "ea043ab5d8ed13b467a9087d81cb876aee7f689a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/process/zipball/ea043ab5d8ed13b467a9087d81cb876aee7f689a", + "reference": "ea043ab5d8ed13b467a9087d81cb876aee7f689a", + "shasum": "" + }, + "require": { + "php": "^7.1.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Process\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Process Component", + "homepage": "https://symfony.com", + "time": "2019-01-03T14:48:52+00:00" + }, + { + "name": "symfony/profiler-pack", + "version": "v1.0.4", + "source": { + "type": "git", + "url": "https://github.com/symfony/profiler-pack.git", + "reference": "99c4370632c2a59bb0444852f92140074ef02209" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/profiler-pack/zipball/99c4370632c2a59bb0444852f92140074ef02209", + "reference": "99c4370632c2a59bb0444852f92140074ef02209", + "shasum": "" + }, + "require": { + "php": "^7.0", + "symfony/stopwatch": "*", + "symfony/twig-bundle": "*", + "symfony/web-profiler-bundle": "*" + }, + "type": "symfony-pack", + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "A pack for the Symfony web profiler", + "time": "2018-12-10T12:11:44+00:00" + }, + { + "name": "symfony/var-dumper", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/var-dumper.git", + "reference": "85bde661b178173d85c6f11ea9d03b61d1212bb2" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/var-dumper/zipball/85bde661b178173d85c6f11ea9d03b61d1212bb2", + "reference": "85bde661b178173d85c6f11ea9d03b61d1212bb2", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/polyfill-mbstring": "~1.0", + "symfony/polyfill-php72": "~1.5" + }, + "conflict": { + "phpunit/phpunit": "<4.8.35|<5.4.3,>=5.0", + "symfony/console": "<3.4" + }, + "require-dev": { + "ext-iconv": "*", + "symfony/console": "~3.4|~4.0", + "symfony/process": "~3.4|~4.0", + "twig/twig": "~1.34|~2.4" + }, + "suggest": { + "ext-iconv": "To convert non-UTF-8 strings to UTF-8 (or symfony/polyfill-iconv in case ext-iconv cannot be used).", + "ext-intl": "To show region name in time zone dump", + "symfony/console": "To use the ServerDumpCommand and/or the bin/var-dump-server script" + }, + "bin": [ + "Resources/bin/var-dump-server" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "files": [ + "Resources/functions/dump.php" + ], + "psr-4": { + "Symfony\\Component\\VarDumper\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony mechanism for exploring and dumping PHP variables", + "homepage": "https://symfony.com", + "keywords": [ + "debug", + "dump" + ], + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/web-profiler-bundle", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/web-profiler-bundle.git", + "reference": "03ea366e5485089e7f4aeee7386dea07fe655454" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/web-profiler-bundle/zipball/03ea366e5485089e7f4aeee7386dea07fe655454", + "reference": "03ea366e5485089e7f4aeee7386dea07fe655454", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/config": "^4.2", + "symfony/http-kernel": "~4.2", + "symfony/routing": "~3.4|~4.0", + "symfony/twig-bundle": "~4.2", + "symfony/var-dumper": "~3.4|~4.0", + "twig/twig": "~1.34|~2.4" + }, + "conflict": { + "symfony/dependency-injection": "<3.4", + "symfony/event-dispatcher": "<3.4", + "symfony/messenger": "<4.2", + "symfony/var-dumper": "<3.4" + }, + "require-dev": { + "symfony/console": "~3.4|~4.0", + "symfony/dependency-injection": "~3.4|~4.0", + "symfony/stopwatch": "~3.4|~4.0" + }, + "type": "symfony-bundle", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Bundle\\WebProfilerBundle\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony WebProfilerBundle", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/web-server-bundle", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/web-server-bundle.git", + "reference": "8d7c77f58cf8f6d018c4c80cea9e067a83921f1c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/web-server-bundle/zipball/8d7c77f58cf8f6d018c4c80cea9e067a83921f1c", + "reference": "8d7c77f58cf8f6d018c4c80cea9e067a83921f1c", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/config": "~3.4|~4.0", + "symfony/console": "~3.4|~4.0", + "symfony/dependency-injection": "~3.4|~4.0", + "symfony/http-kernel": "~3.4|~4.0", + "symfony/polyfill-ctype": "~1.8", + "symfony/process": "^3.4.2|^4.0.2" + }, + "suggest": { + "symfony/expression-language": "For using the filter option of the log server.", + "symfony/monolog-bridge": "For using the log server." + }, + "type": "symfony-bundle", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Bundle\\WebServerBundle\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony WebServerBundle", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/yaml", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/yaml.git", + "reference": "d0aa6c0ea484087927b49fd513383a7d36190ca6" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/yaml/zipball/d0aa6c0ea484087927b49fd513383a7d36190ca6", + "reference": "d0aa6c0ea484087927b49fd513383a7d36190ca6", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/polyfill-ctype": "~1.8" + }, + "conflict": { + "symfony/console": "<3.4" + }, + "require-dev": { + "symfony/console": "~3.4|~4.0" + }, + "suggest": { + "symfony/console": "For validating YAML files using the lint command" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Yaml\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Yaml Component", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" } ], "aliases": [], diff --git a/config/packages/cache.yaml b/config/packages/cache.yaml new file mode 100644 index 0000000..93e620e --- /dev/null +++ b/config/packages/cache.yaml @@ -0,0 +1,19 @@ +framework: + cache: + # Put the unique name of your app here: the prefix seed + # is used to compute stable namespaces for cache keys. + #prefix_seed: your_vendor_name/app_name + + # The app cache caches to the filesystem by default. + # Other options include: + + # Redis + #app: cache.adapter.redis + #default_redis_provider: redis://localhost + + # APCu (not recommended with heavy random-write workloads as memory fragmentation can cause perf issues) + #app: cache.adapter.apcu + + # Namespaced pools use the above "app" backend by default + #pools: + #my.dedicated.cache: ~ diff --git a/config/packages/dev/debug.yaml b/config/packages/dev/debug.yaml new file mode 100644 index 0000000..26d4e53 --- /dev/null +++ b/config/packages/dev/debug.yaml @@ -0,0 +1,4 @@ +debug: + # Forwards VarDumper Data clones to a centralized server allowing to inspect dumps on CLI or in your browser. + # See the "server:dump" command to start a new server. + dump_destination: "tcp://%env(VAR_DUMPER_SERVER)%" diff --git a/config/packages/dev/easy_log_handler.yaml b/config/packages/dev/easy_log_handler.yaml new file mode 100644 index 0000000..27bfc60 --- /dev/null +++ b/config/packages/dev/easy_log_handler.yaml @@ -0,0 +1,16 @@ +services: + EasyCorp\EasyLog\EasyLogHandler: + public: false + arguments: ['%kernel.logs_dir%/%kernel.environment%.log'] + +#// FIXME: How to add this configuration automatically without messing up with the monolog configuration? +#monolog: +# handlers: +# buffered: +# type: buffer +# handler: easylog +# channels: ['!event'] +# level: debug +# easylog: +# type: service +# id: EasyCorp\EasyLog\EasyLogHandler diff --git a/config/packages/doctrine.yaml b/config/packages/doctrine.yaml index 5d5dd1d..a0e7da7 100644 --- a/config/packages/doctrine.yaml +++ b/config/packages/doctrine.yaml @@ -3,12 +3,8 @@ parameters: doctrine: dbal: - default_connection: default - connections: - default: - driver: 'mysqli' - url: '%env(resolve:DATABASE_URL)%' - charset: UTF8 - + driver: 'mysqli' + url: '%env(resolve:DATABASE_URL)%' + charset: 'UTF8' orm: auto_generate_proxy_classes: "%kernel.debug%" diff --git a/config/packages/form.yaml b/config/packages/form.yaml deleted file mode 100644 index b0eeb43..0000000 --- a/config/packages/form.yaml +++ /dev/null @@ -1,3 +0,0 @@ -framework: - form: ~ - csrf_protection: ~ diff --git a/config/packages/framework.yaml b/config/packages/framework.yaml index a52f4a2..d461426 100644 --- a/config/packages/framework.yaml +++ b/config/packages/framework.yaml @@ -7,6 +7,5 @@ framework: handler_id: ~ fragments: ~ http_method_override: true - assets: ~ php_errors: log: true diff --git a/config/packages/serializer.yaml b/config/packages/serializer.yaml deleted file mode 100644 index 1795b43..0000000 --- a/config/packages/serializer.yaml +++ /dev/null @@ -1,3 +0,0 @@ -framework: - serializer: - enable_annotations: true diff --git a/config/packages/test/routing.yaml b/config/packages/test/routing.yaml new file mode 100644 index 0000000..4116679 --- /dev/null +++ b/config/packages/test/routing.yaml @@ -0,0 +1,3 @@ +framework: + router: + strict_requirements: true diff --git a/config/packages/validation.yaml b/config/packages/validation.yaml deleted file mode 100644 index 61807db..0000000 --- a/config/packages/validation.yaml +++ /dev/null @@ -1,3 +0,0 @@ -framework: - validation: - enable_annotations: true diff --git a/config/routes/dev/web_profiler.yaml b/config/routes/dev/web_profiler.yaml new file mode 100644 index 0000000..c82beff --- /dev/null +++ b/config/routes/dev/web_profiler.yaml @@ -0,0 +1,7 @@ +web_profiler_wdt: + resource: '@WebProfilerBundle/Resources/config/routing/wdt.xml' + prefix: /_wdt + +web_profiler_profiler: + resource: '@WebProfilerBundle/Resources/config/routing/profiler.xml' + prefix: /_profiler diff --git a/src/Controller/.gitignore b/src/Controller/.gitignore new file mode 100644 index 0000000..e69de29 diff --git a/symfony.lock b/symfony.lock index 3f3f1bd..8249f62 100644 --- a/symfony.lock +++ b/symfony.lock @@ -1,4 +1,61 @@ { + "easycorp/easy-log-handler": { + "version": "1.0", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "master", + "version": "1.0", + "ref": "70062abc2cd58794d2a90274502f81b55cd9951b" + } + }, + "symfony/cache": { + "version": "v4.2.2" + }, + "symfony/config": { + "version": "v4.2.2" + }, + "symfony/console": { + "version": "3.3", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "master", + "version": "3.3", + "ref": "0fa049c19069a65f52c1c181d64be3de672c1504" + } + }, + "symfony/debug": { + "version": "v4.2.2" + }, + "symfony/debug-bundle": { + "version": "4.1", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "master", + "version": "4.1", + "ref": "f8863cbad2f2e58c4b65fa1eac892ab189971bea" + } + }, + "symfony/debug-pack": { + "version": "v1.0.7" + }, + "symfony/dependency-injection": { + "version": "v4.2.2" + }, + "symfony/doctrine-bridge": { + "version": "v4.2.2" + }, + "symfony/dotenv": { + "version": "v4.2.2" + }, + "symfony/event-dispatcher": { + "version": "v4.2.2" + }, + "symfony/filesystem": { + "version": "v4.2.2" + }, + "symfony/finder": { + "version": "v4.2.2" + }, "symfony/flex": { "version": "1.0", "recipe": { @@ -7,5 +64,128 @@ "version": "1.0", "ref": "dc3fc2e0334a4137c47cfd5a3ececc601fa61a0b" } + }, + "symfony/form": { + "version": "v4.2.2" + }, + "symfony/framework-bundle": { + "version": "4.2", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "master", + "version": "4.2", + "ref": "5bb3a8c27df824d195fa68bb635d074854f8498f" + } + }, + "symfony/http-foundation": { + "version": "v4.2.2" + }, + "symfony/http-kernel": { + "version": "v4.2.2" + }, + "symfony/inflector": { + "version": "v4.2.2" + }, + "symfony/intl": { + "version": "v4.2.2" + }, + "symfony/monolog-bridge": { + "version": "v4.2.2" + }, + "symfony/options-resolver": { + "version": "v4.2.2" + }, + "symfony/orm-pack": { + "version": "v1.0.6" + }, + "symfony/process": { + "version": "v4.2.2" + }, + "symfony/profiler-pack": { + "version": "v1.0.4" + }, + "symfony/property-access": { + "version": "v4.2.2" + }, + "symfony/routing": { + "version": "4.2", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "master", + "version": "4.2", + "ref": "5374e24d508ba8fd6ba9eb15170255fdb778316a" + } + }, + "symfony/security-bundle": { + "version": "3.3", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "master", + "version": "3.3", + "ref": "f8a63faa0d9521526499c0a8f403c9964ecb0527" + } + }, + "symfony/security-core": { + "version": "v4.2.2" + }, + "symfony/security-csrf": { + "version": "v4.2.2" + }, + "symfony/security-guard": { + "version": "v4.2.2" + }, + "symfony/security-http": { + "version": "v4.2.2" + }, + "symfony/stopwatch": { + "version": "v4.2.2" + }, + "symfony/translation": { + "version": "3.3", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "master", + "version": "3.3", + "ref": "1fb02a6e1c8f3d4232cce485c9afa868d63b115a" + } + }, + "symfony/twig-bridge": { + "version": "v4.2.2" + }, + "symfony/twig-bundle": { + "version": "3.3", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "master", + "version": "3.3", + "ref": "369b5b29dc52b2c190002825ae7ec24ab6f962dd" + } + }, + "symfony/var-dumper": { + "version": "v4.2.2" + }, + "symfony/var-exporter": { + "version": "v4.2.2" + }, + "symfony/web-profiler-bundle": { + "version": "3.3", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "master", + "version": "3.3", + "ref": "6bdfa1a95f6b2e677ab985cd1af2eae35d62e0f6" + } + }, + "symfony/web-server-bundle": { + "version": "3.3", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "master", + "version": "3.3", + "ref": "dae9b39fd6717970be7601101ce5aa960bf53d9a" + } + }, + "symfony/yaml": { + "version": "v4.2.2" } } diff --git a/translations/.gitignore b/translations/.gitignore new file mode 100644 index 0000000..e69de29 From c9047ae0a95af63236d8b929eeb32d0a59f3e4f0 Mon Sep 17 00:00:00 2001 From: Alexey Skobkin Date: Sun, 20 Jan 2019 05:50:09 +0300 Subject: [PATCH 07/13] Deps reinstall. Refactoring. --- composer.json | 6 +- composer.lock | 538 ++++++++++++------------- config/bundles.php | 10 +- config/packages/dev/monolog.yaml | 34 +- config/packages/dev/orm_fixtures.yaml | 10 + config/packages/dev/web_profiler.yaml | 3 + config/packages/prod/monolog.yaml | 23 +- config/packages/test/monolog.yaml | 7 + config/packages/test/orm_fixtures.yaml | 10 + config/packages/test/web_profiler.yaml | 3 + config/routes/dev/web_profiles.yaml | 7 - src/DataFixtures/ORM/LoadLanguages.php | 69 +--- src/Entity/Language.php | 7 + symfony.lock | 27 ++ 14 files changed, 395 insertions(+), 359 deletions(-) create mode 100644 config/packages/dev/orm_fixtures.yaml create mode 100644 config/packages/test/monolog.yaml create mode 100644 config/packages/test/orm_fixtures.yaml delete mode 100644 config/routes/dev/web_profiles.yaml diff --git a/composer.json b/composer.json index 9d43bee..184d29b 100644 --- a/composer.json +++ b/composer.json @@ -17,18 +17,18 @@ "require": { "php": ">=7.1.0", "doctrine/annotations": "^1.3", - "doctrine/doctrine-bundle": "^1.4", "doctrine/doctrine-migrations-bundle": "^2.0", - "doctrine/orm": "^2.5", "sensio/framework-extra-bundle": "^5.2", "sentry/sentry-symfony": "^2.2", + "symfony/console": "^4.2", + "symfony/finder": "^4.2", "symfony/flex": "^1.1", "symfony/form": "^4.2", - "symfony/monolog-bundle": "^3.3", "symfony/orm-pack": "^1.0", "symfony/security-bundle": "^4.2", "symfony/translation": "^4.2", "symfony/twig-bundle": "^4.2", + "symfony/yaml": "^4.2", "theodordiaconu/geshi": "dev-master", "theodordiaconu/geshi-bundle": "dev-master" },"require-dev": { diff --git a/composer.lock b/composer.lock index a3b5910..ca20d29 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "3488c5d4756be564e9c5076a918bd373", + "content-hash": "12a1646d5d2aeff9249a996492e96c85", "packages": [ { "name": "doctrine/annotations", @@ -1291,84 +1291,6 @@ ], "time": "2018-06-13T13:22:40+00:00" }, - { - "name": "monolog/monolog", - "version": "1.24.0", - "source": { - "type": "git", - "url": "https://github.com/Seldaek/monolog.git", - "reference": "bfc9ebb28f97e7a24c45bdc3f0ff482e47bb0266" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Seldaek/monolog/zipball/bfc9ebb28f97e7a24c45bdc3f0ff482e47bb0266", - "reference": "bfc9ebb28f97e7a24c45bdc3f0ff482e47bb0266", - "shasum": "" - }, - "require": { - "php": ">=5.3.0", - "psr/log": "~1.0" - }, - "provide": { - "psr/log-implementation": "1.0.0" - }, - "require-dev": { - "aws/aws-sdk-php": "^2.4.9 || ^3.0", - "doctrine/couchdb": "~1.0@dev", - "graylog2/gelf-php": "~1.0", - "jakub-onderka/php-parallel-lint": "0.9", - "php-amqplib/php-amqplib": "~2.4", - "php-console/php-console": "^3.1.3", - "phpunit/phpunit": "~4.5", - "phpunit/phpunit-mock-objects": "2.3.0", - "ruflin/elastica": ">=0.90 <3.0", - "sentry/sentry": "^0.13", - "swiftmailer/swiftmailer": "^5.3|^6.0" - }, - "suggest": { - "aws/aws-sdk-php": "Allow sending log messages to AWS services like DynamoDB", - "doctrine/couchdb": "Allow sending log messages to a CouchDB server", - "ext-amqp": "Allow sending log messages to an AMQP server (1.0+ required)", - "ext-mongo": "Allow sending log messages to a MongoDB server", - "graylog2/gelf-php": "Allow sending log messages to a GrayLog2 server", - "mongodb/mongodb": "Allow sending log messages to a MongoDB server via PHP Driver", - "php-amqplib/php-amqplib": "Allow sending log messages to an AMQP server using php-amqplib", - "php-console/php-console": "Allow sending log messages to Google Chrome", - "rollbar/rollbar": "Allow sending log messages to Rollbar", - "ruflin/elastica": "Allow sending log messages to an Elastic Search server", - "sentry/sentry": "Allow sending log messages to a Sentry server" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Monolog\\": "src/Monolog" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jordi Boggiano", - "email": "j.boggiano@seld.be", - "homepage": "http://seld.be" - } - ], - "description": "Sends your logs to files, sockets, inboxes, databases and various web services", - "homepage": "http://github.com/Seldaek/monolog", - "keywords": [ - "log", - "logging", - "psr-3" - ], - "time": "2018-11-05T09:00:11+00:00" - }, { "name": "ocramius/package-versions", "version": "1.3.0", @@ -3063,137 +2985,6 @@ ], "time": "2019-01-05T16:37:49+00:00" }, - { - "name": "symfony/monolog-bridge", - "version": "v4.2.2", - "source": { - "type": "git", - "url": "https://github.com/symfony/monolog-bridge.git", - "reference": "8fa559511f1d215ca81e22f222d50eb029f93902" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/monolog-bridge/zipball/8fa559511f1d215ca81e22f222d50eb029f93902", - "reference": "8fa559511f1d215ca81e22f222d50eb029f93902", - "shasum": "" - }, - "require": { - "monolog/monolog": "~1.19", - "php": "^7.1.3", - "symfony/contracts": "^1.0", - "symfony/http-kernel": "~3.4|~4.0" - }, - "conflict": { - "symfony/console": "<3.4", - "symfony/http-foundation": "<3.4" - }, - "require-dev": { - "symfony/console": "~3.4|~4.0", - "symfony/event-dispatcher": "~3.4|~4.0", - "symfony/security-core": "~3.4|~4.0", - "symfony/var-dumper": "~3.4|~4.0" - }, - "suggest": { - "symfony/console": "For the possibility to show log messages in console commands depending on verbosity settings.", - "symfony/event-dispatcher": "Needed when using log messages in console commands.", - "symfony/http-kernel": "For using the debugging handlers together with the response life cycle of the HTTP kernel.", - "symfony/var-dumper": "For using the debugging handlers like the console handler or the log server handler." - }, - "type": "symfony-bridge", - "extra": { - "branch-alias": { - "dev-master": "4.2-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Bridge\\Monolog\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony Monolog Bridge", - "homepage": "https://symfony.com", - "time": "2019-01-03T09:07:35+00:00" - }, - { - "name": "symfony/monolog-bundle", - "version": "v3.3.1", - "source": { - "type": "git", - "url": "https://github.com/symfony/monolog-bundle.git", - "reference": "572e143afc03419a75ab002c80a2fd99299195ff" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/monolog-bundle/zipball/572e143afc03419a75ab002c80a2fd99299195ff", - "reference": "572e143afc03419a75ab002c80a2fd99299195ff", - "shasum": "" - }, - "require": { - "monolog/monolog": "~1.22", - "php": ">=5.6", - "symfony/config": "~2.7|~3.3|~4.0", - "symfony/dependency-injection": "~2.7|~3.4.10|^4.0.10", - "symfony/http-kernel": "~2.7|~3.3|~4.0", - "symfony/monolog-bridge": "~2.7|~3.3|~4.0" - }, - "require-dev": { - "symfony/console": "~2.7|~3.3|~4.0", - "symfony/phpunit-bridge": "^3.3|^4.0", - "symfony/yaml": "~2.7|~3.3|~4.0" - }, - "type": "symfony-bundle", - "extra": { - "branch-alias": { - "dev-master": "3.x-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Bundle\\MonologBundle\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Symfony Community", - "homepage": "http://symfony.com/contributors" - }, - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - } - ], - "description": "Symfony MonologBundle", - "homepage": "http://symfony.com", - "keywords": [ - "log", - "logging" - ], - "time": "2018-11-04T09:58:13+00:00" - }, { "name": "symfony/options-resolver", "version": "v4.2.2", @@ -4278,6 +4069,65 @@ ], "time": "2019-01-03T09:09:06+00:00" }, + { + "name": "symfony/yaml", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/yaml.git", + "reference": "d0aa6c0ea484087927b49fd513383a7d36190ca6" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/yaml/zipball/d0aa6c0ea484087927b49fd513383a7d36190ca6", + "reference": "d0aa6c0ea484087927b49fd513383a7d36190ca6", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/polyfill-ctype": "~1.8" + }, + "conflict": { + "symfony/console": "<3.4" + }, + "require-dev": { + "symfony/console": "~3.4|~4.0" + }, + "suggest": { + "symfony/console": "For validating YAML files using the lint command" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Yaml\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Yaml Component", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, { "name": "theodordiaconu/geshi", "version": "dev-master", @@ -4761,6 +4611,84 @@ ], "time": "2016-10-17T18:31:11+00:00" }, + { + "name": "monolog/monolog", + "version": "1.24.0", + "source": { + "type": "git", + "url": "https://github.com/Seldaek/monolog.git", + "reference": "bfc9ebb28f97e7a24c45bdc3f0ff482e47bb0266" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/Seldaek/monolog/zipball/bfc9ebb28f97e7a24c45bdc3f0ff482e47bb0266", + "reference": "bfc9ebb28f97e7a24c45bdc3f0ff482e47bb0266", + "shasum": "" + }, + "require": { + "php": ">=5.3.0", + "psr/log": "~1.0" + }, + "provide": { + "psr/log-implementation": "1.0.0" + }, + "require-dev": { + "aws/aws-sdk-php": "^2.4.9 || ^3.0", + "doctrine/couchdb": "~1.0@dev", + "graylog2/gelf-php": "~1.0", + "jakub-onderka/php-parallel-lint": "0.9", + "php-amqplib/php-amqplib": "~2.4", + "php-console/php-console": "^3.1.3", + "phpunit/phpunit": "~4.5", + "phpunit/phpunit-mock-objects": "2.3.0", + "ruflin/elastica": ">=0.90 <3.0", + "sentry/sentry": "^0.13", + "swiftmailer/swiftmailer": "^5.3|^6.0" + }, + "suggest": { + "aws/aws-sdk-php": "Allow sending log messages to AWS services like DynamoDB", + "doctrine/couchdb": "Allow sending log messages to a CouchDB server", + "ext-amqp": "Allow sending log messages to an AMQP server (1.0+ required)", + "ext-mongo": "Allow sending log messages to a MongoDB server", + "graylog2/gelf-php": "Allow sending log messages to a GrayLog2 server", + "mongodb/mongodb": "Allow sending log messages to a MongoDB server via PHP Driver", + "php-amqplib/php-amqplib": "Allow sending log messages to an AMQP server using php-amqplib", + "php-console/php-console": "Allow sending log messages to Google Chrome", + "rollbar/rollbar": "Allow sending log messages to Rollbar", + "ruflin/elastica": "Allow sending log messages to an Elastic Search server", + "sentry/sentry": "Allow sending log messages to a Sentry server" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Monolog\\": "src/Monolog" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http://seld.be" + } + ], + "description": "Sends your logs to files, sockets, inboxes, databases and various web services", + "homepage": "http://github.com/Seldaek/monolog", + "keywords": [ + "log", + "logging", + "psr-3" + ], + "time": "2018-11-05T09:00:11+00:00" + }, { "name": "paragonie/random_compat", "version": "v9.99.99", @@ -5008,6 +4936,137 @@ ], "time": "2019-01-03T09:07:35+00:00" }, + { + "name": "symfony/monolog-bridge", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/monolog-bridge.git", + "reference": "8fa559511f1d215ca81e22f222d50eb029f93902" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/monolog-bridge/zipball/8fa559511f1d215ca81e22f222d50eb029f93902", + "reference": "8fa559511f1d215ca81e22f222d50eb029f93902", + "shasum": "" + }, + "require": { + "monolog/monolog": "~1.19", + "php": "^7.1.3", + "symfony/contracts": "^1.0", + "symfony/http-kernel": "~3.4|~4.0" + }, + "conflict": { + "symfony/console": "<3.4", + "symfony/http-foundation": "<3.4" + }, + "require-dev": { + "symfony/console": "~3.4|~4.0", + "symfony/event-dispatcher": "~3.4|~4.0", + "symfony/security-core": "~3.4|~4.0", + "symfony/var-dumper": "~3.4|~4.0" + }, + "suggest": { + "symfony/console": "For the possibility to show log messages in console commands depending on verbosity settings.", + "symfony/event-dispatcher": "Needed when using log messages in console commands.", + "symfony/http-kernel": "For using the debugging handlers together with the response life cycle of the HTTP kernel.", + "symfony/var-dumper": "For using the debugging handlers like the console handler or the log server handler." + }, + "type": "symfony-bridge", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Bridge\\Monolog\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Monolog Bridge", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, + { + "name": "symfony/monolog-bundle", + "version": "v3.3.1", + "source": { + "type": "git", + "url": "https://github.com/symfony/monolog-bundle.git", + "reference": "572e143afc03419a75ab002c80a2fd99299195ff" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/monolog-bundle/zipball/572e143afc03419a75ab002c80a2fd99299195ff", + "reference": "572e143afc03419a75ab002c80a2fd99299195ff", + "shasum": "" + }, + "require": { + "monolog/monolog": "~1.22", + "php": ">=5.6", + "symfony/config": "~2.7|~3.3|~4.0", + "symfony/dependency-injection": "~2.7|~3.4.10|^4.0.10", + "symfony/http-kernel": "~2.7|~3.3|~4.0", + "symfony/monolog-bridge": "~2.7|~3.3|~4.0" + }, + "require-dev": { + "symfony/console": "~2.7|~3.3|~4.0", + "symfony/phpunit-bridge": "^3.3|^4.0", + "symfony/yaml": "~2.7|~3.3|~4.0" + }, + "type": "symfony-bundle", + "extra": { + "branch-alias": { + "dev-master": "3.x-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Bundle\\MonologBundle\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Symfony Community", + "homepage": "http://symfony.com/contributors" + }, + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + } + ], + "description": "Symfony MonologBundle", + "homepage": "http://symfony.com", + "keywords": [ + "log", + "logging" + ], + "time": "2018-11-04T09:58:13+00:00" + }, { "name": "symfony/polyfill-php72", "version": "v1.10.0", @@ -5340,65 +5399,6 @@ "description": "Symfony WebServerBundle", "homepage": "https://symfony.com", "time": "2019-01-03T09:07:35+00:00" - }, - { - "name": "symfony/yaml", - "version": "v4.2.2", - "source": { - "type": "git", - "url": "https://github.com/symfony/yaml.git", - "reference": "d0aa6c0ea484087927b49fd513383a7d36190ca6" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/yaml/zipball/d0aa6c0ea484087927b49fd513383a7d36190ca6", - "reference": "d0aa6c0ea484087927b49fd513383a7d36190ca6", - "shasum": "" - }, - "require": { - "php": "^7.1.3", - "symfony/polyfill-ctype": "~1.8" - }, - "conflict": { - "symfony/console": "<3.4" - }, - "require-dev": { - "symfony/console": "~3.4|~4.0" - }, - "suggest": { - "symfony/console": "For validating YAML files using the lint command" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "4.2-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Component\\Yaml\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony Yaml Component", - "homepage": "https://symfony.com", - "time": "2019-01-03T09:07:35+00:00" } ], "aliases": [], diff --git a/config/bundles.php b/config/bundles.php index 97c1560..d271724 100644 --- a/config/bundles.php +++ b/config/bundles.php @@ -4,14 +4,14 @@ return [ Symfony\Bundle\FrameworkBundle\FrameworkBundle::class => ['all' => true], Symfony\Bundle\SecurityBundle\SecurityBundle::class => ['all' => true], Symfony\Bundle\TwigBundle\TwigBundle::class => ['all' => true], - Symfony\Bundle\MonologBundle\MonologBundle::class => ['all' => true], Doctrine\Bundle\DoctrineBundle\DoctrineBundle::class => ['all' => true], Doctrine\Bundle\MigrationsBundle\DoctrineMigrationsBundle::class => ['all' => true], - Doctrine\Bundle\FixturesBundle\DoctrineFixturesBundle::class => ['all' => true], Sensio\Bundle\FrameworkExtraBundle\SensioFrameworkExtraBundle::class => ['all' => true], DT\Bundle\GeshiBundle\DTGeshiBundle::class => ['all' => true], Sentry\SentryBundle\SentryBundle::class => ['all' => true], - Symfony\Bundle\DebugBundle\DebugBundle::class => ['dev' => true, 'test' => true], Symfony\Bundle\WebProfilerBundle\WebProfilerBundle::class => ['dev' => true, 'test' => true], - Symfony\Bundle\WebServerBundle\WebServerBundle::class => ['dev' => true, 'test' => true], -]; \ No newline at end of file + Symfony\Bundle\MonologBundle\MonologBundle::class => ['all' => true], + Symfony\Bundle\DebugBundle\DebugBundle::class => ['dev' => true, 'test' => true], + Symfony\Bundle\WebServerBundle\WebServerBundle::class => ['dev' => true], + Doctrine\Bundle\FixturesBundle\DoctrineFixturesBundle::class => ['dev' => true, 'test' => true], +]; diff --git a/config/packages/dev/monolog.yaml b/config/packages/dev/monolog.yaml index 479f837..b1998da 100644 --- a/config/packages/dev/monolog.yaml +++ b/config/packages/dev/monolog.yaml @@ -1,29 +1,19 @@ monolog: handlers: main: - type: stream - path: "%kernel.logs_dir%/%kernel.environment%.log" - level: debug - console: - type: console - bubble: false - verbosity_levels: - VERBOSITY_VERBOSE: INFO - VERBOSITY_VERY_VERBOSE: DEBUG - channels: ["!doctrine"] - console_very_verbose: - type: console - bubble: false - verbosity_levels: - VERBOSITY_VERBOSE: NOTICE - VERBOSITY_VERY_VERBOSE: NOTICE - VERBOSITY_DEBUG: DEBUG - channels: ["doctrine"] + type: stream + path: "%kernel.logs_dir%/%kernel.environment%.log" + level: debug + channels: ["!event"] # uncomment to get logging in your browser # you may have to allow bigger header sizes in your Web server configuration #firephp: - # type: firephp - # level: info + # type: firephp + # level: info #chromephp: - # type: chromephp - # level: info + # type: chromephp + # level: info + console: + type: console + process_psr_3_messages: false + channels: ["!event", "!doctrine", "!console"] diff --git a/config/packages/dev/orm_fixtures.yaml b/config/packages/dev/orm_fixtures.yaml new file mode 100644 index 0000000..44870a5 --- /dev/null +++ b/config/packages/dev/orm_fixtures.yaml @@ -0,0 +1,10 @@ +# src/AppBundle/Resources/config/dataFixture.yml +services: + _defaults: + tags: ['doctrine.fixture.orm'] + autowire: true # if you need dependency injection, see next bullet point + bind: + $projectDir: '%kernel.project_dir%' + + App\DataFixtures\ORM\: + resource: '%kernel.project_dir%/src/DataFixtures/ORM/*' \ No newline at end of file diff --git a/config/packages/dev/web_profiler.yaml b/config/packages/dev/web_profiler.yaml index 1f1cb2b..e92166a 100644 --- a/config/packages/dev/web_profiler.yaml +++ b/config/packages/dev/web_profiler.yaml @@ -1,3 +1,6 @@ web_profiler: toolbar: true intercept_redirects: false + +framework: + profiler: { only_exceptions: false } diff --git a/config/packages/prod/monolog.yaml b/config/packages/prod/monolog.yaml index 25f2c67..96dbf96 100644 --- a/config/packages/prod/monolog.yaml +++ b/config/packages/prod/monolog.yaml @@ -1,12 +1,25 @@ monolog: handlers: main: - type: fingers_crossed + type: fingers_crossed action_level: error - handler: nested + handler: nested + excluded_404s: + # regex: exclude all 404 errors from the logs + - ^/ nested: - type: stream - path: "%kernel.logs_dir%/%kernel.environment%.log" + type: stream + path: "%kernel.logs_dir%/%kernel.environment%.log" level: debug console: - type: console + type: console + process_psr_3_messages: false + channels: ["!event", "!doctrine"] + deprecation: + type: stream + path: "%kernel.logs_dir%/%kernel.environment%.deprecations.log" + deprecation_filter: + type: filter + handler: deprecation + max_level: info + channels: ["php"] diff --git a/config/packages/test/monolog.yaml b/config/packages/test/monolog.yaml new file mode 100644 index 0000000..2762653 --- /dev/null +++ b/config/packages/test/monolog.yaml @@ -0,0 +1,7 @@ +monolog: + handlers: + main: + type: stream + path: "%kernel.logs_dir%/%kernel.environment%.log" + level: debug + channels: ["!event"] diff --git a/config/packages/test/orm_fixtures.yaml b/config/packages/test/orm_fixtures.yaml new file mode 100644 index 0000000..44870a5 --- /dev/null +++ b/config/packages/test/orm_fixtures.yaml @@ -0,0 +1,10 @@ +# src/AppBundle/Resources/config/dataFixture.yml +services: + _defaults: + tags: ['doctrine.fixture.orm'] + autowire: true # if you need dependency injection, see next bullet point + bind: + $projectDir: '%kernel.project_dir%' + + App\DataFixtures\ORM\: + resource: '%kernel.project_dir%/src/DataFixtures/ORM/*' \ No newline at end of file diff --git a/config/packages/test/web_profiler.yaml b/config/packages/test/web_profiler.yaml index 85319b4..03752de 100644 --- a/config/packages/test/web_profiler.yaml +++ b/config/packages/test/web_profiler.yaml @@ -1,3 +1,6 @@ web_profiler: toolbar: false intercept_redirects: false + +framework: + profiler: { collect: false } diff --git a/config/routes/dev/web_profiles.yaml b/config/routes/dev/web_profiles.yaml deleted file mode 100644 index c82beff..0000000 --- a/config/routes/dev/web_profiles.yaml +++ /dev/null @@ -1,7 +0,0 @@ -web_profiler_wdt: - resource: '@WebProfilerBundle/Resources/config/routing/wdt.xml' - prefix: /_wdt - -web_profiler_profiler: - resource: '@WebProfilerBundle/Resources/config/routing/profiler.xml' - prefix: /_profiler diff --git a/src/DataFixtures/ORM/LoadLanguages.php b/src/DataFixtures/ORM/LoadLanguages.php index a23bc3a..03a4e5c 100644 --- a/src/DataFixtures/ORM/LoadLanguages.php +++ b/src/DataFixtures/ORM/LoadLanguages.php @@ -2,48 +2,28 @@ namespace App\DataFixtures\ORM; -use Doctrine\Common\DataFixtures\FixtureInterface; +use Doctrine\Bundle\FixturesBundle\Fixture; use Doctrine\Common\Persistence\ObjectManager; -use Doctrine\ORM\Query; -use Symfony\Component\DependencyInjection\ContainerAwareInterface; -use Symfony\Component\DependencyInjection\ContainerInterface; -use Symfony\Component\Console\Output\ConsoleOutput; use Symfony\Component\Finder\Finder; -use Symfony\Component\Finder\SplFileInfo; use App\Entity\Language; -/** - * Description of LoadLanguages - * - * @author Alexey Skobkin - */ -class LoadLanguages implements FixtureInterface, ContainerAwareInterface +class LoadLanguages extends Fixture { - /** - * @var ContainerInterface - */ - private $container; - - /** - * {@inheritDoc} - */ - public function setContainer(ContainerInterface $container = null) + /** @var string */ + private $projectDir; + + public function __construct(string $projectDir) { - $this->container = $container; + $this->projectDir = $projectDir; } - - /** - * {@inheritDoc} - */ + public function load(ObjectManager $manager) { - $output = new ConsoleOutput(); - - $geshiPath = $this->container->get('kernel')->getRootDir() . '/../vendor/theodordiaconu/geshi/src/GeSHi/geshi'; - + $geshiPath = $this->projectDir.'/vendor/theodordiaconu/geshi/src/GeSHi/geshi'; + $finder = new Finder(); $finder->files()->in($geshiPath); - + // Fix constants define('GESHI_CAPS_NO_CHANGE', true); define('GESHI_COMMENTS', true); @@ -73,26 +53,19 @@ class LoadLanguages implements FixtureInterface, ContainerAwareInterface define('GESHI_CLASS', true); define('GESHI_NUMBER_OCT_PREFIX_0O', true); define('GESHI_NUMBER_OCT_PREFIX_AT', true); - - /* @var $file SplFileInfo */ + + /* @var $file \SplFileInfo */ foreach ($finder as $file) { - $output->writeln($file->getRelativePathname() . ' found. Parsing...'); - include $geshiPath.DIRECTORY_SEPARATOR.$file->getRelativePathname(); - - $language = new Language(); - $language - ->setName($language_data['LANG_NAME']) - ->setCode(basename($file->getRelativePathname(), '.php')) - ->setIsEnabled(true) - ; - - $output->write('---> "' . $language->getName() . '"'); + + $language = new Language( + $language_data['LANG_NAME'], + basename($file->getRelativePathname(), '.php') + ); + $manager->persist($language); - $manager->flush(); - $output->writeln(' [ PERSISTED ]'); } - - $output->writeln('Import finished!'); + + $manager->flush(); } } diff --git a/src/Entity/Language.php b/src/Entity/Language.php index 41597a9..2a96541 100644 --- a/src/Entity/Language.php +++ b/src/Entity/Language.php @@ -51,6 +51,13 @@ class Language */ private $isEnabled; + public function __construct(string $name, string $code, bool $enabled = true) + { + $this->name = $name; + $this->code = $code; + $this->isEnabled = $enabled; + } + public function getId(): int { return $this->id; diff --git a/symfony.lock b/symfony.lock index 8249f62..e5cd7a9 100644 --- a/symfony.lock +++ b/symfony.lock @@ -1,4 +1,16 @@ { + "doctrine/data-fixtures": { + "version": "v1.3.1" + }, + "doctrine/doctrine-fixtures-bundle": { + "version": "3.0", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "master", + "version": "3.0", + "ref": "fc52d86631a6dfd9fdf3381d0b7e3df2069e51b3" + } + }, "easycorp/easy-log-handler": { "version": "1.0", "recipe": { @@ -8,6 +20,9 @@ "ref": "70062abc2cd58794d2a90274502f81b55cd9951b" } }, + "monolog/monolog": { + "version": "1.24.0" + }, "symfony/cache": { "version": "v4.2.2" }, @@ -92,12 +107,24 @@ "symfony/monolog-bridge": { "version": "v4.2.2" }, + "symfony/monolog-bundle": { + "version": "3.1", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "master", + "version": "3.1", + "ref": "18ebf5a940573a20de06f9c4060101eeb438cf3d" + } + }, "symfony/options-resolver": { "version": "v4.2.2" }, "symfony/orm-pack": { "version": "v1.0.6" }, + "symfony/polyfill-php72": { + "version": "v1.10.0" + }, "symfony/process": { "version": "v4.2.2" }, From 713099333c32ae28c6925243afba15fc761928d2 Mon Sep 17 00:00:00 2001 From: Alexey Skobkin Date: Sun, 20 Jan 2019 05:55:58 +0300 Subject: [PATCH 08/13] More deps reinstall. --- config/bundles.php | 3 +- config/packages/prod/doctrine.yaml | 32 +++++ config/packages/sensio_framework_extra.yaml | 2 +- config/routes/annotations.yaml | 3 + src/Entity/.gitignore | 0 src/Migrations/.gitignore | 0 src/Repository/.gitignore | 0 symfony.lock | 144 ++++++++++++++++++++ 8 files changed, 182 insertions(+), 2 deletions(-) create mode 100644 config/packages/prod/doctrine.yaml create mode 100644 config/routes/annotations.yaml create mode 100644 src/Entity/.gitignore create mode 100644 src/Migrations/.gitignore create mode 100644 src/Repository/.gitignore diff --git a/config/bundles.php b/config/bundles.php index d271724..1bff153 100644 --- a/config/bundles.php +++ b/config/bundles.php @@ -6,7 +6,6 @@ return [ Symfony\Bundle\TwigBundle\TwigBundle::class => ['all' => true], Doctrine\Bundle\DoctrineBundle\DoctrineBundle::class => ['all' => true], Doctrine\Bundle\MigrationsBundle\DoctrineMigrationsBundle::class => ['all' => true], - Sensio\Bundle\FrameworkExtraBundle\SensioFrameworkExtraBundle::class => ['all' => true], DT\Bundle\GeshiBundle\DTGeshiBundle::class => ['all' => true], Sentry\SentryBundle\SentryBundle::class => ['all' => true], Symfony\Bundle\WebProfilerBundle\WebProfilerBundle::class => ['dev' => true, 'test' => true], @@ -14,4 +13,6 @@ return [ Symfony\Bundle\DebugBundle\DebugBundle::class => ['dev' => true, 'test' => true], Symfony\Bundle\WebServerBundle\WebServerBundle::class => ['dev' => true], Doctrine\Bundle\FixturesBundle\DoctrineFixturesBundle::class => ['dev' => true, 'test' => true], + Doctrine\Bundle\DoctrineCacheBundle\DoctrineCacheBundle::class => ['all' => true], + Sensio\Bundle\FrameworkExtraBundle\SensioFrameworkExtraBundle::class => ['all' => true], ]; diff --git a/config/packages/prod/doctrine.yaml b/config/packages/prod/doctrine.yaml new file mode 100644 index 0000000..0a7c53b --- /dev/null +++ b/config/packages/prod/doctrine.yaml @@ -0,0 +1,32 @@ +doctrine: + orm: + auto_generate_proxy_classes: false + metadata_cache_driver: + type: service + id: doctrine.system_cache_provider + query_cache_driver: + type: service + id: doctrine.system_cache_provider + result_cache_driver: + type: service + id: doctrine.result_cache_provider + +services: + doctrine.result_cache_provider: + class: Symfony\Component\Cache\DoctrineProvider + public: false + arguments: + - '@doctrine.result_cache_pool' + doctrine.system_cache_provider: + class: Symfony\Component\Cache\DoctrineProvider + public: false + arguments: + - '@doctrine.system_cache_pool' + +framework: + cache: + pools: + doctrine.result_cache_pool: + adapter: cache.app + doctrine.system_cache_pool: + adapter: cache.system diff --git a/config/packages/sensio_framework_extra.yaml b/config/packages/sensio_framework_extra.yaml index 20e5cf3..1821ccc 100644 --- a/config/packages/sensio_framework_extra.yaml +++ b/config/packages/sensio_framework_extra.yaml @@ -1,3 +1,3 @@ sensio_framework_extra: router: - annotations: false \ No newline at end of file + annotations: false diff --git a/config/routes/annotations.yaml b/config/routes/annotations.yaml new file mode 100644 index 0000000..89e306b --- /dev/null +++ b/config/routes/annotations.yaml @@ -0,0 +1,3 @@ +#controllers: +# resource: ../../src/Controller/ +# type: annotation diff --git a/src/Entity/.gitignore b/src/Entity/.gitignore new file mode 100644 index 0000000..e69de29 diff --git a/src/Migrations/.gitignore b/src/Migrations/.gitignore new file mode 100644 index 0000000..e69de29 diff --git a/src/Repository/.gitignore b/src/Repository/.gitignore new file mode 100644 index 0000000..e69de29 diff --git a/symfony.lock b/symfony.lock index e5cd7a9..a709f77 100644 --- a/symfony.lock +++ b/symfony.lock @@ -1,7 +1,40 @@ { + "doctrine/annotations": { + "version": "1.0", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "master", + "version": "1.0", + "ref": "cb4152ebcadbe620ea2261da1a1c5a9b8cea7672" + } + }, + "doctrine/cache": { + "version": "v1.8.0" + }, + "doctrine/collections": { + "version": "v1.5.0" + }, + "doctrine/common": { + "version": "v2.10.0" + }, "doctrine/data-fixtures": { "version": "v1.3.1" }, + "doctrine/dbal": { + "version": "v2.9.2" + }, + "doctrine/doctrine-bundle": { + "version": "1.6", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "master", + "version": "1.6", + "ref": "453e89b78ded666f351617baca5ae40d20622351" + } + }, + "doctrine/doctrine-cache-bundle": { + "version": "1.3.5" + }, "doctrine/doctrine-fixtures-bundle": { "version": "3.0", "recipe": { @@ -11,6 +44,39 @@ "ref": "fc52d86631a6dfd9fdf3381d0b7e3df2069e51b3" } }, + "doctrine/doctrine-migrations-bundle": { + "version": "1.2", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "master", + "version": "1.2", + "ref": "c1431086fec31f17fbcfe6d6d7e92059458facc1" + } + }, + "doctrine/event-manager": { + "version": "v1.0.0" + }, + "doctrine/inflector": { + "version": "v1.3.0" + }, + "doctrine/instantiator": { + "version": "1.1.0" + }, + "doctrine/lexer": { + "version": "v1.0.1" + }, + "doctrine/migrations": { + "version": "v2.0.0" + }, + "doctrine/orm": { + "version": "v2.6.3" + }, + "doctrine/persistence": { + "version": "v1.1.0" + }, + "doctrine/reflection": { + "version": "v1.0.0" + }, "easycorp/easy-log-handler": { "version": "1.0", "recipe": { @@ -20,9 +86,60 @@ "ref": "70062abc2cd58794d2a90274502f81b55cd9951b" } }, + "fig/link-util": { + "version": "1.0.0" + }, + "jdorn/sql-formatter": { + "version": "v1.2.17" + }, + "jean85/pretty-package-versions": { + "version": "1.2" + }, "monolog/monolog": { "version": "1.24.0" }, + "ocramius/proxy-manager": { + "version": "2.2.2" + }, + "paragonie/random_compat": { + "version": "v9.99.99" + }, + "psr/cache": { + "version": "1.0.1" + }, + "psr/container": { + "version": "1.0.0" + }, + "psr/link": { + "version": "1.0.0" + }, + "psr/log": { + "version": "1.1.0" + }, + "psr/simple-cache": { + "version": "1.0.1" + }, + "sensio/framework-extra-bundle": { + "version": "5.2", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "master", + "version": "5.2", + "ref": "fb7e19da7f013d0d422fa9bce16f5c510e27609b" + } + }, + "sentry/sentry": { + "version": "1.10.0" + }, + "sentry/sentry-symfony": { + "version": "1.0", + "recipe": { + "repo": "github.com/symfony/recipes-contrib", + "branch": "master", + "version": "1.0", + "ref": "fa1a2dfc020798cd7076b5419596e72dca07047a" + } + }, "symfony/cache": { "version": "v4.2.2" }, @@ -38,6 +155,9 @@ "ref": "0fa049c19069a65f52c1c181d64be3de672c1504" } }, + "symfony/contracts": { + "version": "v1.0.2" + }, "symfony/debug": { "version": "v4.2.2" }, @@ -122,6 +242,15 @@ "symfony/orm-pack": { "version": "v1.0.6" }, + "symfony/polyfill-ctype": { + "version": "v1.10.0" + }, + "symfony/polyfill-intl-icu": { + "version": "v1.10.0" + }, + "symfony/polyfill-mbstring": { + "version": "v1.10.0" + }, "symfony/polyfill-php72": { "version": "v1.10.0" }, @@ -214,5 +343,20 @@ }, "symfony/yaml": { "version": "v4.2.2" + }, + "theodordiaconu/geshi": { + "version": "dev-master" + }, + "theodordiaconu/geshi-bundle": { + "version": "dev-master" + }, + "twig/twig": { + "version": "v2.6.2" + }, + "zendframework/zend-code": { + "version": "3.3.1" + }, + "zendframework/zend-eventmanager": { + "version": "3.2.1" } } From 969fea6eb36af5042347d9433f88ba985e4f5fa4 Mon Sep 17 00:00:00 2001 From: Alexey Skobkin Date: Sun, 20 Jan 2019 07:11:30 +0300 Subject: [PATCH 09/13] Refactoring for symfony/flex. It finally works. --- composer.json | 1 + composer.lock | 91 ++++++++++++++++++- config/packages/doctrine.yaml | 8 ++ config/packages/test/doctrine.yaml | 11 +-- config/packages/validator.yaml | 3 + config/routes.yaml | 8 +- config/services.yaml | 4 + public/index.php | 40 +++++--- src/Command/DropExpiredPasteCommand.php | 4 +- src/Controller/PasteController.php | 23 +++-- src/Entity/{Copypaste.php => Paste.php} | 8 +- src/Form/FakeCaptchaType.php | 5 - src/Form/{CopypasteType.php => PasteType.php} | 16 +--- symfony.lock | 9 ++ templates/Form/fields.html.twig | 2 +- templates/base.html.twig | 4 +- templates/layout.html.twig | 2 +- 17 files changed, 173 insertions(+), 66 deletions(-) create mode 100644 config/packages/validator.yaml rename src/Entity/{Copypaste.php => Paste.php} (97%) rename src/Form/{CopypasteType.php => PasteType.php} (85%) diff --git a/composer.json b/composer.json index 184d29b..093497a 100644 --- a/composer.json +++ b/composer.json @@ -28,6 +28,7 @@ "symfony/security-bundle": "^4.2", "symfony/translation": "^4.2", "symfony/twig-bundle": "^4.2", + "symfony/validator": "^4.2", "symfony/yaml": "^4.2", "theodordiaconu/geshi": "dev-master", "theodordiaconu/geshi-bundle": "dev-master" diff --git a/composer.lock b/composer.lock index ca20d29..26f68ec 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "12a1646d5d2aeff9249a996492e96c85", + "content-hash": "b2efcf2213eb068842d3ad2b85667014", "packages": [ { "name": "doctrine/annotations", @@ -4009,6 +4009,95 @@ "homepage": "https://symfony.com", "time": "2019-01-03T09:07:35+00:00" }, + { + "name": "symfony/validator", + "version": "v4.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/validator.git", + "reference": "f89d2fab883a6a20d0d0093537392763cf52f0ba" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/validator/zipball/f89d2fab883a6a20d0d0093537392763cf52f0ba", + "reference": "f89d2fab883a6a20d0d0093537392763cf52f0ba", + "shasum": "" + }, + "require": { + "php": "^7.1.3", + "symfony/contracts": "^1.0.2", + "symfony/polyfill-ctype": "~1.8", + "symfony/polyfill-mbstring": "~1.0" + }, + "conflict": { + "phpunit/phpunit": "<4.8.35|<5.4.3,>=5.0", + "symfony/dependency-injection": "<3.4", + "symfony/http-kernel": "<3.4", + "symfony/intl": "<4.1", + "symfony/translation": "<4.2", + "symfony/yaml": "<3.4" + }, + "require-dev": { + "doctrine/annotations": "~1.0", + "doctrine/cache": "~1.0", + "egulias/email-validator": "^1.2.8|~2.0", + "symfony/cache": "~3.4|~4.0", + "symfony/config": "~3.4|~4.0", + "symfony/dependency-injection": "~3.4|~4.0", + "symfony/expression-language": "~3.4|~4.0", + "symfony/http-foundation": "~4.1", + "symfony/http-kernel": "~3.4|~4.0", + "symfony/intl": "~4.1", + "symfony/property-access": "~3.4|~4.0", + "symfony/translation": "~4.2", + "symfony/var-dumper": "~3.4|~4.0", + "symfony/yaml": "~3.4|~4.0" + }, + "suggest": { + "doctrine/annotations": "For using the annotation mapping. You will also need doctrine/cache.", + "doctrine/cache": "For using the default cached annotation reader and metadata cache.", + "egulias/email-validator": "Strict (RFC compliant) email validation", + "psr/cache-implementation": "For using the metadata cache.", + "symfony/config": "", + "symfony/expression-language": "For using the Expression validator", + "symfony/http-foundation": "", + "symfony/intl": "", + "symfony/property-access": "For accessing properties within comparison constraints", + "symfony/translation": "For translating validation errors.", + "symfony/yaml": "" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Validator\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Validator Component", + "homepage": "https://symfony.com", + "time": "2019-01-06T14:13:54+00:00" + }, { "name": "symfony/var-exporter", "version": "v4.2.2", diff --git a/config/packages/doctrine.yaml b/config/packages/doctrine.yaml index a0e7da7..242d78b 100644 --- a/config/packages/doctrine.yaml +++ b/config/packages/doctrine.yaml @@ -8,3 +8,11 @@ doctrine: charset: 'UTF8' orm: auto_generate_proxy_classes: "%kernel.debug%" + auto_mapping: true + mappings: + App\Entity: + type: annotation + dir: '%kernel.project_dir%/src/Entity' + is_bundle: false + prefix: App\Entity + alias: App diff --git a/config/packages/test/doctrine.yaml b/config/packages/test/doctrine.yaml index 4b2ec5d..a4013b4 100644 --- a/config/packages/test/doctrine.yaml +++ b/config/packages/test/doctrine.yaml @@ -1,6 +1,5 @@ -doctrine: - dbal: - dbname: "%test_database_name%" - port: "%test_database_port%" - user: "%test_database_user%" - password: "%test_database_password%" +#doctrine: +# dbal: +# driver: 'mysqli' +# url: '%env(resolve:DATABASE_URL)%' +# charset: 'UTF8' diff --git a/config/packages/validator.yaml b/config/packages/validator.yaml new file mode 100644 index 0000000..a695e1a --- /dev/null +++ b/config/packages/validator.yaml @@ -0,0 +1,3 @@ +framework: + validation: + email_validation_mode: html5 diff --git a/config/routes.yaml b/config/routes.yaml index 49e4ce1..39fb7dd 100644 --- a/config/routes.yaml +++ b/config/routes.yaml @@ -1,3 +1,7 @@ +paste_new: + path: / + defaults: { _controller: 'App\Controller\PasteController::newAction' } + paste_show_public: path: /{id} defaults: { _controller: 'App\Controller\PasteController::showAction', secret: null } @@ -11,10 +15,6 @@ paste_show_private: id: \d+ secret: \w{16} -paste_new: - path: / - defaults: { _controller: 'App\Controller\PasteController::newAction' } - paste_create: path: /create defaults: { _controller: 'App\Controller\PasteController::createAction' } diff --git a/config/services.yaml b/config/services.yaml index fe6be92..6678f6d 100644 --- a/config/services.yaml +++ b/config/services.yaml @@ -22,3 +22,7 @@ services: App\Controller\: resource: '../src/Controller' tags: ['controller.service_arguments'] + + # Overriding old bundle service definition + DT\Bundle\GeshiBundle\Highlighter\HighlighterInterface: + class: DT\Bundle\GeshiBundle\Highlighter\GeshiHighlighter diff --git a/public/index.php b/public/index.php index c52f821..e30f90c 100644 --- a/public/index.php +++ b/public/index.php @@ -1,17 +1,27 @@ =1.2) -if (is_array($env = @include dirname(__DIR__).'/.env.local.php')) { - $_SERVER += $env; - $_ENV += $env; -} elseif (!class_exists(Dotenv::class)) { - throw new RuntimeException('Please run "composer require symfony/dotenv" to load the ".env" files configuring the application.'); -} else { - // load all the .env files - (new Dotenv())->loadEnv(dirname(__DIR__).'/.env'); + +use App\Kernel; +use Symfony\Component\Debug\Debug; +use Symfony\Component\HttpFoundation\Request; + +require dirname(__DIR__).'/config/bootstrap.php'; + +if ($_SERVER['APP_DEBUG']) { + umask(0000); + + Debug::enable(); } -$_SERVER['APP_ENV'] = $_ENV['APP_ENV'] = ($_SERVER['APP_ENV'] ?? $_ENV['APP_ENV'] ?? null) ?: 'dev'; -$_SERVER['APP_DEBUG'] = $_SERVER['APP_DEBUG'] ?? $_ENV['APP_DEBUG'] ?? 'prod' !== $_SERVER['APP_ENV']; -$_SERVER['APP_DEBUG'] = $_ENV['APP_DEBUG'] = (int) $_SERVER['APP_DEBUG'] || filter_var($_SERVER['APP_DEBUG'], FILTER_VALIDATE_BOOLEAN) ? '1' : '0'; + +if ($trustedProxies = $_SERVER['TRUSTED_PROXIES'] ?? $_ENV['TRUSTED_PROXIES'] ?? false) { + Request::setTrustedProxies(explode(',', $trustedProxies), Request::HEADER_X_FORWARDED_ALL ^ Request::HEADER_X_FORWARDED_HOST); +} + +if ($trustedHosts = $_SERVER['TRUSTED_HOSTS'] ?? $_ENV['TRUSTED_HOSTS'] ?? false) { + Request::setTrustedHosts([$trustedHosts]); +} + +$kernel = new Kernel($_SERVER['APP_ENV'], (bool) $_SERVER['APP_DEBUG']); +$request = Request::createFromGlobals(); +$response = $kernel->handle($request); +$response->send(); +$kernel->terminate($request, $response); diff --git a/src/Command/DropExpiredPasteCommand.php b/src/Command/DropExpiredPasteCommand.php index 91c5db9..de28607 100644 --- a/src/Command/DropExpiredPasteCommand.php +++ b/src/Command/DropExpiredPasteCommand.php @@ -3,7 +3,7 @@ namespace App\Command; use Doctrine\ORM\EntityManagerInterface; -use App\Entity\Copypaste; +use App\Entity\Paste; use Symfony\Component\Console\Command\Command; use Symfony\Component\Console\Input\InputInterface; use Symfony\Component\Console\Output\OutputInterface; @@ -39,7 +39,7 @@ class DropExpiredPasteCommand extends Command // @todo move to repository $qb = $this->em->createQueryBuilder() - ->delete(Copypaste::class, 'c') + ->delete(Paste::class, 'c') ->where('c.dateExpire < :now') ->andWhere('c.dateExpire IS NOT NULL') ->setParameter('now', new \DateTime()); diff --git a/src/Controller/PasteController.php b/src/Controller/PasteController.php index 6d90231..9712f88 100644 --- a/src/Controller/PasteController.php +++ b/src/Controller/PasteController.php @@ -2,20 +2,21 @@ namespace App\Controller; +use Doctrine\ORM\EntityManagerInterface; use DT\Bundle\GeshiBundle\Highlighter\HighlighterInterface; use Symfony\Bundle\FrameworkBundle\Controller\AbstractController; use Symfony\Component\Form\Extension\Core\Type\SubmitType; use Symfony\Component\Form\FormInterface; use Symfony\Component\HttpFoundation\{Request, Response}; -use App\Entity\Copypaste; -use App\Form\CopypasteType; +use App\Entity\Paste; +use App\Form\PasteType; use \GeSHi\GeSHi; class PasteController extends AbstractController { public function createAction(Request $request): Response { - $paste = new Copypaste(); + $paste = new Paste(); $form = $this->createCreateForm($paste); $form->handleRequest($request); @@ -58,7 +59,7 @@ class PasteController extends AbstractController public function newAction(): Response { - $paste = new Copypaste(); + $paste = new Paste(); $createForm = $this->createCreateForm($paste); return $this->render('Paste/new.html.twig', [ @@ -67,12 +68,10 @@ class PasteController extends AbstractController ]); } - public function showAction(int $id, ?string $secret, HighlighterInterface $highlighter): Response + public function showAction(int $id, ?string $secret, EntityManagerInterface $em, HighlighterInterface $highlighter): Response { - $em = $this->getDoctrine()->getManager(); - - /* @var $paste \App\Entity\Copypaste */ - $paste = $em->getRepository(Copypaste::class)->findOneBy([ + /* @var $paste \App\Entity\Paste */ + $paste = $em->getRepository(Paste::class)->findOneBy([ 'id' =>$id, 'secret' => $secret ]); @@ -99,7 +98,7 @@ class PasteController extends AbstractController { $em = $this->getDoctrine()->getManager(); - $pastes = $em->getRepository(Copypaste::class)->findBy( + $pastes = $em->getRepository(Paste::class)->findBy( ['secret' => null], ['id' => 'DESC'], // @todo move to the config @@ -109,9 +108,9 @@ class PasteController extends AbstractController return $this->render('sidebar.html.twig', ['pastes' => $pastes]); } - private function createCreateForm(Copypaste $entity): FormInterface + private function createCreateForm(Paste $entity): FormInterface { - $form = $this->createForm(CopypasteType::class, $entity, [ + $form = $this->createForm(PasteType::class, $entity, [ 'action' => $this->generateUrl('paste_create'), 'method' => 'POST', ]); diff --git a/src/Entity/Copypaste.php b/src/Entity/Paste.php similarity index 97% rename from src/Entity/Copypaste.php rename to src/Entity/Paste.php index 5e65fb6..b2b8ebd 100644 --- a/src/Entity/Copypaste.php +++ b/src/Entity/Paste.php @@ -6,14 +6,12 @@ use Doctrine\ORM\Mapping as ORM; use Symfony\Component\Validator\Constraints as Assert; /** - * Copypaste - * * @ORM\Table(name="copypastes", indexes={ * @ORM\Index(name="idx_expire", columns={"date_expire"}) * }) * @ORM\Entity */ -class Copypaste +class Paste { /** * @var integer @@ -111,7 +109,7 @@ class Copypaste return $this; } - public function getText(): string + public function getText(): ?string { return $this->text; } @@ -135,7 +133,7 @@ class Copypaste return $this; } - public function getLanguage(): Language + public function getLanguage(): ?Language { return $this->language; } diff --git a/src/Form/FakeCaptchaType.php b/src/Form/FakeCaptchaType.php index 2e6750a..a1179f8 100644 --- a/src/Form/FakeCaptchaType.php +++ b/src/Form/FakeCaptchaType.php @@ -9,11 +9,6 @@ use Symfony\Component\OptionsResolver\OptionsResolver; class FakeCaptchaType extends AbstractType { - public function buildForm(FormBuilderInterface $builder, array $options) - { - - } - public function configureOptions(OptionsResolver $resolver) { $resolver->setDefaults([ diff --git a/src/Form/CopypasteType.php b/src/Form/PasteType.php similarity index 85% rename from src/Form/CopypasteType.php rename to src/Form/PasteType.php index de645a4..aedfcd2 100644 --- a/src/Form/CopypasteType.php +++ b/src/Form/PasteType.php @@ -2,25 +2,17 @@ namespace App\Form; -use App\Entity\Copypaste; -use App\Entity\Language; +use App\Entity\{Paste, Language}; use Symfony\Bridge\Doctrine\Form\Type\EntityType; use Symfony\Component\Form\AbstractType; -use Symfony\Component\Form\Extension\Core\Type\CheckboxType; -use Symfony\Component\Form\Extension\Core\Type\ChoiceType; -use Symfony\Component\Form\Extension\Core\Type\TextareaType; -use Symfony\Component\Form\Extension\Core\Type\TextType; +use Symfony\Component\Form\Extension\Core\Type\{CheckboxType, ChoiceType, TextareaType, TextType}; use Symfony\Component\Form\FormBuilderInterface; use Symfony\Component\OptionsResolver\OptionsResolver; use Doctrine\ORM\EntityRepository; use Doctrine\ORM\QueryBuilder; -class CopypasteType extends AbstractType +class PasteType extends AbstractType { - /** - * @param FormBuilderInterface $builder - * @param array $options - */ public function buildForm(FormBuilderInterface $builder, array $options) { $builder @@ -83,7 +75,7 @@ class CopypasteType extends AbstractType public function configureOptions(OptionsResolver $resolver) { $resolver->setDefaults([ - 'data_class' => Copypaste::class + 'data_class' => Paste::class ]); } } diff --git a/symfony.lock b/symfony.lock index a709f77..57bda98 100644 --- a/symfony.lock +++ b/symfony.lock @@ -317,6 +317,15 @@ "ref": "369b5b29dc52b2c190002825ae7ec24ab6f962dd" } }, + "symfony/validator": { + "version": "4.1", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "master", + "version": "4.1", + "ref": "0cdc982334f45d554957a6167e030482795bf9d7" + } + }, "symfony/var-dumper": { "version": "v4.2.2" }, diff --git a/templates/Form/fields.html.twig b/templates/Form/fields.html.twig index dec8ba7..9420c54 100644 --- a/templates/Form/fields.html.twig +++ b/templates/Form/fields.html.twig @@ -1,4 +1,4 @@ -{% block copypaste_fake_captcha_widget %} +{% block fake_captcha_widget %} {% spaceless %}
+ {% endblock %} {%- block header -%} diff --git a/templates/layout.html.twig b/templates/layout.html.twig index 7755374..ad7a4cb 100644 --- a/templates/layout.html.twig +++ b/templates/layout.html.twig @@ -4,7 +4,7 @@ {%- block head -%} {% block title %}CopyPaste{% endblock %} - + {%- block css -%} {%- endblock -%} From 11b4903cf1b6466bc7ed81b8741dcd1881c2b8b7 Mon Sep 17 00:00:00 2001 From: Alexey Skobkin Date: Sun, 20 Jan 2019 07:13:52 +0300 Subject: [PATCH 10/13] Redundant import removed. --- src/Form/FakeCaptchaType.php | 1 - 1 file changed, 1 deletion(-) diff --git a/src/Form/FakeCaptchaType.php b/src/Form/FakeCaptchaType.php index a1179f8..9d0935a 100644 --- a/src/Form/FakeCaptchaType.php +++ b/src/Form/FakeCaptchaType.php @@ -4,7 +4,6 @@ namespace App\Form; use Symfony\Component\Form\AbstractType; use Symfony\Component\Form\Extension\Core\Type\HiddenType; -use Symfony\Component\Form\FormBuilderInterface; use Symfony\Component\OptionsResolver\OptionsResolver; class FakeCaptchaType extends AbstractType From 13c3f9c660364b7527558eae45c9b406ba79fd5e Mon Sep 17 00:00:00 2001 From: Alexey Skobkin Date: Thu, 24 Jan 2019 21:36:25 +0300 Subject: [PATCH 11/13] .gitignore optimized. Ignored files removed from index. --- .gitignore | 5 ----- var/cache/.gitkeep | 0 var/log/.gitkeep | 0 3 files changed, 5 deletions(-) delete mode 100644 var/cache/.gitkeep delete mode 100644 var/log/.gitkeep diff --git a/.gitignore b/.gitignore index d2f575b..ffb635d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,9 +1,4 @@ /.idea/ -/var/cache/* -/var/log/* -!/var/cache/.gitkeep -!/var/log/.gitkeep -/vendor/ /.env ###> symfony/framework-bundle ### /.env.local diff --git a/var/cache/.gitkeep b/var/cache/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/var/log/.gitkeep b/var/log/.gitkeep deleted file mode 100644 index e69de29..0000000 From 406346134745af6c3e9b3a5f4b439da199f4e407 Mon Sep 17 00:00:00 2001 From: Alexey Skobkin Date: Thu, 24 Jan 2019 23:09:58 +0300 Subject: [PATCH 12/13] Doctrine Migrations config fixed. --- config/packages/doctrine_migrations.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/packages/doctrine_migrations.yaml b/config/packages/doctrine_migrations.yaml index b5aa645..70959a6 100644 --- a/config/packages/doctrine_migrations.yaml +++ b/config/packages/doctrine_migrations.yaml @@ -1,3 +1,3 @@ doctrine_migrations: dir_name: '%kernel.project_dir%/src/Migrations' - namespace: Migrations + namespace: DoctrineMigrations From d7dadacf0bac91864697b291e18a545fc85ce0d6 Mon Sep 17 00:00:00 2001 From: Alexey Skobkin Date: Thu, 24 Jan 2019 23:17:34 +0300 Subject: [PATCH 13/13] composer require --dev symfony/phpunit-bridge --- .env.test | 4 +++ .gitignore | 5 ++++ bin/phpunit | 19 ++++++++++++++ composer.json | 1 + composer.lock | 68 +++++++++++++++++++++++++++++++++++++++++++++++- phpunit.xml.dist | 31 ++++++++++++++++++++++ symfony.lock | 9 +++++++ tests/.gitignore | 0 8 files changed, 136 insertions(+), 1 deletion(-) create mode 100644 .env.test create mode 100755 bin/phpunit create mode 100644 phpunit.xml.dist create mode 100644 tests/.gitignore diff --git a/.env.test b/.env.test new file mode 100644 index 0000000..414430e --- /dev/null +++ b/.env.test @@ -0,0 +1,4 @@ +# define your env variables for the test env here +KERNEL_CLASS='App\Kernel' +APP_SECRET='s$cretf0rt3st' +SYMFONY_DEPRECATIONS_HELPER=999999 diff --git a/.gitignore b/.gitignore index ffb635d..3b0ecc2 100644 --- a/.gitignore +++ b/.gitignore @@ -12,3 +12,8 @@ ###> symfony/web-server-bundle ### /.web-server-pid ###< symfony/web-server-bundle ### + +###> symfony/phpunit-bridge ### +.phpunit +/phpunit.xml +###< symfony/phpunit-bridge ### diff --git a/bin/phpunit b/bin/phpunit new file mode 100755 index 0000000..cd7e32e --- /dev/null +++ b/bin/phpunit @@ -0,0 +1,19 @@ +#!/usr/bin/env php +=5.3.3" + }, + "conflict": { + "phpunit/phpunit": "<4.8.35|<5.4.3,>=5.0" + }, + "suggest": { + "ext-zip": "Zip support is required when using bin/simple-phpunit", + "symfony/debug": "For tracking deprecated interfaces usages at runtime with DebugClassLoader" + }, + "bin": [ + "bin/simple-phpunit" + ], + "type": "symfony-bridge", + "extra": { + "branch-alias": { + "dev-master": "4.2-dev" + }, + "thanks": { + "name": "phpunit/phpunit", + "url": "https://github.com/sebastianbergmann/phpunit" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Bridge\\PhpUnit\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony PHPUnit Bridge", + "homepage": "https://symfony.com", + "time": "2019-01-03T09:07:35+00:00" + }, { "name": "symfony/polyfill-php72", "version": "v1.10.0", diff --git a/phpunit.xml.dist b/phpunit.xml.dist new file mode 100644 index 0000000..134c69e --- /dev/null +++ b/phpunit.xml.dist @@ -0,0 +1,31 @@ + + + + + + + + + + + + + tests + + + + + + src + + + + + + + diff --git a/symfony.lock b/symfony.lock index 57bda98..f5dcc46 100644 --- a/symfony.lock +++ b/symfony.lock @@ -242,6 +242,15 @@ "symfony/orm-pack": { "version": "v1.0.6" }, + "symfony/phpunit-bridge": { + "version": "4.1", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "master", + "version": "4.1", + "ref": "0e548dd90adba18fabd4ef419b14d361fe4d6c74" + } + }, "symfony/polyfill-ctype": { "version": "v1.10.0" }, diff --git a/tests/.gitignore b/tests/.gitignore new file mode 100644 index 0000000..e69de29