4

I've removed a few large files from my repo following these instructions:

http://help.github.com/remove-sensitive-data

However, if I do a fresh clone from my main repo, I still pull down the deleted data. I suspect it's because of this:

"Be warned that force-pushing does not erase commits on the remote repo, it simply introduces new ones and moves the branch pointer to point to them. If you are worried about users accessing the bad commits directly via SHA1, you will have to delete the repo and recreate it."

I've tried pushing the commits to a new repo, and while it doesn't have the extra data, it's also missing all my github issues.

Two (related) questions: - is there a way to push the cleaned up repo to the main repo? - if not, is there a way to transfer the issues from the main repo to the new repo?

7
  • Possible duplicate Commented Aug 3, 2011 at 1:21
  • Hi Andy. I saw that thread, but it didn't conclusively answer the first question (whether there was a way to force a GC on github's side), and it didn't touch on the second one (some way to transfer GitHub Issues). I've sent GitHub a support request to ask about the former. Commented Aug 3, 2011 at 1:42
  • According to one of the comments in that thread, gc happens after every repo operation Commented Aug 3, 2011 at 1:44
  • Aha, hadn't noticed that. Then it seems garbage collection is not actually the answer, since it doesn't seem to lead to a smaller repo. Commented Aug 3, 2011 at 1:58
  • Make sure you delete any remote refs that might be pointing to somewhere keeping it in the repo. Commented Aug 3, 2011 at 2:07

2 Answers 2

2

Alright, after some back and forth with GitHub's excellent support team (thanks Tekkub!), we figure out what was happening.

The answer was that the repo had tags, which kept pointers to the old data. The solution was to force-push the tags as well, ensuring that the old tags got deleted (and hence the old data got garbage collected).

Sign up to request clarification or add additional context in comments.

Comments

0

If you still get the stuff you removed when you clone, then it is still referenced somewhere. Check out git branch -va on the fresh clone, you probably have an old branch pointing at the commits you wanted to remove.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.