Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pre-release 5.0.0, support SonarQube 10.x.x #401

Merged
merged 23 commits into from
Jun 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
7f61850
support SQ10 + add expiration date to token
Topin2001 May 22, 2024
ac080b7
Remove plugin func to use only standalone, even for plugin uses
Topin2001 May 23, 2024
965f42b
Fix broken CI
Topin2001 May 27, 2024
7669974
update maven dependencies
Topin2001 May 28, 2024
1106ed8
Added branch name in md report
Topin2001 May 28, 2024
68b2d7d
Implement git branch display on docx file
Topin2001 May 31, 2024
e9465d3
Update yarn.lock file
Topin2001 May 31, 2024
9751abd
Added ProjectBranch Tests
Topin2001 Jun 4, 2024
793c250
Update plugin version + fix jacoco report
Topin2001 Jun 4, 2024
0bb01a6
Implement new qualityGates tests
Topin2001 Jun 4, 2024
8bfe242
Fix untest case of matching qualitygate
Topin2001 Jun 4, 2024
afb8e05
Added starting programs tests
Topin2001 Jun 4, 2024
ba95ce8
Fix sonarlint issues
Topin2001 Jun 4, 2024
de4a418
Fix intellij issues
Topin2001 Jun 4, 2024
550d0f7
Fix sonarlint issues and crlf
Topin2001 Jun 4, 2024
9f1cdd5
Clean update of front according to the sonar plugin exemple method
Topin2001 Jun 5, 2024
694aa3f
Update and clean the front project, added new style.css file
Topin2001 Jun 5, 2024
23ebe38
Update conf repository location
Topin2001 Jun 11, 2024
50e8184
Added generation report page from project page
Topin2001 Jun 11, 2024
1d5c828
Allow for all SQ 10 versions; even if dev only for 10.5
Topin2001 Jun 11, 2024
878516f
Update documentation
Topin2001 Jun 11, 2024
ee4423e
Merge pull request #397 from cnescatlab/update/sq10-support
Topin2001 Jun 27, 2024
0270ee1
Add permissions for github action token
louisjdmartin Jun 27, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/close-milestone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ on:
jobs:
close:
name: Close completed milestone
runs-on: ubuntu-latest
runs-on: ubuntu-22.04
if: ${{ github.event.workflow_run.conclusion == 'success' }}
steps:
- name: Close a milestone if completed
Expand Down
10 changes: 6 additions & 4 deletions .github/workflows/draft-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,17 +12,19 @@ on:

jobs:
release:
runs-on: ubuntu-latest
runs-on: ubuntu-22.04
permissions:
contents: write
steps:
- name: Check out repository code
uses: actions/checkout@v2
uses: actions/checkout@v4
- name: Setup java
uses: actions/setup-java@v2
uses: actions/setup-java@v4
with:
distribution: 'adopt'
java-version: '17'
- name: Cache Maven packages
uses: actions/cache@v2
uses: actions/cache@v4
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
Expand Down
16 changes: 8 additions & 8 deletions .github/workflows/java-continuous-integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,29 +12,29 @@ on: [push, pull_request]
jobs:

build:
runs-on: ubuntu-latest
runs-on: ubuntu-22.04
strategy:
matrix:
java: [ '17' ]
name: Java ${{ matrix.Java }} CI
steps:
- name: Check out repository code
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup java
uses: actions/setup-java@v2
uses: actions/setup-java@v4
with:
distribution: 'adopt'
java-version: ${{ matrix.java }}
- name: Cache Maven packages
uses: actions/cache@v2
uses: actions/cache@v4
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2
- name: Cache node_modules
uses: actions/cache@v2
uses: actions/cache@v4
with:
path: node_modules
key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }}
Expand All @@ -43,14 +43,13 @@ jobs:
run: mvn -B clean package
- name: Test cnes-report
env:
SONARQUBE_VERSION: 9.9-community
SONARQUBE_VERSION: 10.5-community
run: |
version=$(cat pom.xml | grep "<version>.*</version>" | head -1 |awk -F'[><]' '{print $3}');
echo "Starting docker";
docker run --name sonarqube_${SONARQUBE_VERSION} -d -p 9000:9000 sonarqube:${SONARQUBE_VERSION};
echo "Inject plugin";
docker cp target/sonar-cnes-report-${version}.jar sonarqube_${SONARQUBE_VERSION}:/opt/sonarqube/extensions/plugins/;
docker exec -u root sonarqube_${SONARQUBE_VERSION} chown sonarqube:sonarqube /opt/sonarqube/extensions/plugins/sonar-cnes-report-${version}.jar;
docker restart sonarqube_${SONARQUBE_VERSION};
echo "Waiting up to 5 minutes for SonarQube...";
counter=0;
Expand All @@ -61,6 +60,7 @@ jobs:
counter=$(( $counter + 1 ));
status_sonar=$(curl -s "http://localhost:9000/api/system/status" | grep "\"status\":\"UP\"" > /dev/null; echo $?);
done;
echo "SonarQube is $([[ 0 -eq $status_sonar ]] && echo "up" || echo "down"), after $counter tries";
mvn sonar:sonar -Dsonar.host.url=http://localhost:9000 -Dsonar.login=admin -Dsonar.password=admin -Dsonar.organization=default-organization;
echo "Waiting for the SonarQube Compute Engine task to be completed...";
ce=$(grep ceTaskUrl= target/sonar/report-task.txt);
Expand All @@ -84,7 +84,7 @@ jobs:
curl -u admin:admin ${url_cnesreport} -O -J;

