git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Advice/help needed

From
IHIan Hobson <ian@ianhobson.co.uk>
Date
Nov 16, 2009, 22:46 UTC
Message-ID
<4B01D661.2060401@ianhobson.co.uk>
In-Reply-To
<551f769b0911160840k6ea274e9q33de777fac7cec70@mail.gmail.com>
Yann Simon wrote:
Show 47 quoted lines
> 2009/11/16 Ian Hobson <ian@ianhobson.co.uk>:
>   
>> My thoughts are to have 4 branches, one for each customer. 99% of all
>> changes will be needed by all (or at least most)
>> of the customers (P,W,S and E). How can I make a change to master and then
>> use git to apply those changes to the four branches, without losing the
>> differences between branches?
>>
>> For example (if this is the best way) go from this
>> O-----O-----A-----B-----C  (master)
>>  \----P
>>  \---W
>>   \--S
>>    \-E
>>
>> to first this, where D is the net effect of A B and C  (this is for ease of
>> reading logs, and commit messages),
>> O-----O-----D  (head)  \----P
>>  \---W
>>   \--S
>>    \-E
>>
>> and then to this, (without editing all the files four times?)
>> O-----O-----D  (head)
>>  \----P-----D'
>>  \---W----D''
>>   \--S-----D'''
>>    \-E-----D''''
>>     
>
> What I would do is:
> - one branch for the common
> - one branch for each customer, which contains the specific
> differences compare to the common branch
>
> You could program on the common branch.
> When you are ready, you can checkout each specific branch and rebase
> on the common branch.
> For example:
> $ git checkout common
> edit, test, commit
> $ git checkout client1
> $ git rebase common
> $ git checkout client2
> $ git rebase common
>
>   
Hi Yann,

I'll use master for common, unless I have a large chunk of development to do, and see how it goes.

Many thanks.
Ian
Previous: Yann Simon
Message 3 of 3 in “Advice/help needed”
  1. Ian HobsonNov 16, 2009
  2. Yann SimonNov 16, 2009
  3. Ian HobsonNov 16, 2009

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.