From bd75e038fb3773154ec32dde88786a55dd6297a7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 4 Sep 2024 06:15:54 +0200 Subject: [PATCH 01/17] Bump actions/download-artifact from 3 to 4.1.7 in /.github/workflows (#211) Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 3 to 4.1.7. - [Release notes](https://github.com/actions/download-artifact/releases) - [Commits](https://github.com/actions/download-artifact/compare/v3...v4.1.7) --- updated-dependencies: - dependency-name: actions/download-artifact dependency-type: direct:production ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- .github/workflows/benchmark.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/benchmark.yml b/.github/workflows/benchmark.yml index a53624a7..86bfecf8 100644 --- a/.github/workflows/benchmark.yml +++ b/.github/workflows/benchmark.yml @@ -107,7 +107,7 @@ jobs: - # https://github.com/actions/download-artifact name: Retrieve PHPBench baseline results - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4.1.7 with: name: "PHPBench-Baseline" path: ".phpbench/" From 70c2d72da2f2993e5ebe7cc3ff691d1b183b9b36 Mon Sep 17 00:00:00 2001 From: Laurent Laville Date: Sun, 8 Sep 2024 05:00:10 +0000 Subject: [PATCH 02/17] prettify BOX config files --- box.json | 5 ++++- box.json.dist | 27 +++++++++++++++++++++------ 2 files changed, 25 insertions(+), 7 deletions(-) diff --git a/box.json b/box.json index c5d8c2d7..559a6f6c 100644 --- a/box.json +++ b/box.json @@ -11,5 +11,8 @@ ], "force-autodiscovery": true, "exclude-dev-files": false, - "files": ["autoload.php", "phplint.php"] + "files": [ + "autoload.php", + "phplint.php" + ] } diff --git a/box.json.dist b/box.json.dist index 563e4c5f..45b02bad 100644 --- a/box.json.dist +++ b/box.json.dist @@ -11,11 +11,26 @@ ], "force-autodiscovery": true, "exclude-dev-files": false, - "files": ["autoload.php", "phplint.php"], - "stub": "stub.php", - "files-bin": ["sbom.json", "console.txt"], + "files": [ + "autoload.php", + "phplint.php" + ], + "files-bin": [ + "console-table.txt", + "plain.txt", + "sbom.json", + ".box.manifests.bin" + ], "map": [ - { "console.txt": ".box.manifests/console.txt" }, - { "sbom.json": ".box.manifests/sbom.json" } - ] + { + "console-table.txt": ".box.manifests/console-table.txt" + }, + { + "plain.txt": ".box.manifests/plain.txt" + }, + { + "sbom.json": ".box.manifests/sbom.json" + } + ], + "stub": "stub.php" } From 28ce07f08c28148c19739912e0fa7357a30369bc Mon Sep 17 00:00:00 2001 From: Laurent Laville Date: Sun, 8 Sep 2024 05:01:23 +0000 Subject: [PATCH 03/17] upgrade release workflow to be able to run Box Manifest v4 --- .github/workflows/release.yml | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 9312e41a..83e41398 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -49,19 +49,19 @@ jobs: composer-options: "--prefer-dist" - # https://github.com/llaville/box-manifest - name: Download BOX Manifest Artifact - run: | - curl -Ls https://github.com/llaville/box-manifest/releases/latest/download/box-manifest.phar -o /usr/local/bin/box-manifest - chmod +x /usr/local/bin/box-manifest + name: Download BOX Manifest Artifact + env: + BOX_MANIFEST_VERSION: "4.0.0-rc.1" + run: | + curl -Ls "https://github.com/llaville/box-manifest/releases/download/$BOX_MANIFEST_VERSION/box-manifest.phar" -o /usr/local/bin/box-manifest + chmod +x /usr/local/bin/box-manifest - # https://github.com/llaville/box-manifest - name: Build Release Artifact - run: | - box-manifest manifest:build --ansi -vv -c box.json --output-file=sbom.json - box-manifest manifest:build --ansi -vv -c box.json --output-file=console.txt --format console - box-manifest manifest:stub --ansi -vv -c box.json --output-file=stub.php --resource console.txt --resource sbom.json - box compile --ansi -vv -c box.json.dist - box info --ansi ${{ github.workspace }}/bin/phplint.phar + name: Build Release Artifact + run: | + box-manifest make build stub configure -r console-table.txt -r plain.txt -r sbom.json --output-stub stub.php --output-conf box.json.dist -vvv --ansi + box compile -c box.json.dist -vvv --ansi + bin/phplint.phar --manifest - # https://github.com/softprops/action-gh-release name: Create Release from current tag From a2c53d9bf51d2888a14383fe819d389e6672952d Mon Sep 17 00:00:00 2001 From: Laurent Laville Date: Sun, 8 Sep 2024 05:04:01 +0000 Subject: [PATCH 04/17] avoid to commit assets created by BOX Manifest v4 --- .gitignore | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index 1e07ad01..9db486fe 100644 --- a/.gitignore +++ b/.gitignore @@ -6,4 +6,9 @@ composer.lock .php-cs-fixer.cache /vendor-bin/**/vendor .phpbench/ -site/ \ No newline at end of file +site/ +.box.manifests.bin +console-table.txt +plain.txt +sbom.json +stub.php From c1b32d86aa6f8c8b6722775cca8e5e223801affe Mon Sep 17 00:00:00 2001 From: Laurent Laville Date: Sun, 8 Sep 2024 05:10:54 +0000 Subject: [PATCH 05/17] force GitHub Actions to understand hyperlinks used on console-table manifest format --- .github/workflows/release.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 83e41398..25a22a22 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -58,6 +58,8 @@ jobs: - # https://github.com/llaville/box-manifest name: Build Release Artifact + env: + TERM_PROGRAM: Hyper run: | box-manifest make build stub configure -r console-table.txt -r plain.txt -r sbom.json --output-stub stub.php --output-conf box.json.dist -vvv --ansi box compile -c box.json.dist -vvv --ansi From 9cae7ab6be4e78fd9d75cfb981aa0b450031bdba Mon Sep 17 00:00:00 2001 From: Laurent Laville Date: Mon, 7 Oct 2024 12:19:05 +0000 Subject: [PATCH 06/17] temporary bump new upcoming feature release before removing hard-coded value --- src/Console/Application.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Console/Application.php b/src/Console/Application.php index 6e64b5d4..008c2b04 100644 --- a/src/Console/Application.php +++ b/src/Console/Application.php @@ -36,7 +36,7 @@ final class Application extends BaseApplication { public const NAME = 'phplint'; - public const VERSION = '9.4.1'; + public const VERSION = '9.5.0-dev'; public function __construct() { From 32a1d7363ffcb1616eed2c3bcb499531e652de2f Mon Sep 17 00:00:00 2001 From: Laurent Laville Date: Mon, 7 Oct 2024 12:20:12 +0000 Subject: [PATCH 07/17] re-apply fix for issue #192 --- Dockerfile | 7 ++++++- entrypoint.sh | 18 +++++++++++++++--- 2 files changed, 21 insertions(+), 4 deletions(-) diff --git a/Dockerfile b/Dockerfile index d084dd07..22a9f6e5 100644 --- a/Dockerfile +++ b/Dockerfile @@ -7,6 +7,11 @@ COPY entrypoint.sh /entrypoint.sh RUN chmod +x /entrypoint.sh RUN cp /usr/local/etc/php/php.ini-development /usr/local/etc/php/php.ini +# Default container directory where to mount your project source files +# GitLab uses $CI_PROJECT_DIR to identify where job runs on source files +# GitHub uses $GITHUB_WORKSPACE to identify where job runs on source files +RUN mkdir /workdir + # Create a group and user RUN addgroup appgroup && adduser appuser -D -G appgroup @@ -16,7 +21,7 @@ USER appuser # Install Composer v2 then overtrue/phplint package COPY --from=composer/composer:2-bin /composer /usr/bin/composer ENV COMPOSER_ALLOW_SUPERUSER 1 -RUN composer global require --no-progress overtrue/phplint 9.4.x-dev +RUN composer global require --no-progress overtrue/phplint 9.5.x-dev # Following recommendation at https://docs.github.com/en/actions/creating-actions/dockerfile-support-for-github-actions#workdir diff --git a/entrypoint.sh b/entrypoint.sh index 9e10dbcb..2b4dea5e 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -3,12 +3,24 @@ [ "$APP_DEBUG" == 'true' ] && set -x set -e -composer_global_home="/home/$(id -u -n)/.composer" +if [ ! -z ${GITHUB_WORKSPACE} ]; then + APP_WORKSPACE=$GITHUB_WORKSPACE +elif [ ! -z ${CI_PROJECT_DIR} ]; then + APP_WORKSPACE=$CI_PROJECT_DIR +else + APP_WORKSPACE="/workdir" +fi + +COMPOSER_HOME="/home/$(id -u -n)/.composer" if [ "$APP_DEBUG" == 'true' ] then echo "> You will act as user: $(id -u -n)" - echo "> Path to Composer home dir: ${composer_global_home}" + echo "> Your project source directory : $(ls -al $APP_WORKSPACE)" fi -"${composer_global_home}/vendor/bin/phplint" $@ +if [ ! -z ${INPUT_PATH} ]; then + sh -c "cd $APP_WORKSPACE; $COMPOSER_HOME/vendor/bin/phplint ${INPUT_PATH} ${INPUT_OPTIONS}" +else + sh -c "cd $APP_WORKSPACE; $COMPOSER_HOME/vendor/bin/phplint $*" +fi From 2a62d84f096df4a3632c8c07fde7e78ee59fab6f Mon Sep 17 00:00:00 2001 From: Laurent Laville Date: Mon, 7 Oct 2024 13:13:31 +0000 Subject: [PATCH 08/17] use stable final version 4.0.0 of BOX Manifest (and clean-up release workflow) --- .github/workflows/release.yml | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 25a22a22..49c4f26e 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -51,19 +51,16 @@ jobs: - # https://github.com/llaville/box-manifest name: Download BOX Manifest Artifact env: - BOX_MANIFEST_VERSION: "4.0.0-rc.1" + BOX_MANIFEST_VERSION: "4.0.0" run: | curl -Ls "https://github.com/llaville/box-manifest/releases/download/$BOX_MANIFEST_VERSION/box-manifest.phar" -o /usr/local/bin/box-manifest chmod +x /usr/local/bin/box-manifest - # https://github.com/llaville/box-manifest name: Build Release Artifact - env: - TERM_PROGRAM: Hyper run: | box-manifest make build stub configure -r console-table.txt -r plain.txt -r sbom.json --output-stub stub.php --output-conf box.json.dist -vvv --ansi box compile -c box.json.dist -vvv --ansi - bin/phplint.phar --manifest - # https://github.com/softprops/action-gh-release name: Create Release from current tag From fc32b73c50ffe816f2afea9dbc1ab2ef29611412 Mon Sep 17 00:00:00 2001 From: Laurent Laville Date: Mon, 7 Oct 2024 14:08:32 +0000 Subject: [PATCH 09/17] fix feature #213 --- .php-cs-fixer.release.php | 18 --- composer.json | 10 +- src/Console/Application.php | 37 +++++- .../src/ApplicationVersionFixer.php | 118 ------------------ 4 files changed, 37 insertions(+), 146 deletions(-) delete mode 100644 .php-cs-fixer.release.php delete mode 100644 vendor-bin/php-cs-fixer/src/ApplicationVersionFixer.php diff --git a/.php-cs-fixer.release.php b/.php-cs-fixer.release.php deleted file mode 100644 index e0743c18..00000000 --- a/.php-cs-fixer.release.php +++ /dev/null @@ -1,18 +0,0 @@ -registerCustomFixers([ - new ApplicationVersionFixer(), - ]) - ->setRules([ - ApplicationVersionFixer::name() => true, - ]) - ->setFinder( - PhpCsFixer\Finder::create() - ->in([__DIR__.'/src/Console']) - ) -; diff --git a/composer.json b/composer.json index 7d7b9cfa..e6588bb9 100644 --- a/composer.json +++ b/composer.json @@ -25,6 +25,7 @@ "ext-dom": "*", "ext-json": "*", "ext-mbstring": "*", + "composer-runtime-api": "^2.0", "symfony/cache": "^6.4 || ^7.0", "symfony/console": "^6.4 || ^7.0", "symfony/event-dispatcher": "^6.4 || ^7.0", @@ -59,13 +60,10 @@ "pre-commit": [ "composer style:fix", "composer code:check" - ], - "pre-push": [ - "composer qa:check" ] }, "branch-alias": { - "dev-main": "9.4.x-dev" + "dev-main": "9.5.x-dev" } }, "scripts": { @@ -81,8 +79,6 @@ "@composer bin all install --ansi" ], "cghooks": "vendor/bin/cghooks", - "qa:check": "vendor/bin/php-cs-fixer fix --config=.php-cs-fixer.release.php --using-cache=no --verbose --ansi --diff --dry-run", - "qa:fix": "vendor/bin/php-cs-fixer fix --config=.php-cs-fixer.release.php --using-cache=no --verbose --ansi", "style:check": "vendor/bin/php-cs-fixer fix --config=.php-cs-fixer.dist.php --using-cache=no --verbose --ansi --diff --dry-run", "style:fix": "vendor/bin/php-cs-fixer fix --config=.php-cs-fixer.dist.php --using-cache=no --verbose --ansi", "tests:unit": "vendor/bin/phpunit --testsuite=cache,configuration,finder", @@ -94,8 +90,6 @@ "minimum-stability": "dev", "prefer-stable": true, "scripts-descriptions": { - "qa:check": "Run QA style checks before pushing new tag and releasing a new version (only dry run - no fixing!).", - "qa:fix": "Run QA style checks and fix violations.", "style:check": "Run style checks (only dry run - no fixing!).", "style:fix": "Run style checks and fix violations.", "tests:unit": "Run unit tests on following components: cache, configuration, finder", diff --git a/src/Console/Application.php b/src/Console/Application.php index 008c2b04..341013b2 100644 --- a/src/Console/Application.php +++ b/src/Console/Application.php @@ -13,6 +13,8 @@ namespace Overtrue\PHPLint\Console; +use Composer\InstalledVersions; +use OutOfBoundsException; use Overtrue\PHPLint\Helper\DebugFormatterHelper; use Overtrue\PHPLint\Helper\ProcessHelper; use Overtrue\PHPLint\Output\ConsoleOutput; @@ -26,6 +28,7 @@ use function array_keys; use function in_array; +use function sprintf; use const STDOUT; @@ -36,11 +39,12 @@ final class Application extends BaseApplication { public const NAME = 'phplint'; - public const VERSION = '9.5.0-dev'; + + private const PACKAGE_NAME = 'overtrue/phplint'; public function __construct() { - parent::__construct(self::NAME, self::VERSION); + parent::__construct(self::NAME, self::getPrettyVersion()); } public function run(InputInterface $input = null, OutputInterface $output = null): int @@ -69,4 +73,33 @@ protected function getCommandName(InputInterface $input): ?string $name = parent::getCommandName($input); return in_array($name, array_keys(parent::all())) ? $name : null; } + + private static function getPrettyVersion(): string + { + foreach (InstalledVersions::getAllRawData() as $installed) { + if (!isset($installed['versions'][self::PACKAGE_NAME])) { + continue; + } + + $version = $installed['versions'][self::PACKAGE_NAME]['pretty_version'] + ?? $installed['versions'][self::PACKAGE_NAME]['version'] + ?? 'dev' + ; + + $aliases = $installed['versions'][self::PACKAGE_NAME]['aliases'] ?? []; + + $reference = $installed['versions'][self::PACKAGE_NAME]['reference']; + if (null === $reference) { + return sprintf('%s', $aliases[0] ?? $version); + } + + return sprintf( + '%s@%s', + $aliases[0] ?? $version, + substr($reference, 0, 7) + ); + } + + throw new OutOfBoundsException(sprintf('Package "%s" is not installed', self::PACKAGE_NAME)); + } } diff --git a/vendor-bin/php-cs-fixer/src/ApplicationVersionFixer.php b/vendor-bin/php-cs-fixer/src/ApplicationVersionFixer.php deleted file mode 100644 index 3b1bf0a7..00000000 --- a/vendor-bin/php-cs-fixer/src/ApplicationVersionFixer.php +++ /dev/null @@ -1,118 +0,0 @@ -isAllTokenKindsFound([T_CLASS, T_CONSTANT_ENCAPSED_STRING]); - } - - /** - * @inheritDoc - */ - public function isRisky(): bool - { - return false; - } - - protected function applyFix(SplFileInfo $file, Tokens $tokens): void - { - foreach ($tokens as $index => $token) { - if (!$token->isGivenKind(T_CONSTANT_ENCAPSED_STRING)) { - continue; - } - if (!$this->isVersionConst($tokens, $index)) { - continue; - } - - $tag = @exec('git describe --tags --abbrev=0 2>&1'); - - if ($token->getContent() !== $tag) { - $tokens[$index] = new Token([$token->getId(), "'$tag'"]); - } - } - } - - private function isVersionConst(Tokens $tokens, int $index): bool - { - $prevTokenIndex = $tokens->getPrevMeaningfulToken($index); - if (!$tokens[$prevTokenIndex]->equals('=')) { - return false; - } - - $constantNamePosition = $tokens->getPrevMeaningfulToken($prevTokenIndex); - return $tokens[$constantNamePosition]->equals([T_STRING, 'VERSION']); - } - - /** - * @inheritDoc - */ - public function getDefinition(): FixerDefinitionInterface - { - return new FixerDefinition( - 'Application::VERSION constant value must match the current git tag.', - [] - ); - } - - /** - * @inheritDoc - */ - public function getName(): string - { - return self::name(); - } - - public static function name(): string - { - return 'OvertrueCsFixer/application_version'; - } - - /** - * @inheritDoc - */ - public function supports(SplFileInfo $file): bool - { - return $file->getBasename() === 'Application.php'; - } - - /** - * @inheritDoc - */ - public function getPriority(): int - { - return 0; - } -} From 93e95e85b7d1d8058938499b8f9b5a580dcb827c Mon Sep 17 00:00:00 2001 From: Laurent Laville Date: Mon, 7 Oct 2024 14:30:38 +0000 Subject: [PATCH 10/17] fix BOX config files to avoid issue with manifests (see https://github.com/llaville/box-manifest/issues/13) --- box.json | 1 + box.json.dist | 1 + 2 files changed, 2 insertions(+) diff --git a/box.json b/box.json index 559a6f6c..3abdddbb 100644 --- a/box.json +++ b/box.json @@ -10,6 +10,7 @@ "with this source code in the file LICENSE." ], "force-autodiscovery": true, + "dump-autoload": true, "exclude-dev-files": false, "files": [ "autoload.php", diff --git a/box.json.dist b/box.json.dist index 45b02bad..b707158b 100644 --- a/box.json.dist +++ b/box.json.dist @@ -10,6 +10,7 @@ "with this source code in the file LICENSE." ], "force-autodiscovery": true, + "dump-autoload": true, "exclude-dev-files": false, "files": [ "autoload.php", From 8d9a058d36821d6ef0570b921757cca041131e64 Mon Sep 17 00:00:00 2001 From: Laurent Laville Date: Mon, 7 Oct 2024 14:54:08 +0000 Subject: [PATCH 11/17] use PHPUnit defined by vendor-bin --- .github/workflows/lint.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 54493471..f76c7c65 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -30,12 +30,11 @@ jobs: uses: actions/checkout@v4 - # https://github.com/shivammathur/setup-php - name: Setup PHP runtime for PHPUnit 10 + name: Setup PHP runtime uses: shivammathur/setup-php@v2 with: php-version: "${{ matrix.php-version }}" coverage: "none" - tools: phpunit:10.5 - # https://github.com/ramsey/composer-install name: Install Composer dependencies @@ -45,4 +44,4 @@ jobs: - # https://github.com/sebastianbergmann/phpunit/tree/10.5 name: Unit tests with PHPUnit 10 - run: phpunit --no-progress --testdox --do-not-cache-result + run: vendor/bin/phpunit --no-progress --testdox --do-not-cache-result From 88342d9fdd02e569b25b16f20f9188d115f5e01e Mon Sep 17 00:00:00 2001 From: Laurent Laville Date: Mon, 7 Oct 2024 16:27:29 +0000 Subject: [PATCH 12/17] drop support to PHP 8.1 --- .github/workflows/lint.yml | 2 -- composer.json | 16 ++++++++-------- docs/usage/github-actions.md | 2 -- 3 files changed, 8 insertions(+), 12 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index f76c7c65..d554b12f 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -16,11 +16,9 @@ jobs: matrix: operating-system: - - "ubuntu-20.04" - "ubuntu-22.04" php-version: - - "8.1" - "8.2" - "8.3" diff --git a/composer.json b/composer.json index e6588bb9..65d39905 100644 --- a/composer.json +++ b/composer.json @@ -21,18 +21,18 @@ } ], "require": { - "php": "^8.1", + "php": "^8.2", "ext-dom": "*", "ext-json": "*", "ext-mbstring": "*", "composer-runtime-api": "^2.0", - "symfony/cache": "^6.4 || ^7.0", - "symfony/console": "^6.4 || ^7.0", - "symfony/event-dispatcher": "^6.4 || ^7.0", - "symfony/finder": "^6.4 || ^7.0", - "symfony/options-resolver": "^6.4 || ^7.0", - "symfony/process": "^6.4 || ^7.0", - "symfony/yaml": "^6.4 || ^7.0" + "symfony/cache": "^7.0", + "symfony/console": "^7.0", + "symfony/event-dispatcher": "^7.0", + "symfony/finder": "^7.0", + "symfony/options-resolver": "^7.0", + "symfony/process": "^7.0", + "symfony/yaml": "^7.0" }, "require-dev": { "php-parallel-lint/php-console-highlighter": "^1.0", diff --git a/docs/usage/github-actions.md b/docs/usage/github-actions.md index f280c3bc..5dc09b4f 100644 --- a/docs/usage/github-actions.md +++ b/docs/usage/github-actions.md @@ -36,11 +36,9 @@ jobs: matrix: operating-system: - - "ubuntu-20.04" - "ubuntu-22.04" php-version: - - "8.1" - "8.2" - "8.3" From 7697ce146e0e940f4372ce4f3fd94eaa3c49decc Mon Sep 17 00:00:00 2001 From: Laurent Laville Date: Tue, 8 Oct 2024 03:50:58 +0000 Subject: [PATCH 13/17] prepare feature release 9.5.0 --- .changes/9.5.0.md | 13 +++++++++++++ CHANGELOG.md | 13 +++++++++++++ README.md | 1 + docs/installation.md | 4 ++-- 4 files changed, 29 insertions(+), 2 deletions(-) create mode 100644 .changes/9.5.0.md diff --git a/.changes/9.5.0.md b/.changes/9.5.0.md new file mode 100644 index 00000000..23fed13f --- /dev/null +++ b/.changes/9.5.0.md @@ -0,0 +1,13 @@ + +## 9.5.0 - 2024-10-08 + +### Changed + +- drop support to PHP 8.1 +- [#213](https://github.com/overtrue/phplint/issues/213) : Get application version from Composer Runtime API + +### Fixed + +- [#192](https://github.com/overtrue/phplint/issues/192) : The "-x" option does not exist. + +**Full Changelog**: [9.4.1...9.5.0](https://github.com/overtrue/phplint/compare/9.4.1...9.5.0) diff --git a/CHANGELOG.md b/CHANGELOG.md index fb84b62a..a275aaad 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,19 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html), and is generated by [Changie](https://github.com/miniscruff/changie). +## 9.5.0 - 2024-10-08 + +### Changed + +- drop support to PHP 8.1 +- [#213](https://github.com/overtrue/phplint/issues/213) : Get application version from Composer Runtime API + +### Fixed + +- [#192](https://github.com/overtrue/phplint/issues/192) : The "-x" option does not exist. + +**Full Changelog**: [9.4.1...9.5.0](https://github.com/overtrue/phplint/compare/9.4.1...9.5.0) + ## 9.4.1 - 2024-07-05 > [!NOTE] diff --git a/README.md b/README.md index 20a119a7..d2917e73 100644 --- a/README.md +++ b/README.md @@ -13,6 +13,7 @@ | Version | Status | Requirements | |:--------|:------------------------------------------|:---------------| | **9.x** | **Active development** | **PHP >= 8.1** | +| 9.5 | Active support | PHP >= 8.2 | | 9.4 | Active support | PHP >= 8.1 | | 9.3 | Active support | PHP >= 8.1 | | 9.2 | Active support | PHP >= 8.1 | diff --git a/docs/installation.md b/docs/installation.md index d48af523..2bcd2f06 100644 --- a/docs/installation.md +++ b/docs/installation.md @@ -48,7 +48,7 @@ You can also install `phplint` locally to your project with [Phive][phive] and c ```xml - + ``` @@ -61,7 +61,7 @@ phive install --force-accept-unsigned You can install `phplint` with [Composer][composer] ```shell -composer global require overtrue/phplint +composer global require overtrue/phplint ^9.5 ``` If you cannot install it because of a dependency conflict, or you prefer to install it for your project, we recommend From e8908f002882e5afb4cd989dcbfc0055fa9c3c8a Mon Sep 17 00:00:00 2001 From: Laurent Laville Date: Tue, 8 Oct 2024 03:58:44 +0000 Subject: [PATCH 14/17] bump docker/setup-qemu-action from v2 to v3 (Node 20 replace Node 16 deprecated) --- .github/workflows/docker.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index f65daabe..0bf1d874 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -24,9 +24,9 @@ jobs: - # https://github.com/actions/checkout name: Checkout code uses: actions/checkout@v4 - - + - # https://github.com/docker/setup-qemu-action name: Set up QEMU - uses: docker/setup-qemu-action@v2 + uses: docker/setup-qemu-action@v3 - name: Set up Docker Buildx uses: docker/setup-buildx-action@v2 From e24b71c56fa51fa64dcfdaa830a7c722f4354ff4 Mon Sep 17 00:00:00 2001 From: Laurent Laville Date: Tue, 8 Oct 2024 04:00:33 +0000 Subject: [PATCH 15/17] bump docker/setup-buildx-action from v2 to v3 (Node 20 replace Node 16 deprecated) --- .github/workflows/docker.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index 0bf1d874..e319ff98 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -27,9 +27,9 @@ jobs: - # https://github.com/docker/setup-qemu-action name: Set up QEMU uses: docker/setup-qemu-action@v3 - - + - # https://github.com/docker/setup-buildx-action name: Set up Docker Buildx - uses: docker/setup-buildx-action@v2 + uses: docker/setup-buildx-action@v3 - name: Login to DockerHub uses: docker/login-action@v2 From f661072fb798496e8dd12cead949eedf25765858 Mon Sep 17 00:00:00 2001 From: Laurent Laville Date: Tue, 8 Oct 2024 04:01:57 +0000 Subject: [PATCH 16/17] bump docker/login-action from v2 to v3 (Node 20 replace Node 16 deprecated) --- .github/workflows/docker.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index e319ff98..0437043c 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -30,9 +30,9 @@ jobs: - # https://github.com/docker/setup-buildx-action name: Set up Docker Buildx uses: docker/setup-buildx-action@v3 - - + - # https://github.com/docker/login-action name: Login to DockerHub - uses: docker/login-action@v2 + uses: docker/login-action@v3 with: username: ${{ secrets.DOCKER_USERNAME }} password: ${{ secrets.DOCKER_PASSWORD }} From c25c75c76379d768661891d8f1cd0f047ce54e1e Mon Sep 17 00:00:00 2001 From: Laurent Laville Date: Tue, 8 Oct 2024 04:04:18 +0000 Subject: [PATCH 17/17] bump docker/build-push-action from v3 to v6 (Node 20 replace Node 16 deprecated) --- .github/workflows/docker.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index 0437043c..fdc2356c 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -36,9 +36,9 @@ jobs: with: username: ${{ secrets.DOCKER_USERNAME }} password: ${{ secrets.DOCKER_PASSWORD }} - - + - # https://github.com/docker/build-push-action name: Build and push Docker images - uses: docker/build-push-action@v3 + uses: docker/build-push-action@v6 with: push: true tags: overtrue/phplint:${{ env.DOCKER_BUILD_TAG }}