Skip to content

Commit 5eb1cc7

Browse files
committed
Dropped PHP 7 support
1 parent fe154ec commit 5eb1cc7

File tree

62 files changed

+516
-590
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

62 files changed

+516
-590
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file.
44
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
55
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
66

7+
## [Unreleased]
8+
### Removed
9+
- Dropped PHP 7 support.
10+
711
## [0.5.2] - 2021-01-14
812
### Added
913
- PHP 8.0 support.

composer.json

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,15 +16,15 @@
1616
}
1717
],
1818
"require": {
19-
"php": "^7.3 | ^8",
19+
"php": "~8.0.0 || ~8.1.0 || ~8.2.0",
2020
"ext-intl": "*",
21-
"remorhaz/php-json-data": "^0.5.3",
22-
"remorhaz/php-json-pointer": "^0.6.10"
21+
"remorhaz/php-json-data": "^0.6",
22+
"remorhaz/php-json-pointer": "^0.7"
2323
},
2424
"require-dev": {
25-
"phpunit/phpunit": "^9.5",
26-
"infection/infection": "^0.18",
27-
"squizlabs/php_codesniffer": "^3.5"
25+
"phpunit/phpunit": "^9.6.13 || ^10",
26+
"infection/infection": "^0.26.19 || ^0.27.2",
27+
"squizlabs/php_codesniffer": "^3.7.2"
2828
},
2929
"autoload": {
3030
"psr-4": {
@@ -33,7 +33,7 @@
3333
},
3434
"autoload-dev": {
3535
"psr-4": {
36-
"Remorhaz\\JSON\\Test\\Patch\\": "tests/"
36+
"Remorhaz\\JSON\\Patch\\Test\\": "tests/"
3737
}
3838
},
3939
"scripts": {
@@ -52,5 +52,10 @@
5252
"mkdir -p build/logs/infection",
5353
"vendor/bin/infection --threads=4 --coverage=build/logs --no-progress --skip-initial-tests"
5454
]
55+
},
56+
"config": {
57+
"allow-plugins": {
58+
"infection/extension-installer": true
59+
}
5560
}
5661
}

docker-compose.yml

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,6 @@ version: '3'
22

33
services:
44
php:
5-
build:
6-
context: .
7-
dockerfile: php-7.3.Dockerfile
8-
volumes:
9-
- .:/app
10-
working_dir: /app
11-
php7.4:
12-
build:
13-
context: .
14-
dockerfile: php-7.4.Dockerfile
15-
volumes:
16-
- .:/app
17-
working_dir: /app
18-
php8.0:
195
build:
206
context: .
217
dockerfile: php-8.0.Dockerfile

php-7.3.Dockerfile

Lines changed: 0 additions & 17 deletions
This file was deleted.

php-7.4.Dockerfile

Lines changed: 0 additions & 17 deletions
This file was deleted.

php-8.0.Dockerfile

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,15 @@ RUN apt-get update && apt-get install -y \
44
zip \
55
git \
66
libicu-dev && \
7-
pecl install xdebug && \
7+
pecl install -o -f xdebug && \
88
docker-php-ext-enable xdebug && \
99
docker-php-ext-configure intl --enable-intl && \
10-
docker-php-ext-install intl && \
10+
docker-php-ext-install intl pcntl && \
1111
echo "xdebug.mode = develop,coverage,debug" >> "$PHP_INI_DIR/conf.d/docker-php-ext-xdebug.ini"
1212

1313
ENV COMPOSER_ALLOW_SUPERUSER=1 \
1414
COMPOSER_PROCESS_TIMEOUT=1200
1515

1616
RUN curl --silent --show-error https://getcomposer.org/installer | php -- \
17-
--install-dir=/usr/bin --filename=composer
17+
--install-dir=/usr/bin --filename=composer && \
18+
git config --global --add safe.directory '*'

phpcs.xml.dist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
<arg name="colors"/>
99

10-
<rule ref="PSR2">
10+
<rule ref="PSR12">
1111
</rule>
1212

1313
<rule ref="PSR1.Methods.CamelCapsMethodName.NotCamelCaps">

src/Exception/ExceptionInterface.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<?php
2+
23
declare(strict_types=1);
34

45
namespace Remorhaz\JSON\Patch\Exception;

src/Operation/AddOperation.php

Lines changed: 4 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<?php
2+
23
declare(strict_types=1);
34

45
namespace Remorhaz\JSON\Patch\Operation;
@@ -9,21 +10,11 @@
910

1011
final class AddOperation implements OperationInterface
1112
{
12-
13-
private $index;
14-
15-
private $pathPointer;
16-
17-
private $value;
18-
1913
public function __construct(
20-
int $index,
21-
PointerQueryInterface $pathPointer,
22-
NodeValueInterface $value
14+
private int $index,
15+
private PointerQueryInterface $pathPointer,
16+
private NodeValueInterface $value,
2317
) {
24-
$this->index = $index;
25-
$this->pathPointer = $pathPointer;
26-
$this->value = $value;
2718
}
2819

2920
public function apply(NodeValueInterface $input, PointerProcessorInterface $pointerProcessor): NodeValueInterface

src/Operation/CopyOperation.php

Lines changed: 4 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<?php
2+
23
declare(strict_types=1);
34

45
namespace Remorhaz\JSON\Patch\Operation;
@@ -9,21 +10,11 @@
910

1011
final class CopyOperation implements OperationInterface
1112
{
12-
13-
private $index;
14-
15-
private $pathPointer;
16-
17-
private $fromPointer;
18-
1913
public function __construct(
20-
int $index,
21-
PointerQueryInterface $pathPointer,
22-
PointerQueryInterface $fromPointer
14+
private int $index,
15+
private PointerQueryInterface $pathPointer,
16+
private PointerQueryInterface $fromPointer,
2317
) {
24-
$this->index = $index;
25-
$this->pathPointer = $pathPointer;
26-
$this->fromPointer = $fromPointer;
2718
}
2819

2920
public function apply(NodeValueInterface $input, PointerProcessorInterface $pointerProcessor): NodeValueInterface

0 commit comments

Comments
 (0)