File tree Expand file tree Collapse file tree 2 files changed +44
-4
lines changed
Expand file tree Collapse file tree 2 files changed +44
-4
lines changed Original file line number Diff line number Diff line change 4242 - name : Install dependencies
4343 run : composer install --prefer-dist
4444
45- - name : Coding Standard Checks
46- if : ${{ matrix.php-versions == '8.0' }}
47- run : PHP_CS_FIXER_IGNORE_ENV=1 ./bin/php-cs-fixer fix --dry-run --diff
48-
4945 - name : Static Analysis
5046 if : ${{ matrix.php-versions == '8.0' }}
5147 run : ./bin/psalm.phar --no-cache
Original file line number Diff line number Diff line change 1+ name : PHP CS Fixer
2+
3+ on :
4+ pull_request :
5+
6+ permissions :
7+ contents : write
8+
9+ jobs :
10+ cs-fixer :
11+ runs-on : ubuntu-22.04
12+ steps :
13+ - uses : actions/checkout@v6
14+ with :
15+ ref : ${{ github.head_ref }}
16+ token : ${{ secrets.GITHUB_TOKEN }}
17+
18+ - name : Install PHP
19+ uses : shivammathur/setup-php@v2
20+ with :
21+ php-version : ' 8.0'
22+ tools : composer:v2.2
23+ env :
24+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
25+
26+ - name : Cache Composer packages
27+ uses : actions/cache@v5
28+ with :
29+ path : vendor
30+ key : ${{ runner.os }}-php-cs-fixer-${{ hashFiles('**/composer.lock') }}
31+ restore-keys : |
32+ ${{ runner.os }}-php-cs-fixer-
33+
34+ - name : Install dependencies
35+ run : composer install --prefer-dist
36+
37+ - name : Run PHP CS Fixer
38+ run : ./bin/php-cs-fixer fix --diff
39+
40+ - name : Commit CS Fixer fixes
41+ uses : stefanzweifel/git-auto-commit-action@v5
42+ with :
43+ commit_message : " style: apply php-cs-fixer changes"
44+ commit_author : " github-actions[bot] <github-actions[bot]@users.noreply.github.com>"
You can’t perform that action at this time.
0 commit comments