Saturday, January 11, 2014

Error 400 Pushing my Repository to Github in windows 7 64 bit

error: The requested URL returned error: 400 while accessing https://github.com/jkasaudhan/projects.git[branch master]/info/refs
fatal: HTTP request failed 

Solution: 
  1. Changed ssh key configuration in github 
  •  Open git bash, type ssh-keygen -t rsa  then y , enter enter ,enter .
  •  Then cat ~/.ssh/id_rsa.pub and copy the ssh key all as it is and paste it to github web interface on                  Account    setting>>ssh key 
  • removed old origin using command - git remote rm origin 
  • added new origin with ssh url using command -            git remote add origin git@github.com:jkasaudhan/projects.git
  •  do not place url with https://.....rather use ssh url type
  •   push to repo using command git push origin master. It worked !!!

No comments:

Post a Comment