Positioning powershell.exe in Microsoft.PowerShell.ConsoleHost for consumption by Start-DevPowerShell

This commit is contained in:
Mike Richmond committed 2016-07-19 16:41:13 -07:00
1 parent 4e7f582d43
commit 8ab10c52a9
1 file changed
+8
+8
View File
@@ -247,6 +247,14 @@ cmd.exe /C cd /d "$location" "&" "$($vcVarsPath)\vcvarsall.bat" "$NativeHostArch
log " Executing command: $command"
Start-NativeExecution { Invoke-Expression -Command:$command }
}
# Copy the executable binary from the local build directory to the expected destination to enable Start-DevPowerShell to work
#
# TODO: This should be updated to handle per-architecture builds gracefully.
$srcPath = Join-Path (Join-Path (Join-Path (Get-Location) "bin") $msbuildConfiguration) "FullCLR/powershell.exe"
$dstPath = ($script:Options).Top
log " Copying $srcPath to $dstPath"
Copy-Item $srcPath $dstPath
} finally {
Pop-Location
}