I want to use a web deploy to publish my ASP.Net Web API project along with Angular app. Angular app build is running in pre-build action, I'm using CustommCollectFiles to include \dist folder in publish, but because it's not waiting for finishing it the dist folder content can be outdated. How to wait until pre-build action finish and only after that copy dist folder?
Solution was using msbuild task in publish profile config (*.pubxml)
I found solution in this answer