PatrickMelia
PatrickMelia

Reputation: 87

Git Bash can't add my user.name or user.email

I am a new user to github/git bash.

I am trying to add my project to github using git bash. Once I get to the stage of git push, username for 'github.com' appears, but I can't type in my user name. Why is this?

I also tried this by using git config --global user.name "Your Name Here"

Upvotes: 1

Views: 1669

Answers (1)

Jeff Stagg
Jeff Stagg

Reputation: 45

You'll want to remove and re-add your github remote as the ssh url, rather than the https url. So, say you've been pushing to 'origin', and your 'origin' is "https://github.com/username/repo/repo.git". You'll want to do:

git remote remove origin
git remote add origin [email protected]:username/repository.git
git push origin branch

Otherwise, you're going to have to enter your github email address and password on each session.

Upvotes: 1

Related Questions