Re: Call Me Gitless

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

 



On Mon, 18 Aug 2008, Junio C Hamano wrote:

> Daniel Barkalow <barkalow@xxxxxxxxxxxx> writes:
> 
> > if you'd get:
> >
> > --- (index)/foo/bar
> > +++ ./foo/bar
> >
> > people would at least be clear on what information they were getting, even 
> > if they didn't know why they were getting that as opposed to a different 
> > combination.
> 
> [Removed somebody who decided not use git from CC.]
> 
> I know you mentioned this as an example of differenciating the output
> between the modes, and not as a serious suggestion.  The above may apply
> cleanly because "(index)" and "." are both one level deep, but they look
> ugly and the filenames do not align.

I actually think it would be fine; the filenames don't align, but it 
doesn't matter much because we practically never have patches where they 
aren't the same anyway (unless there are also rename headers), so there's 
no need for it to be easy to compare them visually.

> I often make a quick patch all inside the work tree, never committing, and
> then send it out by including "git diff --stat -p" output in the mail as a
> suggested patch.  If we did what you suggest, people could tell such a
> patch and a format-patch output.  I actually do like the fact that we
> consistently say "a/" vs "b/", but some people actually may prefer to see
> the difference.

You could use --src-prefix and --dest-prefix to put it back to a/ and b/ 
(or whatever else you wanted to make it look like). The opposite isn't 
really true though; while I can use --src-prefix='(index)/' 
--dest-prefix='./', I'd need to figure out per-command-line what I'm going 
to be getting, which sort of defeats the purpose.

Actually, this weekend I was trying to cherry-pick the aggregated changes 
to certain files from one branch onto another, and was repeatedly confused 
by the fact that the only available diffs are backwards and there're no 
clues in the output. (That is, you can't get the difference between (---) 
the {index,working tree} and (+++) some commit, and when you've done "git 
diff messy", the resulting diff doesn't give any clues that you're 
deciding whether to add the - lines and remove the + lines.)

	-Daniel
*This .sig left intentionally blank*
--
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]

  Powered by Linux