JetBrains / TeamCity.SonarQubePlugin

A plugin for TeamCity server allowing you to configure and run SonarQube analysis from the CI
Apache License 2.0
53 stars 32 forks source link

Change special characters for project key #27

Closed renzors closed 8 years ago

renzors commented 8 years ago

Before that run the analyse process, I need to change some special characters for project key. How can I do that?

Linfar commented 8 years ago

@renzors Can you be more specific?

renzors commented 8 years ago

Sure. I am using four tools: Stash, TeamCity, Sonar for Stash and SonarQube.

When I make a change on stash, that run a build process in teamcity and in my process I set the project key, in my case is the same name of branch on stash. It must be the branch name because in a second time I use sonar for stash to analyze the pull request issues, but this tool search a project key in sonarqube named as the branch.

All is fine, except when the branch name have a special characters as # for example. So, currently I get the branch name through of a parameter, but I'd like will can replace the characters as part of configuration. I think that it is a reason because in sonar for stash exist a field for replace special characters, i suppose because it is recurrent.

Linfar commented 8 years ago

@renzors Ok, now I got it. There is no such functionality in TeamCity. As a workaround you can modify this parameter in a separate build step before Sonar analysis (refer to service message documentation). On the other hand this looks like it should be done inside TeamCity SonarQube plugin. I'll try to fix it tomorrow.

renzors commented 8 years ago

Nice @Linfar I will be expectant :-)

Linfar commented 8 years ago

@renzors You can update the plugin from CI

renzors commented 8 years ago

@Linfar Thanks a lot :-)