Quality analysis #625
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: 'Quality analysis' | |
on: | |
push: | |
branches: | |
- master | |
- release | |
paths-ignore: | |
- '*.md' | |
pull_request: | |
paths-ignore: | |
- '*.md' | |
schedule: | |
- cron: '42 16 * * 4' | |
env: | |
MVN_CMD: "./mvnw --settings .cicd.settings.xml -e -B -V" | |
jobs: | |
code-analysis: | |
runs-on: ubuntu-22.04 | |
env: | |
COVERALLS_REPO_TOKEN_EXISTS: ${{ secrets.COVERALLS_REPO_TOKEN != '' }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Set up JDK 8 | |
# build with JDK 8 because of issue https://github.com/trautonen/coveralls-maven-plugin/issues/112 | |
uses: actions/setup-java@v3 | |
with: | |
distribution: zulu | |
java-version: 8 | |
# Initializes the CodeQL tools for scanning. | |
- name: Initialize CodeQL | |
uses: github/codeql-action/init@v2 | |
with: | |
languages: 'java' | |
- name: Build and test with Maven | |
run: $MVN_CMD install | |
- name: upload test results | |
uses: actions/upload-artifact@v3 # upload test results | |
if: success() || failure() # run this step even if previous step failed | |
with: | |
name: test-results | |
path: '**/target/*-reports/TEST-*.xml' | |
- name: Execute Maven coveralls Plugin | |
if: ${{ env.COVERALLS_REPO_TOKEN_EXISTS == 'true' }} | |
env: | |
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }} | |
GITHUB_EVENT_NAME: ${{ github.event_name }} | |
GITHUB_EVENT_PATH: ${{ github.event_path }} | |
run: $MVN_CMD coveralls:report -DrepoToken=$COVERALLS_REPO_TOKEN -DserviceName=GitHub-Actions | |
- name: Perform CodeQL Analysis | |
uses: github/codeql-action/analyze@v2 |