0

I'm currently trying to use EGit, however I keep getting this error when I attempt to push:

Cannot connect to any URI: <Remote URL> (<Remote URL>: not authorized)

(Remote URL hid)

However, I input my credentials correctly and set my user.name and user.email correctly.

This is my config file:

[core]
    repositoryformatversion = 0
    filemode = true
    logallrefupdates = true
[remote "origin"]
    url = <Remote URL>
    fetch = +refs/heads/*:refs/remotes/origin/*
[branch "main"]
    remote = origin
    merge = refs/heads/main

I don't have two-factor authentication on (thus I do not need an access key), and I've tried using many of the methods that I found, to no avail.

Note: when I clone a repository, which also requires credentials, the authentication goes by perfectly fine.

What is the reason for this and how can I fix it?

new Q Open Wid
  • 2,225
  • 2
  • 18
  • 34
  • Cloning does not require (correct) credentials when it's a public GitHub repository, at least for HTTPS. GitHub does not allow using your GitHub account password for HTTPS anymore. You need to create a personal access token and use it as password: https://stackoverflow.com/a/68802292/6505250 – howlger Feb 13 '22 at 18:55
  • 1
    Oh my goodness! So that's why, I totally forgot, I haven't used Git in a long time – new Q Open Wid Feb 13 '22 at 19:20

0 Answers0