Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Commits From a Deleted Repo Re-appear in Recreated Repo

E_H_N November 8, 2021

I want to delete a repo including all commits and then re-create this repo without having the previous commits available.

When I (1) delete a repo, (2) re-create it with the same name and then (3) push my commit to it, I can go to the 'Commits' page and view both the present commit as well as the previous commits from the deleted repo.  Is this a bug?  Should the commits from the deleted repo be deleted as well and no longer accessible?

This issue may be related to one that was recently posted on the BitBucket Server Bug Board: Bitbucket Server BSERV-13038 Deleting a repository doesn't delete commits data sent to Jira Cloud

Any feedback from the BitBucket team regarding this issue will be greatly appreciated thanks!

1 answer

0 votes
E_H_N November 8, 2021

...So I may have found an answer...

I re-attempted by:

(1) Deleting a particular repo;

(2) Re-creating it in BitBucket;

(3) Deleting the '.git' folder on my local machine for the given project;

(4) Re-committing and pushing the contents of the project from local to the remote; then

(5) Checking to see which commits were available in BitBucket.

I was able to confirm that only one commit was now present in BitBucket.  What may have happened earlier was that I was not re-initialising Git for the project on my local machine, which resulted in the previous commits getting re-committed and pushed to BitBucket.

This does not appear to be a S/W issue, it is a 'me' issue...

Happy to hear from anyone else if they have experienced something similar!

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events