提交 8db9c9fb 编写于 作者: R Ravi Chande

Add a script that installs Roslyn VSIXes

to the RoslynPerf hive.
上级 b01bb2b0
#load "test_util.csx"
var binaries = new RelativeDirectory().MyBinaries();
var vsixes = new[]
{
"Roslyn.VisualStudio.Setup.vsix",
"Roslyn.VisualStudio.Test.Setup.vsix",
"Microsoft.VisualStudio.VsInteractiveWindow.vsix",
"Roslyn.VisualStudio.InteractiveComponents.vsix",
"Roslyn.VisualStudio.Setup.Interactive.vsix",
"Roslyn.Compilers.Extension.vsix",
"Microsoft.VisualStudio.LanguageServices.Telemetry.vsix"
};
var installer = Path.Combine(binaries, "VSIXExpInstaller.exe");
foreach (var vsix in vsixes)
{
ShellOutVital(installer, $"/rootSuffix:RoslynPerf {vsix}", binaries, System.Threading.CancellationToken.None);
}
......@@ -61,6 +61,31 @@ class RelativeDirectory
}
}
public string MyBinaries()
{
// The exceptation is that scripts calling this are included
// in a project in the solution and have already been deployed
// to a binaries folder
// Debug?
var debug = "debug";
var debugIndex = _workingDir.IndexOf(debug, StringComparison.CurrentCultureIgnoreCase);
if (debugIndex != -1)
{
return _workingDir.Substring(0, debugIndex + debug.Length);
}
// Release?
var release = "release";
var releaseIndex = _workingDir.IndexOf(release, StringComparison.CurrentCultureIgnoreCase);
if (releaseIndex != -1)
{
return _workingDir.Substring(0, releaseIndex + release.Length);
}
throw new Exception("Couldn't find binaries. Are you running from the binaries directory?");
}
public string PerfDirectory => Path.Combine(RoslynDirectory, "src", "Test", "Perf");
public string BinDirectory => Path.Combine(RoslynDirectory, "Binaries");
......
......@@ -121,6 +121,9 @@
<Content Include="Perf\util\trace_manager_util.csx">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
<Content Include="Perf\util\InstallVsixes.csx">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
</ItemGroup>
<ItemGroup>
<Content Include="Perf\tests\helloworld\HelloWorld.cs">
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册