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

diff -r BASE:HEAD and switched subdirectories?

From: Rory McCann <rory_at_netsoc.ucd.ie>
Date: 2007-02-28 12:20:09 CET

I'm having trouble with svn diff on directories that I've 'switch'ed.

In the repository, I have 2 directories, a and c.

$ svn list -R file:///path/to/repo
a/
a/c/
c/
c/file1
c/file2

In my working copy I have 'a' checked out and have switched 'a/c' to be
c, so it looks like this:

$ find a ! -path '*.svn*'
a
a/c
a/c/file2
a/c/file1

This is because I need the files in c to be shared amoung a few
different directories.

I can update and commit fine and it'll go through the various
subdirectories and commit to the right place, eg:
$ svn update
At revision 9.
$ svn diff
$

But when I try to see what would be changed (remember this has just been
updated, so there should be nothing changed)

$ svn diff -rBASE:HEAD
Index: c/file1
===================================================================
--- c/file1 (revision 9)
+++ c/file1 (working copy)
@@ -1 +0,0 @@
-test c/file1
Index: c/file2
===================================================================
--- c/file2 (revision 9)
+++ c/file2 (working copy)
@@ -1 +0,0 @@
-this is file 2

However normal svn diff works fine:

$ cat >> c/file2
A new line on the end of file2
$ svn diff
Index: c/file2
===================================================================
--- c/file2 (revision 9)
+++ c/file2 (working copy)
@@ -1 +1,2 @@
 this is file 2
+A new line on the end of file2

It looks as if when you svn diff with a switched directory, it doesn't
'follow' the switch. If there actually are updates, they don't appear.
If you cd to the directory and run the command it works correctly, but
this is a bit of a pain.

Is there anyway to 'fix' this?

Thanks,

Rory

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Wed Feb 28 16:06:32 2007

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

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