diff options
author | Philippe Blain <levraiphilippeblain@gmail.com> | 2020-11-01 17:28:44 +0000 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2020-11-01 15:54:14 -0800 |
commit | 180d641d7d71ba45a140e9c83777d30be59c4274 (patch) | |
tree | 3d80f94b4d7e3882f263b5720218494a25aeef26 /builtin/blame.c | |
parent | doc: add more pointers to gitattributes(5) for userdiff (diff) | |
download | tgif-180d641d7d71ba45a140e9c83777d30be59c4274.tar.xz |
line-log: mention both modes in 'blame' and 'log' short help
'git blame -h' and 'git log -h' both show '-L <n,m>' and describe this
option as "Process only line range n,m, counting from 1". No hint is
given that a function name regex can also be used.
Use <range> instead, and expand the description of the option to mention
both modes. Remove "counting from 1" as it's uneeded; it's uncommon to
refer to the first line of a file as "line 0".
Also, for 'git log', improve the wording to better reflect the long help.
Signed-off-by: Philippe Blain <levraiphilippeblain@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/blame.c')
-rw-r--r-- | builtin/blame.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/builtin/blame.c b/builtin/blame.c index b5036ab327..484e194068 100644 --- a/builtin/blame.c +++ b/builtin/blame.c @@ -891,7 +891,8 @@ int cmd_blame(int argc, const char **argv, const char *prefix) OPT_STRING(0, "contents", &contents_from, N_("file"), N_("Use <file>'s contents as the final image")), OPT_CALLBACK_F('C', NULL, &opt, N_("score"), N_("Find line copies within and across files"), PARSE_OPT_OPTARG, blame_copy_callback), OPT_CALLBACK_F('M', NULL, &opt, N_("score"), N_("Find line movements within and across files"), PARSE_OPT_OPTARG, blame_move_callback), - OPT_STRING_LIST('L', NULL, &range_list, N_("n,m"), N_("Process only line range n,m, counting from 1")), + OPT_STRING_LIST('L', NULL, &range_list, N_("range"), + N_("Process only line range <start>,<end> or function :<funcname>")), OPT__ABBREV(&abbrev), OPT_END() }; |