public void ConstructProductVersionWhenProductVersionHasOnly3Fields() { Assert.AreEqual( "1.2.3", PublishNuGetPackageTask.ConstructProductVersionStringUsedForNupkg( new Version("1.2.3"))); }
public void ConstructProductVersionWhenProductVersionRevisionIs0() { Assert.AreEqual( "1.2.3", PublishNuGetPackageTask.ConstructProductVersionStringUsedForNupkg( new Version("1.2.3.0"))); }
private static void TargetNuGet(ITaskContext context, string nugetId) { PublishNuGetPackageTask publishTask = new PublishNuGetPackageTask(nugetId, @"Flubu\Flubu.nuspec"); publishTask.ForApiKeyUseEnvironmentVariable(); publishTask.Execute(context); }
private static void TargetNuGet(ITaskContext context, string projectName) { string nuspecFileName = Path.Combine(projectName, projectName) + ".nuspec"; PublishNuGetPackageTask publishTask = new PublishNuGetPackageTask( projectName, nuspecFileName); publishTask.BasePath = Path.GetFullPath(projectName); publishTask.ForApiKeyUseEnvironmentVariable(); publishTask.Execute(context); }