Skip to content

Commit

Permalink
feature #186 Support symfony 7 (Tom32i, ogizanagi)
Browse files Browse the repository at this point in the history
This PR was merged into the 0.x-dev branch.

Discussion
----------

Support symfony 7

Support Symfony 7

Commits
-------

887f6d1 LastModifiedFetcher: suggest new process runtime error handling
6938a01 Extra tweaks
b558c7d Fix for symfony/process v7.1
92c49fa Update app dependencies
4f996e3 Fix workflow
6481e86 Updated doc to Symfony 7 and PHP 8.3
1e5f6a8 Drop php 7 support
ae0a324 Update doc
baee6b8 Fixed tests
c861917 Fixed normalizer
6458728 Updated doc
1ea4e77 Fix PHPunit version
ee65428 Update workflows
29c822d Fixing lint
539a5c6 Support symfony 7
  • Loading branch information
ogizanagi committed Apr 4, 2024
2 parents 091e668 + 887f6d1 commit 7183ad2
Show file tree
Hide file tree
Showing 132 changed files with 5,784 additions and 17,340 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/build_static.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,15 @@ jobs:
- name: 'Setup node'
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 20

- name: 'Setup PHP'
uses: shivammathur/setup-php@v2
with:
coverage: "none"
extensions: "json"
ini-values: "memory_limit=-1"
php-version: "8.1"
php-version: "8.3"

- name: 'Determine composer cache directory'
id: composer-cache
Expand Down
50 changes: 17 additions & 33 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ on:
push:
branches:
- master
pull_request: ~
pull_request:
types: [ opened, synchronize, reopened, ready_for_review ]

jobs:

Expand All @@ -24,7 +25,7 @@ jobs:
coverage: "none"
extensions: "json"
ini-values: "memory_limit=-1"
php-version: "8.1"
php-version: "8.3"

- name: 'Determine composer cache directory'
id: composer-cache
Expand Down Expand Up @@ -81,46 +82,29 @@ jobs:
fail-fast: false # don't cancel other matrix jobs on failure
matrix:
include:
# Previous PHP versions
- name: 'Test Symfony 5.4 [Linux, PHP 7.4]'
os: 'ubuntu-latest'
php: '7.4'
symfony: '5.4.*'

# Most recent, non-EOL versions
- name: 'Test Symfony 5.4 [Linux, PHP 8.1]'
- name: 'Test Symfony 6.4 [Linux, PHP 8.2]'
os: 'ubuntu-latest'
php: '8.1'
symfony: '5.4.*'

- name: 'Test Symfony 5.4 [Windows, PHP 8.0]'
os: 'windows-latest'
php: '8.0'
symfony: '5.4.*'

- name: 'Test Symfony 6.0 [Linux, PHP 8.1]'
os: 'ubuntu-latest'
php: '8.1'
symfony: '6.0.*'
php: '8.2'
symfony: '6.4.*'

- name: 'Test Symfony 6.1 [Linux, PHP 8.1]'
- name: 'Test Symfony 7.0 [Linux, PHP 8.3]'
os: 'ubuntu-latest'
php: '8.1'
symfony: '6.1.*'
php: '8.3'
symfony: '7.0.*'

# Bleeding edges:
- name: 'Test Symfony 6.2 [Linux, PHP 8.1]'
- name: 'Test Symfony 7.1 [Linux, PHP 8.3]'
os: 'ubuntu-latest'
php: '8.1'
symfony: '6.2.*@dev'
php: '8.3'
symfony: '7.1.*@dev'
allow-unstable: true
allow-failure: true

- name: 'Test Symfony 6.2 [Linux, PHP 8.2]'
- name: 'Test Symfony 7.1 [Linux, PHP 8.4]'
os: 'ubuntu-latest'
php: '8.2'
symfony: '6.2.*@dev'
composer-flags: '--ignore-platform-req php'
php: '8.4'
symfony: '7.1.*@dev'
allow-unstable: true
allow-failure: true

Expand Down Expand Up @@ -181,15 +165,15 @@ jobs:
- name: 'Setup node'
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 20

- name: 'Setup PHP'
uses: shivammathur/setup-php@v2
with:
coverage: "none"
extensions: "json"
ini-values: "memory_limit=-1"
php-version: "8.1"
php-version: "8.3"

- name: 'Determine composer cache directory'
id: composer-cache
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/dist.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
- name: 'Setup node'
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 20

- name: 'Generate dist'
run: make dist.install dist
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/update-dist-deps.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
- name: 'Setup node'
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 20

- name: 'Update dist dependencies'
run: make dist.update
Expand Down
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
20
3 changes: 2 additions & 1 deletion .php-cs-fixer.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@
This file is part of the "StenopePHP/Stenope" bundle.
@author Thomas Jarrand <[email protected]>
@author Maxime Steinhausser <[email protected]>
EOF;

