From: "Takuya N via GitGitGadget" <gitgitgadget@gmail.com>
To: git@vger.kernel.org
Cc: Takuya N <takninnovationresearch@gmail.com>,
Takuya Noguchi <takninnovationresearch@gmail.com>
Subject: [PATCH v2] doc: use 'rev' instead of 'commit' for merge-base arguments
Date: Wed, 04 Mar 2020 12:38:34 +0000 [thread overview]
Message-ID: <pull.719.v2.git.git.1583325514607.gitgitgadget@gmail.com> (raw)
In-Reply-To: <pull.719.git.git.1583220197856.gitgitgadget@gmail.com>
From: Takuya Noguchi <takninnovationresearch@gmail.com>
The notation <commit> can be misunderstandable only for commit SHA1,
but merge-base accepts any commit references. Like rev-parse, the name
of arguments should be <rev> instead of <commit>.
Signed-off-by: Takuya Noguchi <takninnovationresearch@gmail.com>
---
doc: use 'rev' instead of 'commit' for merge-base arguments
The notation can be misunderstandable only for commit SHA1, but
merge-base accepts any commit references. Like rev-parse, the name of
arguments should be instead of .
Changes since v1:
* Use rev instead of ref, not commit-ish which is less used than rev
through the document.
Signed-off-by: Takuya Noguchi takninnovationresearch@gmail.com
[takninnovationresearch@gmail.com]
Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-git-719%2Ftnir%2Fmerge-base-supporting-refs-v2
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-git-719/tnir/merge-base-supporting-refs-v2
Pull-Request: https://github.com/git/git/pull/719
Range-diff vs v1:
1: 9c83cf1c620 ! 1: 6e2157da4b1 doc: use 'ref' instead of 'commit' for merge-base arguments
@@ -1,10 +1,10 @@
Author: Takuya Noguchi <takninnovationresearch@gmail.com>
- doc: use 'ref' instead of 'commit' for merge-base arguments
+ doc: use 'rev' instead of 'commit' for merge-base arguments
The notation <commit> can be misunderstandable only for commit SHA1,
- but merge-base accepts any commit references. Like reflog, the name of
- arguments should be <ref> instead of <commit>.
+ but merge-base accepts any commit references. Like rev-parse, the name
+ of arguments should be <rev> instead of <commit>.
Signed-off-by: Takuya Noguchi <takninnovationresearch@gmail.com>
@@ -20,11 +20,11 @@
-'git merge-base' --is-ancestor <commit> <commit>
-'git merge-base' --independent <commit>...
-'git merge-base' --fork-point <ref> [<commit>]
-+'git merge-base' [-a|--all] <ref> <ref>...
-+'git merge-base' [-a|--all] --octopus <ref>...
-+'git merge-base' --is-ancestor <ref> <ref>
-+'git merge-base' --independent <ref>...
-+'git merge-base' --fork-point <ref> [<ref>]
++'git merge-base' [-a|--all] <rev> <rev>...
++'git merge-base' [-a|--all] --octopus <rev>...
++'git merge-base' --is-ancestor <rev> <rev>
++'git merge-base' --independent <rev>...
++'git merge-base' --fork-point <ref> [<rev>]
DESCRIPTION
-----------
@@ -41,11 +41,11 @@
- N_("git merge-base --independent <commit>..."),
- N_("git merge-base --is-ancestor <commit> <commit>"),
- N_("git merge-base --fork-point <ref> [<commit>]"),
-+ N_("git merge-base [-a | --all] <ref> <ref>..."),
-+ N_("git merge-base [-a | --all] --octopus <ref>..."),
-+ N_("git merge-base --independent <ref>..."),
-+ N_("git merge-base --is-ancestor <ref> <ref>"),
-+ N_("git merge-base --fork-point <ref1> [<ref2>]"),
++ N_("git merge-base [-a | --all] <rev> <rev>..."),
++ N_("git merge-base [-a | --all] --octopus <rev>..."),
++ N_("git merge-base --independent <rev>..."),
++ N_("git merge-base --is-ancestor <rev> <rev>"),
++ N_("git merge-base --fork-point <ref> [<rev>]"),
NULL
};
@@ -54,7 +54,7 @@
N_("is the first one ancestor of the other?"), 'a'),
OPT_CMDMODE(0, "fork-point", &cmdmode,
- N_("find where <commit> forked from reflog of <ref>"), 'f'),
-+ N_("find where <ref2> forked from reflog of <ref1>"), 'f'),
++ N_("find where <rev> forked from reflog of <ref>"), 'f'),
OPT_END()
};
Documentation/git-merge-base.txt | 10 +++++-----
builtin/merge-base.c | 12 ++++++------
2 files changed, 11 insertions(+), 11 deletions(-)
diff --git a/Documentation/git-merge-base.txt b/Documentation/git-merge-base.txt
index 2d944e0851f..60438a00871 100644
--- a/Documentation/git-merge-base.txt
+++ b/Documentation/git-merge-base.txt
@@ -9,11 +9,11 @@ git-merge-base - Find as good common ancestors as possible for a merge
SYNOPSIS
--------
[verse]
-'git merge-base' [-a|--all] <commit> <commit>...
-'git merge-base' [-a|--all] --octopus <commit>...
-'git merge-base' --is-ancestor <commit> <commit>
-'git merge-base' --independent <commit>...
-'git merge-base' --fork-point <ref> [<commit>]
+'git merge-base' [-a|--all] <rev> <rev>...
+'git merge-base' [-a|--all] --octopus <rev>...
+'git merge-base' --is-ancestor <rev> <rev>
+'git merge-base' --independent <rev>...
+'git merge-base' --fork-point <ref> [<rev>]
DESCRIPTION
-----------
diff --git a/builtin/merge-base.c b/builtin/merge-base.c
index e3f8da13b69..e03f2269e88 100644
--- a/builtin/merge-base.c
+++ b/builtin/merge-base.c
@@ -29,11 +29,11 @@ static int show_merge_base(struct commit **rev, int rev_nr, int show_all)
}
static const char * const merge_base_usage[] = {
- N_("git merge-base [-a | --all] <commit> <commit>..."),
- N_("git merge-base [-a | --all] --octopus <commit>..."),
- N_("git merge-base --independent <commit>..."),
- N_("git merge-base --is-ancestor <commit> <commit>"),
- N_("git merge-base --fork-point <ref> [<commit>]"),
+ N_("git merge-base [-a | --all] <rev> <rev>..."),
+ N_("git merge-base [-a | --all] --octopus <rev>..."),
+ N_("git merge-base --independent <rev>..."),
+ N_("git merge-base --is-ancestor <rev> <rev>"),
+ N_("git merge-base --fork-point <ref> [<rev>]"),
NULL
};
@@ -158,7 +158,7 @@ int cmd_merge_base(int argc, const char **argv, const char *prefix)
OPT_CMDMODE(0, "is-ancestor", &cmdmode,
N_("is the first one ancestor of the other?"), 'a'),
OPT_CMDMODE(0, "fork-point", &cmdmode,
- N_("find where <commit> forked from reflog of <ref>"), 'f'),
+ N_("find where <rev> forked from reflog of <ref>"), 'f'),
OPT_END()
};
base-commit: 2f268890c2cd2f115424936bbee27f8269080e5e
--
gitgitgadget
next prev parent reply other threads:[~2020-03-04 12:38 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-03 7:23 [PATCH] doc: use 'ref' instead of 'commit' for merge-base arguments Takuya N via GitGitGadget
2020-03-03 7:32 ` Bryan Turner
2020-03-03 14:08 ` Johannes Schindelin
2020-03-03 14:30 ` Junio C Hamano
2020-03-03 19:38 ` Johannes Schindelin
2020-03-03 20:08 ` Junio C Hamano
2020-03-04 12:38 ` Takuya N via GitGitGadget [this message]
2020-03-04 16:44 ` [PATCH v2] doc: use 'rev' " Junio C Hamano
2020-03-04 17:26 ` Junio C Hamano
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=pull.719.v2.git.git.1583325514607.gitgitgadget@gmail.com \
--to=gitgitgadget@gmail.com \
--cc=git@vger.kernel.org \
--cc=takninnovationresearch@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.