mirror of
https://github.com/rectorphp/rector.git
synced 2025-04-22 16:32:27 +02:00
[README] init
This commit is contained in:
parent
466e284524
commit
7c62780a54
@ -15,10 +15,10 @@ script:
|
||||
# run tests
|
||||
- vendor/bin/phpunit $PHPUNIT_FLAGS
|
||||
# check coding standard (defined in composer.json "scripts" section)
|
||||
# if this fails, run "composer fix-cs" to fix all fixable issues
|
||||
# - composer check-cs
|
||||
# if this fails, run "composer fs" to fix all fixable issues
|
||||
- composer cs
|
||||
# check with phpstan (defined in composer.json "scripts" section)
|
||||
- composer phpstan
|
||||
- composer ps
|
||||
|
||||
after_script:
|
||||
# upload coverage.xml file to Coveralls to analyze it
|
||||
|
45
README.md
Normal file
45
README.md
Normal file
@ -0,0 +1,45 @@
|
||||
# Rector - Reconstruct your Legacy Code to Modern Codebase
|
||||
|
||||
[](https://travis-ci.org/TomasVotruba/Rector)
|
||||
[](https://coveralls.io/github/TomasVotruba/Rector?branch=master)
|
||||
|
||||
|
||||
This tool will *reconstruct* (change) your code - **run it only in a new clean git branch**.
|
||||
|
||||
|
||||
## All Reconstructors
|
||||
|
||||
- `InjectAnnotationToConstructorReconstructor`
|
||||
|
||||
|
||||
## Install
|
||||
|
||||
```bash
|
||||
composer require rector/rector --dev
|
||||
```
|
||||
|
||||
## Use
|
||||
|
||||
```bash
|
||||
vendor/bin/rector reconstruct src
|
||||
```
|
||||
|
||||
### How to Contribute
|
||||
|
||||
Just follow 3 rules:
|
||||
|
||||
- **1 feature per pull-request**
|
||||
- **New feature needs tests**. [Coveralls.io](https://coveralls.io/) checks code coverage under every PR.
|
||||
- Tests, coding standard and PHPStan **checks must pass**
|
||||
|
||||
```bash
|
||||
composer all
|
||||
```
|
||||
|
||||
Often you don't need to fix coding standard manually, just run:
|
||||
|
||||
```bash
|
||||
composer fs
|
||||
```
|
||||
|
||||
We would be happy to merge your feature then.
|
@ -29,6 +29,9 @@
|
||||
}
|
||||
},
|
||||
"scripts": {
|
||||
"phpstan": "phpstan analyse src tests --level 7"
|
||||
"all": ["phpunit", "@cs", "@ps"],
|
||||
"cs": "ecs check src tests",
|
||||
"fs": "ecs check src tests --fix",
|
||||
"ps": "phpstan analyse src tests --level 7"
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user