Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #PSReadline theme to match VSCode editor colors
- if ($env:TERM_PROGRAM -eq 'VSCode' -or $env:WT_SESSION) {
- if ($psedition -eq 'core') {
- $ansiesc = "`e"
- } else {
- $ansiesc = [char]0x1b
- }
- Set-PSReadlineOption -Colors @{
- Command = "$($ansiesc)[93m"
- Comment = "$($ansiesc)[32m"
- ContinuationPrompt = "$($ansiesc)[37m"
- Default = "$($ansiesc)[37m"
- Emphasis = "$($ansiesc)[96m"
- Error = "$($ansiesc)[31m"
- Keyword = "$($ansiesc)[35m"
- Member = "$($ansiesc)[96m"
- Number = "$($ansiesc)[35m"
- Operator = "$($ansiesc)[37m"
- Parameter = "$($ansiesc)[37m"
- Selection = "$($ansiesc)[37;46m"
- String = "$($ansiesc)[33m"
- Type = "$($ansiesc)[34m"
- Variable = "$($ansiesc)[96m"
- }
- #Verbose Text should be distinguishable, some hosts set this to yellow
- $host.PrivateData.ErrorForegroundColor = 'Red'
- $host.PrivateData.VerboseForegroundColor = 'Cyan'
- $host.PrivateData.WarningForegroundColor = 'Yellow'
- $host.PrivateData.DebugForegroundColor = 'Magenta'
- $host.PrivateData.ProgressForegroundColor = 'Yellow'
- $host.PrivateData.ProgressBackgroundColor = 'DarkCyan'
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement