title: How do I integrate exe publishing with the VS2019 build of the console .net core 2.2 application?
body: <p>I saw a couple of similar questions but so far I found no single answer to the problem of integrating the publishing step with my build process. Unfortunately the dotnet publish command rebuilds the project again meaning that if I put the "dotnet publish" command in the project's Post-Build steps I get an infinite loop of building retries.</p>
  
  <p>What I want to achieve is to get an exe built for my .NET Core 2.2 Console App for a few selected environments eg. osx and windows-10, possibly linux too, each in its own folder. Obvious condition is that it has to be integrated with the build, so no extra manuals steps (commands) are required. This has to work from within VS2019 Pro as well in CI (like AzureDevOps).</p>
  
  <p>Is this basic step achievable or .Net core was a major step-back in the progress of software development?
  I hope I just miss something and I am just grossly exaggerating. :)</p>
  
  <p>Thanks, Radek</p>