All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Santi Béjar" <sbejar@gmail.com>
To: Git Mailing List <git@vger.kernel.org>
Subject: Re: [COGITO PATCH] cg-branch-switch and local branches
Date: Wed, 01 Jun 2005 16:41:38 +0200	[thread overview]
Message-ID: <87mzqaqgv1.fsf@gmail.com> (raw)
In-Reply-To: <87ekbmi5zl.fsf@ifae.es> ( Santi Béjar's message of "Wed, 01 Jun 2005 15:03:42 +0200")

Hi,

        after reading it I think I have to explain it better.

        And first I have to say that this patch depends on my patches
        in the thread "[COGITO PATCH] Heads and tags in subdirectories".
        But the logic does not depend on it, I think :)

Suppose I want to make some modifications to the cogito. So I do:

cg-clone cogito rsync://rsync.kernel.org/pub/scm/cogito/cogito.git

the first argument been the name I've gave to this repositori. Now I can
do the changes/commits in the usual way. But I want to work in two
differents patches, named dirs and switch, so I do:

cg-branch-add dirs cogito
cg-branch-add switch cogito

Now I have to local branches with their respective names, and the origin
been the cogito branch for both (but it can be different).

If I want to work on the dirs branch I do:

cg-branch-switch dirs

an the same for switch. In each case I can do a:

cg-merge origin

and merge their respective origin (in this case is the same).

If I want to work directly in cogito, I can do:

cg-branch-switch cogito

and work in the usual way. If the cogito repository have a branche
called cogito2 I could do:

cg-branch-switch cogito#cogito2

in the case I've already pulled this branch.

Internally it is:

Local branches
--------------

The master file is always a link:

master -> ${localbranch}

The content of $_git/branches/${localbranch} is the original branch of
local branch. The cases and the corresponding origin links are:

1a.- name         : a name of an external repository
                    $branch corresponding to the definition
                    origin -> $name/$branch
1b.- name#branch : optionally with a branch
                    origin -> $name/$branch
2 .- name         : a name of another local branch
                    $branch corresponding to the definition
                    origin -> $name/$branch

Local unnamed branches
----------------------

The master file is a regular file and the origin link only has the cases
1a and 1b where the $name is name of the local branch.




  reply	other threads:[~2005-06-01 14:38 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-06-01 13:03 [COGITO PATCH] cg-branch-switch and local branches Santi Béjar
2005-06-01 14:41 ` Santi Béjar [this message]
2005-06-01 16:20   ` Santi Béjar
2005-06-02  6:09     ` Santi Béjar

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=87mzqaqgv1.fsf@gmail.com \
    --to=sbejar@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.