问题
I'm building an application that needs to be able to, on a command, publish itself to a specified directory.
I'm looking for something like
System.BuildSystem.Build(<project file>, 'release');
System.BuildSystem.Publish(<project file>, <destination folder>);
Is this possible?
回答1:
Take a look at msbuild or nant. Personally, I use msbuild to push releases to our QA environment and create packages to be rolled out to production.
Your application could, for example, call batch files that run msbuild scripts to produce and publish builds.
来源:https://stackoverflow.com/questions/4961074/build-and-publish-net-web-app-programmatically