diff --git a/.gitignore b/.gitignore
index c6178a65..6884decd 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,6 +2,7 @@
/.idea/
/.mage/
/.vscode/
+/public/base-packages/
/public/p/
/public/p2/
/public/satis/
diff --git a/.mage.yml b/.mage.yml
index c1609b5d..0e81427a 100644
--- a/.mage.yml
+++ b/.mage.yml
@@ -11,6 +11,7 @@ magephp:
- ./public/packages.json
- ./stubs
- ./tests
+ - ./tmp
- ./tools
- ./var
- ./LICENSE
@@ -30,8 +31,10 @@ magephp:
- exec: { cmd: "echo \"APP_ENV=prod\" >> .env.local", desc: "Create .env.local" }
- composer/install: { flags: '--no-dev --no-progress --optimize-autoloader' }
on-deploy:
+ - exec: { cmd: 'mkdir -p tmp/base-packages', desc: 'Create tmp/base-packages folder' }
- exec: { cmd: 'mkdir -p var', desc: 'Create var folder' }
- exec: { cmd: 'mkdir -p var/satis', desc: 'Create var/satis folder' }
+ - exec: { cmd: 'test -d ~/site/shared/base-packages || mkdir -p ~/site/shared/base-packages', desc: 'Create shared/base-packages folder' }
- exec: { cmd: 'test -d ~/site/shared/public/satis || mkdir -p ~/site/shared/public/satis', desc: 'Create shared/public/satis folder' }
- fs/link: { from: "../../../shared/.env.local", to: ".env.local" }
- fs/link: { from: "../../../../shared/public/satis", to: "public/satis" }
@@ -39,6 +42,7 @@ magephp:
- fs/link: { from: "satis/p2", to: "public/p2" }
- fs/link: { from: "satis/aliases.json", to: "public/aliases.json" }
- fs/link: { from: "satis/packages.json", to: "public/packages.json" }
+ - fs/link: { from: "../../../../../shared/base-packages", to: "tmp/base-packages/packages" }
- exec: { cmd: "sqlite3 ~/site/mage/current/var/gettr.db '.backup var/gettr.db'", desc: "Copy DB" }
- exec: { cmd: "php-restart", desc: "Restart PHP and reset OPcache" }
- exec: { cmd: "php ./bin/console doctrine:migrations:sync-metadata-storage --no-interaction", desc: "Synchronize DB Migrations" }
diff --git a/cnf/nginx.conf b/cnf/nginx.conf
index 327f2f4f..eea84713 100644
--- a/cnf/nginx.conf
+++ b/cnf/nginx.conf
@@ -54,6 +54,9 @@ location ~ (?!^\/\.well-known)\/\. {
allow 213.144.157.127;
allow 2001:1620:c7f:111::/64;
+# Allow GitHub for webhook testing
+allow 140.82.115.0/24;
+
# Block abusing IPs
deny 212.95.122.212;
diff --git a/composer.json b/composer.json
index 1bfdd2ed..fb26dbb3 100644
--- a/composer.json
+++ b/composer.json
@@ -34,78 +34,84 @@
"ext-ctype": "*",
"ext-iconv": "*",
"ext-json": "*",
+ "ext-mbstring": "*",
"ext-sqlite3": "*",
+ "ext-zip": "*",
"ext-zlib": "*",
- "composer/semver": "^3.3",
- "doctrine/collections": "^1.6",
- "doctrine/dbal": "^3.3",
- "doctrine/doctrine-bundle": "^2.7",
- "doctrine/doctrine-migrations-bundle": "^3.2",
- "doctrine/inflector": "^2.0",
- "doctrine/orm": "^2.12",
- "doctrine/persistence": "^2.5",
- "easycorp/easyadmin-bundle": "^4.3",
- "erusev/parsedown": "^1.7",
- "guzzlehttp/guzzle": "^7.4",
- "guzzlehttp/promises": "^1.5",
- "jms/serializer": "^3.17",
- "jms/serializer-bundle": "^4.0.2",
+ "composer/composer": "^2.5.5",
+ "composer/semver": "^3.3.2",
+ "doctrine/collections": "^1.8",
+ "doctrine/dbal": "^3.6.2",
+ "doctrine/doctrine-bundle": "^2.9.1",
+ "doctrine/doctrine-migrations-bundle": "^3.2.2",
+ "doctrine/inflector": "^2.0.6",
+ "doctrine/orm": "^2.14.3",
+ "doctrine/persistence": "^2.5.7",
+ "easycorp/easyadmin-bundle": "^4.6.1",
+ "erusev/parsedown": "^1.7.4",
+ "guzzlehttp/guzzle": "^7.5.1",
+ "guzzlehttp/promises": "^1.5.2",
+ "jms/serializer": "^3.23",
+ "jms/serializer-bundle": "^4.2.0",
"knplabs/knp-menu": "^3.3",
- "nelmio/api-doc-bundle": "^4.9",
- "nelmio/cors-bundle": "^2.2",
- "nelmio/security-bundle": "^2.5",
+ "nelmio/api-doc-bundle": "^4.11.1",
+ "nelmio/cors-bundle": "^2.3.1",
+ "nelmio/security-bundle": "^2.12",
"psr/log": "^2.0",
- "symfony/asset": "^6.2",
- "symfony/cache": "^6.2",
- "symfony/cache-contracts": "^2.5",
- "symfony/console": "^6.2",
- "symfony/dependency-injection": "^6.2",
- "symfony/dotenv": "^6.2",
- "symfony/expression-language": "^6.2",
- "symfony/flex": "^2.2",
- "symfony/form": "^6.2",
- "symfony/framework-bundle": "^6.2",
- "symfony/http-client": "^6.2",
- "symfony/http-foundation": "^6.2",
- "symfony/http-kernel": "^6.2",
- "symfony/intl": "^6.2",
- "symfony/mailer": "^6.2",
- "symfony/mime": "^6.2",
- "symfony/monolog-bundle": "^3.1",
- "symfony/notifier": "^6.2",
- "symfony/process": "^6.2",
- "symfony/property-access": "^6.2",
- "symfony/property-info": "^6.2",
- "symfony/proxy-manager-bridge": "^6.2",
- "symfony/routing": "^6.2",
- "symfony/runtime": "^6.2",
- "symfony/security-bundle": "^6.2",
- "symfony/security-http": "^6.2",
- "symfony/serializer": "^6.2",
- "symfony/translation": "^6.2",
- "symfony/twig-bundle": "^6.2",
- "symfony/validator": "^6.2",
- "symfony/web-link": "^6.2",
- "symfony/yaml": "^6.2",
- "t3g/symfony-template-bundle": "^3.4",
+ "symfony/asset": "^6.2.7",
+ "symfony/cache": "^6.2.8",
+ "symfony/cache-contracts": "^2.5.2",
+ "symfony/console": "^6.2.8",
+ "symfony/dependency-injection": "^6.2.8",
+ "symfony/dotenv": "^6.2.8",
+ "symfony/expression-language": "^6.2.7",
+ "symfony/filesystem": "^6.2.7",
+ "symfony/finder": "^6.2.7",
+ "symfony/flex": "^2.2.5",
+ "symfony/form": "^6.2.8",
+ "symfony/framework-bundle": "^6.2.9",
+ "symfony/http-client": "^6.2.9",
+ "symfony/http-foundation": "^6.2.8",
+ "symfony/http-kernel": "^6.2.9",
+ "symfony/intl": "^6.2.9",
+ "symfony/mailer": "^6.2.8",
+ "symfony/mime": "^6.2.7",
+ "symfony/monolog-bundle": "^3.8",
+ "symfony/notifier": "^6.2.8",
+ "symfony/options-resolver": "^6.2.7",
+ "symfony/process": "^6.2.8",
+ "symfony/property-access": "^6.2.8",
+ "symfony/property-info": "^6.2.8",
+ "symfony/proxy-manager-bridge": "^6.2.7",
+ "symfony/routing": "^6.2.8",
+ "symfony/runtime": "^6.2.8",
+ "symfony/security-bundle": "^6.2.8",
+ "symfony/security-http": "^6.2.8",
+ "symfony/serializer": "^6.2.8",
+ "symfony/translation": "^6.2.8",
+ "symfony/twig-bundle": "^6.2.7",
+ "symfony/validator": "^6.2.8",
+ "symfony/web-link": "^6.2.7",
+ "symfony/yaml": "^6.2.7",
+ "t3g/symfony-template-bundle": "^3.5",
"t3g/symfony-usercentrics-bundle": "^1.0.2 || dev-master",
- "twig/extra-bundle": "^2.12 || ^3.0",
- "twig/twig": "^2.12 || ^3.0"
+ "twig/extra-bundle": "^2.12 || ^3.5.1",
+ "twig/twig": "^2.12 || ^3.5.1"
},
"require-dev": {
- "bamarni/composer-bin-plugin": "^1.8",
- "doctrine/doctrine-fixtures-bundle": "^3.4",
- "ergebnis/composer-normalize": "^2.28",
- "fakerphp/faker": "^1.20",
+ "bamarni/composer-bin-plugin": "^1.8.2",
+ "doctrine/doctrine-fixtures-bundle": "^3.4.3",
+ "ergebnis/composer-normalize": "^2.30.2",
+ "fakerphp/faker": "^1.21",
"roave/security-advisories": "dev-latest",
- "symfony/browser-kit": "^6.2",
- "symfony/css-selector": "^6.2",
- "symfony/debug-bundle": "^6.2",
- "symfony/maker-bundle": "^1.45",
- "symfony/panther": "^2.0",
- "symfony/stopwatch": "^6.2",
- "symfony/var-dumper": "^6.2",
- "symfony/web-profiler-bundle": "^6.2"
+ "symfony/browser-kit": "^6.2.7",
+ "symfony/css-selector": "^6.2.7",
+ "symfony/debug-bundle": "^6.2.7",
+ "symfony/maker-bundle": "^1.48",
+ "symfony/panther": "^2.0.1",
+ "symfony/stopwatch": "^6.2.7",
+ "symfony/var-dumper": "^6.2.8",
+ "symfony/web-profiler-bundle": "^6.2.7"
},
"replace": {
"paragonie/random_compat": "2.*",
diff --git a/composer.lock b/composer.lock
index 0ee4eacc..b4639770 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": "8e1b5f08cabf42768a73e907373eb415",
+ "content-hash": "1ddf83ba22b6b292386b8ac262f094da",
"packages": [
{
"name": "composer/ca-bundle",
@@ -82,6 +82,332 @@
],
"time": "2023-01-11T08:27:00+00:00"
},
+ {
+ "name": "composer/class-map-generator",
+ "version": "1.0.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/composer/class-map-generator.git",
+ "reference": "1e1cb2b791facb2dfe32932a7718cf2571187513"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/composer/class-map-generator/zipball/1e1cb2b791facb2dfe32932a7718cf2571187513",
+ "reference": "1e1cb2b791facb2dfe32932a7718cf2571187513",
+ "shasum": ""
+ },
+ "require": {
+ "composer/pcre": "^2 || ^3",
+ "php": "^7.2 || ^8.0",
+ "symfony/finder": "^4.4 || ^5.3 || ^6"
+ },
+ "require-dev": {
+ "phpstan/phpstan": "^1.6",
+ "phpstan/phpstan-deprecation-rules": "^1",
+ "phpstan/phpstan-phpunit": "^1",
+ "phpstan/phpstan-strict-rules": "^1.1",
+ "symfony/filesystem": "^5.4 || ^6",
+ "symfony/phpunit-bridge": "^5"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "1.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Composer\\ClassMapGenerator\\": "src"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Jordi Boggiano",
+ "email": "j.boggiano@seld.be",
+ "homepage": "https://seld.be"
+ }
+ ],
+ "description": "Utilities to scan PHP code and generate class maps.",
+ "keywords": [
+ "classmap"
+ ],
+ "support": {
+ "issues": "https://github.com/composer/class-map-generator/issues",
+ "source": "https://github.com/composer/class-map-generator/tree/1.0.0"
+ },
+ "funding": [
+ {
+ "url": "https://packagist.com",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/composer",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/composer/composer",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2022-06-19T11:31:27+00:00"
+ },
+ {
+ "name": "composer/composer",
+ "version": "2.5.5",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/composer/composer.git",
+ "reference": "c7cffaad16a60636a776017eac5bd8cd0095c32f"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/composer/composer/zipball/c7cffaad16a60636a776017eac5bd8cd0095c32f",
+ "reference": "c7cffaad16a60636a776017eac5bd8cd0095c32f",
+ "shasum": ""
+ },
+ "require": {
+ "composer/ca-bundle": "^1.0",
+ "composer/class-map-generator": "^1.0",
+ "composer/metadata-minifier": "^1.0",
+ "composer/pcre": "^2.1 || ^3.1",
+ "composer/semver": "^3.0",
+ "composer/spdx-licenses": "^1.5.7",
+ "composer/xdebug-handler": "^2.0.2 || ^3.0.3",
+ "justinrainbow/json-schema": "^5.2.11",
+ "php": "^7.2.5 || ^8.0",
+ "psr/log": "^1.0 || ^2.0 || ^3.0",
+ "react/promise": "^2.8",
+ "seld/jsonlint": "^1.4",
+ "seld/phar-utils": "^1.2",
+ "seld/signal-handler": "^2.0",
+ "symfony/console": "^5.4.11 || ^6.0.11",
+ "symfony/filesystem": "^5.4 || ^6.0",
+ "symfony/finder": "^5.4 || ^6.0",
+ "symfony/polyfill-php73": "^1.24",
+ "symfony/polyfill-php80": "^1.24",
+ "symfony/polyfill-php81": "^1.24",
+ "symfony/process": "^5.4 || ^6.0"
+ },
+ "require-dev": {
+ "phpstan/phpstan": "^1.9.3",
+ "phpstan/phpstan-deprecation-rules": "^1",
+ "phpstan/phpstan-phpunit": "^1.0",
+ "phpstan/phpstan-strict-rules": "^1",
+ "phpstan/phpstan-symfony": "^1.2.10",
+ "symfony/phpunit-bridge": "^6.0"
+ },
+ "suggest": {
+ "ext-openssl": "Enabling the openssl extension allows you to access https URLs for repositories and packages",
+ "ext-zip": "Enabling the zip extension allows you to unzip archives",
+ "ext-zlib": "Allow gzip compression of HTTP requests"
+ },
+ "bin": [
+ "bin/composer"
+ ],
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "2.5-dev"
+ },
+ "phpstan": {
+ "includes": [
+ "phpstan/rules.neon"
+ ]
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Composer\\": "src/Composer"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Nils Adermann",
+ "email": "naderman@naderman.de",
+ "homepage": "https://www.naderman.de"
+ },
+ {
+ "name": "Jordi Boggiano",
+ "email": "j.boggiano@seld.be",
+ "homepage": "https://seld.be"
+ }
+ ],
+ "description": "Composer helps you declare, manage and install dependencies of PHP projects. It ensures you have the right stack everywhere.",
+ "homepage": "https://getcomposer.org/",
+ "keywords": [
+ "autoload",
+ "dependency",
+ "package"
+ ],
+ "support": {
+ "irc": "ircs://irc.libera.chat:6697/composer",
+ "issues": "https://github.com/composer/composer/issues",
+ "source": "https://github.com/composer/composer/tree/2.5.5"
+ },
+ "funding": [
+ {
+ "url": "https://packagist.com",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/composer",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/composer/composer",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2023-03-21T10:50:05+00:00"
+ },
+ {
+ "name": "composer/metadata-minifier",
+ "version": "1.0.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/composer/metadata-minifier.git",
+ "reference": "c549d23829536f0d0e984aaabbf02af91f443207"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/composer/metadata-minifier/zipball/c549d23829536f0d0e984aaabbf02af91f443207",
+ "reference": "c549d23829536f0d0e984aaabbf02af91f443207",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^5.3.2 || ^7.0 || ^8.0"
+ },
+ "require-dev": {
+ "composer/composer": "^2",
+ "phpstan/phpstan": "^0.12.55",
+ "symfony/phpunit-bridge": "^4.2 || ^5"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "1.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Composer\\MetadataMinifier\\": "src"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Jordi Boggiano",
+ "email": "j.boggiano@seld.be",
+ "homepage": "http://seld.be"
+ }
+ ],
+ "description": "Small utility library that handles metadata minification and expansion.",
+ "keywords": [
+ "composer",
+ "compression"
+ ],
+ "support": {
+ "issues": "https://github.com/composer/metadata-minifier/issues",
+ "source": "https://github.com/composer/metadata-minifier/tree/1.0.0"
+ },
+ "funding": [
+ {
+ "url": "https://packagist.com",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/composer",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/composer/composer",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2021-04-07T13:37:33+00:00"
+ },
+ {
+ "name": "composer/pcre",
+ "version": "3.1.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/composer/pcre.git",
+ "reference": "4bff79ddd77851fe3cdd11616ed3f92841ba5bd2"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/composer/pcre/zipball/4bff79ddd77851fe3cdd11616ed3f92841ba5bd2",
+ "reference": "4bff79ddd77851fe3cdd11616ed3f92841ba5bd2",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^7.4 || ^8.0"
+ },
+ "require-dev": {
+ "phpstan/phpstan": "^1.3",
+ "phpstan/phpstan-strict-rules": "^1.1",
+ "symfony/phpunit-bridge": "^5"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "3.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Composer\\Pcre\\": "src"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Jordi Boggiano",
+ "email": "j.boggiano@seld.be",
+ "homepage": "http://seld.be"
+ }
+ ],
+ "description": "PCRE wrapping library that offers type-safe preg_* replacements.",
+ "keywords": [
+ "PCRE",
+ "preg",
+ "regex",
+ "regular expression"
+ ],
+ "support": {
+ "issues": "https://github.com/composer/pcre/issues",
+ "source": "https://github.com/composer/pcre/tree/3.1.0"
+ },
+ "funding": [
+ {
+ "url": "https://packagist.com",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/composer",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/composer/composer",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2022-11-17T09:50:14+00:00"
+ },
{
"name": "composer/semver",
"version": "3.3.2",
@@ -163,6 +489,152 @@
],
"time": "2022-04-01T19:23:25+00:00"
},
+ {
+ "name": "composer/spdx-licenses",
+ "version": "1.5.7",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/composer/spdx-licenses.git",
+ "reference": "c848241796da2abf65837d51dce1fae55a960149"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/composer/spdx-licenses/zipball/c848241796da2abf65837d51dce1fae55a960149",
+ "reference": "c848241796da2abf65837d51dce1fae55a960149",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^5.3.2 || ^7.0 || ^8.0"
+ },
+ "require-dev": {
+ "phpstan/phpstan": "^0.12.55",
+ "symfony/phpunit-bridge": "^4.2 || ^5"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "1.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Composer\\Spdx\\": "src"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Nils Adermann",
+ "email": "naderman@naderman.de",
+ "homepage": "http://www.naderman.de"
+ },
+ {
+ "name": "Jordi Boggiano",
+ "email": "j.boggiano@seld.be",
+ "homepage": "http://seld.be"
+ },
+ {
+ "name": "Rob Bast",
+ "email": "rob.bast@gmail.com",
+ "homepage": "http://robbast.nl"
+ }
+ ],
+ "description": "SPDX licenses list and validation library.",
+ "keywords": [
+ "license",
+ "spdx",
+ "validator"
+ ],
+ "support": {
+ "irc": "irc://irc.freenode.org/composer",
+ "issues": "https://github.com/composer/spdx-licenses/issues",
+ "source": "https://github.com/composer/spdx-licenses/tree/1.5.7"
+ },
+ "funding": [
+ {
+ "url": "https://packagist.com",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/composer",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/composer/composer",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2022-05-23T07:37:50+00:00"
+ },
+ {
+ "name": "composer/xdebug-handler",
+ "version": "3.0.3",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/composer/xdebug-handler.git",
+ "reference": "ced299686f41dce890debac69273b47ffe98a40c"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/ced299686f41dce890debac69273b47ffe98a40c",
+ "reference": "ced299686f41dce890debac69273b47ffe98a40c",
+ "shasum": ""
+ },
+ "require": {
+ "composer/pcre": "^1 || ^2 || ^3",
+ "php": "^7.2.5 || ^8.0",
+ "psr/log": "^1 || ^2 || ^3"
+ },
+ "require-dev": {
+ "phpstan/phpstan": "^1.0",
+ "phpstan/phpstan-strict-rules": "^1.1",
+ "symfony/phpunit-bridge": "^6.0"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Composer\\XdebugHandler\\": "src"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "John Stevenson",
+ "email": "john-stevenson@blueyonder.co.uk"
+ }
+ ],
+ "description": "Restarts a process without Xdebug.",
+ "keywords": [
+ "Xdebug",
+ "performance"
+ ],
+ "support": {
+ "irc": "irc://irc.freenode.org/composer",
+ "issues": "https://github.com/composer/xdebug-handler/issues",
+ "source": "https://github.com/composer/xdebug-handler/tree/3.0.3"
+ },
+ "funding": [
+ {
+ "url": "https://packagist.com",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/composer",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/composer/composer",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2022-02-25T21:32:43+00:00"
+ },
{
"name": "doctrine/annotations",
"version": "2.0.1",
@@ -2393,16 +2865,86 @@
"xml"
],
"support": {
- "issues": "https://github.com/schmittjoh/JMSSerializerBundle/issues",
- "source": "https://github.com/schmittjoh/JMSSerializerBundle/tree/4.2.0"
+ "issues": "https://github.com/schmittjoh/JMSSerializerBundle/issues",
+ "source": "https://github.com/schmittjoh/JMSSerializerBundle/tree/4.2.0"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/goetas",
+ "type": "github"
+ }
+ ],
+ "time": "2022-09-13T19:27:18+00:00"
+ },
+ {
+ "name": "justinrainbow/json-schema",
+ "version": "5.2.12",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/justinrainbow/json-schema.git",
+ "reference": "ad87d5a5ca981228e0e205c2bc7dfb8e24559b60"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/justinrainbow/json-schema/zipball/ad87d5a5ca981228e0e205c2bc7dfb8e24559b60",
+ "reference": "ad87d5a5ca981228e0e205c2bc7dfb8e24559b60",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=5.3.3"
+ },
+ "require-dev": {
+ "friendsofphp/php-cs-fixer": "~2.2.20||~2.15.1",
+ "json-schema/json-schema-test-suite": "1.2.0",
+ "phpunit/phpunit": "^4.8.35"
+ },
+ "bin": [
+ "bin/validate-json"
+ ],
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "5.0.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "JsonSchema\\": "src/JsonSchema/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Bruno Prieto Reis",
+ "email": "bruno.p.reis@gmail.com"
+ },
+ {
+ "name": "Justin Rainbow",
+ "email": "justin.rainbow@gmail.com"
+ },
+ {
+ "name": "Igor Wiedler",
+ "email": "igor@wiedler.ch"
+ },
+ {
+ "name": "Robert Schönthal",
+ "email": "seroscho@googlemail.com"
+ }
+ ],
+ "description": "A library to validate a json schema.",
+ "homepage": "https://github.com/justinrainbow/json-schema",
+ "keywords": [
+ "json",
+ "schema"
+ ],
+ "support": {
+ "issues": "https://github.com/justinrainbow/json-schema/issues",
+ "source": "https://github.com/justinrainbow/json-schema/tree/5.2.12"
},
- "funding": [
- {
- "url": "https://github.com/goetas",
- "type": "github"
- }
- ],
- "time": "2022-09-13T19:27:18+00:00"
+ "time": "2022-04-13T08:02:27+00:00"
},
{
"name": "knplabs/knp-components",
@@ -3780,6 +4322,255 @@
},
"time": "2019-03-08T08:55:37+00:00"
},
+ {
+ "name": "react/promise",
+ "version": "v2.9.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/reactphp/promise.git",
+ "reference": "234f8fd1023c9158e2314fa9d7d0e6a83db42910"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/reactphp/promise/zipball/234f8fd1023c9158e2314fa9d7d0e6a83db42910",
+ "reference": "234f8fd1023c9158e2314fa9d7d0e6a83db42910",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=5.4.0"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^9.3 || ^5.7 || ^4.8.36"
+ },
+ "type": "library",
+ "autoload": {
+ "files": [
+ "src/functions_include.php"
+ ],
+ "psr-4": {
+ "React\\Promise\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Jan Sorgalla",
+ "email": "jsorgalla@gmail.com",
+ "homepage": "https://sorgalla.com/"
+ },
+ {
+ "name": "Christian Lück",
+ "email": "christian@clue.engineering",
+ "homepage": "https://clue.engineering/"
+ },
+ {
+ "name": "Cees-Jan Kiewiet",
+ "email": "reactphp@ceesjankiewiet.nl",
+ "homepage": "https://wyrihaximus.net/"
+ },
+ {
+ "name": "Chris Boden",
+ "email": "cboden@gmail.com",
+ "homepage": "https://cboden.dev/"
+ }
+ ],
+ "description": "A lightweight implementation of CommonJS Promises/A for PHP",
+ "keywords": [
+ "promise",
+ "promises"
+ ],
+ "support": {
+ "issues": "https://github.com/reactphp/promise/issues",
+ "source": "https://github.com/reactphp/promise/tree/v2.9.0"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/WyriHaximus",
+ "type": "github"
+ },
+ {
+ "url": "https://github.com/clue",
+ "type": "github"
+ }
+ ],
+ "time": "2022-02-11T10:27:51+00:00"
+ },
+ {
+ "name": "seld/jsonlint",
+ "version": "1.9.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/Seldaek/jsonlint.git",
+ "reference": "4211420d25eba80712bff236a98960ef68b866b7"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/Seldaek/jsonlint/zipball/4211420d25eba80712bff236a98960ef68b866b7",
+ "reference": "4211420d25eba80712bff236a98960ef68b866b7",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^5.3 || ^7.0 || ^8.0"
+ },
+ "require-dev": {
+ "phpstan/phpstan": "^1.5",
+ "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.0 || ^8.5.13"
+ },
+ "bin": [
+ "bin/jsonlint"
+ ],
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Seld\\JsonLint\\": "src/Seld/JsonLint/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Jordi Boggiano",
+ "email": "j.boggiano@seld.be",
+ "homepage": "http://seld.be"
+ }
+ ],
+ "description": "JSON Linter",
+ "keywords": [
+ "json",
+ "linter",
+ "parser",
+ "validator"
+ ],
+ "support": {
+ "issues": "https://github.com/Seldaek/jsonlint/issues",
+ "source": "https://github.com/Seldaek/jsonlint/tree/1.9.0"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/Seldaek",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/seld/jsonlint",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2022-04-01T13:37:23+00:00"
+ },
+ {
+ "name": "seld/phar-utils",
+ "version": "1.2.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/Seldaek/phar-utils.git",
+ "reference": "ea2f4014f163c1be4c601b9b7bd6af81ba8d701c"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/Seldaek/phar-utils/zipball/ea2f4014f163c1be4c601b9b7bd6af81ba8d701c",
+ "reference": "ea2f4014f163c1be4c601b9b7bd6af81ba8d701c",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=5.3"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Seld\\PharUtils\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Jordi Boggiano",
+ "email": "j.boggiano@seld.be"
+ }
+ ],
+ "description": "PHAR file format utilities, for when PHP phars you up",
+ "keywords": [
+ "phar"
+ ],
+ "support": {
+ "issues": "https://github.com/Seldaek/phar-utils/issues",
+ "source": "https://github.com/Seldaek/phar-utils/tree/1.2.1"
+ },
+ "time": "2022-08-31T10:31:18+00:00"
+ },
+ {
+ "name": "seld/signal-handler",
+ "version": "2.0.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/Seldaek/signal-handler.git",
+ "reference": "f69d119511dc0360440cdbdaa71829c149b7be75"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/Seldaek/signal-handler/zipball/f69d119511dc0360440cdbdaa71829c149b7be75",
+ "reference": "f69d119511dc0360440cdbdaa71829c149b7be75",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=7.2.0"
+ },
+ "require-dev": {
+ "phpstan/phpstan": "^1",
+ "phpstan/phpstan-deprecation-rules": "^1.0",
+ "phpstan/phpstan-phpunit": "^1",
+ "phpstan/phpstan-strict-rules": "^1.3",
+ "phpunit/phpunit": "^7.5.20 || ^8.5.23",
+ "psr/log": "^1 || ^2 || ^3"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "2.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Seld\\Signal\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Jordi Boggiano",
+ "email": "j.boggiano@seld.be",
+ "homepage": "http://seld.be"
+ }
+ ],
+ "description": "Simple unix signal handler that silently fails where signals are not supported for easy cross-platform development",
+ "keywords": [
+ "posix",
+ "sigint",
+ "signal",
+ "sigterm",
+ "unix"
+ ],
+ "support": {
+ "issues": "https://github.com/Seldaek/signal-handler/issues",
+ "source": "https://github.com/Seldaek/signal-handler/tree/2.0.1"
+ },
+ "time": "2022-07-20T18:31:45+00:00"
+ },
{
"name": "setasign/fpdi",
"version": "v2.3.7",
@@ -9675,76 +10466,6 @@
},
"time": "2022-12-13T13:54:32+00:00"
},
- {
- "name": "justinrainbow/json-schema",
- "version": "5.2.12",
- "source": {
- "type": "git",
- "url": "https://github.com/justinrainbow/json-schema.git",
- "reference": "ad87d5a5ca981228e0e205c2bc7dfb8e24559b60"
- },
- "dist": {
- "type": "zip",
- "url": "https://api.github.com/repos/justinrainbow/json-schema/zipball/ad87d5a5ca981228e0e205c2bc7dfb8e24559b60",
- "reference": "ad87d5a5ca981228e0e205c2bc7dfb8e24559b60",
- "shasum": ""
- },
- "require": {
- "php": ">=5.3.3"
- },
- "require-dev": {
- "friendsofphp/php-cs-fixer": "~2.2.20||~2.15.1",
- "json-schema/json-schema-test-suite": "1.2.0",
- "phpunit/phpunit": "^4.8.35"
- },
- "bin": [
- "bin/validate-json"
- ],
- "type": "library",
- "extra": {
- "branch-alias": {
- "dev-master": "5.0.x-dev"
- }
- },
- "autoload": {
- "psr-4": {
- "JsonSchema\\": "src/JsonSchema/"
- }
- },
- "notification-url": "https://packagist.org/downloads/",
- "license": [
- "MIT"
- ],
- "authors": [
- {
- "name": "Bruno Prieto Reis",
- "email": "bruno.p.reis@gmail.com"
- },
- {
- "name": "Justin Rainbow",
- "email": "justin.rainbow@gmail.com"
- },
- {
- "name": "Igor Wiedler",
- "email": "igor@wiedler.ch"
- },
- {
- "name": "Robert Schönthal",
- "email": "seroscho@googlemail.com"
- }
- ],
- "description": "A library to validate a json schema.",
- "homepage": "https://github.com/justinrainbow/json-schema",
- "keywords": [
- "json",
- "schema"
- ],
- "support": {
- "issues": "https://github.com/justinrainbow/json-schema/issues",
- "source": "https://github.com/justinrainbow/json-schema/tree/5.2.12"
- },
- "time": "2022-04-13T08:02:27+00:00"
- },
{
"name": "localheinz/diff",
"version": "1.1.1",
@@ -9807,26 +10528,24 @@
},
{
"name": "masterminds/html5",
- "version": "2.7.6",
+ "version": "2.8.0",
"source": {
"type": "git",
"url": "https://github.com/Masterminds/html5-php.git",
- "reference": "897eb517a343a2281f11bc5556d6548db7d93947"
+ "reference": "3c5d5a56d56f48a1ca08a0670f0f80c1dad368f3"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/Masterminds/html5-php/zipball/897eb517a343a2281f11bc5556d6548db7d93947",
- "reference": "897eb517a343a2281f11bc5556d6548db7d93947",
+ "url": "https://api.github.com/repos/Masterminds/html5-php/zipball/3c5d5a56d56f48a1ca08a0670f0f80c1dad368f3",
+ "reference": "3c5d5a56d56f48a1ca08a0670f0f80c1dad368f3",
"shasum": ""
},
"require": {
- "ext-ctype": "*",
"ext-dom": "*",
- "ext-libxml": "*",
"php": ">=5.3.0"
},
"require-dev": {
- "phpunit/phpunit": "^4.8.35 || ^5.7.21 || ^6 || ^7"
+ "phpunit/phpunit": "^4.8.35 || ^5.7.21 || ^6 || ^7 || ^8"
},
"type": "library",
"extra": {
@@ -9870,9 +10589,9 @@
],
"support": {
"issues": "https://github.com/Masterminds/html5-php/issues",
- "source": "https://github.com/Masterminds/html5-php/tree/2.7.6"
+ "source": "https://github.com/Masterminds/html5-php/tree/2.8.0"
},
- "time": "2022-08-18T16:18:26+00:00"
+ "time": "2023-04-26T07:27:39+00:00"
},
{
"name": "nikic/php-parser",
@@ -10002,12 +10721,12 @@
"source": {
"type": "git",
"url": "https://github.com/Roave/SecurityAdvisories.git",
- "reference": "d2832e4594571d458e36fb4622220915a3c3a8f4"
+ "reference": "5eb9b0587e4625150e4892e569bb223714c86256"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/Roave/SecurityAdvisories/zipball/d2832e4594571d458e36fb4622220915a3c3a8f4",
- "reference": "d2832e4594571d458e36fb4622220915a3c3a8f4",
+ "url": "https://api.github.com/repos/Roave/SecurityAdvisories/zipball/5eb9b0587e4625150e4892e569bb223714c86256",
+ "reference": "5eb9b0587e4625150e4892e569bb223714c86256",
"shasum": ""
},
"conflict": {
@@ -10343,7 +11062,7 @@
"prestashop/blockwishlist": ">=2,<2.1.1",
"prestashop/contactform": ">=1.0.1,<4.3",
"prestashop/gamification": "<2.3.2",
- "prestashop/prestashop": "<8.0.1",
+ "prestashop/prestashop": "<8.0.4",
"prestashop/productcomments": "<5.0.2",
"prestashop/ps_emailsubscription": "<2.6.1",
"prestashop/ps_facetedsearch": "<3.4.1",
@@ -10599,7 +11318,7 @@
"type": "tidelift"
}
],
- "time": "2023-04-25T13:05:55+00:00"
+ "time": "2023-04-25T20:04:17+00:00"
},
{
"name": "symfony/browser-kit",
@@ -11160,7 +11879,9 @@
"ext-ctype": "*",
"ext-iconv": "*",
"ext-json": "*",
+ "ext-mbstring": "*",
"ext-sqlite3": "*",
+ "ext-zip": "*",
"ext-zlib": "*"
},
"platform-dev": [],
diff --git a/config/packages/framework.yaml b/config/packages/framework.yaml
index 7853e9ed..6a7e85e0 100644
--- a/config/packages/framework.yaml
+++ b/config/packages/framework.yaml
@@ -17,6 +17,9 @@ framework:
php_errors:
log: true
+ form:
+ legacy_error_messages: false
+
when@test:
framework:
test: true
diff --git a/config/packages/nelmio_api_doc.yaml b/config/packages/nelmio_api_doc.yaml
index 0b825b43..7246deb6 100644
--- a/config/packages/nelmio_api_doc.yaml
+++ b/config/packages/nelmio_api_doc.yaml
@@ -3,7 +3,7 @@ nelmio_api_doc:
info:
title: get.typo3.org
description: REST API for getting information about TYPO3 releases
- version: 1.0.0
+ version: 1.1.0
components:
securitySchemes:
Basic:
diff --git a/config/packages/twig.yaml b/config/packages/twig.yaml
index 8f4c7e42..5439e3ac 100644
--- a/config/packages/twig.yaml
+++ b/config/packages/twig.yaml
@@ -5,3 +5,5 @@ twig:
packagist:
search: https://packagist.org/explore/?type=typo3-cms-extension
submit: https://packagist.org/packages/submit
+ form_themes:
+ - 'form/custom_theme.html.twig'
diff --git a/config/services.yaml b/config/services.yaml
index cd4c0610..b158a746 100644
--- a/config/services.yaml
+++ b/config/services.yaml
@@ -5,6 +5,8 @@
# https://symfony.com/doc/current/best_practices/configuration.html#application-related-configuration
parameters:
app.domain: '%env(APP_DOMAIN)%'
+ app.base_packages_project_dir: 'tmp/base-packages'
+ app.base_packages_assets_dir: 'base-packages'
services:
# default configuration for services in *this* file
@@ -17,10 +19,14 @@ services:
App\:
resource: '../src/'
exclude:
+ - '../src/DataFixtures/'
- '../src/DependencyInjection/'
- '../src/Entity/'
- - '../src/Kernel.php'
+ - '../src/Enum/'
+ - '../src/Exception/'
+ - '../src/Package/'
- '../src/Tests/'
+ - '../src/Kernel.php'
# controllers are imported separately to make sure services can be injected
# as action arguments even if you don't extend any base controller class
@@ -34,6 +40,9 @@ services:
arguments:
$appDomain: '%env(APP_DOMAIN)%'
+ App\EventListener\BasePackageListener:
+ tags: ['doctrine.orm.entity_listener']
+
App\EventListener\MajorVersionListener:
tags: ['doctrine.orm.entity_listener']
@@ -43,6 +52,17 @@ services:
App\EventListener\RequirementListener:
tags: ['doctrine.orm.entity_listener']
+ App\Security\GitHubRequestChecker:
+ arguments:
+ $signingSecret: '%env(APP_WEBHOOK_SECRET_GITHUB)%'
+
+ App\Service\BasePackageService:
+ arguments:
+ $projectDir: '%app.base_packages_project_dir%'
+ $assetsDir: '%app.base_packages_assets_dir%'
+
App\Service\CacheWarmupService:
arguments:
$baseUrl: '%env(BASE_URL)%'
+
+ Composer\Console\Application:
diff --git a/migrations/Version20220818095608.php b/migrations/Version20220818095608.php
index 4f41860e..55f8a83f 100644
--- a/migrations/Version20220818095608.php
+++ b/migrations/Version20220818095608.php
@@ -33,7 +33,7 @@ final class Version20220818095608 extends AbstractMigration
{
public function getDescription(): string
{
- return '';
+ return 'Add ID to Requirements';
}
public function up(Schema $schema): void
diff --git a/migrations/Version20220818183005.php b/migrations/Version20220818183005.php
new file mode 100644
index 00000000..ad578d6c
--- /dev/null
+++ b/migrations/Version20220818183005.php
@@ -0,0 +1,53 @@
+addSql('CREATE TABLE base_packages (name VARCHAR(255) NOT NULL, active BOOLEAN NOT NULL, official BOOLEAN NOT NULL, PRIMARY KEY(name))');
+ $this->addSql('INSERT INTO base_packages (name, active, official) VALUES (?, ?, ?)', ['1' => 'typo3/bootstrap-package', '2' => 1, '3' => 1], ['1' => 2, '2' => 5, '3' => 5]);
+ $this->addSql('INSERT INTO base_packages (name, active, official) VALUES (?, ?, ?)', ['1' => 'typo3/fluid-styled-content', '2' => 1, '3' => 1], ['1' => 2, '2' => 5, '3' => 5]);
+ $this->addSql('INSERT INTO base_packages (name, active, official) VALUES (?, ?, ?)', ['1' => 'typo3/introduction-package', '2' => 1, '3' => 0], ['1' => 2, '2' => 5, '3' => 5]);
+ }
+
+ public function down(Schema $schema): void
+ {
+ // this down() migration is auto-generated, please modify it to your needs
+ $this->addSql('DROP TABLE base_packages');
+ }
+}
diff --git a/public/assets/Css/additions.css b/public/assets/Css/additions.css
index 1d507832..7e21c392 100644
--- a/public/assets/Css/additions.css
+++ b/public/assets/Css/additions.css
@@ -81,3 +81,11 @@ pre {
.frame .swagger-ui .auth-wrapper .authorize {
margin-right: 0;
}
+
+
+/* BasePackage List */
+.basepackage-official-badge {
+ position: absolute;
+ right: 0.75em;
+ transform: translate(0, 25%);
+}
diff --git a/public/assets/Images/OfficialBadge.svg b/public/assets/Images/OfficialBadge.svg
new file mode 100644
index 00000000..829a4ac8
--- /dev/null
+++ b/public/assets/Images/OfficialBadge.svg
@@ -0,0 +1,92 @@
+
+
+
+
+]>
+
diff --git a/src/Command/ExtensionsTerJsonCreateCommand.php b/src/Command/ExtensionsTerJsonCreateCommand.php
index 7a6bcf4f..33340dc1 100644
--- a/src/Command/ExtensionsTerJsonCreateCommand.php
+++ b/src/Command/ExtensionsTerJsonCreateCommand.php
@@ -423,9 +423,12 @@ protected function getPackageArray(SimpleXMLElement $extension, SimpleXMLElement
],
];
if ($version->composerinfo !== null) {
- $composerInfo = json_decode((string)$version->composerinfo, true, 512);
- if (is_array($composerInfo) && is_array($composerInfo['autoload'] ?? null)) {
- $autoload = $composerInfo['autoload'];
+ try {
+ $composerInfo = json_decode((string)$version->composerinfo, true, 512, JSON_THROW_ON_ERROR);
+ if (is_array($composerInfo) && is_array($composerInfo['autoload'] ?? null)) {
+ $autoload = $composerInfo['autoload'];
+ }
+ } catch (\Throwable) {
}
}
diff --git a/src/Controller/Admin/BasePackageCrudController.php b/src/Controller/Admin/BasePackageCrudController.php
new file mode 100644
index 00000000..9d9934e5
--- /dev/null
+++ b/src/Controller/Admin/BasePackageCrudController.php
@@ -0,0 +1,68 @@
+add(Crud::PAGE_INDEX, Action::DETAIL)
+ ->add(Crud::PAGE_EDIT, Action::DETAIL)
+ ->remove(Crud::PAGE_INDEX, Action::DELETE)
+ ;
+ }
+
+ public function configureFilters(Filters $filters): Filters
+ {
+ return $filters
+ ->add('name')
+ ->add('active')
+ ->add('official')
+ ;
+ }
+
+ public function configureFields(string $pageName): iterable
+ {
+ return [
+ TextField::new('name', 'Composer Package Name'),
+ BooleanField::new('active', 'Active'),
+ BooleanField::new('official', 'Official'),
+ ];
+ }
+}
diff --git a/src/Controller/Admin/DashboardController.php b/src/Controller/Admin/DashboardController.php
index 96d0b9de..c82c6bf0 100644
--- a/src/Controller/Admin/DashboardController.php
+++ b/src/Controller/Admin/DashboardController.php
@@ -23,6 +23,7 @@
namespace App\Controller\Admin;
+use App\Entity\BasePackage;
use App\Entity\MajorVersion;
use App\Entity\Release;
use App\Entity\Requirement;
@@ -32,7 +33,6 @@
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Security\Http\Attribute\IsGranted;
-use Iterator;
#[IsGranted('ROLE_ADMIN')]
class DashboardController extends AbstractDashboardController
@@ -49,14 +49,12 @@ public function configureDashboard(): Dashboard
->setTitle('Administration');
}
- /**
- * @return Iterator<\EasyCorp\Bundle\EasyAdminBundle\Config\Menu\CrudMenuItem|\EasyCorp\Bundle\EasyAdminBundle\Config\Menu\DashboardMenuItem>
- */
public function configureMenuItems(): iterable
{
yield MenuItem::linkToDashboard('Dashboard', 'fa fa-home');
yield MenuItem::linkToCrud('Major Versions', 'fas fa-list', MajorVersion::class);
yield MenuItem::linkToCrud('Requirements', 'fas fa-list', Requirement::class);
yield MenuItem::linkToCrud('Releases', 'fas fa-list', Release::class);
+ yield MenuItem::linkToCrud('Base Packages', 'fas fa-list', BasePackage::class);
}
}
diff --git a/src/Controller/Api/AbstractController.php b/src/Controller/Api/AbstractController.php
index 8e567041..83d47961 100644
--- a/src/Controller/Api/AbstractController.php
+++ b/src/Controller/Api/AbstractController.php
@@ -36,17 +36,16 @@
use JMS\Serializer\SerializerInterface;
use Symfony\Component\HttpKernel\Exception\BadRequestHttpException;
use Symfony\Component\HttpKernel\Exception\NotFoundHttpException;
-use Symfony\Component\Validator\ConstraintViolationInterface;
use Symfony\Contracts\Cache\TagAwareCacheInterface;
use DateTime;
use DateTimeImmutable;
-use function iterator_apply;
-use function iterator_to_array;
use function is_string;
abstract class AbstractController extends \Symfony\Bundle\FrameworkBundle\Controller\AbstractController
{
+ use ValidationTrait;
+
public function __construct(
private \Symfony\Contracts\Cache\TagAwareCacheInterface $cache,
private \App\Service\CacheService $cacheService,
@@ -106,26 +105,6 @@ protected function findMajorVersion(string $version): MajorVersion
return $majorVersion;
}
- protected function validateObject(object $object): void
- {
- $violations = $this->validator->validate($object);
-
- if ($violations->count() > 0) {
- $messages = '';
-
- iterator_apply(
- $violations,
- static function (ConstraintViolationInterface $violation) use (&$messages): bool {
- $messages .= \sprintf("%s: %s\n", $violation->getPropertyPath(), $violation->getMessage());
- return true;
- },
- iterator_to_array($violations)
- );
-
- throw new BadRequestHttpException(trim($messages));
- }
- }
-
/**
* @param array
+ Instead of using the website, you can also create your Sitepackage using + the API. +
+{% endframe %} +{% frame with { id: 'privacy', color: 'light', center: true, indent: true, title: 'We respect your Privacy!' } %} ++ We are not storing, sharing or doing any other crazy stuff with the + data you provide to generate your very own Sitepackage. Simple as + that, check the sources. +
+{% endframe %} diff --git a/templates/tools/sitepackage/configure.html.twig b/templates/tools/sitepackage/configure.html.twig new file mode 100644 index 00000000..dc5a8284 --- /dev/null +++ b/templates/tools/sitepackage/configure.html.twig @@ -0,0 +1,18 @@ +{% extends 'tools/layout.html.twig' %} + +{% block title %}Create your own TYPO3 Sitepackage{% endblock %} + +{% block body %} + + {% frame with { color: 'dark', center: true, title: 'Create your own Sitepackage', titleSize: 1, backgroundImage: asset("assets/Images/keyvisual.png") } %} ++ Awesome you made it here! Just a few more details about your + project and your own Sitepackage is ready for download. +
+ {% endframe %} + + {% frame with { id: 'configuration', indent: true, title: 'Configuration' } %} + {{ form(form, {'attr': {'novalidate': 'novalidate'}}) }} + {% endframe %} + +{% endblock %} diff --git a/templates/tools/sitepackage/detail.html.twig b/templates/tools/sitepackage/detail.html.twig new file mode 100644 index 00000000..580a5a1b --- /dev/null +++ b/templates/tools/sitepackage/detail.html.twig @@ -0,0 +1,90 @@ +{% extends 'tools/layout.html.twig' %} + +{% block title %}Create your own TYPO3 Sitepackage{% endblock %} + +{% block body %} + + {% frame with { color: 'dark', center: true, title: 'Create your own Sitepackage', titleSize: 1, backgroundImage: asset("assets/Images/keyvisual.png") } %} ++ Awesome you made it here! Just a few more details about your + project and your own Sitepackage is ready for download. +
+ {% endframe %} + + {% frame %} +Last Update | +15 September 2020 | +
---|---|
Extensions | +Bootstrap Package Extension XY |
+
Framework | +Bootstrap | +
Columns | +3 | +
Layout | +Responsive | +
+ Your sitepackage was not created, please check the error below. +
+ {% endframe %} + + {% frame with { id: 'error', indent: true, title: 'Error information' } %} +{{ error }}
++ + {{ icon('actions-arrow-left-alt', 'auto') }} + Back + +
+ {% endframe %} + +{% endblock %} diff --git a/templates/tools/sitepackage/index.html.twig b/templates/tools/sitepackage/index.html.twig new file mode 100644 index 00000000..ab5b8bdd --- /dev/null +++ b/templates/tools/sitepackage/index.html.twig @@ -0,0 +1,38 @@ +{% extends 'tools/layout.html.twig' %} + +{% block title %}Kickstart your TYPO3 template development{% endblock %} + +{% block body %} + + {% frame with { color: 'dark', center: true, title: 'Sitepackage Builder', titleSize: 1, backgroundImage: asset("assets/Images/keyvisual.png") } %} ++ Sitepackage-Builder is your kickstarter for modern TYPO3 Theme development. Learn more about TYPO3 templating + or start your own template right now. +
++ + {{ icon('actions-rocket', 'auto') }} + Create Sitepackage + +
+ {% endframe %} + + {% frame with { id: 'about', title: 'What is a Sitepackage?' } %} ++ A Sitepackage is a TYPO3 Extension that containers all relevant configuration for a Website. + Having all configuration stored in a package keeps it protected from unauthorized access. + As Extension your Sitepackage will manage your dependencies to other Extensions and/or the TYPO3 Version. + This will ease your deployment and enables you to put the configuration of your Webiste under Version Control. +
++ Learn more about the best practices recommended from the TYPO3 Core Team. +
++ + {{ icon('actions-notebook', 'auto') }} + Learn about Sitepackages + +
+ {% endframe %} + +{% endblock %} diff --git a/templates/tools/sitepackage/new.html.twig b/templates/tools/sitepackage/new.html.twig new file mode 100644 index 00000000..7a87e261 --- /dev/null +++ b/templates/tools/sitepackage/new.html.twig @@ -0,0 +1,88 @@ +{% extends 'tools/layout.html.twig' %} + +{% block title %}Create your own TYPO3 Sitepackage{% endblock %} + +{% block body %} + + {% frame with { color: 'dark', center: true, title: 'Create your own Sitepackage', titleSize: 1, backgroundImage: asset("assets/Images/keyvisual.png") } %} ++ Awesome you made it here! Just a few more details about your + project and your own Sitepackage is ready for download. +
+ {% endframe %} + + {% if basePackages|length > 0 %} + {% if not filtered %} + {% frame with { id: 'base-packages', center: true, title: 'Choose a Base Package to continue with' } %}{% endframe %} + {% endif %} + + {% frame %} +{{ basePackage.description }}
++ + {{ icon('actions-rocket', 'auto') }} + Show all Base Packages + +
+ {% endframe %} + {% endif %} + {% else %} ++ Your Sitepackage has been successfully prepared. You can now check the + configuration or download the prepared Sitepackage. +
+ {% endframe %} + + {% frame with { id: 'configuration', indent: true, title: 'Your Sitepackage Configuration' } %} ++ + {{ icon('actions-undo', 'auto') }} + Restart + + + {{ icon('actions-open', 'auto') }} + Edit Configuration + + + {{ icon('actions-download', 'auto') }} + Download + +
+ {% endframe %} + + {% frame with { color: 'dark', size: 'default', center: true } %} ++ Your Sitepackage has been successfully created and is ready for download. +
+ + {% endframe %} + +{% endblock %} diff --git a/tests/Functional/Controller/Web/DefaultControllerTest.php b/tests/Functional/Controller/Web/DefaultControllerTest.php index c75f4e1b..5c6d5679 100644 --- a/tests/Functional/Controller/Web/DefaultControllerTest.php +++ b/tests/Functional/Controller/Web/DefaultControllerTest.php @@ -46,7 +46,7 @@ public function webDefault(): void { $this->client->request('GET', '/'); self::assertResponseIsSuccessful(); - self::assertSelectorTextContains('h1', 'Build Blazingly'); + self::assertSelectorTextContains('div.frame-container:nth-child(2) > div:nth-child(1) > h1:nth-child(1)', 'Build Blazingly'); self::assertSelectorTextContains('#download-community-1 .btn', 'Get version 10'); self::assertSelectorTextContains('#download-community-2 .btn', 'Get version 9'); self::assertSelectorTextContains('#download-elts-1 .btn-primary', 'Buy ELTS'); @@ -70,7 +70,7 @@ public function webVersionSprint(): void { $this->client->request('GET', '/version/10'); self::assertResponseIsSuccessful(); - self::assertSelectorTextContains('h1', 'TYPO3 10'); + self::assertSelectorTextContains('div.frame-container:nth-child(2) > div:nth-child(1) > h1:nth-child(1)', 'TYPO3 10'); } /** @@ -80,7 +80,7 @@ public function webVersionSpecific(): void { $this->client->request('GET', '/version/10.0.0'); self::assertResponseIsSuccessful(); - self::assertSelectorTextContains('h1', '(10.0.0)'); + self::assertSelectorTextContains('div.frame-container:nth-child(2) > div:nth-child(1) > h1:nth-child(1)', '(10.0.0)'); self::assertSelectorNotExists('#notice-elts'); self::assertSelectorExists('#accordion-download'); } @@ -92,7 +92,7 @@ public function webVersionElts(): void { $this->client->request('GET', '/version/6.2'); self::assertResponseIsSuccessful(); - self::assertSelectorTextContains('h1', '(6.2.23 ELTS)'); + self::assertSelectorTextContains('div.frame-container:nth-child(2) > div:nth-child(1) > h1:nth-child(1)', '(6.2.23 ELTS)'); self::assertSelectorExists('#notice-elts'); self::assertSelectorNotExists('#accordion-download'); } @@ -104,7 +104,7 @@ public function webVersionBeforeElts(): void { $this->client->request('GET', '/version/6.2.0'); self::assertResponseIsSuccessful(); - self::assertSelectorTextContains('h1', '(6.2.0)'); + self::assertSelectorTextContains('div.frame-container:nth-child(2) > div:nth-child(1) > h1:nth-child(1)', '(6.2.0)'); self::assertSelectorExists('#notice-elts'); self::assertSelectorExists('#accordion-download'); } @@ -116,7 +116,7 @@ public function webVersionOutdated(): void { $this->client->request('GET', '/version/4.5.0'); self::assertResponseIsSuccessful(); - self::assertSelectorTextContains('h1', '(4.5.0)'); + self::assertSelectorTextContains('div.frame-container:nth-child(2) > div:nth-child(1) > h1:nth-child(1)', '(4.5.0)'); self::assertSelectorExists('#notice-outdated'); self::assertSelectorExists('#accordion-download'); } @@ -128,7 +128,7 @@ public function webVersionOutdatedElts(): void { $this->client->request('GET', '/version/4.5'); self::assertResponseIsSuccessful(); - self::assertSelectorTextContains('h1', '(4.5.23 ELTS)'); + self::assertSelectorTextContains('div.frame-container:nth-child(2) > div:nth-child(1) > h1:nth-child(1)', '(4.5.23 ELTS)'); self::assertSelectorExists('#notice-outdated'); self::assertSelectorNotExists('#accordion-download'); } @@ -150,7 +150,7 @@ public function weReleaseNotesSprint(): void { $this->client->request('GET', '/release-notes/10'); self::assertResponseIsSuccessful(); - self::assertSelectorTextContains('h1', '10.0.5'); + self::assertSelectorTextContains('div.frame-container:nth-child(2) > div:nth-child(1) > h1:nth-child(1)', '10.0.5'); } /** @@ -160,7 +160,7 @@ public function webReleaseNotesSpecific(): void { $this->client->request('GET', '/release-notes/10.0.0'); self::assertResponseIsSuccessful(); - self::assertSelectorTextContains('h1', '10.0.0'); + self::assertSelectorTextContains('div.frame-container:nth-child(2) > div:nth-child(1) > h1:nth-child(1)', '10.0.0'); self::assertSelectorNotExists('#notice-elts'); } @@ -171,7 +171,7 @@ public function webReleaseNotesElts(): void { $this->client->request('GET', '/release-notes/6.2'); self::assertResponseIsSuccessful(); - self::assertSelectorTextContains('h1', '6.2.23 ELTS'); + self::assertSelectorTextContains('div.frame-container:nth-child(2) > div:nth-child(1) > h1:nth-child(1)', '6.2.23 ELTS'); self::assertSelectorExists('#notice-elts'); } @@ -182,7 +182,7 @@ public function webReleaseNotesBeforeElts(): void { $this->client->request('GET', '/release-notes/6.2.0'); self::assertResponseIsSuccessful(); - self::assertSelectorTextContains('h1', '6.2.0'); + self::assertSelectorTextContains('div.frame-container:nth-child(2) > div:nth-child(1) > h1:nth-child(1)', '6.2.0'); self::assertSelectorExists('#notice-elts'); } @@ -193,7 +193,7 @@ public function webReleaseNotesOutdated(): void { $this->client->request('GET', '/release-notes/4.5.0'); self::assertResponseIsSuccessful(); - self::assertSelectorTextContains('h1', '4.5.0'); + self::assertSelectorTextContains('div.frame-container:nth-child(2) > div:nth-child(1) > h1:nth-child(1)', '4.5.0'); self::assertSelectorExists('#notice-outdated'); } @@ -204,7 +204,7 @@ public function webReleaseNotesOutdatedElts(): void { $this->client->request('GET', '/release-notes/4.5'); self::assertResponseIsSuccessful(); - self::assertSelectorTextContains('h1', '4.5.23 ELTS'); + self::assertSelectorTextContains('div.frame-container:nth-child(2) > div:nth-child(1) > h1:nth-child(1)', '4.5.23 ELTS'); self::assertSelectorExists('#notice-outdated'); } } diff --git a/tmp/.gitkeep b/tmp/.gitkeep deleted file mode 100644 index e69de29b..00000000 diff --git a/tmp/base-packages/.gitignore b/tmp/base-packages/.gitignore new file mode 100644 index 00000000..a68d087b --- /dev/null +++ b/tmp/base-packages/.gitignore @@ -0,0 +1,2 @@ +/* +!/.gitignore