Re: Git documentation reorganization and cleanup
- From: Santi Béjar <santi agolina net>
- To: Owen Taylor <otaylor redhat com>
- Cc: gnome-infrastructure gnome org, GNOME Desktop Hackers <desktop-devel-list gnome org>
- Subject: Re: Git documentation reorganization and cleanup
- Date: Sat, 18 Apr 2009 18:14:53 +0200
2009/4/18 Owen Taylor <otaylor redhat com>:
> ===
> In Git, branches and tags are simply references to a commit. You can
> check out a branch using the following command, once you have cloned the
> project:
>
> git checkout [branch name]
>
> For a list of the available branches for a given project:
>
> git branch -r
>
> The following example will check out gnome-utils master and then check
> out the 'gnome-2-0' branch:
>
> git clone git://git.gnome.org/gnome-utils
> cd gnome-utils
> git checkout gnome-2-0
> ===
>
> That obviously doesn't work - it needs to show:
>
> git checkout -b [branch name] origin/[branch name]
>
> For initially creating the local branch, and have some explanation of
> what is going on.
>
> (It's a little confusing here to use git checkout -b to create the
> branch... multiple things going on at once; but 'git checkout -b' has
> the important side-effect of setting up the new branch to pull from the
> origin, which you would have to do manually if you used 'git branch' to
> create the branch.)
git branch [branch name] origin/[branch name]
also does the setup the same way as ´git checkout -b´.
Santi
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]