Skip to content

chore: update SonarCloud action in CI to minvws/action-sonarqube #36

chore: update SonarCloud action in CI to minvws/action-sonarqube

chore: update SonarCloud action in CI to minvws/action-sonarqube #36

Workflow file for this run

name: CI
on:
workflow_dispatch:
push:
branches: [ main ]
tags: [ v* ]
pull_request:
env:
PHP_VERSION: 8.2
jobs:
validate:
name: 'Build & validate'
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v5
with:
fetch-depth: 0
- name: Install PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ env.PHP_VERSION }}
extensions: xdebug, zip, pcov
- name: 'Composer install'
run: composer install --no-interaction --no-scripts --no-progress --prefer-dist --no-ansi
- name: Static analysis with PHPStan
run: composer phpstan
- name: Coding style PSR12 Check
run: composer phpcs
- name: Execute tests (Unit and Feature)
run: composer test
sonar:
name: SonarCloud
runs-on: ubuntu-22.04
needs: validate
steps:
- name: Checkout repository
uses: actions/checkout@v5
with:
fetch-depth: 0
- name: Run SonarQube scan
uses: minvws/action-sonarqube@v1
with:
sonar-token: ${{ secrets.SONAR_TOKEN }}