I have two Bitbucket accounts using two different Email address. Everything looks working fine except one strange behavior.:
If I log in into account #2 and get into the Commits screen I see the commit history however the Icon picture at the begging of the line is the picture that related to account #1 and if I click on it I get a "You'r never been here" screen. Beside that everything works fine. The icon on the bottom left corner of the screen is correct and I can click on it and get the correct profile.
Could't find any way to fix that.
Welcome to the Community.
The commit contains author name and email – this is configured in Git client on your local machine. Bitbucket then resolves the user that created a commit by looking at that author metadata.
So it looks like you used the email linked to your account#1 when you created commits (as in, it is configured in Git client), then you pushed these commits to account#2's repository (committer and pusher can be different people, and in fact, author could be different both of these too). Bitbucket correctly resolved commit author using account#1's email to account#1 — this is why you see the avatar of account#1. Now, account#1 has private profile page, so account#2 can't access it — this is why you see "You were never here" error page.
A way to fix would be to override at least user.email property in Git config for that repository (or by other means, Git config is hierarchical). Here's the Git config documentation page for details.
Hope this helps. Let me know if you have any questions.
No worries, always happy to help :)
Is there any way to change the history?
Yes, what you need is called Git history rewrite. Very powerful tool, so be careful. Also note that if there's more than one consumer of that repo, they might need to do some untangling if they happened to fetch the history you've rewritten before you did that and started some work on top of it. It's worth reading this article first to understand the possible implications.
Here's the related Git documentation page. Simple but manual way is to use interactive rebase and amend every commit. However if you have more than a couple of commits to change, you might want to go with filter-branch instead. Here's a SO answer that suggests a script which I believe does exactly what you need.
Let me know if you have any questions.
Hi everyone, The Cloud team recently announced 12 new DevOps features that help developers ship better code, faster ! While we’re all excited about the new improvements to Bitbucket ...
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event
You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events