mirror of
https://github.com/Athou/commafeed.git
synced 2026-03-21 21:37:29 +00:00
run sonarqube as part of the CI
This commit is contained in:
38
.github/workflows/sonar.yml
vendored
Normal file
38
.github/workflows/sonar.yml
vendored
Normal file
@@ -0,0 +1,38 @@
|
||||
name: SonarQube
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
pull_request:
|
||||
types: [ opened, synchronize, reopened ]
|
||||
|
||||
env:
|
||||
JAVA_VERSION: 21
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
# Checkout
|
||||
- name: Checkout
|
||||
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
# Setup
|
||||
- name: Set up JDK
|
||||
uses: actions/setup-java@v4
|
||||
with:
|
||||
java-version: ${{ env.JAVA_VERSION }}
|
||||
distribution: "temurin"
|
||||
cache: "maven"
|
||||
|
||||
- name: Install Playwright dependencies
|
||||
run: sudo apt-get install -y libgbm1
|
||||
|
||||
# Run test coverage and SonarQube analysis
|
||||
- name: Analyze with SonarQube
|
||||
env:
|
||||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
|
||||
run: mvn --batch-mode verify sonar:sonar -Dsonar.projectKey=Athou_commafeed
|
||||
Reference in New Issue
Block a user