All of lore.kernel.org
 help / color / mirror / Atom feed
From: merlyn@stonehenge.com (Randal L. Schwartz)
To: Bill Lear <rael@zopyra.com>
Cc: git@vger.kernel.org
Subject: Re: pull into dirty working tree
Date: Wed, 13 Jun 2007 08:01:14 -0700	[thread overview]
Message-ID: <86zm33291h.fsf@blue.stonehenge.com> (raw)
In-Reply-To: <18031.64456.948230.375333@lisa.zopyra.com> (Bill Lear's message of "Wed, 13 Jun 2007 09:14:32 -0500")

>>>>> "Bill" == Bill Lear <rael@zopyra.com> writes:

Bill> We have some CVS users who complain that they cannot do a pull
Bill> into a dirty working tree, as they could under CVS.  Here is
Bill> their scenario: they make a few changes to their code and want
Bill> to test it out; someone else pushes changes to the central repo
Bill> that they then want to add to their working tree to test also;
Bill> they then want to pull in these changes and test everything, as
Bill> if they had done 'mv stuff stuff-; git pull; mv stuff- stuff'.

Bill> They would like an option (perhaps a config option) to do a "dirty
Bill> pull".

Maybe this will do it, presuming they haven't published any of their local
work, and they're on a topic branch "topic"

git-tag WIP # mark HEAD so we can come back
git-commit -a -m WIP # commit current work so we can replay it
git-fetch origin # grabs the upstream
git-rebase origin # rebase current work-in-progress onto new upstream
# might need to resolve and commit conflicts repeatedly
git-reset --soft WIP # next commit will be on top of commit prior to rebase
git-reset # mark all files as uncommitted as yet
git-tag -d WIP # no more need for this tag

This effectively puts the upstream changes "under" (or "prior to") the current
topic branch.

-- 
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<merlyn@stonehenge.com> <URL:http://www.stonehenge.com/merlyn/>
Perl/Unix/security consulting, Technical writing, Comedy, etc. etc.
See PerlTraining.Stonehenge.com for onsite and open-enrollment Perl training!

  parent reply	other threads:[~2007-06-13 15:01 UTC|newest]

Thread overview: 43+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-06-13 14:14 pull into dirty working tree Bill Lear
2007-06-13 14:38 ` Pierre Habouzit
2007-06-13 14:43   ` Pierre Habouzit
2007-06-13 14:47     ` Pierre Habouzit
2007-06-13 14:45   ` Bill Lear
2007-06-13 14:53     ` Pierre Habouzit
2007-06-13 15:01 ` Randal L. Schwartz [this message]
2007-06-13 19:28   ` Alex Riesen
2007-06-13 19:32     ` Randal L. Schwartz
2007-06-13 20:47       ` Alex Riesen
2007-06-13 20:52         ` Randal L. Schwartz
2007-06-13 21:39           ` Alex Riesen
2007-06-13 22:01             ` Randal L. Schwartz
2007-06-13 22:27               ` Alex Riesen
2007-06-13 15:01 ` Johannes Schindelin
2007-06-13 15:40   ` Andy Parkins
2007-06-13 15:54     ` Johannes Schindelin
2007-06-13 15:56     ` Bill Lear
2007-06-13 16:07       ` Johannes Schindelin
2007-06-13 16:30         ` Bill Lear
2007-06-13 17:13   ` Junio C Hamano
2007-06-14  4:22 ` Daniel Barkalow
2007-06-14  5:21 ` Linus Torvalds
2007-06-14  7:49   ` Junio C Hamano
2007-06-14  8:01     ` Raimund Bauer
2007-06-14  8:06     ` Steven Grimm
2007-06-14 14:25       ` Nicolas Pitre
2007-06-14 12:46   ` Bill Lear
2007-06-14 15:46     ` Linus Torvalds
2007-06-14 20:20       ` Olivier Galibert
2007-06-14 20:30         ` Linus Torvalds
2007-06-15  0:46       ` Martin Langhoff
2007-06-15  1:07         ` Linus Torvalds
2007-06-15  3:33           ` Martin Langhoff
2007-06-15 18:26             ` Robin Rosenberg
  -- strict thread matches above, loose matches on Subject: below --
2007-06-13 15:03 MichaelTiloDressel
2007-06-13 15:36 ` Bill Lear
2007-06-13 17:31   ` Michael Dressel
2007-06-13 18:12     ` Bill Lear
2007-06-13 18:30       ` Johannes Schindelin
2007-06-13 18:56         ` Bill Lear
2007-06-13 20:17           ` Robin Rosenberg
2007-06-13 23:32             ` Johannes Schindelin

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=86zm33291h.fsf@blue.stonehenge.com \
    --to=merlyn@stonehenge.com \
    --cc=git@vger.kernel.org \
    --cc=rael@zopyra.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.