From: Tor Arntsen Date: Tue, 29 Mar 2011 06:15:58 GMT Subject: Re: how to squash two commits into only one Message-ID: In-Reply-To: On Tue, Mar 29, 2011 at 07:42, Lynn Lin wrote: > All, >   I have only have two commits in repo,then I want to squash these > two commit into one through git rebase -i .However it fails > > $ git rebase -i HEAD^1 > it only show up one commit so can't squash (can't squash without a > previous commit) To squash commits with rebase -i: git log (identify the commit you wish to squash to) git rebase -i