From ab88749b2d60139649c2f607a6a001db0d19c3b4 Mon Sep 17 00:00:00 2001 From: KingJul1an <80104042+KingJul1an@users.noreply.github.com> Date: Wed, 19 Jun 2024 14:38:48 +0200 Subject: [PATCH] fix(docs): dead link in sonarExecuteScan (#4936) * fix dead link in sonarExecuteScan.yaml https://docs.sonarqube.org/display/SCAN/Analyzing+with+SonarQube+Scanner leads to "Page not found" * Update sonarExecuteScan.yaml * Update sonarExecuteScan.yaml typo * Update sonarExecuteScan_generated.go --------- Co-authored-by: Christopher Fenner <26137398+CCFenner@users.noreply.github.com> --- cmd/sonarExecuteScan_generated.go | 4 ++-- resources/metadata/sonarExecuteScan.yaml | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/cmd/sonarExecuteScan_generated.go b/cmd/sonarExecuteScan_generated.go index c818d61499..3620a877b9 100644 --- a/cmd/sonarExecuteScan_generated.go +++ b/cmd/sonarExecuteScan_generated.go @@ -155,7 +155,7 @@ func SonarExecuteScanCommand() *cobra.Command { var createSonarExecuteScanCmd = &cobra.Command{ Use: STEP_NAME, Short: "Executes the Sonar scanner", - Long: `The step executes the [sonar-scanner](https://docs.sonarqube.org/display/SCAN/Analyzing+with+SonarQube+Scanner) cli command to scan the defined sources and publish the results to a SonarQube instance.`, + Long: `The step executes the [sonar-scanner](https://docs.sonarsource.com/sonarqube/latest/analyzing-source-code/scanners/sonarscanner/) cli command to scan the defined sources and publish the results to a SonarQube instance. Check [source repository](https://github.com/SonarSource/sonar-scanner-cli) for more details.`, PreRunE: func(cmd *cobra.Command, _ []string) error { startTime = time.Now() log.SetStepName(STEP_NAME) @@ -256,7 +256,7 @@ func addSonarExecuteScanFlags(cmd *cobra.Command, stepConfig *sonarExecuteScanOp cmd.Flags().StringVar(&stepConfig.CustomScanVersion, "customScanVersion", os.Getenv("PIPER_customScanVersion"), "A custom version used along with the uploaded scan results.") cmd.Flags().StringVar(&stepConfig.ProjectKey, "projectKey", os.Getenv("PIPER_projectKey"), "The project key identifies the project in SonarQube.") cmd.Flags().StringSliceVar(&stepConfig.CoverageExclusions, "coverageExclusions", []string{}, "A list of patterns that should be excluded from the coverage scan.") - cmd.Flags().BoolVar(&stepConfig.InferJavaBinaries, "inferJavaBinaries", false, "Find the location of generated Java class files in all modules and pass the option `sonar.java.binaries to the sonar tool.") + cmd.Flags().BoolVar(&stepConfig.InferJavaBinaries, "inferJavaBinaries", false, "Find the location of generated Java class files in all modules and pass the option `sonar.java.binaries` to the sonar tool.") cmd.Flags().BoolVar(&stepConfig.InferJavaLibraries, "inferJavaLibraries", false, "If the parameter `m2Path` is configured for the step `mavenExecute` in the general section of the configuration, pass it as option `sonar.java.libraries` to the sonar tool.") cmd.Flags().StringSliceVar(&stepConfig.Options, "options", []string{}, "A list of options which are passed to the sonar-scanner.") cmd.Flags().BoolVar(&stepConfig.WaitForQualityGate, "waitForQualityGate", false, "Whether the scan should wait for and consider the result of the quality gate.") diff --git a/resources/metadata/sonarExecuteScan.yaml b/resources/metadata/sonarExecuteScan.yaml index e3230f13de..43be0d24b0 100644 --- a/resources/metadata/sonarExecuteScan.yaml +++ b/resources/metadata/sonarExecuteScan.yaml @@ -1,8 +1,8 @@ metadata: name: sonarExecuteScan description: Executes the Sonar scanner - longDescription: "The step executes the [sonar-scanner](https://docs.sonarqube.org/display/SCAN/Analyzing+with+SonarQube+Scanner) - cli command to scan the defined sources and publish the results to a SonarQube instance." + longDescription: "The step executes the [sonar-scanner](https://docs.sonarsource.com/sonarqube/latest/analyzing-source-code/scanners/sonarscanner/) + cli command to scan the defined sources and publish the results to a SonarQube instance. Check [source repository](https://github.com/SonarSource/sonar-scanner-cli) for more details." spec: inputs: secrets: @@ -126,7 +126,7 @@ spec: - name: inferJavaBinaries type: bool description: "Find the location of generated Java class files in all modules - and pass the option `sonar.java.binaries to the sonar tool." + and pass the option `sonar.java.binaries` to the sonar tool." scope: - PARAMETERS - STAGES