Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhancement: Synchronize with ergebnis/php-library-template #130

Merged
merged 1 commit into from
Jun 23, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 9 additions & 9 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ We are using [`yamllint`](https://github.com/adrienverge/yamllint) to enforce co

If you do not have `yamllint` installed yet, run

```
```sh
$ brew install yamllint
```

Expand All @@ -28,7 +28,7 @@ We are using [`friendsofphp/php-cs-fixer`](https://github.com/FriendsOfPHP/PHP-C

Run

```
```sh
$ make coding-standards
```

Expand All @@ -40,7 +40,7 @@ We are using [`maglnet/composer-require-checker`](https://github.com/maglnet/Com

Run

```
```sh
$ make dependency-analysis
```

Expand All @@ -52,7 +52,7 @@ We are using [`phpstan/phpstan`](https://github.com/phpstan/phpstan) and [`vimeo

Run

```
```sh
$ make static-code-analysis
```

Expand All @@ -62,7 +62,7 @@ We are also using the baseline features of [`phpstan/phpstan`](https://medium.co

Run

```
```sh
$ make static-code-analysis-baseline
```

Expand All @@ -76,7 +76,7 @@ We are using [`phpunit/phpunit`](https://github.com/sebastianbergmann/phpunit) t

Run

```
```sh
$ make tests
```

Expand All @@ -88,7 +88,7 @@ We are using [`infection/infection`](https://github.com/infection/infection) to

Enable `pcov` or `Xdebug` and run

```
```sh
$ make mutation-tests
```

Expand All @@ -98,7 +98,7 @@ to run mutation tests.

Run

```
```sh
$ make
```

Expand All @@ -108,7 +108,7 @@ to enforce coding standards, run a static code analysis, and run tests!

:bulb: Run

```
```sh
$ make help
```

Expand Down
27 changes: 27 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# https://help.github.com/en/github/administering-a-repository/configuration-options-for-dependency-updates

version: 2

updates:
- commit-message:
include: "scope"
prefix: "composer"
directory: "/"
labels:
- "dependency"
open-pull-requests-limit: 10
package-ecosystem: "composer"
schedule:
interval: "daily"
versioning-strategy: "increase"

- commit-message:
include: "scope"
prefix: "github-actions"
directory: "/"
labels:
- "dependency"
open-pull-requests-limit: 10
package-ecosystem: "github-actions"
schedule:
interval: "daily"
29 changes: 15 additions & 14 deletions .github/workflows/integrate.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ on: # yamllint disable-line rule:truthy
env:
MIN_COVERED_MSI: 100
MIN_MSI: 100
REQUIRED_PHP_EXTENSIONS: "mbstring"
PHP_EXTENSIONS: "mbstring"

jobs:
coding-standards:
Expand All @@ -29,7 +29,7 @@ jobs:

steps:
- name: "Checkout"
uses: "actions/checkout@v2"
uses: "actions/checkout@v2.3.1"

- name: "Lint YAML files"
uses: "ibiqlik/action-yamllint@v1"
Expand All @@ -42,7 +42,7 @@ jobs:
uses: "shivammathur/setup-php@v2"
with:
coverage: "none"
extensions: "${{ env.REQUIRED_PHP_EXTENSIONS }}"
extensions: "${{ env.PHP_EXTENSIONS }}"
php-version: "${{ matrix.php-version }}"

- name: "Validate composer.json and composer.lock"
Expand Down Expand Up @@ -102,13 +102,13 @@ jobs:

steps:
- name: "Checkout"
uses: "actions/checkout@v2"
uses: "actions/checkout@v2.3.1"

- name: "Install PHP with extensions"
uses: "shivammathur/setup-php@v2"
with:
coverage: "none"
extensions: "${{ env.REQUIRED_PHP_EXTENSIONS }}"
extensions: "${{ env.PHP_EXTENSIONS }}"
php-version: "${{ matrix.php-version }}"

- name: "Determine composer cache directory"
Expand Down Expand Up @@ -152,13 +152,13 @@ jobs:

steps:
- name: "Checkout"
uses: "actions/checkout@v2"
uses: "actions/checkout@v2.3.1"

- name: "Install PHP with extensions"
uses: "shivammathur/setup-php@v2"
with:
coverage: "none"
extensions: "${{ env.REQUIRED_PHP_EXTENSIONS }}"
extensions: "${{ env.PHP_EXTENSIONS }}"
php-version: "${{ matrix.php-version }}"

- name: "Determine composer cache directory"
Expand Down Expand Up @@ -230,13 +230,13 @@ jobs:

steps:
- name: "Checkout"
uses: "actions/checkout@v2"
uses: "actions/checkout@v2.3.1"

- name: "Install PHP with extensions"
uses: "shivammathur/setup-php@v2"
with:
coverage: "none"
extensions: "${{ env.REQUIRED_PHP_EXTENSIONS }}"
extensions: "${{ env.PHP_EXTENSIONS }}"
php-version: "${{ matrix.php-version }}"

- name: "Determine composer cache directory"
Expand Down Expand Up @@ -286,13 +286,13 @@ jobs:

steps:
- name: "Checkout"
uses: "actions/checkout@v2"
uses: "actions/checkout@v2.3.1"

- name: "Install PHP with extensions"
uses: "shivammathur/setup-php@v2"
with:
coverage: "xdebug"
extensions: "${{ env.REQUIRED_PHP_EXTENSIONS }}"
extensions: "${{ env.PHP_EXTENSIONS }}"
php-version: "${{ matrix.php-version }}"

- name: "Determine composer cache directory"
Expand Down Expand Up @@ -344,13 +344,13 @@ jobs:

steps:
- name: "Checkout"
uses: "actions/checkout@v2"
uses: "actions/checkout@v2.3.1"

- name: "Install PHP with extensions"
uses: "shivammathur/setup-php@v2"
with:
coverage: "xdebug"
extensions: "${{ env.REQUIRED_PHP_EXTENSIONS }}"
extensions: "${{ env.PHP_EXTENSIONS }}"
php-version: "${{ matrix.php-version }}"

- name: "Determine composer cache directory"
Expand Down Expand Up @@ -399,7 +399,8 @@ jobs:
github.event.action == 'reopened' ||
github.event.action == 'synchronize'
) && (
(github.actor == 'dependabot[bot]' && startsWith(github.event.pull_request.title, 'Build(deps-dev)')) ||
(github.actor == 'dependabot[bot]' && startsWith(github.event.pull_request.title, 'composer(deps-dev)')) ||
(github.actor == 'dependabot[bot]' && startsWith(github.event.pull_request.title, 'github-actions(deps)')) ||
(github.actor == 'ergebnis-bot' && github.event.pull_request.title == 'Enhancement: Update license year') ||
(github.actor == 'localheinz' && contains(github.event.pull_request.labels.*.name, 'merge'))
)
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
run: "echo \"::set-output name=tag::${GITHUB_REF#refs/tags/}\""

- name: "Create release"
uses: "actions/create-release@v1"
uses: "actions/create-release@v1.1.1"
env:
GITHUB_TOKEN: "${{ secrets.ERGEBNIS_BOT_TOKEN }}"
with:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/renew.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on: # yamllint disable-line rule:truthy
- cron: "1 0 1 1 *"

env:
REQUIRED_PHP_EXTENSIONS: "mbstring"
PHP_EXTENSIONS: "mbstring"

jobs:
license:
Expand All @@ -25,13 +25,13 @@ jobs:

steps:
- name: "Checkout"
uses: "actions/checkout@v2"
uses: "actions/checkout@v2.3.1"

- name: "Install PHP with extensions"
uses: "shivammathur/setup-php@v2"
with:
coverage: "none"
extensions: "${{ env.REQUIRED_PHP_EXTENSIONS }}"
extensions: "${{ env.PHP_EXTENSIONS }}"
php-version: "${{ matrix.php-version }}"

- name: "Validate composer.json and composer.lock"
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Provides a configuration factory and multiple rule sets for [`friendsofphp/php-c

Run

```shell
```sh
$ composer require --dev ergebnis/php-cs-fixer-config
```

Expand Down
2 changes: 1 addition & 1 deletion psalm-baseline.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<files psalm-version="3.10.1@eeed5ecccc10131397f0eb7ee6da810c0be3a7fc">
<files psalm-version="3.11.5@3c60609c218d4d4b3b257728b8089094e5c6c6c2">
<file src="test/Unit/FactoryTest.php">
<MixedInferredReturnType occurrences="1">
<code>\Generator</code>
Expand Down