Re: [RFC/PATCH 0/2] New 'stage' command

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Junio C Hamano <gitster@...>
Cc: David Aguilar <davvid@...>, Sverre Rabbelier <srabbelier@...>, <markus.heidelberg@...>, Felipe Contreras <felipe.contreras@...>, <git@...>
Date: Monday, April 6, 2009 - 9:20 am

The following message is a courtesy copy of an article
that has been posted to gmane.comp.version-control.git as well.

Junio C Hamano <gitster@pobox.com> writes:


Thanks, I would have brought it back up myself if you hadn't.


What do you mean? This was a suggestion for how git diff should
work. I fail to see how you would need a WORKTREEANDTHEINDEX there.

I think this is a basic usability issue for a high-level porcelain
command such as diff. Having the command syntax "git diff <something>
<somethingelse>" makes sure you never wonder what you are
diffing. "git diff --cached" makes me wonder what the index is diffed
against every time I see it.

We wouldn't have to use the "STAGE" or "WORKTREE" names, of course. It
doesn't have to look like refspecs even. The last example already has
a syntax that matches the suggestion:

     git diff --cached <commit>

So, extrapolating this to "git diff --worktree --cached" would mean
what "git diff -R" means today etc.

The obvious objection is that "git diff --cached <foo>" would mean the
inverse of "git diff <foo> --cached", but maybe that isn't so
unexpected by the user after all?

-- 
David Kågedal
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[RFC/PATCH 0/2] New 'stage' command, Felipe Contreras, (Sun Apr 5, 9:48 am)
Re: [RFC/PATCH 0/2] New 'stage' command, Markus Heidelberg, (Sun Apr 5, 5:58 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Felipe Contreras, (Sun Apr 5, 6:35 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Markus Heidelberg, (Sun Apr 5, 7:17 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Sverre Rabbelier, (Sun Apr 5, 7:22 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, David Aguilar, (Sun Apr 5, 11:24 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Junio C Hamano, (Mon Apr 6, 1:17 am)
Re: [RFC/PATCH 0/2] New 'stage' command, David Kågedal, (Mon Apr 6, 9:20 am)
Re: [RFC/PATCH 0/2] New 'stage' command, Junio C Hamano, (Mon Apr 6, 2:30 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Octavio Alvarez, (Tue Apr 7, 3:38 am)
Re: [RFC/PATCH 0/2] New 'stage' command, Stefan Karpinski, (Mon Apr 6, 9:36 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Matthieu Moy, (Mon Apr 6, 4:49 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Junio C Hamano, (Mon Apr 6, 8:55 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Felipe Contreras, (Mon Apr 6, 3:13 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Björn, (Mon Apr 6, 3:25 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Felipe Contreras, (Tue Apr 7, 6:01 am)
Re: [RFC/PATCH 0/2] New 'stage' command, Johannes Schindelin, (Tue Apr 7, 8:45 am)
Re: [RFC/PATCH 0/2] New 'stage' command, David Kågedal, (Mon Apr 6, 9:42 am)
Re: [RFC/PATCH 0/2] New 'stage' command, David Aguilar, (Mon Apr 6, 1:53 am)
Re: [RFC/PATCH 0/2] New 'stage' command, Junio C Hamano, (Mon Apr 6, 2:18 am)
Re: [RFC/PATCH 0/2] New 'stage' command, Johannes Schindelin, (Sun Apr 5, 7:45 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Felipe Contreras, (Mon Apr 6, 5:37 am)
Re: [RFC/PATCH 0/2] New 'stage' command, Björn, (Sun Apr 5, 7:06 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Markus Heidelberg, (Sun Apr 5, 7:23 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Björn, (Mon Apr 6, 5:48 am)
Re: [RFC/PATCH 0/2] New 'stage' command, Junio C Hamano, (Sun Apr 5, 3:02 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Felipe Contreras, (Sun Apr 5, 3:28 pm)
[RFC/PATCH 0/2] Re: New 'stage' command, Nicolas Sebrecht, (Sun Apr 5, 3:34 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Junio C Hamano, (Sun Apr 5, 3:33 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Junio C Hamano, (Sun Apr 5, 3:59 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Felipe Contreras, (Sun Apr 5, 4:41 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Jay Soffian, (Sun Apr 5, 4:55 pm)
Re: [RFC/PATCH 0/2] New 'stage' command, Felipe Contreras, (Sun Apr 5, 6:06 pm)
[RFC/PATCH 1/2] git: remote stage, Felipe Contreras, (Sun Apr 5, 9:48 am)
[RFC/PATCH 2/2] Add new 'git stage' script, Felipe Contreras, (Sun Apr 5, 9:48 am)