Access denied when trying to push to Github

Asked

Viewed 846 times

0

I’m having trouble pushing to a repository on Github:

remote: Permission to fabiojaniolima/laravel-boot.git denied to user123.
fatal: unable to access 'https://github.com/fabiojaniolima/laravel-boot.git/': The requested URL returned error: 403

I do not know where this user user123, my goal is to go up with the user fabiojaniolima, I already searched the configuration but I did not find, I looked in the project settings and global.

  • Have you tried git config --global user.email?

  • already looked, this defined as fabiojaniolima

  • returns Fabio-janio. I inspected with Sourcetree and did not find any notes for this account user123 (Obs: I remember having tested with this account a few days ago)

  • That’s not exactly an email, right?

  • the global user.email and user.name variables and project locations are with the correct email and name.

2 answers

1

I thought the problem was just what I didn’t expect. In the git settings everything was correct, the problem was in the macOS keyring, he saved an old login with user123, when I was running a push he was considering the credentials of user123 and not the user configured on ~/.gitconfig or .git/gitconfig

0

Check the repository’s ". /. git/config" file, it may be configured locally with this user.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.