Skip to content
This repository was archived by the owner on Mar 1, 2023. It is now read-only.

Commit 5589ac2

Browse files
authored
Merge pull request #302 from PrisisForks/feature/php8
2 parents 76893cf + 92b4262 commit 5589ac2

39 files changed

+5263
-4349
lines changed

Diff for: .build/composer.json

-48
This file was deleted.

Diff for: .build/rector-src.yaml

-23
This file was deleted.

Diff for: .build/rector-tests.yaml

-17
This file was deleted.

Diff for: .build/travis/README.md

-6
This file was deleted.

Diff for: .build/travis/configure_php.sh

-5
This file was deleted.

Diff for: .dependabot/config.yml

-48
This file was deleted.

Diff for: .docker/php/Dockerfile

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ RUN apt-get update && \
2424
apt-get clean -y && \
2525
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
2626

27-
RUN docker-php-ext-install opcache bcmath zip pcntl
27+
RUN docker-php-ext-install opcache bcmath zip pcntl intl
2828

2929
RUN docker-php-ext-configure zip
3030

@@ -58,7 +58,7 @@ RUN { \
5858
ENV COMPOSER_ALLOW_SUPERUSER 1
5959

6060
RUN php -r "readfile('http://getcomposer.org/installer');" | php -- --install-dir=/usr/bin/ --filename=composer && \
61-
composer global require phploc/phploc ergebnis/composer-normalize narrowspark/automatic-composer-prefetcher narrowspark/automatic-security-audit
61+
composer global require phploc/phploc ergebnis/composer-normalize
6262

6363
ARG INSTALL_XDEBUG
6464
ARG XDEBUG_VERSION

Diff for: .github/PULL_REQUEST_TEMPLATE.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
| Q | A
22
| ------------- | ---
3-
| Branch? | master <!-- for features -->
3+
| Branch? | main <!-- for features -->
44
| Bug fix? | yes/no
55
| New feature? | yes/no <!-- don't forget to update CHANGELOG.md file(s) -->
66
| Deprecations? | yes/no <!-- don't forget to update UPGRADE-*.md file(s) -->
@@ -17,6 +17,6 @@ Additionally:
1717
- Never break backward compatibility
1818
- Bug fixes must be submitted against the lowest branch where they apply
1919
(lowest branches are regularly merged to upper ones so they get the fixes too).
20-
- Features and deprecations must be submitted against the branch "master".
21-
- Legacy code removals go to the master branch.
20+
- Features and deprecations must be submitted against the branch "main".
21+
- Legacy code removals go to the main branch.
2222
-->

Diff for: .github/renovate.json5

+71
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
{
2+
$schema: "https://docs.renovatebot.com/renovate-schema.json",
3+
extends: ["config:base", ":semanticCommits", ":preserveSemverRanges", ":ignoreModulesAndTests", "group:allNonMajor"],
4+
labels: ["dependency", "Changed"],
5+
lockFileMaintenance: {
6+
"enabled": true
7+
},
8+
semanticCommitType: "chore",
9+
semanticCommitScope: "deps",
10+
rebaseWhen: "behind-base-branch",
11+
timezone: "Europe/Berlin",
12+
dependencyDashboard: true,
13+
packageRules: [
14+
{
15+
groupName: "dependencies (major)",
16+
automerge: false,
17+
depTypeList: ["dependencies"],
18+
updateTypes: ["major"],
19+
labels: ["dependency", "Changed"],
20+
semanticCommitType: "chore",
21+
semanticCommitScope: "deps",
22+
rangeStrategy: "replace",
23+
vulnerabilityAlerts: {
24+
labels: ["Security"],
25+
assignees: ["@prisis"]
26+
}
27+
},
28+
{
29+
groupName: "dependencies (non-major)",
30+
automerge: true,
31+
depTypeList: ["dependencies"],
32+
updateTypes: ["minor", "patch", "digest"],
33+
labels: ["dependency", "Changed"],
34+
semanticCommitType: "chore",
35+
semanticCommitScope: "deps",
36+
rangeStrategy: "replace",
37+
vulnerabilityAlerts: {
38+
labels: ["Security"],
39+
assignees: ["@prisis"]
40+
}
41+
},
42+
{
43+
groupName: "devDependencies (major)",
44+
automerge: false,
45+
depTypeList: ["devDependencies"],
46+
updateTypes: ["major"],
47+
labels: ["dependency", "Changed"],
48+
semanticCommitType: "chore",
49+
semanticCommitScope: "deps",
50+
rangeStrategy: "replace",
51+
vulnerabilityAlerts: {
52+
labels: ["Security"],
53+
assignees: ["@prisis"]
54+
}
55+
},
56+
{
57+
groupName: "devDependencies (non-major)",
58+
automerge: true,
59+
depTypeList: ["devDependencies"],
60+
updateTypes: ["minor", "patch", "digest"],
61+
labels: ["dependency", "Changed"],
62+
semanticCommitType: "chore",
63+
semanticCommitScope: "deps",
64+
rangeStrategy: "replace",
65+
vulnerabilityAlerts: {
66+
labels: ["Security"],
67+
assignees: ["@prisis"]
68+
}
69+
}
70+
]
71+
}

Diff for: .github/settings.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# https://github.com/probot/settings
22

33
branches:
4-
- name: master
4+
- name: main
55
protection:
66
enforce_admins: false
77
required_pull_request_reviews:
@@ -89,7 +89,7 @@ repository:
8989
allow_rebase_merge: false
9090
allow_squash_merge: false
9191
archived: false
92-
default_branch: master
92+
default_branch: main
9393
delete_branch_on_merge: true
9494
description: ":notebook: Provides a configuration for fabpot/php-cs-fixer, used within Narrowspark."
9595
has_downloads: true

Diff for: .github/workflows/code-coverage.yml

+6-12
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,13 @@ jobs:
2020

2121
strategy:
2222
matrix:
23-
php-versions: ["7.3"]
23+
php-versions: ["8.0"]
2424

2525
env:
2626
key: "code-coverage-v4" # change key (version) to clear cache
2727
extensions: "mbstring"
28-
ini-values: "date.timezone=Europe/Berlin, opcache.enable_cli=1, serialize_precision=14, pcov.directory=api"
29-
tools: "composer, composer-prefetcher, cs2pr"
28+
ini-values: "date.timezone=Europe/Berlin, serialize_precision=14, pcov.directory=api"
29+
tools: "composer, cs2pr"
3030

3131
steps:
3232
- uses: actions/checkout@v2
@@ -57,12 +57,6 @@ jobs:
5757
tools: ${{ env.tools }}
5858
coverage: "pcov"
5959

60-
- name: "Configure Container"
61-
run: |
62-
echo "::set-env name=PHPUNIT::./vendor/bin/phpunit --verbose"
63-
echo "::set-env name=COMPOSER_UP::composer update --no-progress --no-suggest --no-interaction --prefer-source --ansi"
64-
echo "::set-env name=PHPUNIT_COVERAGE::true"
65-
6660
- name: "Setup Problem Matchers for PHP"
6761
run: echo "::add-matcher::${{ runner.tool_cache }}/php.json"
6862

@@ -83,17 +77,17 @@ jobs:
8377
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
8478

8579
- name: "Cache dependencies"
86-
uses: actions/cache@v1
80+
uses: actions/cache@v2
8781
with:
8882
path: ${{ steps.composer-cache.outputs.dir }}
8983
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}
9084
restore-keys: ${{ runner.os }}-composer-
9185

