Re: applying a patch to 2 branches
- From: Shaun McCance <shaunm gnome org>
- To: "Dr. Michael J. Chudobiak" <mjc avtechpulse com>
- Cc: gnome-infrastructure gnome org
- Subject: Re: applying a patch to 2 branches
- Date: Wed, 22 Apr 2009 10:58:04 -0500
On Wed, 2009-04-22 at 09:43 -0400, Dr. Michael J. Chudobiak wrote:
> Hi all,
>
> Can someone explain the "proper way" to apply a patches to both a stable
> branch and the master branch, using git?
>
> With svn, I would commit the patches to the stable branch (say as
> commits 124 and 125), then go to the trunk branch, then use something
> like "svn merge -r 123:125 /path/to/stable/branch", and commit from trunk.
>
> I'm struggling to understand the equivalent in git. Perhaps it's
> obvious, just not to me...
Do you ever want anything on stable and not on master?
If not, you can just merge from stable to master.
git checkout master
git merge stable
You can do this over and over and over. Git knows which
commits from stable it's already merged, because those
commits are actually in the history of master, rather
than cheap copies of them.
I do this all the time, and never have any problems worse
than an easy-to-resolve merge conflict.
--
Shaun
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]