25

I noticed that in my commits to github there is my email address.

I couldn't find this email address appear anywhere on github, but I was wondering if it could appear anywhere and be crawled by bots for spam?

If so, is that possible to remove the email address and not have it in the commits anymore?

Note: the project is open and public on github (not private repository)

Matthieu Napoli
  • 48,448
  • 45
  • 173
  • 261
  • 5
    It's almost certainly too late to prevent it from being harvested by spam bots, and I really doubt that making sure your email address isn't published on the web is at all useful for reducing spam; good filtering is the only real solution. – Wooble Sep 04 '12 at 14:41
  • I'm voting to close this question as off-topic because it's not about software or programming but about how GitHub works. This probably belongs on SuperUser. – Charlie-Blake Sep 08 '15 at 08:24

2 Answers2

78

Anyone who clones the git repository will be able to see the email address you made the commit with.

If you add .patch to any commit URL you will see the raw commit data (including the commiter's email). For example: https://github.com/kennethreitz/requests/commit/c8f166f696327d.patch

mhsmith
  • 6,675
  • 3
  • 41
  • 58
yprez
  • 14,854
  • 11
  • 55
  • 70
  • 3
    And of course there's the nice REST api for retrieving the last few public events of a user, complete with commit email adresses: `https://api.github.com/users/{user}/events/public`, look for any `events[type="PushEvent"].payload.commits[].author.email` – Robert Nov 19 '17 at 17:05
  • 10
    Wow. with `.patch` I don't need to clone a repo again, to see 'real' email address. – azzamsa Dec 30 '18 at 22:23
  • Of course the trick with appending `.patch` to the commitURL might just show `@users.noreply.github.com`, in which case this does not reveal any useful information (e.g., for contacting the author)... unless someone knows a work-around for this scenario? – raner May 31 '22 at 05:32
0

It is possible that your email address is public on your profile like mine is here: https://github.com/noahc.

You can see here: https://github.com/search?q=John&repo=&langOverride=&start_value=1&type=Users&language= it is quite easy to collect email addresses for common names.

It seems to me those should be your two biggest concerns. Obviously, if someone pulls it down they can see the email address as well.

Noah Clark
  • 8,101
  • 14
  • 74
  • 116
  • @MatthieuNapoli Seems like it only works for old accounts (circa 2008) EDIT: Actually, it may be the "Public email" setting in Profile Settings, which now defaults to "Don't show my email address" but probably was different circa 2008. – ADTC Aug 08 '15 at 06:51