Comment faire pour afficher la branche locale de l'histoire?

Je suis très nouveau pour git, je veux savoir comment suivre l'histoire de la branche?

Par exemple:

echo "update README in branch master" >> README.md
git commit -a -m"commit in branch master"
git checkout -b b1
echo "update README in branch b1" >> README.md
git commit -a -m"commit in branch b1"
git checkout master
git merge b1
git push

puis quelqu'un clone de ce repo, la façon de montrer l'histoire de la branche?

git log --graph

* commit 4162ecc962aa020ec6294312e4f8eed63ca152d1
| Author: test1 <[email protected]>
| Date:   Fri Feb 15 14:37:43 2013 +0900
|
|     commit in branch b1
|
* commit 08e80fc644fa7ebb374a601e16533a8fc3578f88
| Author: test1 <[email protected]>
| Date:   Fri Feb 15 14:37:04 2013 +0900
|
|     commit in branch master
|
* commit 9d9649cdb409654616798d8feeb516738997e2e0
  Author: test1 <[email protected]>
    Date:   Thu Feb 14 21:33:46 2013 -0800

            Initial commit

Je vois aussi un peu de ce genre de journal:

* commit 2f49d77afe0708037eab1de3d216484d01f1c190
| Author: ericz <[email protected]>
| Date:   Wed Feb 13 11:45:49 2013 -0800
|
|     readme update
|
*   commit 996214b87cce3473297ed0997ca567497271e05a
|\  Merge: a239b70 5269cd4
| | Author: ericz <[email protected]>
| | Date:   Wed Feb 13 11:45:23 2013 -0800
| |
| |     Merge branch 'master' of github.com:peers/peerjs
| |
| * commit 5269cd455f1522e88ab5a15228effe11665e6a89
| | Author: Eric Zhang <[email protected]>
| | Date:   Wed Feb 13 09:47:05 2013 -0800
| |
| |     Update README.md
| |
* | commit a239b706f294c469a5c6542ce7e6f5e60417445a
| | Author: ericz <[email protected]>
| | Date:   Wed Feb 13 11:45:09 2013 -0800
| |
| |     new exmales
| |
* | commit 0ce560d093637b3a17c7b5f1ab1de3f9c00bb888
|/ Author: ericz <[email protected]>
|   Date:   Wed Feb 13 11:02:33 2013 -0800
|
|       simple chat example

comment cela se fait?

et comment tracer le graphique comme ceci:

               D---E-------F
                      /    \       \
                     B---C---G---H---I---J
                    /                    \
                   A-------K---------------L--M
Votre premier exemple est trop simple donc git seulement d'appliquer les correctifs dans les fast-forward, sans une fusion de commettre. Vous pouvez forcer le git pour créer une fusion de commettre au lieu d'avancer rapidement à l'aide de git merge --no-ff.

OriginalL'auteur Sato | 2013-02-15