Git: delete a single remote revision
git, github
Solution
The post located here solved my problem.
If the commit you want to fix isn’t the most recent one:
`git rebase --interactive $parent_of_flawed_commit`
If you want to fix several flawed commits, pass the parent of the oldest one of them.
An editor will come up, with a list of all commits since the one you gave.
- Change `pick` to `edit` in front of any commits you want to fix.
- Once you save, git will replay the listed commits.
Git will drop back to the shell for every commit you said you want to edit:
- Change the commit in any way you like.
- `git commit --amend`
- `git rebase --continue`
Most of this sequence will be explained to you by the output of the various commands as you go. It’s very easy, you don’t need to memorise it – just remember that `git rebase --interactive` lets you correct commits no matter how long ago they were.
Problem
I've started switching my private subversion projects to git (Github) and release the code to the public. Therefore, I am a git newbie. Unfortunately, there is a revision of a project that contains confidential data. The revision is not tagged, I just know its hash value. Is there a way to completely erase that particular revision from the remote git repository? It is a solo project, so nobody will be harmed from the operation.