SQSCANGHA-26 Warning instead of failure for Maven/Gradle projects

This commit is contained in:
antoine.vinot
2024-05-20 16:17:53 +02:00
committed by Antoine Vinot
parent fed3555e67
commit 320b72385a
2 changed files with 14 additions and 16 deletions

View File

@@ -21,13 +21,13 @@ if [[ -n "${SONAR_ROOT_CERT}" ]]; then
fi
if [[ -f "${INPUT_PROJECTBASEDIR%/}/pom.xml" ]]; then
echo "Maven project detected. You should run the goal 'org.sonarsource.scanner.maven:sonar' during build rather than using this GitHub Action."
exit 1
echo "WARNING! Maven project detected. Sonar recommends running the 'org.sonarsource.scanner.maven:sonar-maven-plugin:sonar' goal during the build process instead of using this GitHub Action
to get more accurate results."
fi
if [[ -f "${INPUT_PROJECTBASEDIR%/}/build.gradle" ]]; then
echo "Gradle project detected. You should use the SonarQube plugin for Gradle during build rather than using this GitHub Action."
exit 1
echo "WARNING! Gradle project detected. Sonar recommends using the SonarQube plugin for Gradle during the build process instead of using this GitHub Action
to get more accurate results."
fi
debug_flag=''