1

I am trying to fetch from my colleagues fork using the following command:

git remote add fellow https://<servername>/~nsarkr/<application>.git

Next I try to fetch the branches:

git fetch fellow

I get the following error:

fatal: Authentication failed for 'https://<servername>/~nsarkr/<application>.git'

But I'm not sure what can authenticate me. I am aware that my colleague may create personal tokens and can share it with me, but how would I use that? I need to use the fetch command. I don't want to clone the repo again, since that would clutter my workspace.

The following article explains about cloning the repo using personal tokens.

https://help.github.com/en/github/authenticating-to-github/creating-a-personal-access-token-for-the-command-line

Thanks in advance!!

Energya
  • 2,623
  • 2
  • 19
  • 24
Nilotpal
  • 3,237
  • 4
  • 34
  • 56
  • This depends on the type of server being used for the remote. Perhaps you've stored credentials for this remote before that have now expired? https://stackoverflow.com/a/50105930/283078 – cmbuckley Nov 26 '19 at 10:26

0 Answers0