Building NuGet package refactored