Skip to content

Commit 3e29dcc

Browse files
authored
Create code-style.yml
1 parent e84a824 commit 3e29dcc

1 file changed

Lines changed: 42 additions & 0 deletions

File tree

.github/workflows/code-style.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: Coding Guidelines
2+
3+
on:
4+
pull_request:
5+
push:
6+
paths:
7+
- '.github/workflows/**'
8+
- '**.php'
9+
- 'phpunit.xml'
10+
- 'composer.json'
11+
- 'composer.lock'
12+
13+
jobs:
14+
php-cs-fixer:
15+
runs-on: ubuntu-latest
16+
17+
steps:
18+
- name: Checkout code
19+
uses: actions/checkout@v4
20+
with:
21+
ref: ${{ github.head_ref }}
22+
23+
- name: Setup PHP 🔧
24+
uses: shivammathur/setup-php@v2
25+
with:
26+
php-version: 8.3
27+
extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick
28+
coverage: none
29+
tools: composer:v2
30+
env:
31+
COMPOSER_TOKEN: ${{ secrets.TOKEN }}
32+
33+
- name: Install Dependencies 🔧
34+
run: composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist
35+
36+
- name: Run Pint
37+
run: vendor/bin/pint
38+
39+
- name: Commit changes
40+
uses: stefanzweifel/git-auto-commit-action@v6
41+
with:
42+
commit_message: Fixed code style

0 commit comments

Comments
 (0)