Git and the PowerShell prompt

There is lots of information out there on using Posh-Git. This is nothing new, its just a little helper for me since I have been recently been shuffling through workstations at an alarming rate. If it is useful for you as well, stellar!

  1. Install GIT

  1. From an elevated powershell prompt:
Install-Package posh-git


  1. Modify your profile for PowerShell and PowerShell_ISE

Reference for PowerShell profiles

Posh-Git will install in C:\Program Files\WindowsPowerShell\Modules\posh-git\ This will obviously change as newer versions are released. Verify the path with this command –

(Get-Module Posh-Git).Path

In this directory you will find profile.example.ps1

Comment out line 4 and uncomment line 8. (Unless this doesn’t work for you, then make the modifications that would work for you)


  1. Make any additional modification you want to make to your profile and then copy the contents of profile.example.ps1 to:

C:\Users[username]\Documents\WindowsPowerShell\Microsoft.PowerShell_profile.ps1 and



  1. Start a new PowerShell instance and then create a new GIT repository. Check out your awesome prompt.