Skip to content

Commit 7c8fcc2

Browse files
author
DKravtsov
committed
phpcpd 9.0.0 release.
1 parent 9dce0f0 commit 7c8fcc2

40 files changed

Lines changed: 841 additions & 925 deletions

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ jobs:
4747
strategy:
4848
matrix:
4949
operating-system: [ 'ubuntu-latest' ]
50-
php-versions: [ '8.3', '8.4', '8.5' ]
50+
php-versions: [ '8.4', '8.5' ]
5151
steps:
5252
- name: Setup PHP
5353
uses: shivammathur/setup-php@v2

.idea/php.xml

Lines changed: 7 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

ChangeLog.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,15 @@
22

33
All notable changes in PHPCPD are documented in this file using the [Keep a CHANGELOG](http://keepachangelog.com/) principles.
44

5+
## [9.0.0] - 2026-03-08
6+
7+
### Updated
8+
9+
* Updated the minimum PHP requirement to version 8.4, meaning this tool is no longer supported on PHP 8.3.
10+
* Updated the Suffix Tree engine to use PHP native arrays, completely eliminating hash collisions, achieving zero memory bloat, and boosting performance by up to 17%.
11+
* Updated the PMD-CPD XML report generator to use the modern Dom\XMLDocument extension.
12+
* Updated Composer dependencies and improved the development environment for the support team.
13+
514
## [8.3.0] - 2026-02-16
615

716
### Added

Dockerfile

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,9 @@ RUN apt-get update && apt-get upgrade -y && apt-get install -y \
5151
&& rm -rf /var/lib/apt/lists/* \
5252
&& apt-get clean
5353

54+
# Pull the PHP extension installer from the official image
55+
COPY --from=mlocati/php-extension-installer:latest /usr/bin/install-php-extensions /usr/local/bin/
56+
5457
# create document root, fix permissions for www-data user and change owner to www-data
5558
RUN mkdir -p $APP_HOME/public && \
5659
mkdir -p /home/$USERNAME && chown $USERNAME:$USERNAME /home/$USERNAME \
@@ -63,9 +66,13 @@ COPY ./docker/$BUILD_ARGUMENT_ENV/www.conf /usr/local/etc/php-fpm.d/www.conf
6366
COPY ./docker/$BUILD_ARGUMENT_ENV/php.ini /usr/local/etc/php/php.ini
6467

6568
# install Xdebug in case dev environment
66-
COPY ./docker/general/do_we_need_xdebug.sh /tmp/
6769
COPY ./docker/dev/xdebug-${XDEBUG_CONFIG}.ini /tmp/xdebug.ini
68-
RUN chmod u+x /tmp/do_we_need_xdebug.sh && /tmp/do_we_need_xdebug.sh
70+
RUN if [ "$ENV" = "dev" ] || [ "$ENV" = "test" ]; then \
71+
install-php-extensions xdebug-${XDEBUG_VERSION} && \
72+
mv /tmp/xdebug.ini /usr/local/etc/php/conf.d/xdebug.ini; \
73+
else \
74+
rm /tmp/xdebug.ini; \
75+
fi
6976

7077
# install composer
7178
COPY --from=composer:latest /usr/bin/composer /usr/bin/composer

build.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<project name="phpcpd" default="setup">
33
<property name="basedir" value="." override="false"/>
4-
<property name="version" value="8.3.0" override="false"/>
4+
<property name="version" value="9.0.0" override="false"/>
55
<target name="setup" depends="clean,install-dependencies"/>
66

77
<target name="clean" description="Cleanup build artifacts">

build/phar-autoload.php.in

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@
33

44
declare(strict_types=1);
55

6-
if (version_compare('8.3.0', PHP_VERSION, '>')) {
6+
if (version_compare('8.4.0', PHP_VERSION, '>')) {
77
fwrite(
88
STDERR,
99
sprintf(
10-
'This version of PHPCPD requires PHP 8.3 (or later).' . PHP_EOL .
10+
'This version of PHPCPD requires PHP 8.4 (or later).' . PHP_EOL .
1111
'You are using PHP %s%s.' . PHP_EOL,
1212
PHP_VERSION,
1313
defined('PHP_BINARY') ? ' (' . PHP_BINARY . ')' : ''
@@ -54,6 +54,6 @@ if (isset($_SERVER['argv'][1]) && $_SERVER['argv'][1] === '--manifest') {
5454
exit;
5555
}
5656

57-
exit((new \Systemsdk\PhpCPD\Cli\Application())->run($_SERVER['argv']));
57+
exit(new \Systemsdk\PhpCPD\Cli\Application()->run($_SERVER['argv']));
5858

5959
__HALT_COMPILER();

composer.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -30,16 +30,16 @@
3030
}
3131
],
3232
"require": {
33-
"php": ">=8.3",
33+
"php": ">=8.4",
3434
"ext-dom": "*",
3535
"ext-mbstring": "*",
36-
"sebastian/cli-parser": "^4.0",
37-
"sebastian/version": "^6.0",
38-
"phpunit/php-file-iterator": "^6.0",
39-
"phpunit/php-timer": "^8.0"
36+
"sebastian/cli-parser": "^5.0",
37+
"sebastian/version": "^7.0",
38+
"phpunit/php-file-iterator": "^7.0",
39+
"phpunit/php-timer": "^9.0"
4040
},
4141
"require-dev": {
42-
"bamarni/composer-bin-plugin": "^1.8",
42+
"bamarni/composer-bin-plugin": "^1.9",
4343
"roave/security-advisories": "dev-latest"
4444
},
4545
"config": {

0 commit comments

Comments
 (0)