2015-06-01 125 views
0

我有一个TeamCity项目,它构建了一个C#.NET解决方案并构建了一个NuGet包以供部署。其中一个步骤然后将NuGet包发布到Octopus Deploy库存储库。出于某种原因,我的TeamCity项目将NuGet包推送到Octopus库存储库18次。我已经扩大了第一步,以显示细节。TeamCity多次发布NuGet包

[13:52:56]Step 3/5: Publish Nuget Package (NuGet Publish) (3m:24s) 
[13:52:56][Step 3/5] push: Publish package MyWebProject\bin\MyWebProject.2.19.5627.20520.nupkg (13s) 
[13:52:56][push] NuGet command: C:\TeamCity\buildAgent\plugins\nuget-agent\bin\JetBrains.TeamCity.NuGetRunner.exe C:\TeamCity\buildAgent\tools\NuGet.CommandLine.DEFAULT.nupkg\tools\NuGet.exe push C:\DEVONLINE\IRM\Main\MyWebProject\MyWebProject\bin\MyWebProject.2.19.5627.20520.nupkg %%teamcity_nuget_api_key_1433181176848%% -Source http://localhost:8024/nuget/packages 
[13:52:56][push] Starting: C:\TeamCity\buildAgent\temp\agentTmp\custom_script3530589901220837023.cmd 
[13:52:56][push] in directory: C:\DEVONLINE\Main\MyWebProject\bin 
[13:52:56][push] JetBrains TeamCity NuGet Runner 8.0.32060.9 
[13:52:56][push] Registered additional extensions from paths: C:\TeamCity\buildAgent\plugins\nuget-agent\bin\plugins-2.8 
[13:52:56][push] Starting NuGet.exe 2.8.50926.602 from C:\TeamCity\buildAgent\tools\NuGet.CommandLine.DEFAULT.nupkg\tools\NuGet.exe 
[13:52:57][push] Pushing MyWebProject 2.19.5627.20520 to 'http://localhost:8024/nuget/packages'... 
[13:53:10][push] Your package was pushed. 
[13:53:10][push] Process exited with code 0 
[13:53:10][Step 3/5] push: Publish package MyWebProject\bin\MyWebProject.2.19.5627.21133.nupkg (12s) 
[13:53:23][Step 3/5] push: Publish package MyWebProject\bin\MyWebProject.2.19.5627.21281.nupkg (5s) 
[13:53:28][Step 3/5] push: Publish package MyWebProject\bin\MyWebProject.2.19.5627.21680.nupkg (14s) 
[13:53:42][Step 3/5] push: Publish package MyWebProject\bin\MyWebProject.2.19.5627.21777.nupkg (12s) 
[13:53:55][Step 3/5] push: Publish package MyWebProject\bin\MyWebProject.2.19.5627.23661.nupkg (6s) 
[13:54:02][Step 3/5] push: Publish package MyWebProject\bin\MyWebProject.2.19.5627.23808.nupkg (12s) 
[13:54:14][Step 3/5] push: Publish package MyWebProject\bin\MyWebProject.2.19.5627.24431.nupkg (13s) 
[13:54:28][Step 3/5] push: Publish package MyWebProject\bin\MyWebProject.2.19.5627.25366.nupkg (6s) 
[13:54:34][Step 3/5] push: Publish package MyWebProject\bin\MyWebProject.2.19.5627.25732.nupkg (15s) 
[13:54:49][Step 3/5] push: Publish package MyWebProject\bin\MyWebProject.2.19.5627.26132.nupkg (13s) 
[13:55:02][Step 3/5] push: Publish package MyWebProject\bin\MyWebProject.2.19.5627.26469.nupkg (6s) 
[13:55:09][Step 3/5] push: Publish package MyWebProject\bin\MyWebProject.2.19.5627.26890.nupkg (13s) 
[13:55:23][Step 3/5] push: Publish package MyWebProject\bin\MyWebProject.2.19.5630.18299.nupkg (7s) 
[13:55:30][Step 3/5] push: Publish package MyWebProject\bin\MyWebProject.2.19.5630.18837.nupkg (8s) 
[13:55:39][Step 3/5] push: Publish package MyWebProject\bin\MyWebProject.2.19.5630.20862.nupkg (17s) 
[13:55:56][Step 3/5] push: Publish package MyWebProject\bin\MyWebProject.2.19.5630.22872.nupkg (7s) 
[13:56:03][Step 3/5] push: Publish package MyWebProject\bin\MyWebProject.2.19.5630.23126.nupkg (17s) 

我的SLn包含总共14个项目。导致NuGet软件包被多次推入八达通图书馆的原因是什么?

+1

该文件夹是否包含nuget包的旧副本? –

+0

是的 - 这是问题所在。谢谢 – ihatemash

+0

如果您将此帖作为答案发布,我会接受。 – ihatemash

回答

3

您发布的日志文件中包含您需要的信息,这里是更新后的版本,其中包含一些噪音......将您的目光投向标有星号的列中的包名称。

---------------------*****------------ 
[13:53:10] 2.19.5627.21133.nupkg (12s) 
[13:53:23] 2.19.5627.21281.nupkg (5s) 
[13:53:28] 2.19.5627.21680.nupkg (14s) 
[13:53:42] 2.19.5627.21777.nupkg (12s) 
[13:53:55] 2.19.5627.23661.nupkg (6s) 
[13:54:02] 2.19.5627.23808.nupkg (12s) 
[13:54:14] 2.19.5627.24431.nupkg (13s) 
[13:54:28] 2.19.5627.25366.nupkg (6s) 
[13:54:34] 2.19.5627.25732.nupkg (15s) 
[13:54:49] 2.19.5627.26132.nupkg (13s) 
[13:55:02] 2.19.5627.26469.nupkg (6s) 
[13:55:09] 2.19.5627.26890.nupkg (13s) 
[13:55:23] 2.19.5630.18299.nupkg (7s) 
[13:55:30] 2.19.5630.18837.nupkg (8s) 
[13:55:39] 2.19.5630.20862.nupkg (17s) 
[13:55:56] 2.19.5630.22872.nupkg (7s) 
[13:56:03] 2.19.5630.23126.nupkg (17s) 

您可能能够解决使用Team City's clean checkout option每次源被取出删除旧版本这个问题。