docs: update website/docs/installation/prompt.mdx

This commit is contained in:
Cody Scavenger 2022-06-15 22:57:35 -04:00 committed by Jan De Dobbeleer
parent d8b979ec3b
commit d83af96d7a

View file

@ -48,6 +48,17 @@ Then add the following line.
```powershell
oh-my-posh init pwsh | Invoke-Expression
```
:::warning Antivirus software
If adding an exception to your Antivirus software still blocks Oh My Posh for Windows, you can try using the below
alternate line in your PowerShell profile. This is a drop-in replacement to the above call with Invoke-Expression.
Tested with PowerShell 7.2.4 with Bitdefender Antivirus installed and requires NO exceptions for oh-my-posh.exe.
Bitdefender blocks the calls to Invoke-Expression as malicious code and this alternate line skips the double calls:
```powershell
& ([ScriptBlock]::Create((oh-my-posh init pwsh --config "$env:POSH_THEMES_PATH\jandedobbeleer.omp.json" --print) -join "`n"))
```
:::
Once added, reload your profile for the changes to take effect.