From 7abd92ac465eb83eea24d6d6941b3c13405f1bb2 Mon Sep 17 00:00:00 2001
From: n-b-sonar <15651687+n-b-sonar@users.noreply.github.com>
Date: Wed, 12 Jun 2019 22:25:51 +0200
Subject: [PATCH 01/77] Description update
---
README.md | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/README.md b/README.md
index b287fef..30c3153 100644
--- a/README.md
+++ b/README.md
@@ -1,9 +1,11 @@
# Scan your code with SonarCloud
-> Using this GitHub Action, scan your code with [SonarCloud](https://sonarcloud.io/) to detects bugs, vulnerabilities and code smells in more than 25 programming languages!
+Using this GitHub Action, scan your code with [SonarCloud](https://sonarcloud.io/) to detects bugs, vulnerabilities and code smells in more than 20 programming languages!
+SonarCloud is the leading product for Continuous Code Quality online, totally free for open-source projects. It supports all major programming languages, including C#, VB .Net, JavaScript, TypeScript, C/C++ and many more. If your code is closed source, SonarCloud also offers a paid plan to run private analyses
+
## Requirements
* Have an account on SonarCloud. [Sign up for free now](https://sonarcloud.io/sessions/init/github) if it's not already the case!
From c99fa9533766a223fa21fc5a57fb9adf654385bc Mon Sep 17 00:00:00 2001
From: Simon Brandhof
Date: Wed, 31 Jul 2019 09:55:15 +0200
Subject: [PATCH 02/77] Fix installation of nodeJS in the Docker image
---
Dockerfile | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/Dockerfile b/Dockerfile
index fb94dbe..dfa5265 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -19,10 +19,11 @@ ENV SONAR_SCANNER_HOME=${SONAR_SCANNER_HOME} \
ENV PATH=${PATH}:${SONAR_SCANNER_HOME}/bin:${NODEJS_HOME}/bin
+WORKDIR /opt
+
RUN apt-get update \
- && apt-get install -y --no-install-recommends wget \
- && apt-get install -y --no-install-recommends git \
- && apt-get install -y --no-install-recommends jq
+ && apt-get install -y --no-install-recommends wget git jq unzip tar xz-utils \
+ && rm -rf /var/lib/apt/lists/*
RUN wget -U "sonarcloud-github-action" -q -O sonar-scanner-cli.zip https://binaries.sonarsource.com/Distribution/sonar-scanner-cli/sonar-scanner-cli-${SONAR_SCANNER_VERSION}.zip \
&& unzip sonar-scanner-cli.zip \
@@ -30,7 +31,7 @@ RUN wget -U "sonarcloud-github-action" -q -O sonar-scanner-cli.zip https://binar
&& mv sonar-scanner-${SONAR_SCANNER_VERSION} ${SONAR_SCANNER_HOME}
RUN wget -q -O nodejs.tar.xz https://nodejs.org/dist/${NODEJS_VERSION}/node-${NODEJS_VERSION}-linux-x64.tar.xz \
- && tar Jxf nodejs.tar.xz \
+ && tar -Jxf nodejs.tar.xz \
&& mv node-${NODEJS_VERSION}-linux-x64 ${NODEJS_HOME}
RUN npm install -g typescript
From f0d459e4022450fe283b2b07d0f05f0498f22603 Mon Sep 17 00:00:00 2001
From: Simon Brandhof
Date: Thu, 1 Aug 2019 11:01:58 +0200
Subject: [PATCH 03/77] Do not use Docker cache
---
.travis.yml | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/.travis.yml b/.travis.yml
index 8f14929..a1678c7 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,8 +1,8 @@
# any language
-language: ruby
+language: python
services:
- docker
script:
- - docker build -t sonarsource/sonarcloud-github-action .
+ - docker build --no-cache -t sonarsource/sonarcloud-github-action .
From 5f4162d349f54e4e45438dca0336fb3c36146ebb Mon Sep 17 00:00:00 2001
From: Simon Brandhof
Date: Thu, 1 Aug 2019 11:04:30 +0200
Subject: [PATCH 04/77] Print version of Docker on Travis
---
.travis.yml | 1 +
1 file changed, 1 insertion(+)
diff --git a/.travis.yml b/.travis.yml
index a1678c7..45d5e7f 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -5,4 +5,5 @@ services:
- docker
script:
+ - docker -v
- docker build --no-cache -t sonarsource/sonarcloud-github-action .
From c418f3dc9f11e425eadc35c06c2985b97996e927 Mon Sep 17 00:00:00 2001
From: Simon Brandhof
Date: Thu, 1 Aug 2019 16:25:38 +0200
Subject: [PATCH 05/77] Display size of Docker image
---
.travis.yml | 2 ++
1 file changed, 2 insertions(+)
diff --git a/.travis.yml b/.travis.yml
index 45d5e7f..8f10cd3 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -7,3 +7,5 @@ services:
script:
- docker -v
- docker build --no-cache -t sonarsource/sonarcloud-github-action .
+ - docker image ls sonarsource/sonarcloud-github-action
+ - docker history sonarsource/sonarcloud-github-action
From 782b45beda9b7a37f11df8d9e964aaba7692518b Mon Sep 17 00:00:00 2001
From: n-b-sonar <15651687+n-b-sonar@users.noreply.github.com>
Date: Fri, 2 Aug 2019 12:12:22 +0200
Subject: [PATCH 06/77] Adjust highlighted languages
Similar list as https://marketplace.atlassian.com/apps/1219262/sonarcloud?hosting=cloud&tab=overview , less .Net-centric
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 30c3153..f3fd437 100644
--- a/README.md
+++ b/README.md
@@ -4,7 +4,7 @@ Using this GitHub Action, scan your code with [SonarCloud](https://sonarcloud.io
-SonarCloud is the leading product for Continuous Code Quality online, totally free for open-source projects. It supports all major programming languages, including C#, VB .Net, JavaScript, TypeScript, C/C++ and many more. If your code is closed source, SonarCloud also offers a paid plan to run private analyses
+SonarCloud is the leading product for Continuous Code Quality & Code Security online, totally free for open-source projects. It supports all major programming languages, including Java, JavaScript, TypeScript, C#, C/C++ and many more. If your code is closed source, SonarCloud also offers a paid plan to run private analyses
## Requirements
From cc7ffd578d505a7147c563f4c9b814ea6e2ee5a3 Mon Sep 17 00:00:00 2001
From: Fabrice Bellingard
Date: Tue, 13 Aug 2019 09:38:59 +0200
Subject: [PATCH 07/77] Add action.yml for action-v2 needs
---
action.yml | 8 ++++++++
1 file changed, 8 insertions(+)
create mode 100644 action.yml
diff --git a/action.yml b/action.yml
new file mode 100644
index 0000000..52d19dc
--- /dev/null
+++ b/action.yml
@@ -0,0 +1,8 @@
+name: 'SonarCloud Scan'
+description: 'Scan your code with SonarCloud to detect bugs, vulnerabilities and code smells in more than 25 programming languages.'
+branding:
+ icon: 'check'
+ color: 'green'
+runs:
+ using: 'docker'
+ image: 'Dockerfile'
From b1cb00842a9af0abc53544774a5b400708b815ee Mon Sep 17 00:00:00 2001
From: Fabrice Bellingard
Date: Tue, 13 Aug 2019 09:39:51 +0200
Subject: [PATCH 08/77] Update main.workflow sample to use YML syntax
---
README.md | 22 +++++++++++++---------
1 file changed, 13 insertions(+), 9 deletions(-)
diff --git a/README.md b/README.md
index f3fd437..b756695 100644
--- a/README.md
+++ b/README.md
@@ -27,15 +27,19 @@ sonar.sources=.
The workflow, usually declared in `.github/main.workflow`, looks like:
```
-workflow "Main Workflow" {
- on = "push"
- resolves = "SonarCloud Trigger"
-}
-
-action "SonarCloud Trigger" {
- uses = "sonarsource/sonarcloud-github-action@master"
- secrets = ["GITHUB_TOKEN", "SONAR_TOKEN"]
-}
+on: push
+name: Main Workflow
+jobs:
+ sonarCloudTrigger:
+ name: SonarCloud Trigger
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@master
+ - name: SonarCloud Scan
+ uses: sonarsource/sonarcloud-github-action@master
+ env:
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+ SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
```
### Secrets
From 296a30c54de73f744d59960c3026dfa581fcb565 Mon Sep 17 00:00:00 2001
From: Leon Kiefer
Date: Sun, 1 Sep 2019 18:41:12 +0200
Subject: [PATCH 09/77] added syntax highlighting to README
---
README.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index b756695..35f9e55 100644
--- a/README.md
+++ b/README.md
@@ -15,7 +15,7 @@ SonarCloud is the leading product for Continuous Code Quality & Code Security on
Project metadata, including the location to the sources to be analyzed, must be declared in the file `sonar-project.properties` in the base directory:
-```
+```properties
sonar.organization=
sonar.projectKey=
@@ -26,7 +26,7 @@ sonar.sources=.
The workflow, usually declared in `.github/main.workflow`, looks like:
-```
+```yaml
on: push
name: Main Workflow
jobs:
From 89970df79951b97bcc1fa75a0b09b7900dc5359c Mon Sep 17 00:00:00 2001
From: Simon Brandhof
Date: Wed, 4 Sep 2019 10:15:37 +0200
Subject: [PATCH 10/77] Fix workflow filename in README
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 35f9e55..5944694 100644
--- a/README.md
+++ b/README.md
@@ -24,7 +24,7 @@ sonar.projectKey=
Date: Thu, 5 Sep 2019 13:41:10 +0200
Subject: [PATCH 11/77] Add support section to README
---
README.md | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/README.md b/README.md
index 5944694..978cd77 100644
--- a/README.md
+++ b/README.md
@@ -57,6 +57,10 @@ jobs:
* You want to analyze a .NET solution: use the [SonarCloud Azure DevOps Extension](https://marketplace.visualstudio.com/items?itemName=SonarSource.sonarcloud) to analyze your code on SonarCloud with Azure Pipelines
* You want to analyze C/C++ code: rely on our [Travis-CI extension](https://docs.travis-ci.com/user/sonarcloud/) and look at [our sample C/C++ project](https://github.com/SonarSource/sq-com_example_c-sqscanner-travis)
+## Have question or feedback?
+
+To provide feedback (requesting a feature or reporting a bug) please post on the [SonarSource Community Forum](https://community.sonarsource.com/) with the tag `sonarcloud`.
+
## License
The Dockerfile and associated scripts and documentation in this project are released under the LGPLv3 License.
From e48f96aa276213e16c6c6a61653ba5f2fb52904b Mon Sep 17 00:00:00 2001
From: Simon Brandhof
Date: Thu, 12 Sep 2019 14:39:23 +0200
Subject: [PATCH 12/77] Fix rendering of README
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 978cd77..3424fe4 100644
--- a/README.md
+++ b/README.md
@@ -57,7 +57,7 @@ jobs:
* You want to analyze a .NET solution: use the [SonarCloud Azure DevOps Extension](https://marketplace.visualstudio.com/items?itemName=SonarSource.sonarcloud) to analyze your code on SonarCloud with Azure Pipelines
* You want to analyze C/C++ code: rely on our [Travis-CI extension](https://docs.travis-ci.com/user/sonarcloud/) and look at [our sample C/C++ project](https://github.com/SonarSource/sq-com_example_c-sqscanner-travis)
-## Have question or feedback?
+## Have question or feedback?
To provide feedback (requesting a feature or reporting a bug) please post on the [SonarSource Community Forum](https://community.sonarsource.com/) with the tag `sonarcloud`.
From c7f7c25d4114527c3634c44d19d47674909b51b3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Romain=20PR=C3=89VOST?=
Date: Fri, 4 Oct 2019 16:55:48 +0200
Subject: [PATCH 13/77] Add support of project base dir from env
---
README.md | 10 +++++++++-
action.yml | 5 +++++
entrypoint.sh | 2 +-
3 files changed, 15 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 3424fe4..6e0d0b9 100644
--- a/README.md
+++ b/README.md
@@ -4,7 +4,7 @@ Using this GitHub Action, scan your code with [SonarCloud](https://sonarcloud.io
-SonarCloud is the leading product for Continuous Code Quality & Code Security online, totally free for open-source projects. It supports all major programming languages, including Java, JavaScript, TypeScript, C#, C/C++ and many more. If your code is closed source, SonarCloud also offers a paid plan to run private analyses
+SonarCloud is the leading product for Continuous Code Quality & Code Security online, totally free for open-source projects. It supports all major programming languages, including Java, JavaScript, TypeScript, C#, C/C++ and many more. If your code is closed source, SonarCloud also offers a paid plan to run private analyses.
## Requirements
@@ -24,6 +24,14 @@ sonar.projectKey=
Date: Thu, 28 Nov 2019 14:58:03 +0100
Subject: [PATCH 14/77] Clarifications about YAML snippet and GITHUB_TOKEN
---
README.md | 17 +++++++++--------
1 file changed, 9 insertions(+), 8 deletions(-)
diff --git a/README.md b/README.md
index 6e0d0b9..09e5664 100644
--- a/README.md
+++ b/README.md
@@ -24,14 +24,6 @@ sonar.projectKey=
Date: Mon, 30 Mar 2020 19:48:28 +0200
Subject: [PATCH 15/77] Accept triggering from GitHub event "pull_request"
---
README.md | 14 ++++++++++----
entrypoint.sh | 8 --------
2 files changed, 10 insertions(+), 12 deletions(-)
diff --git a/README.md b/README.md
index 09e5664..bbd5945 100644
--- a/README.md
+++ b/README.md
@@ -27,14 +27,20 @@ sonar.sources=.
The workflow, usually declared in `.github/workflows/build.yml`, looks like:
```yaml
-on: push
+on:
+ # Trigger analysis when pushing in master or pull requests, and when creating
+ # a pull request.
+ push:
+ branches:
+ - master
+ pull_request:
+ types: [opened, synchronize, reopened]
name: Main Workflow
jobs:
- sonarCloudTrigger:
- name: SonarCloud Trigger
+ sonarcloud:
runs-on: ubuntu-latest
steps:
- - uses: actions/checkout@master
+ - uses: actions/checkout@v2
- name: SonarCloud Scan
uses: sonarsource/sonarcloud-github-action@master
env:
diff --git a/entrypoint.sh b/entrypoint.sh
index 4820677..079cb96 100755
--- a/entrypoint.sh
+++ b/entrypoint.sh
@@ -17,14 +17,6 @@ if [[ -f "build.gradle" ]]; then
exit 1
fi
-if [[ "${GITHUB_EVENT_NAME}" == "pull_request" ]]; then
- EVENT_ACTION=$(jq -r ".action" "${GITHUB_EVENT_PATH}")
- if [[ "${EVENT_ACTION}" != "opened" ]]; then
- echo "No need to run analysis. It is already triggered by the push event."
- exit 78
- fi
-fi
-
if [[ -z "${SONARCLOUD_URL}" ]]; then
SONARCLOUD_URL="https://sonarcloud.io"
fi
From 6b0def60a4cd3b8312363daaaf908bfd26632f3c Mon Sep 17 00:00:00 2001
From: Simon Brandhof
Date: Mon, 4 May 2020 17:38:52 +0200
Subject: [PATCH 16/77] Document disabling of shallow clones
---
README.md | 3 +++
1 file changed, 3 insertions(+)
diff --git a/README.md b/README.md
index bbd5945..8115215 100644
--- a/README.md
+++ b/README.md
@@ -41,6 +41,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
+ with:
+ # Disabling shallow clone is recommended for improving relevancy of reporting
+ fetch-depth: 0
- name: SonarCloud Scan
uses: sonarsource/sonarcloud-github-action@master
env:
From c35654669e40ece974c8835211c2e8ad9c802df0 Mon Sep 17 00:00:00 2001
From: Ken Huang
Date: Wed, 27 May 2020 17:07:45 +1200
Subject: [PATCH 17/77] Speed-up initialization of action
by using the built image of scanner CLI
---
Dockerfile | 23 +++--------------------
1 file changed, 3 insertions(+), 20 deletions(-)
diff --git a/Dockerfile b/Dockerfile
index dfa5265..9866fb8 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,4 +1,4 @@
-FROM openjdk:11-jre-slim
+FROM sonarsource/sonar-scanner-cli:4.3
LABEL version="0.0.1"
LABEL repository="https://github.com/sonarsource/sonarcloud-github-action"
@@ -12,29 +12,12 @@ LABEL "com.github.actions.color"="green"
ARG SONAR_SCANNER_HOME=/opt/sonar-scanner
ARG NODEJS_HOME=/opt/nodejs
-ENV SONAR_SCANNER_HOME=${SONAR_SCANNER_HOME} \
- SONAR_SCANNER_VERSION=3.3.0.1492 \
- NODEJS_HOME=${NODEJS_HOME} \
- NODEJS_VERSION=v8.12.0
-
ENV PATH=${PATH}:${SONAR_SCANNER_HOME}/bin:${NODEJS_HOME}/bin
WORKDIR /opt
-RUN apt-get update \
- && apt-get install -y --no-install-recommends wget git jq unzip tar xz-utils \
- && rm -rf /var/lib/apt/lists/*
-
-RUN wget -U "sonarcloud-github-action" -q -O sonar-scanner-cli.zip https://binaries.sonarsource.com/Distribution/sonar-scanner-cli/sonar-scanner-cli-${SONAR_SCANNER_VERSION}.zip \
- && unzip sonar-scanner-cli.zip \
- && rm sonar-scanner-cli.zip \
- && mv sonar-scanner-${SONAR_SCANNER_VERSION} ${SONAR_SCANNER_HOME}
-
-RUN wget -q -O nodejs.tar.xz https://nodejs.org/dist/${NODEJS_VERSION}/node-${NODEJS_VERSION}-linux-x64.tar.xz \
- && tar -Jxf nodejs.tar.xz \
- && mv node-${NODEJS_VERSION}-linux-x64 ${NODEJS_HOME}
-
-RUN npm install -g typescript
+# https://help.github.com/en/actions/creating-actions/dockerfile-support-for-github-actions#user
+USER root
COPY entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
From f4c6e4d91ea9785ec823eaeed459042606123402 Mon Sep 17 00:00:00 2001
From: Dag Wieers
Date: Tue, 25 Aug 2020 10:44:51 +0200
Subject: [PATCH 18/77] Add args option to action (#9)
---
Dockerfile | 17 +++++++++--------
README.md | 20 ++++++++++++++++++++
action.yml | 23 ++++++++++++++---------
entrypoint.sh | 4 +---
4 files changed, 44 insertions(+), 20 deletions(-)
diff --git a/Dockerfile b/Dockerfile
index 9866fb8..8bd98e3 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,13 +1,13 @@
FROM sonarsource/sonar-scanner-cli:4.3
-LABEL version="0.0.1"
-LABEL repository="https://github.com/sonarsource/sonarcloud-github-action"
-LABEL homepage="https://github.com/sonarsource/sonarcloud-github-action"
-LABEL maintainer="SonarSource"
-LABEL "com.github.actions.name"="SonarCloud Scan"
-LABEL "com.github.actions.description"="Scan your code with SonarCloud to detect bugs, vulnerabilities and code smells in more than 25 programming languages."
-LABEL "com.github.actions.icon"="check"
-LABEL "com.github.actions.color"="green"
+LABEL version="0.0.1" \
+ repository="https://github.com/sonarsource/sonarcloud-github-action" \
+ homepage="https://github.com/sonarsource/sonarcloud-github-action" \
+ maintainer="SonarSource" \
+ com.github.actions.name="SonarCloud Scan" \
+ com.github.actions.description="Scan your code with SonarCloud to detect bugs, vulnerabilities and code smells in more than 25 programming languages." \
+ com.github.actions.icon="check" \
+ com.github.actions.color="green"
ARG SONAR_SCANNER_HOME=/opt/sonar-scanner
ARG NODEJS_HOME=/opt/nodejs
@@ -19,6 +19,7 @@ WORKDIR /opt
# https://help.github.com/en/actions/creating-actions/dockerfile-support-for-github-actions#user
USER root
+# Prepare entrypoint
COPY entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
ENTRYPOINT ["/entrypoint.sh"]
diff --git a/README.md b/README.md
index 8115215..b197534 100644
--- a/README.md
+++ b/README.md
@@ -59,6 +59,26 @@ with:
projectBaseDir: my-custom-directory
```
+In case you need to add additional analysis parameters, you can use the `args` option:
+
+```yaml
+- name: Analyze with SonarCloud
+ uses: sonarsource/sonarcloud-github-action@master
+ with:
+ projectBaseDir: my-custom-directory
+ args: >
+ -Dsonar.organization=my-organization
+ -Dsonar.projectKey=my-projectkey
+ -Dsonar.python.coverage.reportPaths=coverage.xml
+ -Dsonar.sources=lib/
+ -Dsonar.test.exclusions=tests/**
+ -Dsonar.tests=tests/
+ -Dsonar.verbose=true
+```
+
+More information about possible analysis parameters is found in the documentation at:
+https://sonarcloud.io/documentation/analysis/analysis-parameters/
+
### Secrets
- `SONAR_TOKEN` – **Required** this is the token used to authenticate access to SonarCloud. You can generate a token on your [Security page in SonarCloud](https://sonarcloud.io/account/security/). You can set the `SONAR_TOKEN` environment variable in the "Secrets" settings page of your repository.
diff --git a/action.yml b/action.yml
index 24a9607..7c1c588 100644
--- a/action.yml
+++ b/action.yml
@@ -1,13 +1,18 @@
-name: 'SonarCloud Scan'
-description: 'Scan your code with SonarCloud to detect bugs, vulnerabilities and code smells in more than 25 programming languages.'
+name: SonarCloud Scan
+description: >
+ Scan your code with SonarCloud to detect bugs, vulnerabilities and code smells
+ in more than 25 programming languages.
branding:
- icon: 'check'
- color: 'green'
+ icon: check
+ color: green
runs:
- using: 'docker'
- image: 'Dockerfile'
+ using: docker
+ image: Dockerfile
inputs:
- projectBaseDir:
- description: 'Set the sonar.projectBaseDir analysis property'
+ args:
+ description: Additional arguments to the sonarcloud scanner
required: false
- default: '.'
\ No newline at end of file
+ projectBaseDir:
+ description: Set the sonar.projectBaseDir analysis property
+ required: false
+ default: .
diff --git a/entrypoint.sh b/entrypoint.sh
index 079cb96..7fa41cb 100755
--- a/entrypoint.sh
+++ b/entrypoint.sh
@@ -21,6 +21,4 @@ if [[ -z "${SONARCLOUD_URL}" ]]; then
SONARCLOUD_URL="https://sonarcloud.io"
fi
-sonar-scanner -Dsonar.projectBaseDir=${INPUT_PROJECTBASEDIR} -Dsonar.host.url=${SONARCLOUD_URL}
-
-
+sonar-scanner -Dsonar.projectBaseDir=${INPUT_PROJECTBASEDIR} -Dsonar.host.url=${SONARCLOUD_URL} ${INPUT_ARGS}
From 32ea6119a4bd977dc6307acb6bbbf277152ede95 Mon Sep 17 00:00:00 2001
From: Tobias Mahnke <8829994+nottobe@users.noreply.github.com>
Date: Mon, 11 Jan 2021 14:41:24 +0100
Subject: [PATCH 19/77] update sonar-scanner-cli to 4.5 (#13)
---
Dockerfile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Dockerfile b/Dockerfile
index 8bd98e3..b5ef5b1 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,4 +1,4 @@
-FROM sonarsource/sonar-scanner-cli:4.3
+FROM sonarsource/sonar-scanner-cli:4.5
LABEL version="0.0.1" \
repository="https://github.com/sonarsource/sonarcloud-github-action" \
From 4fed9427eb5092f539cd949002445fbb7d7c01f8 Mon Sep 17 00:00:00 2001
From: Tom Van Braband
Date: Fri, 12 Feb 2021 13:47:14 +0100
Subject: [PATCH 20/77] SC-2971 Unset JAVA_HOME before executing the scanner
---
entrypoint.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/entrypoint.sh b/entrypoint.sh
index 7fa41cb..3f4db4e 100755
--- a/entrypoint.sh
+++ b/entrypoint.sh
@@ -20,5 +20,5 @@ fi
if [[ -z "${SONARCLOUD_URL}" ]]; then
SONARCLOUD_URL="https://sonarcloud.io"
fi
-
+unset JAVA_HOME
sonar-scanner -Dsonar.projectBaseDir=${INPUT_PROJECTBASEDIR} -Dsonar.host.url=${SONARCLOUD_URL} ${INPUT_ARGS}
From de2e56b42aa84d0b1c5b622644ac17e505c9a049 Mon Sep 17 00:00:00 2001
From: Tom Van Braband
Date: Fri, 12 Feb 2021 14:26:17 +0100
Subject: [PATCH 21/77] Upgrade to sonar-scanner-cli:4.6
---
Dockerfile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Dockerfile b/Dockerfile
index b5ef5b1..7b47568 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,4 +1,4 @@
-FROM sonarsource/sonar-scanner-cli:4.5
+FROM sonarsource/sonar-scanner-cli:4.6
LABEL version="0.0.1" \
repository="https://github.com/sonarsource/sonarcloud-github-action" \
From 5c2f7d2ca8f064c7a1bc1dacc14aac4123a88c22 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C5=81ukasz=20Zdanikowski?=
Date: Mon, 19 Apr 2021 08:39:22 +0200
Subject: [PATCH 22/77] Set up locale env variables (#14)
Setting those variables fixes the issue that sonar has with non-asci chars in filenames
Co-authored-by: Tom
---
Dockerfile | 3 +++
1 file changed, 3 insertions(+)
diff --git a/Dockerfile b/Dockerfile
index 7b47568..c9e3286 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -14,6 +14,9 @@ ARG NODEJS_HOME=/opt/nodejs
ENV PATH=${PATH}:${SONAR_SCANNER_HOME}/bin:${NODEJS_HOME}/bin
+# set up local envs in order to allow for special chars (non-asci) in filenames
+ENV LC_ALL="C.UTF-8"
+
WORKDIR /opt
# https://help.github.com/en/actions/creating-actions/dockerfile-support-for-github-actions#user
From 110d46544bb9fb17733590f909fa33f6a7ba9a55 Mon Sep 17 00:00:00 2001
From: Janos Gyerik
Date: Fri, 11 Jun 2021 11:33:32 +0200
Subject: [PATCH 23/77] Add tip for running the scanner on windows platform
(#23)
Co-authored-by: Tom
---
README.md | 1 +
1 file changed, 1 insertion(+)
diff --git a/README.md b/README.md
index b197534..47dcfc2 100644
--- a/README.md
+++ b/README.md
@@ -94,6 +94,7 @@ https://sonarcloud.io/documentation/analysis/analysis-parameters/
* Your code is built with Gradle: use the SonarQube plugin for Gradle during the build
* You want to analyze a .NET solution: use the [SonarCloud Azure DevOps Extension](https://marketplace.visualstudio.com/items?itemName=SonarSource.sonarcloud) to analyze your code on SonarCloud with Azure Pipelines
* You want to analyze C/C++ code: rely on our [Travis-CI extension](https://docs.travis-ci.com/user/sonarcloud/) and look at [our sample C/C++ project](https://github.com/SonarSource/sq-com_example_c-sqscanner-travis)
+* You want to analyze C/C++/Objective-C code on `windows-latest`: see [this guide](https://community.sonarsource.com/t/sonarcloud-with-msbuild-build-wrapper-on-github-actions/35607) contributed on our community forum
## Have question or feedback?
From 5392662532e48780d7e796d79e55351fcb7ee3c9 Mon Sep 17 00:00:00 2001
From: Peeter Piegaze
<61758048+peeter-piegaze-sonarsource@users.noreply.github.com>
Date: Thu, 16 Sep 2021 11:05:33 +0200
Subject: [PATCH 24/77] Remove warning about not using for .NET (#26)
* Remove warning about not using for .NET
* Update instruction for analyzing a .NET solution
Co-authored-by: Tom Howlett (Sonarsource)
---
README.md | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/README.md b/README.md
index 47dcfc2..e4f744f 100644
--- a/README.md
+++ b/README.md
@@ -20,7 +20,7 @@ sonar.organization=
sonar.projectKey=
# relative paths to source directories. More details and properties are described
-# in https://sonarcloud.io/documentation/project-administration/narrowing-the-focus/
+# in https://sonarcloud.io/documentation/project-administration/narrowing-the-focus/
sonar.sources=.
```
@@ -29,7 +29,7 @@ The workflow, usually declared in `.github/workflows/build.yml`, looks like:
```yaml
on:
# Trigger analysis when pushing in master or pull requests, and when creating
- # a pull request.
+ # a pull request.
push:
branches:
- master
@@ -92,7 +92,7 @@ https://sonarcloud.io/documentation/analysis/analysis-parameters/
* Your code is built with Maven: run 'org.sonarsource.scanner.maven:sonar' during the build
* Your code is built with Gradle: use the SonarQube plugin for Gradle during the build
-* You want to analyze a .NET solution: use the [SonarCloud Azure DevOps Extension](https://marketplace.visualstudio.com/items?itemName=SonarSource.sonarcloud) to analyze your code on SonarCloud with Azure Pipelines
+* You want to analyze a .NET solution: Follow our interactive tutorial for Github Actions after importing your project directly in SonarCloud
* You want to analyze C/C++ code: rely on our [Travis-CI extension](https://docs.travis-ci.com/user/sonarcloud/) and look at [our sample C/C++ project](https://github.com/SonarSource/sq-com_example_c-sqscanner-travis)
* You want to analyze C/C++/Objective-C code on `windows-latest`: see [this guide](https://community.sonarsource.com/t/sonarcloud-with-msbuild-build-wrapper-on-github-actions/35607) contributed on our community forum
From edb8ada98c3e9a655134ae70d5d7c96f4ed894a2 Mon Sep 17 00:00:00 2001
From: colin-mueller-sonarsource
Date: Thu, 9 Dec 2021 10:53:33 +0100
Subject: [PATCH 25/77] Add link to sample repo with more examples (#30)
Co-authored-by: Janos Gyerik
---
README.md | 3 +++
1 file changed, 3 insertions(+)
diff --git a/README.md b/README.md
index e4f744f..7275d2d 100644
--- a/README.md
+++ b/README.md
@@ -79,6 +79,9 @@ In case you need to add additional analysis parameters, you can use the `args` o
More information about possible analysis parameters is found in the documentation at:
https://sonarcloud.io/documentation/analysis/analysis-parameters/
+See also example configurations at:
+https://github.com/sonarsource/sonarcloud-github-action-samples/
+
### Secrets
- `SONAR_TOKEN` – **Required** this is the token used to authenticate access to SonarCloud. You can generate a token on your [Security page in SonarCloud](https://sonarcloud.io/account/security/). You can set the `SONAR_TOKEN` environment variable in the "Secrets" settings page of your repository.
From 4338a6969defadc39bf5e585b5e642dfc7c24de1 Mon Sep 17 00:00:00 2001
From: Javier <32640454+JavierMonton@users.noreply.github.com>
Date: Wed, 12 Jan 2022 15:57:22 +0100
Subject: [PATCH 26/77] Fix broken link in README.md (#32)
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 7275d2d..bc1a2df 100644
--- a/README.md
+++ b/README.md
@@ -77,7 +77,7 @@ In case you need to add additional analysis parameters, you can use the `args` o
```
More information about possible analysis parameters is found in the documentation at:
-https://sonarcloud.io/documentation/analysis/analysis-parameters/
+https://docs.sonarcloud.io/advanced-setup/analysis-parameters
See also example configurations at:
https://github.com/sonarsource/sonarcloud-github-action-samples/
From 25b0be1ad1c39388799624b0d0914282bc36ac8e Mon Sep 17 00:00:00 2001
From: Julien Carsique
Date: Thu, 17 Mar 2022 13:17:14 +0100
Subject: [PATCH 27/77] BUILD-1287 The repository is owned by the SonarCloud
team (#33)
Co-authored-by: re-team-bot
---
.github/CODEOWNERS | 1 +
1 file changed, 1 insertion(+)
create mode 100644 .github/CODEOWNERS
diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS
new file mode 100644
index 0000000..b36ce56
--- /dev/null
+++ b/.github/CODEOWNERS
@@ -0,0 +1 @@
+.github/CODEOWNERS @sonarsource/sonarcloud
From 64d3b081fed0b3f4d5314ebbcaf044283a913910 Mon Sep 17 00:00:00 2001
From: Jair Henrique
Date: Mon, 15 Aug 2022 05:33:07 -0300
Subject: [PATCH 28/77] Update sonar-scanner-cli to v4.7 (#34)
---
Dockerfile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Dockerfile b/Dockerfile
index c9e3286..7234c30 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,4 +1,4 @@
-FROM sonarsource/sonar-scanner-cli:4.6
+FROM sonarsource/sonar-scanner-cli:4.7
LABEL version="0.0.1" \
repository="https://github.com/sonarsource/sonarcloud-github-action" \
From 156db6fef3e168e4972abb76de0b32bbce8ec77a Mon Sep 17 00:00:00 2001
From: Oleg Shur
Date: Mon, 15 Aug 2022 12:20:28 +0300
Subject: [PATCH 29/77] Perform Maven/Gradle check in the projectBaseDir (#19)
Co-authored-by: Tom
---
entrypoint.sh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/entrypoint.sh b/entrypoint.sh
index 3f4db4e..d6922f4 100755
--- a/entrypoint.sh
+++ b/entrypoint.sh
@@ -7,12 +7,12 @@ if [[ -z "${SONAR_TOKEN}" ]]; then
exit 1
fi
-if [[ -f "pom.xml" ]]; then
+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
fi
-if [[ -f "build.gradle" ]]; then
+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
fi
From bc5ac1002a3db8dc8eb109870ec9145b9e6350a8 Mon Sep 17 00:00:00 2001
From: Nawar Hamo <100778766+nawar-hamo-sonarsource@users.noreply.github.com>
Date: Mon, 21 Nov 2022 14:37:11 +0100
Subject: [PATCH 30/77] update README to mention GH action for C and C++ (#37)
---
README.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index bc1a2df..80bfbe0 100644
--- a/README.md
+++ b/README.md
@@ -1,6 +1,7 @@
# Scan your code with SonarCloud
Using this GitHub Action, scan your code with [SonarCloud](https://sonarcloud.io/) to detects bugs, vulnerabilities and code smells in more than 20 programming languages!
+In case you want to analyze C and C++ code: rely on our [SonarCloud Scan for C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and look at [our sample C and C++ project](https://github.com/sonarsource-cfamily-examples)
@@ -96,8 +97,7 @@ https://github.com/sonarsource/sonarcloud-github-action-samples/
* Your code is built with Maven: run 'org.sonarsource.scanner.maven:sonar' during the build
* Your code is built with Gradle: use the SonarQube plugin for Gradle during the build
* You want to analyze a .NET solution: Follow our interactive tutorial for Github Actions after importing your project directly in SonarCloud
-* You want to analyze C/C++ code: rely on our [Travis-CI extension](https://docs.travis-ci.com/user/sonarcloud/) and look at [our sample C/C++ project](https://github.com/SonarSource/sq-com_example_c-sqscanner-travis)
-* You want to analyze C/C++/Objective-C code on `windows-latest`: see [this guide](https://community.sonarsource.com/t/sonarcloud-with-msbuild-build-wrapper-on-github-actions/35607) contributed on our community forum
+* You want to analyze C and C++ code: rely on our [SonarCloud Scan for C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and look at [our sample C and C++ project](https://github.com/sonarsource-cfamily-examples)
## Have question or feedback?
From cb201f3b2d7a38231a8c042dfea4539c8bea180b Mon Sep 17 00:00:00 2001
From: Nawar Hamo <100778766+nawar-hamo-sonarsource@users.noreply.github.com>
Date: Mon, 21 Nov 2022 15:36:58 +0100
Subject: [PATCH 31/77] update README to mention GH action for C and C++ (#38)
---
README.md | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/README.md b/README.md
index 80bfbe0..ced2d31 100644
--- a/README.md
+++ b/README.md
@@ -1,11 +1,11 @@
# Scan your code with SonarCloud
Using this GitHub Action, scan your code with [SonarCloud](https://sonarcloud.io/) to detects bugs, vulnerabilities and code smells in more than 20 programming languages!
-In case you want to analyze C and C++ code: rely on our [SonarCloud Scan for C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and look at [our sample C and C++ project](https://github.com/sonarsource-cfamily-examples)
+In case you want to analyze C and C++ code: rely on our [SonarCloud Scan for C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and look at [our sample C and C++ project](https://github.com/sonarsource-cfamily-examples?q=gh-actions-sc&type=all&language=&sort=)
-SonarCloud is the leading product for Continuous Code Quality & Code Security online, totally free for open-source projects. It supports all major programming languages, including Java, JavaScript, TypeScript, C#, C/C++ and many more. If your code is closed source, SonarCloud also offers a paid plan to run private analyses.
+SonarCloud is the leading product for Continuous Code Quality & Code Security online, totally free for open-source projects. It supports all major programming languages, including Java, JavaScript, TypeScript, C#, [C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and many more. If your code is closed source, SonarCloud also offers a paid plan to run private analyses.
## Requirements
@@ -97,7 +97,7 @@ https://github.com/sonarsource/sonarcloud-github-action-samples/
* Your code is built with Maven: run 'org.sonarsource.scanner.maven:sonar' during the build
* Your code is built with Gradle: use the SonarQube plugin for Gradle during the build
* You want to analyze a .NET solution: Follow our interactive tutorial for Github Actions after importing your project directly in SonarCloud
-* You want to analyze C and C++ code: rely on our [SonarCloud Scan for C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and look at [our sample C and C++ project](https://github.com/sonarsource-cfamily-examples)
+* You want to analyze C and C++ code: rely on our [SonarCloud Scan for C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and look at [our sample C and C++ project](https://github.com/sonarsource-cfamily-examples?q=gh-actions-sc&type=all&language=&sort=)
## Have question or feedback?
From db501078e936e4b4c8773d1bb949ba9ddb7b6b6a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Antonio=20Garc=C3=ADa=20Jim=C3=A9nez?=
Date: Fri, 3 Mar 2023 08:53:16 +0100
Subject: [PATCH 32/77] SC-4361 Update sonar-scanner-cli to v4.8 (#47)
---
Dockerfile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Dockerfile b/Dockerfile
index 7234c30..0f08c40 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,4 +1,4 @@
-FROM sonarsource/sonar-scanner-cli:4.7
+FROM sonarsource/sonar-scanner-cli:4.8
LABEL version="0.0.1" \
repository="https://github.com/sonarsource/sonarcloud-github-action" \
From 5875562561d22a34be0c657405578705a169af6c Mon Sep 17 00:00:00 2001
From: bogdanakushnir <114225401+bogdanakushnir@users.noreply.github.com>
Date: Thu, 20 Apr 2023 12:31:51 +0300
Subject: [PATCH 33/77] SC-6662 update README to use v3 of actions
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index ced2d31..2a1c428 100644
--- a/README.md
+++ b/README.md
@@ -41,7 +41,7 @@ jobs:
sonarcloud:
runs-on: ubuntu-latest
steps:
- - uses: actions/checkout@v2
+ - uses: actions/checkout@v3
with:
# Disabling shallow clone is recommended for improving relevancy of reporting
fetch-depth: 0
From 9c0534dd12d09f22d69fbb301a1955249e49d910 Mon Sep 17 00:00:00 2001
From: Tom
Date: Wed, 10 May 2023 17:19:52 +0200
Subject: [PATCH 34/77] Delete .travis.yml
---
.travis.yml | 11 -----------
1 file changed, 11 deletions(-)
delete mode 100644 .travis.yml
diff --git a/.travis.yml b/.travis.yml
deleted file mode 100644
index 8f10cd3..0000000
--- a/.travis.yml
+++ /dev/null
@@ -1,11 +0,0 @@
-# any language
-language: python
-
-services:
- - docker
-
-script:
- - docker -v
- - docker build --no-cache -t sonarsource/sonarcloud-github-action .
- - docker image ls sonarsource/sonarcloud-github-action
- - docker history sonarsource/sonarcloud-github-action
From 4b4d7634dab97dcee0b75763a54a6dc92a9e6bc1 Mon Sep 17 00:00:00 2001
From: Nawar Hamo <100778766+nawar-hamo-sonarsource@users.noreply.github.com>
Date: Thu, 3 Aug 2023 15:37:56 +0200
Subject: [PATCH 35/77] Update scanner cli version to 5.0 (#51)
---
Dockerfile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Dockerfile b/Dockerfile
index 0f08c40..ac2bf45 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,4 +1,4 @@
-FROM sonarsource/sonar-scanner-cli:4.8
+FROM sonarsource/sonar-scanner-cli:5.0
LABEL version="0.0.1" \
repository="https://github.com/sonarsource/sonarcloud-github-action" \
From a244ec8e13e936b0bf97ee18f0ab980ffc2f2310 Mon Sep 17 00:00:00 2001
From: Nawar Hamo <100778766+nawar-hamo-sonarsource@users.noreply.github.com>
Date: Tue, 5 Sep 2023 15:32:55 +0200
Subject: [PATCH 36/77] SC-9154 Update SonarCloud GitHub Action docs (#54)
---
README.md | 12 ++++++------
action.yml | 2 +-
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/README.md b/README.md
index 2a1c428..ec91d31 100644
--- a/README.md
+++ b/README.md
@@ -1,15 +1,15 @@
-# Scan your code with SonarCloud
+# Analyze your code for free with SonarCloud
-Using this GitHub Action, scan your code with [SonarCloud](https://sonarcloud.io/) to detects bugs, vulnerabilities and code smells in more than 20 programming languages!
+Using this GitHub Action, scan your code with [SonarCloud](https://sonarcloud.io/) to detects bugs, vulnerabilities and code smells in 26+ programming languages!
In case you want to analyze C and C++ code: rely on our [SonarCloud Scan for C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and look at [our sample C and C++ project](https://github.com/sonarsource-cfamily-examples?q=gh-actions-sc&type=all&language=&sort=)
-SonarCloud is the leading product for Continuous Code Quality & Code Security online, totally free for open-source projects. It supports all major programming languages, including Java, JavaScript, TypeScript, C#, [C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and many more. If your code is closed source, SonarCloud also offers a paid plan to run private analyses.
+SonarCloud is the leading product for Continuous Code Quality & Code Security online, totally free for open-source projects. It supports all major programming languages, including Java, JavaScript, TypeScript, C#, [C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and many more. If your code is closed source, SonarCloud also offers a free, no-commitment 14-day trial to run private analyses. Start your free trial here: [SonarCloud Sign up](https://www.sonarsource.com/products/sonarcloud/signup/). With SonarCloud, you also get IDE Support with [SonarLint](https://www.sonarsource.com/products/sonarlint/) integration to find code issues on the fly. SonarCloud rules and analysis settings synchronize to [SonarLint](https://www.sonarsource.com/products/sonarlint/), aligning teams around a single standard of Clean Code.
## Requirements
-* Have an account on SonarCloud. [Sign up for free now](https://sonarcloud.io/sessions/init/github) if it's not already the case!
+* Create your account on SonarCloud. Sign up for free now if it's not already the case! [SonarCloud Sign up](https://www.sonarsource.com/products/sonarcloud/signup/)
* The repository to analyze is set up on SonarCloud. [Set it up](https://sonarcloud.io/projects/create) in just one click.
## Usage
@@ -92,6 +92,8 @@ https://github.com/sonarsource/sonarcloud-github-action-samples/
+Want to see more examples of SonarCloud in action? You can [explore current Open Source projects in SonarCloud](https://sonarcloud.io/explore/projects?sort=-analysis_date) that are using the Clean as You Code methodology.
+
## Do not use this GitHub action if you are in the following situations
* Your code is built with Maven: run 'org.sonarsource.scanner.maven:sonar' during the build
@@ -108,5 +110,3 @@ To provide feedback (requesting a feature or reporting a bug) please post on the
The Dockerfile and associated scripts and documentation in this project are released under the LGPLv3 License.
Container images built with this project include third party materials.
-
-[](https://travis-ci.com/SonarSource/sonarcloud-github-action)
diff --git a/action.yml b/action.yml
index 7c1c588..2564e59 100644
--- a/action.yml
+++ b/action.yml
@@ -1,7 +1,7 @@
name: SonarCloud Scan
description: >
Scan your code with SonarCloud to detect bugs, vulnerabilities and code smells
- in more than 25 programming languages.
+ in 26+ programming languages.
branding:
icon: check
color: green
From c25d2e7e3def96d0d1781000d3c429da22cd6252 Mon Sep 17 00:00:00 2001
From: bogdanakushnir <114225401+bogdanakushnir@users.noreply.github.com>
Date: Fri, 8 Sep 2023 15:23:53 +0200
Subject: [PATCH 37/77] SC-9154 Update links in README
---
README.md | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/README.md b/README.md
index ec91d31..d323f72 100644
--- a/README.md
+++ b/README.md
@@ -1,15 +1,15 @@
# Analyze your code for free with SonarCloud
-Using this GitHub Action, scan your code with [SonarCloud](https://sonarcloud.io/) to detects bugs, vulnerabilities and code smells in 26+ programming languages!
+Using this GitHub Action, scan your code with [SonarCloud](https://www.sonarsource.com/products/sonarcloud/?utm_medium=referral&utm_source=github&utm_campaign=sc-product&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x) to detects bugs, vulnerabilities and code smells in 26+ programming languages!
In case you want to analyze C and C++ code: rely on our [SonarCloud Scan for C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and look at [our sample C and C++ project](https://github.com/sonarsource-cfamily-examples?q=gh-actions-sc&type=all&language=&sort=)
-SonarCloud is the leading product for Continuous Code Quality & Code Security online, totally free for open-source projects. It supports all major programming languages, including Java, JavaScript, TypeScript, C#, [C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and many more. If your code is closed source, SonarCloud also offers a free, no-commitment 14-day trial to run private analyses. Start your free trial here: [SonarCloud Sign up](https://www.sonarsource.com/products/sonarcloud/signup/). With SonarCloud, you also get IDE Support with [SonarLint](https://www.sonarsource.com/products/sonarlint/) integration to find code issues on the fly. SonarCloud rules and analysis settings synchronize to [SonarLint](https://www.sonarsource.com/products/sonarlint/), aligning teams around a single standard of Clean Code.
+SonarCloud is the leading product for Continuous Code Quality & Code Security online, totally free for open-source projects. It supports all major programming languages, including Java, JavaScript, TypeScript, C#, [C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and many more. If your code is closed source, SonarCloud also offers a free, no-commitment 14-day trial to run private analyses. Start your free trial here: [SonarCloud Sign up](https://www.sonarsource.com/products/sonarcloud/signup/?utm_medium=referral&utm_source=github&utm_campaign=sc-signup&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x). With SonarCloud, you also get IDE Support with [SonarLint](https://www.sonarsource.com/products/sonarlint/?utm_medium=referral&utm_source=github&utm_campaign=sc-signup&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x) integration to find code issues on the fly. SonarCloud rules and analysis settings synchronize to [SonarLint](https://www.sonarsource.com/products/sonarlint/?utm_medium=referral&utm_source=github&utm_campaign=sc-signup&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x), aligning teams around a single standard of Clean Code.
## Requirements
-* Create your account on SonarCloud. Sign up for free now if it's not already the case! [SonarCloud Sign up](https://www.sonarsource.com/products/sonarcloud/signup/)
+* Create your account on SonarCloud. Sign up for free now if it's not already the case! [SonarCloud Sign up](https://www.sonarsource.com/products/sonarcloud/signup/?utm_medium=referral&utm_source=github&utm_campaign=sc-signup&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x)
* The repository to analyze is set up on SonarCloud. [Set it up](https://sonarcloud.io/projects/create) in just one click.
## Usage
@@ -92,7 +92,7 @@ https://github.com/sonarsource/sonarcloud-github-action-samples/
-Want to see more examples of SonarCloud in action? You can [explore current Open Source projects in SonarCloud](https://sonarcloud.io/explore/projects?sort=-analysis_date) that are using the Clean as You Code methodology.
+Want to see more examples of SonarCloud in action? You can [explore current Open Source projects in SonarCloud](https://sonarcloud.io/explore/projects?sort=-analysis_date?utm_medium=referral&utm_source=github&utm_campaign=sc-signup&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x) that are using the Clean as You Code methodology.
## Do not use this GitHub action if you are in the following situations
From 5ee47de3c96f0c1c51b09d2ff1fec0cfeefcf67c Mon Sep 17 00:00:00 2001
From: David Cho-Lerat
<117642976+david-cho-lerat-sonarsource@users.noreply.github.com>
Date: Tue, 19 Sep 2023 10:37:06 +0200
Subject: [PATCH 38/77] Update README with new Clean Code wording and link from
Marketing (#56)
---
README.md | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/README.md b/README.md
index d323f72..6f529f8 100644
--- a/README.md
+++ b/README.md
@@ -5,7 +5,7 @@ In case you want to analyze C and C++ code: rely on our [SonarCloud Scan for C a
-SonarCloud is the leading product for Continuous Code Quality & Code Security online, totally free for open-source projects. It supports all major programming languages, including Java, JavaScript, TypeScript, C#, [C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and many more. If your code is closed source, SonarCloud also offers a free, no-commitment 14-day trial to run private analyses. Start your free trial here: [SonarCloud Sign up](https://www.sonarsource.com/products/sonarcloud/signup/?utm_medium=referral&utm_source=github&utm_campaign=sc-signup&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x). With SonarCloud, you also get IDE Support with [SonarLint](https://www.sonarsource.com/products/sonarlint/?utm_medium=referral&utm_source=github&utm_campaign=sc-signup&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x) integration to find code issues on the fly. SonarCloud rules and analysis settings synchronize to [SonarLint](https://www.sonarsource.com/products/sonarlint/?utm_medium=referral&utm_source=github&utm_campaign=sc-signup&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x), aligning teams around a single standard of Clean Code.
+SonarCloud is the leading product for Continuous Code Quality & Code Security online, totally free for open-source projects. It supports all major programming languages, including Java, JavaScript, TypeScript, C#, [C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c), and many more. If your code is closed source, SonarCloud also offers a free, no-commitment 14-day trial to run private analyses. Start your free trial here: [SonarCloud Sign up](https://www.sonarsource.com/products/sonarcloud/signup/?utm_medium=referral&utm_source=github&utm_campaign=sc-signup&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x). With SonarCloud, you also get IDE Support with [SonarLint](https://www.sonarsource.com/products/sonarlint/?utm_medium=referral&utm_source=github&utm_campaign=sc-signup&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x) integration to find code issues on the fly. SonarCloud rules and analysis settings synchronize to [SonarLint](https://www.sonarsource.com/products/sonarlint/?utm_medium=referral&utm_source=github&utm_campaign=sc-signup&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x), aligning teams around a single standard of [Clean Code](https://www.sonarsource.com/solutions/clean-code/).
## Requirements
@@ -14,7 +14,7 @@ SonarCloud is the leading product for Continuous Code Quality & Code Security on
## Usage
-Project metadata, including the location to the sources to be analyzed, must be declared in the file `sonar-project.properties` in the base directory:
+Project metadata, including the location of the sources to be analyzed, must be declared in the file `sonar-project.properties` in the base directory:
```properties
sonar.organization=
@@ -98,10 +98,10 @@ Want to see more examples of SonarCloud in action? You can [explore current Open
* Your code is built with Maven: run 'org.sonarsource.scanner.maven:sonar' during the build
* Your code is built with Gradle: use the SonarQube plugin for Gradle during the build
-* You want to analyze a .NET solution: Follow our interactive tutorial for Github Actions after importing your project directly in SonarCloud
+* You want to analyze a .NET solution: Follow our interactive tutorial for GitHub Actions after importing your project directly into SonarCloud
* You want to analyze C and C++ code: rely on our [SonarCloud Scan for C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and look at [our sample C and C++ project](https://github.com/sonarsource-cfamily-examples?q=gh-actions-sc&type=all&language=&sort=)
-## Have question or feedback?
+## Have questions or feedback?
To provide feedback (requesting a feature or reporting a bug) please post on the [SonarSource Community Forum](https://community.sonarsource.com/) with the tag `sonarcloud`.
@@ -109,4 +109,4 @@ To provide feedback (requesting a feature or reporting a bug) please post on the
The Dockerfile and associated scripts and documentation in this project are released under the LGPLv3 License.
-Container images built with this project include third party materials.
+Container images built with this project include third-party materials.
From e2a1ee7c31ee491f1e09c74535b1c0d3e9f5cd82 Mon Sep 17 00:00:00 2001
From: Cody Simms <141657208+cody-simms-sonarsource@users.noreply.github.com>
Date: Fri, 8 Dec 2023 14:57:12 -0600
Subject: [PATCH 39/77] Fix permissions of .scannerwork directory (#57)
---
Dockerfile | 6 +++---
action.yml | 2 ++
cleanup.sh | 9 +++++++++
3 files changed, 14 insertions(+), 3 deletions(-)
create mode 100644 cleanup.sh
diff --git a/Dockerfile b/Dockerfile
index ac2bf45..7f0d45f 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -19,10 +19,10 @@ ENV LC_ALL="C.UTF-8"
WORKDIR /opt
-# https://help.github.com/en/actions/creating-actions/dockerfile-support-for-github-actions#user
-USER root
-
# Prepare entrypoint
COPY entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
+COPY cleanup.sh /cleanup.sh
+RUN chmod +x /cleanup.sh
ENTRYPOINT ["/entrypoint.sh"]
+
diff --git a/action.yml b/action.yml
index 2564e59..de11390 100644
--- a/action.yml
+++ b/action.yml
@@ -8,6 +8,8 @@ branding:
runs:
using: docker
image: Dockerfile
+ entrypoint: "/entrypoint.sh"
+ post-entrypoint: "/cleanup.sh"
inputs:
args:
description: Additional arguments to the sonarcloud scanner
diff --git a/cleanup.sh b/cleanup.sh
new file mode 100644
index 0000000..2c20c8b
--- /dev/null
+++ b/cleanup.sh
@@ -0,0 +1,9 @@
+#!/bin/bash
+
+set -e
+
+_tmp_file=$(ls "${INPUT_PROJECTBASEDIR}/" | head -1)
+PERM=$(stat -c "%u:%g" "${INPUT_PROJECTBASEDIR}/$_tmp_file")
+
+chown -R $PERM "${INPUT_PROJECTBASEDIR}/"
+
From fb9ead3f769d0e39eae9f1cc305b1a51b545a67f Mon Sep 17 00:00:00 2001
From: Cody Simms
Date: Tue, 12 Dec 2023 09:58:29 -0600
Subject: [PATCH 40/77] chown only .scannerwork
---
cleanup.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/cleanup.sh b/cleanup.sh
index 2c20c8b..79e6545 100644
--- a/cleanup.sh
+++ b/cleanup.sh
@@ -5,5 +5,5 @@ set -e
_tmp_file=$(ls "${INPUT_PROJECTBASEDIR}/" | head -1)
PERM=$(stat -c "%u:%g" "${INPUT_PROJECTBASEDIR}/$_tmp_file")
-chown -R $PERM "${INPUT_PROJECTBASEDIR}/"
+chown -R $PERM "${INPUT_PROJECTBASEDIR}/.scannerwork/"
From 5f0b5356929ddab0e0366a1c604f3f55dd0f2fe3 Mon Sep 17 00:00:00 2001
From: Cody Simms
Date: Tue, 12 Dec 2023 13:36:18 -0600
Subject: [PATCH 41/77] Check for existance of .scannerwork in cleanup script
---
cleanup.sh | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/cleanup.sh b/cleanup.sh
index 79e6545..72d5f41 100644
--- a/cleanup.sh
+++ b/cleanup.sh
@@ -2,6 +2,11 @@
set -e
+if [ ! -d "${INPUT_PROJECTBASEDIR}/.scannerwork" ]; then
+ echo ".scannerwork directory not found; nothing to clean up."
+ exit
+fi
+
_tmp_file=$(ls "${INPUT_PROJECTBASEDIR}/" | head -1)
PERM=$(stat -c "%u:%g" "${INPUT_PROJECTBASEDIR}/$_tmp_file")
From 49e6cd3b187936a73b8280d59ffd9da69df63ec9 Mon Sep 17 00:00:00 2001
From: Duarte Meneses
Date: Tue, 12 Dec 2023 14:31:39 -0600
Subject: [PATCH 42/77] Update README.md about manually cleaning the work
directory
---
README.md | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/README.md b/README.md
index 6f529f8..42f29e5 100644
--- a/README.md
+++ b/README.md
@@ -88,6 +88,19 @@ https://github.com/sonarsource/sonarcloud-github-action-samples/
- `SONAR_TOKEN` – **Required** this is the token used to authenticate access to SonarCloud. You can generate a token on your [Security page in SonarCloud](https://sonarcloud.io/account/security/). You can set the `SONAR_TOKEN` environment variable in the "Secrets" settings page of your repository.
- *`GITHUB_TOKEN` – Provided by Github (see [Authenticating with the GITHUB_TOKEN](https://help.github.com/en/actions/automating-your-workflow-with-github-actions/authenticating-with-the-github_token)).*
+## Error cleaning up workspace
+
+In some cases, the checkout action may fail to clean up the workspace. This is a known problem for GitHub actions implemented as a docker container (such as `sonarcloud-github-actions`) when self-hosted runners are used.
+Example of the error message: `File was unable to be removed Error: EACCES: permission denied, unlink '/actions-runner/_work//project/.scannerwork/.sonar_lock'`
+To work around the problem, `sonarcloud-github-action` attempts to fix the permission of the temporary files that it creates. If that doesn't work, you can manually clean up the workspace by running the following action:
+```
+- name: Clean the workspace
+ uses: docker://alpine
+ with:
+ args: /bin/sh -c "find \"${GITHUB_WORKSPACE}\" -mindepth 1 ! -name . -prune -exec rm -rf {} +"
+```
+You can find more info [here](https://github.com/actions/runner/issues/434).
+
## Example of pull request analysis
From 44eed6088a971ec48af9300c3701483b8815f622 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Francisco=20Robles=20Mart=C3=ADn?=
Date: Mon, 15 Jan 2024 12:28:41 +0100
Subject: [PATCH 43/77] docs: update checkout GitHub Action to the latest
version
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 42f29e5..b1aaea3 100644
--- a/README.md
+++ b/README.md
@@ -41,7 +41,7 @@ jobs:
sonarcloud:
runs-on: ubuntu-latest
steps:
- - uses: actions/checkout@v3
+ - uses: actions/checkout@v4
with:
# Disabling shallow clone is recommended for improving relevancy of reporting
fetch-depth: 0
From 76ec6e7459bd65c7a7ade7d4c7b68d6f0df353c8 Mon Sep 17 00:00:00 2001
From: Claire Villard
<60586848+claire-villard-sonarsource@users.noreply.github.com>
Date: Tue, 19 Mar 2024 09:13:40 -0600
Subject: [PATCH 44/77] SC-12363 Improve the SonarCloud intro in README.md
---
README.md | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/README.md b/README.md
index b1aaea3..52aa45d 100644
--- a/README.md
+++ b/README.md
@@ -1,11 +1,13 @@
# Analyze your code for free with SonarCloud
-Using this GitHub Action, scan your code with [SonarCloud](https://www.sonarsource.com/products/sonarcloud/?utm_medium=referral&utm_source=github&utm_campaign=sc-product&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x) to detects bugs, vulnerabilities and code smells in 26+ programming languages!
-In case you want to analyze C and C++ code: rely on our [SonarCloud Scan for C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and look at [our sample C and C++ project](https://github.com/sonarsource-cfamily-examples?q=gh-actions-sc&type=all&language=&sort=)
+This SonarSource project, available as a GitHub Action, scans your projects with SonarCloud, and helps developers produce
+[Clean Code](https://www.sonarsource.com/solutions/clean-code/?utm_medium=referral&utm_source=github&utm_campaign=clean-code&utm_content=sonarqube-scan-action).
-SonarCloud is the leading product for Continuous Code Quality & Code Security online, totally free for open-source projects. It supports all major programming languages, including Java, JavaScript, TypeScript, C#, [C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c), and many more. If your code is closed source, SonarCloud also offers a free, no-commitment 14-day trial to run private analyses. Start your free trial here: [SonarCloud Sign up](https://www.sonarsource.com/products/sonarcloud/signup/?utm_medium=referral&utm_source=github&utm_campaign=sc-signup&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x). With SonarCloud, you also get IDE Support with [SonarLint](https://www.sonarsource.com/products/sonarlint/?utm_medium=referral&utm_source=github&utm_campaign=sc-signup&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x) integration to find code issues on the fly. SonarCloud rules and analysis settings synchronize to [SonarLint](https://www.sonarsource.com/products/sonarlint/?utm_medium=referral&utm_source=github&utm_campaign=sc-signup&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x), aligning teams around a single standard of [Clean Code](https://www.sonarsource.com/solutions/clean-code/).
+[SonarCloud](https://www.sonarsource.com/products/sonarcloud/) is a widely used static analysis solution for continuous code quality and security inspection.
+It helps developers identify and fix issues in their code that could lead to bugs, vulnerabilities, or decreased development velocity.
+SonarCloud supports the most popular programming languages, including Java, JavaScript, TypeScript, C#, Python, C, C++, and [many more](https://www.sonarsource.com/knowledge/languages/).
## Requirements
From 6bbd64e0cb2194e04addb429d669a9ee873eeeef Mon Sep 17 00:00:00 2001
From: Alex Odoux
<42917730+alexandre-odoux-sonarsource@users.noreply.github.com>
Date: Tue, 2 Apr 2024 08:17:58 +0200
Subject: [PATCH 45/77] makes sonarsource/analysis-experience-squad the code
owner (#66)
---
.github/CODEOWNERS | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS
index b36ce56..3f43f0d 100644
--- a/.github/CODEOWNERS
+++ b/.github/CODEOWNERS
@@ -1 +1 @@
-.github/CODEOWNERS @sonarsource/sonarcloud
+.github/CODEOWNERS @sonarsource/analysis-experience-squad
From 19888635fa64d24e533d388efe8264402dfd721b Mon Sep 17 00:00:00 2001
From: Marharyta
Date: Wed, 8 May 2024 10:35:05 +0200
Subject: [PATCH 46/77] SCSCANGHA-3 Update the condition to detect
"build.gradle.kts" files (#71)
---
entrypoint.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/entrypoint.sh b/entrypoint.sh
index d6922f4..5c26844 100755
--- a/entrypoint.sh
+++ b/entrypoint.sh
@@ -12,7 +12,7 @@ if [[ -f "${INPUT_PROJECTBASEDIR%/}/pom.xml" ]]; then
exit 1
fi
-if [[ -f "${INPUT_PROJECTBASEDIR%/}/build.gradle" ]]; then
+if [[ -f "${INPUT_PROJECTBASEDIR%/}/build.gradle" || -f "${INPUT_PROJECTBASEDIR%/}/build.gradle.kts" ]]; then
echo "Gradle project detected. You should use the SonarQube plugin for Gradle during build rather than using this GitHub Action."
exit 1
fi
From 0861f01544857d159912c78ca5f7b90d172173d5 Mon Sep 17 00:00:00 2001
From: "antoine.vinot"
Date: Mon, 13 May 2024 11:23:03 +0200
Subject: [PATCH 47/77] SCSCANGHA-6 Add Github Actions tests
---
.github/workflows/qa.yml | 128 ++++++++++++++++++++
Dockerfile | 1 -
test/assertFileContains | 10 ++
test/assertFileExists | 8 ++
test/gradle-project-kotlin/build.gradle.kts | 0
test/gradle-project/build.gradle | 1 +
test/maven-project/pom.xml | 1 +
7 files changed, 148 insertions(+), 1 deletion(-)
create mode 100644 .github/workflows/qa.yml
create mode 100755 test/assertFileContains
create mode 100755 test/assertFileExists
create mode 100644 test/gradle-project-kotlin/build.gradle.kts
create mode 100644 test/gradle-project/build.gradle
create mode 100644 test/maven-project/pom.xml
diff --git a/.github/workflows/qa.yml b/.github/workflows/qa.yml
new file mode 100644
index 0000000..ab7870f
--- /dev/null
+++ b/.github/workflows/qa.yml
@@ -0,0 +1,128 @@
+name: QA
+
+on:
+ push:
+ branches:
+ - main
+ pull_request:
+ types: [opened, synchronize, reopened]
+
+jobs:
+ argsInputTest:
+ name: >
+ 'args' input
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v4
+ with:
+ token: ${{ secrets.GITHUB_TOKEN }}
+ - name: Run action with args
+ uses: ./
+ with:
+ args: -Dsonar.someArg=aValue -Dsonar.scanner.dumpToFile=./output.properties
+ env:
+ SONAR_TOKEN: FAKE_TOKEN
+ - name: Assert
+ run: |
+ ./test/assertFileContains ./output.properties "sonar.someArg=aValue"
+ projectBaseDirInputTest:
+ name: >
+ 'projectBaseDir' input
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v4
+ with:
+ token: ${{ secrets.GITHUB_TOKEN }}
+ - run: |
+ mkdir -p ./baseDir
+ - name: Run action with projectBaseDir
+ uses: ./
+ with:
+ args: -Dsonar.scanner.dumpToFile=./output.properties
+ projectBaseDir: ./baseDir
+ env:
+ SONAR_TOKEN: FAKE_TOKEN
+ - name: Assert
+ run: |
+ ./test/assertFileContains ./output.properties "sonar.projectBaseDir=.*/baseDir"
+ sonarTokenRequiredTest:
+ name: >
+ 'SONAR_TOKEN' env var required
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v4
+ with:
+ token: ${{ secrets.GITHUB_TOKEN }}
+ - name: Run action without SONAR_TOKEN
+ uses: ./
+ with:
+ args: -Dsonar.scanner.dumpToFile=./output.properties
+ continue-on-error: true
+ - name: Previous should have failed
+ if: ${{ steps.runTest.outcome == 'success'}}
+ run: |
+ echo "Expected previous step to fail"
+ exit 1
+ failFastGradleTest:
+ name: >
+ Fail fast on Gradle project
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v4
+ with:
+ token: ${{ secrets.GITHUB_TOKEN }}
+ - name: Run action on Gradle project
+ id: runTest
+ uses: ./
+ continue-on-error: true
+ env:
+ SONAR_TOKEN: FAKE_TOKEN
+ with:
+ projectBaseDir: ./test/gradle-project
+ - name: Previous should have failed
+ if: ${{ steps.runTest.outcome == 'success'}}
+ run: |
+ echo "Expected previous step to fail"
+ exit 1
+ failFastGradleKotlinTest:
+ name: >
+ Fail fast on Kotlin Gradle project
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v4
+ with:
+ token: ${{ secrets.GITHUB_TOKEN }}
+ - name: Run action on Kotlin Gradle project
+ id: runTest
+ uses: ./
+ continue-on-error: true
+ env:
+ SONAR_TOKEN: FAKE_TOKEN
+ with:
+ projectBaseDir: ./test/gradle-project-kotlin
+ - name: Previous should have failed
+ if: ${{ steps.runTest.outcome == 'success'}}
+ run: |
+ echo "Expected previous step to fail"
+ exit 1
+ failFastMavenTest:
+ name: >
+ Fail fast on Maven project
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v4
+ with:
+ token: ${{ secrets.GITHUB_TOKEN }}
+ - name: Run action on Maven project
+ id: runTest
+ uses: ./
+ continue-on-error: true
+ env:
+ SONAR_TOKEN: FAKE_TOKEN
+ with:
+ projectBaseDir: ./test/maven-project
+ - name: Previous should have failed
+ if: ${{ steps.runTest.outcome == 'success'}}
+ run: |
+ echo "Expected previous step to fail"
+ exit 1
diff --git a/Dockerfile b/Dockerfile
index 7f0d45f..d7e9d66 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -25,4 +25,3 @@ RUN chmod +x /entrypoint.sh
COPY cleanup.sh /cleanup.sh
RUN chmod +x /cleanup.sh
ENTRYPOINT ["/entrypoint.sh"]
-
diff --git a/test/assertFileContains b/test/assertFileContains
new file mode 100755
index 0000000..69380e1
--- /dev/null
+++ b/test/assertFileContains
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+error() { echo -e "\\e[31m✗ $*\\e[0m"; }
+
+assertFileExists $1
+
+if ! grep -q $2 $1; then
+ error "'$2' not found in '$1'"
+ exit 1
+fi
\ No newline at end of file
diff --git a/test/assertFileExists b/test/assertFileExists
new file mode 100755
index 0000000..8f04686
--- /dev/null
+++ b/test/assertFileExists
@@ -0,0 +1,8 @@
+#!/bin/bash
+
+error() { echo -e "\\e[31m✗ $*\\e[0m"; }
+
+if [ ! -f $1 ]; then
+ error "File '$1' not found"
+ exit 1
+fi
\ No newline at end of file
diff --git a/test/gradle-project-kotlin/build.gradle.kts b/test/gradle-project-kotlin/build.gradle.kts
new file mode 100644
index 0000000..e69de29
diff --git a/test/gradle-project/build.gradle b/test/gradle-project/build.gradle
new file mode 100644
index 0000000..8b13789
--- /dev/null
+++ b/test/gradle-project/build.gradle
@@ -0,0 +1 @@
+
diff --git a/test/maven-project/pom.xml b/test/maven-project/pom.xml
new file mode 100644
index 0000000..8b13789
--- /dev/null
+++ b/test/maven-project/pom.xml
@@ -0,0 +1 @@
+
From 3da91d8a6aff5e898114575b30c6dc1e4787a254 Mon Sep 17 00:00:00 2001
From: "antoine.vinot"
Date: Thu, 16 May 2024 13:08:11 +0200
Subject: [PATCH 48/77] SCSCANGHA-6 Fix main branch name in GitHub workflow
---
.github/workflows/qa.yml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/.github/workflows/qa.yml b/.github/workflows/qa.yml
index ab7870f..7f98e93 100644
--- a/.github/workflows/qa.yml
+++ b/.github/workflows/qa.yml
@@ -3,7 +3,7 @@ name: QA
on:
push:
branches:
- - main
+ - master
pull_request:
types: [opened, synchronize, reopened]
From 49689c44074ddbc5afef45d88e4a0f9bcf94e51a Mon Sep 17 00:00:00 2001
From: "antoine.vinot"
Date: Mon, 20 May 2024 15:13:57 +0200
Subject: [PATCH 49/77] SCSCANGHA-9 Enable Mend scan
---
.cirrus.star | 4 ++++
.cirrus.yml | 35 ++++++++++++++++++++++++++++++++
.cirrus/wss-unified-agent.config | 4 ++++
3 files changed, 43 insertions(+)
create mode 100644 .cirrus.star
create mode 100644 .cirrus.yml
create mode 100644 .cirrus/wss-unified-agent.config
diff --git a/.cirrus.star b/.cirrus.star
new file mode 100644
index 0000000..28b17b7
--- /dev/null
+++ b/.cirrus.star
@@ -0,0 +1,4 @@
+load("github.com/SonarSource/cirrus-modules@v2", "load_features")
+
+def main(ctx):
+ return load_features(ctx)
diff --git a/.cirrus.yml b/.cirrus.yml
new file mode 100644
index 0000000..e2c861c
--- /dev/null
+++ b/.cirrus.yml
@@ -0,0 +1,35 @@
+env:
+ CIRRUS_VAULT_URL: https://vault.sonar.build:8200
+ CIRRUS_VAULT_AUTH_PATH: jwt-cirrusci
+ CIRRUS_VAULT_ROLE: cirrusci-${CIRRUS_REPO_OWNER}-${CIRRUS_REPO_NAME}
+
+ # Staging image configuration
+ STAGING_IMAGE_NAME: sonarsource/sonarcloud-github-action
+ CURRENT_TAG: master
+
+vm_instance_template: &VM_TEMPLATE
+ experimental: true # see https://github.com/cirruslabs/cirrus-ci-docs/issues/1051
+ image: docker-builder-v*
+ type: t2.small
+ region: eu-central-1
+ subnet_id: ${CIRRUS_AWS_SUBNET}
+ disk: 10
+ cpu: 4
+ memory: 16G
+
+mend_task:
+ ec2_instance:
+ <<: *VM_TEMPLATE
+ # run only on master and long-term branches
+ only_if: $CIRRUS_USER_COLLABORATOR == 'true' && $CIRRUS_TAG == "" && ($CIRRUS_BRANCH == "master" || $CIRRUS_BRANCH =~ "branch-.*")
+ env:
+ MEND_API_KEY: VAULT[development/kv/data/mend data.apikey]
+ setup_script:
+ - docker build --tag "${STAGING_IMAGE_NAME}:${CURRENT_TAG}" .
+ - apt-get remove -y unattended-upgrades
+ - apt-get update && apt-get install -y --no-install-recommends openjdk-17-jre
+ - curl -sSL https://unified-agent.s3.amazonaws.com/wss-unified-agent.jar -o wss-unified-agent.jar
+ - echo "docker.includes=${CURRENT_TAG}" >> .cirrus/wss-unified-agent.config
+ scan_script:
+ - echo "Scan the ${STAGING_IMAGE_NAME}:${CURRENT_TAG} image"
+ - java -jar wss-unified-agent.jar -c .cirrus/wss-unified-agent.config -apiKey $MEND_API_KEY
diff --git a/.cirrus/wss-unified-agent.config b/.cirrus/wss-unified-agent.config
new file mode 100644
index 0000000..d23b6de
--- /dev/null
+++ b/.cirrus/wss-unified-agent.config
@@ -0,0 +1,4 @@
+docker.projectNameFormat=repositoryNameAndTag
+docker.scanImages=true
+wss.url=https://saas-eu.whitesourcesoftware.com/agent
+productName=GitHubAction/SonarCloudGitHubAction
From 1373cf75e259ec3132e780bfb8c6e4bce4fbb80d Mon Sep 17 00:00:00 2001
From: Ari Becker
Date: Tue, 21 May 2024 14:50:39 +0300
Subject: [PATCH 50/77] SCSCANGHA-14 Enable debug logging when GitHub Actions
debug logging is enabled (#43)
---
entrypoint.sh | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/entrypoint.sh b/entrypoint.sh
index 5c26844..664602f 100755
--- a/entrypoint.sh
+++ b/entrypoint.sh
@@ -20,5 +20,11 @@ fi
if [[ -z "${SONARCLOUD_URL}" ]]; then
SONARCLOUD_URL="https://sonarcloud.io"
fi
+
+debug_flag=''
+if [[ "$RUNNER_DEBUG" == '1' ]]; then
+ debug_flag=' --debug '
+fi
+
unset JAVA_HOME
-sonar-scanner -Dsonar.projectBaseDir=${INPUT_PROJECTBASEDIR} -Dsonar.host.url=${SONARCLOUD_URL} ${INPUT_ARGS}
+sonar-scanner $debug_flag -Dsonar.projectBaseDir=${INPUT_PROJECTBASEDIR} -Dsonar.host.url=${SONARCLOUD_URL} ${INPUT_ARGS}
From 714bd356bff7a469fc67bb81ede7cdd0a17371ac Mon Sep 17 00:00:00 2001
From: Istvan Bodo <127833893+istvan-bodo-sonarsource@users.noreply.github.com>
Date: Wed, 22 May 2024 09:56:47 +0200
Subject: [PATCH 51/77] SCSCANGHA-15 Add test for scanner debug logging (#77)
---
.github/workflows/qa.yml | 18 ++++++++++++++++++
1 file changed, 18 insertions(+)
diff --git a/.github/workflows/qa.yml b/.github/workflows/qa.yml
index 7f98e93..ba76818 100644
--- a/.github/workflows/qa.yml
+++ b/.github/workflows/qa.yml
@@ -126,3 +126,21 @@ jobs:
run: |
echo "Expected previous step to fail"
exit 1
+ runnerDebugUsedTest:
+ name: >
+ 'RUNNER_DEBUG' is used
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v4
+ with:
+ token: ${{ secrets.GITHUB_TOKEN }}
+ - name: Run action with debug mode
+ uses: ./
+ with:
+ args: -Dsonar.scanner.dumpToFile=./output.properties
+ env:
+ RUNNER_DEBUG: 1
+ SONAR_TOKEN: FAKE_TOKEN
+ - name: Assert
+ run: |
+ ./test/assertFileContains ./output.properties "sonar.verbose=true"
From f1d5a2ae707b7e1fafb1050fa8e2e9cb75db3d1e Mon Sep 17 00:00:00 2001
From: "antoine.vinot"
Date: Mon, 20 May 2024 15:47:23 +0200
Subject: [PATCH 52/77] SCSCANGHA-13 Warning instead of failure for
Maven/Gradle projects
---
.github/workflows/qa.yml | 34 ++++++++++++++++------------------
entrypoint.sh | 8 ++++----
2 files changed, 20 insertions(+), 22 deletions(-)
diff --git a/.github/workflows/qa.yml b/.github/workflows/qa.yml
index ba76818..f3af6f1 100644
--- a/.github/workflows/qa.yml
+++ b/.github/workflows/qa.yml
@@ -63,9 +63,9 @@ jobs:
run: |
echo "Expected previous step to fail"
exit 1
- failFastGradleTest:
+ dontFailGradleTest:
name: >
- Fail fast on Gradle project
+ Don't fail on Gradle project
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
@@ -79,14 +79,13 @@ jobs:
SONAR_TOKEN: FAKE_TOKEN
with:
projectBaseDir: ./test/gradle-project
- - name: Previous should have failed
- if: ${{ steps.runTest.outcome == 'success'}}
+ args: -Dsonar.scanner.dumpToFile=./output.properties
+ - name: Assert
run: |
- echo "Expected previous step to fail"
- exit 1
- failFastGradleKotlinTest:
+ ./test/assertFileExists ./output.properties
+ dontFailGradleKotlinTest:
name: >
- Fail fast on Kotlin Gradle project
+ Don't fail on Kotlin Gradle project
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
@@ -100,14 +99,13 @@ jobs:
SONAR_TOKEN: FAKE_TOKEN
with:
projectBaseDir: ./test/gradle-project-kotlin
- - name: Previous should have failed
- if: ${{ steps.runTest.outcome == 'success'}}
+ args: -Dsonar.scanner.dumpToFile=./output.properties
+ - name: Assert
run: |
- echo "Expected previous step to fail"
- exit 1
- failFastMavenTest:
+ ./test/assertFileExists ./output.properties
+ dontFailMavenTest:
name: >
- Fail fast on Maven project
+ Don't fail on Maven project
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
@@ -121,11 +119,10 @@ jobs:
SONAR_TOKEN: FAKE_TOKEN
with:
projectBaseDir: ./test/maven-project
- - name: Previous should have failed
- if: ${{ steps.runTest.outcome == 'success'}}
+ args: -Dsonar.scanner.dumpToFile=./output.properties
+ - name: Assert
run: |
- echo "Expected previous step to fail"
- exit 1
+ ./test/assertFileExists ./output.properties
runnerDebugUsedTest:
name: >
'RUNNER_DEBUG' is used
@@ -144,3 +141,4 @@ jobs:
- name: Assert
run: |
./test/assertFileContains ./output.properties "sonar.verbose=true"
+
diff --git a/entrypoint.sh b/entrypoint.sh
index 664602f..9cd1c40 100755
--- a/entrypoint.sh
+++ b/entrypoint.sh
@@ -8,13 +8,13 @@ if [[ -z "${SONAR_TOKEN}" ]]; 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" || -f "${INPUT_PROJECTBASEDIR%/}/build.gradle.kts" ]]; 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
if [[ -z "${SONARCLOUD_URL}" ]]; then
From a69a8edf1df352adece45acf0c3b810050657eda Mon Sep 17 00:00:00 2001
From: "antoine.vinot"
Date: Wed, 22 May 2024 11:17:24 +0200
Subject: [PATCH 53/77] SCSCANGHA-5 Update the base image
---
Dockerfile | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/Dockerfile b/Dockerfile
index d7e9d66..3e7aee8 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,6 +1,6 @@
-FROM sonarsource/sonar-scanner-cli:5.0
+FROM sonarsource/sonar-scanner-cli:10.0
-LABEL version="0.0.1" \
+LABEL version="2.2.0" \
repository="https://github.com/sonarsource/sonarcloud-github-action" \
homepage="https://github.com/sonarsource/sonarcloud-github-action" \
maintainer="SonarSource" \
@@ -19,9 +19,14 @@ ENV LC_ALL="C.UTF-8"
WORKDIR /opt
+# GitHub actions should be run under ROOT
+# https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners/about-github-hosted-runners#docker-container-filesystem
+USER 0
+
# Prepare entrypoint
COPY entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
COPY cleanup.sh /cleanup.sh
RUN chmod +x /cleanup.sh
+
ENTRYPOINT ["/entrypoint.sh"]
From d08d592c0b694607865c089cba90bbf87c9a6d89 Mon Sep 17 00:00:00 2001
From: Istvan Bodo <127833893+istvan-bodo-sonarsource@users.noreply.github.com>
Date: Thu, 23 May 2024 10:49:51 +0200
Subject: [PATCH 54/77] SCSCANGHA-16 Support passing args with spaces (#79)
---
.github/workflows/qa.yml | 5 +++--
entrypoint.sh | 4 +++-
2 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/.github/workflows/qa.yml b/.github/workflows/qa.yml
index f3af6f1..dfe76d6 100644
--- a/.github/workflows/qa.yml
+++ b/.github/workflows/qa.yml
@@ -19,12 +19,13 @@ jobs:
- name: Run action with args
uses: ./
with:
- args: -Dsonar.someArg=aValue -Dsonar.scanner.dumpToFile=./output.properties
+ args: >-
+ "-Dsonar.someArg=a value with spaces" -Dsonar.scanner.dumpToFile=./output.properties
env:
SONAR_TOKEN: FAKE_TOKEN
- name: Assert
run: |
- ./test/assertFileContains ./output.properties "sonar.someArg=aValue"
+ ./test/assertFileContains ./output.properties "sonar.someArg=a value with spaces"
projectBaseDirInputTest:
name: >
'projectBaseDir' input
diff --git a/entrypoint.sh b/entrypoint.sh
index 9cd1c40..af68fa6 100755
--- a/entrypoint.sh
+++ b/entrypoint.sh
@@ -27,4 +27,6 @@ if [[ "$RUNNER_DEBUG" == '1' ]]; then
fi
unset JAVA_HOME
-sonar-scanner $debug_flag -Dsonar.projectBaseDir=${INPUT_PROJECTBASEDIR} -Dsonar.host.url=${SONARCLOUD_URL} ${INPUT_ARGS}
+
+eval "args=(${INPUT_ARGS})"
+sonar-scanner $debug_flag "-Dsonar.projectBaseDir=${INPUT_PROJECTBASEDIR}" "-Dsonar.host.url=${SONARCLOUD_URL}" "${args[@]}"
From 9c11606f1328e4a0d52d6df7cbe4b21e62b8dfdc Mon Sep 17 00:00:00 2001
From: "antoine.vinot"
Date: Thu, 23 May 2024 11:56:27 +0200
Subject: [PATCH 55/77] Use a placeholder for the action version in README
---
README.md | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/README.md b/README.md
index 52aa45d..356ade0 100644
--- a/README.md
+++ b/README.md
@@ -48,7 +48,7 @@ jobs:
# Disabling shallow clone is recommended for improving relevancy of reporting
fetch-depth: 0
- name: SonarCloud Scan
- uses: sonarsource/sonarcloud-github-action@master
+ uses: sonarsource/sonarcloud-github-action@ # Ex: v2.1.0, See the latest version at https://github.com/marketplace/actions/sonarcloud-scan
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
@@ -57,7 +57,7 @@ jobs:
You can change the analysis base directory by using the optional input `projectBaseDir` like this:
```yaml
-uses: sonarsource/sonarcloud-github-action@master
+uses: sonarsource/sonarcloud-github-action@ # Ex: v2.1.0, See the latest version at https://github.com/marketplace/actions/sonarcloud-scan
with:
projectBaseDir: my-custom-directory
```
@@ -66,7 +66,7 @@ In case you need to add additional analysis parameters, you can use the `args` o
```yaml
- name: Analyze with SonarCloud
- uses: sonarsource/sonarcloud-github-action@master
+ uses: sonarsource/sonarcloud-github-action@ # Ex: v2.1.0, See the latest version at https://github.com/marketplace/actions/sonarcloud-scan
with:
projectBaseDir: my-custom-directory
args: >
From 4006f663ecaf1f8093e8e4abb9227f6041f52216 Mon Sep 17 00:00:00 2001
From: Bogdana
Date: Thu, 9 Feb 2023 14:44:35 +0100
Subject: [PATCH 56/77] SC-6818 drop GH token from README
---
README.md | 1 -
1 file changed, 1 deletion(-)
diff --git a/README.md b/README.md
index 356ade0..fe15a1e 100644
--- a/README.md
+++ b/README.md
@@ -50,7 +50,6 @@ jobs:
- name: SonarCloud Scan
uses: sonarsource/sonarcloud-github-action@ # Ex: v2.1.0, See the latest version at https://github.com/marketplace/actions/sonarcloud-scan
env:
- GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
```
From 13d84ab51ea6fc29e22a1288ec28cc71fd2eb19e Mon Sep 17 00:00:00 2001
From: "antoine.vinot"
Date: Thu, 23 May 2024 16:50:14 +0200
Subject: [PATCH 57/77] SCSCANGHA-18 Add workflow to automate tags creation
upon release
---
.github/workflows/update-tags.yml | 32 +++++++++++++++++++++++++++++++
1 file changed, 32 insertions(+)
create mode 100644 .github/workflows/update-tags.yml
diff --git a/.github/workflows/update-tags.yml b/.github/workflows/update-tags.yml
new file mode 100644
index 0000000..a07d193
--- /dev/null
+++ b/.github/workflows/update-tags.yml
@@ -0,0 +1,32 @@
+name: Update Tags
+
+on:
+ push:
+ tags:
+ - v*.*.*
+
+jobs:
+ generate:
+ runs-on: ubuntu-latest
+ permissions:
+ contents: write
+
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v4
+
+ - name: Parse semver
+ uses: madhead/semver-utils@40bbdc6e50b258c09f35f574e83c51f60d2ce3a2 # v4.0.0
+ id: version
+ with:
+ version: ${{ github.ref_name }}
+
+ - name: Update tags
+ run: |
+ TAGS='v${{ steps.version.outputs.major }} v${{ steps.version.outputs.major }}.${{ steps.version.outputs.minor }}'
+
+ for t in $TAGS; do
+ git tag -f "$t"
+ git push origin ":$t" 2>/dev/null || true
+ git push origin "$t"
+ done
From e44258b109568baa0df60ed515909fc6c72cba92 Mon Sep 17 00:00:00 2001
From: csaba-feher-sonarsource
<93765926+csaba-feher-sonarsource@users.noreply.github.com>
Date: Thu, 13 Jun 2024 14:34:22 +0200
Subject: [PATCH 58/77] Revert "SCSCANGHA-16 Support passing args with spaces
(#79)" (#83)
This reverts commit d08d592c0b694607865c089cba90bbf87c9a6d89.
---
.github/workflows/qa.yml | 5 ++---
entrypoint.sh | 4 +---
2 files changed, 3 insertions(+), 6 deletions(-)
diff --git a/.github/workflows/qa.yml b/.github/workflows/qa.yml
index dfe76d6..f3af6f1 100644
--- a/.github/workflows/qa.yml
+++ b/.github/workflows/qa.yml
@@ -19,13 +19,12 @@ jobs:
- name: Run action with args
uses: ./
with:
- args: >-
- "-Dsonar.someArg=a value with spaces" -Dsonar.scanner.dumpToFile=./output.properties
+ args: -Dsonar.someArg=aValue -Dsonar.scanner.dumpToFile=./output.properties
env:
SONAR_TOKEN: FAKE_TOKEN
- name: Assert
run: |
- ./test/assertFileContains ./output.properties "sonar.someArg=a value with spaces"
+ ./test/assertFileContains ./output.properties "sonar.someArg=aValue"
projectBaseDirInputTest:
name: >
'projectBaseDir' input
diff --git a/entrypoint.sh b/entrypoint.sh
index af68fa6..9cd1c40 100755
--- a/entrypoint.sh
+++ b/entrypoint.sh
@@ -27,6 +27,4 @@ if [[ "$RUNNER_DEBUG" == '1' ]]; then
fi
unset JAVA_HOME
-
-eval "args=(${INPUT_ARGS})"
-sonar-scanner $debug_flag "-Dsonar.projectBaseDir=${INPUT_PROJECTBASEDIR}" "-Dsonar.host.url=${SONARCLOUD_URL}" "${args[@]}"
+sonar-scanner $debug_flag -Dsonar.projectBaseDir=${INPUT_PROJECTBASEDIR} -Dsonar.host.url=${SONARCLOUD_URL} ${INPUT_ARGS}
From f4a7a62a4338b4becc0a60899ffd56de935dcd42 Mon Sep 17 00:00:00 2001
From: Piotr Idzik <65706193+vil02@users.noreply.github.com>
Date: Fri, 12 Jul 2024 10:29:30 +0200
Subject: [PATCH 59/77] NO-JIRA Prevent globbing and word splitting (#84)
* Prevent globbing and word splitting
* Revert changes in `entrypoint.sh`
---
cleanup.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/cleanup.sh b/cleanup.sh
index 72d5f41..8a5e4c9 100644
--- a/cleanup.sh
+++ b/cleanup.sh
@@ -10,5 +10,5 @@ fi
_tmp_file=$(ls "${INPUT_PROJECTBASEDIR}/" | head -1)
PERM=$(stat -c "%u:%g" "${INPUT_PROJECTBASEDIR}/$_tmp_file")
-chown -R $PERM "${INPUT_PROJECTBASEDIR}/.scannerwork/"
+chown -R "$PERM" "${INPUT_PROJECTBASEDIR}/.scannerwork/"
From b7cc8bf2004f4a9ef190137d8831630e9ae5d2e7 Mon Sep 17 00:00:00 2001
From: "antoine.vinot"
Date: Fri, 12 Jul 2024 10:17:09 +0200
Subject: [PATCH 60/77] NO-JIRA Bump cirrus module version
---
.cirrus.star | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/.cirrus.star b/.cirrus.star
index 28b17b7..9f91e15 100644
--- a/.cirrus.star
+++ b/.cirrus.star
@@ -1,4 +1,4 @@
-load("github.com/SonarSource/cirrus-modules@v2", "load_features")
+load("github.com/SonarSource/cirrus-modules@v3", "load_features")
def main(ctx):
return load_features(ctx)
From 3bf6e4b720a4d3daa14ada88a4ee5e81d092adab Mon Sep 17 00:00:00 2001
From: Pierre
Date: Wed, 24 Jul 2024 18:10:13 +0200
Subject: [PATCH 61/77] test QA with no GITHUB_TOKEN permissions
---
.github/workflows/qa.yml | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/.github/workflows/qa.yml b/.github/workflows/qa.yml
index f3af6f1..d73c25f 100644
--- a/.github/workflows/qa.yml
+++ b/.github/workflows/qa.yml
@@ -12,6 +12,7 @@ jobs:
name: >
'args' input
runs-on: ubuntu-latest
+ permissions: {}
steps:
- uses: actions/checkout@v4
with:
@@ -29,6 +30,7 @@ jobs:
name: >
'projectBaseDir' input
runs-on: ubuntu-latest
+ permissions: {}
steps:
- uses: actions/checkout@v4
with:
@@ -49,6 +51,7 @@ jobs:
name: >
'SONAR_TOKEN' env var required
runs-on: ubuntu-latest
+ permissions: {}
steps:
- uses: actions/checkout@v4
with:
@@ -67,6 +70,7 @@ jobs:
name: >
Don't fail on Gradle project
runs-on: ubuntu-latest
+ permissions: {}
steps:
- uses: actions/checkout@v4
with:
@@ -87,6 +91,7 @@ jobs:
name: >
Don't fail on Kotlin Gradle project
runs-on: ubuntu-latest
+ permissions: {}
steps:
- uses: actions/checkout@v4
with:
@@ -107,6 +112,7 @@ jobs:
name: >
Don't fail on Maven project
runs-on: ubuntu-latest
+ permissions: {}
steps:
- uses: actions/checkout@v4
with:
@@ -127,6 +133,7 @@ jobs:
name: >
'RUNNER_DEBUG' is used
runs-on: ubuntu-latest
+ permissions: {}
steps:
- uses: actions/checkout@v4
with:
From f5003fc9688ade81ce47b57a3fa97a8d3f12de4c Mon Sep 17 00:00:00 2001
From: Pierre
Date: Wed, 24 Jul 2024 18:16:38 +0200
Subject: [PATCH 62/77] Revert "test QA with no GITHUB_TOKEN permissions"
This reverts commit 3bf6e4b720a4d3daa14ada88a4ee5e81d092adab.
---
.github/workflows/qa.yml | 7 -------
1 file changed, 7 deletions(-)
diff --git a/.github/workflows/qa.yml b/.github/workflows/qa.yml
index d73c25f..f3af6f1 100644
--- a/.github/workflows/qa.yml
+++ b/.github/workflows/qa.yml
@@ -12,7 +12,6 @@ jobs:
name: >
'args' input
runs-on: ubuntu-latest
- permissions: {}
steps:
- uses: actions/checkout@v4
with:
@@ -30,7 +29,6 @@ jobs:
name: >
'projectBaseDir' input
runs-on: ubuntu-latest
- permissions: {}
steps:
- uses: actions/checkout@v4
with:
@@ -51,7 +49,6 @@ jobs:
name: >
'SONAR_TOKEN' env var required
runs-on: ubuntu-latest
- permissions: {}
steps:
- uses: actions/checkout@v4
with:
@@ -70,7 +67,6 @@ jobs:
name: >
Don't fail on Gradle project
runs-on: ubuntu-latest
- permissions: {}
steps:
- uses: actions/checkout@v4
with:
@@ -91,7 +87,6 @@ jobs:
name: >
Don't fail on Kotlin Gradle project
runs-on: ubuntu-latest
- permissions: {}
steps:
- uses: actions/checkout@v4
with:
@@ -112,7 +107,6 @@ jobs:
name: >
Don't fail on Maven project
runs-on: ubuntu-latest
- permissions: {}
steps:
- uses: actions/checkout@v4
with:
@@ -133,7 +127,6 @@ jobs:
name: >
'RUNNER_DEBUG' is used
runs-on: ubuntu-latest
- permissions: {}
steps:
- uses: actions/checkout@v4
with:
From eb211723266fe8e83102bac7361f0a05c3ac1d1b Mon Sep 17 00:00:00 2001
From: Istvan Bodo <127833893+istvan-bodo-sonarsource@users.noreply.github.com>
Date: Tue, 20 Aug 2024 10:54:41 +0200
Subject: [PATCH 63/77] SCSCANGHA-23 Update scanner cli to v11.0 (#90)
---
.github/workflows/qa.yml | 14 +++++++-------
Dockerfile | 4 ++--
2 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/.github/workflows/qa.yml b/.github/workflows/qa.yml
index f3af6f1..92c0135 100644
--- a/.github/workflows/qa.yml
+++ b/.github/workflows/qa.yml
@@ -19,7 +19,7 @@ jobs:
- name: Run action with args
uses: ./
with:
- args: -Dsonar.someArg=aValue -Dsonar.scanner.dumpToFile=./output.properties
+ args: -Dsonar.someArg=aValue -Dsonar.scanner.internal.dumpToFile=./output.properties
env:
SONAR_TOKEN: FAKE_TOKEN
- name: Assert
@@ -38,7 +38,7 @@ jobs:
- name: Run action with projectBaseDir
uses: ./
with:
- args: -Dsonar.scanner.dumpToFile=./output.properties
+ args: -Dsonar.scanner.internal.dumpToFile=./output.properties
projectBaseDir: ./baseDir
env:
SONAR_TOKEN: FAKE_TOKEN
@@ -56,7 +56,7 @@ jobs:
- name: Run action without SONAR_TOKEN
uses: ./
with:
- args: -Dsonar.scanner.dumpToFile=./output.properties
+ args: -Dsonar.scanner.internal.dumpToFile=./output.properties
continue-on-error: true
- name: Previous should have failed
if: ${{ steps.runTest.outcome == 'success'}}
@@ -79,7 +79,7 @@ jobs:
SONAR_TOKEN: FAKE_TOKEN
with:
projectBaseDir: ./test/gradle-project
- args: -Dsonar.scanner.dumpToFile=./output.properties
+ args: -Dsonar.scanner.internal.dumpToFile=./output.properties
- name: Assert
run: |
./test/assertFileExists ./output.properties
@@ -99,7 +99,7 @@ jobs:
SONAR_TOKEN: FAKE_TOKEN
with:
projectBaseDir: ./test/gradle-project-kotlin
- args: -Dsonar.scanner.dumpToFile=./output.properties
+ args: -Dsonar.scanner.internal.dumpToFile=./output.properties
- name: Assert
run: |
./test/assertFileExists ./output.properties
@@ -119,7 +119,7 @@ jobs:
SONAR_TOKEN: FAKE_TOKEN
with:
projectBaseDir: ./test/maven-project
- args: -Dsonar.scanner.dumpToFile=./output.properties
+ args: -Dsonar.scanner.internal.dumpToFile=./output.properties
- name: Assert
run: |
./test/assertFileExists ./output.properties
@@ -134,7 +134,7 @@ jobs:
- name: Run action with debug mode
uses: ./
with:
- args: -Dsonar.scanner.dumpToFile=./output.properties
+ args: -Dsonar.scanner.internal.dumpToFile=./output.properties
env:
RUNNER_DEBUG: 1
SONAR_TOKEN: FAKE_TOKEN
diff --git a/Dockerfile b/Dockerfile
index 3e7aee8..05ec9e7 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,6 +1,6 @@
-FROM sonarsource/sonar-scanner-cli:10.0
+FROM sonarsource/sonar-scanner-cli:11.0
-LABEL version="2.2.0" \
+LABEL version="3.0.0" \
repository="https://github.com/sonarsource/sonarcloud-github-action" \
homepage="https://github.com/sonarsource/sonarcloud-github-action" \
maintainer="SonarSource" \
From 2900b02098e8818d13060762140fad033f7b746d Mon Sep 17 00:00:00 2001
From: Samir M
Date: Fri, 23 Aug 2024 16:00:06 +0200
Subject: [PATCH 64/77] BUILD-6088 Fix bad link in SECURITY.md file
---
SECURITY.md | 13 +++++++++++++
1 file changed, 13 insertions(+)
create mode 100644 SECURITY.md
diff --git a/SECURITY.md b/SECURITY.md
new file mode 100644
index 0000000..3989705
--- /dev/null
+++ b/SECURITY.md
@@ -0,0 +1,13 @@
+# Reporting Security Issues
+
+A mature software vulnerability treatment process is a cornerstone of a robust information security management system. Contributions from the community play an important role in the evolution and security of our products, and in safeguarding the security and privacy of our users.
+
+If you believe you have discovered a security vulnerability in Sonar's products, we encourage you to report it immediately.
+
+To responsibly report a security issue, please email us at [security@sonarsource.com](mailto:security@sonarsource.com). Sonar’s security team will acknowledge your report, guide you through the next steps, or request additional information if necessary. Customers with a support contract can also report the vulnerability directly through the support channel.
+
+For security vulnerabilities found in third-party libraries, please also contact the library's owner or maintainer directly.
+
+## Responsible Disclosure Policy
+
+For more information about disclosing a security vulnerability to Sonar, please refer to our community post: [Responsible Vulnerability Disclosure](https://community.sonarsource.com/t/responsible-vulnerability-disclosure/9317).
\ No newline at end of file
From 383f7e52eae3ab0510c3cb0e7d9d150bbaeab838 Mon Sep 17 00:00:00 2001
From: Julien HENRY
Date: Thu, 3 Oct 2024 11:33:42 +0200
Subject: [PATCH 65/77] SCSCANGHA-24 Update the Docker base image to the latest
minor 11.1
---
.github/workflows/qa.yml | 20 +++++++++++++++++++-
Dockerfile | 4 ++--
entrypoint.sh | 16 ++++++++++------
test/assertFileContains | 5 ++++-
test/assertFileExists | 2 ++
5 files changed, 37 insertions(+), 10 deletions(-)
diff --git a/.github/workflows/qa.yml b/.github/workflows/qa.yml
index 92c0135..dcf9500 100644
--- a/.github/workflows/qa.yml
+++ b/.github/workflows/qa.yml
@@ -141,4 +141,22 @@ jobs:
- name: Assert
run: |
./test/assertFileContains ./output.properties "sonar.verbose=true"
-
+ overrideSonarcloudUrlTest:
+ name: >
+ 'SONARCLOUD_URL' is used
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v4
+ with:
+ token: ${{ secrets.GITHUB_TOKEN }}
+ - name: Run action with SONARCLOUD_URL
+ uses: ./
+ with:
+ args: -Dsonar.scanner.internal.dumpToFile=./output.properties
+ env:
+ SONARCLOUD_URL: mirror.sonarcloud.io
+ SONAR_TOKEN: FAKE_TOKEN
+ - name: Assert
+ run: |
+ ./test/assertFileContains ./output.properties "sonar.host.url=mirror.sonarcloud.io"
+ ./test/assertFileContains ./output.properties "sonar.scanner.sonarcloudUrl=mirror.sonarcloud.io"
diff --git a/Dockerfile b/Dockerfile
index 05ec9e7..3cc91c6 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,6 +1,6 @@
-FROM sonarsource/sonar-scanner-cli:11.0
+FROM sonarsource/sonar-scanner-cli:11.1
-LABEL version="3.0.0" \
+LABEL version="3.1.0" \
repository="https://github.com/sonarsource/sonarcloud-github-action" \
homepage="https://github.com/sonarsource/sonarcloud-github-action" \
maintainer="SonarSource" \
diff --git a/entrypoint.sh b/entrypoint.sh
index 9cd1c40..d8e59e0 100755
--- a/entrypoint.sh
+++ b/entrypoint.sh
@@ -1,6 +1,8 @@
#!/bin/bash
-set -e
+set -eo pipefail
+
+declare -a args=()
if [[ -z "${SONAR_TOKEN}" ]]; then
echo "Set the SONAR_TOKEN env variable."
@@ -17,14 +19,16 @@ if [[ -f "${INPUT_PROJECTBASEDIR%/}/build.gradle" || -f "${INPUT_PROJECTBASEDIR%
to get more accurate results."
fi
-if [[ -z "${SONARCLOUD_URL}" ]]; then
- SONARCLOUD_URL="https://sonarcloud.io"
+if [[ ${SONARCLOUD_URL} ]]; then
+ args+=("-Dsonar.scanner.sonarcloudUrl=${SONARCLOUD_URL}")
fi
-debug_flag=''
if [[ "$RUNNER_DEBUG" == '1' ]]; then
- debug_flag=' --debug '
+ args+=("--debug")
fi
unset JAVA_HOME
-sonar-scanner $debug_flag -Dsonar.projectBaseDir=${INPUT_PROJECTBASEDIR} -Dsonar.host.url=${SONARCLOUD_URL} ${INPUT_ARGS}
+
+args+=("-Dsonar.projectBaseDir=${INPUT_PROJECTBASEDIR}")
+
+sonar-scanner "${args[@]}" ${INPUT_ARGS}
diff --git a/test/assertFileContains b/test/assertFileContains
index 69380e1..88a5dd2 100755
--- a/test/assertFileContains
+++ b/test/assertFileContains
@@ -1,10 +1,13 @@
#!/bin/bash
+set -eo pipefail
+
error() { echo -e "\\e[31m✗ $*\\e[0m"; }
-assertFileExists $1
+. ${BASH_SOURCE%/*}/assertFileExists $1
if ! grep -q $2 $1; then
error "'$2' not found in '$1'"
+ cat $1
exit 1
fi
\ No newline at end of file
diff --git a/test/assertFileExists b/test/assertFileExists
index 8f04686..1b7f79a 100755
--- a/test/assertFileExists
+++ b/test/assertFileExists
@@ -1,5 +1,7 @@
#!/bin/bash
+set -eo pipefail
+
error() { echo -e "\\e[31m✗ $*\\e[0m"; }
if [ ! -f $1 ]; then
From 9f9bba2c7aaf7a55eac26abbac906c3021d211b2 Mon Sep 17 00:00:00 2001
From: Evgeny Mandrikov <138671+Godin@users.noreply.github.com>
Date: Fri, 11 Oct 2024 15:21:47 +0200
Subject: [PATCH 66/77] Recommend to not use this action for analysis of Dart
code
---
README.md | 1 +
1 file changed, 1 insertion(+)
diff --git a/README.md b/README.md
index fe15a1e..c0a4606 100644
--- a/README.md
+++ b/README.md
@@ -114,6 +114,7 @@ Want to see more examples of SonarCloud in action? You can [explore current Open
* Your code is built with Gradle: use the SonarQube plugin for Gradle during the build
* You want to analyze a .NET solution: Follow our interactive tutorial for GitHub Actions after importing your project directly into SonarCloud
* You want to analyze C and C++ code: rely on our [SonarCloud Scan for C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and look at [our sample C and C++ project](https://github.com/sonarsource-cfamily-examples?q=gh-actions-sc&type=all&language=&sort=)
+* You want to analyze Dart code: use [SonarScanner CLI](https://docs.sonarsource.com/sonarcloud/advanced-setup/ci-based-analysis/sonarscanner-cli/) during the build
## Have questions or feedback?
From 982992a35a56c6bebd7c76c65e5c3e4c18e634c8 Mon Sep 17 00:00:00 2001
From: Pavel Mikula
Date: Wed, 27 Nov 2024 14:29:52 +0100
Subject: [PATCH 67/77] Add Jira integration
---
.github/PULL_REQUEST_TEMPLATE.md | 7 ++++++
.github/workflows/PullRequestClosed.yml | 29 +++++++++++++++++++++++
.github/workflows/PullRequestCreated.yml | 29 +++++++++++++++++++++++
.github/workflows/RequestReview.yml | 28 ++++++++++++++++++++++
.github/workflows/SubmitReview.yml | 30 ++++++++++++++++++++++++
5 files changed, 123 insertions(+)
create mode 100644 .github/PULL_REQUEST_TEMPLATE.md
create mode 100644 .github/workflows/PullRequestClosed.yml
create mode 100644 .github/workflows/PullRequestCreated.yml
create mode 100644 .github/workflows/RequestReview.yml
create mode 100644 .github/workflows/SubmitReview.yml
diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md
new file mode 100644
index 0000000..4ae3727
--- /dev/null
+++ b/.github/PULL_REQUEST_TEMPLATE.md
@@ -0,0 +1,7 @@
+Part of
+
diff --git a/.github/workflows/PullRequestClosed.yml b/.github/workflows/PullRequestClosed.yml
new file mode 100644
index 0000000..b50896e
--- /dev/null
+++ b/.github/workflows/PullRequestClosed.yml
@@ -0,0 +1,29 @@
+name: Pull Request Closed
+
+on:
+ pull_request:
+ types: [closed]
+
+jobs:
+ PullRequestMerged_job:
+ name: Pull Request Merged
+ runs-on: ubuntu-latest
+ permissions:
+ id-token: write
+ pull-requests: read
+ # For external PR, ticket should be moved manually
+ if: |
+ github.event.pull_request.head.repo.full_name == github.repository
+ && github.event.pull_request.merged
+ steps:
+ - id: secrets
+ uses: SonarSource/vault-action-wrapper@v3
+ with:
+ secrets: |
+ development/kv/data/jira user | JIRA_USER;
+ development/kv/data/jira token | JIRA_TOKEN;
+ - uses: sonarsource/gh-action-lt-backlog/PullRequestClosed@v2
+ with:
+ github-token: ${{secrets.GITHUB_TOKEN}}
+ jira-user: ${{ fromJSON(steps.secrets.outputs.vault).JIRA_USER }}
+ jira-token: ${{ fromJSON(steps.secrets.outputs.vault).JIRA_TOKEN }}
diff --git a/.github/workflows/PullRequestCreated.yml b/.github/workflows/PullRequestCreated.yml
new file mode 100644
index 0000000..fc20e4a
--- /dev/null
+++ b/.github/workflows/PullRequestCreated.yml
@@ -0,0 +1,29 @@
+name: Pull Request Created
+
+on:
+ pull_request:
+ types: ["opened"]
+
+jobs:
+ PullRequestCreated_job:
+ name: Pull Request Created
+ runs-on: ubuntu-latest
+ permissions:
+ id-token: write
+ # For external PR, ticket should be created manually
+ if: |
+ github.event.pull_request.head.repo.full_name == github.repository
+ steps:
+ - id: secrets
+ uses: SonarSource/vault-action-wrapper@v3
+ with:
+ secrets: |
+ development/github/token/{REPO_OWNER_NAME_DASH}-jira token | GITHUB_TOKEN;
+ development/kv/data/jira user | JIRA_USER;
+ development/kv/data/jira token | JIRA_TOKEN;
+ - uses: sonarsource/gh-action-lt-backlog/PullRequestCreated@v2
+ with:
+ github-token: ${{ fromJSON(steps.secrets.outputs.vault).GITHUB_TOKEN }}
+ jira-user: ${{ fromJSON(steps.secrets.outputs.vault).JIRA_USER }}
+ jira-token: ${{ fromJSON(steps.secrets.outputs.vault).JIRA_TOKEN }}
+ jira-project: SCSCANGHA
diff --git a/.github/workflows/RequestReview.yml b/.github/workflows/RequestReview.yml
new file mode 100644
index 0000000..5eac0d5
--- /dev/null
+++ b/.github/workflows/RequestReview.yml
@@ -0,0 +1,28 @@
+name: Request review
+
+on:
+ pull_request:
+ types: ["review_requested"]
+
+jobs:
+ RequestReview_job:
+ name: Request review
+ runs-on: ubuntu-latest
+ permissions:
+ id-token: write
+ # For external PR, ticket should be moved manually
+ if: |
+ github.event.pull_request.head.repo.full_name == github.repository
+ steps:
+ - id: secrets
+ uses: SonarSource/vault-action-wrapper@v3
+ with:
+ secrets: |
+ development/github/token/{REPO_OWNER_NAME_DASH}-jira token | GITHUB_TOKEN;
+ development/kv/data/jira user | JIRA_USER;
+ development/kv/data/jira token | JIRA_TOKEN;
+ - uses: sonarsource/gh-action-lt-backlog/RequestReview@v2
+ with:
+ github-token: ${{ fromJSON(steps.secrets.outputs.vault).GITHUB_TOKEN }}
+ jira-user: ${{ fromJSON(steps.secrets.outputs.vault).JIRA_USER }}
+ jira-token: ${{ fromJSON(steps.secrets.outputs.vault).JIRA_TOKEN }}
diff --git a/.github/workflows/SubmitReview.yml b/.github/workflows/SubmitReview.yml
new file mode 100644
index 0000000..d5f22e6
--- /dev/null
+++ b/.github/workflows/SubmitReview.yml
@@ -0,0 +1,30 @@
+name: Submit Review
+
+on:
+ pull_request_review:
+ types: [submitted]
+
+jobs:
+ SubmitReview_job:
+ name: Submit Review
+ runs-on: ubuntu-latest
+ permissions:
+ id-token: write
+ pull-requests: read
+ # For external PR, ticket should be moved manually
+ if: |
+ github.event.pull_request.head.repo.full_name == github.repository
+ && (github.event.review.state == 'changes_requested'
+ || github.event.review.state == 'approved')
+ steps:
+ - id: secrets
+ uses: SonarSource/vault-action-wrapper@v3
+ with:
+ secrets: |
+ development/kv/data/jira user | JIRA_USER;
+ development/kv/data/jira token | JIRA_TOKEN;
+ - uses: sonarsource/gh-action-lt-backlog/SubmitReview@v2
+ with:
+ github-token: ${{secrets.GITHUB_TOKEN}}
+ jira-user: ${{ fromJSON(steps.secrets.outputs.vault).JIRA_USER }}
+ jira-token: ${{ fromJSON(steps.secrets.outputs.vault).JIRA_TOKEN }}
From 48d9e10f8a0c9c63a55ab961986769bd8a750032 Mon Sep 17 00:00:00 2001
From: Antonio Aversa
Date: Thu, 31 Oct 2024 18:40:29 +0100
Subject: [PATCH 68/77] SCSCANGHA-25 Replace the Docker action by a composite
action forwarding to the SonarQube action
---
.github/workflows/qa.yml | 133 ++++++--------------
Dockerfile | 32 -----
README.md | 11 +-
action.yml | 36 ++++--
cleanup.sh | 14 ---
entrypoint.sh | 34 -----
test/assertFileDoesntExist | 8 ++
test/gradle-project-kotlin/build.gradle.kts | 0
test/gradle-project/build.gradle | 1 -
test/maven-project/pom.xml | 1 -
10 files changed, 79 insertions(+), 191 deletions(-)
delete mode 100644 Dockerfile
delete mode 100644 cleanup.sh
delete mode 100755 entrypoint.sh
create mode 100755 test/assertFileDoesntExist
delete mode 100644 test/gradle-project-kotlin/build.gradle.kts
delete mode 100644 test/gradle-project/build.gradle
delete mode 100644 test/maven-project/pom.xml
diff --git a/.github/workflows/qa.yml b/.github/workflows/qa.yml
index dcf9500..5fc2cbf 100644
--- a/.github/workflows/qa.yml
+++ b/.github/workflows/qa.yml
@@ -11,7 +11,10 @@ jobs:
argsInputTest:
name: >
'args' input
- runs-on: ubuntu-latest
+ strategy:
+ matrix:
+ os: [ ubuntu-latest, windows-latest, macos-latest ]
+ runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
with:
@@ -28,7 +31,10 @@ jobs:
projectBaseDirInputTest:
name: >
'projectBaseDir' input
- runs-on: ubuntu-latest
+ strategy:
+ matrix:
+ os: [ ubuntu-latest, windows-latest, macos-latest ]
+ runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
with:
@@ -45,118 +51,51 @@ jobs:
- name: Assert
run: |
./test/assertFileContains ./output.properties "sonar.projectBaseDir=.*/baseDir"
- sonarTokenRequiredTest:
+ scannerVersionTest:
name: >
- 'SONAR_TOKEN' env var required
- runs-on: ubuntu-latest
+ 'scannerVersion' input
+ runs-on: ubuntu-latest # assumes default RUNNER_ARCH for linux is X64
steps:
- uses: actions/checkout@v4
with:
token: ${{ secrets.GITHUB_TOKEN }}
- - name: Run action without SONAR_TOKEN
+ - name: Run action with scannerVersion
uses: ./
with:
+ scannerVersion: 6.1.0.4477
args: -Dsonar.scanner.internal.dumpToFile=./output.properties
- continue-on-error: true
- - name: Previous should have failed
- if: ${{ steps.runTest.outcome == 'success'}}
+ env:
+ NO_CACHE: true # force install-sonar-scanner-cli.sh execution
+ SONAR_HOST_URL: http://not_actually_used
+ SONAR_SCANNER_JSON_PARAMS: '{"sonar.scanner.internal.dumpToFile": "./output.properties"}'
+ - name: Assert
run: |
- echo "Expected previous step to fail"
- exit 1
- dontFailGradleTest:
+ ./test/assertFileExists "$RUNNER_TEMP/sonarscanner/sonar-scanner-cli-6.1.0.4477-linux-x64.zip"
+ scannerBinariesUrlTest:
name: >
- Don't fail on Gradle project
- runs-on: ubuntu-latest
+ 'scannerBinariesUrl' input with invalid URL
+ runs-on: ubuntu-latest # assumes default RUNNER_ARCH for linux is X64
steps:
- uses: actions/checkout@v4
with:
token: ${{ secrets.GITHUB_TOKEN }}
- - name: Run action on Gradle project
+ - name: Run action with scannerBinariesUrl
id: runTest
uses: ./
continue-on-error: true
+ with:
+ scannerVersion: 6.2.1.4610
+ scannerBinariesUrl: https://invalid_uri/Distribution/sonar-scanner-cli
env:
- SONAR_TOKEN: FAKE_TOKEN
- with:
- projectBaseDir: ./test/gradle-project
- args: -Dsonar.scanner.internal.dumpToFile=./output.properties
- - name: Assert
+ NO_CACHE: true # force install-sonar-scanner-cli.sh execution
+ SONAR_HOST_URL: http://not_actually_used
+ SONAR_SCANNER_JSON_PARAMS: '{"sonar.scanner.internal.dumpToFile": "./output.properties"}'
+ - name: Fail if action succeeded
+ if: steps.runTest.outcome == 'success'
+ run: exit 1
+ - name: Assert Sonar Scanner CLI was not downloaded
run: |
- ./test/assertFileExists ./output.properties
- dontFailGradleKotlinTest:
- name: >
- Don't fail on Kotlin Gradle project
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout@v4
- with:
- token: ${{ secrets.GITHUB_TOKEN }}
- - name: Run action on Kotlin Gradle project
- id: runTest
- uses: ./
- continue-on-error: true
- env:
- SONAR_TOKEN: FAKE_TOKEN
- with:
- projectBaseDir: ./test/gradle-project-kotlin
- args: -Dsonar.scanner.internal.dumpToFile=./output.properties
- - name: Assert
+ ./test/assertFileDoesntExist "$RUNNER_TEMP/sonarscanner/sonar-scanner-cli-6.2.1.4610-linux-x64.zip"
+ - name: Assert Sonar Scanner CLI was not executed
run: |
- ./test/assertFileExists ./output.properties
- dontFailMavenTest:
- name: >
- Don't fail on Maven project
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout@v4
- with:
- token: ${{ secrets.GITHUB_TOKEN }}
- - name: Run action on Maven project
- id: runTest
- uses: ./
- continue-on-error: true
- env:
- SONAR_TOKEN: FAKE_TOKEN
- with:
- projectBaseDir: ./test/maven-project
- args: -Dsonar.scanner.internal.dumpToFile=./output.properties
- - name: Assert
- run: |
- ./test/assertFileExists ./output.properties
- runnerDebugUsedTest:
- name: >
- 'RUNNER_DEBUG' is used
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout@v4
- with:
- token: ${{ secrets.GITHUB_TOKEN }}
- - name: Run action with debug mode
- uses: ./
- with:
- args: -Dsonar.scanner.internal.dumpToFile=./output.properties
- env:
- RUNNER_DEBUG: 1
- SONAR_TOKEN: FAKE_TOKEN
- - name: Assert
- run: |
- ./test/assertFileContains ./output.properties "sonar.verbose=true"
- overrideSonarcloudUrlTest:
- name: >
- 'SONARCLOUD_URL' is used
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout@v4
- with:
- token: ${{ secrets.GITHUB_TOKEN }}
- - name: Run action with SONARCLOUD_URL
- uses: ./
- with:
- args: -Dsonar.scanner.internal.dumpToFile=./output.properties
- env:
- SONARCLOUD_URL: mirror.sonarcloud.io
- SONAR_TOKEN: FAKE_TOKEN
- - name: Assert
- run: |
- ./test/assertFileContains ./output.properties "sonar.host.url=mirror.sonarcloud.io"
- ./test/assertFileContains ./output.properties "sonar.scanner.sonarcloudUrl=mirror.sonarcloud.io"
+ ./test/assertFileDoesntExist ./output.properties
diff --git a/Dockerfile b/Dockerfile
deleted file mode 100644
index 3cc91c6..0000000
--- a/Dockerfile
+++ /dev/null
@@ -1,32 +0,0 @@
-FROM sonarsource/sonar-scanner-cli:11.1
-
-LABEL version="3.1.0" \
- repository="https://github.com/sonarsource/sonarcloud-github-action" \
- homepage="https://github.com/sonarsource/sonarcloud-github-action" \
- maintainer="SonarSource" \
- com.github.actions.name="SonarCloud Scan" \
- com.github.actions.description="Scan your code with SonarCloud to detect bugs, vulnerabilities and code smells in more than 25 programming languages." \
- com.github.actions.icon="check" \
- com.github.actions.color="green"
-
-ARG SONAR_SCANNER_HOME=/opt/sonar-scanner
-ARG NODEJS_HOME=/opt/nodejs
-
-ENV PATH=${PATH}:${SONAR_SCANNER_HOME}/bin:${NODEJS_HOME}/bin
-
-# set up local envs in order to allow for special chars (non-asci) in filenames
-ENV LC_ALL="C.UTF-8"
-
-WORKDIR /opt
-
-# GitHub actions should be run under ROOT
-# https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners/about-github-hosted-runners#docker-container-filesystem
-USER 0
-
-# Prepare entrypoint
-COPY entrypoint.sh /entrypoint.sh
-RUN chmod +x /entrypoint.sh
-COPY cleanup.sh /cleanup.sh
-RUN chmod +x /cleanup.sh
-
-ENTRYPOINT ["/entrypoint.sh"]
diff --git a/README.md b/README.md
index c0a4606..99428e9 100644
--- a/README.md
+++ b/README.md
@@ -81,6 +81,14 @@ In case you need to add additional analysis parameters, you can use the `args` o
More information about possible analysis parameters is found in the documentation at:
https://docs.sonarcloud.io/advanced-setup/analysis-parameters
+In case you need to specify the version of the Sonar Scanner, you can use the `scannerVersion` option:
+
+```yaml
+uses: sonarsource/sonarcloud-github-action@ # Ex: v2.1.0, See the latest version at https://github.com/marketplace/actions/sonarcloud-scan
+with:
+ scannerVersion: 6.2.0.4584
+```
+
See also example configurations at:
https://github.com/sonarsource/sonarcloud-github-action-samples/
@@ -114,7 +122,6 @@ Want to see more examples of SonarCloud in action? You can [explore current Open
* Your code is built with Gradle: use the SonarQube plugin for Gradle during the build
* You want to analyze a .NET solution: Follow our interactive tutorial for GitHub Actions after importing your project directly into SonarCloud
* You want to analyze C and C++ code: rely on our [SonarCloud Scan for C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and look at [our sample C and C++ project](https://github.com/sonarsource-cfamily-examples?q=gh-actions-sc&type=all&language=&sort=)
-* You want to analyze Dart code: use [SonarScanner CLI](https://docs.sonarsource.com/sonarcloud/advanced-setup/ci-based-analysis/sonarscanner-cli/) during the build
## Have questions or feedback?
@@ -122,6 +129,4 @@ To provide feedback (requesting a feature or reporting a bug) please post on the
## License
-The Dockerfile and associated scripts and documentation in this project are released under the LGPLv3 License.
-
Container images built with this project include third-party materials.
diff --git a/action.yml b/action.yml
index de11390..9573796 100644
--- a/action.yml
+++ b/action.yml
@@ -1,20 +1,38 @@
name: SonarCloud Scan
description: >
- Scan your code with SonarCloud to detect bugs, vulnerabilities and code smells
- in 26+ programming languages.
+ Scan your code with SonarQube Cloud to detect coding issues in 30+
+ languages, frameworks, and IaC platforms.
+ The solution also provides fix recommendations leveraging AI with
+ Sonar's AI CodeFix capability. (Formerly SonarCloud)
branding:
icon: check
color: green
-runs:
- using: docker
- image: Dockerfile
- entrypoint: "/entrypoint.sh"
- post-entrypoint: "/cleanup.sh"
inputs:
args:
- description: Additional arguments to the sonarcloud scanner
+ description: Additional arguments to the Sonar Scanner CLI
required: false
projectBaseDir:
description: Set the sonar.projectBaseDir analysis property
required: false
- default: .
+ scannerVersion:
+ description: Version of the Sonar Scanner CLI to use
+ required: false
+ default: 6.2.1.4610
+ scannerBinariesUrl:
+ description: URL to download the Sonar Scanner CLI binaries from
+ required: false
+ default: https://binaries.sonarsource.com/Distribution/sonar-scanner-cli
+runs:
+ using: "composite"
+ steps:
+ - name: Deprecation warning
+ shell: bash
+ run: |
+ echo "::warning title=SonarScanner::This action is deprecated and will be removed in a future release. Please use the sonarqube-scan-action action instead. The sonarqube-scan-action is a drop-in replacement for this action."
+ - name: SonarQube Cloud Scan
+ uses: SonarSource/sonarqube-scan-action@v4.1.0
+ with:
+ args: ${{ inputs.args }}
+ projectBaseDir: ${{ inputs.projectBaseDir }}
+ scannerVersion: ${{ inputs.scannerVersion }}
+ scannerBinariesUrl: ${{ inputs.scannerBinariesUrl }}
diff --git a/cleanup.sh b/cleanup.sh
deleted file mode 100644
index 8a5e4c9..0000000
--- a/cleanup.sh
+++ /dev/null
@@ -1,14 +0,0 @@
-#!/bin/bash
-
-set -e
-
-if [ ! -d "${INPUT_PROJECTBASEDIR}/.scannerwork" ]; then
- echo ".scannerwork directory not found; nothing to clean up."
- exit
-fi
-
-_tmp_file=$(ls "${INPUT_PROJECTBASEDIR}/" | head -1)
-PERM=$(stat -c "%u:%g" "${INPUT_PROJECTBASEDIR}/$_tmp_file")
-
-chown -R "$PERM" "${INPUT_PROJECTBASEDIR}/.scannerwork/"
-
diff --git a/entrypoint.sh b/entrypoint.sh
deleted file mode 100755
index d8e59e0..0000000
--- a/entrypoint.sh
+++ /dev/null
@@ -1,34 +0,0 @@
-#!/bin/bash
-
-set -eo pipefail
-
-declare -a args=()
-
-if [[ -z "${SONAR_TOKEN}" ]]; then
- echo "Set the SONAR_TOKEN env variable."
- exit 1
-fi
-
-if [[ -f "${INPUT_PROJECTBASEDIR%/}/pom.xml" ]]; then
- 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" || -f "${INPUT_PROJECTBASEDIR%/}/build.gradle.kts" ]]; then
- 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
-
-if [[ ${SONARCLOUD_URL} ]]; then
- args+=("-Dsonar.scanner.sonarcloudUrl=${SONARCLOUD_URL}")
-fi
-
-if [[ "$RUNNER_DEBUG" == '1' ]]; then
- args+=("--debug")
-fi
-
-unset JAVA_HOME
-
-args+=("-Dsonar.projectBaseDir=${INPUT_PROJECTBASEDIR}")
-
-sonar-scanner "${args[@]}" ${INPUT_ARGS}
diff --git a/test/assertFileDoesntExist b/test/assertFileDoesntExist
new file mode 100755
index 0000000..032a07c
--- /dev/null
+++ b/test/assertFileDoesntExist
@@ -0,0 +1,8 @@
+#!/bin/bash
+
+error() { echo -e "\\e[31m✗ $*\\e[0m"; }
+
+if [ -f $1 ]; then
+ error "File '$1' found"
+ exit 1
+fi
\ No newline at end of file
diff --git a/test/gradle-project-kotlin/build.gradle.kts b/test/gradle-project-kotlin/build.gradle.kts
deleted file mode 100644
index e69de29..0000000
diff --git a/test/gradle-project/build.gradle b/test/gradle-project/build.gradle
deleted file mode 100644
index 8b13789..0000000
--- a/test/gradle-project/build.gradle
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/test/maven-project/pom.xml b/test/maven-project/pom.xml
deleted file mode 100644
index 8b13789..0000000
--- a/test/maven-project/pom.xml
+++ /dev/null
@@ -1 +0,0 @@
-
From 4afec8845b1f72780b5e4dcb03ce8338fce48f9c Mon Sep 17 00:00:00 2001
From: Antonio Aversa
Date: Tue, 19 Nov 2024 10:29:09 +0100
Subject: [PATCH 69/77] SCSCANGHA-28 Rebranding
---
README.md | 145 ++++++++++++---------
action.yml | 2 +-
images/SQ_Logo_Cloud_Dark_Backgrounds.png | Bin 0 -> 21928 bytes
images/SQ_Logo_Cloud_Light_Backgrounds.png | Bin 0 -> 23073 bytes
images/SonarCloud-72px.png | Bin 3735 -> 0 bytes
images/SonarCloud-analysis-in-Checks.png | Bin 96420 -> 0 bytes
6 files changed, 83 insertions(+), 64 deletions(-)
create mode 100644 images/SQ_Logo_Cloud_Dark_Backgrounds.png
create mode 100644 images/SQ_Logo_Cloud_Light_Backgrounds.png
delete mode 100644 images/SonarCloud-72px.png
delete mode 100644 images/SonarCloud-analysis-in-Checks.png
diff --git a/README.md b/README.md
index 99428e9..7a40440 100644
--- a/README.md
+++ b/README.md
@@ -1,131 +1,150 @@
-# Analyze your code for free with SonarCloud
+# Scan your code with SonarQube Cloud [](https://github.com/SonarSource/sonarcloud-github-action/actions/workflows/qa.yml)
-This SonarSource project, available as a GitHub Action, scans your projects with SonarCloud, and helps developers produce
-[Clean Code](https://www.sonarsource.com/solutions/clean-code/?utm_medium=referral&utm_source=github&utm_campaign=clean-code&utm_content=sonarqube-scan-action).
+> [!WARNING]
+> This action is deprecated and will be removed in a future release.
+> Please use the `sonarqube-scan-action` action instead.
+> The `sonarqube-scan-action` is a drop-in replacement for this action.
-
+This SonarSource project, available as a GitHub Action, scans your projects with SonarQube [Cloud](https://www.sonarsource.com/products/sonarcloud/).
-[SonarCloud](https://www.sonarsource.com/products/sonarcloud/) is a widely used static analysis solution for continuous code quality and security inspection.
-It helps developers identify and fix issues in their code that could lead to bugs, vulnerabilities, or decreased development velocity.
-SonarCloud supports the most popular programming languages, including Java, JavaScript, TypeScript, C#, Python, C, C++, and [many more](https://www.sonarsource.com/knowledge/languages/).
+
+
+
+SonarQube [Cloud](https://www.sonarsource.com/products/sonarcloud/) (formerly SonarCloud) is a widely used static analysis solution for continuous code quality and security inspection.
+
+It helps developers detect coding issues in 30+ languages, frameworks, and IaC platforms, including Java, JavaScript, TypeScript, C#, Python, C, C++, and [many more](https://www.sonarsource.com/knowledge/languages/).
+
+The solution also provides fix recommendations leveraging AI with Sonar's AI CodeFix capability.
## Requirements
-* Create your account on SonarCloud. Sign up for free now if it's not already the case! [SonarCloud Sign up](https://www.sonarsource.com/products/sonarcloud/signup/?utm_medium=referral&utm_source=github&utm_campaign=sc-signup&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x)
-* The repository to analyze is set up on SonarCloud. [Set it up](https://sonarcloud.io/projects/create) in just one click.
+* Create your account on SonarQube Cloud. [Sign up for free](https://www.sonarsource.com/products/sonarcloud/signup/?utm_medium=referral&utm_source=github&utm_campaign=sc-signup&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x) now if it's not already the case!
+* The repository to analyze is set up on SonarQube Cloud. [Set it up](https://sonarcloud.io/projects/create) in just one click.
## Usage
Project metadata, including the location of the sources to be analyzed, must be declared in the file `sonar-project.properties` in the base directory:
```properties
-sonar.organization=
-sonar.projectKey=
+sonar.organization=
+sonar.projectKey=
# relative paths to source directories. More details and properties are described
-# in https://sonarcloud.io/documentation/project-administration/narrowing-the-focus/
+# at https://docs.sonarsource.com/sonarqube-cloud/advanced-setup/analysis-scope/
sonar.sources=.
```
-The workflow, usually declared in `.github/workflows/build.yml`, looks like:
+The workflow, usually declared under `.github/workflows`, looks like:
```yaml
on:
- # Trigger analysis when pushing in master or pull requests, and when creating
- # a pull request.
+ # Trigger analysis when pushing to your main branches, and when creating a pull request.
push:
branches:
+ - main
- master
+ - develop
+ - 'releases/**'
pull_request:
types: [opened, synchronize, reopened]
+
name: Main Workflow
jobs:
- sonarcloud:
+ sonarqube:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
- # Disabling shallow clone is recommended for improving relevancy of reporting
+ # Disabling shallow clones is recommended for improving the relevancy of reporting
fetch-depth: 0
- - name: SonarCloud Scan
- uses: sonarsource/sonarcloud-github-action@ # Ex: v2.1.0, See the latest version at https://github.com/marketplace/actions/sonarcloud-scan
+ - name: SonarQube Scan
+ uses: sonarsource/sonarcloud-github-action@ # Ex: v4.0.0, See the latest version at https://github.com/marketplace/actions/sonarcloud-scan
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
```
+## Action parameters
+
You can change the analysis base directory by using the optional input `projectBaseDir` like this:
```yaml
-uses: sonarsource/sonarcloud-github-action@ # Ex: v2.1.0, See the latest version at https://github.com/marketplace/actions/sonarcloud-scan
-with:
- projectBaseDir: my-custom-directory
+- uses: sonarsource/sonarcloud-github-action@
+ with:
+ projectBaseDir: app/src
```
-In case you need to add additional analysis parameters, you can use the `args` option:
+In case you need to specify the version of the Sonar Scanner, you can use the `scannerVersion` option:
```yaml
-- name: Analyze with SonarCloud
- uses: sonarsource/sonarcloud-github-action@ # Ex: v2.1.0, See the latest version at https://github.com/marketplace/actions/sonarcloud-scan
+- uses: sonarsource/sonarcloud-github-action@
with:
- projectBaseDir: my-custom-directory
+ scannerVersion: 6.2.0.4584
+```
+
+In case you need to add additional analysis parameters, and you do not wish to set them in the `sonar-project.properties` file, you can use the `args` option:
+
+```yaml
+- uses: sonarsource/sonarcloud-github-action@
+ with:
+ projectBaseDir: app/src
args: >
-Dsonar.organization=my-organization
-Dsonar.projectKey=my-projectkey
-Dsonar.python.coverage.reportPaths=coverage.xml
-Dsonar.sources=lib/
- -Dsonar.test.exclusions=tests/**
-Dsonar.tests=tests/
+ -Dsonar.test.exclusions=tests/**
-Dsonar.verbose=true
```
-More information about possible analysis parameters is found in the documentation at:
-https://docs.sonarcloud.io/advanced-setup/analysis-parameters
-
-In case you need to specify the version of the Sonar Scanner, you can use the `scannerVersion` option:
+You can also specify the URL where to retrieve the SonarScanner CLI from.
+The specified URL overrides the default address: `https://binaries.sonarsource.com/Distribution/sonar-scanner-cli`.
+This can be useful when the runner executing the action is self-hosted and has regulated or no access to the Internet:
```yaml
-uses: sonarsource/sonarcloud-github-action@ # Ex: v2.1.0, See the latest version at https://github.com/marketplace/actions/sonarcloud-scan
-with:
- scannerVersion: 6.2.0.4584
-```
-
-See also example configurations at:
-https://github.com/sonarsource/sonarcloud-github-action-samples/
-
-### Secrets
-
-- `SONAR_TOKEN` – **Required** this is the token used to authenticate access to SonarCloud. You can generate a token on your [Security page in SonarCloud](https://sonarcloud.io/account/security/). You can set the `SONAR_TOKEN` environment variable in the "Secrets" settings page of your repository.
-- *`GITHUB_TOKEN` – Provided by Github (see [Authenticating with the GITHUB_TOKEN](https://help.github.com/en/actions/automating-your-workflow-with-github-actions/authenticating-with-the-github_token)).*
-
-## Error cleaning up workspace
-
-In some cases, the checkout action may fail to clean up the workspace. This is a known problem for GitHub actions implemented as a docker container (such as `sonarcloud-github-actions`) when self-hosted runners are used.
-Example of the error message: `File was unable to be removed Error: EACCES: permission denied, unlink '/actions-runner/_work//project/.scannerwork/.sonar_lock'`
-To work around the problem, `sonarcloud-github-action` attempts to fix the permission of the temporary files that it creates. If that doesn't work, you can manually clean up the workspace by running the following action:
-```
-- name: Clean the workspace
- uses: docker://alpine
+- uses: sonarsource/sonarcloud-github-action@
with:
- args: /bin/sh -c "find \"${GITHUB_WORKSPACE}\" -mindepth 1 ! -name . -prune -exec rm -rf {} +"
+ scannerBinariesUrl: https://my.custom.binaries.url.com/Distribution/sonar-scanner-cli/
```
-You can find more info [here](https://github.com/actions/runner/issues/434).
-## Example of pull request analysis
+More information about possible analysis parameters can be found in the [Analysis parameters page](https://docs.sonarsource.com/sonarqube-cloud/advanced-setup/analysis-parameters/) of the SonarQube Cloud documentation.
-
+### Environment variables
-Want to see more examples of SonarCloud in action? You can [explore current Open Source projects in SonarCloud](https://sonarcloud.io/explore/projects?sort=-analysis_date?utm_medium=referral&utm_source=github&utm_campaign=sc-signup&utm_content=signup-sonarcloud-listing-x-x&utm_term=ww-psp-x) that are using the Clean as You Code methodology.
+- `SONAR_TOKEN` – **Required** this is the token used to authenticate access to SonarQube. You can read more about security tokens in the [documentation](https://docs.sonarsource.com/sonarqube-cloud/managing-your-account/managing-tokens/). You can set the `SONAR_TOKEN` environment variable in the "Secrets" settings page of your repository, or you can add them at the level of your GitHub organization (recommended).
+- *`GITHUB_TOKEN` – Provided by Github (see [Authenticating with the GITHUB_TOKEN](https://help.github.com/en/actions/automating-your-workflow-with-github-actions/authenticating-with-the-github_token)).*
+- `SONAR_ROOT_CERT` – Holds an additional certificate (in PEM format) that is used to validate the certificate of a secured proxy to SonarQube Cloud. You can set the `SONAR_ROOT_CERT` environment variable in the "Secrets" settings page of your repository, or you can add them at the level of your GitHub organization (recommended).
-## Do not use this GitHub action if you are in the following situations
+Here is an example of how you can pass a certificate (in PEM format) to the Scanner truststore:
-* Your code is built with Maven: run 'org.sonarsource.scanner.maven:sonar' during the build
-* Your code is built with Gradle: use the SonarQube plugin for Gradle during the build
-* You want to analyze a .NET solution: Follow our interactive tutorial for GitHub Actions after importing your project directly into SonarCloud
-* You want to analyze C and C++ code: rely on our [SonarCloud Scan for C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) and look at [our sample C and C++ project](https://github.com/sonarsource-cfamily-examples?q=gh-actions-sc&type=all&language=&sort=)
+```yaml
+- uses: sonarsource/sonarcloud-github-action@
+ env:
+ SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
+ SONAR_ROOT_CERT: ${{ secrets.SONAR_ROOT_CERT }}
+```
+
+If your source code file names contain special characters that are not covered by the locale range of `en_US.UTF-8`, you can configure your desired locale like this:
+
+```yaml
+- uses: sonarsource/sonarcloud-github-action@
+ env:
+ SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
+ LC_ALL: "ru_RU.UTF-8"
+```
+
+## Alternatives for Java, .NET, and C/C++ projects
+
+This GitHub Action will not work for all technologies. If you are in one of the following situations, you should use the following alternatives:
+
+* Your code is built with Maven. Read the documentation about our [SonarScanner for Maven](https://docs.sonarsource.com/sonarqube-cloud/advanced-setup/ci-based-analysis/sonarscanner-for-maven/).
+* Your code is built with Gradle. Read the documentation about our [SonarScanner for Gradle](https://docs.sonarsource.com/sonarqube-cloud/advanced-setup/ci-based-analysis/sonarscanner-for-gradle/).
+* You want to analyze a .NET solution. Read the documentation about our [SonarScanner for .NET](https://docs.sonarsource.com/sonarqube-cloud/advanced-setup/ci-based-analysis/sonarscanner-for-dotnet/introduction/).
+* You want to analyze C or C++ code. Starting from SonarQube 10.6, this GitHub Action will scan C and C++ out of the box. If you want to have better control over the scan configuration/setup, you can switch to the [SonarQube Cloud Scan for C and C++](https://github.com/marketplace/actions/sonarcloud-scan-for-c-and-c) GitHub Action - look at [our sample C and C++ project](https://github.com/sonarsource-cfamily-examples?q=gh-actions-sc&type=all&language=&sort=).
## Have questions or feedback?
-To provide feedback (requesting a feature or reporting a bug) please post on the [SonarSource Community Forum](https://community.sonarsource.com/) with the tag `sonarcloud`.
+To provide feedback (requesting a feature or reporting a bug) please post on the [SonarSource Community Forum](https://community.sonarsource.com/tags/c/help/sc/9/github-actions).
## License
diff --git a/action.yml b/action.yml
index 9573796..f4d07e9 100644
--- a/action.yml
+++ b/action.yml
@@ -1,4 +1,4 @@
-name: SonarCloud Scan
+name: SonarQube Cloud Scan
description: >
Scan your code with SonarQube Cloud to detect coding issues in 30+
languages, frameworks, and IaC platforms.
diff --git a/images/SQ_Logo_Cloud_Dark_Backgrounds.png b/images/SQ_Logo_Cloud_Dark_Backgrounds.png
new file mode 100644
index 0000000000000000000000000000000000000000..9e9a1f41fbee273783b6a7d7ab70eca31d1cb103
GIT binary patch
literal 21928
zcmeFY_dnb3_dgz`sztTbE=rB6z4xp=Thv~y5gN1hR{GScRV!xD)~LN>Z?*SG5P}-9
zA_!vpq_6j%@cs3h+by@;^0*$?bVdez@kW&5o5&$x@>F^H;ybRQp0Tp9UxAA|7fJ(Yb06=vD>D9Zt
z0Ki*0O%)|0e**N9k}sn=cenTwhXUw#?`H6wi>=oQavFiD(^ggpfbACTB8wo
z_m0W4Z!h878NaE&ntxg$uX~YbH7nBdOBywwbjVpb%PIUfCQDY
zRJM&9;&b8*4J>Hvbo7-0na#=9H#TnG_>~1vbbaLg(`Xcp(%ofH7>soS?6igLOs$9B
zW+?;<{1fl^Esv_;L#WRTlsXL-udVG-j!m$Uy9)k4-9A(2>5v;{5i9g*BN(wxKD%cv
zvn>J=MEHuGGl|>(lN@?vooOI4zo3uu9SFXIFPVN-NL3)xUd-$wWpzJoNPA}^<$IFdx$wBfPokMb|-
zozu2H47y5Jxz^<1Us9AJk$wZ3zjz%`Sw3&TQ^9nz-K;}krjIYmdrAaJ=b1NuW9A%_
z>?3ePTKsyTCUkdtUHt!wB_s4k%HPp=J6L5e|1No#2u7Gcx4EebI(dz+3{ZK#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mwTHRDe)GyWP3a<@Q(OFuQ6~7$dr>
z2WCwZ*uP%zqT&jAzF3s|w$q8|6I#~C9ue`SQMj#X%<|OJ<3l4d^kH*YR!76fxQoDS
zCSS@95qsUx)-r)%N1V~XrG!OLKHYb+9yepKfaY}};LUjTG3wC|ee3*d>LE*A5qA!J
z)Am#NJb|w3kjR75|M*mP
zK0jj^r(xi$*4Op47+w2g|p_16BfH%jJt_fy?vyQnur^PU=nN$
zR-`11mK7dRj+{FTNzY|NbEYi*pa*!Idgx6s{rf*2RG)6uqJ`Bsx^o)m^rHyto_MH&
zFODP1ZEbtC)IJMP3jwNq0rR5zzKwyd9;lQ=elNXZkpN%Nt=-^rj#Dh07YL@ditsoC
zPa#ME@QkGuJqIfzMT17S=WJ)QO1c*sRUeL1)Cl%7f~gKe&T=6h~7y0Ltwi-
zOD}#gPwt7!QYxNp%KWp-DV6Wh_5wuOwB!48hD$!r;OX%q{P*{tS%H7rjsTq?Xn5@K
R@|EL?cl1njOKv)Z{|~^DYvup|
literal 0
HcmV?d00001
diff --git a/images/SQ_Logo_Cloud_Light_Backgrounds.png b/images/SQ_Logo_Cloud_Light_Backgrounds.png
new file mode 100644
index 0000000000000000000000000000000000000000..4a7f25ef944058ce6f86ee030af45739b8a8314f
GIT binary patch
literal 23073
zcmeEu^;cWZ7cJDFPzsb%DB2b)P^@^MP`p^6xVsd0w@-_-c!A;siaQhu9w_b!9tf_%
zf&~Z`cg3E(n|SriCb|g~TazdIp-o>|
z8?b(|$|ZV>x2*PnOaB2&p5Di4p1btB=lHn({QuYg%Lx3pWBK5%J{A*Cqmk67CNZ8A
zcRPViji&!Mvb;%zptqx9jFNU&vQ+^*qe%=7F`kf5Y=NG!sr_rJ{g)6BnT}6OCROV_
z+|gzn}d>Pz~?~DEa=dE_5|UH8M2Ji
zk#pe?KqJ$?{&Pf*MRsvjeemNQ`Gv@%wgf!8_ht9Ip(Uhk_QgMYvedS0?(Sav?#y(1
z(&KTwT}a2_#D+X(64U-aJB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