Closed WizX20 closed 3 years ago
function Test-IsVanillaWindow { if($env:PROMPT -or $env:ConEmuANSI) { # Console return $false } elseif ($env:TERM_PROGRAM -eq "Hyper") { # Hyper.is return $false } elseif ($env:TERM_PROGRAM -eq "vscode") { # Visual Studio Code return $false } else { # Powershell return $true } } $v = Test-IsVanillaWindow Write-Output $v Import-Module PSReadLine Set-PSReadlineOption -BellStyle None Set-PSReadLineKeyHandler -Key UpArrow -Function HistorySearchBackward Set-PSReadLineKeyHandler -Key DownArrow -Function HistorySearchForward Write-Output 'Loading Choco Profile' $ChocolateyProfile = "$env:ChocolateyInstall\helpers\chocolateyProfile.psm1" if (Test-Path($ChocolateyProfile)) { Import-Module "$ChocolateyProfile" } Write-Output 'Loading Posh Modules' Import-Module posh-git Import-Module oh-my-posh Write-Output 'Setting Theme' #$ThemeSettings.GitSymbols.BranchSymbol = [char]::ConvertFromUtf32(0xE0A0) #Set Theme Paradox Set-Theme Operator
V3 changed the cmdlet names to no longer conflict with others. Have a look here for more context.