Skip to content

Commit af2c8e2

Browse files
authored
Merge pull request #15 from maartenpaauw/develop
Release
2 parents b0d519c + f9f83ac commit af2c8e2

Some content is hidden

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

44 files changed

+287
-184
lines changed

.editorconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@ root = true
22

33
[*]
44
charset = utf-8
5+
end_of_line = lf
56
indent_size = 4
67
indent_style = space
7-
end_of_line = lf
88
insert_final_newline = true
99
trim_trailing_whitespace = true
1010

.gitattributes

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2,18 +2,19 @@
22
# https://www.kernel.org/pub/software/scm/git/docs/gitattributes.html
33

44
# Ignore all test and documentation with "export-ignore".
5-
/.github export-ignore
6-
/.gitattributes export-ignore
7-
/.gitignore export-ignore
8-
/phpunit.xml.dist export-ignore
9-
/art export-ignore
10-
/docs export-ignore
11-
/tests export-ignore
12-
/.editorconfig export-ignore
13-
/.php_cs.dist.php export-ignore
14-
/psalm.xml export-ignore
15-
/psalm.xml.dist export-ignore
16-
/testbench.yaml export-ignore
17-
/UPGRADING.md export-ignore
18-
/phpstan.neon.dist export-ignore
5+
/.github export-ignore
6+
/.gitattributes export-ignore
7+
/.gitignore export-ignore
8+
/phpunit.xml.dist export-ignore
9+
/art export-ignore
10+
/docs export-ignore
11+
/tests export-ignore
12+
/workbench export-ignore
13+
/.editorconfig export-ignore
14+
/.php_cs.dist.php export-ignore
15+
/psalm.xml export-ignore
16+
/psalm.xml.dist export-ignore
17+
/testbench.yaml export-ignore
18+
/UPGRADING.md export-ignore
19+
/phpstan.neon.dist export-ignore
1920
/phpstan-baseline.neon export-ignore

.github/ISSUE_TEMPLATE/bug.yml

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
name: Bug Report
2+
description: Report an Issue or Bug with the Package
3+
title: "[Bug]: "
4+
labels: ["bug"]
5+
body:
6+
- type: markdown
7+
attributes:
8+
value: |
9+
We're sorry to hear you have a problem. Can you help us solve it by providing the following details.
10+
- type: textarea
11+
id: what-happened
12+
attributes:
13+
label: What happened?
14+
description: What did you expect to happen?
15+
placeholder: I cannot currently do X thing because when I do, it breaks X thing.
16+
validations:
17+
required: true
18+
- type: textarea
19+
id: how-to-reproduce
20+
attributes:
21+
label: How to reproduce the bug
22+
description: How did this occur, please add any config values used and provide a set of reliable steps if possible.
23+
placeholder: When I do X I see Y.
24+
validations:
25+
required: true
26+
- type: input
27+
id: package-version
28+
attributes:
29+
label: Package Version
30+
description: What version of our Package are you running? Please be as specific as possible
31+
placeholder: 2.0.0
32+
validations:
33+
required: true
34+
- type: input
35+
id: php-version
36+
attributes:
37+
label: PHP Version
38+
description: What version of PHP are you running? Please be as specific as possible
39+
placeholder: 8.3.0
40+
validations:
41+
required: true
42+
- type: input
43+
id: laravel-version
44+
attributes:
45+
label: Laravel Version
46+
description: What version of Laravel are you running? Please be as specific as possible
47+
placeholder: 10.0.0
48+
validations:
49+
required: true
50+
- type: dropdown
51+
id: operating-systems
52+
attributes:
53+
label: Which operating systems does with happen with?
54+
description: You may select more than one.
55+
multiple: true
56+
options:
57+
- macOS
58+
- Windows
59+
- Linux
60+
- type: textarea
61+
id: notes
62+
attributes:
63+
label: Notes
64+
description: Use this field to provide any other notes that you feel might be relevant to the issue.
65+
validations:
66+
required: false

.github/dependabot.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,4 @@ updates:
2929
assignees:
3030
- "maartenpaauw"
3131
reviewers:
32-
- "maarten"
32+
- "maartenpaauw"

.github/workflows/code-coverage.yml

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

1818
steps:
1919
- name: Checkout code
20-
uses: actions/checkout@v3
20+
uses: actions/checkout@v4
2121

