-
-
Notifications
You must be signed in to change notification settings - Fork 20
40 lines (31 loc) · 1.28 KB
/
rector.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
name: Rector
on:
pull_request: null
jobs:
rector:
# run only on core developers with access
if: github.event.pull_request.head.repo.full_name == github.repository
runs-on: ubuntu-latest
steps:
-
uses: actions/checkout@v3
with:
token: ${{ secrets.ACCESS_TOKEN }}
-
uses: shivammathur/setup-php@v2
with:
php-version: 8.2
- uses: "ramsey/composer-install@v1"
## First run Rector - here can't be --dry-run !!! it would stop the job with it and not commit anything in the future
- run: vendor/bin/rector process ${{ matrix.directories }} --ansi
- run: vendor/bin/ecs check --fix --ansi
# see https://github.com/EndBug/add-and-commit
-
# commit only to core contributors who have repository access
if: github.event.pull_request.head.repo.full_name == github.repository
uses: EndBug/add-and-commit@v9
with:
default_author: github_actions
message: "🧹✨"
add: "*"
push: origin HEAD:${{ github.head_ref }} --force