Skip to content

Commit 851c3ba

Browse files
committed
Fixed readme
1 parent 03dc455 commit 851c3ba

1 file changed

Lines changed: 7 additions & 38 deletions

File tree

README.md

Lines changed: 7 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -1,53 +1,22 @@
1-
pre-commit-laravel
1+
pre-commit-composer
22
==================
3-
A [pre-commit](https://pre-commit.com/) hook for [Laravel](https://laravel.com/).
3+
A [pre-commit](https://pre-commit.com/) hook for [Composer](https://getcomposer.org/), the PHP package manager.
44

5-
This adds support for running [Laravel Pint](https://laravel.com/docs/10.x/pint) and
6-
[Artisan Tests](https://laravel.com/docs/10.x/testing#running-tests) as pre-commit hooks in your Laravel project.
5+
This adds support for running various composer utilities in pre-commit hooks.
76

87
Usage
98
-----
109

11-
### Using Laravel Pint with pre-commit
10+
### Using Composer validate with pre-commit
1211
Add this to your `.pre-commit-config.yaml`:
1312

1413
```yaml
15-
- repo: https://github.com/matchory/pre-commit-laravel
16-
rev: v1.0.1
14+
- repo: https://github.com/matchory/pre-commit-composer
15+
rev: v1.0.0
1716
hooks:
18-
- id: laravel-pint
17+
- id: composer-validate
1918
```
2019
21-
Or, to disable automatic fixing:
22-
```yaml
23-
- repo: https://github.com/matchory/pre-commit-laravel
24-
rev: v1.0.1
25-
hooks:
26-
- id: laravel-pint
27-
args: ["--test"]
28-
```
29-
30-
### Using Artisan tests with pre-commit
31-
Add this to your `.pre-commit-config.yaml`:
32-
33-
```yaml
34-
- repo: https://github.com/matchory/pre-commit-laravel
35-
rev: v1.0.1
36-
hooks:
37-
- id: laravel-tests
38-
```
39-
40-
Or, to enable parallel testing:
41-
```yaml
42-
- repo: https://github.com/matchory/pre-commit-laravel
43-
rev: v1.0.1
44-
hooks:
45-
- id: laravel-tests
46-
args: ["--parallel"]
47-
```
48-
Note that this requires the [`brianium/paratest` package](https://packagist.org/packages/brianium/paratest) to be
49-
installed in your project.
50-
5120
License
5221
-------
5322
MIT

0 commit comments

Comments
 (0)