Re: [PATCH v3 1/2] stash show: teach --include-untracked and --only-untracked

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

 



Hi Junio,

On Tue, Feb 16, 2021 at 12:22:52PM -0800, Junio C Hamano wrote:
>  builtin/stash.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git c/builtin/stash.c w/builtin/stash.c
> index c788a3e236..7e0204bd8a 100644
> --- c/builtin/stash.c
> +++ w/builtin/stash.c
> @@ -807,10 +807,11 @@ static void diff_include_untracked(const struct stash_info *info, struct diff_op
>  		init_tree_desc(&tree_desc[i], tree[i]->buffer, tree[i]->size);
>  	}
>  
> +	/* mimic "git read-tree W U" without "-m" */
>  	unpack_tree_opt.head_idx = -1;
>  	unpack_tree_opt.src_index = &the_index;
>  	unpack_tree_opt.dst_index = &the_index;
> -	unpack_tree_opt.fn = twoway_merge;
> +	unpack_tree_opt.fn = NULL;

Perhaps it would be even more clear if we just removed this line
entirely, otherwise it may give future readers a false impression that
.fn is significant in any way.

Aside from that, both of your SQUASH??? commits look good to me. Thanks
for tying up the loose ends.

-Denton

>  	if (unpack_trees(ARRAY_SIZE(tree_desc), tree_desc, &unpack_tree_opt))
>  		die(_("failed to unpack trees"));



[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