Skip to content

Instantly share code, notes, and snippets.

@skalibog
Created April 6, 2020 14:35
Show Gist options
  • Save skalibog/f7f741617281ffdf4c34ac3da8106ede to your computer and use it in GitHub Desktop.
Save skalibog/f7f741617281ffdf4c34ac3da8106ede to your computer and use it in GitHub Desktop.
Script for change github access
echo "=========================================="
echo "Set ssh id_rsa(sample desc)"
echo "=========================================="
git config --global --replace-all user.email "YOURNAME@gmail.com"
git config --global --replace-all user.name "GITHUB NAME"
echo "------------------------------------------"
echo "User creds"
git config --global user.email
git config --global user.name
echo "------------------------------------------"
killall ssh-agent
ssh-add ~/scripts/keys/id_rsa_sample # generated key
ssh -T git@github.com # check for acc access
echo "=========================================="
echo "Set ssh id_rsa successfully"
echo "=========================================="
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment