generated from ergebnis/php-package-template
-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Enhancement: Synchronize with ergebnis/php-package-template
- Loading branch information
1 parent
82f44a6
commit 3dd8994
Showing
19 changed files
with
363 additions
and
115 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,3 +12,4 @@ | |
/Makefile export-ignore | ||
/psalm-baseline.xml export-ignore | ||
/psalm.xml export-ignore | ||
/rector.php export-ignore |
Validating CODEOWNERS rules …
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,3 @@ | ||
# https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners | ||
|
||
* @ergebnis-bot @localheinz |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -57,12 +57,13 @@ jobs: | |
- name: "Collect code coverage with Xdebug and phpunit/phpunit" | ||
env: | ||
XDEBUG_MODE: "coverage" | ||
run: "vendor/bin/phpunit --configuration=test/Unit/phpunit.xml --coverage-clover=.build/phpunit/logs/clover.xml" | ||
run: "vendor/bin/phpunit --colors=always --configuration=test/Unit/phpunit.xml --coverage-clover=.build/phpunit/logs/clover.xml" | ||
|
||
- name: "Send code coverage report to Codecov.io" | ||
env: | ||
CODECOV_TOKEN: "${{ secrets.CODECOV_TOKEN }}" | ||
run: "bash <(curl -s https://codecov.io/bash)" | ||
- name: "Send code coverage report to codecov.io" | ||
uses: "codecov/[email protected]" | ||
with: | ||
files: ".build/phpunit/logs/clover.xml" | ||
token: "${{ secrets.CODECOV_TOKEN }}" | ||
|
||
coding-standards: | ||
name: "Coding Standards" | ||
|
@@ -82,7 +83,7 @@ jobs: | |
uses: "actions/[email protected]" | ||
|
||
- name: "Lint YAML files" | ||
uses: "ibiqlik/[email protected]" | ||
uses: "ibiqlik/[email protected].1" | ||
with: | ||
config_file: ".yamllint.yaml" | ||
file_or_dir: "." | ||
|
@@ -132,7 +133,7 @@ jobs: | |
php-${{ matrix.php-version }}-php-cs-fixer- | ||
- name: "Run friendsofphp/php-cs-fixer" | ||
run: "vendor/bin/php-cs-fixer fix --config=.php-cs-fixer.php --diff --dry-run --verbose" | ||
run: "vendor/bin/php-cs-fixer fix --ansi --config=.php-cs-fixer.php --diff --dry-run --verbose" | ||
|
||
dependency-analysis: | ||
name: "Dependency Analysis" | ||
|
@@ -157,6 +158,7 @@ jobs: | |
coverage: "none" | ||
extensions: "none, ctype, dom, json, mbstring, phar, simplexml, tokenizer, xml, xmlwriter" | ||
php-version: "${{ matrix.php-version }}" | ||
tools: "phive" | ||
|
||
- name: "Set up problem matchers for PHP" | ||
run: "echo \"::add-matcher::${{ runner.tool_cache }}/php.json\"" | ||
|
@@ -176,6 +178,11 @@ jobs: | |
with: | ||
dependencies: "${{ matrix.dependencies }}" | ||
|
||
- name: "Install dependencies with phive" | ||
uses: "ergebnis/.github/actions/phive/[email protected]" | ||
with: | ||
trust-gpg-keys: "0x033E5F8D801A2F8D" | ||
|
||
- name: "Run maglnet/composer-require-checker" | ||
run: ".phive/composer-require-checker check --config-file=$(pwd)/composer-require-checker.json" | ||
|
||
|
@@ -224,7 +231,97 @@ jobs: | |
- name: "Run mutation tests with Xdebug and infection/infection" | ||
env: | ||
XDEBUG_MODE: "coverage" | ||
run: "vendor/bin/infection --configuration=infection.json --logger-github" | ||
run: "vendor/bin/infection --ansi --configuration=infection.json --logger-github" | ||
|
||
refactoring: | ||
name: "Refactoring" | ||
|
||
runs-on: "ubuntu-latest" | ||
|
||
strategy: | ||
matrix: | ||
php-version: | ||
- "8.0" | ||
|
||
dependencies: | ||
- "locked" | ||
|
||
steps: | ||
- name: "Checkout" | ||
uses: "actions/[email protected]" | ||
|
||
- name: "Set up PHP" | ||
uses: "shivammathur/[email protected]" | ||
with: | ||
coverage: "none" | ||
extensions: "none, ctype, dom, intl, json, mbstring, phar, simplexml, tokenizer, xml, xmlwriter" | ||
php-version: "${{ matrix.php-version }}" | ||
|
||
- name: "Set up problem matchers for PHP" | ||
run: "echo \"::add-matcher::${{ runner.tool_cache }}/php.json\"" | ||
|
||
- name: "Determine composer cache directory" | ||
uses: "ergebnis/.github/actions/composer/[email protected]" | ||
|
||
- name: "Cache dependencies installed with composer" | ||
uses: "actions/[email protected]" | ||
with: | ||
path: "${{ env.COMPOSER_CACHE_DIR }}" | ||
key: "php-${{ matrix.php-version }}-composer-${{ matrix.dependencies }}-${{ hashFiles('composer.lock') }}" | ||
restore-keys: "php-${{ matrix.php-version }}-composer-${{ matrix.dependencies }}-" | ||
|
||
- name: "Install ${{ matrix.dependencies }} dependencies with composer" | ||
uses: "ergebnis/.github/actions/composer/[email protected]" | ||
with: | ||
dependencies: "${{ matrix.dependencies }}" | ||
|
||
- name: "Create cache directory for rector/rector" | ||
run: "mkdir -p .build/rector" | ||
|
||
- name: "Cache cache directory for rector/rector" | ||
uses: "actions/[email protected]" | ||
with: | ||
path: ".build/rector" | ||
key: "php-${{ matrix.php-version }}-rector-${{ github.ref_name }}" | ||
restore-keys: | | ||
php-${{ matrix.php-version }}-rector-main | ||
php-${{ matrix.php-version }}-rector- | ||
- name: "Run automated refactoring with rector/rector" | ||
run: "vendor/bin/rector --ansi --config=rector.php --dry-run" | ||
|
||
security-analysis: | ||
name: "Security Analysis" | ||
|
||
runs-on: "ubuntu-latest" | ||
|
||
strategy: | ||
matrix: | ||
php-version: | ||
- "8.0" | ||
|
||
dependencies: | ||
- "locked" | ||
|
||
steps: | ||
- name: "Checkout" | ||
uses: "actions/[email protected]" | ||
|
||
- name: "Set up PHP" | ||
uses: "shivammathur/[email protected]" | ||
with: | ||
coverage: "none" | ||
extensions: "none, ctype, dom, json, mbstring, phar, simplexml, tokenizer, xml, xmlwriter" | ||
php-version: "${{ matrix.php-version }}" | ||
|
||
- name: "Set up problem matchers for PHP" | ||
run: "echo \"::add-matcher::${{ runner.tool_cache }}/php.json\"" | ||
|
||
- name: "Validate composer.json and composer.lock" | ||
run: "composer validate --ansi --strict" | ||
|
||
- name: "Check installed packages for security vulnerability advisories" | ||
run: "composer audit --ansi" | ||
|
||
static-code-analysis: | ||
name: "Static Code Analysis" | ||
|
@@ -247,7 +344,7 @@ jobs: | |
uses: "shivammathur/[email protected]" | ||
with: | ||
coverage: "none" | ||
extensions: "none, ctype, curl, dom, json, mbstring, pcntl, phar, posix, simplexml, tokenizer, xml, xmlwriter" | ||
extensions: "none, ctype, curl, dom, json, mbstring, opcache, pcntl, phar, posix, simplexml, tokenizer, xml, xmlwriter" | ||
php-version: "${{ matrix.php-version }}" | ||
|
||
- name: "Set up problem matchers for PHP" | ||
|
@@ -324,4 +421,4 @@ jobs: | |
dependencies: "${{ matrix.dependencies }}" | ||
|
||
- name: "Run unit tests with phpunit/phpunit" | ||
run: "vendor/bin/phpunit --configuration=test/Unit/phpunit.xml" | ||
run: "vendor/bin/phpunit --colors=always --configuration=test/Unit/phpunit.xml" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -33,8 +33,8 @@ jobs: | |
- name: "Assign @ergebnis-bot" | ||
uses: "ergebnis/.github/actions/github/pull-request/[email protected]" | ||
with: | ||
github-token: "${{ secrets.ERGEBNIS_BOT_TOKEN }}" | ||
assignee: "ergebnis-bot" | ||
github-token: "${{ secrets.ERGEBNIS_BOT_TOKEN }}" | ||
|
||
- name: "Approve pull request" | ||
uses: "ergebnis/.github/actions/github/pull-request/[email protected]" | ||
|
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -67,7 +67,7 @@ jobs: | |
php-${{ matrix.php-version }}-php-cs-fixer- | ||
- name: "Run friendsofphp/php-cs-fixer" | ||
run: "vendor/bin/php-cs-fixer fix --config=.php-cs-fixer.php --diff --verbose" | ||
run: "vendor/bin/php-cs-fixer fix --ansi --config=.php-cs-fixer.php --diff --verbose" | ||
|
||
- name: "Commit modified files" | ||
uses: "stefanzweifel/[email protected]" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
/.build/ | ||
/.notes/ | ||
/.phive/ | ||
/vendor/ | ||
!/.phive/phars.xml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<phive xmlns="https://phar.io/phive"> | ||
<phar name="composer-require-checker" version="^4.3.0" installed="4.3.0" location="./.phive/composer-require-checker" copy="true"/> | ||
<phar name="composer-require-checker" version="^4.3.0" installed="4.3.0" location="./.phive/composer-require-checker" copy="false"/> | ||
</phive> |
Oops, something went wrong.