Skip to content

Instantly share code, notes, and snippets.

@Kova93
Last active January 23, 2023 12:32
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 Kova93/c619d4d142d84c685ba66560aa69d0c0 to your computer and use it in GitHub Desktop.
Save Kova93/c619d4d142d84c685ba66560aa69d0c0 to your computer and use it in GitHub Desktop.
.bashrc for Windows git bash
SSH_AGENT_PID=$(ps | grep ssh-agent | awk '{print $1}')
if [[ -n "$SSH_AGENT_PID" ]]; then
SSH_AUTH_SOCK=$(find /tmp/ssh-* -name "agent.$(( $SSH_AGENT_PID - 1 ))")
export SSH_AGENT_PID
export SSH_AUTH_SOCK
else
eval $(ssh-agent)
fi
ssh-add ~/.ssh/id_ed25519
test -f ~/.bash_aliases && . ~/.bash_aliases
cdgit
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment