build and publish .net Web App programmatically

3.4k Views Asked by At

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

There are 1 best solutions below

3
On BEST ANSWER

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.