2222
- name: Setup PHP
2323
uses: shivammathur/setup-php@v2
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: "Dependabot Auto-Merge"
2+
3+
on: pull_request_target
4+
5+
permissions:
6+
pull-requests: write
7+
contents: write
8+
9+
jobs:
10+
dependabot:
11+
runs-on: ubuntu-latest
12+
timeout-minutes: 5
13+
if: ${{ github.actor == 'dependabot[bot]' }}
14+
steps:
15+
16+
- name: Dependabot metadata
17+
id: metadata
18+
uses: dependabot/[email protected]
19+
with:
20+
github-token: "${{ secrets.GITHUB_TOKEN }}"
21+
22+
- name: Auto-merge Dependabot PRs for semver-minor updates
23+
if: ${{steps.metadata.outputs.update-type == 'version-update:semver-minor'}}
24+
run: gh pr merge --auto --merge "$PR_URL"
25+
env:
26+
PR_URL: ${{github.event.pull_request.html_url}}
27+
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
28+
29+
- name: Auto-merge Dependabot PRs for semver-patch updates
30+
if: ${{steps.metadata.outputs.update-type == 'version-update:semver-patch'}}
31+
run: gh pr merge --auto --merge "$PR_URL"
32+
env:
33+
PR_URL: ${{github.event.pull_request.html_url}}
34+
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Fix PHP code style issues
2+
3+
on:
4+
push:
5+
paths:
6+
- '**.php'
7+
8+
permissions:
9+
contents: write
10+
11+
jobs:
12+
php-code-styling:
13+
runs-on: ubuntu-latest
14+
timeout-minutes: 5
15+
16+
steps:
17+
- name: Checkout code
18+
uses: actions/checkout@v4
19+
with:
20+
ref: ${{ github.head_ref }}
21+
22+
- name: Fix PHP code style issues
23+
uses: aglipanci/[email protected]
24+
25+
- name: Commit changes
26+
uses: stefanzweifel/git-auto-commit-action@v5
27+
with:
28+
commit_message: "chore: fix code styling"

.github/workflows/php-cs-fixer.yml

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

.github/workflows/phpstan.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,22 +5,24 @@ on:
55
paths:
66
- '**.php'
77
- 'phpstan.neon.dist'
8+
- '.github/workflows/phpstan.yml'
89

910
jobs:
1011
phpstan:
1112
name: phpstan
1213
runs-on: ubuntu-latest
14+
timeout-minutes: 5
1315
steps:
14-
- uses: actions/checkout@v3
16+
- uses: actions/checkout@v4
1517

1618
- name: Setup PHP
1719
uses: shivammathur/setup-php@v2
1820
with:
19-
php-version: '8.0'
21+
php-version: '8.1'
2022
coverage: none
2123

2224
- name: Install composer dependencies
23-
uses: ramsey/composer-install@v1
25+
uses: ramsey/composer-install@v3
2426

2527
- name: Run PHPStan
2628
run: ./vendor/bin/phpstan --error-format=github

.github/workflows/run-tests.yml

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,24 +9,23 @@ on:
99
jobs:
1010
test:
1111
runs-on: ${{ matrix.os }}
12+
timeout-minutes: 5
1213
strategy:
1314
fail-fast: true
1415
matrix:
1516
os: [ubuntu-latest, windows-latest]
16-
php: [8.1, 8.2]
17-
laravel: [9.*, 10.*]
17+
php: [8.1, 8.2, 8.3]
18+
laravel: [10.*]
1819
stability: [prefer-lowest, prefer-stable]
1920
include:
20-
- laravel: 9.*
21-
testbench: ^7.1
2221
- laravel: 10.*
2322
testbench: ^8.0.10
2423

2524
name: P${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.stability }} - ${{ matrix.os }}
2625

2726
steps:
2827
- name: Checkout code
29-
uses: actions/checkout@v3
28+
uses: actions/checkout@v4
3029

3130
- name: Setup PHP
3231
uses: shivammathur/setup-php@v2
@@ -45,5 +44,8 @@ jobs:
4544
composer require "laravel/framework:${{ matrix.laravel }}" "orchestra/testbench:${{ matrix.testbench }}" --no-interaction --no-update
4645
composer update --${{ matrix.stability }} --prefer-dist --no-interaction
4746
47+
- name: List Installed Dependencies
48+
run: composer show -D
49+
4850
- name: Execute tests
49-
run: vendor/bin/pest
51+
run: vendor/bin/pest --ci