$finder = PhpCsFixer\Finder::create()
$finder = (new PhpCsFixer\Finder())
->in([__DIR__])
->exclude('doc/app')
->exclude('tests/fixtures/app/var')
Expand Down
2 changes: 1 addition & 1 deletion .php-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.1
8.3
46 changes: 17 additions & 29 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
include .make/help.mk
include .make/text.mk

PHP_CS_FIXER_VERSION=v3.13.0
PHP_CS_FIXER_VERSION=v3.52.1

##########
# Colors #
Expand All @@ -15,13 +15,6 @@ COLOR_INFO := \033[32m
COLOR_WARNING := \033[33m
COLOR_COMMENT := \033[36m

###########
# Helpers #
###########

php8:
@php -r "exit (PHP_MAJOR_VERSION == 8 ? 0 : 1);" || ($(call message_error, Please use PHP 8) && exit 1)

###########
# Install #
###########
Expand All @@ -37,31 +30,28 @@ install:
symfony composer config minimum-stability --unset
symfony composer update --prefer-dist

## Install - Install Symfony 5.4 deps
install.54: setup
install.54: export SYMFONY_REQUIRE = 5.4.*@dev
install.54:
rm -f composer.lock
symfony composer update

## Install - Install Symfony 6.0 deps
install.60: setup
install.60: export SYMFONY_REQUIRE = 6.0.*@dev
install.60:
## Install - Install Symfony 6.4 deps
install.64: setup
install.64: export SYMFONY_REQUIRE = 6.4.*@dev
install.64:
rm -f composer.lock
symfony composer config minimum-stability dev
symfony composer update
symfony composer config minimum-stability --unset

## Install - Install Symfony 6.1 deps
install.61: setup
install.61: export SYMFONY_REQUIRE = 6.1.*@dev
install.61:
## Install - Install Symfony 7.0 deps
install.70: setup
install.70: export SYMFONY_REQUIRE = 7.0.*@dev
install.70:
rm -f composer.lock
symfony composer config minimum-stability dev
symfony composer update
symfony composer config minimum-stability --unset

## Install - Install Symfony 6.2 deps
install.62: setup
install.62: export SYMFONY_REQUIRE = 6.2.*@dev
install.62:
## Install - Install Symfony 7.1 deps
install.71: setup
install.71: export SYMFONY_REQUIRE = 7.1.*@dev
install.71:
rm -f composer.lock
symfony composer config minimum-stability dev
symfony composer update
Expand All @@ -80,12 +70,10 @@ lint.fix: lint.php-cs-fixer.fix
lint.composer:
symfony composer validate --strict

lint.php-cs-fixer: php8
lint.php-cs-fixer: php-cs-fixer.phar
lint.php-cs-fixer:
symfony php ./php-cs-fixer.phar fix --dry-run --diff

lint.php-cs-fixer.fix: php8
lint.php-cs-fixer.fix: php-cs-fixer.phar
lint.php-cs-fixer.fix:
symfony php ./php-cs-fixer.phar fix
Expand Down
1 change: 1 addition & 0 deletions bin/lint.twig.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
* This file is part of the "StenopePHP/Stenope" bundle.
*
* @author Thomas Jarrand <[email protected]>
* @author Maxime Steinhausser <[email protected]>
*/

require __DIR__ . '/../vendor/autoload.php';
Expand Down
57 changes: 29 additions & 28 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,43 +33,44 @@
},
"prefer-stable": true,
"require": {
"php": ">=7.4",
"php": "^8.1",
"ext-dom": "*",
"erusev/parsedown": "^1.7.4",
"symfony/asset": "^5.1|^6.0",
"symfony/config": "^5.1|^6.0",
"symfony/console": "^5.1|^6.0",
"symfony/css-selector": "^5.1|^6.0",
"symfony/dependency-injection": "^5.1|^6.0",
"symfony/dom-crawler": "^5.1|^6.0",
"symfony/event-dispatcher": "^5.1|^6.0",
"symfony/filesystem": "^5.1|^6.0",
"symfony/finder": "^5.1|^6.0",
"symfony/http-foundation": "^5.1|^6.0",
"symfony/http-kernel": "^5.1|^6.0",
"symfony/mime": "^5.1|^6.0",
"symfony/process": "^5.1|^6.0",
"symfony/property-access": "^5.1|^6.0",
"symfony/routing": "^5.1|^6.0",
"symfony/serializer": "^5.1|^6.0",
"symfony/stopwatch": "^5.1|^6.0",
"symfony/string": "^5.1|^6.0",
"symfony/yaml": "^5.1|^6.0",
"symfony/asset": "^6.1|^7.0",
"symfony/config": "^6.1|^7.0",
"symfony/console": "^6.1|^7.0",
"symfony/css-selector": "^6.1|^7.0",
"symfony/dependency-injection": "^6.1|^7.0",
"symfony/dom-crawler": "^6.1|^7.0",
"symfony/event-dispatcher": "^6.1|^7.0",
"symfony/filesystem": "^6.1|^7.0",
"symfony/finder": "^6.1|^7.0",
"symfony/http-foundation": "^6.1|^7.0",
"symfony/http-kernel": "^6.1|^7.0",
"symfony/mime": "^6.1|^7.0",
"symfony/process": "^6.1|^7.0",
"symfony/property-access": "^6.1|^7.0",
"symfony/routing": "^6.1|^7.0",
"symfony/serializer": "^6.1|^7.0",
"symfony/stopwatch": "^6.1|^7.0",
"symfony/string": "^6.1|^7.0",
"symfony/yaml": "^6.1|^7.0",
"twig/twig": "^2.12|^3.0"
},
"require-dev": {
"doctrine/annotations": "^1.9",
"ekino/phpstan-banned-code": "^1.0",
"fig/log-test": "^1.1",
"phpspec/prophecy-phpunit": "^2.0",
"phpstan/phpstan": "^1.6",
"psr/log": "^1",
"symfony/browser-kit": "^5.1|^6.0",
"symfony/expression-language": "^5.1|^6.0",
"symfony/framework-bundle": "^5.1|^6.0",
"phpunit/phpunit": "^9.6",
"psr/log": "^1|^2",
"symfony/browser-kit": "^6.1|^7.0",
"symfony/expression-language": "^6.1|^7.0",
"symfony/framework-bundle": "^6.1|^7.0",
"symfony/monolog-bundle": "^3.7",
"symfony/phpunit-bridge": "^5.3|^6.0",
"symfony/twig-bridge": "^5.1|^6.0",
"symfony/twig-bundle": "^5.1|^6.0"
"symfony/phpunit-bridge": "^6.1|^7.0",
"symfony/twig-bridge": "^6.1|^7.0",
"symfony/twig-bundle": "^6.1|^7.0"
},
"extra": {
"branch-alias": {
Expand Down
1 change: 1 addition & 0 deletions config/processors.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
* This file is part of the "StenopePHP/Stenope" bundle.
*
* @author Thomas Jarrand <[email protected]>
* @author Maxime Steinhausser <[email protected]>
*/

namespace Symfony\Component\DependencyInjection\Loader\Configurator;
Expand Down
1 change: 1 addition & 0 deletions config/services.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
* This file is part of the "StenopePHP/Stenope" bundle.
*
* @author Thomas Jarrand <[email protected]>
* @author Maxime Steinhausser <[email protected]>
*/

namespace Symfony\Component\DependencyInjection\Loader\Configurator;
Expand Down
1 change: 1 addition & 0 deletions config/tags.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
* This file is part of the "StenopePHP/Stenope" bundle.
*
* @author Thomas Jarrand <[email protected]>
* @author Maxime Steinhausser <[email protected]>
*/

namespace Stenope\Bundle\DependencyInjection\tags;
Expand Down
2 changes: 1 addition & 1 deletion doc/app/.nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
16
20
2 changes: 1 addition & 1 deletion doc/app/.php-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.1
8.3
34 changes: 17 additions & 17 deletions doc/app/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,30 +2,30 @@
"type": "project",
"license": "proprietary",
"require": {
"php": ">=8.1",
"php": ">=8.3",
"ext-ctype": "*",
"ext-iconv": "*",
"composer/package-versions-deprecated": "^1.11",
"phpdocumentor/reflection-docblock": "^5.2",
"stenope/stenope": "dev-master",
"symfony/asset": "^6.2",
"symfony/console": "^6.2",
"symfony/dotenv": "^6.2",
"symfony/flex": "^1.3.1",
"symfony/framework-bundle": "^6.2",
"symfony/asset": "^7.0",
"symfony/console": "^7.0",
"symfony/dotenv": "^7.0",
"symfony/flex": "^2",
"symfony/framework-bundle": "^7.0",
"symfony/monolog-bundle": "^3.7",
"symfony/runtime": "^6.2",
"symfony/twig-bundle": "^6.2",
"symfony/webpack-encore-bundle": "^1.11",
"symfony/yaml": "^6.2",
"twig/extra-bundle": "^2.12|^3.0",
"twig/twig": "^2.12|^3.0"
"symfony/runtime": "^7.0",
"symfony/twig-bundle": "^7.0",
"symfony/webpack-encore-bundle": "^2.1",
"symfony/yaml": "^7.0",
"twig/extra-bundle": "^3.0",
"twig/twig": "^3.0"
},
"require-dev": {
"symfony/debug-bundle": "^6.2",
"symfony/stopwatch": "^6.2",
"symfony/var-dumper": "^6.2",
"symfony/web-profiler-bundle": "^6.2"
"symfony/debug-bundle": "^7.0",
"symfony/stopwatch": "^7.0",
"symfony/var-dumper": "^7.0",
"symfony/web-profiler-bundle": "^7.0"
},
"config": {
"optimize-autoloader": true,
Expand Down Expand Up @@ -76,7 +76,7 @@
"extra": {
"symfony": {
"allow-contrib": false,
"require": "6.2.*"
"require": "^7.0"
}
},
"repositories": {
Expand Down
Loading

0 comments on commit 7183ad2

Please sign in to comment.