Skip to content

Commit

Permalink
Updated CI actions.
Browse files Browse the repository at this point in the history
  • Loading branch information
laurentmuller committed Mar 4, 2024
1 parent ea5b17f commit 526df2c
Show file tree
Hide file tree
Showing 9 changed files with 207 additions and 110 deletions.
65 changes: 0 additions & 65 deletions .github/workflows/ci.yaml

This file was deleted.

28 changes: 28 additions & 0 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Lint

on: [ push, pull_request ]

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4

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

- name: Install dependencies
run: composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist

- name: Lint Markdown
uses: DavidAnson/markdownlint-cli2-action@v15
with:
globs: '*.md'

- name: Validate Composer
run: composer validate --strict
26 changes: 26 additions & 0 deletions .github/workflows/php-cs-fixer.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: PHP-CS-Fixer

on: [ push, pull_request ]

env:
PHP_CS_FIXER_IGNORE_ENV: 1

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4

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

- name: Install dependencies
run: composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist

- name: Run PHP CS Fixer
run: vendor/bin/php-cs-fixer fix --diff --dry-run --show-progress=none
23 changes: 23 additions & 0 deletions .github/workflows/php_stan.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: PHPStan

on: [ push, pull_request ]

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4

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

- name: Install dependencies
run: composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist

- name: Run PHPStan
run: vendor/bin/phpstan analyze --no-progress
31 changes: 31 additions & 0 deletions .github/workflows/php_unit.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: PHPUnit

on: [ push, pull_request ]

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Install PHP with extensions
uses: shivammathur/setup-php@v2
with:
php-version: '8.2'
coverage: xdebug

- name: Install dependencies
run: composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist

- name: Run PHPUnit
run: vendor/bin/phpunit --no-progress --coverage-clover ./clover.xml

- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4.0.1
with:
token: ${{ secrets.CODECOV_TOKEN }}
slug: 'laurentmuller/HighchartsBundle'
disable_search: true
file: ./clover.xml
23 changes: 23 additions & 0 deletions .github/workflows/pslam.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Psalm

on: [ push, pull_request ]

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4

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

- name: Install dependencies
run: composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist

- name: Run Psalm
run: vendor/bin/psalm --config=psalm.xml --no-progress
23 changes: 23 additions & 0 deletions .github/workflows/rector.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Rector

on: [ push, pull_request ]

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4

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

- name: Install dependencies
run: composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist

- name: Run Rector
run: vendor/bin/rector process --dry-run --no-progress-bar
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## [Unreleased]

- Merged GitHub actions.
- Updated CI actions.
- Completed tests.
- Added new tests.

Expand Down

0 comments on commit 526df2c

Please sign in to comment.