Skip to content

Commit

Permalink
fix: provide full path to executable
Browse files Browse the repository at this point in the history
resolves #98
  • Loading branch information
JanDeDobbeleer committed Oct 25, 2020
1 parent 90f367e commit 6deeb55
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/powershell/oh-my-posh/oh-my-posh.psm1
Expand Up @@ -51,14 +51,14 @@ function Set-PoshPrompt {
$startInfo = New-Object System.Diagnostics.ProcessStartInfo
$startInfo.FileName = Get-PoshCommand
$config = $global:PoshSettings.Theme
$startInfo.Arguments = "-config $config -pwd $PWD -error $realLASTEXITCODE"
$startInfo.Arguments = "-config $config -pwd ""$PWD"" -error $realLASTEXITCODE"
$startInfo.Environment["TERM"] = "xterm-256color"
$startInfo.CreateNoWindow = $true
$startInfo.StandardOutputEncoding = [System.Text.Encoding]::UTF8
$startInfo.RedirectStandardOutput = $true
$startInfo.UseShellExecute = $false
if ($PWD.Provider.Name -eq "FileSystem") {
$startInfo.WorkingDirectory = $PWD
$startInfo.WorkingDirectory = "$PWD"
}
$process = New-Object System.Diagnostics.Process
$process.StartInfo = $startInfo
Expand Down

0 comments on commit 6deeb55

Please sign in to comment.