Home > Software design >  Why git clone works for VS Code but not for Terminal?
Why git clone works for VS Code but not for Terminal?

Time:01-12

When I execute the following command in the VS Code it works fine.

git clone https://github.com/example-repo.git

But when I execute the same command in the terminal(Ubuntu) it gives the following error:

remote: Support for password authentication was removed on August 13, 2021. Please use a personal access token instead.
remote: Please see https://github.blog/2020-12-15-token-authentication-requirements-for-git-operations/ for more information.
fatal: Authentication failed for 'https://example-repo.git/'

Personal access tokens have been already setup for this account (With read, write and delete permissions).

CodePudding user response:

you need to generate an ssh keys in your folder ~/.git, you can read this article it will help you setup your keys:

https://dev.to/augustocarmona/how-to-set-up-ssh-keys-and-connect-them-to-github-3136#:~:text=Connecting to GitHub with SSH:&text=After this, go to your,enter your password and voila!

CodePudding user response:

Since support for password authentication is removed, I'd just recommend using the github-cli its gonna make your life a lot simpler.

https://cli.github.com/

  •  Tags:  
  • Related