From: Francis Moreau <francis.moro@gmail.com>
To: ding@gnus.org
Subject: Re: git newbie errors
Date: Tue, 09 Nov 2010 21:19:40 +0100 [thread overview]
Message-ID: <m2eiaus10j.fsf@gmail.com> (raw)
In-Reply-To: <87fwvaba7v.fsf@dod.no> (Steinar Bang's message of "Tue, 09 Nov 2010 19:52:52 +0100")
Steinar Bang <sb@dod.no> writes:
> I learnt something about git today. We've been running it in a CVS like
> fashion, and that is (apparently) not the way.
>
> What we did was to have one branch in the hub index that our group was
> working on, and then we all each had a local branch tracking it, and we
> were all working directly on our local tracking branches.
>
> When we then did "git pull" we got some odd merges done into our local
> branches. It was hard to see what had happened and hard to undo.
>
> I ended up with a fresh git clone, replace the index in the working
> directory, and doing a "git reset --hard" today, after a misbegotten
> clean up attempt.
>
> So... what we'll do come tomorrow, is:
> - each create a local branch tracking the shared branch on origin
> - branch off from this local tracking branch to do work, and commit all
> of our work to this branch
> - when finished working, switch to the local tracking branch
> - pull ff changes from the shared origin branch
> - merge in the local work branch into the tracking branch
> - handle conflicts
> - push
> - if the push fails (because someone else have pushed since your pull),
> reset --hard your tracking branch, do a new ff pull from origin, do a
> merge from the temp branch and try pushing again (repeat as needed)
> - when push has completed the work branch can be deleted (git branch -d
> will only delete remerged branches)
>
> This is the recommended CVS-like pattern of git (or so I'm told).
But why still using CVS-like pattern with git ?
IOW, why not using git as it should be ?
--
Francis
next prev parent reply other threads:[~2010-11-09 20:19 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-09 18:09 Lars Magne Ingebrigtsen
2010-11-09 18:52 ` Steinar Bang
2010-11-09 18:56 ` Julien Danjou
2010-11-09 19:07 ` Lars Magne Ingebrigtsen
2010-11-09 21:12 ` Andreas Schwab
2010-11-09 20:19 ` Francis Moreau [this message]
2010-11-09 20:36 ` Steinar Bang
2010-11-10 13:50 ` Francis Moreau
2010-11-10 14:02 ` Steinar Bang
2010-11-12 0:01 ` Greg Troxel
2010-11-10 2:15 ` Katsumi Yamaoka
2010-11-10 17:38 ` Andreas Schwab
2010-11-10 17:56 ` Lars Magne Ingebrigtsen
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=m2eiaus10j.fsf@gmail.com \
--to=francis.moro@gmail.com \
--cc=ding@gnus.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).