Remove a git commit

Soldato
Joined
1 Mar 2003
Posts
5,508
Location
Cotham, Bristol
Let's say I have the following commits

F
E
D
C
B
A

And I wished to remove commit C from the stack but keep the rest as is, i.e. like so

F
E
D
B
A

Is that possible? I know of git reset, but that resets the whole stack to a point, i.e. it gets rid of anything after that commit too.
 
A build is due to be released at the end of the week, there is a potential problem with commit 'C' so we wish to remove it and have it committed to a later build once the problem is sorted.

'C' is a cherry picked commit from a topic branch in to the main branch
 
Last edited:
Back
Top Bottom