Re: [PATCH] Use a temporary index for interactive git-commit

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

 



On Thu, Dec 30, 2010 at 12:47:18AM +0000, Conrad Irwin wrote:

> Hitherto even an aborted git commit -p or git commit --interactive has
> added the selected changes to the index.

Hmm. I see how it could be confusing if you do ^C in "git commit -p" and
it actually commits what you had staged. But if I am reading the patch
right here:

> --- a/builtin/add.c
> +++ b/builtin/add.c
> @@ -378,7 +386,7 @@ int cmd_add(int argc, const char **argv, const char *prefix)
>  	if (patch_interactive)
>  		add_interactive = 1;
>  	if (add_interactive)
> -		exit(interactive_add(argc - 1, argv + 1, prefix, patch_interactive));
> +		exit(interactive_add(argc - 1, argv + 1, prefix, patch_interactive, NULL));
>  

this behavior will not apply to "git add -p". So doesn't that introduce
a new confusing inconsistency, that ^C from "git commit -p" abandons
changes entirely, but from "git add -p" will silently stage changes?

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