• Colored Windows PowerShell

    Home » Forums » AskWoody support » Windows » Windows 8.1 » Windows 8.1 – other » Colored Windows PowerShell

    Author
    Topic
    #2429604

    Hello,

    I installed the newest Windows(!) Powershell (not PowerShell) 5.1 for Windows 8.1 Pro.

    $PSVersionTable

    PSVersion 5.1.14409.1005
    PSEdition Desktop
    PSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}
    BuildVersion 10.0.14409.1005
    CLRVersion 4.0.30319.42000
    WSManStackVersion 3.0
    PSRemotingProtocolVersion 2.3
    SerializationVersion 1.1.0.1

    I would like to color my Windows PowerShell 5.1 like in Windows 10.

    How can I turn colors on?

    Cheers

    Viewing 1 reply thread
    Author
    Replies
    • #2429638

      This works for PowerShell and Command Prompt and I suspect it will work for your Powershell.

      Open the Powershell
      Right click the icon at the top left of the title bar
      Select Properties from the context menu.
      Select Colors tab and make your changes
      OK your changes to save.

      Let us know if if works for your version of Powershell.

      HTHG, Dana:))

      HTH, Dana:))

    • #2429688

      Searching,

      You can also do it via your Profile using PSReadline:

      Import-Module G:\BEKDocs\WindowsPowershell\Modules\PSReadline
      Set-PSReadlineOption -TokenKind Keyword   -ForegroundColor DarkBlue 
      Set-PSReadlineOption -TokenKind Variable  -ForegroundColor Red 
      Set-PSReadlineOption -TokenKind Operator  -ForegroundColor DarkGray
      Set-PSReadlineOption -TokenKind Type      -ForegroundColor Cyan
      Set-PSReadlineOption -TokenKind Command   -ForegroundColor Blue
      Set-PSReadlineOption -TokenKind Parameter -ForegroundColor DarkCyan
      Set-PSReadlineOption -TokenKind Comment   -ForegroundColor DarkGreen
      Set-PSReadlineOption -TokenKind String    -ForegroundColor DarkRed
      Set-PSReadlineOption -TokenKind Number    -ForegroundColor DarkBlue
      Set-PSReadlineOption -TokenKind Member    -ForegroundColor Black
      

      Note: the Import command at the top is only necesary in WindowsPowerShell. PSReadline is automatically included in PowerShell Core V6+

      May the Forces of good computing be with you!

      RG

      PowerShell & VBA Rule!
      Computer Specs

    Viewing 1 reply thread
    Reply To: Colored Windows PowerShell

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: