Teamcity creating too many nuget packages

I'm trying to get Teamcity to create and publish one nuget package at the end of my build. The trouble is that even when I specify a specific .nuspec file under "Specification files" nuget, in addition to creating my specified package, will also create packages for each directory in the root directory of my checked out repo.
The root directory of my repo looks like this -
root dir
so nuget pack ends up creating two extraneous packages - "src" and "upgradeScripts" that contain all files within the respective directories.

Here's my nuget pack configuration -
nuget pack config

Here's my .nuspec -

<?xml version="1.0"?>
<package >
    <title>Blah Site</title>
    <authors>Blah LLC</authors>
    <description>Blah Blah</description>
    <releaseNotes>First release!</releaseNotes>
    <copyright>Copyright 2015</copyright>
    <file src="..\..\Deployable\nop_2.50\**\*.*" target="" />

It's not a deal breaker but the src directory is rather large and it takes up a lot of unnecessary space in addition to making the publish step in teamcity take 10+ mins. Any ideas? Thanks!

Comment actions Permalink

Hi Nick,

Please try to set Base Directory parameter to "Use project/.nuspec directory".

Comment actions Permalink

Hi Alina,

I tried that but it's still outputting the extra packages.

If it helps I recently updated my Teamcity version to v9 but that didn't help either.



Comment actions Permalink

Hi Alina,

I have same issue. I also tried all the things. Please give us resolution regarding this.



Comment actions Permalink

Hello Shyam,

What TeamCity version do you use? Could you please describe your issue and setup in more details? Please attach screenshot of the build step settings.

Comment actions Permalink

Hi Alina,

Thank you for your reply.

I am using teamcity version 9.1.6 and 10.0.1.

Screen shot attached below:

While publishing package lots of packages are published see below snap shot:




Please sign in to leave a comment.