Merge pull request #328 from senacor/dependabot/maven/org.apache.mave… #880
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@v4 | |
- name: Set up JDK 17 | |
# build with JDK 8 because of issue https://github.com/trautonen/coveralls-maven-plugin/issues/112 | |
uses: actions/setup-java@v4 | |
with: | |
distribution: zulu | |
java-version: 17 | |
# Initializes the CodeQL tools for scanning. | |
- name: Initialize CodeQL | |
uses: github/codeql-action/init@v3 | |
with: | |
languages: 'java' | |
- name: Build and test with Maven | |
run: $MVN_CMD install | |
- name: upload test results | |
uses: actions/upload-artifact@v4 # 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@v3 |