Re: [PATCH 06/11] reset_head(): make default_reflog_action optional

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

 



"Phillip Wood via GitGitGadget" <gitgitgadget@xxxxxxxxx> writes:

> From: Phillip Wood <phillip.wood@xxxxxxxxxxxxx>
>
> This parameter is only needed when a ref is going to be updated and
> the caller does not pass an explicit reflog message. Callers that are
> just discarding changes in the working tree like create_autostash() do
> not update any refs so should not have to worry about passing this
> parameter.
>
> Signed-off-by: Phillip Wood <phillip.wood@xxxxxxxxxxxxx>
> ---
>  builtin/merge.c  |  6 ++----
>  builtin/rebase.c | 14 ++++++--------
>  reset.c          | 16 ++++++++++++----
>  sequencer.c      |  6 +++---
>  sequencer.h      |  3 +--
>  5 files changed, 24 insertions(+), 21 deletions(-)
>
> diff --git a/builtin/merge.c b/builtin/merge.c
> index d2c52b6e971..35833a963fc 100644
> --- a/builtin/merge.c
> +++ b/builtin/merge.c
> @@ -1561,8 +1561,7 @@ int cmd_merge(int argc, const char **argv, const char *prefix)
>  
>  		if (autostash)
>  			create_autostash(the_repository,
> -					 git_path_merge_autostash(the_repository),
> -					 "merge");
> +					 git_path_merge_autostash(the_repository));
>  		if (checkout_fast_forward(the_repository,
>  					  &head_commit->object.oid,
>  					  &commit->object.oid,

The title talks about an optional change to reset_head(); perhaps a
change to create_autostash() should be a separate preliminary step.



[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]

  Powered by Linux