Home > Blockchain >  Git not working on wsl but it is working on powershell without pat token
Git not working on wsl but it is working on powershell without pat token

Time:09-04

I am trying to clone a repository using wsl but I get the error

remote: Repository not found.
fatal: repository '<WORKING LINK>' not found

I can clone the repository using github desktop application or by using power shell

I have tried to delete the credential file as I read that it might give this problem
After which I get the remote: Support for password authentication was removed on August 13, 2021. error.
I do NOT have access to the PAT of the repo as I am not the owner but I am a collaborator
The Repository is a private repository

Can anyone help with this? Thank you

CodePudding user response:

First thing, add you git configurations to the system:

git config --global user.name "Your Name"
git config --global user.email "[email protected]"

Then you can create Personal Access Token from your Github account here. Note that PAT is account specific and if you are a collaborator in a repo then you can use your PAT to do stuff (according to the privileges you have)

Now try cloning your repository normally using the following:

git clone https://github.com/privateRepo/privateRepo.git # using HTTPS

The prompt will ask for your username password/Authentication Token.

or

git clone https://username:[email protected]/user/repo
  • Related