I lost my commits! #189285
-
Select Topic AreaQuestion BodyI once changed my primary and secondary account e-mails addresses, for connecting with my student e-mail and get the Educational version, but doing it, all the commits I made with my old e-mail address were no longer associated with my account. So I did the "obvious", I added my old e-mail to my account again, now I have three e-mails associated. When I open the commits, I can see they associated to my account, BUUUT, this is not shown in repositories contributions and neither in my profile graphic of last contributions. It contains very important contributions. Can anyone help me? |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 6 replies
-
|
If you want the codebase at that stage of the commit you can directly access it by using git checkout "commit id" in your terminal. You can copy it from your commit history in the repository. I think I got your problem. If it is something else let me know will be glad to help you |
Beta Was this translation helpful? Give feedback.
-
|
It sounds like you've done the right thing by re-adding the old email to your GitHub account. Since the commits are now showing as linked to your profile, the hard part is over. The missing contributions on your graph are usually due to one of these three reasons: Default Branch: GitHub only tracks contributions made to the default branch (usually main or master). If your commits are in a feature branch that hasn't been merged yet, they won't show up on the green square map. Email Verification: Go to your GitHub Email Settings and make sure that old address is marked as "Verified." If it isn't, the commits will link to your name but won't count toward your stats. Update Lag: It can take up to 24 hours for GitHub to rebuild your contribution graph after you re-associate an email. If those are all set, check your profile settings to ensure "Private contributions" are toggled on, especially if those important commits were in a private repository. |
Beta Was this translation helpful? Give feedback.
-
|
If the commits are already showing as linked to your account inside the repository, that's a good sign. One thing you may want to double-check is the email used in the commits. You can run: git log --pretty=format:"%an %ae" and confirm that the email in the commits is one of the emails added to your GitHub account. Also note that GitHub only counts contributions that are in the repository's default branch. If those commits are in another branch that hasn't been merged yet, they won't appear in your contribution graph. If everything looks correct, GitHub sometimes takes a bit of time to update the graph after email changes. |
Beta Was this translation helpful? Give feedback.

It sounds like you've done the right thing by re-adding the old email to your GitHub account. Since the commits are now showing as linked to your profile, the hard part is over. The missing contributions on your graph are usually due to one of these three reasons:
Default Branch: GitHub only tracks contributions made to the default branch (usually main or master). If your commits are in a feature branch that hasn't been merged yet, they won't show up on the green square map.
Email Verification: Go to your GitHub Email Settings and make sure that old address is marked as "Verified." If it isn't, the commits will link to your name but won't count toward your stats.
Update Lag: It can take u…