From: "Catalin Marinas" <catalin.marinas@gmail.com>
To: "Theodore Tso" <tytso@mit.edu>
Cc: "Yann Dirson" <ydirson@altern.org>,
"Jakub Narebski" <jnareb@gmail.com>,
git@vger.kernel.org
Subject: Re: Rebasing stgit stacks
Date: Sun, 28 Jan 2007 23:21:19 +0000 [thread overview]
Message-ID: <b0943d9e0701281521i60da11dfscd8649f56960730d@mail.gmail.com> (raw)
In-Reply-To: <20070128043312.GG9897@thunk.org>
On 28/01/07, Theodore Tso <tytso@mit.edu> wrote:
> Well, a typical use case for me is:
>
> stg branch master
> git pull .
> stg branch 2.6.20-rc5
> stg export -d /tmp/temp-stack
> stg branch master
> stg branch -C 2.6.20-rc6
> stg import -s /tmp/temp-stack/series
>
> That's because I want to keep the original patch series for
> 2.6.20-rc5, but I also want rebase the patch set to 2.6.20-rc6. Is
> there a better way of doing this?
As Yann pointed out, you could just clone 2.6.20-rc5 into 2.6.20-rc6
and rebase the latter (currently with 'stg rebase v2.6.20-rc6').
If you have the branches already created, you can avoid the
export/import with a cherry-pick (with better merging than just
applying a patch). The 'pick' command only takes an argument (I'd like
to extend it to accept multiple or patch ranges) but you can use it
with 'series':
stg branch 2.6.20-rc6
stg series -b 2.6.20-rc5 --noprefix --showbranch [patches...] \
| xargs -rn1 stg pick
You could even use the --missing instead of -b for the series command.
This option shows the patches on the remote branch which are missing
in current. Pretty useful if you want to continue importing after
fixing a conflict for example (that's a reason why I haven't extended
'pick' yet, 'series -m' seemed pretty powerful).
Another trick if you modify some patches in one branch (i.e.
2.6.20-rc5) is to use 'stg sync -b 2.6.20-rc5 [patches]' in the other
branch. It tries a three-way merge of each individual patch with the
corresponding one in the other branch, showing you any possible
conflicts (I usually have 'imerger' set to emacs... and 'autoimerge'
to 'yes' in the config file so that emacs' ediff is automatically
invoked for every conflict).
--
Catalin
next prev parent reply other threads:[~2007-01-28 23:21 UTC|newest]
Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-01-09 21:35 Howto use StGit and git-svn at same time Guilhem Bonnefille
2007-01-09 21:41 ` Guilhem Bonnefille
2007-01-09 22:41 ` Yann Dirson
2007-01-15 13:26 ` Guilhem Bonnefille
2007-01-15 20:24 ` Rebasing stgit stacks Yann Dirson
2007-01-15 22:46 ` Catalin Marinas
2007-01-15 23:39 ` Yann Dirson
2007-01-16 22:42 ` Catalin Marinas
2007-01-16 23:17 ` Yann Dirson
2007-01-16 23:30 ` Jakub Narebski
2007-01-17 9:03 ` Karl Hasselström
2007-01-17 11:07 ` David Kågedal
2007-01-17 19:34 ` Yann Dirson
2007-01-17 20:53 ` Yann Dirson
2007-01-18 12:06 ` Catalin Marinas
2007-01-18 19:42 ` Yann Dirson
2007-01-19 9:40 ` Jakub Narebski
2007-01-20 13:17 ` Yann Dirson
2007-01-20 19:16 ` Jakub Narebski
2007-01-20 20:07 ` Yann Dirson
2007-01-22 23:12 ` Catalin Marinas
2007-01-18 9:05 ` Catalin Marinas
2007-01-18 20:52 ` Yann Dirson
2007-01-19 9:47 ` Jakub Narebski
2007-01-22 17:54 ` Catalin Marinas
2007-01-22 19:47 ` Yann Dirson
2007-01-22 22:58 ` Catalin Marinas
2007-01-23 7:49 ` Yann Dirson
2007-01-23 22:03 ` Catalin Marinas
2007-01-24 0:05 ` Yann Dirson
2007-01-24 12:37 ` Catalin Marinas
2007-01-24 20:03 ` Yann Dirson
2007-01-28 4:33 ` Theodore Tso
2007-01-28 10:25 ` Yann Dirson
2007-01-28 23:21 ` Catalin Marinas [this message]
2007-01-17 21:30 ` Yann Dirson
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=b0943d9e0701281521i60da11dfscd8649f56960730d@mail.gmail.com \
--to=catalin.marinas@gmail.com \
--cc=git@vger.kernel.org \
--cc=jnareb@gmail.com \
--cc=tytso@mit.edu \
--cc=ydirson@altern.org \
/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).