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

New files need to appear in diff output by default.

From: Mo DeJong <supermo_at_bayarea.net>
Date: 2001-09-13 12:18:41 CEST

Hi all.

If you have used CVS for long you have no doubt run into
the `cvs diff -N` flag. The -N flag to cvs diff will
add new files to a generated patch file. I really
could not tell you why it is not on by default in
CVS. Subversion needs to be able to add new files
to a patch file, but it should be safe to just
make this the default instead of adding a command
line switch for it. The current svn diff code will
silently fail in the case of a locally added file
since diff will try to compare the added file to
a non-existent one in the SVN/text-base dir.

I wrote up a quick fix for this problem, it
basically just does a touch of the file in the
SVN/text-base dir before running the diff and then
cleans up the temp file afterward. This patch is
still in the "rough draft" stage since I did not
take any race conditions into account.
Any reactions to this approach?

Mo DeJong

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Received on Sat Oct 21 14:36:41 2006

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