Re: how to squash two commits into only one
- From
- Lynn Lin <lynn.xin.lin@gmail.com>
- Date
- Mar 29, 2011, 06:04 UTC
- Message-ID
- <AANLkTi=uqCm6cZa1c0VDig8MXKxupZWHdtKW2N36RtoU@mail.gmail.com>
- In-Reply-To
- <AANLkTi=PZY2d+NhNnnOyXMX70N31vRg3qS5er+hECy8A@mail.gmail.com>
On Tue, Mar 29, 2011 at 1:59 PM, Henrik Hautakoski <henrik@fiktivkod.org> wrote:
> You can do a soft reset and amend the changes to the root commit. > git reset HEAD^1 > (add the files) > git commit --amend
really good!
Thanks Lynn
Show 26 quoted lines
> On Tue, Mar 29, 2011 at 07:42, Lynn Lin <lynn.xin.lin@gmail.com> 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) >> >> >> Any help on this? >> >> Thanks >> Lynn >> -- >> To unsubscribe from this list: send the line "unsubscribe git" in >> the body of a message to majordomo@vger.kernel.org >> More majordomo info at http://vger.kernel.org/majordomo-info.html > > > > -- > Henrik Hautakoski > henrik@fiktivkod.org >