Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CI: separate codecov to another job #229

Merged
merged 4 commits into from
Nov 22, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
47 changes: 35 additions & 12 deletions .github/workflows/github-actions.yml
Original file line number Diff line number Diff line change
@@ -1,20 +1,26 @@
name: build
on: [push, pull_request]
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
pipeline:
name: jhlight pipeline
tests:
name: tests
runs-on: ubuntu-latest
if: "!contains(github.event.head_commit.message, '[ci skip]') && !contains(github.event.head_commit.message, '[skip ci]') && !contains(github.event.pull_request.title, '[skip ci]') && !contains(github.event.pull_request.title, '[ci skip]')"
timeout-minutes: 40
timeout-minutes: 20
steps:
- uses: actions/checkout@v2
- name: 'Setup: checkout project'
uses: actions/checkout@v2
- name: 'Setup: Node.js'
uses: actions/setup-node@v2.4.1
with:
node-version: 16.13.0
- name: 'Setup: update npm'
run: npm install -g npm
- name: 'Setup: Java'
- name: 'Setup: Java 17'
uses: actions/setup-java@v2
with:
distribution: 'temurin'
Expand All @@ -39,9 +45,26 @@ jobs:
run: |
chmod +x mvnw
./mvnw clean verify
- uses: codecov/codecov-action@v2
- name: 'Artifact: upload JaCoCo report'
uses: actions/upload-artifact@v2
with:
token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos
files: ./target/jacoco/jacoco.xml
fail_ci_if_error: true # optional (default = false)
verbose: true # optional (
name: jacoco
path: '${{ github.workspace }}/target/jacoco/jacoco.xml'
retention-days: 1
codecov:
needs: tests
name: codecov
runs-on: ubuntu-latest
steps:
- name: 'Setup: checkout project'
uses: actions/checkout@v2
- name: 'Artifact: download JaCoCo report'
uses: actions/download-artifact@v2
with:
name: jacoco
- name: 'Codecov: sending analyzis...'
uses: codecov/codecov-action@v2
with:
files: jacoco.xml
fail_ci_if_error: true
verbose: true