0

Recently a staff member has informed me that using the following procedures:

So you download Git, GitExtensions, and KDiff3, clone the repository, right click on the downloaded folder, open repository, and there you can see all the commits that have been done as of the time you downloaded it. You pick on a commit and you find the description of it and that of the author.

they are able to view my email address and this is sensitive information that I would prefer not to give out. I have changed the email linked to my account, and my public and commit emails, yet it still refuses to change even after they downloaded the latest dev build, and my information is still present.

I would like to know if there is any way to erase this information or alternatively to remove all the commit history (as I make most of the commits and have done so from the beginning) so that my email is not leaked.

jonrsharpe
  • 115,751
  • 26
  • 228
  • 437
keiowo
  • 11
  • 3
  • 2
    Changing your committer data will only impact *new* commits, if you want to change the old ones you have to explicitly rewrite them all, force push the new history and ask GitLab support to remove the old commits from the remote. – jonrsharpe Dec 21 '19 at 09:20
  • 1
    hi, welcome to stackoverflow. **rewriting** history may cause problem with someone else in the team, do keep it in mind. rewriting commit history will require you to redo the entire commits up to head. your best bet would just start a new repository. – Bagus Tesa Dec 21 '19 at 09:25
  • https://stackoverflow.com/search?q=%5Bgit%5D+change+commit+email – phd Dec 21 '19 at 10:34

1 Answers1

2

With modern VCS, thus also git, the commits consist of the the actual data and some meta data which include the author of the changes made. These can never be changed by the GUI tools of a hosting site - unless they provide and you allow them to rewrite the history of the repository in its entirety. Usually this is done off-line with git itself. If the history is rewritten, all clones of the repository will still have the old information, though. Depending on the client(s) you use to interact with git, there's different ways in achieving your goal. See here for an incomprehensive overview.

Consider to use one e-mail for all your commits which you still do read, though. It's possibly the only means of people to contact you when they get hold of code you wrote.

planetmaker
  • 5,884
  • 3
  • 28
  • 37