[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] Show more information in diff labels in mailer.py

From: Peter Samuelson <peter_at_p12n.org>
Date: 2006-09-19 22:06:07 CEST

I think the parenthesized text is much too verbose:

[Mathias Weinert]
> --- /dev/null 00:00:00 1970 (empty, because file is newly added)
> +++ dir1/file3 Sun Sep 9 01:46:40 2001 (r1)

For added files, "empty" in place of "rNNN" already implies that the
file is newly added.

> --- file2 Sun Sep 9 15:40:00 2001 (r5, original)
> +++ /dev/null 00:00:00 1970 (empty, because file is deleted)

I would abbreviate "(empty, because file is deleted)" as "(deleted)".

> --- dir2/file5 Sun Sep 9 01:46:40 2001 (r1, original)
> +++ dir2/file5 Sun Sep 9 04:33:20 2001 (r2)

For modified files, "original" is redundant. That is what the --- line
_always_ means, and anyone who knows unified diff format _knows_ this.

Now for file copies, we have a problem:

> --- file1 Sun Sep 9 01:46:40 2001 (r1, copy source)
> +++ dir2/file7 Sun Sep 9 07:20:00 2001 (r3, unchanged copied file)

Is this an empty diff (just a diff header and nothing else), or is it
the full contents of the file? Either way, you cannot expect diff -R
to do the right thing, unless file1 is labeled as /dev/null.

> --- file1 Sun Sep 9 01:46:40 2001 (r1, copy source)
> +++ dir3/file8 Sun Sep 9 10:06:40 2001 (r4)

This one is copy + modify. Is this supposed to show a diff between
file1 and file8, or the full contents of file8?

Received on Tue Sep 19 22:06:29 2006

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.