Re: [PATCH] commit: suggest --amend --reset-author to fix commiter identity

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Matthieu Moy <Matthieu.Moy@xxxxxxx> writes:

> The advantage of this command is that it is cut-and-paste ready, while
> using --author='...' requires the user to type his name and email a
> second time.
>
> Signed-off-by: Matthieu Moy <Matthieu.Moy@xxxxxxx>
> ---
>  builtin/commit.c |    6 +++++-
>  1 files changed, 5 insertions(+), 1 deletions(-)
>
> diff --git a/builtin/commit.c b/builtin/commit.c
> index 22ba54f..440223c 100644
> --- a/builtin/commit.c
> +++ b/builtin/commit.c
> @@ -47,7 +47,11 @@ static const char implicit_ident_advice[] =
>  "\n"
>  "If the identity used for this commit is wrong, you can fix it with:\n"
>  "\n"
> -"    git commit --amend --author='Your Name <you@xxxxxxxxxxx>'\n";
> +"    git commit --amend --author='Your Name <you@xxxxxxxxxxx>'\n"
> +"\n"
> +"or\n"
> +"\n"
> +"    git commit --amend --reset-author\n";

I don't think making the "cheat-sheet" insn longer by offering more
choices is a good idea.  These are messages for lazy and busy people.

Wouldn't it work better to just get rid of the longer form and say
something like:

    ... here is how to tell your name to git (existing message) ...

    After doing the above, run

    	git commit --amend --reset-author

    to fix the identity used for this commit.

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]