.gitignore

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
.idea
2-
.php_cs
3-
.php_cs.cache
4-
.phpunit.result.cache
2+
.phpunit.cache
53
build
64
composer.lock
75
coverage
@@ -11,5 +9,4 @@ phpstan.neon
119
testbench.yaml
1210
vendor
1311
node_modules
14-
.php-cs-fixer.cache
1512
coverage.xml

.php_cs.dist.php

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

CHANGELOG.md

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,22 @@
22

33
All notable changes to `laravel-specification-pattern` will be documented in this file.
44

5+
## [v2.1.0] - 2024-03-08
6+
7+
### Added
8+
9+
- Support for PHP 8.3.
10+
11+
### Removed
12+
13+
- Support for Laravel 9.
14+
- Support for PHP 8.0.
15+
516
## [v2.0.0] - 2023-03-21
617

718
### Added
819

9-
- Support from Laravel 10.
20+
- Support for Laravel 10.
1021

1122
### Changed
1223

@@ -32,6 +43,7 @@ All notable changes to `laravel-specification-pattern` will be documented in thi
3243

3344
- initial release
3445

46+
[v2.1.0]: https://github.com/maartenpaauw/laravel-specification-pattern/compare/v2.0.0...v2.1.0
3547
[v2.0.0]: https://github.com/maartenpaauw/laravel-specification-pattern/compare/v1.1.0...v2.0.0
3648
[v1.1.0]: https://github.com/maartenpaauw/laravel-specification-pattern/compare/v1.0.0...v1.1.0
3749
[v1.0.0]: https://github.com/maartenpaauw/laravel-specification-pattern/releases/tag/v1.0.0

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
# Laravel specification pattern
22

33
[![Latest Version on Packagist](https://img.shields.io/packagist/v/maartenpaauw/laravel-specification-pattern.svg?style=flat-square)](https://packagist.org/packages/maartenpaauw/laravel-specification-pattern)
4-
[![GitHub Tests Action Status](https://img.shields.io/github/actions/workflow/status/maartenpaauw/laravel-specification-pattern/run-tests.yml?label=tests)](https://github.com/maartenpaauw/laravel-specification-pattern/actions?query=workflow%3Arun-tests+branch%3Amain)
5-
[![GitHub Code Style Action Status](https://img.shields.io/github/actions/workflow/status/maartenpaauw/laravel-specification-pattern/php-cs-fixer.yml?label=code%20style)](https://github.com/maartenpaauw/laravel-specification-pattern/actions?query=workflow%3A"Check+%26+fix+styling"+branch%3Amain)
4+
[![GitHub Tests Action Status](https://img.shields.io/github/actions/workflow/status/maartenpaauw/laravel-specification-pattern/run-tests.yml?branch=develop&label=tests&style=flat-square)](https://github.com/maartenpaauw/laravel-specification-pattern/actions?query=workflow%3Arun-tests+branch%3Adevelop)
5+
[![GitHub Code Style Action Status](https://img.shields.io/github/actions/workflow/status/maartenpaauw/laravel-specification-pattern/fix-php-code-style-issues.yml?branch=develop&label=code%20style&style=flat-square)](https://github.com/maartenpaauw/laravel-specification-pattern/actions?query=workflow%3A"Fix+PHP+code+style+issues"+branch%3Adevelop)
66
[![Codecov](https://codecov.io/gh/maartenpaauw/laravel-specification-pattern/branch/develop/graph/badge.svg?token=YM9A0DUA4R)](https://codecov.io/gh/maartenpaauw/laravel-specification-pattern)
77
[![Total Downloads](https://img.shields.io/packagist/dt/maartenpaauw/laravel-specification-pattern.svg?style=flat-square)](https://packagist.org/packages/maartenpaauw/laravel-specification-pattern)
88

@@ -53,7 +53,7 @@ use Maartenpaauw\Specifications\Specification;
5353
class AdultSpecification implements Specification
5454
{
5555
/**
56-
* @inheritDoc
56+
* {@inheritDoc}
5757
*/
5858
public function isSatisfiedBy(mixed $candidate): bool
5959
{
@@ -87,7 +87,7 @@ use Maartenpaauw\Specifications\Specification;
8787
class AdultSpecification implements Specification
8888
{
8989
/**
90-
* @inheritDoc
90+
* {@inheritDoc}
9191
*/
9292
public function isSatisfiedBy(mixed $candidate): bool
9393
{

0 commit comments

Comments
 (0)