MSBUILD APIを使用して、サービスを使用してソリューションを構築しています。
例えば
var pc = new ProjectCollection();
var buildProperties = new Dictionary<string, string>
{
{"Configuration", "Release"},
{"Platform", "Any CPU"},
{"OutputPath", _outputPath}
};
var buildParameters = new BuildParameters(pc);
var buildRequest = new BuildRequestData(_buildFile, buildProperties, null, new[] { "Clean", "Rebuild" }, null);
var buildResult = BuildManager.DefaultBuildManager.Build(buildParameters, buildRequest);
私ができるようにしたいのは、除外されたプロジェクトタイプまたは拡張機能のリストを渡すことです。まず、除外したいのは次のとおりです。
- データベースプロジェクト
- WinRTプロジェクト
- 一般的なMSBUILDファイル(プロジェクトタイプGUIDなし)。
いくつかのパラメーターをMSBUILDマネージャーに渡すことでこれを解決する方法はありますか?