【问题标题】:Diagnosing Sonarqube with Roslyn analyzers使用 Roslyn 分析仪诊断 Sonarqube
【发布时间】:2016-02-03 00:20:37
【问题描述】:

我正在为我的团队设置 Sonarqube,但在使用 the Sonarqube Roslyn SDK found on github 时遇到了问题。

按照github页面上的说明,我已经成功编译了解决方案。但是,在 [directory]/Sonarqube.Plugins.Roslyn.PluginGenerator.exe 运行生成器工具时,尝试按照 Microsoft.CodeAnalysis.Analyzers 的说明创建插件时出现以下错误:

c:\users\[HomeDirectory]\src\github\sonarqube-roslyn-sdk\RoslynPluginGenerator\bin\Debug\sonarqube.plugins.roslyn.plugingenerator.exe /a:c:\users\[HomeDirectory]\src\github\sonarqube-roslyn-sdk\RoslynPluginGenerator\bin\Debug\Microsoft.CodeAnalysis.Analyzers:1.0.0
Roslyn Analyzer Plugin Generator for SonarQube 0.1.0.0
    [DEBUG] Parsed NuGet reference. Id: c:\users\[HomeDirectory]\src\github\sonarqube-roslyn-sdk\RoslynPluginGenerator\bin\Debug\Microsoft.CodeAnalysis.Analyzers, version: 1.0.0
    [DEBUG] Fetching NuGet config files...
    [DEBUG] Enabled package sources:
    [WARNING] No enabled package sources. Please update the NuGet config to specify at least one valid package source.
    Attempting to locate package with id 'c:\users\[HomeDirectory]\src\github\sonarqube-roslyn-sdk\RoslynPluginGenerator\bin\Debug\Microsoft.CodeAnalysis.Analyzers'
    [DEBUG] Number of packages located: 0
    No packages with the specified id were found:
    c:\users\[HomeDirectory]\src\github\sonarqube-roslyn-sdk\RoslynPluginGenerator\bin\Debug\Microsoft.CodeAnalysis.Analyzers

在机器上启用了正确的 (v3) 包源的情况下,我在 Visual Studio 中的 NuGet 没有其他问题。我知道 Sonarqube Roslyn SDK 目前是一个测试版,但我想知道是否有人真的成功地从一个引用的 NuGet 库创建了一个插件。

附带说明一下,Sonarqube 运行良好,只是我无法将基于分析器的静态分析问题导入 Sonarqube。此问题特定于 SDK。任何见解将不胜感激。

【问题讨论】:

    标签: c# visual-studio-2015 roslyn sonarqube5.3


    【解决方案1】:

    在发布原始问题后,此问题已通过 Roslyn SDK 得到修复。只需按照 SDK 的 github 页面上提供的说明进行操作即可。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2014-12-24
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多