Fix running 'pwsh' produced from 'dotnet build' (#6549)

This commit is contained in:
Dongbo Wang
2018-04-03 12:06:14 -07:00
committed by GitHub
parent 24cf020442
commit ceac82abc5
2 changed files with 2 additions and 2 deletions
@@ -1612,6 +1612,7 @@ namespace Microsoft.PowerShell
OpenConsoleRunspace(consoleRunspace, staMode);
}
Runspace.PrimaryRunspace = consoleRunspace;
_runspaceRef = new RunspaceRef(consoleRunspace);
if (psReadlineFailed)
@@ -1656,10 +1657,8 @@ namespace Microsoft.PowerShell
#endif
runspace.ThreadOptions = PSThreadOptions.ReuseThread;
runspace.EngineActivityId = EtwActivity.GetActivityId();
Runspace.PrimaryRunspace = runspace;
s_runspaceInitTracer.WriteLine("Calling Runspace.Open");
runspace.Open();
}
@@ -12,6 +12,7 @@
<Compile Include="..\powershell\Program.cs" Exclude="bin\**;obj\**;**\*.xproj;packages\**" />
<Content Include="..\System.Management.Automation\powershell.config.json">
<Link>powershell.config.json</Link>
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
<CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory>
</Content>
<Content Include="..\Modules\Windows-Core\**\*;..\Modules\Windows-Core+Full\**\*;..\Modules\Shared\**\*">