➜ /myproj git:(master) git push -u origin master
Username for 'https://github.com': username
Password for 'https://username@github.com':
remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls
for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/myrepo/myproj.git/'
In order to fix the authentication error, follow the below steps:
Step 1: Create Personal access token:
- Go to github.com,
- Go to Profile -> Settings,
- Select Developer Settings,
- Select Personal access tokens,
- Now click on Generate new token,
- Select Expiration and Scope,
- Click on Generate Token.
- Copy the token, it should look something like this ghp_129ZVLCiqkYTiWXxYC9ZSXjf20AkhN1InLOf
Step 2: Clone git project using token
% git clone https://github.com/user/repo
Username:
Password: access-token
Provide Feedback For This Article
We take your feedback seriously and use it to improve our content. Thank you for helping us serve you better!
😊 Thanks for your time, your feedback has been registered!
Comments & Discussion
Facing issues? Have questions? Post them here! We're happy to help!