All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ramkumar Ramachandra <artagnon@gmail.com>
To: julia <deborave@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: Opinions on my GIT model
Date: Thu, 20 Jan 2011 10:03:27 +0530	[thread overview]
Message-ID: <20110120043322.GA9493@kytes> (raw)
In-Reply-To: <1295465635148-5941048.post@n2.nabble.com>

Hi Julia,

julia writes:
> Working on a GIT model for my projects.
> 
> 1.  Three main repositories, bare public repo, maintainer repo, developer
> repo
> 2.  Developer1 clones the public repo and makes feature1 branch, updates,
> commits changes and pulls/pushes.
> 3.  Developer2 on their local repo does the same thing and pushes updates.
> 4.  Maintainer get the green light to rebase feature1 branch with master -
> they pull the whole repo, rebase the feature1 branch with master and then
> push feature1.
> 5.  Developer1 pulls feature1 brach again and continues to work, does a
> pull/push to feature1 on public repo.

Having a mainline + feature branches is a very common development
model.

> Now, main question is - given that in step 4 maintainer rebase the feature
> branch with master then pushed, he is committing a cardinal sin by rebasing
> a branch that has already been pushed to the public repo, so if anyone has
> made any changes based on the commits originally pushed that now have been
> rebased - developer who tries to push those changes will have issues.
> 
> Will these be solved by executing of a pull? 

In many projects, including git.git itself, master's history is never
overwritten. Feature branches are merged into `pu`, then into `next`,
and finally graduate to `master`. I suppose it's a matter of
convinience- you should have atleast one stable branch (ie. `master`)
so that developers know what to base their work on.

git-pull.sh is a porcelain-level helper that executes a fetch and
performs a kind of merge/ rebase depending on the situation and
command-line flags. I'd encourage you to read the manpage and shell
script itself and see what all these options are, and how they work.

Finally, I think the merge operation is what you're looking
for. Please read git-merge(1).

-- Ram

      reply	other threads:[~2011-01-20  4:32 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-19 19:33 Opinions on my GIT model julia
2011-01-20  4:33 ` Ramkumar Ramachandra [this message]

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=20110120043322.GA9493@kytes \
    --to=artagnon@gmail.com \
    --cc=deborave@gmail.com \
    --cc=git@vger.kernel.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 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.