This is an automated email from the ASF dual-hosted git repository.
adoroszlai pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ozone.git
The following commit(s) were added to refs/heads/master by this push:
new 5983ccc0ef HDDS-10101. Set sonar.coverage.jacoco.xmlReportPaths (#5972)
5983ccc0ef is described below
commit 5983ccc0ef66defa8ae27cd09ac0f1ca3471bcb0
Author: Doroszlai, Attila <[email protected]>
AuthorDate: Sat Jan 27 08:05:24 2024 +0100
HDDS-10101. Set sonar.coverage.jacoco.xmlReportPaths (#5972)
---
hadoop-ozone/dev-support/checks/sonar.sh | 11 ++++-------
1 file changed, 4 insertions(+), 7 deletions(-)
diff --git a/hadoop-ozone/dev-support/checks/sonar.sh
b/hadoop-ozone/dev-support/checks/sonar.sh
index 9a36c70a66..27a971f691 100755
--- a/hadoop-ozone/dev-support/checks/sonar.sh
+++ b/hadoop-ozone/dev-support/checks/sonar.sh
@@ -23,11 +23,8 @@ if [ ! "$SONAR_TOKEN" ]; then
exit 1
fi
-#Workaround: Sonar expects per-project Sonar XML report, but we have one,
combined. Sonar seems to handle it well.
-# Only the classes from the current project will be used. We can copy the
same, combined report to all the subprojects.
-if [ -f "$PROJECT_DIR/target/coverage/all.xml" ]; then
- find "$PROJECT_DIR" -name pom.xml | grep -v target | xargs dirname | xargs
-n1 -IDIR mkdir -p DIR/target/coverage/
- find "$PROJECT_DIR" -name pom.xml | grep -v target | xargs dirname | xargs
-n1 -IDIR cp "$PROJECT_DIR/target/coverage/all.xml" DIR/target/coverage/
-fi
-mvn -B verify -DskipShade -DskipTests -Dskip.npx -Dskip.installnpx
org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar
-Dsonar.host.url=https://sonarcloud.io -Dsonar.organization=apache
-Dsonar.projectKey=hadoop-ozone
+mvn -V -B -DskipShade -DskipTests -Dskip.npx -Dskip.installnpx
--no-transfer-progress \
+ -Dsonar.coverage.jacoco.xmlReportPaths="$(pwd)/target/coverage/all.xml" \
+ -Dsonar.host.url=https://sonarcloud.io -Dsonar.organization=apache
-Dsonar.projectKey=hadoop-ozone \
+ verify org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]