Skip to content

BUILD-8939 sonar project version#69

Merged
julien-carsique-sonarsource merged 1 commit intomasterfrom
fix/jcarsique/BUILD-8939-sonarProjectVersion
Sep 2, 2025
Merged

BUILD-8939 sonar project version#69
julien-carsique-sonarsource merged 1 commit intomasterfrom
fix/jcarsique/BUILD-8939-sonarProjectVersion

Conversation

@julien-carsique-sonarsource
Copy link
Copy Markdown
Contributor

@julien-carsique-sonarsource julien-carsique-sonarsource commented Aug 27, 2025

BUILD-8939 use CURRENT_VERSION instead of PROJECT_VERSION for sonar.projectVersion parameter.

The Sonar project version must remain unchanged between master and PRs for comparison purpose.
CURRENT_VERSION is the version configured in the project, with no change, fix or cleanup (like -SNAPSHOT).
PROJECT_VERSION is the sanitized version, and appended with the build number for most cases (equivalent to the release version). There are a few cases for which the version is kept unchanged, equal to CURRENT_VERSION.

Sonar parameter updated in build-gradle, build-maven, build-npm, build-poetry, and build-yarn.
For consistency, all set_project_version() functions now export CURRENT_VERSION and PROJECT_VERSION.

Tested by:

@julien-carsique-sonarsource julien-carsique-sonarsource force-pushed the fix/jcarsique/BUILD-8939-sonarProjectVersion branch 2 times, most recently from be09f43 to 23aff77 Compare August 27, 2025 16:48
@julien-carsique-sonarsource julien-carsique-sonarsource marked this pull request as ready for review August 29, 2025 14:26
@julien-carsique-sonarsource julien-carsique-sonarsource requested a review from a team August 29, 2025 14:26
@julien-carsique-sonarsource julien-carsique-sonarsource force-pushed the fix/jcarsique/BUILD-8939-sonarProjectVersion branch from 3d7042c to 0cda5b9 Compare August 29, 2025 14:26
@julien-carsique-sonarsource julien-carsique-sonarsource marked this pull request as draft August 29, 2025 14:26
@julien-carsique-sonarsource julien-carsique-sonarsource force-pushed the fix/jcarsique/BUILD-8939-sonarProjectVersion branch from 0cda5b9 to 298d7a0 Compare August 29, 2025 15:39
@julien-carsique-sonarsource julien-carsique-sonarsource marked this pull request as ready for review August 29, 2025 15:39
Comment thread build-poetry/build.sh Outdated
Comment thread shared/common-functions.sh Outdated
Reviewed-by: matemoln
@julien-carsique-sonarsource julien-carsique-sonarsource force-pushed the fix/jcarsique/BUILD-8939-sonarProjectVersion branch from 298d7a0 to 17544c2 Compare September 2, 2025 09:03
@julien-carsique-sonarsource julien-carsique-sonarsource merged commit a5d13e5 into master Sep 2, 2025
8 of 9 checks passed
@julien-carsique-sonarsource julien-carsique-sonarsource deleted the fix/jcarsique/BUILD-8939-sonarProjectVersion branch September 2, 2025 09:06
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud Bot commented Sep 2, 2025

🤖 Pull Request summary

Updates version handling and command logging across build scripts.

Version handling: Adds CURRENT_VERSION export to preserve original version, uses it for SonarQube analysis instead of modified PROJECT_VERSION
Command logging: Adds command echo statements before Maven, Gradle, Poetry, and NPM tool executions for better visibility
Test output fixes: Corrects expected test assertions to match new command logging and GitHub Actions grouping
Poetry action fix: Changes output reference from env var to step output for consistency
Maven summary: Adds build number to workflow summary output

Focus areas for review:

  • Verify the version variable separation logic doesn't break existing workflows
  • Check that the new command logging doesn't expose sensitive information
  • Confirm Maven maintenance branch version handling changes are correct

💬 Please send your feedback

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarQube Cloud

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants