diff options
author | Clemens Buchacher <drizzd@aon.at> | 2009-10-21 19:21:23 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2009-10-21 14:20:50 -0700 |
commit | d504f6975d34025ed3b5478b657789410b52cdb1 (patch) | |
tree | 15a1740788917b9242b65a911f312edfbeaf8e5a /Documentation/git-merge.txt | |
parent | 78d553b7d7b269bb22ebd8b1198657c37484a3a0 (diff) | |
download | git-d504f6975d34025ed3b5478b657789410b52cdb1.tar.gz |
modernize fetch/merge/pull examples
The "git pull" documentation has examples which follow an outdated
style. Update the examples to use "git merge" where appropriate and
move the examples to the corresponding manpages.
Furthermore,
- show that pull is equivalent to fetch and merge, which is still a
frequently asked question,
- explain the default fetch refspec.
Signed-off-by: Clemens Buchacher <drizzd@aon.at>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation/git-merge.txt')
-rw-r--r-- | Documentation/git-merge.txt | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/Documentation/git-merge.txt b/Documentation/git-merge.txt index d05f324462..e886c2ef54 100644 --- a/Documentation/git-merge.txt +++ b/Documentation/git-merge.txt @@ -212,6 +212,39 @@ You can work through the conflict with a number of tools: common ancestor, 'git show :2:filename' shows the HEAD version and 'git show :3:filename' shows the remote version. + +EXAMPLES +-------- + +* Merge branches `fixes` and `enhancements` on top of + the current branch, making an octopus merge: ++ +------------------------------------------------ +$ git merge fixes enhancements +------------------------------------------------ + +* Merge branch `obsolete` into the current branch, using `ours` + merge strategy: ++ +------------------------------------------------ +$ git merge -s ours obsolete +------------------------------------------------ + +* Merge branch `maint` into the current branch, but do not make + a new commit automatically: ++ +------------------------------------------------ +$ git merge --no-commit maint +------------------------------------------------ ++ +This can be used when you want to include further changes to the +merge, or want to write your own merge commit message. ++ +You should refrain from abusing this option to sneak substantial +changes into a merge commit. Small fixups like bumping +release/version name would be acceptable. + + SEE ALSO -------- linkgit:git-fmt-merge-msg[1], linkgit:git-pull[1], |