Re: confusion with some `git reset` commands
- From
Kevin <ikke@ikke.info>
- Date
- Dec 18, 2014, 08:23 UTC
- Message-ID
- <CAO54GHAVMSYCHAoqH1OOSaUeHBdSmqTvzJLWWUa0_bO3CLy4zg@mail.gmail.com>
- In-Reply-To
- <2055441.uOK6yH3IMG@linux-wzza.site>
On Tue, Dec 16, 2014 at 7:39 PM, Arup Rakshit <aruprakshit@rocketmail.com> wrote:
Show 6 quoted lines
> Hi, > .. > > But I am looking for any differences - > > a) git reset --soft and git reset --keep
git reset --keep is a safer version of git reset --hard. It will reset the working tree. but will abort when it has to overwrite uncomitted changes.
> b) git reset --hard and git reset --merge
git reset --merge does the same as hard, but keeps unstaged changes. When unstaged changes would need to be overwritted, it also aborts.