I am considering running MSBuild from a Powershell script by tapping directly to the MSBuild assemblies (as opposed to looking up MSBuild install path and starting msbuild.e
Once upon a time I've been playing with running augmented MSBuild build processes (like, skip some parts of the build more aggressively).
There were two choices:
I've implemented both and had to abandon #1 because it wasn't flexible enough.
For instance, MSBuild has a load of assembly binding redirections in its .config file.
The Visual Studio process (devenv.exe) which also hosts MSBuild with its API ends up copypasting these into its devenv.exe.config. Mine .exe.config had also to have these, but it adheres you to a specific MSBuild version. And, of course, you have to modify the config. Which is not an option with PS actually, so I doubt if you could get a really stable solution.