Skip to content

Commit

Permalink
Add lint on code
Browse files Browse the repository at this point in the history
  • Loading branch information
ndousson committed Dec 22, 2023
1 parent de9cfd0 commit 5f3ce6a
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 12 deletions.
15 changes: 5 additions & 10 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,31 +29,26 @@ jobs:
- name: Composer dependencies
run: COMPOSER_UPDATE_FLAGS+="${{matrix.composer_update_flags}}" make vendor

- name: Lint
run: find . -name '*.php' ! -path './vendor/' | grep -ve /tests/ -ve /src/ | parallel -j 4 php -l {}

- name: PHPUnit
run: make phpunit

static-analysis:
runs-on: ubuntu-latest
name: Static analysis
strategy:
fail-fast: false
matrix:
include:
- php: 8.1
composer_update_flags: --prefer-lowest
- php: 8.1
- php: 8.2

steps:
- uses: actions/checkout@v2

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: "${{ matrix.php }}"
php-version: "8.2"

- name: Composer dependencies
run: COMPOSER_UPDATE_FLAGS+="${{matrix.composer_update_flags}}" make vendor
run: make vendor

- name: Composer validate
run: make composer-validate
Expand Down
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@
},
"require-dev": {
"friendsofphp/php-cs-fixer": "^3.9",
"phpstan/phpstan": "1.8.2",
"phpstan/phpstan-phpunit": "1.1.1",
"phpstan/phpstan": "1.10.50",
"phpstan/phpstan-phpunit": "1.3.15",
"phpunit/phpunit": "^10.4.2",
"symfony/var-dumper": ">=6.3.8"
}
Expand Down

0 comments on commit 5f3ce6a

Please sign in to comment.