I am pushing into repositories from my laptop using Git Bash which is Riturajrs but it is showing that it was pushed from an account I was previously logged into. I also tried reinstalling git bash but problem persisted. Please help. Apparently the problem must be in web browser which is changing my name after being pushed
Asked
Active
Viewed 165 times
0
-
When you say "it is showing that it was pushed from an account I was previously logged into" where do you see this? – Code-Apprentice Jun 14 '22 at 19:57
-
In commits section. Once I have pushed it from my system, in repository it shows NAPS pushed whereas my id is Riturajrs – Rituraj Seal Jun 14 '22 at 20:10
-
1This may be helpful: https://stackoverflow.com/questions/22844806/how-to-change-my-git-username-in-terminal – Christian Jun 14 '22 at 20:34
-
You don't "log in" to Git: you just use it. There are no saved log-in credentials. There *is* a `user.name` and `user.email` setting; Git uses those to set the corresponding strings in new commits. When you run `git push`, Git uses either https or ssh, and *those* have *authentication* (not "logging in") and those are very different. So you need to decide which things to fix: `user.name` etc as shown by `git log`, or authentication to GitHub. GitHub authentication will depend on whether you're using https or ssh. – torek Jun 15 '22 at 09:28
1 Answers
2
Your git config has your old settings in it.
To set your global username/email configuration:
Open the command line.
Set your username: git config --global user.name "FIRST_NAME LAST_NAME"
Set your email address: git config --global user.email "MY_NAME@example.com"
(source: https://support.atlassian.com/bitbucket-cloud/docs/configure-your-dvcs-username-for-commits/)

Rb C
- 21
- 4