Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to prevent team city from cleaning up nuget artifacts

Tags:

nuget

teamcity

We're using team city as a nuget server and the artifact cleaning is removing old nuget packages. Unfortunately some of our packages aren't built that often, and when they get cleaned up other builds break.

I've tried changing the clean up rules to exclude *.nupkg, but this doesn't seem to be working.

Any ideas?

like image 945
jonnii Avatar asked Nov 13 '12 23:11

jonnii


2 Answers

I don't know about the version of TC you were using when this was posted, but in version 7 and up there is a place to set rules for clean ups.

By setting -:*.nupkg you can exclude NuGet packages from the cleanup process.

like image 176
Logarr Avatar answered Nov 13 '22 02:11

Logarr


In TeamCity's Build History Clean-up options, near the bottom you'll find a Dependencies category with an option to prevent cleanup of builds that other build configurations depend on. I think that will solve your problem.

like image 1
KevinF Avatar answered Nov 13 '22 04:11

KevinF