Template for a good new topic, formatted with Markdown:
ALM used Azure DevOps
CI system: Azure DevOps
Languages of the repository: Net Core 3.1.8 , C#, Json , Yaml
Hi everyone,
Our organization uses sonar cloud paid plan for static code analysis. We setup sonar integration using Azure Devops for REST API project but I don’t see the language showed in the project after creation. Can someone help me out with this? Is there any configuration which needs to be setup in sonar cloud for projects to detect the language which is being used and show in the sonar UI.
It is just showing me yaml not the .net language which was used to build the project
NOTE: This is the same case/problem with all the projects which we have with other languages (i.e for android/web/etc). Also I am not using any exclude properties here but it skipped all the source code lines here
You should make sure you’re using the Scanner for .NET, following the documentation here or in the tutorial available in the SonarCloud UI when creating a project (or visiting the project-level Administration > Analysis Method)
Attached latest log I have tried to use cmd to install dotnet-sonarscanner.
We used the same manual config mode for other languages like web/android. The projects are able to detect languages after creation only for .net we are unable to get that.
Is there any example available with standalone scanner/manual for .net? Else please guide me what needs to be added in Azure DevOps pipeline as a task.
I have tried even with Integrate with MSBuild option its not working. I have created a test project where it states the project is empty. Here the main branch is dev I renamed and ran but no luck.
NOTE: We are using standalone scanner/manual option for all the repos and every other repo is working fine and able to detect the language except .net which is stated in above scenario.
With manual/standalone scanner it worked earlier but not sure why it is not working now. Is there any working example available for standalone scanner?
Attached build logs for more info: logs_16150.zip (240.6 KB)
Scanner mode: Integrate with msbuild (Tried with the other scanner mode as suggested above)
branch: dev (dev is our main/master branch here so renamed the branch as dev in sonar ui at project level and did analysis)
FYI we used standalone scanner mode in past for .net projects and it worked as expected.