From: Junio C Hamano <gitster@pobox.com>
To: Jon Loeliger <jdl@freescale.com>
Cc: Sitaram Chamarty <sitaramc@gmail.com>, Git List <git@vger.kernel.org>
Subject: Re: [RFC] New command: 'git snapshot'.
Date: Tue, 10 Feb 2009 12:31:28 -0800 [thread overview]
Message-ID: <7v7i3ym3tr.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <1234295272.10335.26.camel@ld0161-tx32> (Jon Loeliger's message of "Tue, 10 Feb 2009 13:47:52 -0600")
Jon Loeliger <jdl@freescale.com> writes:
> On Tue, 2009-02-10 at 04:51 +0000, Sitaram Chamarty wrote:
>
>> I use cross-branch stashes all the time. Stash it here, go
>> there, and pop the stash. I hope that does not change :-)
>
> Perhaps 'git checkout -m other_branch'?
Sure, or even "git checkout other_branch" without -m.
"Stash it here, go there, and pop the stash" is what you would use when
you have many changes that you _know_ "checkout -m" will run a 3-way merge
to produce a heavy conflict, and you suspect you may need to be able to
retry the unstashing after taking a break.
If you are lucky and manage to resolve the conflicts easily (or did not
even get conflicts when applying), then pop will drop the stash and you
have everything you want in your index and the work tree. Otherwise, your
work tree would be a mess, and you may have to "reset --hard" out to start
from scratch, but then the stash will still be there.
next prev parent reply other threads:[~2009-02-10 20:33 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-02-09 18:54 [RFC] New command: 'git snapshot' Fabio Augusto Dal Castel
2009-02-09 19:52 ` Giuseppe Bilotta
[not found] ` <38cfbb550902101232l4c83b6dfjc70e1e2f79a8c3c1@mail.gmail.com>
2009-02-10 20:48 ` Fabio Augusto Dal Castel
2009-02-09 22:36 ` Brandon Casey
2009-02-10 4:51 ` Sitaram Chamarty
2009-02-10 19:47 ` Jon Loeliger
2009-02-10 20:31 ` Junio C Hamano [this message]
2009-02-11 1:22 ` Sitaram Chamarty
2009-02-10 20:40 ` Fabio Augusto Dal Castel
2009-02-10 23:00 ` Jeff King
2009-02-10 23:08 ` Junio C Hamano
2009-02-10 23:38 ` Jeff King
2009-02-10 23:39 ` Geoffrey Lee
2009-02-11 13:43 ` Jeff King
2009-02-11 9:04 ` Matthieu Moy
2009-02-11 20:40 ` Fabio Augusto Dal Castel
-- strict thread matches above, loose matches on Subject: below --
2009-02-10 23:58 Ulrik Sverdrup
2009-02-11 0:05 ` Ulrik Sverdrup
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7v7i3ym3tr.fsf@gitster.siamese.dyndns.org \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=jdl@freescale.com \
--cc=sitaramc@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).