Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
72 changes: 59 additions & 13 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,31 @@ jobs:
sarif_file: 'trivy-fs-results.sarif'
category: 'trivy-source'

composer:
name: Checks / Composer
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v6

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

- name: Validate
run: composer validate

- name: Install dependencies
run: composer install --prefer-dist --no-progress --ignore-platform-reqs

- name: Audit
env:
COMPOSER_NO_AUDIT: 0
run: composer audit

format:
name: Checks / Format
runs-on: ubuntu-latest
Expand All @@ -96,15 +121,18 @@ jobs:
- run: git checkout HEAD^2
if: github.event_name == 'pull_request'

- name: Validate composer.json and composer.lock
run: |
docker run --rm -v $PWD:/app composer:2.8 sh -c \
"composer validate"
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.3'
tools: composer:v2
coverage: none

- name: Install dependencies
run: composer install --prefer-dist --no-progress --ignore-platform-reqs

- name: Run Linter
run: |
docker run --rm -v $PWD:/app composer:2.8 sh -c \
"composer install --profile --ignore-platform-reqs && composer lint"
run: composer lint

analyze:
name: Checks / Analyze
Expand All @@ -113,15 +141,33 @@ jobs:
- name: Check out the repo
uses: actions/checkout@v6

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

- name: Install dependencies
run: composer install --prefer-dist --no-progress --ignore-platform-reqs

- name: Run PHPStan
run: |
docker run --rm -v $PWD:/app composer:2.8 sh -c \
"composer install --profile --ignore-platform-reqs && composer analyze"
run: composer analyze

locale:
name: Checks / Locale
runs-on: ubuntu-latest
steps:
- name: Check out the repo
uses: actions/checkout@v6

- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: '24'

- name: Run Locale check
run: |
docker run --rm -v $PWD:/app node:24-alpine sh -c \
"cd /app/.github/workflows/static-analysis/locale && node index.js"
run: node .github/workflows/static-analysis/locale/index.js

matrix:
name: Tests / Matrix
Expand Down
6 changes: 2 additions & 4 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,7 @@
"test": "vendor/bin/phpunit",
"lint": "vendor/bin/pint --test --config pint.json",
"format": "vendor/bin/pint --config pint.json",
"bench": "vendor/bin/phpbench run --report=benchmark",
"analyze": "./vendor/bin/phpstan analyse -c phpstan.neon --memory-limit=1G"
"analyze": "./vendor/bin/phpstan analyse -c phpstan.neon --memory-limit=1G"
},
"autoload": {
"psr-4": {
Expand Down Expand Up @@ -102,8 +101,7 @@
"phpstan/phpstan": "^2.0",
"textalk/websocket": "1.5.*",
"czproject/git-php": "4.*",
"laravel/pint": "1.*",
"phpbench/phpbench": "1.*"
"laravel/pint": "1.*"
},
"provide": {
"ext-phpiredis": "*"
Expand Down
Loading
Loading