Skip to content

Commit

Permalink
improve workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
mozex committed Jun 28, 2024
1 parent c922371 commit ba5a22e
Show file tree
Hide file tree
Showing 3 changed files with 57 additions and 44 deletions.
28 changes: 28 additions & 0 deletions .github/workflows/code-analysis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Code Analysis

on:
push:
paths:
- '**.php'
- 'phpstan.neon.dist'
- '.github/workflows/code-analysis.yml'

jobs:
phpstan:
name: PHPStan
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.2'
coverage: none

- name: Install composer dependencies
uses: ramsey/composer-install@v3

- name: Run PHPStan
run: ./vendor/bin/phpstan --memory-limit=-1 --error-format=github
29 changes: 29 additions & 0 deletions .github/workflows/code-styling.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Code Styling

on:
push:
paths:
- '**.php'

permissions:
contents: write

jobs:
pint:
name: Pint
runs-on: ubuntu-latest
timeout-minutes: 5

steps:
- name: Checkout code
uses: actions/checkout@v4
with:
ref: ${{ github.head_ref }}

- name: Fix PHP code style issues
uses: aglipanci/[email protected]

- name: Commit changes
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: Fix styling
44 changes: 0 additions & 44 deletions .github/workflows/formats.yml

This file was deleted.

0 comments on commit ba5a22e

Please sign in to comment.