spotless fixes (#441) #74
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: CI | |
on: push | |
jobs: | |
verify: | |
name: Verify Code | |
runs-on: ubuntu-latest | |
env: | |
COVERITY: coverity_tool | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Setup Maven Central | |
uses: actions/setup-java@v2 | |
with: | |
java-version: 8.0.292+10 | |
distribution: 'adopt' | |
- name: Cache Local Maven Repository | |
uses: actions/cache@v2 | |
with: | |
path: ~/.m2/repository | |
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }} | |
- name: Install test dependencies | |
run: cd / && sudo apt-get update && sudo apt-get install wget rpm2cpio && sudo wget -q https://download.rockylinux.org/pub/rocky/8/AppStream/x86_64/os/Packages/g/geolite2-city-20180605-1.el8.noarch.rpm && sudo wget -q https://download.rockylinux.org/pub/rocky/8/AppStream/x86_64/os/Packages/g/geolite2-country-20180605-1.el8.noarch.rpm && rpm2cpio geolite2-city-20180605-1.el8.noarch.rpm | sudo cpio -i --make-directories && rpm2cpio geolite2-country-20180605-1.el8.noarch.rpm | sudo cpio -i --make-directories | |
- name: Compile Test and Verify | |
run: mvn --batch-mode clean verify | |
- name: Cache Coverity | |
id: cache_coverity | |
uses: actions/cache@v2 | |
with: | |
path: ${{ env.COVERITY }} | |
key: coverity | |
- name: Download Coverity | |
if: steps.cache_coverity.outputs.cache-hit != 'true' | |
run: | | |
wget --quiet https://scan.coverity.com/download/linux64 --post-data "token=${{ secrets.COVERITY_TOKEN }}&project=${{ vars.COVERITY_PROJECT_URL_NAME }}" -O ${{ env.COVERITY }}.tgz | |
mkdir -p ${{ env.COVERITY }} | |
tar zxvf ${{ env.COVERITY }}.tgz -C ${{ env.COVERITY }} --strip-components 1 | |
- name: Compile Coverity | |
run: | | |
${{ env.COVERITY }}/bin/cov-build --dir cov-int mvn -DskipTests=true --batch-mode clean compile | |
tar czvf sources.tgz cov-int | |
- name: Upload to Coverity | |
run: curl --silent --form token=${{ secrets.COVERITY_TOKEN }} --form email=${{ secrets.COVERITY_EMAIL }} --form [email protected] --form version="${GITHUB_REF##*/}" --form description="automated upload" https://scan.coverity.com/builds?project=${{ vars.COVERITY_PROJECT_URL_NAME }} |