Skip to content

Instantly share code, notes, and snippets.

@thinkbeforecoding
Created March 11, 2016 16:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save thinkbeforecoding/11fd14096ccd4c28a4a0 to your computer and use it in GitHub Desktop.
Save thinkbeforecoding/11fd14096ccd4c28a4a0 to your computer and use it in GitHub Desktop.
Setup GitHub for windows in Powershell profile
. $env:UserProfile\AppData\Local\GitHub\shell.ps1
$r = ssh-agent -s
[regex]::Matches($r,"SSH_AUTH_SOCK=([^;]+);") | % { $env:SSH_AUTH_SOCK = $_.Groups[1] }
[regex]::Matches($r,"SSH_AGENT_PID=(\d+);") | % { $env:SSH_AGENT_PID = $_.Groups[1] }
ssh-add $env:UserProfile\.ssh\github_rsa
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment