tutorial: Use only separate layout
Then the newbies only have to understand one layout. Signed-off-by: Santi Béjar <sbejar@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
Santi Béjar committed
Jan 17, 2007 at 01:09 UTC
8b616f24ea5f18a13bd274f9dd9a1a42e6c4b223
1 file changed
+13
-13
Documentation/tutorial.txt
+13
-13
@@ -283,10 +283,12 @@ at /home/bob/myrepo. She does this with:
283
284
------------------------------------------------
285
$ cd /home/alice/project
286
-$ git pull /home/bob/myrepo master
286
+$ git remote add bob /home/bob/myrepo
287
+$ git pull bob master
288
------------------------------------------------
289
289
-This merges the changes from Bob's "master" branch into Alice's
290
+First it adds the "remote" Bob's repository with the name "bob" and
291
+then it merges the changes from Bob's "master" branch into Alice's
292
current branch. If Alice has made her own changes in the meantime,
293
then she may need to manually fix any conflicts. (Note that the
294
"master" argument in the above command is actually unnecessary, as it
@@ -296,18 +298,16 @@ The "pull" command thus performs two operations: it fetches changes
298
from a remote branch, then merges them into the current branch.
299
300
You can perform the first operation alone using the "git fetch"
299
-command. For example, Alice could create a temporary branch just to
300
-track Bob's changes, without merging them with her own, using:
301
+command without merging them with her own branch, using:
302
303
-------------------------------------
303
-$ git fetch /home/bob/myrepo master:bob-incoming
304
+$ git fetch bob
305
-------------------------------------
306
306
-which fetches the changes from Bob's master branch into a new branch
307
-named bob-incoming. Then
307
+which fetches the changes from Bob's branches. Then
308
309
-------------------------------------
310
-$ git log -p master..bob-incoming
310
+$ git log -p master..bob/master
311
-------------------------------------
312
313
shows a list of all the changes that Bob made since he branched from
@@ -318,21 +318,21 @@ could merge the changes into her master branch:
318
319
-------------------------------------
320
$ git checkout master
321
-$ git merge bob-incoming
321
+$ git merge bob/master
322
-------------------------------------
323
324
-The last command is a merge from the "bob-incoming" branch in Alice's
324
+The last command is a merge of the "bob/master" branch in Alice's
325
own repository.
326
327
Alice could also perform both steps at once with:
328
329
-------------------------------------
330
-$ git pull /home/bob/myrepo master:bob-incoming
330
+$ git pull bob
331
-------------------------------------
332
333
-This is just like the "git pull /home/bob/myrepo master" that we saw
333
+This is just like the "git pull bob master" that we saw
334
before, except that it also stores the unmerged changes from bob's
335
-master branch in bob-incoming before merging them into Alice's
335
+master branch in bob/master before merging them into Alice's
336
current branch. Note that git pull always merges into the current
337
branch, regardless of what else is given on the commandline.
338