9286
- name: "Install locked dependencies with composer"
93-
run: $COMPOSER_UP
87+
run: composer update --no-progress --no-interaction --prefer-source --ansi
9488

9589
- name: "Collect code coverage"
96-
run: $PHPUNIT --configuration=./phpunit.xml --coverage-clover=./.build/phpunit/coverage/clover.xml
90+
run: ./vendor/bin/phpunit --verbose --configuration=./phpunit.xml --coverage-clover=./.build/phpunit/coverage/clover.xml
9791

9892
- name: "Send code coverage report to Codecov.io"
9993
uses: codecov/codecov-action@v1

Diff for: .github/workflows/coding-standard.yml

+6-8
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,13 @@ jobs:
2020

2121
strategy:
2222
matrix:
23-
php-versions: ["7.3"]
23+
php-versions: ["8.0"]
2424

2525
env:
2626
key: "coding-standard-v4" # change key (version) to clear cache
2727
extensions: "mbstring"
2828
ini-values: "date.timezone=Europe/Berlin, opcache.enable_cli=1"
29-
tools: "composer, composer-prefetcher, cs2pr"
29+
tools: "composer, cs2pr"
3030

3131
steps:
3232
- uses: actions/checkout@v2
@@ -42,7 +42,7 @@ jobs:
4242
key: ${{ env.key }}
4343

4444
- name: "Cache extensions"
45-
uses: actions/cache@v1
45+
uses: actions/cache@v2
4646
with:
4747
path: ${{ steps.cache-env.outputs.dir }}
4848
key: ${{ steps.cache-env.outputs.key }}
@@ -62,8 +62,6 @@ jobs:
6262
NARROWSPARK_EMAIL: ${{ secrets.NARROWSPARK_EMAIL }}
6363
NARROWSPARK_USERNAME: ${{ secrets.NARROWSPARK_USERNAME }}
6464
run: |
65-
echo "::set-env name=COMPOSER_UP::composer update --no-progress --no-suggest --no-interaction --prefer-source --ansi"
66-
6765
EMAIL=${NARROWSPARK_EMAIL:-"[email protected]"}
6866
NAME=${NARROWSPARK_USERNAME:-"prisis"}
6967
@@ -90,14 +88,14 @@ jobs:
9088
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
9189

9290
- name: "Cache dependencies"
93-
uses: actions/cache@v1
91+
uses: actions/cache@v2
9492
with:
9593
path: ${{ steps.composer-cache.outputs.dir }}
9694
key: ${{ runner.os }}-composer-${{ hashFiles('**/.build/composer.json') }}
9795
restore-keys: ${{ runner.os }}-composer-
9896

9997
- name: "Install highest .build dependencies"
100-
run: $COMPOSER_UP --working-dir=./.build --lock
98+
run: composer update --no-progress --no-interaction --prefer-source --ansi
10199

102100
- name: "lint php code"
103-
run: composer --working-dir=./.build cs:check -- --format=checkstyle | cs2pr
101+
run: composer cs:check -- --format=checkstyle | cs2pr

0 commit comments

Comments
 (0)