From f88bd227ab09a6a8f15fa9daaa0e4edb10d9eb33 Mon Sep 17 00:00:00 2001 From: Arne Keller Date: Thu, 28 Jan 2021 14:48:56 +0100 Subject: [PATCH] CI: Move calculation into script --- .gitlab-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index b493f11..1d3c6a7 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -5,7 +5,7 @@ build: - mvn -Dmaven.repo.local=/tmp/m2/repository -Duser.home=/tmp jacoco:prepare-agent test jacoco:report - python3 /opt/cover2cover.py target/site/jacoco/jacoco.xml src/main/java > target/site/cobertura.xml - python3 /opt/source2filename.py target/site/cobertura.xml - - "head -n 1 target/site/cobertura.xml | rg --only-matching -r '\$1' 'line-rate=\"([0-9.]+)\"' | awk '{ print \"Test Coverage: \" (\$1 * 100) \"%\" }'" + - "head -n 1 target/site/cobertura.xml | rg --only-matching -r '\\$1' 'line-rate=\"([0-9.]+)\"' | awk '{ print \"Test Coverage: \" (\$1 * 100) \"%\" }'" artifacts: reports: cobertura: target/site/cobertura.xml