diff --git a/bin/git-merge-into b/bin/git-merge-into
index 4ec774f..ddaaea9 100755
--- a/bin/git-merge-into
+++ b/bin/git-merge-into
@@ -5,11 +5,11 @@ current_branch() {
}
usage() {
- echo "Usage: git merge-into [src] dest [--ff]"
+ echo "Usage: git merge-into [src] dest [--ff-only]"
}
cur_branch=$(current_branch)
-if [ "${!#}" == '--ff' ]; then
+if [ "${!#}" == '--ff-only' ]; then
case $# in
2 ) # dest --ff
git push "$(git rev-parse --show-toplevel)" "$cur_branch":"$1";;
diff --git a/man/git-merge-into.1 b/man/git-merge-into.1
index e0ce182..2ed9f19 100644
--- a/man/git-merge-into.1
+++ b/man/git-merge-into.1
@@ -1,13 +1,13 @@
.\" generated with Ronn/v0.7.3
.\" http://github.com/rtomayko/ronn/tree/0.7.3
.
-.TH "GIT\-MERGE\-INTO" "1" "April 2015" "" ""
+.TH "GIT\-MERGE\-INTO" "1" "August 2015" "" "Git Extras"
.
.SH "NAME"
\fBgit\-merge\-into\fR \- Merge one branch into another
.
.SH "SYNOPSIS"
-\fBgit merge\-into\fR [src] [\-\-ff]
+\fBgit merge\-into\fR [src] [\-\-ff\-only]
.
.SH "DESCRIPTION"
Merge one branch into another, and keep yourself on current branch\. If src branch not given, it will merge current one to dest\.
@@ -25,10 +25,10 @@ The name of the branch will be merged into\. If this not given, use current bran
The name of the branch to merge into\.
.
.P
-\-\-ff
+\-\-ff\-only
.
.P
-Try to use \fBgit push\fR instead of \fBgit merge\fR\. Only work on fast\-forward mode\.
+Refuse to merge and exit with a non\-zero status unless the current HEAD is already up\-to\-date or the merge can be resolved as a fast\-forward\.
.
.SH "EXAMPLES"
Assume the following history exists and the current branch is src:
@@ -64,7 +64,7 @@ After running \fBgit merge\-into dest\fR, it will look like this:
The \fBH\fR commit will record the merge result, just like what \fBgit merge\fR does\. And \fBsrc\fR is still the current branch\.
.
.P
-The default implementation of \fBmerge\-into\fR use \fBgit checkout\fR and \fBgit merge\fR, which may cause temporary change in the working tree\. If you make sure your branch can be merged fast\-forward, add \fB\-\-ff\fR to avoid files change\.
+The default implementation of \fBmerge\-into\fR use \fBgit checkout\fR and \fBgit merge\fR, which may cause temporary change in the working tree\. If you make sure your branch can be merged fast\-forward, add \fB\-\-ff\-only\fR to avoid files change\.
.
.SH "AUTHOR"
Written by spacewander <\fIspacewanderlzx@gmail\.com\fR>
diff --git a/man/git-merge-into.html b/man/git-merge-into.html
index 449c4d1..077ad0e 100644
--- a/man/git-merge-into.html
+++ b/man/git-merge-into.html
@@ -65,7 +65,7 @@
- git-merge-into(1)
-
+ - Git Extras
- git-merge-into(1)
@@ -76,7 +76,7 @@
SYNOPSIS
-git merge-into [src] <dest> [--ff]
+git merge-into [src] <dest> [--ff-only]
DESCRIPTION
@@ -92,9 +92,10 @@
The name of the branch to merge into.
- --ff
+ --ff-only
- Try to use git push instead of git merge. Only work on fast-forward mode.
+ Refuse to merge and exit with a non-zero status unless the current HEAD is
+ already up-to-date or the merge can be resolved as a fast-forward.
EXAMPLES
@@ -117,11 +118,11 @@ And src is still the current branch.
The default implementation of merge-into use git checkout and git merge,
which may cause temporary change in the working tree. If you make sure your
-branch can be merged fast-forward, add --ff to avoid files change.
+branch can be merged fast-forward, add --ff-only to avoid files change.
AUTHOR
-Written by spacewander <spacewanderlzx@gmail.com>
+Written by spacewander <spacewanderlzx@gmail.com>
REPORTING BUGS
@@ -134,7 +135,7 @@ branch can be merged fast-forward, add --ff to avoid files change.<
diff --git a/man/git-merge-into.md b/man/git-merge-into.md
index 8d200ca..0c9c372 100644
--- a/man/git-merge-into.md
+++ b/man/git-merge-into.md
@@ -3,7 +3,7 @@ git-merge-into(1) -- Merge one branch into another
## SYNOPSIS
-`git merge-into` [src] <dest> [--ff]
+`git merge-into` [src] <dest> [--ff-only]
## DESCRIPTION
@@ -19,9 +19,11 @@ Merge one branch into another, and keep yourself on current branch. If src branc
The name of the branch to merge into.
- --ff
+ --ff-only
+
+ Refuse to merge and exit with a non-zero status unless the current HEAD is
+ already up-to-date or the merge can be resolved as a fast-forward.
- Try to use `git push` instead of `git merge`. Only work on fast-forward mode.
## EXAMPLES
@@ -42,7 +44,7 @@ And `src` is still the current branch.
The default implementation of `merge-into` use `git checkout` and `git merge`,
which may cause temporary change in the working tree. If you make sure your
-branch can be merged fast-forward, add `--ff` to avoid files change.
+branch can be merged fast-forward, add `--ff-only` to avoid files change.
## AUTHOR