How to add to 'NuGet Packages' report tab?

TeamCity (very nicely) generates a report tab named 'NuGet Packages' when you use any of the built-in NuGet runners to Install/Pack/Publish packages.  Is it possible to populate this report when not using the built-in NuGet runners?  For example: via NuGet.exe command line runner?

The built-in NuGet Installer runner requires a path to a Visual Studio solution file; however, NuGet.exe itself has no such requirement.  We often install NuGet packages that have no correlation to Visual Studio projects, so we can't use the built-in NuGet Installer runner.  We had to create our own Meta Runner that basically wraps NuGet.exe.  Unfortunately, none of the packages installed with our custom Meta Runner appear on the NuGet Packages report tab.  

As a workaround, we've been generating our own nuget.xml file and publishing this as an artifact (.teamcity/nuget/nuget.xml) which will correctly show packages installed via our custom Meta Runner on the report tab; however, this clobbers TeamCity's built-in mechanism and overwrites the internally-published nuget.xml.  I was wondering if we could somehow make these "additive" rather than "exclusive."

Thanks,
Bryan

2 comments
Comment actions Permalink

Hello Bryan,

.teamcity/nuget/nuget.xml is written and published as artifact on build finish event. There is no extension point available to re-write its content. As workaround you can publish a separate artifact and display it in a custom report tab.

We have the related request https://youtrack.jetbrains.com/issue/TW-33820 which closely relates to your initial problem, please vote for it.

0
Comment actions Permalink

I have also come across this requirement. I have moved away from TeamCity from being the fount of all knowledge in terms the build opting to use build scripts in source control instead. However the power of the reporting tabs is really useful. If we where to push a `nuget.xml` artifact to `.teamcity/nuget.xml` during the build process would this get the same result?

0

Please sign in to leave a comment.