Main workflow #565
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
# This workflow will build a Java project with Maven | |
name: Main workflow | |
on: | |
push: | |
branches: [ master ] | |
pull_request: | |
branches: [ master ] | |
schedule: | |
- cron: 0 0 * * * | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up JDK 11 | |
uses: actions/setup-java@v1 | |
with: | |
java-version: 11 | |
- name: Build with Maven | |
run: mvn clean org.jacoco:jacoco-maven-plugin:prepare-agent package --file pom.xml | |
- name: Analyze with SonarCloud | |
run: mvn -B verify sonar:sonar -Dsonar.projectKey=pl.zankowski:iextrading4j -Dsonar.organization=wojciechzankowski-github -Dsonar.host.url=https://sonarcloud.io -Dsonar.login=$SONAR_TOKEN | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} | |
- name: Code coverage | |
run: source <(sudo curl -s https://codecov.io/bash) |