code-analysis:
runs-on: ubuntu-latest
runs-on: ubuntu-22.04
name: SonarCloud Code Analysis
# It's not possible to launch an analysis on external pull requests
if: ${{ github.repository_owner == 'cnescatlab' }}
Expand Down
34 changes: 27 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,13 +116,15 @@ For legacy versions, check the wiki page here : [Note on legacy versions](https:
<table>
<tr>
<td><b>cnesreport <br>\<br> SonarQube</b></td>
<td><b>3.0.x<br/>Standalone + Plugin</td>
<td><b>3.1.0<br/>Standalone + Plugin</td>
<td><b>3.2.x<br/>Standalone + Plugin</td>
<td><b>3.3.x<br/>Standalone + Plugin</td>
<td><b>4.0.0<br/>Standalone + Plugin</td>
<td><b>4.1.x<br/>Standalone + Plugin</td>
<td><b>4.2.x<br/>Standalone + Plugin</td>
<td><b>3.0.x<br/>Standalone + Plugin</b></td>
<td><b>3.1.0<br/>Standalone + Plugin</b></td>
<td><b>3.2.x<br/>Standalone + Plugin</b></td>
<td><b>3.3.x<br/>Standalone + Plugin</b></td>
<td><b>4.0.0<br/>Standalone + Plugin</b></td>
<td><b>4.1.x<br/>Standalone + Plugin</b></td>
<td><b>4.2.x<br/>Standalone + Plugin</b></td>
<td><b>4.3.x<br/>Standalone + Plugin</b></td>
<td><b>5.0.x<br/>Standalone + Plugin</b></td>
</tr>
<tr>
<td><b>7.9.x</b></td>
Expand All @@ -133,6 +135,8 @@ For legacy versions, check the wiki page here : [Note on legacy versions](https:
<td>-</td>
<td>-</td>
<td>-</td>
<td>-</td>
<td>-</td>
</tr>
<tr>
<td><b>8.9.x</b></td>
Expand All @@ -143,6 +147,8 @@ For legacy versions, check the wiki page here : [Note on legacy versions](https:
<td>X</td>
<td>X</td>
<td>-</td>
<td>-</td>
<td>-</td>
</tr>
<tr>
<td><b>9.9.x (LTS)</b></td>
Expand All @@ -153,7 +159,21 @@ For legacy versions, check the wiki page here : [Note on legacy versions](https:
<td>-</td>
<td>-</td>
<td>X</td>
<td>X</td>
<td>-</td>
</tr>
<tr>
<td><b>10.5.x</b></td>
<td>-</td>
<td>-</td>
<td>-</td>
<td>-</td>
<td>-</td>
<td>-</td>
<td>-</td>
<td>-</td>
<td>X</td>
</tr>
</table>

### How to contribute
Expand Down
69 changes: 24 additions & 45 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,45 +1,24 @@
{
"name": "sonar-cnes-report-plugin",
"license": "GPL-3.0",
"version": "4.2.0",
"devDependencies": {
"@babel/core": "^7.8.7",
"@babel/plugin-proposal-class-properties": "^7.8.3",
"@babel/preset-env": "^7.8.7",
"@babel/preset-react": "^7.8.3",
"@emotion/core": "^10.0.17",
"@emotion/styled": "^10.0.17",
"autoprefixer": "9.7.4",
"babel-core": "6.14.0",
"babel-jest": "^25.1.0",
"babel-loader": "^8.0.6",
"babel-preset-react-app": "0.2.1",
"css-loader": "^3.4.2",
"emotion-theming": "^10.0.19",
"lodash": "4.17.21",
"postcss-calc": "7.0.2",
"postcss-custom-properties": "9.1.1",
"postcss-loader": "3.0.0",
"react": "16.13.0",
"react-dev-utils": "^11.0.4",
"react-dom": "16.13.0",
"react-router": "3.2.6",
"sonar-ui-common": "1.0.33",
"style-loader": "1.1.3",
"uglifyjs-webpack-plugin": "^2.2.0",
"webpack": "^4.42.0"
},
"scripts": {
"build": "node src/main/js/scripts/build.js"
},
"babel": {
"presets": [
"@babel/env",
"@babel/react"
],
"plugins": [
"@babel/plugin-proposal-class-properties"
]
},
"dependencies": {}
}
{
"name": "sonar-cnes-report",
"license": "GPL-3.0",
"version": "5.0.0",
"scripts": {
"build": "node scripts/build.js"
},
"babel": {
"presets": [
"react-app"
]
},
"dependencies": {
"@babel/core": "7.24.6",
"babel-loader": "9.1.3",
"babel-preset-react-app": "10.0.1",
"css-loader": "7.1.2",
"style-loader": "4.0.0",
"webpack": "5.91.0"
},
"devDependencies": {
"@babel/plugin-proposal-private-property-in-object": "7.21.11"
}
}
Loading
Loading