I forgot to check the option interactive when rebasing a branch. I need one final commit but instead I have N commits on master. Is it possible to squash commits after the rebase process was finished?
            Asked
            
        
        
            Active
            
        
            Viewed 4,268 times
        
    4
            
            
         
    
    
        Amio.io
        
- 20,677
- 15
- 82
- 117
- 
                    1What is the _virtual_ option? Which tool do you use? This does not seem like standard git cli. – Johannes Thorn May 26 '16 at 11:23
- 
                    @JohannesThorn, sorry, of course I meant `interactive`. – Amio.io May 26 '16 at 11:29
- 
                    Possible duplicate of [Squash my last X commits together using Git](http://stackoverflow.com/questions/5189560/squash-my-last-x-commits-together-using-git) – Marcin Koziński May 26 '16 at 11:31
1 Answers
6
            Yes you can rebase them again. Use the following command for an interactive rebase:
git rebase --interactive <commit-id>
Where <commit-id> is the last commit you want unchanged. After that an editor will show up. Change all the pick commands to squash for the commits you want squashed into one.
 
    
    
        Johannes Thorn
        
- 902
- 6
- 13