Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Incorrect credentials when trying to clone Repository to NetBeans with https

I use NetBeans 12.5, set up a new project and want to clone an existing repository to my local drive. I use Tools -> Git -> Clone... image of top many choices made

After entering the Repository URL and a user/password I get the error message:

Incorrect credentials for repository at https://github.com/MYORG/PATH/TO/myrepro

Image of Clone-Repository wizard window and error message

I have checked that I can login tp the repository on Github with exactly that combination of username and password that that worked.

I have also used the commandline interface to clone my repository and that worked (to make sure it's not a connectivity issue). The commandline that I use is exactly the same path to repo and it clones the correct repository:

git clone https://github.com/MYORG/PATH/TO/myrepro

However the commandline uses a different authenticator (info: please complete authentication in your browser...).

My questions are:

  1. How can I get the NetBeans clone to work?
  2. As a workaround, can I clone on the commandline and to which directory do I have to clone?
like image 238
safir Avatar asked Mar 24 '26 07:03

safir


1 Answers

follow these steps to solve it :

  1. Login to your github account and click on your username and select settings
  2. On the sidebar select "Developer settings"
  3. Select on the shown screen "Personal access tokens"
  4. On top right select "Generate new token"
  5. Under "note" field give a name to the generated tokens
  6. Give an expiration to your token under "Expiration" field
  7. Under "Select scope" check "repo"
  8. Click "Generate token"
  9. Copy the generated token and save it anywhere safely and use it on netbeans as password
like image 106
Nessa Avatar answered Mar 27 '26 05:03

Nessa