Monday, 1 December 2014

Setting Git after configure the two-factor authentication with GitHub

Two-factor authentication allow the user to link her mobile phone with the GitHub account, which is more secure. The problem with this is after it is set, the old password is no longer accepted and instead, a token should be provided.

1. Generate token
1.1 Go to GitHub account
1.2 Go to Application
1.3 On "Personal access tokens", click on "Generate new token" or you can just click on the follow link:

https://github.com/settings/tokens/new

1.4 Write down the description for the token and click on "Generate Token"

2. Add tokens to your computer
2.1 You should remove the token saved in your computer first. If you are using Mac OS, just find it in the keychain and delete it
2.2 After it, try to get the data from the repository. For example, write "git pull" in the terminal/console.
2.3 Fill your username in the GitHub
2.4 In the password field, paste your token

Source
http://olivierlacan.com/posts/why-is-git-https-not-working-on-github/
https://help.github.com/articles/creating-an-access-token-for-command-line-use/


No comments:

Post a Comment