Not sure if this is an issue with posh-git or oh-my-posh but version 1.0.0.-beta1 breaks compatibility with oh-my-posh whereby the prompt disappears and it can even hang. I know that 1.x contains breaking changes but this change was maybe not intended since 0.7.2-pre1 integrates without problems with oh-my-posh
I'm not surprised, as posh-git v1 changes quite a bit of our internals. We're trying pretty hard to keep v0 backwards-compatible.
cc @JanJoris
Do you see anything in $Errors or posh-git's captured $invokeErrors?
I was trying to reproduce this on my current dev machine but PSCore doesn't seem to like v1 yet. I'll run a Windows dev setup asap to check what's going on.
If you are on PSCore, make sure you are running PSReadLine 2.0.0-beta1.
Also, the way Write-GitStatus, Write-VcsStatus and Write-Prompt work is fundamentally different on a system that support ANSI esc seqs and has the property $GitPromptSettings.AnsiConsole set to $true. @bergmeister if you set the above setting to $false, does posh-git / oh-my-posh behave any better?
@JanJoris The Write functions will not write anything if the host supports ANSI, they will instead return a string that contains ANSI esc sequences around text. If the system doesn't support ANSI (or the user has disable ANSI support with the setting above), then the Write commands will write to host as before. Here is the pattern we recommend:
$prompt = Write-Prompt "Text before posh-git prompt" -ForegroundColor Orange
$prompt += & $GitPromptScriptBlock
$prompt += Write-Prompt "Text after posh-git prompt" -ForegroundColor ([ConsoleColor]::Magenta)
if ($prompt) { $prompt } else { " " } # prevent PowerShell from adding 'PS>'
In the ANSI not available (or disabled) case, $prompt will contain an empty string.
@rkeithhill Thanks for the tip. Yes, setting $GitPromptSettings.AnsiConsole = $false does the trick. :-)
I was able to make the changes and everything works on PSCore. However, I still have to validate if this doesn't break the non-core version of PS. Pretty awesome though, no changes were needed to the logic in my scripts other than a few minor tweaks and @rkeithhill 's pointer towards Write-Prompt

@JanDeDobbeleer Were you ever able to verify that the updated oh-my-posh works correctly on Windows PowerShell? If so, I'd like to close this issue. If not, I'd like to know if there is anything we need to do in posh-git to accommodate you.
Please close the issue as everything seems to be working like a charm.
Excellent!
Thanks, I can confirm this works now well with the latest version 2.0.0-beta1 of PSReadline and 1.0.0-beta1 of posh-git (and 2.0.193 of oh-my-posh) on Windows 10 1803 using ConEmu 161206 [64] {Stable}
Most helpful comment
Thanks, I can confirm this works now well with the latest version
2.0.0-beta1ofPSReadlineand1.0.0-beta1ofposh-git(and2.0.193ofoh-my-posh) on Windows 10 1803 usingConEmu 161206 [64] {Stable}